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