@aws-sdk/client-rolesanywhere 3.185.0 → 3.188.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 +16 -0
- package/dist-es/RolesAnywhere.js +106 -113
- package/dist-es/RolesAnywhereClient.js +22 -28
- package/dist-es/commands/CreateProfileCommand.js +21 -28
- package/dist-es/commands/CreateTrustAnchorCommand.js +21 -28
- package/dist-es/commands/DeleteCrlCommand.js +21 -28
- package/dist-es/commands/DeleteProfileCommand.js +21 -28
- package/dist-es/commands/DeleteTrustAnchorCommand.js +21 -28
- package/dist-es/commands/DisableCrlCommand.js +21 -28
- package/dist-es/commands/DisableProfileCommand.js +21 -28
- package/dist-es/commands/DisableTrustAnchorCommand.js +21 -28
- package/dist-es/commands/EnableCrlCommand.js +21 -28
- package/dist-es/commands/EnableProfileCommand.js +21 -28
- package/dist-es/commands/EnableTrustAnchorCommand.js +21 -28
- package/dist-es/commands/GetCrlCommand.js +21 -28
- package/dist-es/commands/GetProfileCommand.js +21 -28
- package/dist-es/commands/GetSubjectCommand.js +21 -28
- package/dist-es/commands/GetTrustAnchorCommand.js +21 -28
- package/dist-es/commands/ImportCrlCommand.js +21 -28
- package/dist-es/commands/ListCrlsCommand.js +21 -28
- package/dist-es/commands/ListProfilesCommand.js +21 -28
- package/dist-es/commands/ListSubjectsCommand.js +21 -28
- package/dist-es/commands/ListTagsForResourceCommand.js +21 -28
- package/dist-es/commands/ListTrustAnchorsCommand.js +21 -28
- package/dist-es/commands/TagResourceCommand.js +21 -28
- package/dist-es/commands/UntagResourceCommand.js +21 -28
- package/dist-es/commands/UpdateCrlCommand.js +21 -28
- package/dist-es/commands/UpdateProfileCommand.js +21 -28
- package/dist-es/commands/UpdateTrustAnchorCommand.js +21 -28
- package/dist-es/endpoints.js +8 -8
- package/dist-es/models/RolesAnywhereServiceException.js +5 -10
- package/dist-es/models/models_0.js +163 -83
- package/dist-es/pagination/ListCrlsPaginator.js +24 -67
- package/dist-es/pagination/ListProfilesPaginator.js +24 -67
- package/dist-es/pagination/ListSubjectsPaginator.js +24 -67
- package/dist-es/pagination/ListTrustAnchorsPaginator.js +24 -67
- package/dist-es/protocols/Aws_restJson1.js +1558 -2315
- package/dist-es/runtimeConfig.browser.js +26 -12
- package/dist-es/runtimeConfig.js +30 -12
- package/dist-es/runtimeConfig.native.js +8 -5
- package/dist-es/runtimeConfig.shared.js +8 -11
- package/package.json +33 -33
|
@@ -1,2306 +1,1566 @@
|
|
|
1
|
-
import { __assign, __awaiter, __generator, __read } from "tslib";
|
|
2
1
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
2
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, expectUnion as __expectUnion, map as __map, parseRfc3339DateTime as __parseRfc3339DateTime, resolvedPath as __resolvedPath, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
4
3
|
import { AccessDeniedException, ResourceNotFoundException, SourceData, TooManyTagsException, ValidationException, } from "../models/models_0";
|
|
5
4
|
import { RolesAnywhereServiceException as __BaseException } from "../models/RolesAnywhereServiceException";
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
34
|
-
return __generator(this, function (_c) {
|
|
35
|
-
switch (_c.label) {
|
|
36
|
-
case 0: return [4, context.endpoint()];
|
|
37
|
-
case 1:
|
|
38
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
39
|
-
headers = {
|
|
40
|
-
"content-type": "application/json",
|
|
41
|
-
};
|
|
42
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchors";
|
|
43
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign({}, (input.enabled != null && { enabled: input.enabled })), (input.name != null && { name: input.name })), (input.source != null && { source: serializeAws_restJson1Source(input.source, context) })), (input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) })));
|
|
44
|
-
return [2, new __HttpRequest({
|
|
45
|
-
protocol: protocol,
|
|
46
|
-
hostname: hostname,
|
|
47
|
-
port: port,
|
|
48
|
-
method: "POST",
|
|
49
|
-
headers: headers,
|
|
50
|
-
path: resolvedPath,
|
|
51
|
-
body: body,
|
|
52
|
-
})];
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
}); };
|
|
56
|
-
export var serializeAws_restJson1DeleteCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
57
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
58
|
-
return __generator(this, function (_c) {
|
|
59
|
-
switch (_c.label) {
|
|
60
|
-
case 0: return [4, context.endpoint()];
|
|
61
|
-
case 1:
|
|
62
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
63
|
-
headers = {};
|
|
64
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crl/{crlId}";
|
|
65
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", function () { return input.crlId; }, "{crlId}", false);
|
|
66
|
-
return [2, new __HttpRequest({
|
|
67
|
-
protocol: protocol,
|
|
68
|
-
hostname: hostname,
|
|
69
|
-
port: port,
|
|
70
|
-
method: "DELETE",
|
|
71
|
-
headers: headers,
|
|
72
|
-
path: resolvedPath,
|
|
73
|
-
body: body,
|
|
74
|
-
})];
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
}); };
|
|
78
|
-
export var serializeAws_restJson1DeleteProfileCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
79
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
80
|
-
return __generator(this, function (_c) {
|
|
81
|
-
switch (_c.label) {
|
|
82
|
-
case 0: return [4, context.endpoint()];
|
|
83
|
-
case 1:
|
|
84
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
85
|
-
headers = {};
|
|
86
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/profile/{profileId}";
|
|
87
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", function () { return input.profileId; }, "{profileId}", false);
|
|
88
|
-
return [2, new __HttpRequest({
|
|
89
|
-
protocol: protocol,
|
|
90
|
-
hostname: hostname,
|
|
91
|
-
port: port,
|
|
92
|
-
method: "DELETE",
|
|
93
|
-
headers: headers,
|
|
94
|
-
path: resolvedPath,
|
|
95
|
-
body: body,
|
|
96
|
-
})];
|
|
97
|
-
}
|
|
98
|
-
});
|
|
99
|
-
}); };
|
|
100
|
-
export var serializeAws_restJson1DeleteTrustAnchorCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
101
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
102
|
-
return __generator(this, function (_c) {
|
|
103
|
-
switch (_c.label) {
|
|
104
|
-
case 0: return [4, context.endpoint()];
|
|
105
|
-
case 1:
|
|
106
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
107
|
-
headers = {};
|
|
108
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchor/{trustAnchorId}";
|
|
109
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", function () { return input.trustAnchorId; }, "{trustAnchorId}", false);
|
|
110
|
-
return [2, new __HttpRequest({
|
|
111
|
-
protocol: protocol,
|
|
112
|
-
hostname: hostname,
|
|
113
|
-
port: port,
|
|
114
|
-
method: "DELETE",
|
|
115
|
-
headers: headers,
|
|
116
|
-
path: resolvedPath,
|
|
117
|
-
body: body,
|
|
118
|
-
})];
|
|
119
|
-
}
|
|
120
|
-
});
|
|
121
|
-
}); };
|
|
122
|
-
export var serializeAws_restJson1DisableCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
123
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
124
|
-
return __generator(this, function (_c) {
|
|
125
|
-
switch (_c.label) {
|
|
126
|
-
case 0: return [4, context.endpoint()];
|
|
127
|
-
case 1:
|
|
128
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
129
|
-
headers = {};
|
|
130
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crl/{crlId}/disable";
|
|
131
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", function () { return input.crlId; }, "{crlId}", false);
|
|
132
|
-
return [2, new __HttpRequest({
|
|
133
|
-
protocol: protocol,
|
|
134
|
-
hostname: hostname,
|
|
135
|
-
port: port,
|
|
136
|
-
method: "POST",
|
|
137
|
-
headers: headers,
|
|
138
|
-
path: resolvedPath,
|
|
139
|
-
body: body,
|
|
140
|
-
})];
|
|
141
|
-
}
|
|
142
|
-
});
|
|
143
|
-
}); };
|
|
144
|
-
export var serializeAws_restJson1DisableProfileCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
145
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
146
|
-
return __generator(this, function (_c) {
|
|
147
|
-
switch (_c.label) {
|
|
148
|
-
case 0: return [4, context.endpoint()];
|
|
149
|
-
case 1:
|
|
150
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
151
|
-
headers = {};
|
|
152
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/profile/{profileId}/disable";
|
|
153
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", function () { return input.profileId; }, "{profileId}", false);
|
|
154
|
-
return [2, new __HttpRequest({
|
|
155
|
-
protocol: protocol,
|
|
156
|
-
hostname: hostname,
|
|
157
|
-
port: port,
|
|
158
|
-
method: "POST",
|
|
159
|
-
headers: headers,
|
|
160
|
-
path: resolvedPath,
|
|
161
|
-
body: body,
|
|
162
|
-
})];
|
|
163
|
-
}
|
|
164
|
-
});
|
|
165
|
-
}); };
|
|
166
|
-
export var serializeAws_restJson1DisableTrustAnchorCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
167
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
168
|
-
return __generator(this, function (_c) {
|
|
169
|
-
switch (_c.label) {
|
|
170
|
-
case 0: return [4, context.endpoint()];
|
|
171
|
-
case 1:
|
|
172
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
173
|
-
headers = {};
|
|
174
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchor/{trustAnchorId}/disable";
|
|
175
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", function () { return input.trustAnchorId; }, "{trustAnchorId}", false);
|
|
176
|
-
return [2, new __HttpRequest({
|
|
177
|
-
protocol: protocol,
|
|
178
|
-
hostname: hostname,
|
|
179
|
-
port: port,
|
|
180
|
-
method: "POST",
|
|
181
|
-
headers: headers,
|
|
182
|
-
path: resolvedPath,
|
|
183
|
-
body: body,
|
|
184
|
-
})];
|
|
185
|
-
}
|
|
186
|
-
});
|
|
187
|
-
}); };
|
|
188
|
-
export var serializeAws_restJson1EnableCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
189
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
190
|
-
return __generator(this, function (_c) {
|
|
191
|
-
switch (_c.label) {
|
|
192
|
-
case 0: return [4, context.endpoint()];
|
|
193
|
-
case 1:
|
|
194
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
195
|
-
headers = {};
|
|
196
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crl/{crlId}/enable";
|
|
197
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", function () { return input.crlId; }, "{crlId}", false);
|
|
198
|
-
return [2, new __HttpRequest({
|
|
199
|
-
protocol: protocol,
|
|
200
|
-
hostname: hostname,
|
|
201
|
-
port: port,
|
|
202
|
-
method: "POST",
|
|
203
|
-
headers: headers,
|
|
204
|
-
path: resolvedPath,
|
|
205
|
-
body: body,
|
|
206
|
-
})];
|
|
207
|
-
}
|
|
208
|
-
});
|
|
209
|
-
}); };
|
|
210
|
-
export var serializeAws_restJson1EnableProfileCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
211
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
212
|
-
return __generator(this, function (_c) {
|
|
213
|
-
switch (_c.label) {
|
|
214
|
-
case 0: return [4, context.endpoint()];
|
|
215
|
-
case 1:
|
|
216
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
217
|
-
headers = {};
|
|
218
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/profile/{profileId}/enable";
|
|
219
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", function () { return input.profileId; }, "{profileId}", false);
|
|
220
|
-
return [2, new __HttpRequest({
|
|
221
|
-
protocol: protocol,
|
|
222
|
-
hostname: hostname,
|
|
223
|
-
port: port,
|
|
224
|
-
method: "POST",
|
|
225
|
-
headers: headers,
|
|
226
|
-
path: resolvedPath,
|
|
227
|
-
body: body,
|
|
228
|
-
})];
|
|
229
|
-
}
|
|
230
|
-
});
|
|
231
|
-
}); };
|
|
232
|
-
export var serializeAws_restJson1EnableTrustAnchorCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
233
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
234
|
-
return __generator(this, function (_c) {
|
|
235
|
-
switch (_c.label) {
|
|
236
|
-
case 0: return [4, context.endpoint()];
|
|
237
|
-
case 1:
|
|
238
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
239
|
-
headers = {};
|
|
240
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchor/{trustAnchorId}/enable";
|
|
241
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", function () { return input.trustAnchorId; }, "{trustAnchorId}", false);
|
|
242
|
-
return [2, new __HttpRequest({
|
|
243
|
-
protocol: protocol,
|
|
244
|
-
hostname: hostname,
|
|
245
|
-
port: port,
|
|
246
|
-
method: "POST",
|
|
247
|
-
headers: headers,
|
|
248
|
-
path: resolvedPath,
|
|
249
|
-
body: body,
|
|
250
|
-
})];
|
|
251
|
-
}
|
|
252
|
-
});
|
|
253
|
-
}); };
|
|
254
|
-
export var serializeAws_restJson1GetCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
255
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
256
|
-
return __generator(this, function (_c) {
|
|
257
|
-
switch (_c.label) {
|
|
258
|
-
case 0: return [4, context.endpoint()];
|
|
259
|
-
case 1:
|
|
260
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
261
|
-
headers = {};
|
|
262
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crl/{crlId}";
|
|
263
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", function () { return input.crlId; }, "{crlId}", false);
|
|
264
|
-
return [2, new __HttpRequest({
|
|
265
|
-
protocol: protocol,
|
|
266
|
-
hostname: hostname,
|
|
267
|
-
port: port,
|
|
268
|
-
method: "GET",
|
|
269
|
-
headers: headers,
|
|
270
|
-
path: resolvedPath,
|
|
271
|
-
body: body,
|
|
272
|
-
})];
|
|
273
|
-
}
|
|
274
|
-
});
|
|
275
|
-
}); };
|
|
276
|
-
export var serializeAws_restJson1GetProfileCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
277
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
278
|
-
return __generator(this, function (_c) {
|
|
279
|
-
switch (_c.label) {
|
|
280
|
-
case 0: return [4, context.endpoint()];
|
|
281
|
-
case 1:
|
|
282
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
283
|
-
headers = {};
|
|
284
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/profile/{profileId}";
|
|
285
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", function () { return input.profileId; }, "{profileId}", false);
|
|
286
|
-
return [2, new __HttpRequest({
|
|
287
|
-
protocol: protocol,
|
|
288
|
-
hostname: hostname,
|
|
289
|
-
port: port,
|
|
290
|
-
method: "GET",
|
|
291
|
-
headers: headers,
|
|
292
|
-
path: resolvedPath,
|
|
293
|
-
body: body,
|
|
294
|
-
})];
|
|
295
|
-
}
|
|
296
|
-
});
|
|
297
|
-
}); };
|
|
298
|
-
export var serializeAws_restJson1GetSubjectCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
299
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
300
|
-
return __generator(this, function (_c) {
|
|
301
|
-
switch (_c.label) {
|
|
302
|
-
case 0: return [4, context.endpoint()];
|
|
303
|
-
case 1:
|
|
304
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
305
|
-
headers = {};
|
|
306
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/subject/{subjectId}";
|
|
307
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "subjectId", function () { return input.subjectId; }, "{subjectId}", false);
|
|
308
|
-
return [2, new __HttpRequest({
|
|
309
|
-
protocol: protocol,
|
|
310
|
-
hostname: hostname,
|
|
311
|
-
port: port,
|
|
312
|
-
method: "GET",
|
|
313
|
-
headers: headers,
|
|
314
|
-
path: resolvedPath,
|
|
315
|
-
body: body,
|
|
316
|
-
})];
|
|
317
|
-
}
|
|
318
|
-
});
|
|
319
|
-
}); };
|
|
320
|
-
export var serializeAws_restJson1GetTrustAnchorCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
321
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
322
|
-
return __generator(this, function (_c) {
|
|
323
|
-
switch (_c.label) {
|
|
324
|
-
case 0: return [4, context.endpoint()];
|
|
325
|
-
case 1:
|
|
326
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
327
|
-
headers = {};
|
|
328
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchor/{trustAnchorId}";
|
|
329
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", function () { return input.trustAnchorId; }, "{trustAnchorId}", false);
|
|
330
|
-
return [2, new __HttpRequest({
|
|
331
|
-
protocol: protocol,
|
|
332
|
-
hostname: hostname,
|
|
333
|
-
port: port,
|
|
334
|
-
method: "GET",
|
|
335
|
-
headers: headers,
|
|
336
|
-
path: resolvedPath,
|
|
337
|
-
body: body,
|
|
338
|
-
})];
|
|
339
|
-
}
|
|
340
|
-
});
|
|
341
|
-
}); };
|
|
342
|
-
export var serializeAws_restJson1ImportCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
343
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
344
|
-
return __generator(this, function (_c) {
|
|
345
|
-
switch (_c.label) {
|
|
346
|
-
case 0: return [4, context.endpoint()];
|
|
347
|
-
case 1:
|
|
348
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
349
|
-
headers = {
|
|
350
|
-
"content-type": "application/json",
|
|
351
|
-
};
|
|
352
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crls";
|
|
353
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign({}, (input.crlData != null && { crlData: context.base64Encoder(input.crlData) })), (input.enabled != null && { enabled: input.enabled })), (input.name != null && { name: input.name })), (input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) })), (input.trustAnchorArn != null && { trustAnchorArn: input.trustAnchorArn })));
|
|
354
|
-
return [2, new __HttpRequest({
|
|
355
|
-
protocol: protocol,
|
|
356
|
-
hostname: hostname,
|
|
357
|
-
port: port,
|
|
358
|
-
method: "POST",
|
|
359
|
-
headers: headers,
|
|
360
|
-
path: resolvedPath,
|
|
361
|
-
body: body,
|
|
362
|
-
})];
|
|
363
|
-
}
|
|
364
|
-
});
|
|
365
|
-
}); };
|
|
366
|
-
export var serializeAws_restJson1ListCrlsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
367
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
368
|
-
return __generator(this, function (_c) {
|
|
369
|
-
switch (_c.label) {
|
|
370
|
-
case 0: return [4, context.endpoint()];
|
|
371
|
-
case 1:
|
|
372
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
373
|
-
headers = {};
|
|
374
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crls";
|
|
375
|
-
query = map({
|
|
376
|
-
nextToken: [, input.nextToken],
|
|
377
|
-
pageSize: [function () { return input.pageSize !== void 0; }, function () { return input.pageSize.toString(); }],
|
|
378
|
-
});
|
|
379
|
-
return [2, new __HttpRequest({
|
|
380
|
-
protocol: protocol,
|
|
381
|
-
hostname: hostname,
|
|
382
|
-
port: port,
|
|
383
|
-
method: "GET",
|
|
384
|
-
headers: headers,
|
|
385
|
-
path: resolvedPath,
|
|
386
|
-
query: query,
|
|
387
|
-
body: body,
|
|
388
|
-
})];
|
|
389
|
-
}
|
|
390
|
-
});
|
|
391
|
-
}); };
|
|
392
|
-
export var serializeAws_restJson1ListProfilesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
393
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
394
|
-
return __generator(this, function (_c) {
|
|
395
|
-
switch (_c.label) {
|
|
396
|
-
case 0: return [4, context.endpoint()];
|
|
397
|
-
case 1:
|
|
398
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
399
|
-
headers = {};
|
|
400
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/profiles";
|
|
401
|
-
query = map({
|
|
402
|
-
nextToken: [, input.nextToken],
|
|
403
|
-
pageSize: [function () { return input.pageSize !== void 0; }, function () { return input.pageSize.toString(); }],
|
|
404
|
-
});
|
|
405
|
-
return [2, new __HttpRequest({
|
|
406
|
-
protocol: protocol,
|
|
407
|
-
hostname: hostname,
|
|
408
|
-
port: port,
|
|
409
|
-
method: "GET",
|
|
410
|
-
headers: headers,
|
|
411
|
-
path: resolvedPath,
|
|
412
|
-
query: query,
|
|
413
|
-
body: body,
|
|
414
|
-
})];
|
|
415
|
-
}
|
|
416
|
-
});
|
|
417
|
-
}); };
|
|
418
|
-
export var serializeAws_restJson1ListSubjectsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
419
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
420
|
-
return __generator(this, function (_c) {
|
|
421
|
-
switch (_c.label) {
|
|
422
|
-
case 0: return [4, context.endpoint()];
|
|
423
|
-
case 1:
|
|
424
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
425
|
-
headers = {};
|
|
426
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/subjects";
|
|
427
|
-
query = map({
|
|
428
|
-
nextToken: [, input.nextToken],
|
|
429
|
-
pageSize: [function () { return input.pageSize !== void 0; }, function () { return input.pageSize.toString(); }],
|
|
430
|
-
});
|
|
431
|
-
return [2, new __HttpRequest({
|
|
432
|
-
protocol: protocol,
|
|
433
|
-
hostname: hostname,
|
|
434
|
-
port: port,
|
|
435
|
-
method: "GET",
|
|
436
|
-
headers: headers,
|
|
437
|
-
path: resolvedPath,
|
|
438
|
-
query: query,
|
|
439
|
-
body: body,
|
|
440
|
-
})];
|
|
441
|
-
}
|
|
442
|
-
});
|
|
443
|
-
}); };
|
|
444
|
-
export var serializeAws_restJson1ListTagsForResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
445
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
446
|
-
return __generator(this, function (_c) {
|
|
447
|
-
switch (_c.label) {
|
|
448
|
-
case 0: return [4, context.endpoint()];
|
|
449
|
-
case 1:
|
|
450
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
451
|
-
headers = {};
|
|
452
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/ListTagsForResource";
|
|
453
|
-
query = map({
|
|
454
|
-
resourceArn: [, input.resourceArn],
|
|
455
|
-
});
|
|
456
|
-
return [2, new __HttpRequest({
|
|
457
|
-
protocol: protocol,
|
|
458
|
-
hostname: hostname,
|
|
459
|
-
port: port,
|
|
460
|
-
method: "GET",
|
|
461
|
-
headers: headers,
|
|
462
|
-
path: resolvedPath,
|
|
463
|
-
query: query,
|
|
464
|
-
body: body,
|
|
465
|
-
})];
|
|
466
|
-
}
|
|
467
|
-
});
|
|
468
|
-
}); };
|
|
469
|
-
export var serializeAws_restJson1ListTrustAnchorsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
470
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, query, body;
|
|
471
|
-
return __generator(this, function (_c) {
|
|
472
|
-
switch (_c.label) {
|
|
473
|
-
case 0: return [4, context.endpoint()];
|
|
474
|
-
case 1:
|
|
475
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
476
|
-
headers = {};
|
|
477
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/trustanchors";
|
|
478
|
-
query = map({
|
|
479
|
-
nextToken: [, input.nextToken],
|
|
480
|
-
pageSize: [function () { return input.pageSize !== void 0; }, function () { return input.pageSize.toString(); }],
|
|
481
|
-
});
|
|
482
|
-
return [2, new __HttpRequest({
|
|
483
|
-
protocol: protocol,
|
|
484
|
-
hostname: hostname,
|
|
485
|
-
port: port,
|
|
486
|
-
method: "GET",
|
|
487
|
-
headers: headers,
|
|
488
|
-
path: resolvedPath,
|
|
489
|
-
query: query,
|
|
490
|
-
body: body,
|
|
491
|
-
})];
|
|
492
|
-
}
|
|
493
|
-
});
|
|
494
|
-
}); };
|
|
495
|
-
export var serializeAws_restJson1TagResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
496
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
497
|
-
return __generator(this, function (_c) {
|
|
498
|
-
switch (_c.label) {
|
|
499
|
-
case 0: return [4, context.endpoint()];
|
|
500
|
-
case 1:
|
|
501
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
502
|
-
headers = {
|
|
503
|
-
"content-type": "application/json",
|
|
504
|
-
};
|
|
505
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/TagResource";
|
|
506
|
-
body = JSON.stringify(__assign(__assign({}, (input.resourceArn != null && { resourceArn: input.resourceArn })), (input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) })));
|
|
507
|
-
return [2, new __HttpRequest({
|
|
508
|
-
protocol: protocol,
|
|
509
|
-
hostname: hostname,
|
|
510
|
-
port: port,
|
|
511
|
-
method: "POST",
|
|
512
|
-
headers: headers,
|
|
513
|
-
path: resolvedPath,
|
|
514
|
-
body: body,
|
|
515
|
-
})];
|
|
516
|
-
}
|
|
517
|
-
});
|
|
518
|
-
}); };
|
|
519
|
-
export var serializeAws_restJson1UntagResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
520
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
521
|
-
return __generator(this, function (_c) {
|
|
522
|
-
switch (_c.label) {
|
|
523
|
-
case 0: return [4, context.endpoint()];
|
|
524
|
-
case 1:
|
|
525
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
526
|
-
headers = {
|
|
527
|
-
"content-type": "application/json",
|
|
528
|
-
};
|
|
529
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/UntagResource";
|
|
530
|
-
body = JSON.stringify(__assign(__assign({}, (input.resourceArn != null && { resourceArn: input.resourceArn })), (input.tagKeys != null && { tagKeys: serializeAws_restJson1TagKeyList(input.tagKeys, context) })));
|
|
531
|
-
return [2, new __HttpRequest({
|
|
532
|
-
protocol: protocol,
|
|
533
|
-
hostname: hostname,
|
|
534
|
-
port: port,
|
|
535
|
-
method: "POST",
|
|
536
|
-
headers: headers,
|
|
537
|
-
path: resolvedPath,
|
|
538
|
-
body: body,
|
|
539
|
-
})];
|
|
540
|
-
}
|
|
541
|
-
});
|
|
542
|
-
}); };
|
|
543
|
-
export var serializeAws_restJson1UpdateCrlCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
544
|
-
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
545
|
-
return __generator(this, function (_c) {
|
|
546
|
-
switch (_c.label) {
|
|
547
|
-
case 0: return [4, context.endpoint()];
|
|
548
|
-
case 1:
|
|
549
|
-
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
550
|
-
headers = {
|
|
551
|
-
"content-type": "application/json",
|
|
552
|
-
};
|
|
553
|
-
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/crl/{crlId}";
|
|
554
|
-
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", function () { return input.crlId; }, "{crlId}", false);
|
|
555
|
-
body = JSON.stringify(__assign(__assign({}, (input.crlData != null && { crlData: context.base64Encoder(input.crlData) })), (input.name != null && { name: input.name })));
|
|
556
|
-
return [2, new __HttpRequest({
|
|
557
|
-
protocol: protocol,
|
|
558
|
-
hostname: hostname,
|
|
559
|
-
port: port,
|
|
560
|
-
method: "PATCH",
|
|
561
|
-
headers: headers,
|
|
562
|
-
path: resolvedPath,
|
|
563
|
-
body: body,
|
|
564
|
-
})];
|
|
565
|
-
}
|
|
5
|
+
export const serializeAws_restJson1CreateProfileCommand = async (input, context) => {
|
|
6
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
7
|
+
const headers = {
|
|
8
|
+
"content-type": "application/json",
|
|
9
|
+
};
|
|
10
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles";
|
|
11
|
+
let body;
|
|
12
|
+
body = JSON.stringify({
|
|
13
|
+
...(input.durationSeconds != null && { durationSeconds: input.durationSeconds }),
|
|
14
|
+
...(input.enabled != null && { enabled: input.enabled }),
|
|
15
|
+
...(input.managedPolicyArns != null && {
|
|
16
|
+
managedPolicyArns: serializeAws_restJson1ManagedPolicyList(input.managedPolicyArns, context),
|
|
17
|
+
}),
|
|
18
|
+
...(input.name != null && { name: input.name }),
|
|
19
|
+
...(input.requireInstanceProperties != null && { requireInstanceProperties: input.requireInstanceProperties }),
|
|
20
|
+
...(input.roleArns != null && { roleArns: serializeAws_restJson1RoleArnList(input.roleArns, context) }),
|
|
21
|
+
...(input.sessionPolicy != null && { sessionPolicy: input.sessionPolicy }),
|
|
22
|
+
...(input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) }),
|
|
23
|
+
});
|
|
24
|
+
return new __HttpRequest({
|
|
25
|
+
protocol,
|
|
26
|
+
hostname,
|
|
27
|
+
port,
|
|
28
|
+
method: "POST",
|
|
29
|
+
headers,
|
|
30
|
+
path: resolvedPath,
|
|
31
|
+
body,
|
|
566
32
|
});
|
|
567
|
-
}
|
|
568
|
-
export
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
path: resolvedPath,
|
|
590
|
-
body: body,
|
|
591
|
-
})];
|
|
592
|
-
}
|
|
33
|
+
};
|
|
34
|
+
export const serializeAws_restJson1CreateTrustAnchorCommand = async (input, context) => {
|
|
35
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
36
|
+
const headers = {
|
|
37
|
+
"content-type": "application/json",
|
|
38
|
+
};
|
|
39
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchors";
|
|
40
|
+
let body;
|
|
41
|
+
body = JSON.stringify({
|
|
42
|
+
...(input.enabled != null && { enabled: input.enabled }),
|
|
43
|
+
...(input.name != null && { name: input.name }),
|
|
44
|
+
...(input.source != null && { source: serializeAws_restJson1Source(input.source, context) }),
|
|
45
|
+
...(input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) }),
|
|
46
|
+
});
|
|
47
|
+
return new __HttpRequest({
|
|
48
|
+
protocol,
|
|
49
|
+
hostname,
|
|
50
|
+
port,
|
|
51
|
+
method: "POST",
|
|
52
|
+
headers,
|
|
53
|
+
path: resolvedPath,
|
|
54
|
+
body,
|
|
593
55
|
});
|
|
594
|
-
}
|
|
595
|
-
export
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
protocol: protocol,
|
|
610
|
-
hostname: hostname,
|
|
611
|
-
port: port,
|
|
612
|
-
method: "PATCH",
|
|
613
|
-
headers: headers,
|
|
614
|
-
path: resolvedPath,
|
|
615
|
-
body: body,
|
|
616
|
-
})];
|
|
617
|
-
}
|
|
56
|
+
};
|
|
57
|
+
export const serializeAws_restJson1DeleteCrlCommand = async (input, context) => {
|
|
58
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
59
|
+
const headers = {};
|
|
60
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crl/{crlId}";
|
|
61
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", () => input.crlId, "{crlId}", false);
|
|
62
|
+
let body;
|
|
63
|
+
return new __HttpRequest({
|
|
64
|
+
protocol,
|
|
65
|
+
hostname,
|
|
66
|
+
port,
|
|
67
|
+
method: "DELETE",
|
|
68
|
+
headers,
|
|
69
|
+
path: resolvedPath,
|
|
70
|
+
body,
|
|
618
71
|
});
|
|
619
|
-
}
|
|
620
|
-
export
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
case 1:
|
|
635
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
636
|
-
if (data.profile != null) {
|
|
637
|
-
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
638
|
-
}
|
|
639
|
-
return [2, contents];
|
|
640
|
-
}
|
|
72
|
+
};
|
|
73
|
+
export const serializeAws_restJson1DeleteProfileCommand = async (input, context) => {
|
|
74
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
75
|
+
const headers = {};
|
|
76
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profile/{profileId}";
|
|
77
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", () => input.profileId, "{profileId}", false);
|
|
78
|
+
let body;
|
|
79
|
+
return new __HttpRequest({
|
|
80
|
+
protocol,
|
|
81
|
+
hostname,
|
|
82
|
+
port,
|
|
83
|
+
method: "DELETE",
|
|
84
|
+
headers,
|
|
85
|
+
path: resolvedPath,
|
|
86
|
+
body,
|
|
641
87
|
});
|
|
642
|
-
}
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
case "AccessDeniedException": return [3, 2];
|
|
658
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
659
|
-
case "ValidationException": return [3, 4];
|
|
660
|
-
case "com.amazonaws.rolesanywhere#ValidationException": return [3, 4];
|
|
661
|
-
}
|
|
662
|
-
return [3, 6];
|
|
663
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
664
|
-
case 3: throw _d.sent();
|
|
665
|
-
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
666
|
-
case 5: throw _d.sent();
|
|
667
|
-
case 6:
|
|
668
|
-
parsedBody = parsedOutput.body;
|
|
669
|
-
throwDefaultError({
|
|
670
|
-
output: output,
|
|
671
|
-
parsedBody: parsedBody,
|
|
672
|
-
exceptionCtor: __BaseException,
|
|
673
|
-
errorCode: errorCode,
|
|
674
|
-
});
|
|
675
|
-
_d.label = 7;
|
|
676
|
-
case 7: return [2];
|
|
677
|
-
}
|
|
88
|
+
};
|
|
89
|
+
export const serializeAws_restJson1DeleteTrustAnchorCommand = async (input, context) => {
|
|
90
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
91
|
+
const headers = {};
|
|
92
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchor/{trustAnchorId}";
|
|
93
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", () => input.trustAnchorId, "{trustAnchorId}", false);
|
|
94
|
+
let body;
|
|
95
|
+
return new __HttpRequest({
|
|
96
|
+
protocol,
|
|
97
|
+
hostname,
|
|
98
|
+
port,
|
|
99
|
+
method: "DELETE",
|
|
100
|
+
headers,
|
|
101
|
+
path: resolvedPath,
|
|
102
|
+
body,
|
|
678
103
|
});
|
|
679
|
-
}
|
|
680
|
-
export
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
case 1:
|
|
695
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
696
|
-
if (data.trustAnchor != null) {
|
|
697
|
-
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
698
|
-
}
|
|
699
|
-
return [2, contents];
|
|
700
|
-
}
|
|
104
|
+
};
|
|
105
|
+
export const serializeAws_restJson1DisableCrlCommand = async (input, context) => {
|
|
106
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
107
|
+
const headers = {};
|
|
108
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crl/{crlId}/disable";
|
|
109
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", () => input.crlId, "{crlId}", false);
|
|
110
|
+
let body;
|
|
111
|
+
return new __HttpRequest({
|
|
112
|
+
protocol,
|
|
113
|
+
hostname,
|
|
114
|
+
port,
|
|
115
|
+
method: "POST",
|
|
116
|
+
headers,
|
|
117
|
+
path: resolvedPath,
|
|
118
|
+
body,
|
|
701
119
|
});
|
|
702
|
-
}
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
case "AccessDeniedException": return [3, 2];
|
|
718
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
719
|
-
case "ValidationException": return [3, 4];
|
|
720
|
-
case "com.amazonaws.rolesanywhere#ValidationException": return [3, 4];
|
|
721
|
-
}
|
|
722
|
-
return [3, 6];
|
|
723
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
724
|
-
case 3: throw _d.sent();
|
|
725
|
-
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
726
|
-
case 5: throw _d.sent();
|
|
727
|
-
case 6:
|
|
728
|
-
parsedBody = parsedOutput.body;
|
|
729
|
-
throwDefaultError({
|
|
730
|
-
output: output,
|
|
731
|
-
parsedBody: parsedBody,
|
|
732
|
-
exceptionCtor: __BaseException,
|
|
733
|
-
errorCode: errorCode,
|
|
734
|
-
});
|
|
735
|
-
_d.label = 7;
|
|
736
|
-
case 7: return [2];
|
|
737
|
-
}
|
|
120
|
+
};
|
|
121
|
+
export const serializeAws_restJson1DisableProfileCommand = async (input, context) => {
|
|
122
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
123
|
+
const headers = {};
|
|
124
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profile/{profileId}/disable";
|
|
125
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", () => input.profileId, "{profileId}", false);
|
|
126
|
+
let body;
|
|
127
|
+
return new __HttpRequest({
|
|
128
|
+
protocol,
|
|
129
|
+
hostname,
|
|
130
|
+
port,
|
|
131
|
+
method: "POST",
|
|
132
|
+
headers,
|
|
133
|
+
path: resolvedPath,
|
|
134
|
+
body,
|
|
738
135
|
});
|
|
739
|
-
}
|
|
740
|
-
export
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
case 1:
|
|
755
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
756
|
-
if (data.crl != null) {
|
|
757
|
-
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
758
|
-
}
|
|
759
|
-
return [2, contents];
|
|
760
|
-
}
|
|
136
|
+
};
|
|
137
|
+
export const serializeAws_restJson1DisableTrustAnchorCommand = async (input, context) => {
|
|
138
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
139
|
+
const headers = {};
|
|
140
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchor/{trustAnchorId}/disable";
|
|
141
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", () => input.trustAnchorId, "{trustAnchorId}", false);
|
|
142
|
+
let body;
|
|
143
|
+
return new __HttpRequest({
|
|
144
|
+
protocol,
|
|
145
|
+
hostname,
|
|
146
|
+
port,
|
|
147
|
+
method: "POST",
|
|
148
|
+
headers,
|
|
149
|
+
path: resolvedPath,
|
|
150
|
+
body,
|
|
761
151
|
});
|
|
762
|
-
}
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
case "AccessDeniedException": return [3, 2];
|
|
778
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
779
|
-
case "ResourceNotFoundException": return [3, 4];
|
|
780
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 4];
|
|
781
|
-
}
|
|
782
|
-
return [3, 6];
|
|
783
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
784
|
-
case 3: throw _d.sent();
|
|
785
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
786
|
-
case 5: throw _d.sent();
|
|
787
|
-
case 6:
|
|
788
|
-
parsedBody = parsedOutput.body;
|
|
789
|
-
throwDefaultError({
|
|
790
|
-
output: output,
|
|
791
|
-
parsedBody: parsedBody,
|
|
792
|
-
exceptionCtor: __BaseException,
|
|
793
|
-
errorCode: errorCode,
|
|
794
|
-
});
|
|
795
|
-
_d.label = 7;
|
|
796
|
-
case 7: return [2];
|
|
797
|
-
}
|
|
152
|
+
};
|
|
153
|
+
export const serializeAws_restJson1EnableCrlCommand = async (input, context) => {
|
|
154
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
155
|
+
const headers = {};
|
|
156
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crl/{crlId}/enable";
|
|
157
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", () => input.crlId, "{crlId}", false);
|
|
158
|
+
let body;
|
|
159
|
+
return new __HttpRequest({
|
|
160
|
+
protocol,
|
|
161
|
+
hostname,
|
|
162
|
+
port,
|
|
163
|
+
method: "POST",
|
|
164
|
+
headers,
|
|
165
|
+
path: resolvedPath,
|
|
166
|
+
body,
|
|
798
167
|
});
|
|
799
|
-
}
|
|
800
|
-
export
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
case 1:
|
|
815
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
816
|
-
if (data.profile != null) {
|
|
817
|
-
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
818
|
-
}
|
|
819
|
-
return [2, contents];
|
|
820
|
-
}
|
|
168
|
+
};
|
|
169
|
+
export const serializeAws_restJson1EnableProfileCommand = async (input, context) => {
|
|
170
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
171
|
+
const headers = {};
|
|
172
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profile/{profileId}/enable";
|
|
173
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", () => input.profileId, "{profileId}", false);
|
|
174
|
+
let body;
|
|
175
|
+
return new __HttpRequest({
|
|
176
|
+
protocol,
|
|
177
|
+
hostname,
|
|
178
|
+
port,
|
|
179
|
+
method: "POST",
|
|
180
|
+
headers,
|
|
181
|
+
path: resolvedPath,
|
|
182
|
+
body,
|
|
821
183
|
});
|
|
822
|
-
}
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
case "AccessDeniedException": return [3, 2];
|
|
838
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
839
|
-
case "ResourceNotFoundException": return [3, 4];
|
|
840
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 4];
|
|
841
|
-
}
|
|
842
|
-
return [3, 6];
|
|
843
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
844
|
-
case 3: throw _d.sent();
|
|
845
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
846
|
-
case 5: throw _d.sent();
|
|
847
|
-
case 6:
|
|
848
|
-
parsedBody = parsedOutput.body;
|
|
849
|
-
throwDefaultError({
|
|
850
|
-
output: output,
|
|
851
|
-
parsedBody: parsedBody,
|
|
852
|
-
exceptionCtor: __BaseException,
|
|
853
|
-
errorCode: errorCode,
|
|
854
|
-
});
|
|
855
|
-
_d.label = 7;
|
|
856
|
-
case 7: return [2];
|
|
857
|
-
}
|
|
184
|
+
};
|
|
185
|
+
export const serializeAws_restJson1EnableTrustAnchorCommand = async (input, context) => {
|
|
186
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
187
|
+
const headers = {};
|
|
188
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchor/{trustAnchorId}/enable";
|
|
189
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", () => input.trustAnchorId, "{trustAnchorId}", false);
|
|
190
|
+
let body;
|
|
191
|
+
return new __HttpRequest({
|
|
192
|
+
protocol,
|
|
193
|
+
hostname,
|
|
194
|
+
port,
|
|
195
|
+
method: "POST",
|
|
196
|
+
headers,
|
|
197
|
+
path: resolvedPath,
|
|
198
|
+
body,
|
|
858
199
|
});
|
|
859
|
-
}
|
|
860
|
-
export
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
case 1:
|
|
875
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
876
|
-
if (data.trustAnchor != null) {
|
|
877
|
-
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
878
|
-
}
|
|
879
|
-
return [2, contents];
|
|
880
|
-
}
|
|
200
|
+
};
|
|
201
|
+
export const serializeAws_restJson1GetCrlCommand = async (input, context) => {
|
|
202
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
203
|
+
const headers = {};
|
|
204
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crl/{crlId}";
|
|
205
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", () => input.crlId, "{crlId}", false);
|
|
206
|
+
let body;
|
|
207
|
+
return new __HttpRequest({
|
|
208
|
+
protocol,
|
|
209
|
+
hostname,
|
|
210
|
+
port,
|
|
211
|
+
method: "GET",
|
|
212
|
+
headers,
|
|
213
|
+
path: resolvedPath,
|
|
214
|
+
body,
|
|
881
215
|
});
|
|
882
|
-
}
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
case "AccessDeniedException": return [3, 2];
|
|
898
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
899
|
-
case "ResourceNotFoundException": return [3, 4];
|
|
900
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 4];
|
|
901
|
-
}
|
|
902
|
-
return [3, 6];
|
|
903
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
904
|
-
case 3: throw _d.sent();
|
|
905
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
906
|
-
case 5: throw _d.sent();
|
|
907
|
-
case 6:
|
|
908
|
-
parsedBody = parsedOutput.body;
|
|
909
|
-
throwDefaultError({
|
|
910
|
-
output: output,
|
|
911
|
-
parsedBody: parsedBody,
|
|
912
|
-
exceptionCtor: __BaseException,
|
|
913
|
-
errorCode: errorCode,
|
|
914
|
-
});
|
|
915
|
-
_d.label = 7;
|
|
916
|
-
case 7: return [2];
|
|
917
|
-
}
|
|
216
|
+
};
|
|
217
|
+
export const serializeAws_restJson1GetProfileCommand = async (input, context) => {
|
|
218
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
219
|
+
const headers = {};
|
|
220
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profile/{profileId}";
|
|
221
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", () => input.profileId, "{profileId}", false);
|
|
222
|
+
let body;
|
|
223
|
+
return new __HttpRequest({
|
|
224
|
+
protocol,
|
|
225
|
+
hostname,
|
|
226
|
+
port,
|
|
227
|
+
method: "GET",
|
|
228
|
+
headers,
|
|
229
|
+
path: resolvedPath,
|
|
230
|
+
body,
|
|
918
231
|
});
|
|
919
|
-
}
|
|
920
|
-
export
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
case 1:
|
|
935
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
936
|
-
if (data.crl != null) {
|
|
937
|
-
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
938
|
-
}
|
|
939
|
-
return [2, contents];
|
|
940
|
-
}
|
|
232
|
+
};
|
|
233
|
+
export const serializeAws_restJson1GetSubjectCommand = async (input, context) => {
|
|
234
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
235
|
+
const headers = {};
|
|
236
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/subject/{subjectId}";
|
|
237
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "subjectId", () => input.subjectId, "{subjectId}", false);
|
|
238
|
+
let body;
|
|
239
|
+
return new __HttpRequest({
|
|
240
|
+
protocol,
|
|
241
|
+
hostname,
|
|
242
|
+
port,
|
|
243
|
+
method: "GET",
|
|
244
|
+
headers,
|
|
245
|
+
path: resolvedPath,
|
|
246
|
+
body,
|
|
941
247
|
});
|
|
942
|
-
}
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
case "AccessDeniedException": return [3, 2];
|
|
958
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
959
|
-
case "ResourceNotFoundException": return [3, 4];
|
|
960
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 4];
|
|
961
|
-
}
|
|
962
|
-
return [3, 6];
|
|
963
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
964
|
-
case 3: throw _d.sent();
|
|
965
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
966
|
-
case 5: throw _d.sent();
|
|
967
|
-
case 6:
|
|
968
|
-
parsedBody = parsedOutput.body;
|
|
969
|
-
throwDefaultError({
|
|
970
|
-
output: output,
|
|
971
|
-
parsedBody: parsedBody,
|
|
972
|
-
exceptionCtor: __BaseException,
|
|
973
|
-
errorCode: errorCode,
|
|
974
|
-
});
|
|
975
|
-
_d.label = 7;
|
|
976
|
-
case 7: return [2];
|
|
977
|
-
}
|
|
248
|
+
};
|
|
249
|
+
export const serializeAws_restJson1GetTrustAnchorCommand = async (input, context) => {
|
|
250
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
251
|
+
const headers = {};
|
|
252
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchor/{trustAnchorId}";
|
|
253
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", () => input.trustAnchorId, "{trustAnchorId}", false);
|
|
254
|
+
let body;
|
|
255
|
+
return new __HttpRequest({
|
|
256
|
+
protocol,
|
|
257
|
+
hostname,
|
|
258
|
+
port,
|
|
259
|
+
method: "GET",
|
|
260
|
+
headers,
|
|
261
|
+
path: resolvedPath,
|
|
262
|
+
body,
|
|
978
263
|
});
|
|
979
|
-
}
|
|
980
|
-
export
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
264
|
+
};
|
|
265
|
+
export const serializeAws_restJson1ImportCrlCommand = async (input, context) => {
|
|
266
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
267
|
+
const headers = {
|
|
268
|
+
"content-type": "application/json",
|
|
269
|
+
};
|
|
270
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crls";
|
|
271
|
+
let body;
|
|
272
|
+
body = JSON.stringify({
|
|
273
|
+
...(input.crlData != null && { crlData: context.base64Encoder(input.crlData) }),
|
|
274
|
+
...(input.enabled != null && { enabled: input.enabled }),
|
|
275
|
+
...(input.name != null && { name: input.name }),
|
|
276
|
+
...(input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) }),
|
|
277
|
+
...(input.trustAnchorArn != null && { trustAnchorArn: input.trustAnchorArn }),
|
|
278
|
+
});
|
|
279
|
+
return new __HttpRequest({
|
|
280
|
+
protocol,
|
|
281
|
+
hostname,
|
|
282
|
+
port,
|
|
283
|
+
method: "POST",
|
|
284
|
+
headers,
|
|
285
|
+
path: resolvedPath,
|
|
286
|
+
body,
|
|
1001
287
|
});
|
|
1002
|
-
}
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
}
|
|
1022
|
-
return [3, 6];
|
|
1023
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
1024
|
-
case 3: throw _d.sent();
|
|
1025
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1026
|
-
case 5: throw _d.sent();
|
|
1027
|
-
case 6:
|
|
1028
|
-
parsedBody = parsedOutput.body;
|
|
1029
|
-
throwDefaultError({
|
|
1030
|
-
output: output,
|
|
1031
|
-
parsedBody: parsedBody,
|
|
1032
|
-
exceptionCtor: __BaseException,
|
|
1033
|
-
errorCode: errorCode,
|
|
1034
|
-
});
|
|
1035
|
-
_d.label = 7;
|
|
1036
|
-
case 7: return [2];
|
|
1037
|
-
}
|
|
288
|
+
};
|
|
289
|
+
export const serializeAws_restJson1ListCrlsCommand = async (input, context) => {
|
|
290
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
291
|
+
const headers = {};
|
|
292
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crls";
|
|
293
|
+
const query = map({
|
|
294
|
+
nextToken: [, input.nextToken],
|
|
295
|
+
pageSize: [() => input.pageSize !== void 0, () => input.pageSize.toString()],
|
|
296
|
+
});
|
|
297
|
+
let body;
|
|
298
|
+
return new __HttpRequest({
|
|
299
|
+
protocol,
|
|
300
|
+
hostname,
|
|
301
|
+
port,
|
|
302
|
+
method: "GET",
|
|
303
|
+
headers,
|
|
304
|
+
path: resolvedPath,
|
|
305
|
+
query,
|
|
306
|
+
body,
|
|
1038
307
|
});
|
|
1039
|
-
}
|
|
1040
|
-
export
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
}
|
|
1059
|
-
return [2, contents];
|
|
1060
|
-
}
|
|
308
|
+
};
|
|
309
|
+
export const serializeAws_restJson1ListProfilesCommand = async (input, context) => {
|
|
310
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
311
|
+
const headers = {};
|
|
312
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profiles";
|
|
313
|
+
const query = map({
|
|
314
|
+
nextToken: [, input.nextToken],
|
|
315
|
+
pageSize: [() => input.pageSize !== void 0, () => input.pageSize.toString()],
|
|
316
|
+
});
|
|
317
|
+
let body;
|
|
318
|
+
return new __HttpRequest({
|
|
319
|
+
protocol,
|
|
320
|
+
hostname,
|
|
321
|
+
port,
|
|
322
|
+
method: "GET",
|
|
323
|
+
headers,
|
|
324
|
+
path: resolvedPath,
|
|
325
|
+
query,
|
|
326
|
+
body,
|
|
1061
327
|
});
|
|
1062
|
-
}
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
}
|
|
1082
|
-
return [3, 6];
|
|
1083
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
1084
|
-
case 3: throw _d.sent();
|
|
1085
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1086
|
-
case 5: throw _d.sent();
|
|
1087
|
-
case 6:
|
|
1088
|
-
parsedBody = parsedOutput.body;
|
|
1089
|
-
throwDefaultError({
|
|
1090
|
-
output: output,
|
|
1091
|
-
parsedBody: parsedBody,
|
|
1092
|
-
exceptionCtor: __BaseException,
|
|
1093
|
-
errorCode: errorCode,
|
|
1094
|
-
});
|
|
1095
|
-
_d.label = 7;
|
|
1096
|
-
case 7: return [2];
|
|
1097
|
-
}
|
|
328
|
+
};
|
|
329
|
+
export const serializeAws_restJson1ListSubjectsCommand = async (input, context) => {
|
|
330
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
331
|
+
const headers = {};
|
|
332
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/subjects";
|
|
333
|
+
const query = map({
|
|
334
|
+
nextToken: [, input.nextToken],
|
|
335
|
+
pageSize: [() => input.pageSize !== void 0, () => input.pageSize.toString()],
|
|
336
|
+
});
|
|
337
|
+
let body;
|
|
338
|
+
return new __HttpRequest({
|
|
339
|
+
protocol,
|
|
340
|
+
hostname,
|
|
341
|
+
port,
|
|
342
|
+
method: "GET",
|
|
343
|
+
headers,
|
|
344
|
+
path: resolvedPath,
|
|
345
|
+
query,
|
|
346
|
+
body,
|
|
1098
347
|
});
|
|
1099
|
-
}
|
|
1100
|
-
export
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
1118
|
-
}
|
|
1119
|
-
return [2, contents];
|
|
1120
|
-
}
|
|
348
|
+
};
|
|
349
|
+
export const serializeAws_restJson1ListTagsForResourceCommand = async (input, context) => {
|
|
350
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
351
|
+
const headers = {};
|
|
352
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListTagsForResource";
|
|
353
|
+
const query = map({
|
|
354
|
+
resourceArn: [, input.resourceArn],
|
|
355
|
+
});
|
|
356
|
+
let body;
|
|
357
|
+
return new __HttpRequest({
|
|
358
|
+
protocol,
|
|
359
|
+
hostname,
|
|
360
|
+
port,
|
|
361
|
+
method: "GET",
|
|
362
|
+
headers,
|
|
363
|
+
path: resolvedPath,
|
|
364
|
+
query,
|
|
365
|
+
body,
|
|
1121
366
|
});
|
|
1122
|
-
}
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
}
|
|
1142
|
-
return [3, 6];
|
|
1143
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
1144
|
-
case 3: throw _d.sent();
|
|
1145
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1146
|
-
case 5: throw _d.sent();
|
|
1147
|
-
case 6:
|
|
1148
|
-
parsedBody = parsedOutput.body;
|
|
1149
|
-
throwDefaultError({
|
|
1150
|
-
output: output,
|
|
1151
|
-
parsedBody: parsedBody,
|
|
1152
|
-
exceptionCtor: __BaseException,
|
|
1153
|
-
errorCode: errorCode,
|
|
1154
|
-
});
|
|
1155
|
-
_d.label = 7;
|
|
1156
|
-
case 7: return [2];
|
|
1157
|
-
}
|
|
367
|
+
};
|
|
368
|
+
export const serializeAws_restJson1ListTrustAnchorsCommand = async (input, context) => {
|
|
369
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
370
|
+
const headers = {};
|
|
371
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchors";
|
|
372
|
+
const query = map({
|
|
373
|
+
nextToken: [, input.nextToken],
|
|
374
|
+
pageSize: [() => input.pageSize !== void 0, () => input.pageSize.toString()],
|
|
375
|
+
});
|
|
376
|
+
let body;
|
|
377
|
+
return new __HttpRequest({
|
|
378
|
+
protocol,
|
|
379
|
+
hostname,
|
|
380
|
+
port,
|
|
381
|
+
method: "GET",
|
|
382
|
+
headers,
|
|
383
|
+
path: resolvedPath,
|
|
384
|
+
query,
|
|
385
|
+
body,
|
|
1158
386
|
});
|
|
1159
|
-
}
|
|
1160
|
-
export
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
return [2, contents];
|
|
1180
|
-
}
|
|
387
|
+
};
|
|
388
|
+
export const serializeAws_restJson1TagResourceCommand = async (input, context) => {
|
|
389
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
390
|
+
const headers = {
|
|
391
|
+
"content-type": "application/json",
|
|
392
|
+
};
|
|
393
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/TagResource";
|
|
394
|
+
let body;
|
|
395
|
+
body = JSON.stringify({
|
|
396
|
+
...(input.resourceArn != null && { resourceArn: input.resourceArn }),
|
|
397
|
+
...(input.tags != null && { tags: serializeAws_restJson1TagList(input.tags, context) }),
|
|
398
|
+
});
|
|
399
|
+
return new __HttpRequest({
|
|
400
|
+
protocol,
|
|
401
|
+
hostname,
|
|
402
|
+
port,
|
|
403
|
+
method: "POST",
|
|
404
|
+
headers,
|
|
405
|
+
path: resolvedPath,
|
|
406
|
+
body,
|
|
1181
407
|
});
|
|
1182
|
-
}
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
return [3, 6];
|
|
1203
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
1204
|
-
case 3: throw _d.sent();
|
|
1205
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1206
|
-
case 5: throw _d.sent();
|
|
1207
|
-
case 6:
|
|
1208
|
-
parsedBody = parsedOutput.body;
|
|
1209
|
-
throwDefaultError({
|
|
1210
|
-
output: output,
|
|
1211
|
-
parsedBody: parsedBody,
|
|
1212
|
-
exceptionCtor: __BaseException,
|
|
1213
|
-
errorCode: errorCode,
|
|
1214
|
-
});
|
|
1215
|
-
_d.label = 7;
|
|
1216
|
-
case 7: return [2];
|
|
1217
|
-
}
|
|
408
|
+
};
|
|
409
|
+
export const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
|
|
410
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
411
|
+
const headers = {
|
|
412
|
+
"content-type": "application/json",
|
|
413
|
+
};
|
|
414
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/UntagResource";
|
|
415
|
+
let body;
|
|
416
|
+
body = JSON.stringify({
|
|
417
|
+
...(input.resourceArn != null && { resourceArn: input.resourceArn }),
|
|
418
|
+
...(input.tagKeys != null && { tagKeys: serializeAws_restJson1TagKeyList(input.tagKeys, context) }),
|
|
419
|
+
});
|
|
420
|
+
return new __HttpRequest({
|
|
421
|
+
protocol,
|
|
422
|
+
hostname,
|
|
423
|
+
port,
|
|
424
|
+
method: "POST",
|
|
425
|
+
headers,
|
|
426
|
+
path: resolvedPath,
|
|
427
|
+
body,
|
|
1218
428
|
});
|
|
1219
|
-
}
|
|
1220
|
-
export
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
}
|
|
429
|
+
};
|
|
430
|
+
export const serializeAws_restJson1UpdateCrlCommand = async (input, context) => {
|
|
431
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
432
|
+
const headers = {
|
|
433
|
+
"content-type": "application/json",
|
|
434
|
+
};
|
|
435
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/crl/{crlId}";
|
|
436
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "crlId", () => input.crlId, "{crlId}", false);
|
|
437
|
+
let body;
|
|
438
|
+
body = JSON.stringify({
|
|
439
|
+
...(input.crlData != null && { crlData: context.base64Encoder(input.crlData) }),
|
|
440
|
+
...(input.name != null && { name: input.name }),
|
|
441
|
+
});
|
|
442
|
+
return new __HttpRequest({
|
|
443
|
+
protocol,
|
|
444
|
+
hostname,
|
|
445
|
+
port,
|
|
446
|
+
method: "PATCH",
|
|
447
|
+
headers,
|
|
448
|
+
path: resolvedPath,
|
|
449
|
+
body,
|
|
1241
450
|
});
|
|
1242
|
-
}
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
parsedBody = parsedOutput.body;
|
|
1269
|
-
throwDefaultError({
|
|
1270
|
-
output: output,
|
|
1271
|
-
parsedBody: parsedBody,
|
|
1272
|
-
exceptionCtor: __BaseException,
|
|
1273
|
-
errorCode: errorCode,
|
|
1274
|
-
});
|
|
1275
|
-
_d.label = 7;
|
|
1276
|
-
case 7: return [2];
|
|
1277
|
-
}
|
|
451
|
+
};
|
|
452
|
+
export const serializeAws_restJson1UpdateProfileCommand = async (input, context) => {
|
|
453
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
454
|
+
const headers = {
|
|
455
|
+
"content-type": "application/json",
|
|
456
|
+
};
|
|
457
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profile/{profileId}";
|
|
458
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "profileId", () => input.profileId, "{profileId}", false);
|
|
459
|
+
let body;
|
|
460
|
+
body = JSON.stringify({
|
|
461
|
+
...(input.durationSeconds != null && { durationSeconds: input.durationSeconds }),
|
|
462
|
+
...(input.managedPolicyArns != null && {
|
|
463
|
+
managedPolicyArns: serializeAws_restJson1ManagedPolicyList(input.managedPolicyArns, context),
|
|
464
|
+
}),
|
|
465
|
+
...(input.name != null && { name: input.name }),
|
|
466
|
+
...(input.roleArns != null && { roleArns: serializeAws_restJson1RoleArnList(input.roleArns, context) }),
|
|
467
|
+
...(input.sessionPolicy != null && { sessionPolicy: input.sessionPolicy }),
|
|
468
|
+
});
|
|
469
|
+
return new __HttpRequest({
|
|
470
|
+
protocol,
|
|
471
|
+
hostname,
|
|
472
|
+
port,
|
|
473
|
+
method: "PATCH",
|
|
474
|
+
headers,
|
|
475
|
+
path: resolvedPath,
|
|
476
|
+
body,
|
|
1278
477
|
});
|
|
1279
|
-
}
|
|
1280
|
-
export
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
}
|
|
478
|
+
};
|
|
479
|
+
export const serializeAws_restJson1UpdateTrustAnchorCommand = async (input, context) => {
|
|
480
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
481
|
+
const headers = {
|
|
482
|
+
"content-type": "application/json",
|
|
483
|
+
};
|
|
484
|
+
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/trustanchor/{trustAnchorId}";
|
|
485
|
+
resolvedPath = __resolvedPath(resolvedPath, input, "trustAnchorId", () => input.trustAnchorId, "{trustAnchorId}", false);
|
|
486
|
+
let body;
|
|
487
|
+
body = JSON.stringify({
|
|
488
|
+
...(input.name != null && { name: input.name }),
|
|
489
|
+
...(input.source != null && { source: serializeAws_restJson1Source(input.source, context) }),
|
|
490
|
+
});
|
|
491
|
+
return new __HttpRequest({
|
|
492
|
+
protocol,
|
|
493
|
+
hostname,
|
|
494
|
+
port,
|
|
495
|
+
method: "PATCH",
|
|
496
|
+
headers,
|
|
497
|
+
path: resolvedPath,
|
|
498
|
+
body,
|
|
1301
499
|
});
|
|
1302
|
-
}
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
_a = [__assign({}, output)];
|
|
1310
|
-
_c = {};
|
|
1311
|
-
return [4, parseErrorBody(output.body, context)];
|
|
1312
|
-
case 1:
|
|
1313
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1314
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1315
|
-
_b = errorCode;
|
|
1316
|
-
switch (_b) {
|
|
1317
|
-
case "ResourceNotFoundException": return [3, 2];
|
|
1318
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 2];
|
|
1319
|
-
}
|
|
1320
|
-
return [3, 4];
|
|
1321
|
-
case 2: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1322
|
-
case 3: throw _d.sent();
|
|
1323
|
-
case 4:
|
|
1324
|
-
parsedBody = parsedOutput.body;
|
|
1325
|
-
throwDefaultError({
|
|
1326
|
-
output: output,
|
|
1327
|
-
parsedBody: parsedBody,
|
|
1328
|
-
exceptionCtor: __BaseException,
|
|
1329
|
-
errorCode: errorCode,
|
|
1330
|
-
});
|
|
1331
|
-
_d.label = 5;
|
|
1332
|
-
case 5: return [2];
|
|
1333
|
-
}
|
|
500
|
+
};
|
|
501
|
+
export const deserializeAws_restJson1CreateProfileCommand = async (output, context) => {
|
|
502
|
+
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
503
|
+
return deserializeAws_restJson1CreateProfileCommandError(output, context);
|
|
504
|
+
}
|
|
505
|
+
const contents = map({
|
|
506
|
+
$metadata: deserializeMetadata(output),
|
|
1334
507
|
});
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
508
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
509
|
+
if (data.profile != null) {
|
|
510
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
511
|
+
}
|
|
512
|
+
return contents;
|
|
513
|
+
};
|
|
514
|
+
const deserializeAws_restJson1CreateProfileCommandError = async (output, context) => {
|
|
515
|
+
const parsedOutput = {
|
|
516
|
+
...output,
|
|
517
|
+
body: await parseErrorBody(output.body, context),
|
|
518
|
+
};
|
|
519
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
520
|
+
switch (errorCode) {
|
|
521
|
+
case "AccessDeniedException":
|
|
522
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
523
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
524
|
+
case "ValidationException":
|
|
525
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
526
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
527
|
+
default:
|
|
528
|
+
const parsedBody = parsedOutput.body;
|
|
529
|
+
throwDefaultError({
|
|
530
|
+
output,
|
|
531
|
+
parsedBody,
|
|
532
|
+
exceptionCtor: __BaseException,
|
|
533
|
+
errorCode,
|
|
534
|
+
});
|
|
535
|
+
}
|
|
536
|
+
};
|
|
537
|
+
export const deserializeAws_restJson1CreateTrustAnchorCommand = async (output, context) => {
|
|
538
|
+
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
539
|
+
return deserializeAws_restJson1CreateTrustAnchorCommandError(output, context);
|
|
540
|
+
}
|
|
541
|
+
const contents = map({
|
|
542
|
+
$metadata: deserializeMetadata(output),
|
|
1357
543
|
});
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
return
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
}
|
|
544
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
545
|
+
if (data.trustAnchor != null) {
|
|
546
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
547
|
+
}
|
|
548
|
+
return contents;
|
|
549
|
+
};
|
|
550
|
+
const deserializeAws_restJson1CreateTrustAnchorCommandError = async (output, context) => {
|
|
551
|
+
const parsedOutput = {
|
|
552
|
+
...output,
|
|
553
|
+
body: await parseErrorBody(output.body, context),
|
|
554
|
+
};
|
|
555
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
556
|
+
switch (errorCode) {
|
|
557
|
+
case "AccessDeniedException":
|
|
558
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
559
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
560
|
+
case "ValidationException":
|
|
561
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
562
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
563
|
+
default:
|
|
564
|
+
const parsedBody = parsedOutput.body;
|
|
565
|
+
throwDefaultError({
|
|
566
|
+
output,
|
|
567
|
+
parsedBody,
|
|
568
|
+
exceptionCtor: __BaseException,
|
|
569
|
+
errorCode,
|
|
570
|
+
});
|
|
571
|
+
}
|
|
572
|
+
};
|
|
573
|
+
export const deserializeAws_restJson1DeleteCrlCommand = async (output, context) => {
|
|
574
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
575
|
+
return deserializeAws_restJson1DeleteCrlCommandError(output, context);
|
|
576
|
+
}
|
|
577
|
+
const contents = map({
|
|
578
|
+
$metadata: deserializeMetadata(output),
|
|
1394
579
|
});
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
580
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
581
|
+
if (data.crl != null) {
|
|
582
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
583
|
+
}
|
|
584
|
+
return contents;
|
|
585
|
+
};
|
|
586
|
+
const deserializeAws_restJson1DeleteCrlCommandError = async (output, context) => {
|
|
587
|
+
const parsedOutput = {
|
|
588
|
+
...output,
|
|
589
|
+
body: await parseErrorBody(output.body, context),
|
|
590
|
+
};
|
|
591
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
592
|
+
switch (errorCode) {
|
|
593
|
+
case "AccessDeniedException":
|
|
594
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
595
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
596
|
+
case "ResourceNotFoundException":
|
|
597
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
598
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
599
|
+
default:
|
|
600
|
+
const parsedBody = parsedOutput.body;
|
|
601
|
+
throwDefaultError({
|
|
602
|
+
output,
|
|
603
|
+
parsedBody,
|
|
604
|
+
exceptionCtor: __BaseException,
|
|
605
|
+
errorCode,
|
|
606
|
+
});
|
|
607
|
+
}
|
|
608
|
+
};
|
|
609
|
+
export const deserializeAws_restJson1DeleteProfileCommand = async (output, context) => {
|
|
610
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
611
|
+
return deserializeAws_restJson1DeleteProfileCommandError(output, context);
|
|
612
|
+
}
|
|
613
|
+
const contents = map({
|
|
614
|
+
$metadata: deserializeMetadata(output),
|
|
1417
615
|
});
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
return
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
}
|
|
616
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
617
|
+
if (data.profile != null) {
|
|
618
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
619
|
+
}
|
|
620
|
+
return contents;
|
|
621
|
+
};
|
|
622
|
+
const deserializeAws_restJson1DeleteProfileCommandError = async (output, context) => {
|
|
623
|
+
const parsedOutput = {
|
|
624
|
+
...output,
|
|
625
|
+
body: await parseErrorBody(output.body, context),
|
|
626
|
+
};
|
|
627
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
628
|
+
switch (errorCode) {
|
|
629
|
+
case "AccessDeniedException":
|
|
630
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
631
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
632
|
+
case "ResourceNotFoundException":
|
|
633
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
634
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
635
|
+
default:
|
|
636
|
+
const parsedBody = parsedOutput.body;
|
|
637
|
+
throwDefaultError({
|
|
638
|
+
output,
|
|
639
|
+
parsedBody,
|
|
640
|
+
exceptionCtor: __BaseException,
|
|
641
|
+
errorCode,
|
|
642
|
+
});
|
|
643
|
+
}
|
|
644
|
+
};
|
|
645
|
+
export const deserializeAws_restJson1DeleteTrustAnchorCommand = async (output, context) => {
|
|
646
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
647
|
+
return deserializeAws_restJson1DeleteTrustAnchorCommandError(output, context);
|
|
648
|
+
}
|
|
649
|
+
const contents = map({
|
|
650
|
+
$metadata: deserializeMetadata(output),
|
|
1454
651
|
});
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
652
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
653
|
+
if (data.trustAnchor != null) {
|
|
654
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
655
|
+
}
|
|
656
|
+
return contents;
|
|
657
|
+
};
|
|
658
|
+
const deserializeAws_restJson1DeleteTrustAnchorCommandError = async (output, context) => {
|
|
659
|
+
const parsedOutput = {
|
|
660
|
+
...output,
|
|
661
|
+
body: await parseErrorBody(output.body, context),
|
|
662
|
+
};
|
|
663
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
664
|
+
switch (errorCode) {
|
|
665
|
+
case "AccessDeniedException":
|
|
666
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
667
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
668
|
+
case "ResourceNotFoundException":
|
|
669
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
670
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
671
|
+
default:
|
|
672
|
+
const parsedBody = parsedOutput.body;
|
|
673
|
+
throwDefaultError({
|
|
674
|
+
output,
|
|
675
|
+
parsedBody,
|
|
676
|
+
exceptionCtor: __BaseException,
|
|
677
|
+
errorCode,
|
|
678
|
+
});
|
|
679
|
+
}
|
|
680
|
+
};
|
|
681
|
+
export const deserializeAws_restJson1DisableCrlCommand = async (output, context) => {
|
|
682
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
683
|
+
return deserializeAws_restJson1DisableCrlCommandError(output, context);
|
|
684
|
+
}
|
|
685
|
+
const contents = map({
|
|
686
|
+
$metadata: deserializeMetadata(output),
|
|
1477
687
|
});
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
return
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
errorCode: errorCode,
|
|
1514
|
-
});
|
|
1515
|
-
_d.label = 9;
|
|
1516
|
-
case 9: return [2];
|
|
1517
|
-
}
|
|
688
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
689
|
+
if (data.crl != null) {
|
|
690
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
691
|
+
}
|
|
692
|
+
return contents;
|
|
693
|
+
};
|
|
694
|
+
const deserializeAws_restJson1DisableCrlCommandError = async (output, context) => {
|
|
695
|
+
const parsedOutput = {
|
|
696
|
+
...output,
|
|
697
|
+
body: await parseErrorBody(output.body, context),
|
|
698
|
+
};
|
|
699
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
700
|
+
switch (errorCode) {
|
|
701
|
+
case "AccessDeniedException":
|
|
702
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
703
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
704
|
+
case "ResourceNotFoundException":
|
|
705
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
706
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
707
|
+
default:
|
|
708
|
+
const parsedBody = parsedOutput.body;
|
|
709
|
+
throwDefaultError({
|
|
710
|
+
output,
|
|
711
|
+
parsedBody,
|
|
712
|
+
exceptionCtor: __BaseException,
|
|
713
|
+
errorCode,
|
|
714
|
+
});
|
|
715
|
+
}
|
|
716
|
+
};
|
|
717
|
+
export const deserializeAws_restJson1DisableProfileCommand = async (output, context) => {
|
|
718
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
719
|
+
return deserializeAws_restJson1DisableProfileCommandError(output, context);
|
|
720
|
+
}
|
|
721
|
+
const contents = map({
|
|
722
|
+
$metadata: deserializeMetadata(output),
|
|
1518
723
|
});
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
724
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
725
|
+
if (data.profile != null) {
|
|
726
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
727
|
+
}
|
|
728
|
+
return contents;
|
|
729
|
+
};
|
|
730
|
+
const deserializeAws_restJson1DisableProfileCommandError = async (output, context) => {
|
|
731
|
+
const parsedOutput = {
|
|
732
|
+
...output,
|
|
733
|
+
body: await parseErrorBody(output.body, context),
|
|
734
|
+
};
|
|
735
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
736
|
+
switch (errorCode) {
|
|
737
|
+
case "AccessDeniedException":
|
|
738
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
739
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
740
|
+
case "ResourceNotFoundException":
|
|
741
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
742
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
743
|
+
default:
|
|
744
|
+
const parsedBody = parsedOutput.body;
|
|
745
|
+
throwDefaultError({
|
|
746
|
+
output,
|
|
747
|
+
parsedBody,
|
|
748
|
+
exceptionCtor: __BaseException,
|
|
749
|
+
errorCode,
|
|
750
|
+
});
|
|
751
|
+
}
|
|
752
|
+
};
|
|
753
|
+
export const deserializeAws_restJson1DisableTrustAnchorCommand = async (output, context) => {
|
|
754
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
755
|
+
return deserializeAws_restJson1DisableTrustAnchorCommandError(output, context);
|
|
756
|
+
}
|
|
757
|
+
const contents = map({
|
|
758
|
+
$metadata: deserializeMetadata(output),
|
|
1541
759
|
});
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
return
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
}
|
|
760
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
761
|
+
if (data.trustAnchor != null) {
|
|
762
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
763
|
+
}
|
|
764
|
+
return contents;
|
|
765
|
+
};
|
|
766
|
+
const deserializeAws_restJson1DisableTrustAnchorCommandError = async (output, context) => {
|
|
767
|
+
const parsedOutput = {
|
|
768
|
+
...output,
|
|
769
|
+
body: await parseErrorBody(output.body, context),
|
|
770
|
+
};
|
|
771
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
772
|
+
switch (errorCode) {
|
|
773
|
+
case "AccessDeniedException":
|
|
774
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
775
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
776
|
+
case "ResourceNotFoundException":
|
|
777
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
778
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
779
|
+
default:
|
|
780
|
+
const parsedBody = parsedOutput.body;
|
|
781
|
+
throwDefaultError({
|
|
782
|
+
output,
|
|
783
|
+
parsedBody,
|
|
784
|
+
exceptionCtor: __BaseException,
|
|
785
|
+
errorCode,
|
|
786
|
+
});
|
|
787
|
+
}
|
|
788
|
+
};
|
|
789
|
+
export const deserializeAws_restJson1EnableCrlCommand = async (output, context) => {
|
|
790
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
791
|
+
return deserializeAws_restJson1EnableCrlCommandError(output, context);
|
|
792
|
+
}
|
|
793
|
+
const contents = map({
|
|
794
|
+
$metadata: deserializeMetadata(output),
|
|
1578
795
|
});
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
796
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
797
|
+
if (data.crl != null) {
|
|
798
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
799
|
+
}
|
|
800
|
+
return contents;
|
|
801
|
+
};
|
|
802
|
+
const deserializeAws_restJson1EnableCrlCommandError = async (output, context) => {
|
|
803
|
+
const parsedOutput = {
|
|
804
|
+
...output,
|
|
805
|
+
body: await parseErrorBody(output.body, context),
|
|
806
|
+
};
|
|
807
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
808
|
+
switch (errorCode) {
|
|
809
|
+
case "AccessDeniedException":
|
|
810
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
811
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
812
|
+
case "ResourceNotFoundException":
|
|
813
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
814
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
815
|
+
default:
|
|
816
|
+
const parsedBody = parsedOutput.body;
|
|
817
|
+
throwDefaultError({
|
|
818
|
+
output,
|
|
819
|
+
parsedBody,
|
|
820
|
+
exceptionCtor: __BaseException,
|
|
821
|
+
errorCode,
|
|
822
|
+
});
|
|
823
|
+
}
|
|
824
|
+
};
|
|
825
|
+
export const deserializeAws_restJson1EnableProfileCommand = async (output, context) => {
|
|
826
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
827
|
+
return deserializeAws_restJson1EnableProfileCommandError(output, context);
|
|
828
|
+
}
|
|
829
|
+
const contents = map({
|
|
830
|
+
$metadata: deserializeMetadata(output),
|
|
1604
831
|
});
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
return
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
}
|
|
832
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
833
|
+
if (data.profile != null) {
|
|
834
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
835
|
+
}
|
|
836
|
+
return contents;
|
|
837
|
+
};
|
|
838
|
+
const deserializeAws_restJson1EnableProfileCommandError = async (output, context) => {
|
|
839
|
+
const parsedOutput = {
|
|
840
|
+
...output,
|
|
841
|
+
body: await parseErrorBody(output.body, context),
|
|
842
|
+
};
|
|
843
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
844
|
+
switch (errorCode) {
|
|
845
|
+
case "AccessDeniedException":
|
|
846
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
847
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
848
|
+
case "ResourceNotFoundException":
|
|
849
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
850
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
851
|
+
default:
|
|
852
|
+
const parsedBody = parsedOutput.body;
|
|
853
|
+
throwDefaultError({
|
|
854
|
+
output,
|
|
855
|
+
parsedBody,
|
|
856
|
+
exceptionCtor: __BaseException,
|
|
857
|
+
errorCode,
|
|
858
|
+
});
|
|
859
|
+
}
|
|
860
|
+
};
|
|
861
|
+
export const deserializeAws_restJson1EnableTrustAnchorCommand = async (output, context) => {
|
|
862
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
863
|
+
return deserializeAws_restJson1EnableTrustAnchorCommandError(output, context);
|
|
864
|
+
}
|
|
865
|
+
const contents = map({
|
|
866
|
+
$metadata: deserializeMetadata(output),
|
|
1641
867
|
});
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
868
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
869
|
+
if (data.trustAnchor != null) {
|
|
870
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
871
|
+
}
|
|
872
|
+
return contents;
|
|
873
|
+
};
|
|
874
|
+
const deserializeAws_restJson1EnableTrustAnchorCommandError = async (output, context) => {
|
|
875
|
+
const parsedOutput = {
|
|
876
|
+
...output,
|
|
877
|
+
body: await parseErrorBody(output.body, context),
|
|
878
|
+
};
|
|
879
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
880
|
+
switch (errorCode) {
|
|
881
|
+
case "AccessDeniedException":
|
|
882
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
883
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
884
|
+
case "ResourceNotFoundException":
|
|
885
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
886
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
887
|
+
default:
|
|
888
|
+
const parsedBody = parsedOutput.body;
|
|
889
|
+
throwDefaultError({
|
|
890
|
+
output,
|
|
891
|
+
parsedBody,
|
|
892
|
+
exceptionCtor: __BaseException,
|
|
893
|
+
errorCode,
|
|
894
|
+
});
|
|
895
|
+
}
|
|
896
|
+
};
|
|
897
|
+
export const deserializeAws_restJson1GetCrlCommand = async (output, context) => {
|
|
898
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
899
|
+
return deserializeAws_restJson1GetCrlCommandError(output, context);
|
|
900
|
+
}
|
|
901
|
+
const contents = map({
|
|
902
|
+
$metadata: deserializeMetadata(output),
|
|
1667
903
|
});
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
return
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
});
|
|
1701
|
-
_d.label = 7;
|
|
1702
|
-
case 7: return [2];
|
|
1703
|
-
}
|
|
904
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
905
|
+
if (data.crl != null) {
|
|
906
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
907
|
+
}
|
|
908
|
+
return contents;
|
|
909
|
+
};
|
|
910
|
+
const deserializeAws_restJson1GetCrlCommandError = async (output, context) => {
|
|
911
|
+
const parsedOutput = {
|
|
912
|
+
...output,
|
|
913
|
+
body: await parseErrorBody(output.body, context),
|
|
914
|
+
};
|
|
915
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
916
|
+
switch (errorCode) {
|
|
917
|
+
case "ResourceNotFoundException":
|
|
918
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
919
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
920
|
+
default:
|
|
921
|
+
const parsedBody = parsedOutput.body;
|
|
922
|
+
throwDefaultError({
|
|
923
|
+
output,
|
|
924
|
+
parsedBody,
|
|
925
|
+
exceptionCtor: __BaseException,
|
|
926
|
+
errorCode,
|
|
927
|
+
});
|
|
928
|
+
}
|
|
929
|
+
};
|
|
930
|
+
export const deserializeAws_restJson1GetProfileCommand = async (output, context) => {
|
|
931
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
932
|
+
return deserializeAws_restJson1GetProfileCommandError(output, context);
|
|
933
|
+
}
|
|
934
|
+
const contents = map({
|
|
935
|
+
$metadata: deserializeMetadata(output),
|
|
1704
936
|
});
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
937
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
938
|
+
if (data.profile != null) {
|
|
939
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
940
|
+
}
|
|
941
|
+
return contents;
|
|
942
|
+
};
|
|
943
|
+
const deserializeAws_restJson1GetProfileCommandError = async (output, context) => {
|
|
944
|
+
const parsedOutput = {
|
|
945
|
+
...output,
|
|
946
|
+
body: await parseErrorBody(output.body, context),
|
|
947
|
+
};
|
|
948
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
949
|
+
switch (errorCode) {
|
|
950
|
+
case "AccessDeniedException":
|
|
951
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
952
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
953
|
+
case "ResourceNotFoundException":
|
|
954
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
955
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
956
|
+
default:
|
|
957
|
+
const parsedBody = parsedOutput.body;
|
|
958
|
+
throwDefaultError({
|
|
959
|
+
output,
|
|
960
|
+
parsedBody,
|
|
961
|
+
exceptionCtor: __BaseException,
|
|
962
|
+
errorCode,
|
|
963
|
+
});
|
|
964
|
+
}
|
|
965
|
+
};
|
|
966
|
+
export const deserializeAws_restJson1GetSubjectCommand = async (output, context) => {
|
|
967
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
968
|
+
return deserializeAws_restJson1GetSubjectCommandError(output, context);
|
|
969
|
+
}
|
|
970
|
+
const contents = map({
|
|
971
|
+
$metadata: deserializeMetadata(output),
|
|
1730
972
|
});
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
return
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
}
|
|
973
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
974
|
+
if (data.subject != null) {
|
|
975
|
+
contents.subject = deserializeAws_restJson1SubjectDetail(data.subject, context);
|
|
976
|
+
}
|
|
977
|
+
return contents;
|
|
978
|
+
};
|
|
979
|
+
const deserializeAws_restJson1GetSubjectCommandError = async (output, context) => {
|
|
980
|
+
const parsedOutput = {
|
|
981
|
+
...output,
|
|
982
|
+
body: await parseErrorBody(output.body, context),
|
|
983
|
+
};
|
|
984
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
985
|
+
switch (errorCode) {
|
|
986
|
+
case "AccessDeniedException":
|
|
987
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
988
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
989
|
+
case "ResourceNotFoundException":
|
|
990
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
991
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
992
|
+
default:
|
|
993
|
+
const parsedBody = parsedOutput.body;
|
|
994
|
+
throwDefaultError({
|
|
995
|
+
output,
|
|
996
|
+
parsedBody,
|
|
997
|
+
exceptionCtor: __BaseException,
|
|
998
|
+
errorCode,
|
|
999
|
+
});
|
|
1000
|
+
}
|
|
1001
|
+
};
|
|
1002
|
+
export const deserializeAws_restJson1GetTrustAnchorCommand = async (output, context) => {
|
|
1003
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1004
|
+
return deserializeAws_restJson1GetTrustAnchorCommandError(output, context);
|
|
1005
|
+
}
|
|
1006
|
+
const contents = map({
|
|
1007
|
+
$metadata: deserializeMetadata(output),
|
|
1767
1008
|
});
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1009
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1010
|
+
if (data.trustAnchor != null) {
|
|
1011
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
1012
|
+
}
|
|
1013
|
+
return contents;
|
|
1014
|
+
};
|
|
1015
|
+
const deserializeAws_restJson1GetTrustAnchorCommandError = async (output, context) => {
|
|
1016
|
+
const parsedOutput = {
|
|
1017
|
+
...output,
|
|
1018
|
+
body: await parseErrorBody(output.body, context),
|
|
1019
|
+
};
|
|
1020
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1021
|
+
switch (errorCode) {
|
|
1022
|
+
case "AccessDeniedException":
|
|
1023
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1024
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1025
|
+
case "ResourceNotFoundException":
|
|
1026
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1027
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1028
|
+
case "ValidationException":
|
|
1029
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1030
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1031
|
+
default:
|
|
1032
|
+
const parsedBody = parsedOutput.body;
|
|
1033
|
+
throwDefaultError({
|
|
1034
|
+
output,
|
|
1035
|
+
parsedBody,
|
|
1036
|
+
exceptionCtor: __BaseException,
|
|
1037
|
+
errorCode,
|
|
1038
|
+
});
|
|
1039
|
+
}
|
|
1040
|
+
};
|
|
1041
|
+
export const deserializeAws_restJson1ImportCrlCommand = async (output, context) => {
|
|
1042
|
+
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
1043
|
+
return deserializeAws_restJson1ImportCrlCommandError(output, context);
|
|
1044
|
+
}
|
|
1045
|
+
const contents = map({
|
|
1046
|
+
$metadata: deserializeMetadata(output),
|
|
1790
1047
|
});
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
return
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
errorCode: errorCode,
|
|
1827
|
-
});
|
|
1828
|
-
_d.label = 9;
|
|
1829
|
-
case 9: return [2];
|
|
1830
|
-
}
|
|
1048
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1049
|
+
if (data.crl != null) {
|
|
1050
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
1051
|
+
}
|
|
1052
|
+
return contents;
|
|
1053
|
+
};
|
|
1054
|
+
const deserializeAws_restJson1ImportCrlCommandError = async (output, context) => {
|
|
1055
|
+
const parsedOutput = {
|
|
1056
|
+
...output,
|
|
1057
|
+
body: await parseErrorBody(output.body, context),
|
|
1058
|
+
};
|
|
1059
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1060
|
+
switch (errorCode) {
|
|
1061
|
+
case "AccessDeniedException":
|
|
1062
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1063
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1064
|
+
case "ValidationException":
|
|
1065
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1066
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1067
|
+
default:
|
|
1068
|
+
const parsedBody = parsedOutput.body;
|
|
1069
|
+
throwDefaultError({
|
|
1070
|
+
output,
|
|
1071
|
+
parsedBody,
|
|
1072
|
+
exceptionCtor: __BaseException,
|
|
1073
|
+
errorCode,
|
|
1074
|
+
});
|
|
1075
|
+
}
|
|
1076
|
+
};
|
|
1077
|
+
export const deserializeAws_restJson1ListCrlsCommand = async (output, context) => {
|
|
1078
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1079
|
+
return deserializeAws_restJson1ListCrlsCommandError(output, context);
|
|
1080
|
+
}
|
|
1081
|
+
const contents = map({
|
|
1082
|
+
$metadata: deserializeMetadata(output),
|
|
1831
1083
|
});
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1084
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1085
|
+
if (data.crls != null) {
|
|
1086
|
+
contents.crls = deserializeAws_restJson1CrlDetails(data.crls, context);
|
|
1087
|
+
}
|
|
1088
|
+
if (data.nextToken != null) {
|
|
1089
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
1090
|
+
}
|
|
1091
|
+
return contents;
|
|
1092
|
+
};
|
|
1093
|
+
const deserializeAws_restJson1ListCrlsCommandError = async (output, context) => {
|
|
1094
|
+
const parsedOutput = {
|
|
1095
|
+
...output,
|
|
1096
|
+
body: await parseErrorBody(output.body, context),
|
|
1097
|
+
};
|
|
1098
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1099
|
+
switch (errorCode) {
|
|
1100
|
+
case "AccessDeniedException":
|
|
1101
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1102
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1103
|
+
case "ValidationException":
|
|
1104
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1105
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1106
|
+
default:
|
|
1107
|
+
const parsedBody = parsedOutput.body;
|
|
1108
|
+
throwDefaultError({
|
|
1109
|
+
output,
|
|
1110
|
+
parsedBody,
|
|
1111
|
+
exceptionCtor: __BaseException,
|
|
1112
|
+
errorCode,
|
|
1113
|
+
});
|
|
1114
|
+
}
|
|
1115
|
+
};
|
|
1116
|
+
export const deserializeAws_restJson1ListProfilesCommand = async (output, context) => {
|
|
1117
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1118
|
+
return deserializeAws_restJson1ListProfilesCommandError(output, context);
|
|
1119
|
+
}
|
|
1120
|
+
const contents = map({
|
|
1121
|
+
$metadata: deserializeMetadata(output),
|
|
1857
1122
|
});
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
parsedBody
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1123
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1124
|
+
if (data.nextToken != null) {
|
|
1125
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
1126
|
+
}
|
|
1127
|
+
if (data.profiles != null) {
|
|
1128
|
+
contents.profiles = deserializeAws_restJson1ProfileDetails(data.profiles, context);
|
|
1129
|
+
}
|
|
1130
|
+
return contents;
|
|
1131
|
+
};
|
|
1132
|
+
const deserializeAws_restJson1ListProfilesCommandError = async (output, context) => {
|
|
1133
|
+
const parsedOutput = {
|
|
1134
|
+
...output,
|
|
1135
|
+
body: await parseErrorBody(output.body, context),
|
|
1136
|
+
};
|
|
1137
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1138
|
+
switch (errorCode) {
|
|
1139
|
+
case "AccessDeniedException":
|
|
1140
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1141
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1142
|
+
case "ValidationException":
|
|
1143
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1144
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1145
|
+
default:
|
|
1146
|
+
const parsedBody = parsedOutput.body;
|
|
1147
|
+
throwDefaultError({
|
|
1148
|
+
output,
|
|
1149
|
+
parsedBody,
|
|
1150
|
+
exceptionCtor: __BaseException,
|
|
1151
|
+
errorCode,
|
|
1152
|
+
});
|
|
1153
|
+
}
|
|
1154
|
+
};
|
|
1155
|
+
export const deserializeAws_restJson1ListSubjectsCommand = async (output, context) => {
|
|
1156
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1157
|
+
return deserializeAws_restJson1ListSubjectsCommandError(output, context);
|
|
1158
|
+
}
|
|
1159
|
+
const contents = map({
|
|
1160
|
+
$metadata: deserializeMetadata(output),
|
|
1894
1161
|
});
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1162
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1163
|
+
if (data.nextToken != null) {
|
|
1164
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
1165
|
+
}
|
|
1166
|
+
if (data.subjects != null) {
|
|
1167
|
+
contents.subjects = deserializeAws_restJson1SubjectSummaries(data.subjects, context);
|
|
1168
|
+
}
|
|
1169
|
+
return contents;
|
|
1170
|
+
};
|
|
1171
|
+
const deserializeAws_restJson1ListSubjectsCommandError = async (output, context) => {
|
|
1172
|
+
const parsedOutput = {
|
|
1173
|
+
...output,
|
|
1174
|
+
body: await parseErrorBody(output.body, context),
|
|
1175
|
+
};
|
|
1176
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1177
|
+
switch (errorCode) {
|
|
1178
|
+
case "AccessDeniedException":
|
|
1179
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1180
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1181
|
+
case "ValidationException":
|
|
1182
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1183
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1184
|
+
default:
|
|
1185
|
+
const parsedBody = parsedOutput.body;
|
|
1186
|
+
throwDefaultError({
|
|
1187
|
+
output,
|
|
1188
|
+
parsedBody,
|
|
1189
|
+
exceptionCtor: __BaseException,
|
|
1190
|
+
errorCode,
|
|
1191
|
+
});
|
|
1192
|
+
}
|
|
1193
|
+
};
|
|
1194
|
+
export const deserializeAws_restJson1ListTagsForResourceCommand = async (output, context) => {
|
|
1195
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1196
|
+
return deserializeAws_restJson1ListTagsForResourceCommandError(output, context);
|
|
1197
|
+
}
|
|
1198
|
+
const contents = map({
|
|
1199
|
+
$metadata: deserializeMetadata(output),
|
|
1912
1200
|
});
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
return
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
exceptionCtor: __BaseException,
|
|
1952
|
-
errorCode: errorCode,
|
|
1953
|
-
});
|
|
1954
|
-
_d.label = 11;
|
|
1955
|
-
case 11: return [2];
|
|
1956
|
-
}
|
|
1201
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1202
|
+
if (data.tags != null) {
|
|
1203
|
+
contents.tags = deserializeAws_restJson1TagList(data.tags, context);
|
|
1204
|
+
}
|
|
1205
|
+
return contents;
|
|
1206
|
+
};
|
|
1207
|
+
const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => {
|
|
1208
|
+
const parsedOutput = {
|
|
1209
|
+
...output,
|
|
1210
|
+
body: await parseErrorBody(output.body, context),
|
|
1211
|
+
};
|
|
1212
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1213
|
+
switch (errorCode) {
|
|
1214
|
+
case "AccessDeniedException":
|
|
1215
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1216
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1217
|
+
case "ResourceNotFoundException":
|
|
1218
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1219
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1220
|
+
case "ValidationException":
|
|
1221
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1222
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1223
|
+
default:
|
|
1224
|
+
const parsedBody = parsedOutput.body;
|
|
1225
|
+
throwDefaultError({
|
|
1226
|
+
output,
|
|
1227
|
+
parsedBody,
|
|
1228
|
+
exceptionCtor: __BaseException,
|
|
1229
|
+
errorCode,
|
|
1230
|
+
});
|
|
1231
|
+
}
|
|
1232
|
+
};
|
|
1233
|
+
export const deserializeAws_restJson1ListTrustAnchorsCommand = async (output, context) => {
|
|
1234
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1235
|
+
return deserializeAws_restJson1ListTrustAnchorsCommandError(output, context);
|
|
1236
|
+
}
|
|
1237
|
+
const contents = map({
|
|
1238
|
+
$metadata: deserializeMetadata(output),
|
|
1957
1239
|
});
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1240
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1241
|
+
if (data.nextToken != null) {
|
|
1242
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
1243
|
+
}
|
|
1244
|
+
if (data.trustAnchors != null) {
|
|
1245
|
+
contents.trustAnchors = deserializeAws_restJson1TrustAnchorDetails(data.trustAnchors, context);
|
|
1246
|
+
}
|
|
1247
|
+
return contents;
|
|
1248
|
+
};
|
|
1249
|
+
const deserializeAws_restJson1ListTrustAnchorsCommandError = async (output, context) => {
|
|
1250
|
+
const parsedOutput = {
|
|
1251
|
+
...output,
|
|
1252
|
+
body: await parseErrorBody(output.body, context),
|
|
1253
|
+
};
|
|
1254
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1255
|
+
switch (errorCode) {
|
|
1256
|
+
case "AccessDeniedException":
|
|
1257
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1258
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1259
|
+
case "ValidationException":
|
|
1260
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1261
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1262
|
+
default:
|
|
1263
|
+
const parsedBody = parsedOutput.body;
|
|
1264
|
+
throwDefaultError({
|
|
1265
|
+
output,
|
|
1266
|
+
parsedBody,
|
|
1267
|
+
exceptionCtor: __BaseException,
|
|
1268
|
+
errorCode,
|
|
1269
|
+
});
|
|
1270
|
+
}
|
|
1271
|
+
};
|
|
1272
|
+
export const deserializeAws_restJson1TagResourceCommand = async (output, context) => {
|
|
1273
|
+
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
1274
|
+
return deserializeAws_restJson1TagResourceCommandError(output, context);
|
|
1275
|
+
}
|
|
1276
|
+
const contents = map({
|
|
1277
|
+
$metadata: deserializeMetadata(output),
|
|
1975
1278
|
});
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
case 9: return [2];
|
|
2015
|
-
}
|
|
1279
|
+
await collectBody(output.body, context);
|
|
1280
|
+
return contents;
|
|
1281
|
+
};
|
|
1282
|
+
const deserializeAws_restJson1TagResourceCommandError = async (output, context) => {
|
|
1283
|
+
const parsedOutput = {
|
|
1284
|
+
...output,
|
|
1285
|
+
body: await parseErrorBody(output.body, context),
|
|
1286
|
+
};
|
|
1287
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1288
|
+
switch (errorCode) {
|
|
1289
|
+
case "AccessDeniedException":
|
|
1290
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1291
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1292
|
+
case "ResourceNotFoundException":
|
|
1293
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1294
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1295
|
+
case "TooManyTagsException":
|
|
1296
|
+
case "com.amazonaws.rolesanywhere#TooManyTagsException":
|
|
1297
|
+
throw await deserializeAws_restJson1TooManyTagsExceptionResponse(parsedOutput, context);
|
|
1298
|
+
case "ValidationException":
|
|
1299
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1300
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1301
|
+
default:
|
|
1302
|
+
const parsedBody = parsedOutput.body;
|
|
1303
|
+
throwDefaultError({
|
|
1304
|
+
output,
|
|
1305
|
+
parsedBody,
|
|
1306
|
+
exceptionCtor: __BaseException,
|
|
1307
|
+
errorCode,
|
|
1308
|
+
});
|
|
1309
|
+
}
|
|
1310
|
+
};
|
|
1311
|
+
export const deserializeAws_restJson1UntagResourceCommand = async (output, context) => {
|
|
1312
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1313
|
+
return deserializeAws_restJson1UntagResourceCommandError(output, context);
|
|
1314
|
+
}
|
|
1315
|
+
const contents = map({
|
|
1316
|
+
$metadata: deserializeMetadata(output),
|
|
2016
1317
|
});
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
1318
|
+
await collectBody(output.body, context);
|
|
1319
|
+
return contents;
|
|
1320
|
+
};
|
|
1321
|
+
const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => {
|
|
1322
|
+
const parsedOutput = {
|
|
1323
|
+
...output,
|
|
1324
|
+
body: await parseErrorBody(output.body, context),
|
|
1325
|
+
};
|
|
1326
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1327
|
+
switch (errorCode) {
|
|
1328
|
+
case "AccessDeniedException":
|
|
1329
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1330
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1331
|
+
case "ResourceNotFoundException":
|
|
1332
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1333
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1334
|
+
case "ValidationException":
|
|
1335
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1336
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1337
|
+
default:
|
|
1338
|
+
const parsedBody = parsedOutput.body;
|
|
1339
|
+
throwDefaultError({
|
|
1340
|
+
output,
|
|
1341
|
+
parsedBody,
|
|
1342
|
+
exceptionCtor: __BaseException,
|
|
1343
|
+
errorCode,
|
|
1344
|
+
});
|
|
1345
|
+
}
|
|
1346
|
+
};
|
|
1347
|
+
export const deserializeAws_restJson1UpdateCrlCommand = async (output, context) => {
|
|
1348
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1349
|
+
return deserializeAws_restJson1UpdateCrlCommandError(output, context);
|
|
1350
|
+
}
|
|
1351
|
+
const contents = map({
|
|
1352
|
+
$metadata: deserializeMetadata(output),
|
|
2039
1353
|
});
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
return
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
case 9: return [2];
|
|
2079
|
-
}
|
|
1354
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1355
|
+
if (data.crl != null) {
|
|
1356
|
+
contents.crl = deserializeAws_restJson1CrlDetail(data.crl, context);
|
|
1357
|
+
}
|
|
1358
|
+
return contents;
|
|
1359
|
+
};
|
|
1360
|
+
const deserializeAws_restJson1UpdateCrlCommandError = async (output, context) => {
|
|
1361
|
+
const parsedOutput = {
|
|
1362
|
+
...output,
|
|
1363
|
+
body: await parseErrorBody(output.body, context),
|
|
1364
|
+
};
|
|
1365
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1366
|
+
switch (errorCode) {
|
|
1367
|
+
case "AccessDeniedException":
|
|
1368
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1369
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1370
|
+
case "ResourceNotFoundException":
|
|
1371
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1372
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1373
|
+
case "ValidationException":
|
|
1374
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1375
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1376
|
+
default:
|
|
1377
|
+
const parsedBody = parsedOutput.body;
|
|
1378
|
+
throwDefaultError({
|
|
1379
|
+
output,
|
|
1380
|
+
parsedBody,
|
|
1381
|
+
exceptionCtor: __BaseException,
|
|
1382
|
+
errorCode,
|
|
1383
|
+
});
|
|
1384
|
+
}
|
|
1385
|
+
};
|
|
1386
|
+
export const deserializeAws_restJson1UpdateProfileCommand = async (output, context) => {
|
|
1387
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1388
|
+
return deserializeAws_restJson1UpdateProfileCommandError(output, context);
|
|
1389
|
+
}
|
|
1390
|
+
const contents = map({
|
|
1391
|
+
$metadata: deserializeMetadata(output),
|
|
2080
1392
|
});
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
1393
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1394
|
+
if (data.profile != null) {
|
|
1395
|
+
contents.profile = deserializeAws_restJson1ProfileDetail(data.profile, context);
|
|
1396
|
+
}
|
|
1397
|
+
return contents;
|
|
1398
|
+
};
|
|
1399
|
+
const deserializeAws_restJson1UpdateProfileCommandError = async (output, context) => {
|
|
1400
|
+
const parsedOutput = {
|
|
1401
|
+
...output,
|
|
1402
|
+
body: await parseErrorBody(output.body, context),
|
|
1403
|
+
};
|
|
1404
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1405
|
+
switch (errorCode) {
|
|
1406
|
+
case "AccessDeniedException":
|
|
1407
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1408
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1409
|
+
case "ResourceNotFoundException":
|
|
1410
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1411
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1412
|
+
case "ValidationException":
|
|
1413
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1414
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1415
|
+
default:
|
|
1416
|
+
const parsedBody = parsedOutput.body;
|
|
1417
|
+
throwDefaultError({
|
|
1418
|
+
output,
|
|
1419
|
+
parsedBody,
|
|
1420
|
+
exceptionCtor: __BaseException,
|
|
1421
|
+
errorCode,
|
|
1422
|
+
});
|
|
1423
|
+
}
|
|
1424
|
+
};
|
|
1425
|
+
export const deserializeAws_restJson1UpdateTrustAnchorCommand = async (output, context) => {
|
|
1426
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1427
|
+
return deserializeAws_restJson1UpdateTrustAnchorCommandError(output, context);
|
|
1428
|
+
}
|
|
1429
|
+
const contents = map({
|
|
1430
|
+
$metadata: deserializeMetadata(output),
|
|
2103
1431
|
});
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
return
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
1432
|
+
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1433
|
+
if (data.trustAnchor != null) {
|
|
1434
|
+
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
1435
|
+
}
|
|
1436
|
+
return contents;
|
|
1437
|
+
};
|
|
1438
|
+
const deserializeAws_restJson1UpdateTrustAnchorCommandError = async (output, context) => {
|
|
1439
|
+
const parsedOutput = {
|
|
1440
|
+
...output,
|
|
1441
|
+
body: await parseErrorBody(output.body, context),
|
|
1442
|
+
};
|
|
1443
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1444
|
+
switch (errorCode) {
|
|
1445
|
+
case "AccessDeniedException":
|
|
1446
|
+
case "com.amazonaws.rolesanywhere#AccessDeniedException":
|
|
1447
|
+
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
1448
|
+
case "ResourceNotFoundException":
|
|
1449
|
+
case "com.amazonaws.rolesanywhere#ResourceNotFoundException":
|
|
1450
|
+
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
1451
|
+
case "ValidationException":
|
|
1452
|
+
case "com.amazonaws.rolesanywhere#ValidationException":
|
|
1453
|
+
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
1454
|
+
default:
|
|
1455
|
+
const parsedBody = parsedOutput.body;
|
|
1456
|
+
throwDefaultError({
|
|
1457
|
+
output,
|
|
1458
|
+
parsedBody,
|
|
1459
|
+
exceptionCtor: __BaseException,
|
|
1460
|
+
errorCode,
|
|
1461
|
+
});
|
|
1462
|
+
}
|
|
1463
|
+
};
|
|
1464
|
+
const map = __map;
|
|
1465
|
+
const deserializeAws_restJson1AccessDeniedExceptionResponse = async (parsedOutput, context) => {
|
|
1466
|
+
const contents = map({});
|
|
1467
|
+
const data = parsedOutput.body;
|
|
1468
|
+
if (data.message != null) {
|
|
1469
|
+
contents.message = __expectString(data.message);
|
|
1470
|
+
}
|
|
1471
|
+
const exception = new AccessDeniedException({
|
|
1472
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1473
|
+
...contents,
|
|
2144
1474
|
});
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
});
|
|
2157
|
-
_a = __expectNonNull;
|
|
2158
|
-
_b = __expectObject;
|
|
2159
|
-
return [4, parseBody(output.body, context)];
|
|
2160
|
-
case 1:
|
|
2161
|
-
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
2162
|
-
if (data.trustAnchor != null) {
|
|
2163
|
-
contents.trustAnchor = deserializeAws_restJson1TrustAnchorDetail(data.trustAnchor, context);
|
|
2164
|
-
}
|
|
2165
|
-
return [2, contents];
|
|
2166
|
-
}
|
|
1475
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1476
|
+
};
|
|
1477
|
+
const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => {
|
|
1478
|
+
const contents = map({});
|
|
1479
|
+
const data = parsedOutput.body;
|
|
1480
|
+
if (data.message != null) {
|
|
1481
|
+
contents.message = __expectString(data.message);
|
|
1482
|
+
}
|
|
1483
|
+
const exception = new ResourceNotFoundException({
|
|
1484
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1485
|
+
...contents,
|
|
2167
1486
|
});
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
2180
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2181
|
-
_b = errorCode;
|
|
2182
|
-
switch (_b) {
|
|
2183
|
-
case "AccessDeniedException": return [3, 2];
|
|
2184
|
-
case "com.amazonaws.rolesanywhere#AccessDeniedException": return [3, 2];
|
|
2185
|
-
case "ResourceNotFoundException": return [3, 4];
|
|
2186
|
-
case "com.amazonaws.rolesanywhere#ResourceNotFoundException": return [3, 4];
|
|
2187
|
-
case "ValidationException": return [3, 6];
|
|
2188
|
-
case "com.amazonaws.rolesanywhere#ValidationException": return [3, 6];
|
|
2189
|
-
}
|
|
2190
|
-
return [3, 8];
|
|
2191
|
-
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
2192
|
-
case 3: throw _d.sent();
|
|
2193
|
-
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
2194
|
-
case 5: throw _d.sent();
|
|
2195
|
-
case 6: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
2196
|
-
case 7: throw _d.sent();
|
|
2197
|
-
case 8:
|
|
2198
|
-
parsedBody = parsedOutput.body;
|
|
2199
|
-
throwDefaultError({
|
|
2200
|
-
output: output,
|
|
2201
|
-
parsedBody: parsedBody,
|
|
2202
|
-
exceptionCtor: __BaseException,
|
|
2203
|
-
errorCode: errorCode,
|
|
2204
|
-
});
|
|
2205
|
-
_d.label = 9;
|
|
2206
|
-
case 9: return [2];
|
|
2207
|
-
}
|
|
1487
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1488
|
+
};
|
|
1489
|
+
const deserializeAws_restJson1TooManyTagsExceptionResponse = async (parsedOutput, context) => {
|
|
1490
|
+
const contents = map({});
|
|
1491
|
+
const data = parsedOutput.body;
|
|
1492
|
+
if (data.message != null) {
|
|
1493
|
+
contents.message = __expectString(data.message);
|
|
1494
|
+
}
|
|
1495
|
+
const exception = new TooManyTagsException({
|
|
1496
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1497
|
+
...contents,
|
|
2208
1498
|
});
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2221
|
-
});
|
|
2222
|
-
}); };
|
|
2223
|
-
var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2224
|
-
var contents, data, exception;
|
|
2225
|
-
return __generator(this, function (_a) {
|
|
2226
|
-
contents = map({});
|
|
2227
|
-
data = parsedOutput.body;
|
|
2228
|
-
if (data.message != null) {
|
|
2229
|
-
contents.message = __expectString(data.message);
|
|
2230
|
-
}
|
|
2231
|
-
exception = new ResourceNotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2232
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2233
|
-
});
|
|
2234
|
-
}); };
|
|
2235
|
-
var deserializeAws_restJson1TooManyTagsExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2236
|
-
var contents, data, exception;
|
|
2237
|
-
return __generator(this, function (_a) {
|
|
2238
|
-
contents = map({});
|
|
2239
|
-
data = parsedOutput.body;
|
|
2240
|
-
if (data.message != null) {
|
|
2241
|
-
contents.message = __expectString(data.message);
|
|
2242
|
-
}
|
|
2243
|
-
exception = new TooManyTagsException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2244
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2245
|
-
});
|
|
2246
|
-
}); };
|
|
2247
|
-
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2248
|
-
var contents, data, exception;
|
|
2249
|
-
return __generator(this, function (_a) {
|
|
2250
|
-
contents = map({});
|
|
2251
|
-
data = parsedOutput.body;
|
|
2252
|
-
if (data.message != null) {
|
|
2253
|
-
contents.message = __expectString(data.message);
|
|
2254
|
-
}
|
|
2255
|
-
exception = new ValidationException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2256
|
-
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
1499
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1500
|
+
};
|
|
1501
|
+
const deserializeAws_restJson1ValidationExceptionResponse = async (parsedOutput, context) => {
|
|
1502
|
+
const contents = map({});
|
|
1503
|
+
const data = parsedOutput.body;
|
|
1504
|
+
if (data.message != null) {
|
|
1505
|
+
contents.message = __expectString(data.message);
|
|
1506
|
+
}
|
|
1507
|
+
const exception = new ValidationException({
|
|
1508
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1509
|
+
...contents,
|
|
2257
1510
|
});
|
|
2258
|
-
|
|
2259
|
-
|
|
1511
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1512
|
+
};
|
|
1513
|
+
const serializeAws_restJson1ManagedPolicyList = (input, context) => {
|
|
2260
1514
|
return input
|
|
2261
|
-
.filter(
|
|
2262
|
-
.map(
|
|
1515
|
+
.filter((e) => e != null)
|
|
1516
|
+
.map((entry) => {
|
|
2263
1517
|
return entry;
|
|
2264
1518
|
});
|
|
2265
1519
|
};
|
|
2266
|
-
|
|
1520
|
+
const serializeAws_restJson1RoleArnList = (input, context) => {
|
|
2267
1521
|
return input
|
|
2268
|
-
.filter(
|
|
2269
|
-
.map(
|
|
1522
|
+
.filter((e) => e != null)
|
|
1523
|
+
.map((entry) => {
|
|
2270
1524
|
return entry;
|
|
2271
1525
|
});
|
|
2272
1526
|
};
|
|
2273
|
-
|
|
2274
|
-
return
|
|
1527
|
+
const serializeAws_restJson1Source = (input, context) => {
|
|
1528
|
+
return {
|
|
1529
|
+
...(input.sourceData != null && { sourceData: serializeAws_restJson1SourceData(input.sourceData, context) }),
|
|
1530
|
+
...(input.sourceType != null && { sourceType: input.sourceType }),
|
|
1531
|
+
};
|
|
2275
1532
|
};
|
|
2276
|
-
|
|
1533
|
+
const serializeAws_restJson1SourceData = (input, context) => {
|
|
2277
1534
|
return SourceData.visit(input, {
|
|
2278
|
-
acmPcaArn:
|
|
2279
|
-
x509CertificateData:
|
|
2280
|
-
_:
|
|
1535
|
+
acmPcaArn: (value) => ({ acmPcaArn: value }),
|
|
1536
|
+
x509CertificateData: (value) => ({ x509CertificateData: value }),
|
|
1537
|
+
_: (name, value) => ({ name: value }),
|
|
2281
1538
|
});
|
|
2282
1539
|
};
|
|
2283
|
-
|
|
2284
|
-
return
|
|
1540
|
+
const serializeAws_restJson1Tag = (input, context) => {
|
|
1541
|
+
return {
|
|
1542
|
+
...(input.key != null && { key: input.key }),
|
|
1543
|
+
...(input.value != null && { value: input.value }),
|
|
1544
|
+
};
|
|
2285
1545
|
};
|
|
2286
|
-
|
|
1546
|
+
const serializeAws_restJson1TagKeyList = (input, context) => {
|
|
2287
1547
|
return input
|
|
2288
|
-
.filter(
|
|
2289
|
-
.map(
|
|
1548
|
+
.filter((e) => e != null)
|
|
1549
|
+
.map((entry) => {
|
|
2290
1550
|
return entry;
|
|
2291
1551
|
});
|
|
2292
1552
|
};
|
|
2293
|
-
|
|
1553
|
+
const serializeAws_restJson1TagList = (input, context) => {
|
|
2294
1554
|
return input
|
|
2295
|
-
.filter(
|
|
2296
|
-
.map(
|
|
1555
|
+
.filter((e) => e != null)
|
|
1556
|
+
.map((entry) => {
|
|
2297
1557
|
return serializeAws_restJson1Tag(entry, context);
|
|
2298
1558
|
});
|
|
2299
1559
|
};
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
.filter(
|
|
2303
|
-
.map(
|
|
1560
|
+
const deserializeAws_restJson1CredentialSummaries = (output, context) => {
|
|
1561
|
+
const retVal = (output || [])
|
|
1562
|
+
.filter((e) => e != null)
|
|
1563
|
+
.map((entry) => {
|
|
2304
1564
|
if (entry === null) {
|
|
2305
1565
|
return null;
|
|
2306
1566
|
}
|
|
@@ -2308,7 +1568,7 @@ var deserializeAws_restJson1CredentialSummaries = function (output, context) {
|
|
|
2308
1568
|
});
|
|
2309
1569
|
return retVal;
|
|
2310
1570
|
};
|
|
2311
|
-
|
|
1571
|
+
const deserializeAws_restJson1CredentialSummary = (output, context) => {
|
|
2312
1572
|
return {
|
|
2313
1573
|
enabled: __expectBoolean(output.enabled),
|
|
2314
1574
|
failed: __expectBoolean(output.failed),
|
|
@@ -2318,7 +1578,7 @@ var deserializeAws_restJson1CredentialSummary = function (output, context) {
|
|
|
2318
1578
|
x509CertificateData: __expectString(output.x509CertificateData),
|
|
2319
1579
|
};
|
|
2320
1580
|
};
|
|
2321
|
-
|
|
1581
|
+
const deserializeAws_restJson1CrlDetail = (output, context) => {
|
|
2322
1582
|
return {
|
|
2323
1583
|
createdAt: output.createdAt != null ? __expectNonNull(__parseRfc3339DateTime(output.createdAt)) : undefined,
|
|
2324
1584
|
crlArn: __expectString(output.crlArn),
|
|
@@ -2330,10 +1590,10 @@ var deserializeAws_restJson1CrlDetail = function (output, context) {
|
|
|
2330
1590
|
updatedAt: output.updatedAt != null ? __expectNonNull(__parseRfc3339DateTime(output.updatedAt)) : undefined,
|
|
2331
1591
|
};
|
|
2332
1592
|
};
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
.filter(
|
|
2336
|
-
.map(
|
|
1593
|
+
const deserializeAws_restJson1CrlDetails = (output, context) => {
|
|
1594
|
+
const retVal = (output || [])
|
|
1595
|
+
.filter((e) => e != null)
|
|
1596
|
+
.map((entry) => {
|
|
2337
1597
|
if (entry === null) {
|
|
2338
1598
|
return null;
|
|
2339
1599
|
}
|
|
@@ -2341,10 +1601,10 @@ var deserializeAws_restJson1CrlDetails = function (output, context) {
|
|
|
2341
1601
|
});
|
|
2342
1602
|
return retVal;
|
|
2343
1603
|
};
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
.filter(
|
|
2347
|
-
.map(
|
|
1604
|
+
const deserializeAws_restJson1InstanceProperties = (output, context) => {
|
|
1605
|
+
const retVal = (output || [])
|
|
1606
|
+
.filter((e) => e != null)
|
|
1607
|
+
.map((entry) => {
|
|
2348
1608
|
if (entry === null) {
|
|
2349
1609
|
return null;
|
|
2350
1610
|
}
|
|
@@ -2352,27 +1612,28 @@ var deserializeAws_restJson1InstanceProperties = function (output, context) {
|
|
|
2352
1612
|
});
|
|
2353
1613
|
return retVal;
|
|
2354
1614
|
};
|
|
2355
|
-
|
|
1615
|
+
const deserializeAws_restJson1InstanceProperty = (output, context) => {
|
|
2356
1616
|
return {
|
|
2357
1617
|
failed: __expectBoolean(output.failed),
|
|
2358
1618
|
properties: output.properties != null ? deserializeAws_restJson1InstancePropertyMap(output.properties, context) : undefined,
|
|
2359
1619
|
seenAt: output.seenAt != null ? __expectNonNull(__parseRfc3339DateTime(output.seenAt)) : undefined,
|
|
2360
1620
|
};
|
|
2361
1621
|
};
|
|
2362
|
-
|
|
2363
|
-
return Object.entries(output).reduce(
|
|
2364
|
-
var _b;
|
|
2365
|
-
var _c = __read(_a, 2), key = _c[0], value = _c[1];
|
|
1622
|
+
const deserializeAws_restJson1InstancePropertyMap = (output, context) => {
|
|
1623
|
+
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
2366
1624
|
if (value === null) {
|
|
2367
1625
|
return acc;
|
|
2368
1626
|
}
|
|
2369
|
-
return
|
|
1627
|
+
return {
|
|
1628
|
+
...acc,
|
|
1629
|
+
[key]: __expectString(value),
|
|
1630
|
+
};
|
|
2370
1631
|
}, {});
|
|
2371
1632
|
};
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
.filter(
|
|
2375
|
-
.map(
|
|
1633
|
+
const deserializeAws_restJson1ManagedPolicyList = (output, context) => {
|
|
1634
|
+
const retVal = (output || [])
|
|
1635
|
+
.filter((e) => e != null)
|
|
1636
|
+
.map((entry) => {
|
|
2376
1637
|
if (entry === null) {
|
|
2377
1638
|
return null;
|
|
2378
1639
|
}
|
|
@@ -2380,7 +1641,7 @@ var deserializeAws_restJson1ManagedPolicyList = function (output, context) {
|
|
|
2380
1641
|
});
|
|
2381
1642
|
return retVal;
|
|
2382
1643
|
};
|
|
2383
|
-
|
|
1644
|
+
const deserializeAws_restJson1ProfileDetail = (output, context) => {
|
|
2384
1645
|
return {
|
|
2385
1646
|
createdAt: output.createdAt != null ? __expectNonNull(__parseRfc3339DateTime(output.createdAt)) : undefined,
|
|
2386
1647
|
createdBy: __expectString(output.createdBy),
|
|
@@ -2398,10 +1659,10 @@ var deserializeAws_restJson1ProfileDetail = function (output, context) {
|
|
|
2398
1659
|
updatedAt: output.updatedAt != null ? __expectNonNull(__parseRfc3339DateTime(output.updatedAt)) : undefined,
|
|
2399
1660
|
};
|
|
2400
1661
|
};
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
.filter(
|
|
2404
|
-
.map(
|
|
1662
|
+
const deserializeAws_restJson1ProfileDetails = (output, context) => {
|
|
1663
|
+
const retVal = (output || [])
|
|
1664
|
+
.filter((e) => e != null)
|
|
1665
|
+
.map((entry) => {
|
|
2405
1666
|
if (entry === null) {
|
|
2406
1667
|
return null;
|
|
2407
1668
|
}
|
|
@@ -2409,10 +1670,10 @@ var deserializeAws_restJson1ProfileDetails = function (output, context) {
|
|
|
2409
1670
|
});
|
|
2410
1671
|
return retVal;
|
|
2411
1672
|
};
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
.filter(
|
|
2415
|
-
.map(
|
|
1673
|
+
const deserializeAws_restJson1RoleArnList = (output, context) => {
|
|
1674
|
+
const retVal = (output || [])
|
|
1675
|
+
.filter((e) => e != null)
|
|
1676
|
+
.map((entry) => {
|
|
2416
1677
|
if (entry === null) {
|
|
2417
1678
|
return null;
|
|
2418
1679
|
}
|
|
@@ -2420,7 +1681,7 @@ var deserializeAws_restJson1RoleArnList = function (output, context) {
|
|
|
2420
1681
|
});
|
|
2421
1682
|
return retVal;
|
|
2422
1683
|
};
|
|
2423
|
-
|
|
1684
|
+
const deserializeAws_restJson1Source = (output, context) => {
|
|
2424
1685
|
return {
|
|
2425
1686
|
sourceData: output.sourceData != null
|
|
2426
1687
|
? deserializeAws_restJson1SourceData(__expectUnion(output.sourceData), context)
|
|
@@ -2428,7 +1689,7 @@ var deserializeAws_restJson1Source = function (output, context) {
|
|
|
2428
1689
|
sourceType: __expectString(output.sourceType),
|
|
2429
1690
|
};
|
|
2430
1691
|
};
|
|
2431
|
-
|
|
1692
|
+
const deserializeAws_restJson1SourceData = (output, context) => {
|
|
2432
1693
|
if (__expectString(output.acmPcaArn) !== undefined) {
|
|
2433
1694
|
return { acmPcaArn: __expectString(output.acmPcaArn) };
|
|
2434
1695
|
}
|
|
@@ -2437,7 +1698,7 @@ var deserializeAws_restJson1SourceData = function (output, context) {
|
|
|
2437
1698
|
}
|
|
2438
1699
|
return { $unknown: Object.entries(output)[0] };
|
|
2439
1700
|
};
|
|
2440
|
-
|
|
1701
|
+
const deserializeAws_restJson1SubjectDetail = (output, context) => {
|
|
2441
1702
|
return {
|
|
2442
1703
|
createdAt: output.createdAt != null ? __expectNonNull(__parseRfc3339DateTime(output.createdAt)) : undefined,
|
|
2443
1704
|
credentials: output.credentials != null ? deserializeAws_restJson1CredentialSummaries(output.credentials, context) : undefined,
|
|
@@ -2452,10 +1713,10 @@ var deserializeAws_restJson1SubjectDetail = function (output, context) {
|
|
|
2452
1713
|
x509Subject: __expectString(output.x509Subject),
|
|
2453
1714
|
};
|
|
2454
1715
|
};
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
.filter(
|
|
2458
|
-
.map(
|
|
1716
|
+
const deserializeAws_restJson1SubjectSummaries = (output, context) => {
|
|
1717
|
+
const retVal = (output || [])
|
|
1718
|
+
.filter((e) => e != null)
|
|
1719
|
+
.map((entry) => {
|
|
2459
1720
|
if (entry === null) {
|
|
2460
1721
|
return null;
|
|
2461
1722
|
}
|
|
@@ -2463,7 +1724,7 @@ var deserializeAws_restJson1SubjectSummaries = function (output, context) {
|
|
|
2463
1724
|
});
|
|
2464
1725
|
return retVal;
|
|
2465
1726
|
};
|
|
2466
|
-
|
|
1727
|
+
const deserializeAws_restJson1SubjectSummary = (output, context) => {
|
|
2467
1728
|
return {
|
|
2468
1729
|
createdAt: output.createdAt != null ? __expectNonNull(__parseRfc3339DateTime(output.createdAt)) : undefined,
|
|
2469
1730
|
enabled: __expectBoolean(output.enabled),
|
|
@@ -2474,16 +1735,16 @@ var deserializeAws_restJson1SubjectSummary = function (output, context) {
|
|
|
2474
1735
|
x509Subject: __expectString(output.x509Subject),
|
|
2475
1736
|
};
|
|
2476
1737
|
};
|
|
2477
|
-
|
|
1738
|
+
const deserializeAws_restJson1Tag = (output, context) => {
|
|
2478
1739
|
return {
|
|
2479
1740
|
key: __expectString(output.key),
|
|
2480
1741
|
value: __expectString(output.value),
|
|
2481
1742
|
};
|
|
2482
1743
|
};
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
.filter(
|
|
2486
|
-
.map(
|
|
1744
|
+
const deserializeAws_restJson1TagList = (output, context) => {
|
|
1745
|
+
const retVal = (output || [])
|
|
1746
|
+
.filter((e) => e != null)
|
|
1747
|
+
.map((entry) => {
|
|
2487
1748
|
if (entry === null) {
|
|
2488
1749
|
return null;
|
|
2489
1750
|
}
|
|
@@ -2491,7 +1752,7 @@ var deserializeAws_restJson1TagList = function (output, context) {
|
|
|
2491
1752
|
});
|
|
2492
1753
|
return retVal;
|
|
2493
1754
|
};
|
|
2494
|
-
|
|
1755
|
+
const deserializeAws_restJson1TrustAnchorDetail = (output, context) => {
|
|
2495
1756
|
return {
|
|
2496
1757
|
createdAt: output.createdAt != null ? __expectNonNull(__parseRfc3339DateTime(output.createdAt)) : undefined,
|
|
2497
1758
|
enabled: __expectBoolean(output.enabled),
|
|
@@ -2502,10 +1763,10 @@ var deserializeAws_restJson1TrustAnchorDetail = function (output, context) {
|
|
|
2502
1763
|
updatedAt: output.updatedAt != null ? __expectNonNull(__parseRfc3339DateTime(output.updatedAt)) : undefined,
|
|
2503
1764
|
};
|
|
2504
1765
|
};
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
.filter(
|
|
2508
|
-
.map(
|
|
1766
|
+
const deserializeAws_restJson1TrustAnchorDetails = (output, context) => {
|
|
1767
|
+
const retVal = (output || [])
|
|
1768
|
+
.filter((e) => e != null)
|
|
1769
|
+
.map((entry) => {
|
|
2509
1770
|
if (entry === null) {
|
|
2510
1771
|
return null;
|
|
2511
1772
|
}
|
|
@@ -2513,57 +1774,39 @@ var deserializeAws_restJson1TrustAnchorDetails = function (output, context) {
|
|
|
2513
1774
|
});
|
|
2514
1775
|
return retVal;
|
|
2515
1776
|
};
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
});
|
|
2524
|
-
};
|
|
2525
|
-
var collectBody = function (streamBody, context) {
|
|
2526
|
-
if (streamBody === void 0) { streamBody = new Uint8Array(); }
|
|
1777
|
+
const deserializeMetadata = (output) => ({
|
|
1778
|
+
httpStatusCode: output.statusCode,
|
|
1779
|
+
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
1780
|
+
extendedRequestId: output.headers["x-amz-id-2"],
|
|
1781
|
+
cfId: output.headers["x-amz-cf-id"],
|
|
1782
|
+
});
|
|
1783
|
+
const collectBody = (streamBody = new Uint8Array(), context) => {
|
|
2527
1784
|
if (streamBody instanceof Uint8Array) {
|
|
2528
1785
|
return Promise.resolve(streamBody);
|
|
2529
1786
|
}
|
|
2530
1787
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
2531
1788
|
};
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
1789
|
+
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
1790
|
+
const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
1791
|
+
value !== null &&
|
|
1792
|
+
value !== "" &&
|
|
1793
|
+
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
1794
|
+
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
1795
|
+
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
1796
|
+
if (encoded.length) {
|
|
1797
|
+
return JSON.parse(encoded);
|
|
1798
|
+
}
|
|
1799
|
+
return {};
|
|
1800
|
+
});
|
|
1801
|
+
const parseErrorBody = async (errorBody, context) => {
|
|
1802
|
+
const value = await parseBody(errorBody, context);
|
|
1803
|
+
value.message = value.message ?? value.Message;
|
|
1804
|
+
return value;
|
|
2541
1805
|
};
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
}
|
|
2547
|
-
return {};
|
|
2548
|
-
});
|
|
2549
|
-
};
|
|
2550
|
-
var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2551
|
-
var value;
|
|
2552
|
-
var _a;
|
|
2553
|
-
return __generator(this, function (_b) {
|
|
2554
|
-
switch (_b.label) {
|
|
2555
|
-
case 0: return [4, parseBody(errorBody, context)];
|
|
2556
|
-
case 1:
|
|
2557
|
-
value = _b.sent();
|
|
2558
|
-
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
2559
|
-
return [2, value];
|
|
2560
|
-
}
|
|
2561
|
-
});
|
|
2562
|
-
}); };
|
|
2563
|
-
var loadRestJsonErrorCode = function (output, data) {
|
|
2564
|
-
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
2565
|
-
var sanitizeErrorCode = function (rawValue) {
|
|
2566
|
-
var cleanValue = rawValue;
|
|
1806
|
+
const loadRestJsonErrorCode = (output, data) => {
|
|
1807
|
+
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
1808
|
+
const sanitizeErrorCode = (rawValue) => {
|
|
1809
|
+
let cleanValue = rawValue;
|
|
2567
1810
|
if (typeof cleanValue === "number") {
|
|
2568
1811
|
cleanValue = cleanValue.toString();
|
|
2569
1812
|
}
|
|
@@ -2578,7 +1821,7 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
2578
1821
|
}
|
|
2579
1822
|
return cleanValue;
|
|
2580
1823
|
};
|
|
2581
|
-
|
|
1824
|
+
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
2582
1825
|
if (headerKey !== undefined) {
|
|
2583
1826
|
return sanitizeErrorCode(output.headers[headerKey]);
|
|
2584
1827
|
}
|