@aws-sdk/client-support-app 3.183.0 → 3.185.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist-cjs/protocols/Aws_restJson1.js +2 -2
- package/dist-es/SupportApp.js +45 -38
- package/dist-es/SupportAppClient.js +28 -22
- package/dist-es/commands/CreateSlackChannelConfigurationCommand.js +28 -21
- package/dist-es/commands/DeleteAccountAliasCommand.js +28 -21
- package/dist-es/commands/DeleteSlackChannelConfigurationCommand.js +28 -21
- package/dist-es/commands/DeleteSlackWorkspaceConfigurationCommand.js +28 -21
- package/dist-es/commands/GetAccountAliasCommand.js +28 -21
- package/dist-es/commands/ListSlackChannelConfigurationsCommand.js +28 -21
- package/dist-es/commands/ListSlackWorkspaceConfigurationsCommand.js +28 -21
- package/dist-es/commands/PutAccountAliasCommand.js +28 -21
- package/dist-es/commands/UpdateSlackChannelConfigurationCommand.js +28 -21
- package/dist-es/endpoints.js +8 -8
- package/dist-es/models/SupportAppServiceException.js +10 -5
- package/dist-es/models/models_0.js +87 -126
- package/dist-es/pagination/ListSlackChannelConfigurationsPaginator.js +67 -24
- package/dist-es/pagination/ListSlackWorkspaceConfigurationsPaginator.js +67 -24
- package/dist-es/protocols/Aws_restJson1.js +926 -663
- 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 +5 -5
|
@@ -1,657 +1,902 @@
|
|
|
1
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
1
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
2
3
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map as __map, throwDefaultError, } from "@aws-sdk/smithy-client";
|
|
3
4
|
import { AccessDeniedException, ConflictException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ValidationException, } from "../models/models_0";
|
|
4
5
|
import { SupportAppServiceException as __BaseException } from "../models/SupportAppServiceException";
|
|
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
|
-
|
|
30
|
-
headers,
|
|
31
|
-
path: resolvedPath,
|
|
32
|
-
body,
|
|
6
|
+
export var serializeAws_restJson1CreateSlackChannelConfigurationCommand = 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 || "") +
|
|
17
|
+
"/control/create-slack-channel-configuration";
|
|
18
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.channelId != null && { channelId: input.channelId })), (input.channelName != null && { channelName: input.channelName })), (input.channelRoleArn != null && { channelRoleArn: input.channelRoleArn })), (input.notifyOnAddCorrespondenceToCase != null && {
|
|
19
|
+
notifyOnAddCorrespondenceToCase: input.notifyOnAddCorrespondenceToCase,
|
|
20
|
+
})), (input.notifyOnCaseSeverity != null && { notifyOnCaseSeverity: input.notifyOnCaseSeverity })), (input.notifyOnCreateOrReopenCase != null && { notifyOnCreateOrReopenCase: input.notifyOnCreateOrReopenCase })), (input.notifyOnResolveCase != null && { notifyOnResolveCase: input.notifyOnResolveCase })), (input.teamId != null && { teamId: input.teamId })));
|
|
21
|
+
return [2, new __HttpRequest({
|
|
22
|
+
protocol: protocol,
|
|
23
|
+
hostname: hostname,
|
|
24
|
+
port: port,
|
|
25
|
+
method: "POST",
|
|
26
|
+
headers: headers,
|
|
27
|
+
path: resolvedPath,
|
|
28
|
+
body: body,
|
|
29
|
+
})];
|
|
30
|
+
}
|
|
33
31
|
});
|
|
34
|
-
};
|
|
35
|
-
export
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
32
|
+
}); };
|
|
33
|
+
export var serializeAws_restJson1DeleteAccountAliasCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
34
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
35
|
+
return __generator(this, function (_c) {
|
|
36
|
+
switch (_c.label) {
|
|
37
|
+
case 0: return [4, context.endpoint()];
|
|
38
|
+
case 1:
|
|
39
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
40
|
+
headers = {
|
|
41
|
+
"content-type": "application/json",
|
|
42
|
+
};
|
|
43
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/control/delete-account-alias";
|
|
44
|
+
body = "";
|
|
45
|
+
return [2, new __HttpRequest({
|
|
46
|
+
protocol: protocol,
|
|
47
|
+
hostname: hostname,
|
|
48
|
+
port: port,
|
|
49
|
+
method: "POST",
|
|
50
|
+
headers: headers,
|
|
51
|
+
path: resolvedPath,
|
|
52
|
+
body: body,
|
|
53
|
+
})];
|
|
54
|
+
}
|
|
51
55
|
});
|
|
52
|
-
};
|
|
53
|
-
export
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
56
|
+
}); };
|
|
57
|
+
export var serializeAws_restJson1DeleteSlackChannelConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
58
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
59
|
+
return __generator(this, function (_c) {
|
|
60
|
+
switch (_c.label) {
|
|
61
|
+
case 0: return [4, context.endpoint()];
|
|
62
|
+
case 1:
|
|
63
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
64
|
+
headers = {
|
|
65
|
+
"content-type": "application/json",
|
|
66
|
+
};
|
|
67
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
68
|
+
"/control/delete-slack-channel-configuration";
|
|
69
|
+
body = JSON.stringify(__assign(__assign({}, (input.channelId != null && { channelId: input.channelId })), (input.teamId != null && { teamId: input.teamId })));
|
|
70
|
+
return [2, new __HttpRequest({
|
|
71
|
+
protocol: protocol,
|
|
72
|
+
hostname: hostname,
|
|
73
|
+
port: port,
|
|
74
|
+
method: "POST",
|
|
75
|
+
headers: headers,
|
|
76
|
+
path: resolvedPath,
|
|
77
|
+
body: body,
|
|
78
|
+
})];
|
|
79
|
+
}
|
|
73
80
|
});
|
|
74
|
-
};
|
|
75
|
-
export
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
81
|
+
}); };
|
|
82
|
+
export var serializeAws_restJson1DeleteSlackWorkspaceConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
83
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
84
|
+
return __generator(this, function (_c) {
|
|
85
|
+
switch (_c.label) {
|
|
86
|
+
case 0: return [4, context.endpoint()];
|
|
87
|
+
case 1:
|
|
88
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
89
|
+
headers = {
|
|
90
|
+
"content-type": "application/json",
|
|
91
|
+
};
|
|
92
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
93
|
+
"/control/delete-slack-workspace-configuration";
|
|
94
|
+
body = JSON.stringify(__assign({}, (input.teamId != null && { teamId: input.teamId })));
|
|
95
|
+
return [2, new __HttpRequest({
|
|
96
|
+
protocol: protocol,
|
|
97
|
+
hostname: hostname,
|
|
98
|
+
port: port,
|
|
99
|
+
method: "POST",
|
|
100
|
+
headers: headers,
|
|
101
|
+
path: resolvedPath,
|
|
102
|
+
body: body,
|
|
103
|
+
})];
|
|
104
|
+
}
|
|
94
105
|
});
|
|
95
|
-
};
|
|
96
|
-
export
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
106
|
+
}); };
|
|
107
|
+
export var serializeAws_restJson1GetAccountAliasCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
108
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
109
|
+
return __generator(this, function (_c) {
|
|
110
|
+
switch (_c.label) {
|
|
111
|
+
case 0: return [4, context.endpoint()];
|
|
112
|
+
case 1:
|
|
113
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
114
|
+
headers = {
|
|
115
|
+
"content-type": "application/json",
|
|
116
|
+
};
|
|
117
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/control/get-account-alias";
|
|
118
|
+
body = "";
|
|
119
|
+
return [2, new __HttpRequest({
|
|
120
|
+
protocol: protocol,
|
|
121
|
+
hostname: hostname,
|
|
122
|
+
port: port,
|
|
123
|
+
method: "POST",
|
|
124
|
+
headers: headers,
|
|
125
|
+
path: resolvedPath,
|
|
126
|
+
body: body,
|
|
127
|
+
})];
|
|
128
|
+
}
|
|
112
129
|
});
|
|
113
|
-
};
|
|
114
|
-
export
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
130
|
+
}); };
|
|
131
|
+
export var serializeAws_restJson1ListSlackChannelConfigurationsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
132
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
133
|
+
return __generator(this, function (_c) {
|
|
134
|
+
switch (_c.label) {
|
|
135
|
+
case 0: return [4, context.endpoint()];
|
|
136
|
+
case 1:
|
|
137
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
138
|
+
headers = {
|
|
139
|
+
"content-type": "application/json",
|
|
140
|
+
};
|
|
141
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
142
|
+
"/control/list-slack-channel-configurations";
|
|
143
|
+
body = JSON.stringify(__assign({}, (input.nextToken != null && { nextToken: input.nextToken })));
|
|
144
|
+
return [2, new __HttpRequest({
|
|
145
|
+
protocol: protocol,
|
|
146
|
+
hostname: hostname,
|
|
147
|
+
port: port,
|
|
148
|
+
method: "POST",
|
|
149
|
+
headers: headers,
|
|
150
|
+
path: resolvedPath,
|
|
151
|
+
body: body,
|
|
152
|
+
})];
|
|
153
|
+
}
|
|
133
154
|
});
|
|
134
|
-
};
|
|
135
|
-
export
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
155
|
+
}); };
|
|
156
|
+
export var serializeAws_restJson1ListSlackWorkspaceConfigurationsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
157
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
158
|
+
return __generator(this, function (_c) {
|
|
159
|
+
switch (_c.label) {
|
|
160
|
+
case 0: return [4, context.endpoint()];
|
|
161
|
+
case 1:
|
|
162
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
163
|
+
headers = {
|
|
164
|
+
"content-type": "application/json",
|
|
165
|
+
};
|
|
166
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
167
|
+
"/control/list-slack-workspace-configurations";
|
|
168
|
+
body = JSON.stringify(__assign({}, (input.nextToken != null && { nextToken: input.nextToken })));
|
|
169
|
+
return [2, new __HttpRequest({
|
|
170
|
+
protocol: protocol,
|
|
171
|
+
hostname: hostname,
|
|
172
|
+
port: port,
|
|
173
|
+
method: "POST",
|
|
174
|
+
headers: headers,
|
|
175
|
+
path: resolvedPath,
|
|
176
|
+
body: body,
|
|
177
|
+
})];
|
|
178
|
+
}
|
|
154
179
|
});
|
|
155
|
-
};
|
|
156
|
-
export
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
180
|
+
}); };
|
|
181
|
+
export var serializeAws_restJson1PutAccountAliasCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
182
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
183
|
+
return __generator(this, function (_c) {
|
|
184
|
+
switch (_c.label) {
|
|
185
|
+
case 0: return [4, context.endpoint()];
|
|
186
|
+
case 1:
|
|
187
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
188
|
+
headers = {
|
|
189
|
+
"content-type": "application/json",
|
|
190
|
+
};
|
|
191
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/control/put-account-alias";
|
|
192
|
+
body = JSON.stringify(__assign({}, (input.accountAlias != null && { accountAlias: input.accountAlias })));
|
|
193
|
+
return [2, new __HttpRequest({
|
|
194
|
+
protocol: protocol,
|
|
195
|
+
hostname: hostname,
|
|
196
|
+
port: port,
|
|
197
|
+
method: "POST",
|
|
198
|
+
headers: headers,
|
|
199
|
+
path: resolvedPath,
|
|
200
|
+
body: body,
|
|
201
|
+
})];
|
|
202
|
+
}
|
|
174
203
|
});
|
|
175
|
-
};
|
|
176
|
-
export
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
headers,
|
|
202
|
-
path: resolvedPath,
|
|
203
|
-
body,
|
|
204
|
+
}); };
|
|
205
|
+
export var serializeAws_restJson1UpdateSlackChannelConfigurationCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
206
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
207
|
+
return __generator(this, function (_c) {
|
|
208
|
+
switch (_c.label) {
|
|
209
|
+
case 0: return [4, context.endpoint()];
|
|
210
|
+
case 1:
|
|
211
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
212
|
+
headers = {
|
|
213
|
+
"content-type": "application/json",
|
|
214
|
+
};
|
|
215
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") +
|
|
216
|
+
"/control/update-slack-channel-configuration";
|
|
217
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.channelId != null && { channelId: input.channelId })), (input.channelName != null && { channelName: input.channelName })), (input.channelRoleArn != null && { channelRoleArn: input.channelRoleArn })), (input.notifyOnAddCorrespondenceToCase != null && {
|
|
218
|
+
notifyOnAddCorrespondenceToCase: input.notifyOnAddCorrespondenceToCase,
|
|
219
|
+
})), (input.notifyOnCaseSeverity != null && { notifyOnCaseSeverity: input.notifyOnCaseSeverity })), (input.notifyOnCreateOrReopenCase != null && { notifyOnCreateOrReopenCase: input.notifyOnCreateOrReopenCase })), (input.notifyOnResolveCase != null && { notifyOnResolveCase: input.notifyOnResolveCase })), (input.teamId != null && { teamId: input.teamId })));
|
|
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
|
+
}
|
|
204
230
|
});
|
|
205
|
-
};
|
|
206
|
-
export
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
231
|
+
}); };
|
|
232
|
+
export var deserializeAws_restJson1CreateSlackChannelConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
233
|
+
var contents;
|
|
234
|
+
return __generator(this, function (_a) {
|
|
235
|
+
switch (_a.label) {
|
|
236
|
+
case 0:
|
|
237
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
238
|
+
return [2, deserializeAws_restJson1CreateSlackChannelConfigurationCommandError(output, context)];
|
|
239
|
+
}
|
|
240
|
+
contents = map({
|
|
241
|
+
$metadata: deserializeMetadata(output),
|
|
242
|
+
});
|
|
243
|
+
return [4, collectBody(output.body, context)];
|
|
244
|
+
case 1:
|
|
245
|
+
_a.sent();
|
|
246
|
+
return [2, contents];
|
|
247
|
+
}
|
|
212
248
|
});
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
249
|
+
}); };
|
|
250
|
+
var deserializeAws_restJson1CreateSlackChannelConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
251
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
252
|
+
var _c;
|
|
253
|
+
return __generator(this, function (_d) {
|
|
254
|
+
switch (_d.label) {
|
|
255
|
+
case 0:
|
|
256
|
+
_a = [__assign({}, output)];
|
|
257
|
+
_c = {};
|
|
258
|
+
return [4, parseErrorBody(output.body, context)];
|
|
259
|
+
case 1:
|
|
260
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
261
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
262
|
+
_b = errorCode;
|
|
263
|
+
switch (_b) {
|
|
264
|
+
case "AccessDeniedException": return [3, 2];
|
|
265
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
266
|
+
case "ConflictException": return [3, 4];
|
|
267
|
+
case "com.amazonaws.supportapp#ConflictException": return [3, 4];
|
|
268
|
+
case "InternalServerException": return [3, 6];
|
|
269
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 6];
|
|
270
|
+
case "ServiceQuotaExceededException": return [3, 8];
|
|
271
|
+
case "com.amazonaws.supportapp#ServiceQuotaExceededException": return [3, 8];
|
|
272
|
+
case "ValidationException": return [3, 10];
|
|
273
|
+
case "com.amazonaws.supportapp#ValidationException": return [3, 10];
|
|
274
|
+
}
|
|
275
|
+
return [3, 12];
|
|
276
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
277
|
+
case 3: throw _d.sent();
|
|
278
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
279
|
+
case 5: throw _d.sent();
|
|
280
|
+
case 6: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
281
|
+
case 7: throw _d.sent();
|
|
282
|
+
case 8: return [4, deserializeAws_restJson1ServiceQuotaExceededExceptionResponse(parsedOutput, context)];
|
|
283
|
+
case 9: throw _d.sent();
|
|
284
|
+
case 10: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
285
|
+
case 11: throw _d.sent();
|
|
286
|
+
case 12:
|
|
287
|
+
parsedBody = parsedOutput.body;
|
|
288
|
+
throwDefaultError({
|
|
289
|
+
output: output,
|
|
290
|
+
parsedBody: parsedBody,
|
|
291
|
+
exceptionCtor: __BaseException,
|
|
292
|
+
errorCode: errorCode,
|
|
293
|
+
});
|
|
294
|
+
_d.label = 13;
|
|
295
|
+
case 13: return [2];
|
|
296
|
+
}
|
|
254
297
|
});
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
case "com.amazonaws.supportapp#ResourceNotFoundException":
|
|
273
|
-
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
274
|
-
default:
|
|
275
|
-
const parsedBody = parsedOutput.body;
|
|
276
|
-
throwDefaultError({
|
|
277
|
-
output,
|
|
278
|
-
parsedBody,
|
|
279
|
-
exceptionCtor: __BaseException,
|
|
280
|
-
errorCode,
|
|
281
|
-
});
|
|
282
|
-
}
|
|
283
|
-
};
|
|
284
|
-
export const deserializeAws_restJson1DeleteSlackChannelConfigurationCommand = async (output, context) => {
|
|
285
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
286
|
-
return deserializeAws_restJson1DeleteSlackChannelConfigurationCommandError(output, context);
|
|
287
|
-
}
|
|
288
|
-
const contents = map({
|
|
289
|
-
$metadata: deserializeMetadata(output),
|
|
298
|
+
}); };
|
|
299
|
+
export var deserializeAws_restJson1DeleteAccountAliasCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
300
|
+
var contents;
|
|
301
|
+
return __generator(this, function (_a) {
|
|
302
|
+
switch (_a.label) {
|
|
303
|
+
case 0:
|
|
304
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
305
|
+
return [2, deserializeAws_restJson1DeleteAccountAliasCommandError(output, context)];
|
|
306
|
+
}
|
|
307
|
+
contents = map({
|
|
308
|
+
$metadata: deserializeMetadata(output),
|
|
309
|
+
});
|
|
310
|
+
return [4, collectBody(output.body, context)];
|
|
311
|
+
case 1:
|
|
312
|
+
_a.sent();
|
|
313
|
+
return [2, contents];
|
|
314
|
+
}
|
|
290
315
|
});
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
throw
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
$metadata: deserializeMetadata(output),
|
|
316
|
+
}); };
|
|
317
|
+
var deserializeAws_restJson1DeleteAccountAliasCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
318
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
319
|
+
var _c;
|
|
320
|
+
return __generator(this, function (_d) {
|
|
321
|
+
switch (_d.label) {
|
|
322
|
+
case 0:
|
|
323
|
+
_a = [__assign({}, output)];
|
|
324
|
+
_c = {};
|
|
325
|
+
return [4, parseErrorBody(output.body, context)];
|
|
326
|
+
case 1:
|
|
327
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
328
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
329
|
+
_b = errorCode;
|
|
330
|
+
switch (_b) {
|
|
331
|
+
case "AccessDeniedException": return [3, 2];
|
|
332
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
333
|
+
case "InternalServerException": return [3, 4];
|
|
334
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 4];
|
|
335
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
336
|
+
case "com.amazonaws.supportapp#ResourceNotFoundException": return [3, 6];
|
|
337
|
+
}
|
|
338
|
+
return [3, 8];
|
|
339
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
340
|
+
case 3: throw _d.sent();
|
|
341
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
342
|
+
case 5: throw _d.sent();
|
|
343
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
344
|
+
case 7: throw _d.sent();
|
|
345
|
+
case 8:
|
|
346
|
+
parsedBody = parsedOutput.body;
|
|
347
|
+
throwDefaultError({
|
|
348
|
+
output: output,
|
|
349
|
+
parsedBody: parsedBody,
|
|
350
|
+
exceptionCtor: __BaseException,
|
|
351
|
+
errorCode: errorCode,
|
|
352
|
+
});
|
|
353
|
+
_d.label = 9;
|
|
354
|
+
case 9: return [2];
|
|
355
|
+
}
|
|
332
356
|
});
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
case "com.amazonaws.supportapp#InternalServerException":
|
|
351
|
-
throw await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context);
|
|
352
|
-
case "ResourceNotFoundException":
|
|
353
|
-
case "com.amazonaws.supportapp#ResourceNotFoundException":
|
|
354
|
-
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
355
|
-
case "ValidationException":
|
|
356
|
-
case "com.amazonaws.supportapp#ValidationException":
|
|
357
|
-
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
358
|
-
default:
|
|
359
|
-
const parsedBody = parsedOutput.body;
|
|
360
|
-
throwDefaultError({
|
|
361
|
-
output,
|
|
362
|
-
parsedBody,
|
|
363
|
-
exceptionCtor: __BaseException,
|
|
364
|
-
errorCode,
|
|
365
|
-
});
|
|
366
|
-
}
|
|
367
|
-
};
|
|
368
|
-
export const deserializeAws_restJson1GetAccountAliasCommand = async (output, context) => {
|
|
369
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
370
|
-
return deserializeAws_restJson1GetAccountAliasCommandError(output, context);
|
|
371
|
-
}
|
|
372
|
-
const contents = map({
|
|
373
|
-
$metadata: deserializeMetadata(output),
|
|
357
|
+
}); };
|
|
358
|
+
export var deserializeAws_restJson1DeleteSlackChannelConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
359
|
+
var contents;
|
|
360
|
+
return __generator(this, function (_a) {
|
|
361
|
+
switch (_a.label) {
|
|
362
|
+
case 0:
|
|
363
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
364
|
+
return [2, deserializeAws_restJson1DeleteSlackChannelConfigurationCommandError(output, context)];
|
|
365
|
+
}
|
|
366
|
+
contents = map({
|
|
367
|
+
$metadata: deserializeMetadata(output),
|
|
368
|
+
});
|
|
369
|
+
return [4, collectBody(output.body, context)];
|
|
370
|
+
case 1:
|
|
371
|
+
_a.sent();
|
|
372
|
+
return [2, contents];
|
|
373
|
+
}
|
|
374
374
|
});
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
return
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
}
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
375
|
+
}); };
|
|
376
|
+
var deserializeAws_restJson1DeleteSlackChannelConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
377
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
378
|
+
var _c;
|
|
379
|
+
return __generator(this, function (_d) {
|
|
380
|
+
switch (_d.label) {
|
|
381
|
+
case 0:
|
|
382
|
+
_a = [__assign({}, output)];
|
|
383
|
+
_c = {};
|
|
384
|
+
return [4, parseErrorBody(output.body, context)];
|
|
385
|
+
case 1:
|
|
386
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
387
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
388
|
+
_b = errorCode;
|
|
389
|
+
switch (_b) {
|
|
390
|
+
case "AccessDeniedException": return [3, 2];
|
|
391
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
392
|
+
case "ConflictException": return [3, 4];
|
|
393
|
+
case "com.amazonaws.supportapp#ConflictException": return [3, 4];
|
|
394
|
+
case "InternalServerException": return [3, 6];
|
|
395
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 6];
|
|
396
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
397
|
+
case "com.amazonaws.supportapp#ResourceNotFoundException": return [3, 8];
|
|
398
|
+
case "ValidationException": return [3, 10];
|
|
399
|
+
case "com.amazonaws.supportapp#ValidationException": return [3, 10];
|
|
400
|
+
}
|
|
401
|
+
return [3, 12];
|
|
402
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
403
|
+
case 3: throw _d.sent();
|
|
404
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
405
|
+
case 5: throw _d.sent();
|
|
406
|
+
case 6: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
407
|
+
case 7: throw _d.sent();
|
|
408
|
+
case 8: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
409
|
+
case 9: throw _d.sent();
|
|
410
|
+
case 10: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
411
|
+
case 11: throw _d.sent();
|
|
412
|
+
case 12:
|
|
413
|
+
parsedBody = parsedOutput.body;
|
|
414
|
+
throwDefaultError({
|
|
415
|
+
output: output,
|
|
416
|
+
parsedBody: parsedBody,
|
|
417
|
+
exceptionCtor: __BaseException,
|
|
418
|
+
errorCode: errorCode,
|
|
419
|
+
});
|
|
420
|
+
_d.label = 13;
|
|
421
|
+
case 13: return [2];
|
|
422
|
+
}
|
|
407
423
|
});
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
}
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
case "com.amazonaws.supportapp#AccessDeniedException":
|
|
426
|
-
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
427
|
-
case "InternalServerException":
|
|
428
|
-
case "com.amazonaws.supportapp#InternalServerException":
|
|
429
|
-
throw await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context);
|
|
430
|
-
default:
|
|
431
|
-
const parsedBody = parsedOutput.body;
|
|
432
|
-
throwDefaultError({
|
|
433
|
-
output,
|
|
434
|
-
parsedBody,
|
|
435
|
-
exceptionCtor: __BaseException,
|
|
436
|
-
errorCode,
|
|
437
|
-
});
|
|
438
|
-
}
|
|
439
|
-
};
|
|
440
|
-
export const deserializeAws_restJson1ListSlackWorkspaceConfigurationsCommand = async (output, context) => {
|
|
441
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
442
|
-
return deserializeAws_restJson1ListSlackWorkspaceConfigurationsCommandError(output, context);
|
|
443
|
-
}
|
|
444
|
-
const contents = map({
|
|
445
|
-
$metadata: deserializeMetadata(output),
|
|
424
|
+
}); };
|
|
425
|
+
export var deserializeAws_restJson1DeleteSlackWorkspaceConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
426
|
+
var contents;
|
|
427
|
+
return __generator(this, function (_a) {
|
|
428
|
+
switch (_a.label) {
|
|
429
|
+
case 0:
|
|
430
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
431
|
+
return [2, deserializeAws_restJson1DeleteSlackWorkspaceConfigurationCommandError(output, context)];
|
|
432
|
+
}
|
|
433
|
+
contents = map({
|
|
434
|
+
$metadata: deserializeMetadata(output),
|
|
435
|
+
});
|
|
436
|
+
return [4, collectBody(output.body, context)];
|
|
437
|
+
case 1:
|
|
438
|
+
_a.sent();
|
|
439
|
+
return [2, contents];
|
|
440
|
+
}
|
|
446
441
|
});
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
};
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
442
|
+
}); };
|
|
443
|
+
var deserializeAws_restJson1DeleteSlackWorkspaceConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
444
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
445
|
+
var _c;
|
|
446
|
+
return __generator(this, function (_d) {
|
|
447
|
+
switch (_d.label) {
|
|
448
|
+
case 0:
|
|
449
|
+
_a = [__assign({}, output)];
|
|
450
|
+
_c = {};
|
|
451
|
+
return [4, parseErrorBody(output.body, context)];
|
|
452
|
+
case 1:
|
|
453
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
454
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
455
|
+
_b = errorCode;
|
|
456
|
+
switch (_b) {
|
|
457
|
+
case "AccessDeniedException": return [3, 2];
|
|
458
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
459
|
+
case "ConflictException": return [3, 4];
|
|
460
|
+
case "com.amazonaws.supportapp#ConflictException": return [3, 4];
|
|
461
|
+
case "InternalServerException": return [3, 6];
|
|
462
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 6];
|
|
463
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
464
|
+
case "com.amazonaws.supportapp#ResourceNotFoundException": return [3, 8];
|
|
465
|
+
case "ValidationException": return [3, 10];
|
|
466
|
+
case "com.amazonaws.supportapp#ValidationException": return [3, 10];
|
|
467
|
+
}
|
|
468
|
+
return [3, 12];
|
|
469
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
470
|
+
case 3: throw _d.sent();
|
|
471
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
472
|
+
case 5: throw _d.sent();
|
|
473
|
+
case 6: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
474
|
+
case 7: throw _d.sent();
|
|
475
|
+
case 8: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
476
|
+
case 9: throw _d.sent();
|
|
477
|
+
case 10: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
478
|
+
case 11: throw _d.sent();
|
|
479
|
+
case 12:
|
|
480
|
+
parsedBody = parsedOutput.body;
|
|
481
|
+
throwDefaultError({
|
|
482
|
+
output: output,
|
|
483
|
+
parsedBody: parsedBody,
|
|
484
|
+
exceptionCtor: __BaseException,
|
|
485
|
+
errorCode: errorCode,
|
|
486
|
+
});
|
|
487
|
+
_d.label = 13;
|
|
488
|
+
case 13: return [2];
|
|
489
|
+
}
|
|
485
490
|
});
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
output,
|
|
509
|
-
parsedBody,
|
|
510
|
-
exceptionCtor: __BaseException,
|
|
511
|
-
errorCode,
|
|
512
|
-
});
|
|
513
|
-
}
|
|
514
|
-
};
|
|
515
|
-
export const deserializeAws_restJson1UpdateSlackChannelConfigurationCommand = async (output, context) => {
|
|
516
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
517
|
-
return deserializeAws_restJson1UpdateSlackChannelConfigurationCommandError(output, context);
|
|
518
|
-
}
|
|
519
|
-
const contents = map({
|
|
520
|
-
$metadata: deserializeMetadata(output),
|
|
491
|
+
}); };
|
|
492
|
+
export var deserializeAws_restJson1GetAccountAliasCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
493
|
+
var contents, data, _a, _b;
|
|
494
|
+
return __generator(this, function (_c) {
|
|
495
|
+
switch (_c.label) {
|
|
496
|
+
case 0:
|
|
497
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
498
|
+
return [2, deserializeAws_restJson1GetAccountAliasCommandError(output, context)];
|
|
499
|
+
}
|
|
500
|
+
contents = map({
|
|
501
|
+
$metadata: deserializeMetadata(output),
|
|
502
|
+
});
|
|
503
|
+
_a = __expectNonNull;
|
|
504
|
+
_b = __expectObject;
|
|
505
|
+
return [4, parseBody(output.body, context)];
|
|
506
|
+
case 1:
|
|
507
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
508
|
+
if (data.accountAlias != null) {
|
|
509
|
+
contents.accountAlias = __expectString(data.accountAlias);
|
|
510
|
+
}
|
|
511
|
+
return [2, contents];
|
|
512
|
+
}
|
|
521
513
|
});
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
555
|
-
switch (errorCode) {
|
|
556
|
-
case "AccessDeniedException":
|
|
557
|
-
case "com.amazonaws.supportapp#AccessDeniedException":
|
|
558
|
-
throw await deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context);
|
|
559
|
-
case "ConflictException":
|
|
560
|
-
case "com.amazonaws.supportapp#ConflictException":
|
|
561
|
-
throw await deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context);
|
|
562
|
-
case "InternalServerException":
|
|
563
|
-
case "com.amazonaws.supportapp#InternalServerException":
|
|
564
|
-
throw await deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context);
|
|
565
|
-
case "ResourceNotFoundException":
|
|
566
|
-
case "com.amazonaws.supportapp#ResourceNotFoundException":
|
|
567
|
-
throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
|
|
568
|
-
case "ValidationException":
|
|
569
|
-
case "com.amazonaws.supportapp#ValidationException":
|
|
570
|
-
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
571
|
-
default:
|
|
572
|
-
const parsedBody = parsedOutput.body;
|
|
573
|
-
throwDefaultError({
|
|
574
|
-
output,
|
|
575
|
-
parsedBody,
|
|
576
|
-
exceptionCtor: __BaseException,
|
|
577
|
-
errorCode,
|
|
578
|
-
});
|
|
579
|
-
}
|
|
580
|
-
};
|
|
581
|
-
const map = __map;
|
|
582
|
-
const deserializeAws_restJson1AccessDeniedExceptionResponse = async (parsedOutput, context) => {
|
|
583
|
-
const contents = map({});
|
|
584
|
-
const data = parsedOutput.body;
|
|
585
|
-
if (data.message != null) {
|
|
586
|
-
contents.message = __expectString(data.message);
|
|
587
|
-
}
|
|
588
|
-
const exception = new AccessDeniedException({
|
|
589
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
590
|
-
...contents,
|
|
514
|
+
}); };
|
|
515
|
+
var deserializeAws_restJson1GetAccountAliasCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
516
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
517
|
+
var _c;
|
|
518
|
+
return __generator(this, function (_d) {
|
|
519
|
+
switch (_d.label) {
|
|
520
|
+
case 0:
|
|
521
|
+
_a = [__assign({}, output)];
|
|
522
|
+
_c = {};
|
|
523
|
+
return [4, parseErrorBody(output.body, context)];
|
|
524
|
+
case 1:
|
|
525
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
526
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
527
|
+
_b = errorCode;
|
|
528
|
+
switch (_b) {
|
|
529
|
+
case "InternalServerException": return [3, 2];
|
|
530
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 2];
|
|
531
|
+
}
|
|
532
|
+
return [3, 4];
|
|
533
|
+
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
534
|
+
case 3: throw _d.sent();
|
|
535
|
+
case 4:
|
|
536
|
+
parsedBody = parsedOutput.body;
|
|
537
|
+
throwDefaultError({
|
|
538
|
+
output: output,
|
|
539
|
+
parsedBody: parsedBody,
|
|
540
|
+
exceptionCtor: __BaseException,
|
|
541
|
+
errorCode: errorCode,
|
|
542
|
+
});
|
|
543
|
+
_d.label = 5;
|
|
544
|
+
case 5: return [2];
|
|
545
|
+
}
|
|
591
546
|
});
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
547
|
+
}); };
|
|
548
|
+
export var deserializeAws_restJson1ListSlackChannelConfigurationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
549
|
+
var contents, data, _a, _b;
|
|
550
|
+
return __generator(this, function (_c) {
|
|
551
|
+
switch (_c.label) {
|
|
552
|
+
case 0:
|
|
553
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
554
|
+
return [2, deserializeAws_restJson1ListSlackChannelConfigurationsCommandError(output, context)];
|
|
555
|
+
}
|
|
556
|
+
contents = map({
|
|
557
|
+
$metadata: deserializeMetadata(output),
|
|
558
|
+
});
|
|
559
|
+
_a = __expectNonNull;
|
|
560
|
+
_b = __expectObject;
|
|
561
|
+
return [4, parseBody(output.body, context)];
|
|
562
|
+
case 1:
|
|
563
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
564
|
+
if (data.nextToken != null) {
|
|
565
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
566
|
+
}
|
|
567
|
+
if (data.slackChannelConfigurations != null) {
|
|
568
|
+
contents.slackChannelConfigurations = deserializeAws_restJson1slackChannelConfigurationList(data.slackChannelConfigurations, context);
|
|
569
|
+
}
|
|
570
|
+
return [2, contents];
|
|
571
|
+
}
|
|
603
572
|
});
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
573
|
+
}); };
|
|
574
|
+
var deserializeAws_restJson1ListSlackChannelConfigurationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
575
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
576
|
+
var _c;
|
|
577
|
+
return __generator(this, function (_d) {
|
|
578
|
+
switch (_d.label) {
|
|
579
|
+
case 0:
|
|
580
|
+
_a = [__assign({}, output)];
|
|
581
|
+
_c = {};
|
|
582
|
+
return [4, parseErrorBody(output.body, context)];
|
|
583
|
+
case 1:
|
|
584
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
585
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
586
|
+
_b = errorCode;
|
|
587
|
+
switch (_b) {
|
|
588
|
+
case "AccessDeniedException": return [3, 2];
|
|
589
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
590
|
+
case "InternalServerException": return [3, 4];
|
|
591
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 4];
|
|
592
|
+
}
|
|
593
|
+
return [3, 6];
|
|
594
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
595
|
+
case 3: throw _d.sent();
|
|
596
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
597
|
+
case 5: throw _d.sent();
|
|
598
|
+
case 6:
|
|
599
|
+
parsedBody = parsedOutput.body;
|
|
600
|
+
throwDefaultError({
|
|
601
|
+
output: output,
|
|
602
|
+
parsedBody: parsedBody,
|
|
603
|
+
exceptionCtor: __BaseException,
|
|
604
|
+
errorCode: errorCode,
|
|
605
|
+
});
|
|
606
|
+
_d.label = 7;
|
|
607
|
+
case 7: return [2];
|
|
608
|
+
}
|
|
615
609
|
});
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
610
|
+
}); };
|
|
611
|
+
export var deserializeAws_restJson1ListSlackWorkspaceConfigurationsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
612
|
+
var contents, data, _a, _b;
|
|
613
|
+
return __generator(this, function (_c) {
|
|
614
|
+
switch (_c.label) {
|
|
615
|
+
case 0:
|
|
616
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
617
|
+
return [2, deserializeAws_restJson1ListSlackWorkspaceConfigurationsCommandError(output, context)];
|
|
618
|
+
}
|
|
619
|
+
contents = map({
|
|
620
|
+
$metadata: deserializeMetadata(output),
|
|
621
|
+
});
|
|
622
|
+
_a = __expectNonNull;
|
|
623
|
+
_b = __expectObject;
|
|
624
|
+
return [4, parseBody(output.body, context)];
|
|
625
|
+
case 1:
|
|
626
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
627
|
+
if (data.nextToken != null) {
|
|
628
|
+
contents.nextToken = __expectString(data.nextToken);
|
|
629
|
+
}
|
|
630
|
+
if (data.slackWorkspaceConfigurations != null) {
|
|
631
|
+
contents.slackWorkspaceConfigurations = deserializeAws_restJson1SlackWorkspaceConfigurationList(data.slackWorkspaceConfigurations, context);
|
|
632
|
+
}
|
|
633
|
+
return [2, contents];
|
|
634
|
+
}
|
|
627
635
|
});
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
636
|
+
}); };
|
|
637
|
+
var deserializeAws_restJson1ListSlackWorkspaceConfigurationsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
638
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
639
|
+
var _c;
|
|
640
|
+
return __generator(this, function (_d) {
|
|
641
|
+
switch (_d.label) {
|
|
642
|
+
case 0:
|
|
643
|
+
_a = [__assign({}, output)];
|
|
644
|
+
_c = {};
|
|
645
|
+
return [4, parseErrorBody(output.body, context)];
|
|
646
|
+
case 1:
|
|
647
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
648
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
649
|
+
_b = errorCode;
|
|
650
|
+
switch (_b) {
|
|
651
|
+
case "AccessDeniedException": return [3, 2];
|
|
652
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
653
|
+
case "InternalServerException": return [3, 4];
|
|
654
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 4];
|
|
655
|
+
}
|
|
656
|
+
return [3, 6];
|
|
657
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
658
|
+
case 3: throw _d.sent();
|
|
659
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
660
|
+
case 5: throw _d.sent();
|
|
661
|
+
case 6:
|
|
662
|
+
parsedBody = parsedOutput.body;
|
|
663
|
+
throwDefaultError({
|
|
664
|
+
output: output,
|
|
665
|
+
parsedBody: parsedBody,
|
|
666
|
+
exceptionCtor: __BaseException,
|
|
667
|
+
errorCode: errorCode,
|
|
668
|
+
});
|
|
669
|
+
_d.label = 7;
|
|
670
|
+
case 7: return [2];
|
|
671
|
+
}
|
|
639
672
|
});
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
673
|
+
}); };
|
|
674
|
+
export var deserializeAws_restJson1PutAccountAliasCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
675
|
+
var contents;
|
|
676
|
+
return __generator(this, function (_a) {
|
|
677
|
+
switch (_a.label) {
|
|
678
|
+
case 0:
|
|
679
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
680
|
+
return [2, deserializeAws_restJson1PutAccountAliasCommandError(output, context)];
|
|
681
|
+
}
|
|
682
|
+
contents = map({
|
|
683
|
+
$metadata: deserializeMetadata(output),
|
|
684
|
+
});
|
|
685
|
+
return [4, collectBody(output.body, context)];
|
|
686
|
+
case 1:
|
|
687
|
+
_a.sent();
|
|
688
|
+
return [2, contents];
|
|
689
|
+
}
|
|
651
690
|
});
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
691
|
+
}); };
|
|
692
|
+
var deserializeAws_restJson1PutAccountAliasCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
693
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
694
|
+
var _c;
|
|
695
|
+
return __generator(this, function (_d) {
|
|
696
|
+
switch (_d.label) {
|
|
697
|
+
case 0:
|
|
698
|
+
_a = [__assign({}, output)];
|
|
699
|
+
_c = {};
|
|
700
|
+
return [4, parseErrorBody(output.body, context)];
|
|
701
|
+
case 1:
|
|
702
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
703
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
704
|
+
_b = errorCode;
|
|
705
|
+
switch (_b) {
|
|
706
|
+
case "AccessDeniedException": return [3, 2];
|
|
707
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
708
|
+
case "InternalServerException": return [3, 4];
|
|
709
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 4];
|
|
710
|
+
case "ValidationException": return [3, 6];
|
|
711
|
+
case "com.amazonaws.supportapp#ValidationException": return [3, 6];
|
|
712
|
+
}
|
|
713
|
+
return [3, 8];
|
|
714
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
715
|
+
case 3: throw _d.sent();
|
|
716
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
717
|
+
case 5: throw _d.sent();
|
|
718
|
+
case 6: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
719
|
+
case 7: throw _d.sent();
|
|
720
|
+
case 8:
|
|
721
|
+
parsedBody = parsedOutput.body;
|
|
722
|
+
throwDefaultError({
|
|
723
|
+
output: output,
|
|
724
|
+
parsedBody: parsedBody,
|
|
725
|
+
exceptionCtor: __BaseException,
|
|
726
|
+
errorCode: errorCode,
|
|
727
|
+
});
|
|
728
|
+
_d.label = 9;
|
|
729
|
+
case 9: return [2];
|
|
730
|
+
}
|
|
731
|
+
});
|
|
732
|
+
}); };
|
|
733
|
+
export var deserializeAws_restJson1UpdateSlackChannelConfigurationCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
734
|
+
var contents, data, _a, _b;
|
|
735
|
+
return __generator(this, function (_c) {
|
|
736
|
+
switch (_c.label) {
|
|
737
|
+
case 0:
|
|
738
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
739
|
+
return [2, deserializeAws_restJson1UpdateSlackChannelConfigurationCommandError(output, context)];
|
|
740
|
+
}
|
|
741
|
+
contents = map({
|
|
742
|
+
$metadata: deserializeMetadata(output),
|
|
743
|
+
});
|
|
744
|
+
_a = __expectNonNull;
|
|
745
|
+
_b = __expectObject;
|
|
746
|
+
return [4, parseBody(output.body, context)];
|
|
747
|
+
case 1:
|
|
748
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
749
|
+
if (data.channelId != null) {
|
|
750
|
+
contents.channelId = __expectString(data.channelId);
|
|
751
|
+
}
|
|
752
|
+
if (data.channelName != null) {
|
|
753
|
+
contents.channelName = __expectString(data.channelName);
|
|
754
|
+
}
|
|
755
|
+
if (data.channelRoleArn != null) {
|
|
756
|
+
contents.channelRoleArn = __expectString(data.channelRoleArn);
|
|
757
|
+
}
|
|
758
|
+
if (data.notifyOnAddCorrespondenceToCase != null) {
|
|
759
|
+
contents.notifyOnAddCorrespondenceToCase = __expectBoolean(data.notifyOnAddCorrespondenceToCase);
|
|
760
|
+
}
|
|
761
|
+
if (data.notifyOnCaseSeverity != null) {
|
|
762
|
+
contents.notifyOnCaseSeverity = __expectString(data.notifyOnCaseSeverity);
|
|
763
|
+
}
|
|
764
|
+
if (data.notifyOnCreateOrReopenCase != null) {
|
|
765
|
+
contents.notifyOnCreateOrReopenCase = __expectBoolean(data.notifyOnCreateOrReopenCase);
|
|
766
|
+
}
|
|
767
|
+
if (data.notifyOnResolveCase != null) {
|
|
768
|
+
contents.notifyOnResolveCase = __expectBoolean(data.notifyOnResolveCase);
|
|
769
|
+
}
|
|
770
|
+
if (data.teamId != null) {
|
|
771
|
+
contents.teamId = __expectString(data.teamId);
|
|
772
|
+
}
|
|
773
|
+
return [2, contents];
|
|
774
|
+
}
|
|
775
|
+
});
|
|
776
|
+
}); };
|
|
777
|
+
var deserializeAws_restJson1UpdateSlackChannelConfigurationCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
778
|
+
var parsedOutput, _a, errorCode, _b, parsedBody;
|
|
779
|
+
var _c;
|
|
780
|
+
return __generator(this, function (_d) {
|
|
781
|
+
switch (_d.label) {
|
|
782
|
+
case 0:
|
|
783
|
+
_a = [__assign({}, output)];
|
|
784
|
+
_c = {};
|
|
785
|
+
return [4, parseErrorBody(output.body, context)];
|
|
786
|
+
case 1:
|
|
787
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
788
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
789
|
+
_b = errorCode;
|
|
790
|
+
switch (_b) {
|
|
791
|
+
case "AccessDeniedException": return [3, 2];
|
|
792
|
+
case "com.amazonaws.supportapp#AccessDeniedException": return [3, 2];
|
|
793
|
+
case "ConflictException": return [3, 4];
|
|
794
|
+
case "com.amazonaws.supportapp#ConflictException": return [3, 4];
|
|
795
|
+
case "InternalServerException": return [3, 6];
|
|
796
|
+
case "com.amazonaws.supportapp#InternalServerException": return [3, 6];
|
|
797
|
+
case "ResourceNotFoundException": return [3, 8];
|
|
798
|
+
case "com.amazonaws.supportapp#ResourceNotFoundException": return [3, 8];
|
|
799
|
+
case "ValidationException": return [3, 10];
|
|
800
|
+
case "com.amazonaws.supportapp#ValidationException": return [3, 10];
|
|
801
|
+
}
|
|
802
|
+
return [3, 12];
|
|
803
|
+
case 2: return [4, deserializeAws_restJson1AccessDeniedExceptionResponse(parsedOutput, context)];
|
|
804
|
+
case 3: throw _d.sent();
|
|
805
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
806
|
+
case 5: throw _d.sent();
|
|
807
|
+
case 6: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
808
|
+
case 7: throw _d.sent();
|
|
809
|
+
case 8: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
810
|
+
case 9: throw _d.sent();
|
|
811
|
+
case 10: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
812
|
+
case 11: throw _d.sent();
|
|
813
|
+
case 12:
|
|
814
|
+
parsedBody = parsedOutput.body;
|
|
815
|
+
throwDefaultError({
|
|
816
|
+
output: output,
|
|
817
|
+
parsedBody: parsedBody,
|
|
818
|
+
exceptionCtor: __BaseException,
|
|
819
|
+
errorCode: errorCode,
|
|
820
|
+
});
|
|
821
|
+
_d.label = 13;
|
|
822
|
+
case 13: return [2];
|
|
823
|
+
}
|
|
824
|
+
});
|
|
825
|
+
}); };
|
|
826
|
+
var map = __map;
|
|
827
|
+
var deserializeAws_restJson1AccessDeniedExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
828
|
+
var contents, data, exception;
|
|
829
|
+
return __generator(this, function (_a) {
|
|
830
|
+
contents = map({});
|
|
831
|
+
data = parsedOutput.body;
|
|
832
|
+
if (data.message != null) {
|
|
833
|
+
contents.message = __expectString(data.message);
|
|
834
|
+
}
|
|
835
|
+
exception = new AccessDeniedException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
836
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
837
|
+
});
|
|
838
|
+
}); };
|
|
839
|
+
var deserializeAws_restJson1ConflictExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
840
|
+
var contents, data, exception;
|
|
841
|
+
return __generator(this, function (_a) {
|
|
842
|
+
contents = map({});
|
|
843
|
+
data = parsedOutput.body;
|
|
844
|
+
if (data.message != null) {
|
|
845
|
+
contents.message = __expectString(data.message);
|
|
846
|
+
}
|
|
847
|
+
exception = new ConflictException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
848
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
849
|
+
});
|
|
850
|
+
}); };
|
|
851
|
+
var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
852
|
+
var contents, data, exception;
|
|
853
|
+
return __generator(this, function (_a) {
|
|
854
|
+
contents = map({});
|
|
855
|
+
data = parsedOutput.body;
|
|
856
|
+
if (data.message != null) {
|
|
857
|
+
contents.message = __expectString(data.message);
|
|
858
|
+
}
|
|
859
|
+
exception = new InternalServerException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
860
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
861
|
+
});
|
|
862
|
+
}); };
|
|
863
|
+
var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
864
|
+
var contents, data, exception;
|
|
865
|
+
return __generator(this, function (_a) {
|
|
866
|
+
contents = map({});
|
|
867
|
+
data = parsedOutput.body;
|
|
868
|
+
if (data.message != null) {
|
|
869
|
+
contents.message = __expectString(data.message);
|
|
870
|
+
}
|
|
871
|
+
exception = new ResourceNotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
872
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
873
|
+
});
|
|
874
|
+
}); };
|
|
875
|
+
var deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
876
|
+
var contents, data, exception;
|
|
877
|
+
return __generator(this, function (_a) {
|
|
878
|
+
contents = map({});
|
|
879
|
+
data = parsedOutput.body;
|
|
880
|
+
if (data.message != null) {
|
|
881
|
+
contents.message = __expectString(data.message);
|
|
882
|
+
}
|
|
883
|
+
exception = new ServiceQuotaExceededException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
884
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
885
|
+
});
|
|
886
|
+
}); };
|
|
887
|
+
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
888
|
+
var contents, data, exception;
|
|
889
|
+
return __generator(this, function (_a) {
|
|
890
|
+
contents = map({});
|
|
891
|
+
data = parsedOutput.body;
|
|
892
|
+
if (data.message != null) {
|
|
893
|
+
contents.message = __expectString(data.message);
|
|
894
|
+
}
|
|
895
|
+
exception = new ValidationException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
896
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
897
|
+
});
|
|
898
|
+
}); };
|
|
899
|
+
var deserializeAws_restJson1SlackChannelConfiguration = function (output, context) {
|
|
655
900
|
return {
|
|
656
901
|
channelId: __expectString(output.channelId),
|
|
657
902
|
channelName: __expectString(output.channelName),
|
|
@@ -663,10 +908,10 @@ const deserializeAws_restJson1SlackChannelConfiguration = (output, context) => {
|
|
|
663
908
|
teamId: __expectString(output.teamId),
|
|
664
909
|
};
|
|
665
910
|
};
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
.filter((e)
|
|
669
|
-
.map((entry)
|
|
911
|
+
var deserializeAws_restJson1slackChannelConfigurationList = function (output, context) {
|
|
912
|
+
var retVal = (output || [])
|
|
913
|
+
.filter(function (e) { return e != null; })
|
|
914
|
+
.map(function (entry) {
|
|
670
915
|
if (entry === null) {
|
|
671
916
|
return null;
|
|
672
917
|
}
|
|
@@ -674,15 +919,15 @@ const deserializeAws_restJson1slackChannelConfigurationList = (output, context)
|
|
|
674
919
|
});
|
|
675
920
|
return retVal;
|
|
676
921
|
};
|
|
677
|
-
|
|
922
|
+
var deserializeAws_restJson1SlackWorkspaceConfiguration = function (output, context) {
|
|
678
923
|
return {
|
|
679
924
|
teamId: __expectString(output.teamId),
|
|
680
925
|
};
|
|
681
926
|
};
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
.filter((e)
|
|
685
|
-
.map((entry)
|
|
927
|
+
var deserializeAws_restJson1SlackWorkspaceConfigurationList = function (output, context) {
|
|
928
|
+
var retVal = (output || [])
|
|
929
|
+
.filter(function (e) { return e != null; })
|
|
930
|
+
.map(function (entry) {
|
|
686
931
|
if (entry === null) {
|
|
687
932
|
return null;
|
|
688
933
|
}
|
|
@@ -690,39 +935,57 @@ const deserializeAws_restJson1SlackWorkspaceConfigurationList = (output, context
|
|
|
690
935
|
});
|
|
691
936
|
return retVal;
|
|
692
937
|
};
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
938
|
+
var deserializeMetadata = function (output) {
|
|
939
|
+
var _a, _b;
|
|
940
|
+
return ({
|
|
941
|
+
httpStatusCode: output.statusCode,
|
|
942
|
+
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"],
|
|
943
|
+
extendedRequestId: output.headers["x-amz-id-2"],
|
|
944
|
+
cfId: output.headers["x-amz-cf-id"],
|
|
945
|
+
});
|
|
946
|
+
};
|
|
947
|
+
var collectBody = function (streamBody, context) {
|
|
948
|
+
if (streamBody === void 0) { streamBody = new Uint8Array(); }
|
|
700
949
|
if (streamBody instanceof Uint8Array) {
|
|
701
950
|
return Promise.resolve(streamBody);
|
|
702
951
|
}
|
|
703
952
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
704
953
|
};
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
value !== null &&
|
|
708
|
-
value !== "" &&
|
|
709
|
-
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
710
|
-
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
711
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
712
|
-
if (encoded.length) {
|
|
713
|
-
return JSON.parse(encoded);
|
|
714
|
-
}
|
|
715
|
-
return {};
|
|
716
|
-
});
|
|
717
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
718
|
-
const value = await parseBody(errorBody, context);
|
|
719
|
-
value.message = value.message ?? value.Message;
|
|
720
|
-
return value;
|
|
954
|
+
var collectBodyString = function (streamBody, context) {
|
|
955
|
+
return collectBody(streamBody, context).then(function (body) { return context.utf8Encoder(body); });
|
|
721
956
|
};
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
957
|
+
var isSerializableHeaderValue = function (value) {
|
|
958
|
+
return value !== undefined &&
|
|
959
|
+
value !== null &&
|
|
960
|
+
value !== "" &&
|
|
961
|
+
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
962
|
+
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
963
|
+
};
|
|
964
|
+
var parseBody = function (streamBody, context) {
|
|
965
|
+
return collectBodyString(streamBody, context).then(function (encoded) {
|
|
966
|
+
if (encoded.length) {
|
|
967
|
+
return JSON.parse(encoded);
|
|
968
|
+
}
|
|
969
|
+
return {};
|
|
970
|
+
});
|
|
971
|
+
};
|
|
972
|
+
var parseErrorBody = function (errorBody, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
973
|
+
var value;
|
|
974
|
+
var _a;
|
|
975
|
+
return __generator(this, function (_b) {
|
|
976
|
+
switch (_b.label) {
|
|
977
|
+
case 0: return [4, parseBody(errorBody, context)];
|
|
978
|
+
case 1:
|
|
979
|
+
value = _b.sent();
|
|
980
|
+
value.message = (_a = value.message) !== null && _a !== void 0 ? _a : value.Message;
|
|
981
|
+
return [2, value];
|
|
982
|
+
}
|
|
983
|
+
});
|
|
984
|
+
}); };
|
|
985
|
+
var loadRestJsonErrorCode = function (output, data) {
|
|
986
|
+
var findKey = function (object, key) { return Object.keys(object).find(function (k) { return k.toLowerCase() === key.toLowerCase(); }); };
|
|
987
|
+
var sanitizeErrorCode = function (rawValue) {
|
|
988
|
+
var cleanValue = rawValue;
|
|
726
989
|
if (typeof cleanValue === "number") {
|
|
727
990
|
cleanValue = cleanValue.toString();
|
|
728
991
|
}
|
|
@@ -737,7 +1000,7 @@ const loadRestJsonErrorCode = (output, data) => {
|
|
|
737
1000
|
}
|
|
738
1001
|
return cleanValue;
|
|
739
1002
|
};
|
|
740
|
-
|
|
1003
|
+
var headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
741
1004
|
if (headerKey !== undefined) {
|
|
742
1005
|
return sanitizeErrorCode(output.headers[headerKey]);
|
|
743
1006
|
}
|