@aws-sdk/client-outposts 3.39.0 → 3.43.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 +41 -0
- package/README.md +10 -10
- package/dist-cjs/Outposts.js +165 -0
- package/dist-cjs/commands/CancelOrderCommand.js +36 -0
- package/dist-cjs/commands/CreateSiteCommand.js +36 -0
- package/dist-cjs/commands/GetCatalogItemCommand.js +36 -0
- package/dist-cjs/commands/GetOrderCommand.js +36 -0
- package/dist-cjs/commands/GetSiteAddressCommand.js +36 -0
- package/dist-cjs/commands/GetSiteCommand.js +36 -0
- package/dist-cjs/commands/ListCatalogItemsCommand.js +36 -0
- package/dist-cjs/commands/ListOrdersCommand.js +36 -0
- package/dist-cjs/commands/UpdateSiteAddressCommand.js +36 -0
- package/dist-cjs/commands/UpdateSiteCommand.js +36 -0
- package/dist-cjs/commands/UpdateSiteRackPhysicalPropertiesCommand.js +36 -0
- package/dist-cjs/commands/index.js +11 -0
- package/dist-cjs/endpoints.js +143 -24
- package/dist-cjs/models/models_0.js +301 -25
- package/dist-cjs/pagination/ListCatalogItemsPaginator.js +35 -0
- package/dist-cjs/pagination/ListOrdersPaginator.js +35 -0
- package/dist-cjs/pagination/index.js +2 -0
- package/dist-cjs/protocols/Aws_restJson1.js +1429 -103
- package/dist-cjs/runtimeConfig.browser.js +6 -3
- package/dist-cjs/runtimeConfig.js +5 -3
- package/dist-es/Outposts.js +165 -0
- package/dist-es/commands/CancelOrderCommand.js +39 -0
- package/dist-es/commands/CreateSiteCommand.js +39 -0
- package/dist-es/commands/GetCatalogItemCommand.js +39 -0
- package/dist-es/commands/GetOrderCommand.js +39 -0
- package/dist-es/commands/GetSiteAddressCommand.js +39 -0
- package/dist-es/commands/GetSiteCommand.js +39 -0
- package/dist-es/commands/ListCatalogItemsCommand.js +39 -0
- package/dist-es/commands/ListOrdersCommand.js +39 -0
- package/dist-es/commands/UpdateSiteAddressCommand.js +39 -0
- package/dist-es/commands/UpdateSiteCommand.js +39 -0
- package/dist-es/commands/UpdateSiteRackPhysicalPropertiesCommand.js +39 -0
- package/dist-es/commands/index.js +11 -0
- package/dist-es/endpoints.js +143 -24
- package/dist-es/models/models_0.js +237 -16
- package/dist-es/pagination/ListCatalogItemsPaginator.js +74 -0
- package/dist-es/pagination/ListOrdersPaginator.js +74 -0
- package/dist-es/pagination/index.js +2 -0
- package/dist-es/protocols/Aws_restJson1.js +1638 -165
- package/dist-es/runtimeConfig.browser.js +3 -2
- package/dist-es/runtimeConfig.js +3 -3
- package/dist-types/Outposts.d.ts +114 -6
- package/dist-types/OutpostsClient.d.ts +24 -5
- package/dist-types/commands/CancelOrderCommand.d.ts +37 -0
- package/dist-types/commands/CreateOrderCommand.d.ts +1 -1
- package/dist-types/commands/CreateOutpostCommand.d.ts +1 -1
- package/dist-types/commands/CreateSiteCommand.d.ts +37 -0
- package/dist-types/commands/DeleteOutpostCommand.d.ts +1 -1
- package/dist-types/commands/DeleteSiteCommand.d.ts +1 -1
- package/dist-types/commands/GetCatalogItemCommand.d.ts +35 -0
- package/dist-types/commands/GetOrderCommand.d.ts +35 -0
- package/dist-types/commands/GetOutpostCommand.d.ts +1 -1
- package/dist-types/commands/GetOutpostInstanceTypesCommand.d.ts +1 -1
- package/dist-types/commands/GetSiteAddressCommand.d.ts +37 -0
- package/dist-types/commands/GetSiteCommand.d.ts +37 -0
- package/dist-types/commands/ListCatalogItemsCommand.d.ts +39 -0
- package/dist-types/commands/ListOrdersCommand.d.ts +36 -0
- package/dist-types/commands/ListOutpostsCommand.d.ts +3 -3
- package/dist-types/commands/ListSitesCommand.d.ts +2 -2
- package/dist-types/commands/ListTagsForResourceCommand.d.ts +1 -1
- package/dist-types/commands/TagResourceCommand.d.ts +1 -1
- package/dist-types/commands/UntagResourceCommand.d.ts +1 -1
- package/dist-types/commands/UpdateSiteAddressCommand.d.ts +46 -0
- package/dist-types/commands/UpdateSiteCommand.d.ts +37 -0
- package/dist-types/commands/UpdateSiteRackPhysicalPropertiesCommand.d.ts +40 -0
- package/dist-types/commands/index.d.ts +11 -0
- package/dist-types/models/models_0.d.ts +1133 -151
- package/dist-types/pagination/ListCatalogItemsPaginator.d.ts +4 -0
- package/dist-types/pagination/ListOrdersPaginator.d.ts +4 -0
- package/dist-types/pagination/index.d.ts +2 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +33 -0
- package/dist-types/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/runtimeConfig.d.ts +2 -0
- package/dist-types/runtimeConfig.native.d.ts +2 -0
- package/dist-types/ts3.4/Outposts.d.ts +55 -0
- package/dist-types/ts3.4/OutpostsClient.d.ts +17 -2
- package/dist-types/ts3.4/commands/CancelOrderCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/CreateSiteCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetCatalogItemCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetOrderCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetSiteAddressCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetSiteCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListCatalogItemsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListOrdersCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateSiteAddressCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateSiteCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateSiteRackPhysicalPropertiesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +11 -0
- package/dist-types/ts3.4/models/models_0.d.ts +511 -52
- package/dist-types/ts3.4/pagination/ListCatalogItemsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/ListOrdersPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/index.d.ts +2 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +33 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +2 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +2 -0
- package/package.json +23 -23
|
@@ -1,8 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1ListTagsForResourceCommand = exports.deserializeAws_restJson1ListSitesCommand = exports.deserializeAws_restJson1ListOutpostsCommand = exports.deserializeAws_restJson1GetOutpostInstanceTypesCommand = exports.deserializeAws_restJson1GetOutpostCommand = exports.deserializeAws_restJson1DeleteSiteCommand = exports.deserializeAws_restJson1DeleteOutpostCommand = exports.deserializeAws_restJson1CreateOutpostCommand = exports.deserializeAws_restJson1CreateOrderCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = exports.serializeAws_restJson1ListSitesCommand = exports.serializeAws_restJson1ListOutpostsCommand = exports.serializeAws_restJson1GetOutpostInstanceTypesCommand = exports.serializeAws_restJson1GetOutpostCommand = exports.serializeAws_restJson1DeleteSiteCommand = exports.serializeAws_restJson1DeleteOutpostCommand = exports.serializeAws_restJson1CreateOutpostCommand = exports.serializeAws_restJson1CreateOrderCommand = void 0;
|
|
3
|
+
exports.deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = exports.deserializeAws_restJson1UpdateSiteAddressCommand = exports.deserializeAws_restJson1UpdateSiteCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1ListTagsForResourceCommand = exports.deserializeAws_restJson1ListSitesCommand = exports.deserializeAws_restJson1ListOutpostsCommand = exports.deserializeAws_restJson1ListOrdersCommand = exports.deserializeAws_restJson1ListCatalogItemsCommand = exports.deserializeAws_restJson1GetSiteAddressCommand = exports.deserializeAws_restJson1GetSiteCommand = exports.deserializeAws_restJson1GetOutpostInstanceTypesCommand = exports.deserializeAws_restJson1GetOutpostCommand = exports.deserializeAws_restJson1GetOrderCommand = exports.deserializeAws_restJson1GetCatalogItemCommand = exports.deserializeAws_restJson1DeleteSiteCommand = exports.deserializeAws_restJson1DeleteOutpostCommand = exports.deserializeAws_restJson1CreateSiteCommand = exports.deserializeAws_restJson1CreateOutpostCommand = exports.deserializeAws_restJson1CreateOrderCommand = exports.deserializeAws_restJson1CancelOrderCommand = exports.serializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = exports.serializeAws_restJson1UpdateSiteAddressCommand = exports.serializeAws_restJson1UpdateSiteCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = exports.serializeAws_restJson1ListSitesCommand = exports.serializeAws_restJson1ListOutpostsCommand = exports.serializeAws_restJson1ListOrdersCommand = exports.serializeAws_restJson1ListCatalogItemsCommand = exports.serializeAws_restJson1GetSiteAddressCommand = exports.serializeAws_restJson1GetSiteCommand = exports.serializeAws_restJson1GetOutpostInstanceTypesCommand = exports.serializeAws_restJson1GetOutpostCommand = exports.serializeAws_restJson1GetOrderCommand = exports.serializeAws_restJson1GetCatalogItemCommand = exports.serializeAws_restJson1DeleteSiteCommand = exports.serializeAws_restJson1DeleteOutpostCommand = exports.serializeAws_restJson1CreateSiteCommand = exports.serializeAws_restJson1CreateOutpostCommand = exports.serializeAws_restJson1CreateOrderCommand = exports.serializeAws_restJson1CancelOrderCommand = 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
|
+
const serializeAws_restJson1CancelOrderCommand = async (input, context) => {
|
|
7
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
8
|
+
const headers = {};
|
|
9
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/orders/{OrderId}/cancel";
|
|
10
|
+
if (input.OrderId !== undefined) {
|
|
11
|
+
const labelValue = input.OrderId;
|
|
12
|
+
if (labelValue.length <= 0) {
|
|
13
|
+
throw new Error("Empty value provided for input HTTP label: OrderId.");
|
|
14
|
+
}
|
|
15
|
+
resolvedPath = resolvedPath.replace("{OrderId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
16
|
+
}
|
|
17
|
+
else {
|
|
18
|
+
throw new Error("No value provided for input HTTP label: OrderId.");
|
|
19
|
+
}
|
|
20
|
+
let body;
|
|
21
|
+
return new protocol_http_1.HttpRequest({
|
|
22
|
+
protocol,
|
|
23
|
+
hostname,
|
|
24
|
+
port,
|
|
25
|
+
method: "POST",
|
|
26
|
+
headers,
|
|
27
|
+
path: resolvedPath,
|
|
28
|
+
body,
|
|
29
|
+
});
|
|
30
|
+
};
|
|
31
|
+
exports.serializeAws_restJson1CancelOrderCommand = serializeAws_restJson1CancelOrderCommand;
|
|
6
32
|
const serializeAws_restJson1CreateOrderCommand = async (input, context) => {
|
|
7
33
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
8
34
|
const headers = {
|
|
@@ -59,6 +85,42 @@ const serializeAws_restJson1CreateOutpostCommand = async (input, context) => {
|
|
|
59
85
|
});
|
|
60
86
|
};
|
|
61
87
|
exports.serializeAws_restJson1CreateOutpostCommand = serializeAws_restJson1CreateOutpostCommand;
|
|
88
|
+
const serializeAws_restJson1CreateSiteCommand = async (input, context) => {
|
|
89
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
90
|
+
const headers = {
|
|
91
|
+
"content-type": "application/json",
|
|
92
|
+
};
|
|
93
|
+
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites";
|
|
94
|
+
let body;
|
|
95
|
+
body = JSON.stringify({
|
|
96
|
+
...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
|
|
97
|
+
...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
|
|
98
|
+
...(input.Notes !== undefined && input.Notes !== null && { Notes: input.Notes }),
|
|
99
|
+
...(input.OperatingAddress !== undefined &&
|
|
100
|
+
input.OperatingAddress !== null && {
|
|
101
|
+
OperatingAddress: serializeAws_restJson1Address(input.OperatingAddress, context),
|
|
102
|
+
}),
|
|
103
|
+
...(input.RackPhysicalProperties !== undefined &&
|
|
104
|
+
input.RackPhysicalProperties !== null && {
|
|
105
|
+
RackPhysicalProperties: serializeAws_restJson1RackPhysicalProperties(input.RackPhysicalProperties, context),
|
|
106
|
+
}),
|
|
107
|
+
...(input.ShippingAddress !== undefined &&
|
|
108
|
+
input.ShippingAddress !== null && {
|
|
109
|
+
ShippingAddress: serializeAws_restJson1Address(input.ShippingAddress, context),
|
|
110
|
+
}),
|
|
111
|
+
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) }),
|
|
112
|
+
});
|
|
113
|
+
return new protocol_http_1.HttpRequest({
|
|
114
|
+
protocol,
|
|
115
|
+
hostname,
|
|
116
|
+
port,
|
|
117
|
+
method: "POST",
|
|
118
|
+
headers,
|
|
119
|
+
path: resolvedPath,
|
|
120
|
+
body,
|
|
121
|
+
});
|
|
122
|
+
};
|
|
123
|
+
exports.serializeAws_restJson1CreateSiteCommand = serializeAws_restJson1CreateSiteCommand;
|
|
62
124
|
const serializeAws_restJson1DeleteOutpostCommand = async (input, context) => {
|
|
63
125
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
64
126
|
const headers = {};
|
|
@@ -111,6 +173,58 @@ const serializeAws_restJson1DeleteSiteCommand = async (input, context) => {
|
|
|
111
173
|
});
|
|
112
174
|
};
|
|
113
175
|
exports.serializeAws_restJson1DeleteSiteCommand = serializeAws_restJson1DeleteSiteCommand;
|
|
176
|
+
const serializeAws_restJson1GetCatalogItemCommand = async (input, context) => {
|
|
177
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
178
|
+
const headers = {};
|
|
179
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/catalog/item/{CatalogItemId}";
|
|
180
|
+
if (input.CatalogItemId !== undefined) {
|
|
181
|
+
const labelValue = input.CatalogItemId;
|
|
182
|
+
if (labelValue.length <= 0) {
|
|
183
|
+
throw new Error("Empty value provided for input HTTP label: CatalogItemId.");
|
|
184
|
+
}
|
|
185
|
+
resolvedPath = resolvedPath.replace("{CatalogItemId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
186
|
+
}
|
|
187
|
+
else {
|
|
188
|
+
throw new Error("No value provided for input HTTP label: CatalogItemId.");
|
|
189
|
+
}
|
|
190
|
+
let body;
|
|
191
|
+
return new protocol_http_1.HttpRequest({
|
|
192
|
+
protocol,
|
|
193
|
+
hostname,
|
|
194
|
+
port,
|
|
195
|
+
method: "GET",
|
|
196
|
+
headers,
|
|
197
|
+
path: resolvedPath,
|
|
198
|
+
body,
|
|
199
|
+
});
|
|
200
|
+
};
|
|
201
|
+
exports.serializeAws_restJson1GetCatalogItemCommand = serializeAws_restJson1GetCatalogItemCommand;
|
|
202
|
+
const serializeAws_restJson1GetOrderCommand = async (input, context) => {
|
|
203
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
204
|
+
const headers = {};
|
|
205
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/orders/{OrderId}";
|
|
206
|
+
if (input.OrderId !== undefined) {
|
|
207
|
+
const labelValue = input.OrderId;
|
|
208
|
+
if (labelValue.length <= 0) {
|
|
209
|
+
throw new Error("Empty value provided for input HTTP label: OrderId.");
|
|
210
|
+
}
|
|
211
|
+
resolvedPath = resolvedPath.replace("{OrderId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
212
|
+
}
|
|
213
|
+
else {
|
|
214
|
+
throw new Error("No value provided for input HTTP label: OrderId.");
|
|
215
|
+
}
|
|
216
|
+
let body;
|
|
217
|
+
return new protocol_http_1.HttpRequest({
|
|
218
|
+
protocol,
|
|
219
|
+
hostname,
|
|
220
|
+
port,
|
|
221
|
+
method: "GET",
|
|
222
|
+
headers,
|
|
223
|
+
path: resolvedPath,
|
|
224
|
+
body,
|
|
225
|
+
});
|
|
226
|
+
};
|
|
227
|
+
exports.serializeAws_restJson1GetOrderCommand = serializeAws_restJson1GetOrderCommand;
|
|
114
228
|
const serializeAws_restJson1GetOutpostCommand = async (input, context) => {
|
|
115
229
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
116
230
|
const headers = {};
|
|
@@ -168,6 +282,114 @@ const serializeAws_restJson1GetOutpostInstanceTypesCommand = async (input, conte
|
|
|
168
282
|
});
|
|
169
283
|
};
|
|
170
284
|
exports.serializeAws_restJson1GetOutpostInstanceTypesCommand = serializeAws_restJson1GetOutpostInstanceTypesCommand;
|
|
285
|
+
const serializeAws_restJson1GetSiteCommand = async (input, context) => {
|
|
286
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
287
|
+
const headers = {};
|
|
288
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}";
|
|
289
|
+
if (input.SiteId !== undefined) {
|
|
290
|
+
const labelValue = input.SiteId;
|
|
291
|
+
if (labelValue.length <= 0) {
|
|
292
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
293
|
+
}
|
|
294
|
+
resolvedPath = resolvedPath.replace("{SiteId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
295
|
+
}
|
|
296
|
+
else {
|
|
297
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
298
|
+
}
|
|
299
|
+
let body;
|
|
300
|
+
return new protocol_http_1.HttpRequest({
|
|
301
|
+
protocol,
|
|
302
|
+
hostname,
|
|
303
|
+
port,
|
|
304
|
+
method: "GET",
|
|
305
|
+
headers,
|
|
306
|
+
path: resolvedPath,
|
|
307
|
+
body,
|
|
308
|
+
});
|
|
309
|
+
};
|
|
310
|
+
exports.serializeAws_restJson1GetSiteCommand = serializeAws_restJson1GetSiteCommand;
|
|
311
|
+
const serializeAws_restJson1GetSiteAddressCommand = async (input, context) => {
|
|
312
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
313
|
+
const headers = {};
|
|
314
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}/address";
|
|
315
|
+
if (input.SiteId !== undefined) {
|
|
316
|
+
const labelValue = input.SiteId;
|
|
317
|
+
if (labelValue.length <= 0) {
|
|
318
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
319
|
+
}
|
|
320
|
+
resolvedPath = resolvedPath.replace("{SiteId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
321
|
+
}
|
|
322
|
+
else {
|
|
323
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
324
|
+
}
|
|
325
|
+
const query = {
|
|
326
|
+
...(input.AddressType !== undefined && { AddressType: input.AddressType }),
|
|
327
|
+
};
|
|
328
|
+
let body;
|
|
329
|
+
return new protocol_http_1.HttpRequest({
|
|
330
|
+
protocol,
|
|
331
|
+
hostname,
|
|
332
|
+
port,
|
|
333
|
+
method: "GET",
|
|
334
|
+
headers,
|
|
335
|
+
path: resolvedPath,
|
|
336
|
+
query,
|
|
337
|
+
body,
|
|
338
|
+
});
|
|
339
|
+
};
|
|
340
|
+
exports.serializeAws_restJson1GetSiteAddressCommand = serializeAws_restJson1GetSiteAddressCommand;
|
|
341
|
+
const serializeAws_restJson1ListCatalogItemsCommand = async (input, context) => {
|
|
342
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
343
|
+
const headers = {};
|
|
344
|
+
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/catalog/items";
|
|
345
|
+
const query = {
|
|
346
|
+
...(input.NextToken !== undefined && { NextToken: input.NextToken }),
|
|
347
|
+
...(input.MaxResults !== undefined && { MaxResults: input.MaxResults.toString() }),
|
|
348
|
+
...(input.ItemClassFilter !== undefined && {
|
|
349
|
+
ItemClassFilter: (input.ItemClassFilter || []).map((_entry) => _entry),
|
|
350
|
+
}),
|
|
351
|
+
...(input.SupportedStorageFilter !== undefined && {
|
|
352
|
+
SupportedStorageFilter: (input.SupportedStorageFilter || []).map((_entry) => _entry),
|
|
353
|
+
}),
|
|
354
|
+
...(input.EC2FamilyFilter !== undefined && {
|
|
355
|
+
EC2FamilyFilter: (input.EC2FamilyFilter || []).map((_entry) => _entry),
|
|
356
|
+
}),
|
|
357
|
+
};
|
|
358
|
+
let body;
|
|
359
|
+
return new protocol_http_1.HttpRequest({
|
|
360
|
+
protocol,
|
|
361
|
+
hostname,
|
|
362
|
+
port,
|
|
363
|
+
method: "GET",
|
|
364
|
+
headers,
|
|
365
|
+
path: resolvedPath,
|
|
366
|
+
query,
|
|
367
|
+
body,
|
|
368
|
+
});
|
|
369
|
+
};
|
|
370
|
+
exports.serializeAws_restJson1ListCatalogItemsCommand = serializeAws_restJson1ListCatalogItemsCommand;
|
|
371
|
+
const serializeAws_restJson1ListOrdersCommand = async (input, context) => {
|
|
372
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
373
|
+
const headers = {};
|
|
374
|
+
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-orders";
|
|
375
|
+
const query = {
|
|
376
|
+
...(input.OutpostIdentifierFilter !== undefined && { OutpostIdentifierFilter: input.OutpostIdentifierFilter }),
|
|
377
|
+
...(input.NextToken !== undefined && { NextToken: input.NextToken }),
|
|
378
|
+
...(input.MaxResults !== undefined && { MaxResults: input.MaxResults.toString() }),
|
|
379
|
+
};
|
|
380
|
+
let body;
|
|
381
|
+
return new protocol_http_1.HttpRequest({
|
|
382
|
+
protocol,
|
|
383
|
+
hostname,
|
|
384
|
+
port,
|
|
385
|
+
method: "GET",
|
|
386
|
+
headers,
|
|
387
|
+
path: resolvedPath,
|
|
388
|
+
query,
|
|
389
|
+
body,
|
|
390
|
+
});
|
|
391
|
+
};
|
|
392
|
+
exports.serializeAws_restJson1ListOrdersCommand = serializeAws_restJson1ListOrdersCommand;
|
|
171
393
|
const serializeAws_restJson1ListOutpostsCommand = async (input, context) => {
|
|
172
394
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
173
395
|
const headers = {};
|
|
@@ -306,18 +528,203 @@ const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
|
|
|
306
528
|
});
|
|
307
529
|
};
|
|
308
530
|
exports.serializeAws_restJson1UntagResourceCommand = serializeAws_restJson1UntagResourceCommand;
|
|
309
|
-
const
|
|
531
|
+
const serializeAws_restJson1UpdateSiteCommand = async (input, context) => {
|
|
532
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
533
|
+
const headers = {
|
|
534
|
+
"content-type": "application/json",
|
|
535
|
+
};
|
|
536
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}";
|
|
537
|
+
if (input.SiteId !== undefined) {
|
|
538
|
+
const labelValue = input.SiteId;
|
|
539
|
+
if (labelValue.length <= 0) {
|
|
540
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
541
|
+
}
|
|
542
|
+
resolvedPath = resolvedPath.replace("{SiteId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
543
|
+
}
|
|
544
|
+
else {
|
|
545
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
546
|
+
}
|
|
547
|
+
let body;
|
|
548
|
+
body = JSON.stringify({
|
|
549
|
+
...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
|
|
550
|
+
...(input.Name !== undefined && input.Name !== null && { Name: input.Name }),
|
|
551
|
+
...(input.Notes !== undefined && input.Notes !== null && { Notes: input.Notes }),
|
|
552
|
+
});
|
|
553
|
+
return new protocol_http_1.HttpRequest({
|
|
554
|
+
protocol,
|
|
555
|
+
hostname,
|
|
556
|
+
port,
|
|
557
|
+
method: "PATCH",
|
|
558
|
+
headers,
|
|
559
|
+
path: resolvedPath,
|
|
560
|
+
body,
|
|
561
|
+
});
|
|
562
|
+
};
|
|
563
|
+
exports.serializeAws_restJson1UpdateSiteCommand = serializeAws_restJson1UpdateSiteCommand;
|
|
564
|
+
const serializeAws_restJson1UpdateSiteAddressCommand = async (input, context) => {
|
|
565
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
566
|
+
const headers = {
|
|
567
|
+
"content-type": "application/json",
|
|
568
|
+
};
|
|
569
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}/address";
|
|
570
|
+
if (input.SiteId !== undefined) {
|
|
571
|
+
const labelValue = input.SiteId;
|
|
572
|
+
if (labelValue.length <= 0) {
|
|
573
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
574
|
+
}
|
|
575
|
+
resolvedPath = resolvedPath.replace("{SiteId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
576
|
+
}
|
|
577
|
+
else {
|
|
578
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
579
|
+
}
|
|
580
|
+
let body;
|
|
581
|
+
body = JSON.stringify({
|
|
582
|
+
...(input.Address !== undefined &&
|
|
583
|
+
input.Address !== null && { Address: serializeAws_restJson1Address(input.Address, context) }),
|
|
584
|
+
...(input.AddressType !== undefined && input.AddressType !== null && { AddressType: input.AddressType }),
|
|
585
|
+
});
|
|
586
|
+
return new protocol_http_1.HttpRequest({
|
|
587
|
+
protocol,
|
|
588
|
+
hostname,
|
|
589
|
+
port,
|
|
590
|
+
method: "PUT",
|
|
591
|
+
headers,
|
|
592
|
+
path: resolvedPath,
|
|
593
|
+
body,
|
|
594
|
+
});
|
|
595
|
+
};
|
|
596
|
+
exports.serializeAws_restJson1UpdateSiteAddressCommand = serializeAws_restJson1UpdateSiteAddressCommand;
|
|
597
|
+
const serializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = async (input, context) => {
|
|
598
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
599
|
+
const headers = {
|
|
600
|
+
"content-type": "application/json",
|
|
601
|
+
};
|
|
602
|
+
let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}/rackPhysicalProperties";
|
|
603
|
+
if (input.SiteId !== undefined) {
|
|
604
|
+
const labelValue = input.SiteId;
|
|
605
|
+
if (labelValue.length <= 0) {
|
|
606
|
+
throw new Error("Empty value provided for input HTTP label: SiteId.");
|
|
607
|
+
}
|
|
608
|
+
resolvedPath = resolvedPath.replace("{SiteId}", smithy_client_1.extendedEncodeURIComponent(labelValue));
|
|
609
|
+
}
|
|
610
|
+
else {
|
|
611
|
+
throw new Error("No value provided for input HTTP label: SiteId.");
|
|
612
|
+
}
|
|
613
|
+
let body;
|
|
614
|
+
body = JSON.stringify({
|
|
615
|
+
...(input.FiberOpticCableType !== undefined &&
|
|
616
|
+
input.FiberOpticCableType !== null && { FiberOpticCableType: input.FiberOpticCableType }),
|
|
617
|
+
...(input.MaximumSupportedWeightLbs !== undefined &&
|
|
618
|
+
input.MaximumSupportedWeightLbs !== null && { MaximumSupportedWeightLbs: input.MaximumSupportedWeightLbs }),
|
|
619
|
+
...(input.OpticalStandard !== undefined &&
|
|
620
|
+
input.OpticalStandard !== null && { OpticalStandard: input.OpticalStandard }),
|
|
621
|
+
...(input.PowerConnector !== undefined &&
|
|
622
|
+
input.PowerConnector !== null && { PowerConnector: input.PowerConnector }),
|
|
623
|
+
...(input.PowerDrawKva !== undefined && input.PowerDrawKva !== null && { PowerDrawKva: input.PowerDrawKva }),
|
|
624
|
+
...(input.PowerFeedDrop !== undefined && input.PowerFeedDrop !== null && { PowerFeedDrop: input.PowerFeedDrop }),
|
|
625
|
+
...(input.PowerPhase !== undefined && input.PowerPhase !== null && { PowerPhase: input.PowerPhase }),
|
|
626
|
+
...(input.UplinkCount !== undefined && input.UplinkCount !== null && { UplinkCount: input.UplinkCount }),
|
|
627
|
+
...(input.UplinkGbps !== undefined && input.UplinkGbps !== null && { UplinkGbps: input.UplinkGbps }),
|
|
628
|
+
});
|
|
629
|
+
return new protocol_http_1.HttpRequest({
|
|
630
|
+
protocol,
|
|
631
|
+
hostname,
|
|
632
|
+
port,
|
|
633
|
+
method: "PATCH",
|
|
634
|
+
headers,
|
|
635
|
+
path: resolvedPath,
|
|
636
|
+
body,
|
|
637
|
+
});
|
|
638
|
+
};
|
|
639
|
+
exports.serializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = serializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand;
|
|
640
|
+
const deserializeAws_restJson1CancelOrderCommand = async (output, context) => {
|
|
310
641
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
311
|
-
return
|
|
642
|
+
return deserializeAws_restJson1CancelOrderCommandError(output, context);
|
|
312
643
|
}
|
|
313
644
|
const contents = {
|
|
314
645
|
$metadata: deserializeMetadata(output),
|
|
315
|
-
Order: undefined,
|
|
316
646
|
};
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
647
|
+
await collectBody(output.body, context);
|
|
648
|
+
return Promise.resolve(contents);
|
|
649
|
+
};
|
|
650
|
+
exports.deserializeAws_restJson1CancelOrderCommand = deserializeAws_restJson1CancelOrderCommand;
|
|
651
|
+
const deserializeAws_restJson1CancelOrderCommandError = async (output, context) => {
|
|
652
|
+
const parsedOutput = {
|
|
653
|
+
...output,
|
|
654
|
+
body: await parseBody(output.body, context),
|
|
655
|
+
};
|
|
656
|
+
let response;
|
|
657
|
+
let errorCode = "UnknownError";
|
|
658
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
659
|
+
switch (errorCode) {
|
|
660
|
+
case "AccessDeniedException":
|
|
661
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
662
|
+
response = {
|
|
663
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
664
|
+
name: errorCode,
|
|
665
|
+
$metadata: deserializeMetadata(output),
|
|
666
|
+
};
|
|
667
|
+
break;
|
|
668
|
+
case "ConflictException":
|
|
669
|
+
case "com.amazonaws.outposts#ConflictException":
|
|
670
|
+
response = {
|
|
671
|
+
...(await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)),
|
|
672
|
+
name: errorCode,
|
|
673
|
+
$metadata: deserializeMetadata(output),
|
|
674
|
+
};
|
|
675
|
+
break;
|
|
676
|
+
case "InternalServerException":
|
|
677
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
678
|
+
response = {
|
|
679
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
680
|
+
name: errorCode,
|
|
681
|
+
$metadata: deserializeMetadata(output),
|
|
682
|
+
};
|
|
683
|
+
break;
|
|
684
|
+
case "NotFoundException":
|
|
685
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
686
|
+
response = {
|
|
687
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
688
|
+
name: errorCode,
|
|
689
|
+
$metadata: deserializeMetadata(output),
|
|
690
|
+
};
|
|
691
|
+
break;
|
|
692
|
+
case "ValidationException":
|
|
693
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
694
|
+
response = {
|
|
695
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
696
|
+
name: errorCode,
|
|
697
|
+
$metadata: deserializeMetadata(output),
|
|
698
|
+
};
|
|
699
|
+
break;
|
|
700
|
+
default:
|
|
701
|
+
const parsedBody = parsedOutput.body;
|
|
702
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
703
|
+
response = {
|
|
704
|
+
...parsedBody,
|
|
705
|
+
name: `${errorCode}`,
|
|
706
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
707
|
+
$fault: "client",
|
|
708
|
+
$metadata: deserializeMetadata(output),
|
|
709
|
+
};
|
|
710
|
+
}
|
|
711
|
+
const message = response.message || response.Message || errorCode;
|
|
712
|
+
response.message = message;
|
|
713
|
+
delete response.Message;
|
|
714
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
715
|
+
};
|
|
716
|
+
const deserializeAws_restJson1CreateOrderCommand = async (output, context) => {
|
|
717
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
718
|
+
return deserializeAws_restJson1CreateOrderCommandError(output, context);
|
|
719
|
+
}
|
|
720
|
+
const contents = {
|
|
721
|
+
$metadata: deserializeMetadata(output),
|
|
722
|
+
Order: undefined,
|
|
723
|
+
};
|
|
724
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
725
|
+
if (data.Order !== undefined && data.Order !== null) {
|
|
726
|
+
contents.Order = deserializeAws_restJson1Order(data.Order, context);
|
|
727
|
+
}
|
|
321
728
|
return Promise.resolve(contents);
|
|
322
729
|
};
|
|
323
730
|
exports.deserializeAws_restJson1CreateOrderCommand = deserializeAws_restJson1CreateOrderCommand;
|
|
@@ -482,6 +889,86 @@ const deserializeAws_restJson1CreateOutpostCommandError = async (output, context
|
|
|
482
889
|
delete response.Message;
|
|
483
890
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
484
891
|
};
|
|
892
|
+
const deserializeAws_restJson1CreateSiteCommand = async (output, context) => {
|
|
893
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
894
|
+
return deserializeAws_restJson1CreateSiteCommandError(output, context);
|
|
895
|
+
}
|
|
896
|
+
const contents = {
|
|
897
|
+
$metadata: deserializeMetadata(output),
|
|
898
|
+
Site: undefined,
|
|
899
|
+
};
|
|
900
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
901
|
+
if (data.Site !== undefined && data.Site !== null) {
|
|
902
|
+
contents.Site = deserializeAws_restJson1Site(data.Site, context);
|
|
903
|
+
}
|
|
904
|
+
return Promise.resolve(contents);
|
|
905
|
+
};
|
|
906
|
+
exports.deserializeAws_restJson1CreateSiteCommand = deserializeAws_restJson1CreateSiteCommand;
|
|
907
|
+
const deserializeAws_restJson1CreateSiteCommandError = async (output, context) => {
|
|
908
|
+
const parsedOutput = {
|
|
909
|
+
...output,
|
|
910
|
+
body: await parseBody(output.body, context),
|
|
911
|
+
};
|
|
912
|
+
let response;
|
|
913
|
+
let errorCode = "UnknownError";
|
|
914
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
915
|
+
switch (errorCode) {
|
|
916
|
+
case "AccessDeniedException":
|
|
917
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
918
|
+
response = {
|
|
919
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
920
|
+
name: errorCode,
|
|
921
|
+
$metadata: deserializeMetadata(output),
|
|
922
|
+
};
|
|
923
|
+
break;
|
|
924
|
+
case "ConflictException":
|
|
925
|
+
case "com.amazonaws.outposts#ConflictException":
|
|
926
|
+
response = {
|
|
927
|
+
...(await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)),
|
|
928
|
+
name: errorCode,
|
|
929
|
+
$metadata: deserializeMetadata(output),
|
|
930
|
+
};
|
|
931
|
+
break;
|
|
932
|
+
case "InternalServerException":
|
|
933
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
934
|
+
response = {
|
|
935
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
936
|
+
name: errorCode,
|
|
937
|
+
$metadata: deserializeMetadata(output),
|
|
938
|
+
};
|
|
939
|
+
break;
|
|
940
|
+
case "ServiceQuotaExceededException":
|
|
941
|
+
case "com.amazonaws.outposts#ServiceQuotaExceededException":
|
|
942
|
+
response = {
|
|
943
|
+
...(await deserializeAws_restJson1ServiceQuotaExceededExceptionResponse(parsedOutput, context)),
|
|
944
|
+
name: errorCode,
|
|
945
|
+
$metadata: deserializeMetadata(output),
|
|
946
|
+
};
|
|
947
|
+
break;
|
|
948
|
+
case "ValidationException":
|
|
949
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
950
|
+
response = {
|
|
951
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
952
|
+
name: errorCode,
|
|
953
|
+
$metadata: deserializeMetadata(output),
|
|
954
|
+
};
|
|
955
|
+
break;
|
|
956
|
+
default:
|
|
957
|
+
const parsedBody = parsedOutput.body;
|
|
958
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
959
|
+
response = {
|
|
960
|
+
...parsedBody,
|
|
961
|
+
name: `${errorCode}`,
|
|
962
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
963
|
+
$fault: "client",
|
|
964
|
+
$metadata: deserializeMetadata(output),
|
|
965
|
+
};
|
|
966
|
+
}
|
|
967
|
+
const message = response.message || response.Message || errorCode;
|
|
968
|
+
response.message = message;
|
|
969
|
+
delete response.Message;
|
|
970
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
971
|
+
};
|
|
485
972
|
const deserializeAws_restJson1DeleteOutpostCommand = async (output, context) => {
|
|
486
973
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
487
974
|
return deserializeAws_restJson1DeleteOutpostCommandError(output, context);
|
|
@@ -634,22 +1121,22 @@ const deserializeAws_restJson1DeleteSiteCommandError = async (output, context) =
|
|
|
634
1121
|
delete response.Message;
|
|
635
1122
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
636
1123
|
};
|
|
637
|
-
const
|
|
1124
|
+
const deserializeAws_restJson1GetCatalogItemCommand = async (output, context) => {
|
|
638
1125
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
639
|
-
return
|
|
1126
|
+
return deserializeAws_restJson1GetCatalogItemCommandError(output, context);
|
|
640
1127
|
}
|
|
641
1128
|
const contents = {
|
|
642
1129
|
$metadata: deserializeMetadata(output),
|
|
643
|
-
|
|
1130
|
+
CatalogItem: undefined,
|
|
644
1131
|
};
|
|
645
1132
|
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
646
|
-
if (data.
|
|
647
|
-
contents.
|
|
1133
|
+
if (data.CatalogItem !== undefined && data.CatalogItem !== null) {
|
|
1134
|
+
contents.CatalogItem = deserializeAws_restJson1CatalogItem(data.CatalogItem, context);
|
|
648
1135
|
}
|
|
649
1136
|
return Promise.resolve(contents);
|
|
650
1137
|
};
|
|
651
|
-
exports.
|
|
652
|
-
const
|
|
1138
|
+
exports.deserializeAws_restJson1GetCatalogItemCommand = deserializeAws_restJson1GetCatalogItemCommand;
|
|
1139
|
+
const deserializeAws_restJson1GetCatalogItemCommandError = async (output, context) => {
|
|
653
1140
|
const parsedOutput = {
|
|
654
1141
|
...output,
|
|
655
1142
|
body: await parseBody(output.body, context),
|
|
@@ -658,14 +1145,70 @@ const deserializeAws_restJson1GetOutpostCommandError = async (output, context) =
|
|
|
658
1145
|
let errorCode = "UnknownError";
|
|
659
1146
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
660
1147
|
switch (errorCode) {
|
|
661
|
-
case "
|
|
662
|
-
case "com.amazonaws.outposts#
|
|
1148
|
+
case "InternalServerException":
|
|
1149
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
663
1150
|
response = {
|
|
664
|
-
...(await
|
|
1151
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1152
|
+
name: errorCode,
|
|
1153
|
+
$metadata: deserializeMetadata(output),
|
|
1154
|
+
};
|
|
1155
|
+
break;
|
|
1156
|
+
case "NotFoundException":
|
|
1157
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1158
|
+
response = {
|
|
1159
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1160
|
+
name: errorCode,
|
|
1161
|
+
$metadata: deserializeMetadata(output),
|
|
1162
|
+
};
|
|
1163
|
+
break;
|
|
1164
|
+
case "ValidationException":
|
|
1165
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1166
|
+
response = {
|
|
1167
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
665
1168
|
name: errorCode,
|
|
666
1169
|
$metadata: deserializeMetadata(output),
|
|
667
1170
|
};
|
|
668
1171
|
break;
|
|
1172
|
+
default:
|
|
1173
|
+
const parsedBody = parsedOutput.body;
|
|
1174
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1175
|
+
response = {
|
|
1176
|
+
...parsedBody,
|
|
1177
|
+
name: `${errorCode}`,
|
|
1178
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1179
|
+
$fault: "client",
|
|
1180
|
+
$metadata: deserializeMetadata(output),
|
|
1181
|
+
};
|
|
1182
|
+
}
|
|
1183
|
+
const message = response.message || response.Message || errorCode;
|
|
1184
|
+
response.message = message;
|
|
1185
|
+
delete response.Message;
|
|
1186
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1187
|
+
};
|
|
1188
|
+
const deserializeAws_restJson1GetOrderCommand = async (output, context) => {
|
|
1189
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1190
|
+
return deserializeAws_restJson1GetOrderCommandError(output, context);
|
|
1191
|
+
}
|
|
1192
|
+
const contents = {
|
|
1193
|
+
$metadata: deserializeMetadata(output),
|
|
1194
|
+
Order: undefined,
|
|
1195
|
+
};
|
|
1196
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1197
|
+
if (data.Order !== undefined && data.Order !== null) {
|
|
1198
|
+
contents.Order = deserializeAws_restJson1Order(data.Order, context);
|
|
1199
|
+
}
|
|
1200
|
+
return Promise.resolve(contents);
|
|
1201
|
+
};
|
|
1202
|
+
exports.deserializeAws_restJson1GetOrderCommand = deserializeAws_restJson1GetOrderCommand;
|
|
1203
|
+
const deserializeAws_restJson1GetOrderCommandError = async (output, context) => {
|
|
1204
|
+
const parsedOutput = {
|
|
1205
|
+
...output,
|
|
1206
|
+
body: await parseBody(output.body, context),
|
|
1207
|
+
};
|
|
1208
|
+
let response;
|
|
1209
|
+
let errorCode = "UnknownError";
|
|
1210
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1211
|
+
switch (errorCode) {
|
|
669
1212
|
case "InternalServerException":
|
|
670
1213
|
case "com.amazonaws.outposts#InternalServerException":
|
|
671
1214
|
response = {
|
|
@@ -674,10 +1217,598 @@ const deserializeAws_restJson1GetOutpostCommandError = async (output, context) =
|
|
|
674
1217
|
$metadata: deserializeMetadata(output),
|
|
675
1218
|
};
|
|
676
1219
|
break;
|
|
677
|
-
case "NotFoundException":
|
|
678
|
-
case "com.amazonaws.outposts#NotFoundException":
|
|
1220
|
+
case "NotFoundException":
|
|
1221
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1222
|
+
response = {
|
|
1223
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1224
|
+
name: errorCode,
|
|
1225
|
+
$metadata: deserializeMetadata(output),
|
|
1226
|
+
};
|
|
1227
|
+
break;
|
|
1228
|
+
case "ValidationException":
|
|
1229
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1230
|
+
response = {
|
|
1231
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1232
|
+
name: errorCode,
|
|
1233
|
+
$metadata: deserializeMetadata(output),
|
|
1234
|
+
};
|
|
1235
|
+
break;
|
|
1236
|
+
default:
|
|
1237
|
+
const parsedBody = parsedOutput.body;
|
|
1238
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1239
|
+
response = {
|
|
1240
|
+
...parsedBody,
|
|
1241
|
+
name: `${errorCode}`,
|
|
1242
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1243
|
+
$fault: "client",
|
|
1244
|
+
$metadata: deserializeMetadata(output),
|
|
1245
|
+
};
|
|
1246
|
+
}
|
|
1247
|
+
const message = response.message || response.Message || errorCode;
|
|
1248
|
+
response.message = message;
|
|
1249
|
+
delete response.Message;
|
|
1250
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1251
|
+
};
|
|
1252
|
+
const deserializeAws_restJson1GetOutpostCommand = async (output, context) => {
|
|
1253
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1254
|
+
return deserializeAws_restJson1GetOutpostCommandError(output, context);
|
|
1255
|
+
}
|
|
1256
|
+
const contents = {
|
|
1257
|
+
$metadata: deserializeMetadata(output),
|
|
1258
|
+
Outpost: undefined,
|
|
1259
|
+
};
|
|
1260
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1261
|
+
if (data.Outpost !== undefined && data.Outpost !== null) {
|
|
1262
|
+
contents.Outpost = deserializeAws_restJson1Outpost(data.Outpost, context);
|
|
1263
|
+
}
|
|
1264
|
+
return Promise.resolve(contents);
|
|
1265
|
+
};
|
|
1266
|
+
exports.deserializeAws_restJson1GetOutpostCommand = deserializeAws_restJson1GetOutpostCommand;
|
|
1267
|
+
const deserializeAws_restJson1GetOutpostCommandError = async (output, context) => {
|
|
1268
|
+
const parsedOutput = {
|
|
1269
|
+
...output,
|
|
1270
|
+
body: await parseBody(output.body, context),
|
|
1271
|
+
};
|
|
1272
|
+
let response;
|
|
1273
|
+
let errorCode = "UnknownError";
|
|
1274
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1275
|
+
switch (errorCode) {
|
|
1276
|
+
case "AccessDeniedException":
|
|
1277
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1278
|
+
response = {
|
|
1279
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1280
|
+
name: errorCode,
|
|
1281
|
+
$metadata: deserializeMetadata(output),
|
|
1282
|
+
};
|
|
1283
|
+
break;
|
|
1284
|
+
case "InternalServerException":
|
|
1285
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1286
|
+
response = {
|
|
1287
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1288
|
+
name: errorCode,
|
|
1289
|
+
$metadata: deserializeMetadata(output),
|
|
1290
|
+
};
|
|
1291
|
+
break;
|
|
1292
|
+
case "NotFoundException":
|
|
1293
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1294
|
+
response = {
|
|
1295
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1296
|
+
name: errorCode,
|
|
1297
|
+
$metadata: deserializeMetadata(output),
|
|
1298
|
+
};
|
|
1299
|
+
break;
|
|
1300
|
+
case "ValidationException":
|
|
1301
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1302
|
+
response = {
|
|
1303
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1304
|
+
name: errorCode,
|
|
1305
|
+
$metadata: deserializeMetadata(output),
|
|
1306
|
+
};
|
|
1307
|
+
break;
|
|
1308
|
+
default:
|
|
1309
|
+
const parsedBody = parsedOutput.body;
|
|
1310
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1311
|
+
response = {
|
|
1312
|
+
...parsedBody,
|
|
1313
|
+
name: `${errorCode}`,
|
|
1314
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1315
|
+
$fault: "client",
|
|
1316
|
+
$metadata: deserializeMetadata(output),
|
|
1317
|
+
};
|
|
1318
|
+
}
|
|
1319
|
+
const message = response.message || response.Message || errorCode;
|
|
1320
|
+
response.message = message;
|
|
1321
|
+
delete response.Message;
|
|
1322
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1323
|
+
};
|
|
1324
|
+
const deserializeAws_restJson1GetOutpostInstanceTypesCommand = async (output, context) => {
|
|
1325
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1326
|
+
return deserializeAws_restJson1GetOutpostInstanceTypesCommandError(output, context);
|
|
1327
|
+
}
|
|
1328
|
+
const contents = {
|
|
1329
|
+
$metadata: deserializeMetadata(output),
|
|
1330
|
+
InstanceTypes: undefined,
|
|
1331
|
+
NextToken: undefined,
|
|
1332
|
+
OutpostArn: undefined,
|
|
1333
|
+
OutpostId: undefined,
|
|
1334
|
+
};
|
|
1335
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1336
|
+
if (data.InstanceTypes !== undefined && data.InstanceTypes !== null) {
|
|
1337
|
+
contents.InstanceTypes = deserializeAws_restJson1InstanceTypeListDefinition(data.InstanceTypes, context);
|
|
1338
|
+
}
|
|
1339
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1340
|
+
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
1341
|
+
}
|
|
1342
|
+
if (data.OutpostArn !== undefined && data.OutpostArn !== null) {
|
|
1343
|
+
contents.OutpostArn = smithy_client_1.expectString(data.OutpostArn);
|
|
1344
|
+
}
|
|
1345
|
+
if (data.OutpostId !== undefined && data.OutpostId !== null) {
|
|
1346
|
+
contents.OutpostId = smithy_client_1.expectString(data.OutpostId);
|
|
1347
|
+
}
|
|
1348
|
+
return Promise.resolve(contents);
|
|
1349
|
+
};
|
|
1350
|
+
exports.deserializeAws_restJson1GetOutpostInstanceTypesCommand = deserializeAws_restJson1GetOutpostInstanceTypesCommand;
|
|
1351
|
+
const deserializeAws_restJson1GetOutpostInstanceTypesCommandError = async (output, context) => {
|
|
1352
|
+
const parsedOutput = {
|
|
1353
|
+
...output,
|
|
1354
|
+
body: await parseBody(output.body, context),
|
|
1355
|
+
};
|
|
1356
|
+
let response;
|
|
1357
|
+
let errorCode = "UnknownError";
|
|
1358
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1359
|
+
switch (errorCode) {
|
|
1360
|
+
case "AccessDeniedException":
|
|
1361
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1362
|
+
response = {
|
|
1363
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1364
|
+
name: errorCode,
|
|
1365
|
+
$metadata: deserializeMetadata(output),
|
|
1366
|
+
};
|
|
1367
|
+
break;
|
|
1368
|
+
case "InternalServerException":
|
|
1369
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1370
|
+
response = {
|
|
1371
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1372
|
+
name: errorCode,
|
|
1373
|
+
$metadata: deserializeMetadata(output),
|
|
1374
|
+
};
|
|
1375
|
+
break;
|
|
1376
|
+
case "NotFoundException":
|
|
1377
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1378
|
+
response = {
|
|
1379
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1380
|
+
name: errorCode,
|
|
1381
|
+
$metadata: deserializeMetadata(output),
|
|
1382
|
+
};
|
|
1383
|
+
break;
|
|
1384
|
+
case "ValidationException":
|
|
1385
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1386
|
+
response = {
|
|
1387
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1388
|
+
name: errorCode,
|
|
1389
|
+
$metadata: deserializeMetadata(output),
|
|
1390
|
+
};
|
|
1391
|
+
break;
|
|
1392
|
+
default:
|
|
1393
|
+
const parsedBody = parsedOutput.body;
|
|
1394
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1395
|
+
response = {
|
|
1396
|
+
...parsedBody,
|
|
1397
|
+
name: `${errorCode}`,
|
|
1398
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1399
|
+
$fault: "client",
|
|
1400
|
+
$metadata: deserializeMetadata(output),
|
|
1401
|
+
};
|
|
1402
|
+
}
|
|
1403
|
+
const message = response.message || response.Message || errorCode;
|
|
1404
|
+
response.message = message;
|
|
1405
|
+
delete response.Message;
|
|
1406
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1407
|
+
};
|
|
1408
|
+
const deserializeAws_restJson1GetSiteCommand = async (output, context) => {
|
|
1409
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1410
|
+
return deserializeAws_restJson1GetSiteCommandError(output, context);
|
|
1411
|
+
}
|
|
1412
|
+
const contents = {
|
|
1413
|
+
$metadata: deserializeMetadata(output),
|
|
1414
|
+
Site: undefined,
|
|
1415
|
+
};
|
|
1416
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1417
|
+
if (data.Site !== undefined && data.Site !== null) {
|
|
1418
|
+
contents.Site = deserializeAws_restJson1Site(data.Site, context);
|
|
1419
|
+
}
|
|
1420
|
+
return Promise.resolve(contents);
|
|
1421
|
+
};
|
|
1422
|
+
exports.deserializeAws_restJson1GetSiteCommand = deserializeAws_restJson1GetSiteCommand;
|
|
1423
|
+
const deserializeAws_restJson1GetSiteCommandError = async (output, context) => {
|
|
1424
|
+
const parsedOutput = {
|
|
1425
|
+
...output,
|
|
1426
|
+
body: await parseBody(output.body, context),
|
|
1427
|
+
};
|
|
1428
|
+
let response;
|
|
1429
|
+
let errorCode = "UnknownError";
|
|
1430
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1431
|
+
switch (errorCode) {
|
|
1432
|
+
case "AccessDeniedException":
|
|
1433
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1434
|
+
response = {
|
|
1435
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1436
|
+
name: errorCode,
|
|
1437
|
+
$metadata: deserializeMetadata(output),
|
|
1438
|
+
};
|
|
1439
|
+
break;
|
|
1440
|
+
case "InternalServerException":
|
|
1441
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1442
|
+
response = {
|
|
1443
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1444
|
+
name: errorCode,
|
|
1445
|
+
$metadata: deserializeMetadata(output),
|
|
1446
|
+
};
|
|
1447
|
+
break;
|
|
1448
|
+
case "NotFoundException":
|
|
1449
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1450
|
+
response = {
|
|
1451
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1452
|
+
name: errorCode,
|
|
1453
|
+
$metadata: deserializeMetadata(output),
|
|
1454
|
+
};
|
|
1455
|
+
break;
|
|
1456
|
+
case "ValidationException":
|
|
1457
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1458
|
+
response = {
|
|
1459
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1460
|
+
name: errorCode,
|
|
1461
|
+
$metadata: deserializeMetadata(output),
|
|
1462
|
+
};
|
|
1463
|
+
break;
|
|
1464
|
+
default:
|
|
1465
|
+
const parsedBody = parsedOutput.body;
|
|
1466
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1467
|
+
response = {
|
|
1468
|
+
...parsedBody,
|
|
1469
|
+
name: `${errorCode}`,
|
|
1470
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1471
|
+
$fault: "client",
|
|
1472
|
+
$metadata: deserializeMetadata(output),
|
|
1473
|
+
};
|
|
1474
|
+
}
|
|
1475
|
+
const message = response.message || response.Message || errorCode;
|
|
1476
|
+
response.message = message;
|
|
1477
|
+
delete response.Message;
|
|
1478
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1479
|
+
};
|
|
1480
|
+
const deserializeAws_restJson1GetSiteAddressCommand = async (output, context) => {
|
|
1481
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1482
|
+
return deserializeAws_restJson1GetSiteAddressCommandError(output, context);
|
|
1483
|
+
}
|
|
1484
|
+
const contents = {
|
|
1485
|
+
$metadata: deserializeMetadata(output),
|
|
1486
|
+
Address: undefined,
|
|
1487
|
+
AddressType: undefined,
|
|
1488
|
+
SiteId: undefined,
|
|
1489
|
+
};
|
|
1490
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1491
|
+
if (data.Address !== undefined && data.Address !== null) {
|
|
1492
|
+
contents.Address = deserializeAws_restJson1Address(data.Address, context);
|
|
1493
|
+
}
|
|
1494
|
+
if (data.AddressType !== undefined && data.AddressType !== null) {
|
|
1495
|
+
contents.AddressType = smithy_client_1.expectString(data.AddressType);
|
|
1496
|
+
}
|
|
1497
|
+
if (data.SiteId !== undefined && data.SiteId !== null) {
|
|
1498
|
+
contents.SiteId = smithy_client_1.expectString(data.SiteId);
|
|
1499
|
+
}
|
|
1500
|
+
return Promise.resolve(contents);
|
|
1501
|
+
};
|
|
1502
|
+
exports.deserializeAws_restJson1GetSiteAddressCommand = deserializeAws_restJson1GetSiteAddressCommand;
|
|
1503
|
+
const deserializeAws_restJson1GetSiteAddressCommandError = async (output, context) => {
|
|
1504
|
+
const parsedOutput = {
|
|
1505
|
+
...output,
|
|
1506
|
+
body: await parseBody(output.body, context),
|
|
1507
|
+
};
|
|
1508
|
+
let response;
|
|
1509
|
+
let errorCode = "UnknownError";
|
|
1510
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1511
|
+
switch (errorCode) {
|
|
1512
|
+
case "AccessDeniedException":
|
|
1513
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1514
|
+
response = {
|
|
1515
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1516
|
+
name: errorCode,
|
|
1517
|
+
$metadata: deserializeMetadata(output),
|
|
1518
|
+
};
|
|
1519
|
+
break;
|
|
1520
|
+
case "InternalServerException":
|
|
1521
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1522
|
+
response = {
|
|
1523
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1524
|
+
name: errorCode,
|
|
1525
|
+
$metadata: deserializeMetadata(output),
|
|
1526
|
+
};
|
|
1527
|
+
break;
|
|
1528
|
+
case "NotFoundException":
|
|
1529
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1530
|
+
response = {
|
|
1531
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1532
|
+
name: errorCode,
|
|
1533
|
+
$metadata: deserializeMetadata(output),
|
|
1534
|
+
};
|
|
1535
|
+
break;
|
|
1536
|
+
case "ValidationException":
|
|
1537
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1538
|
+
response = {
|
|
1539
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1540
|
+
name: errorCode,
|
|
1541
|
+
$metadata: deserializeMetadata(output),
|
|
1542
|
+
};
|
|
1543
|
+
break;
|
|
1544
|
+
default:
|
|
1545
|
+
const parsedBody = parsedOutput.body;
|
|
1546
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1547
|
+
response = {
|
|
1548
|
+
...parsedBody,
|
|
1549
|
+
name: `${errorCode}`,
|
|
1550
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1551
|
+
$fault: "client",
|
|
1552
|
+
$metadata: deserializeMetadata(output),
|
|
1553
|
+
};
|
|
1554
|
+
}
|
|
1555
|
+
const message = response.message || response.Message || errorCode;
|
|
1556
|
+
response.message = message;
|
|
1557
|
+
delete response.Message;
|
|
1558
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1559
|
+
};
|
|
1560
|
+
const deserializeAws_restJson1ListCatalogItemsCommand = async (output, context) => {
|
|
1561
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1562
|
+
return deserializeAws_restJson1ListCatalogItemsCommandError(output, context);
|
|
1563
|
+
}
|
|
1564
|
+
const contents = {
|
|
1565
|
+
$metadata: deserializeMetadata(output),
|
|
1566
|
+
CatalogItems: undefined,
|
|
1567
|
+
NextToken: undefined,
|
|
1568
|
+
};
|
|
1569
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1570
|
+
if (data.CatalogItems !== undefined && data.CatalogItems !== null) {
|
|
1571
|
+
contents.CatalogItems = deserializeAws_restJson1CatalogItemListDefinition(data.CatalogItems, context);
|
|
1572
|
+
}
|
|
1573
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1574
|
+
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
1575
|
+
}
|
|
1576
|
+
return Promise.resolve(contents);
|
|
1577
|
+
};
|
|
1578
|
+
exports.deserializeAws_restJson1ListCatalogItemsCommand = deserializeAws_restJson1ListCatalogItemsCommand;
|
|
1579
|
+
const deserializeAws_restJson1ListCatalogItemsCommandError = async (output, context) => {
|
|
1580
|
+
const parsedOutput = {
|
|
1581
|
+
...output,
|
|
1582
|
+
body: await parseBody(output.body, context),
|
|
1583
|
+
};
|
|
1584
|
+
let response;
|
|
1585
|
+
let errorCode = "UnknownError";
|
|
1586
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1587
|
+
switch (errorCode) {
|
|
1588
|
+
case "InternalServerException":
|
|
1589
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1590
|
+
response = {
|
|
1591
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1592
|
+
name: errorCode,
|
|
1593
|
+
$metadata: deserializeMetadata(output),
|
|
1594
|
+
};
|
|
1595
|
+
break;
|
|
1596
|
+
case "NotFoundException":
|
|
1597
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1598
|
+
response = {
|
|
1599
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1600
|
+
name: errorCode,
|
|
1601
|
+
$metadata: deserializeMetadata(output),
|
|
1602
|
+
};
|
|
1603
|
+
break;
|
|
1604
|
+
case "ValidationException":
|
|
1605
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1606
|
+
response = {
|
|
1607
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1608
|
+
name: errorCode,
|
|
1609
|
+
$metadata: deserializeMetadata(output),
|
|
1610
|
+
};
|
|
1611
|
+
break;
|
|
1612
|
+
default:
|
|
1613
|
+
const parsedBody = parsedOutput.body;
|
|
1614
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1615
|
+
response = {
|
|
1616
|
+
...parsedBody,
|
|
1617
|
+
name: `${errorCode}`,
|
|
1618
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1619
|
+
$fault: "client",
|
|
1620
|
+
$metadata: deserializeMetadata(output),
|
|
1621
|
+
};
|
|
1622
|
+
}
|
|
1623
|
+
const message = response.message || response.Message || errorCode;
|
|
1624
|
+
response.message = message;
|
|
1625
|
+
delete response.Message;
|
|
1626
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1627
|
+
};
|
|
1628
|
+
const deserializeAws_restJson1ListOrdersCommand = async (output, context) => {
|
|
1629
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1630
|
+
return deserializeAws_restJson1ListOrdersCommandError(output, context);
|
|
1631
|
+
}
|
|
1632
|
+
const contents = {
|
|
1633
|
+
$metadata: deserializeMetadata(output),
|
|
1634
|
+
NextToken: undefined,
|
|
1635
|
+
Orders: undefined,
|
|
1636
|
+
};
|
|
1637
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1638
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1639
|
+
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
1640
|
+
}
|
|
1641
|
+
if (data.Orders !== undefined && data.Orders !== null) {
|
|
1642
|
+
contents.Orders = deserializeAws_restJson1OrderSummaryListDefinition(data.Orders, context);
|
|
1643
|
+
}
|
|
1644
|
+
return Promise.resolve(contents);
|
|
1645
|
+
};
|
|
1646
|
+
exports.deserializeAws_restJson1ListOrdersCommand = deserializeAws_restJson1ListOrdersCommand;
|
|
1647
|
+
const deserializeAws_restJson1ListOrdersCommandError = async (output, context) => {
|
|
1648
|
+
const parsedOutput = {
|
|
1649
|
+
...output,
|
|
1650
|
+
body: await parseBody(output.body, context),
|
|
1651
|
+
};
|
|
1652
|
+
let response;
|
|
1653
|
+
let errorCode = "UnknownError";
|
|
1654
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1655
|
+
switch (errorCode) {
|
|
1656
|
+
case "AccessDeniedException":
|
|
1657
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1658
|
+
response = {
|
|
1659
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1660
|
+
name: errorCode,
|
|
1661
|
+
$metadata: deserializeMetadata(output),
|
|
1662
|
+
};
|
|
1663
|
+
break;
|
|
1664
|
+
case "InternalServerException":
|
|
1665
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1666
|
+
response = {
|
|
1667
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1668
|
+
name: errorCode,
|
|
1669
|
+
$metadata: deserializeMetadata(output),
|
|
1670
|
+
};
|
|
1671
|
+
break;
|
|
1672
|
+
case "NotFoundException":
|
|
1673
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
1674
|
+
response = {
|
|
1675
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
1676
|
+
name: errorCode,
|
|
1677
|
+
$metadata: deserializeMetadata(output),
|
|
1678
|
+
};
|
|
1679
|
+
break;
|
|
1680
|
+
case "ValidationException":
|
|
1681
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1682
|
+
response = {
|
|
1683
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1684
|
+
name: errorCode,
|
|
1685
|
+
$metadata: deserializeMetadata(output),
|
|
1686
|
+
};
|
|
1687
|
+
break;
|
|
1688
|
+
default:
|
|
1689
|
+
const parsedBody = parsedOutput.body;
|
|
1690
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1691
|
+
response = {
|
|
1692
|
+
...parsedBody,
|
|
1693
|
+
name: `${errorCode}`,
|
|
1694
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1695
|
+
$fault: "client",
|
|
1696
|
+
$metadata: deserializeMetadata(output),
|
|
1697
|
+
};
|
|
1698
|
+
}
|
|
1699
|
+
const message = response.message || response.Message || errorCode;
|
|
1700
|
+
response.message = message;
|
|
1701
|
+
delete response.Message;
|
|
1702
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1703
|
+
};
|
|
1704
|
+
const deserializeAws_restJson1ListOutpostsCommand = async (output, context) => {
|
|
1705
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1706
|
+
return deserializeAws_restJson1ListOutpostsCommandError(output, context);
|
|
1707
|
+
}
|
|
1708
|
+
const contents = {
|
|
1709
|
+
$metadata: deserializeMetadata(output),
|
|
1710
|
+
NextToken: undefined,
|
|
1711
|
+
Outposts: undefined,
|
|
1712
|
+
};
|
|
1713
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1714
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1715
|
+
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
1716
|
+
}
|
|
1717
|
+
if (data.Outposts !== undefined && data.Outposts !== null) {
|
|
1718
|
+
contents.Outposts = deserializeAws_restJson1outpostListDefinition(data.Outposts, context);
|
|
1719
|
+
}
|
|
1720
|
+
return Promise.resolve(contents);
|
|
1721
|
+
};
|
|
1722
|
+
exports.deserializeAws_restJson1ListOutpostsCommand = deserializeAws_restJson1ListOutpostsCommand;
|
|
1723
|
+
const deserializeAws_restJson1ListOutpostsCommandError = async (output, context) => {
|
|
1724
|
+
const parsedOutput = {
|
|
1725
|
+
...output,
|
|
1726
|
+
body: await parseBody(output.body, context),
|
|
1727
|
+
};
|
|
1728
|
+
let response;
|
|
1729
|
+
let errorCode = "UnknownError";
|
|
1730
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1731
|
+
switch (errorCode) {
|
|
1732
|
+
case "AccessDeniedException":
|
|
1733
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1734
|
+
response = {
|
|
1735
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1736
|
+
name: errorCode,
|
|
1737
|
+
$metadata: deserializeMetadata(output),
|
|
1738
|
+
};
|
|
1739
|
+
break;
|
|
1740
|
+
case "InternalServerException":
|
|
1741
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
1742
|
+
response = {
|
|
1743
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
1744
|
+
name: errorCode,
|
|
1745
|
+
$metadata: deserializeMetadata(output),
|
|
1746
|
+
};
|
|
1747
|
+
break;
|
|
1748
|
+
case "ValidationException":
|
|
1749
|
+
case "com.amazonaws.outposts#ValidationException":
|
|
1750
|
+
response = {
|
|
1751
|
+
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
1752
|
+
name: errorCode,
|
|
1753
|
+
$metadata: deserializeMetadata(output),
|
|
1754
|
+
};
|
|
1755
|
+
break;
|
|
1756
|
+
default:
|
|
1757
|
+
const parsedBody = parsedOutput.body;
|
|
1758
|
+
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1759
|
+
response = {
|
|
1760
|
+
...parsedBody,
|
|
1761
|
+
name: `${errorCode}`,
|
|
1762
|
+
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1763
|
+
$fault: "client",
|
|
1764
|
+
$metadata: deserializeMetadata(output),
|
|
1765
|
+
};
|
|
1766
|
+
}
|
|
1767
|
+
const message = response.message || response.Message || errorCode;
|
|
1768
|
+
response.message = message;
|
|
1769
|
+
delete response.Message;
|
|
1770
|
+
return Promise.reject(Object.assign(new Error(message), response));
|
|
1771
|
+
};
|
|
1772
|
+
const deserializeAws_restJson1ListSitesCommand = async (output, context) => {
|
|
1773
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1774
|
+
return deserializeAws_restJson1ListSitesCommandError(output, context);
|
|
1775
|
+
}
|
|
1776
|
+
const contents = {
|
|
1777
|
+
$metadata: deserializeMetadata(output),
|
|
1778
|
+
NextToken: undefined,
|
|
1779
|
+
Sites: undefined,
|
|
1780
|
+
};
|
|
1781
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
1782
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1783
|
+
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
1784
|
+
}
|
|
1785
|
+
if (data.Sites !== undefined && data.Sites !== null) {
|
|
1786
|
+
contents.Sites = deserializeAws_restJson1siteListDefinition(data.Sites, context);
|
|
1787
|
+
}
|
|
1788
|
+
return Promise.resolve(contents);
|
|
1789
|
+
};
|
|
1790
|
+
exports.deserializeAws_restJson1ListSitesCommand = deserializeAws_restJson1ListSitesCommand;
|
|
1791
|
+
const deserializeAws_restJson1ListSitesCommandError = async (output, context) => {
|
|
1792
|
+
const parsedOutput = {
|
|
1793
|
+
...output,
|
|
1794
|
+
body: await parseBody(output.body, context),
|
|
1795
|
+
};
|
|
1796
|
+
let response;
|
|
1797
|
+
let errorCode = "UnknownError";
|
|
1798
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1799
|
+
switch (errorCode) {
|
|
1800
|
+
case "AccessDeniedException":
|
|
1801
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
1802
|
+
response = {
|
|
1803
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
1804
|
+
name: errorCode,
|
|
1805
|
+
$metadata: deserializeMetadata(output),
|
|
1806
|
+
};
|
|
1807
|
+
break;
|
|
1808
|
+
case "InternalServerException":
|
|
1809
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
679
1810
|
response = {
|
|
680
|
-
...(await
|
|
1811
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
681
1812
|
name: errorCode,
|
|
682
1813
|
$metadata: deserializeMetadata(output),
|
|
683
1814
|
};
|
|
@@ -706,34 +1837,22 @@ const deserializeAws_restJson1GetOutpostCommandError = async (output, context) =
|
|
|
706
1837
|
delete response.Message;
|
|
707
1838
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
708
1839
|
};
|
|
709
|
-
const
|
|
1840
|
+
const deserializeAws_restJson1ListTagsForResourceCommand = async (output, context) => {
|
|
710
1841
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
711
|
-
return
|
|
1842
|
+
return deserializeAws_restJson1ListTagsForResourceCommandError(output, context);
|
|
712
1843
|
}
|
|
713
1844
|
const contents = {
|
|
714
1845
|
$metadata: deserializeMetadata(output),
|
|
715
|
-
|
|
716
|
-
NextToken: undefined,
|
|
717
|
-
OutpostArn: undefined,
|
|
718
|
-
OutpostId: undefined,
|
|
1846
|
+
Tags: undefined,
|
|
719
1847
|
};
|
|
720
1848
|
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
721
|
-
if (data.
|
|
722
|
-
contents.
|
|
723
|
-
}
|
|
724
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
725
|
-
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
726
|
-
}
|
|
727
|
-
if (data.OutpostArn !== undefined && data.OutpostArn !== null) {
|
|
728
|
-
contents.OutpostArn = smithy_client_1.expectString(data.OutpostArn);
|
|
729
|
-
}
|
|
730
|
-
if (data.OutpostId !== undefined && data.OutpostId !== null) {
|
|
731
|
-
contents.OutpostId = smithy_client_1.expectString(data.OutpostId);
|
|
1849
|
+
if (data.Tags !== undefined && data.Tags !== null) {
|
|
1850
|
+
contents.Tags = deserializeAws_restJson1TagMap(data.Tags, context);
|
|
732
1851
|
}
|
|
733
1852
|
return Promise.resolve(contents);
|
|
734
1853
|
};
|
|
735
|
-
exports.
|
|
736
|
-
const
|
|
1854
|
+
exports.deserializeAws_restJson1ListTagsForResourceCommand = deserializeAws_restJson1ListTagsForResourceCommand;
|
|
1855
|
+
const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => {
|
|
737
1856
|
const parsedOutput = {
|
|
738
1857
|
...output,
|
|
739
1858
|
body: await parseBody(output.body, context),
|
|
@@ -742,14 +1861,6 @@ const deserializeAws_restJson1GetOutpostInstanceTypesCommandError = async (outpu
|
|
|
742
1861
|
let errorCode = "UnknownError";
|
|
743
1862
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
744
1863
|
switch (errorCode) {
|
|
745
|
-
case "AccessDeniedException":
|
|
746
|
-
case "com.amazonaws.outposts#AccessDeniedException":
|
|
747
|
-
response = {
|
|
748
|
-
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
749
|
-
name: errorCode,
|
|
750
|
-
$metadata: deserializeMetadata(output),
|
|
751
|
-
};
|
|
752
|
-
break;
|
|
753
1864
|
case "InternalServerException":
|
|
754
1865
|
case "com.amazonaws.outposts#InternalServerException":
|
|
755
1866
|
response = {
|
|
@@ -790,26 +1901,18 @@ const deserializeAws_restJson1GetOutpostInstanceTypesCommandError = async (outpu
|
|
|
790
1901
|
delete response.Message;
|
|
791
1902
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
792
1903
|
};
|
|
793
|
-
const
|
|
1904
|
+
const deserializeAws_restJson1TagResourceCommand = async (output, context) => {
|
|
794
1905
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
795
|
-
return
|
|
1906
|
+
return deserializeAws_restJson1TagResourceCommandError(output, context);
|
|
796
1907
|
}
|
|
797
1908
|
const contents = {
|
|
798
1909
|
$metadata: deserializeMetadata(output),
|
|
799
|
-
NextToken: undefined,
|
|
800
|
-
Outposts: undefined,
|
|
801
1910
|
};
|
|
802
|
-
|
|
803
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
804
|
-
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
805
|
-
}
|
|
806
|
-
if (data.Outposts !== undefined && data.Outposts !== null) {
|
|
807
|
-
contents.Outposts = deserializeAws_restJson1outpostListDefinition(data.Outposts, context);
|
|
808
|
-
}
|
|
1911
|
+
await collectBody(output.body, context);
|
|
809
1912
|
return Promise.resolve(contents);
|
|
810
1913
|
};
|
|
811
|
-
exports.
|
|
812
|
-
const
|
|
1914
|
+
exports.deserializeAws_restJson1TagResourceCommand = deserializeAws_restJson1TagResourceCommand;
|
|
1915
|
+
const deserializeAws_restJson1TagResourceCommandError = async (output, context) => {
|
|
813
1916
|
const parsedOutput = {
|
|
814
1917
|
...output,
|
|
815
1918
|
body: await parseBody(output.body, context),
|
|
@@ -818,18 +1921,18 @@ const deserializeAws_restJson1ListOutpostsCommandError = async (output, context)
|
|
|
818
1921
|
let errorCode = "UnknownError";
|
|
819
1922
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
820
1923
|
switch (errorCode) {
|
|
821
|
-
case "
|
|
822
|
-
case "com.amazonaws.outposts#
|
|
1924
|
+
case "InternalServerException":
|
|
1925
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
823
1926
|
response = {
|
|
824
|
-
...(await
|
|
1927
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
825
1928
|
name: errorCode,
|
|
826
1929
|
$metadata: deserializeMetadata(output),
|
|
827
1930
|
};
|
|
828
1931
|
break;
|
|
829
|
-
case "
|
|
830
|
-
case "com.amazonaws.outposts#
|
|
1932
|
+
case "NotFoundException":
|
|
1933
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
831
1934
|
response = {
|
|
832
|
-
...(await
|
|
1935
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
833
1936
|
name: errorCode,
|
|
834
1937
|
$metadata: deserializeMetadata(output),
|
|
835
1938
|
};
|
|
@@ -858,26 +1961,18 @@ const deserializeAws_restJson1ListOutpostsCommandError = async (output, context)
|
|
|
858
1961
|
delete response.Message;
|
|
859
1962
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
860
1963
|
};
|
|
861
|
-
const
|
|
1964
|
+
const deserializeAws_restJson1UntagResourceCommand = async (output, context) => {
|
|
862
1965
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
863
|
-
return
|
|
1966
|
+
return deserializeAws_restJson1UntagResourceCommandError(output, context);
|
|
864
1967
|
}
|
|
865
1968
|
const contents = {
|
|
866
1969
|
$metadata: deserializeMetadata(output),
|
|
867
|
-
NextToken: undefined,
|
|
868
|
-
Sites: undefined,
|
|
869
1970
|
};
|
|
870
|
-
|
|
871
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
872
|
-
contents.NextToken = smithy_client_1.expectString(data.NextToken);
|
|
873
|
-
}
|
|
874
|
-
if (data.Sites !== undefined && data.Sites !== null) {
|
|
875
|
-
contents.Sites = deserializeAws_restJson1siteListDefinition(data.Sites, context);
|
|
876
|
-
}
|
|
1971
|
+
await collectBody(output.body, context);
|
|
877
1972
|
return Promise.resolve(contents);
|
|
878
1973
|
};
|
|
879
|
-
exports.
|
|
880
|
-
const
|
|
1974
|
+
exports.deserializeAws_restJson1UntagResourceCommand = deserializeAws_restJson1UntagResourceCommand;
|
|
1975
|
+
const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => {
|
|
881
1976
|
const parsedOutput = {
|
|
882
1977
|
...output,
|
|
883
1978
|
body: await parseBody(output.body, context),
|
|
@@ -886,18 +1981,18 @@ const deserializeAws_restJson1ListSitesCommandError = async (output, context) =>
|
|
|
886
1981
|
let errorCode = "UnknownError";
|
|
887
1982
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
888
1983
|
switch (errorCode) {
|
|
889
|
-
case "
|
|
890
|
-
case "com.amazonaws.outposts#
|
|
1984
|
+
case "InternalServerException":
|
|
1985
|
+
case "com.amazonaws.outposts#InternalServerException":
|
|
891
1986
|
response = {
|
|
892
|
-
...(await
|
|
1987
|
+
...(await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)),
|
|
893
1988
|
name: errorCode,
|
|
894
1989
|
$metadata: deserializeMetadata(output),
|
|
895
1990
|
};
|
|
896
1991
|
break;
|
|
897
|
-
case "
|
|
898
|
-
case "com.amazonaws.outposts#
|
|
1992
|
+
case "NotFoundException":
|
|
1993
|
+
case "com.amazonaws.outposts#NotFoundException":
|
|
899
1994
|
response = {
|
|
900
|
-
...(await
|
|
1995
|
+
...(await deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)),
|
|
901
1996
|
name: errorCode,
|
|
902
1997
|
$metadata: deserializeMetadata(output),
|
|
903
1998
|
};
|
|
@@ -926,22 +2021,22 @@ const deserializeAws_restJson1ListSitesCommandError = async (output, context) =>
|
|
|
926
2021
|
delete response.Message;
|
|
927
2022
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
928
2023
|
};
|
|
929
|
-
const
|
|
2024
|
+
const deserializeAws_restJson1UpdateSiteCommand = async (output, context) => {
|
|
930
2025
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
931
|
-
return
|
|
2026
|
+
return deserializeAws_restJson1UpdateSiteCommandError(output, context);
|
|
932
2027
|
}
|
|
933
2028
|
const contents = {
|
|
934
2029
|
$metadata: deserializeMetadata(output),
|
|
935
|
-
|
|
2030
|
+
Site: undefined,
|
|
936
2031
|
};
|
|
937
2032
|
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
938
|
-
if (data.
|
|
939
|
-
contents.
|
|
2033
|
+
if (data.Site !== undefined && data.Site !== null) {
|
|
2034
|
+
contents.Site = deserializeAws_restJson1Site(data.Site, context);
|
|
940
2035
|
}
|
|
941
2036
|
return Promise.resolve(contents);
|
|
942
2037
|
};
|
|
943
|
-
exports.
|
|
944
|
-
const
|
|
2038
|
+
exports.deserializeAws_restJson1UpdateSiteCommand = deserializeAws_restJson1UpdateSiteCommand;
|
|
2039
|
+
const deserializeAws_restJson1UpdateSiteCommandError = async (output, context) => {
|
|
945
2040
|
const parsedOutput = {
|
|
946
2041
|
...output,
|
|
947
2042
|
body: await parseBody(output.body, context),
|
|
@@ -950,6 +2045,22 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
950
2045
|
let errorCode = "UnknownError";
|
|
951
2046
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
952
2047
|
switch (errorCode) {
|
|
2048
|
+
case "AccessDeniedException":
|
|
2049
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
2050
|
+
response = {
|
|
2051
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
2052
|
+
name: errorCode,
|
|
2053
|
+
$metadata: deserializeMetadata(output),
|
|
2054
|
+
};
|
|
2055
|
+
break;
|
|
2056
|
+
case "ConflictException":
|
|
2057
|
+
case "com.amazonaws.outposts#ConflictException":
|
|
2058
|
+
response = {
|
|
2059
|
+
...(await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)),
|
|
2060
|
+
name: errorCode,
|
|
2061
|
+
$metadata: deserializeMetadata(output),
|
|
2062
|
+
};
|
|
2063
|
+
break;
|
|
953
2064
|
case "InternalServerException":
|
|
954
2065
|
case "com.amazonaws.outposts#InternalServerException":
|
|
955
2066
|
response = {
|
|
@@ -990,18 +2101,26 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
990
2101
|
delete response.Message;
|
|
991
2102
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
992
2103
|
};
|
|
993
|
-
const
|
|
2104
|
+
const deserializeAws_restJson1UpdateSiteAddressCommand = async (output, context) => {
|
|
994
2105
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
995
|
-
return
|
|
2106
|
+
return deserializeAws_restJson1UpdateSiteAddressCommandError(output, context);
|
|
996
2107
|
}
|
|
997
2108
|
const contents = {
|
|
998
2109
|
$metadata: deserializeMetadata(output),
|
|
2110
|
+
Address: undefined,
|
|
2111
|
+
AddressType: undefined,
|
|
999
2112
|
};
|
|
1000
|
-
await
|
|
2113
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
2114
|
+
if (data.Address !== undefined && data.Address !== null) {
|
|
2115
|
+
contents.Address = deserializeAws_restJson1Address(data.Address, context);
|
|
2116
|
+
}
|
|
2117
|
+
if (data.AddressType !== undefined && data.AddressType !== null) {
|
|
2118
|
+
contents.AddressType = smithy_client_1.expectString(data.AddressType);
|
|
2119
|
+
}
|
|
1001
2120
|
return Promise.resolve(contents);
|
|
1002
2121
|
};
|
|
1003
|
-
exports.
|
|
1004
|
-
const
|
|
2122
|
+
exports.deserializeAws_restJson1UpdateSiteAddressCommand = deserializeAws_restJson1UpdateSiteAddressCommand;
|
|
2123
|
+
const deserializeAws_restJson1UpdateSiteAddressCommandError = async (output, context) => {
|
|
1005
2124
|
const parsedOutput = {
|
|
1006
2125
|
...output,
|
|
1007
2126
|
body: await parseBody(output.body, context),
|
|
@@ -1010,6 +2129,22 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
1010
2129
|
let errorCode = "UnknownError";
|
|
1011
2130
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1012
2131
|
switch (errorCode) {
|
|
2132
|
+
case "AccessDeniedException":
|
|
2133
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
2134
|
+
response = {
|
|
2135
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
2136
|
+
name: errorCode,
|
|
2137
|
+
$metadata: deserializeMetadata(output),
|
|
2138
|
+
};
|
|
2139
|
+
break;
|
|
2140
|
+
case "ConflictException":
|
|
2141
|
+
case "com.amazonaws.outposts#ConflictException":
|
|
2142
|
+
response = {
|
|
2143
|
+
...(await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)),
|
|
2144
|
+
name: errorCode,
|
|
2145
|
+
$metadata: deserializeMetadata(output),
|
|
2146
|
+
};
|
|
2147
|
+
break;
|
|
1013
2148
|
case "InternalServerException":
|
|
1014
2149
|
case "com.amazonaws.outposts#InternalServerException":
|
|
1015
2150
|
response = {
|
|
@@ -1050,18 +2185,22 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
1050
2185
|
delete response.Message;
|
|
1051
2186
|
return Promise.reject(Object.assign(new Error(message), response));
|
|
1052
2187
|
};
|
|
1053
|
-
const
|
|
2188
|
+
const deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = async (output, context) => {
|
|
1054
2189
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1055
|
-
return
|
|
2190
|
+
return deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommandError(output, context);
|
|
1056
2191
|
}
|
|
1057
2192
|
const contents = {
|
|
1058
2193
|
$metadata: deserializeMetadata(output),
|
|
2194
|
+
Site: undefined,
|
|
1059
2195
|
};
|
|
1060
|
-
await
|
|
2196
|
+
const data = smithy_client_1.expectNonNull(smithy_client_1.expectObject(await parseBody(output.body, context)), "body");
|
|
2197
|
+
if (data.Site !== undefined && data.Site !== null) {
|
|
2198
|
+
contents.Site = deserializeAws_restJson1Site(data.Site, context);
|
|
2199
|
+
}
|
|
1061
2200
|
return Promise.resolve(contents);
|
|
1062
2201
|
};
|
|
1063
|
-
exports.
|
|
1064
|
-
const
|
|
2202
|
+
exports.deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand = deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommand;
|
|
2203
|
+
const deserializeAws_restJson1UpdateSiteRackPhysicalPropertiesCommandError = async (output, context) => {
|
|
1065
2204
|
const parsedOutput = {
|
|
1066
2205
|
...output,
|
|
1067
2206
|
body: await parseBody(output.body, context),
|
|
@@ -1070,6 +2209,22 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
|
|
|
1070
2209
|
let errorCode = "UnknownError";
|
|
1071
2210
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1072
2211
|
switch (errorCode) {
|
|
2212
|
+
case "AccessDeniedException":
|
|
2213
|
+
case "com.amazonaws.outposts#AccessDeniedException":
|
|
2214
|
+
response = {
|
|
2215
|
+
...(await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)),
|
|
2216
|
+
name: errorCode,
|
|
2217
|
+
$metadata: deserializeMetadata(output),
|
|
2218
|
+
};
|
|
2219
|
+
break;
|
|
2220
|
+
case "ConflictException":
|
|
2221
|
+
case "com.amazonaws.outposts#ConflictException":
|
|
2222
|
+
response = {
|
|
2223
|
+
...(await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)),
|
|
2224
|
+
name: errorCode,
|
|
2225
|
+
$metadata: deserializeMetadata(output),
|
|
2226
|
+
};
|
|
2227
|
+
break;
|
|
1073
2228
|
case "InternalServerException":
|
|
1074
2229
|
case "com.amazonaws.outposts#InternalServerException":
|
|
1075
2230
|
response = {
|
|
@@ -1196,6 +2351,23 @@ const deserializeAws_restJson1ValidationExceptionResponse = async (parsedOutput,
|
|
|
1196
2351
|
}
|
|
1197
2352
|
return contents;
|
|
1198
2353
|
};
|
|
2354
|
+
const serializeAws_restJson1Address = (input, context) => {
|
|
2355
|
+
return {
|
|
2356
|
+
...(input.AddressLine1 !== undefined && input.AddressLine1 !== null && { AddressLine1: input.AddressLine1 }),
|
|
2357
|
+
...(input.AddressLine2 !== undefined && input.AddressLine2 !== null && { AddressLine2: input.AddressLine2 }),
|
|
2358
|
+
...(input.AddressLine3 !== undefined && input.AddressLine3 !== null && { AddressLine3: input.AddressLine3 }),
|
|
2359
|
+
...(input.City !== undefined && input.City !== null && { City: input.City }),
|
|
2360
|
+
...(input.ContactName !== undefined && input.ContactName !== null && { ContactName: input.ContactName }),
|
|
2361
|
+
...(input.ContactPhoneNumber !== undefined &&
|
|
2362
|
+
input.ContactPhoneNumber !== null && { ContactPhoneNumber: input.ContactPhoneNumber }),
|
|
2363
|
+
...(input.CountryCode !== undefined && input.CountryCode !== null && { CountryCode: input.CountryCode }),
|
|
2364
|
+
...(input.DistrictOrCounty !== undefined &&
|
|
2365
|
+
input.DistrictOrCounty !== null && { DistrictOrCounty: input.DistrictOrCounty }),
|
|
2366
|
+
...(input.Municipality !== undefined && input.Municipality !== null && { Municipality: input.Municipality }),
|
|
2367
|
+
...(input.PostalCode !== undefined && input.PostalCode !== null && { PostalCode: input.PostalCode }),
|
|
2368
|
+
...(input.StateOrRegion !== undefined && input.StateOrRegion !== null && { StateOrRegion: input.StateOrRegion }),
|
|
2369
|
+
};
|
|
2370
|
+
};
|
|
1199
2371
|
const serializeAws_restJson1LineItemRequest = (input, context) => {
|
|
1200
2372
|
return {
|
|
1201
2373
|
...(input.CatalogItemId !== undefined && input.CatalogItemId !== null && { CatalogItemId: input.CatalogItemId }),
|
|
@@ -1212,6 +2384,23 @@ const serializeAws_restJson1LineItemRequestListDefinition = (input, context) =>
|
|
|
1212
2384
|
return serializeAws_restJson1LineItemRequest(entry, context);
|
|
1213
2385
|
});
|
|
1214
2386
|
};
|
|
2387
|
+
const serializeAws_restJson1RackPhysicalProperties = (input, context) => {
|
|
2388
|
+
return {
|
|
2389
|
+
...(input.FiberOpticCableType !== undefined &&
|
|
2390
|
+
input.FiberOpticCableType !== null && { FiberOpticCableType: input.FiberOpticCableType }),
|
|
2391
|
+
...(input.MaximumSupportedWeightLbs !== undefined &&
|
|
2392
|
+
input.MaximumSupportedWeightLbs !== null && { MaximumSupportedWeightLbs: input.MaximumSupportedWeightLbs }),
|
|
2393
|
+
...(input.OpticalStandard !== undefined &&
|
|
2394
|
+
input.OpticalStandard !== null && { OpticalStandard: input.OpticalStandard }),
|
|
2395
|
+
...(input.PowerConnector !== undefined &&
|
|
2396
|
+
input.PowerConnector !== null && { PowerConnector: input.PowerConnector }),
|
|
2397
|
+
...(input.PowerDrawKva !== undefined && input.PowerDrawKva !== null && { PowerDrawKva: input.PowerDrawKva }),
|
|
2398
|
+
...(input.PowerFeedDrop !== undefined && input.PowerFeedDrop !== null && { PowerFeedDrop: input.PowerFeedDrop }),
|
|
2399
|
+
...(input.PowerPhase !== undefined && input.PowerPhase !== null && { PowerPhase: input.PowerPhase }),
|
|
2400
|
+
...(input.UplinkCount !== undefined && input.UplinkCount !== null && { UplinkCount: input.UplinkCount }),
|
|
2401
|
+
...(input.UplinkGbps !== undefined && input.UplinkGbps !== null && { UplinkGbps: input.UplinkGbps }),
|
|
2402
|
+
};
|
|
2403
|
+
};
|
|
1215
2404
|
const serializeAws_restJson1TagMap = (input, context) => {
|
|
1216
2405
|
return Object.entries(input).reduce((acc, [key, value]) => {
|
|
1217
2406
|
if (value === null) {
|
|
@@ -1223,6 +2412,65 @@ const serializeAws_restJson1TagMap = (input, context) => {
|
|
|
1223
2412
|
};
|
|
1224
2413
|
}, {});
|
|
1225
2414
|
};
|
|
2415
|
+
const deserializeAws_restJson1Address = (output, context) => {
|
|
2416
|
+
return {
|
|
2417
|
+
AddressLine1: smithy_client_1.expectString(output.AddressLine1),
|
|
2418
|
+
AddressLine2: smithy_client_1.expectString(output.AddressLine2),
|
|
2419
|
+
AddressLine3: smithy_client_1.expectString(output.AddressLine3),
|
|
2420
|
+
City: smithy_client_1.expectString(output.City),
|
|
2421
|
+
ContactName: smithy_client_1.expectString(output.ContactName),
|
|
2422
|
+
ContactPhoneNumber: smithy_client_1.expectString(output.ContactPhoneNumber),
|
|
2423
|
+
CountryCode: smithy_client_1.expectString(output.CountryCode),
|
|
2424
|
+
DistrictOrCounty: smithy_client_1.expectString(output.DistrictOrCounty),
|
|
2425
|
+
Municipality: smithy_client_1.expectString(output.Municipality),
|
|
2426
|
+
PostalCode: smithy_client_1.expectString(output.PostalCode),
|
|
2427
|
+
StateOrRegion: smithy_client_1.expectString(output.StateOrRegion),
|
|
2428
|
+
};
|
|
2429
|
+
};
|
|
2430
|
+
const deserializeAws_restJson1CatalogItem = (output, context) => {
|
|
2431
|
+
return {
|
|
2432
|
+
CatalogItemId: smithy_client_1.expectString(output.CatalogItemId),
|
|
2433
|
+
EC2Capacities: output.EC2Capacities !== undefined && output.EC2Capacities !== null
|
|
2434
|
+
? deserializeAws_restJson1EC2CapacityListDefinition(output.EC2Capacities, context)
|
|
2435
|
+
: undefined,
|
|
2436
|
+
ItemStatus: smithy_client_1.expectString(output.ItemStatus),
|
|
2437
|
+
PowerKva: smithy_client_1.limitedParseFloat32(output.PowerKva),
|
|
2438
|
+
SupportedStorage: output.SupportedStorage !== undefined && output.SupportedStorage !== null
|
|
2439
|
+
? deserializeAws_restJson1SupportedStorageList(output.SupportedStorage, context)
|
|
2440
|
+
: undefined,
|
|
2441
|
+
SupportedUplinkGbps: output.SupportedUplinkGbps !== undefined && output.SupportedUplinkGbps !== null
|
|
2442
|
+
? deserializeAws_restJson1SupportedUplinkGbpsListDefinition(output.SupportedUplinkGbps, context)
|
|
2443
|
+
: undefined,
|
|
2444
|
+
WeightLbs: smithy_client_1.expectInt32(output.WeightLbs),
|
|
2445
|
+
};
|
|
2446
|
+
};
|
|
2447
|
+
const deserializeAws_restJson1CatalogItemListDefinition = (output, context) => {
|
|
2448
|
+
return (output || [])
|
|
2449
|
+
.filter((e) => e != null)
|
|
2450
|
+
.map((entry) => {
|
|
2451
|
+
if (entry === null) {
|
|
2452
|
+
return null;
|
|
2453
|
+
}
|
|
2454
|
+
return deserializeAws_restJson1CatalogItem(entry, context);
|
|
2455
|
+
});
|
|
2456
|
+
};
|
|
2457
|
+
const deserializeAws_restJson1EC2Capacity = (output, context) => {
|
|
2458
|
+
return {
|
|
2459
|
+
Family: smithy_client_1.expectString(output.Family),
|
|
2460
|
+
MaxSize: smithy_client_1.expectString(output.MaxSize),
|
|
2461
|
+
Quantity: smithy_client_1.expectString(output.Quantity),
|
|
2462
|
+
};
|
|
2463
|
+
};
|
|
2464
|
+
const deserializeAws_restJson1EC2CapacityListDefinition = (output, context) => {
|
|
2465
|
+
return (output || [])
|
|
2466
|
+
.filter((e) => e != null)
|
|
2467
|
+
.map((entry) => {
|
|
2468
|
+
if (entry === null) {
|
|
2469
|
+
return null;
|
|
2470
|
+
}
|
|
2471
|
+
return deserializeAws_restJson1EC2Capacity(entry, context);
|
|
2472
|
+
});
|
|
2473
|
+
};
|
|
1226
2474
|
const deserializeAws_restJson1InstanceTypeItem = (output, context) => {
|
|
1227
2475
|
return {
|
|
1228
2476
|
InstanceType: smithy_client_1.expectString(output.InstanceType),
|
|
@@ -1256,6 +2504,17 @@ const deserializeAws_restJson1LineItemListDefinition = (output, context) => {
|
|
|
1256
2504
|
return deserializeAws_restJson1LineItem(entry, context);
|
|
1257
2505
|
});
|
|
1258
2506
|
};
|
|
2507
|
+
const deserializeAws_restJson1LineItemStatusCounts = (output, context) => {
|
|
2508
|
+
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
2509
|
+
if (value === null) {
|
|
2510
|
+
return acc;
|
|
2511
|
+
}
|
|
2512
|
+
return {
|
|
2513
|
+
...acc,
|
|
2514
|
+
[key]: smithy_client_1.expectInt32(value),
|
|
2515
|
+
};
|
|
2516
|
+
}, {});
|
|
2517
|
+
};
|
|
1259
2518
|
const deserializeAws_restJson1Order = (output, context) => {
|
|
1260
2519
|
return {
|
|
1261
2520
|
LineItems: output.LineItems !== undefined && output.LineItems !== null
|
|
@@ -1273,6 +2532,33 @@ const deserializeAws_restJson1Order = (output, context) => {
|
|
|
1273
2532
|
Status: smithy_client_1.expectString(output.Status),
|
|
1274
2533
|
};
|
|
1275
2534
|
};
|
|
2535
|
+
const deserializeAws_restJson1OrderSummary = (output, context) => {
|
|
2536
|
+
return {
|
|
2537
|
+
LineItemCountsByStatus: output.LineItemCountsByStatus !== undefined && output.LineItemCountsByStatus !== null
|
|
2538
|
+
? deserializeAws_restJson1LineItemStatusCounts(output.LineItemCountsByStatus, context)
|
|
2539
|
+
: undefined,
|
|
2540
|
+
OrderFulfilledDate: output.OrderFulfilledDate !== undefined && output.OrderFulfilledDate !== null
|
|
2541
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseEpochTimestamp(smithy_client_1.expectNumber(output.OrderFulfilledDate)))
|
|
2542
|
+
: undefined,
|
|
2543
|
+
OrderId: smithy_client_1.expectString(output.OrderId),
|
|
2544
|
+
OrderSubmissionDate: output.OrderSubmissionDate !== undefined && output.OrderSubmissionDate !== null
|
|
2545
|
+
? smithy_client_1.expectNonNull(smithy_client_1.parseEpochTimestamp(smithy_client_1.expectNumber(output.OrderSubmissionDate)))
|
|
2546
|
+
: undefined,
|
|
2547
|
+
OrderType: smithy_client_1.expectString(output.OrderType),
|
|
2548
|
+
OutpostId: smithy_client_1.expectString(output.OutpostId),
|
|
2549
|
+
Status: smithy_client_1.expectString(output.Status),
|
|
2550
|
+
};
|
|
2551
|
+
};
|
|
2552
|
+
const deserializeAws_restJson1OrderSummaryListDefinition = (output, context) => {
|
|
2553
|
+
return (output || [])
|
|
2554
|
+
.filter((e) => e != null)
|
|
2555
|
+
.map((entry) => {
|
|
2556
|
+
if (entry === null) {
|
|
2557
|
+
return null;
|
|
2558
|
+
}
|
|
2559
|
+
return deserializeAws_restJson1OrderSummary(entry, context);
|
|
2560
|
+
});
|
|
2561
|
+
};
|
|
1276
2562
|
const deserializeAws_restJson1Outpost = (output, context) => {
|
|
1277
2563
|
return {
|
|
1278
2564
|
AvailabilityZone: smithy_client_1.expectString(output.AvailabilityZone),
|
|
@@ -1300,11 +2586,31 @@ const deserializeAws_restJson1outpostListDefinition = (output, context) => {
|
|
|
1300
2586
|
return deserializeAws_restJson1Outpost(entry, context);
|
|
1301
2587
|
});
|
|
1302
2588
|
};
|
|
2589
|
+
const deserializeAws_restJson1RackPhysicalProperties = (output, context) => {
|
|
2590
|
+
return {
|
|
2591
|
+
FiberOpticCableType: smithy_client_1.expectString(output.FiberOpticCableType),
|
|
2592
|
+
MaximumSupportedWeightLbs: smithy_client_1.expectString(output.MaximumSupportedWeightLbs),
|
|
2593
|
+
OpticalStandard: smithy_client_1.expectString(output.OpticalStandard),
|
|
2594
|
+
PowerConnector: smithy_client_1.expectString(output.PowerConnector),
|
|
2595
|
+
PowerDrawKva: smithy_client_1.expectString(output.PowerDrawKva),
|
|
2596
|
+
PowerFeedDrop: smithy_client_1.expectString(output.PowerFeedDrop),
|
|
2597
|
+
PowerPhase: smithy_client_1.expectString(output.PowerPhase),
|
|
2598
|
+
UplinkCount: smithy_client_1.expectString(output.UplinkCount),
|
|
2599
|
+
UplinkGbps: smithy_client_1.expectString(output.UplinkGbps),
|
|
2600
|
+
};
|
|
2601
|
+
};
|
|
1303
2602
|
const deserializeAws_restJson1Site = (output, context) => {
|
|
1304
2603
|
return {
|
|
1305
2604
|
AccountId: smithy_client_1.expectString(output.AccountId),
|
|
1306
2605
|
Description: smithy_client_1.expectString(output.Description),
|
|
1307
2606
|
Name: smithy_client_1.expectString(output.Name),
|
|
2607
|
+
Notes: smithy_client_1.expectString(output.Notes),
|
|
2608
|
+
OperatingAddressCity: smithy_client_1.expectString(output.OperatingAddressCity),
|
|
2609
|
+
OperatingAddressCountryCode: smithy_client_1.expectString(output.OperatingAddressCountryCode),
|
|
2610
|
+
OperatingAddressStateOrRegion: smithy_client_1.expectString(output.OperatingAddressStateOrRegion),
|
|
2611
|
+
RackPhysicalProperties: output.RackPhysicalProperties !== undefined && output.RackPhysicalProperties !== null
|
|
2612
|
+
? deserializeAws_restJson1RackPhysicalProperties(output.RackPhysicalProperties, context)
|
|
2613
|
+
: undefined,
|
|
1308
2614
|
SiteArn: smithy_client_1.expectString(output.SiteArn),
|
|
1309
2615
|
SiteId: smithy_client_1.expectString(output.SiteId),
|
|
1310
2616
|
Tags: output.Tags !== undefined && output.Tags !== null
|
|
@@ -1322,6 +2628,26 @@ const deserializeAws_restJson1siteListDefinition = (output, context) => {
|
|
|
1322
2628
|
return deserializeAws_restJson1Site(entry, context);
|
|
1323
2629
|
});
|
|
1324
2630
|
};
|
|
2631
|
+
const deserializeAws_restJson1SupportedStorageList = (output, context) => {
|
|
2632
|
+
return (output || [])
|
|
2633
|
+
.filter((e) => e != null)
|
|
2634
|
+
.map((entry) => {
|
|
2635
|
+
if (entry === null) {
|
|
2636
|
+
return null;
|
|
2637
|
+
}
|
|
2638
|
+
return smithy_client_1.expectString(entry);
|
|
2639
|
+
});
|
|
2640
|
+
};
|
|
2641
|
+
const deserializeAws_restJson1SupportedUplinkGbpsListDefinition = (output, context) => {
|
|
2642
|
+
return (output || [])
|
|
2643
|
+
.filter((e) => e != null)
|
|
2644
|
+
.map((entry) => {
|
|
2645
|
+
if (entry === null) {
|
|
2646
|
+
return null;
|
|
2647
|
+
}
|
|
2648
|
+
return smithy_client_1.expectInt32(entry);
|
|
2649
|
+
});
|
|
2650
|
+
};
|
|
1325
2651
|
const deserializeAws_restJson1TagMap = (output, context) => {
|
|
1326
2652
|
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
1327
2653
|
if (value === null) {
|