@aws-sdk/client-sso-oidc 3.928.0 → 3.930.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/dist-cjs/index.js +430 -538
- package/dist-cjs/runtimeConfig.shared.js +2 -0
- package/dist-es/SSOOIDCClient.js +2 -0
- package/dist-es/commands/CreateTokenCommand.js +3 -10
- package/dist-es/commands/CreateTokenWithIAMCommand.js +3 -10
- package/dist-es/commands/RegisterClientCommand.js +3 -10
- package/dist-es/commands/StartDeviceAuthorizationCommand.js +3 -10
- package/dist-es/models/models_0.js +0 -34
- package/dist-es/runtimeConfig.shared.js +2 -0
- package/dist-es/schemas/schemas_0.js +382 -0
- package/dist-types/SSOOIDCClient.d.ts +10 -1
- package/dist-types/models/models_0.d.ts +0 -24
- package/dist-types/runtimeConfig.browser.d.ts +1 -0
- package/dist-types/runtimeConfig.d.ts +1 -0
- package/dist-types/runtimeConfig.native.d.ts +1 -0
- package/dist-types/runtimeConfig.shared.d.ts +1 -0
- package/dist-types/schemas/schemas_0.d.ts +40 -0
- package/dist-types/ts3.4/SSOOIDCClient.d.ts +4 -0
- package/dist-types/ts3.4/models/models_0.d.ts +0 -18
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +4 -0
- package/dist-types/ts3.4/schemas/schemas_0.d.ts +45 -0
- package/package.json +33 -33
- package/dist-es/protocols/Aws_restJson1.js +0 -430
- package/dist-types/protocols/Aws_restJson1.d.ts +0 -38
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +0 -53
|
@@ -1,430 +0,0 @@
|
|
|
1
|
-
import { loadRestJsonErrorCode, parseJsonBody as parseBody, parseJsonErrorBody as parseErrorBody } from "@aws-sdk/core";
|
|
2
|
-
import { requestBuilder as rb } from "@smithy/core";
|
|
3
|
-
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map, take, withBaseException, } from "@smithy/smithy-client";
|
|
4
|
-
import { AccessDeniedException, AuthorizationPendingException, ExpiredTokenException, InternalServerException, InvalidClientException, InvalidClientMetadataException, InvalidGrantException, InvalidRedirectUriException, InvalidRequestException, InvalidRequestRegionException, InvalidScopeException, SlowDownException, UnauthorizedClientException, UnsupportedGrantTypeException, } from "../models/models_0";
|
|
5
|
-
import { SSOOIDCServiceException as __BaseException } from "../models/SSOOIDCServiceException";
|
|
6
|
-
export const se_CreateTokenCommand = async (input, context) => {
|
|
7
|
-
const b = rb(input, context);
|
|
8
|
-
const headers = {
|
|
9
|
-
"content-type": "application/json",
|
|
10
|
-
};
|
|
11
|
-
b.bp("/token");
|
|
12
|
-
let body;
|
|
13
|
-
body = JSON.stringify(take(input, {
|
|
14
|
-
clientId: [],
|
|
15
|
-
clientSecret: [],
|
|
16
|
-
code: [],
|
|
17
|
-
codeVerifier: [],
|
|
18
|
-
deviceCode: [],
|
|
19
|
-
grantType: [],
|
|
20
|
-
redirectUri: [],
|
|
21
|
-
refreshToken: [],
|
|
22
|
-
scope: (_) => _json(_),
|
|
23
|
-
}));
|
|
24
|
-
b.m("POST").h(headers).b(body);
|
|
25
|
-
return b.build();
|
|
26
|
-
};
|
|
27
|
-
export const se_CreateTokenWithIAMCommand = async (input, context) => {
|
|
28
|
-
const b = rb(input, context);
|
|
29
|
-
const headers = {
|
|
30
|
-
"content-type": "application/json",
|
|
31
|
-
};
|
|
32
|
-
b.bp("/token");
|
|
33
|
-
const query = map({
|
|
34
|
-
[_ai]: [, "t"],
|
|
35
|
-
});
|
|
36
|
-
let body;
|
|
37
|
-
body = JSON.stringify(take(input, {
|
|
38
|
-
assertion: [],
|
|
39
|
-
clientId: [],
|
|
40
|
-
code: [],
|
|
41
|
-
codeVerifier: [],
|
|
42
|
-
grantType: [],
|
|
43
|
-
redirectUri: [],
|
|
44
|
-
refreshToken: [],
|
|
45
|
-
requestedTokenType: [],
|
|
46
|
-
scope: (_) => _json(_),
|
|
47
|
-
subjectToken: [],
|
|
48
|
-
subjectTokenType: [],
|
|
49
|
-
}));
|
|
50
|
-
b.m("POST").h(headers).q(query).b(body);
|
|
51
|
-
return b.build();
|
|
52
|
-
};
|
|
53
|
-
export const se_RegisterClientCommand = async (input, context) => {
|
|
54
|
-
const b = rb(input, context);
|
|
55
|
-
const headers = {
|
|
56
|
-
"content-type": "application/json",
|
|
57
|
-
};
|
|
58
|
-
b.bp("/client/register");
|
|
59
|
-
let body;
|
|
60
|
-
body = JSON.stringify(take(input, {
|
|
61
|
-
clientName: [],
|
|
62
|
-
clientType: [],
|
|
63
|
-
entitledApplicationArn: [],
|
|
64
|
-
grantTypes: (_) => _json(_),
|
|
65
|
-
issuerUrl: [],
|
|
66
|
-
redirectUris: (_) => _json(_),
|
|
67
|
-
scopes: (_) => _json(_),
|
|
68
|
-
}));
|
|
69
|
-
b.m("POST").h(headers).b(body);
|
|
70
|
-
return b.build();
|
|
71
|
-
};
|
|
72
|
-
export const se_StartDeviceAuthorizationCommand = async (input, context) => {
|
|
73
|
-
const b = rb(input, context);
|
|
74
|
-
const headers = {
|
|
75
|
-
"content-type": "application/json",
|
|
76
|
-
};
|
|
77
|
-
b.bp("/device_authorization");
|
|
78
|
-
let body;
|
|
79
|
-
body = JSON.stringify(take(input, {
|
|
80
|
-
clientId: [],
|
|
81
|
-
clientSecret: [],
|
|
82
|
-
startUrl: [],
|
|
83
|
-
}));
|
|
84
|
-
b.m("POST").h(headers).b(body);
|
|
85
|
-
return b.build();
|
|
86
|
-
};
|
|
87
|
-
export const de_CreateTokenCommand = async (output, context) => {
|
|
88
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
89
|
-
return de_CommandError(output, context);
|
|
90
|
-
}
|
|
91
|
-
const contents = map({
|
|
92
|
-
$metadata: deserializeMetadata(output),
|
|
93
|
-
});
|
|
94
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
95
|
-
const doc = take(data, {
|
|
96
|
-
accessToken: __expectString,
|
|
97
|
-
expiresIn: __expectInt32,
|
|
98
|
-
idToken: __expectString,
|
|
99
|
-
refreshToken: __expectString,
|
|
100
|
-
tokenType: __expectString,
|
|
101
|
-
});
|
|
102
|
-
Object.assign(contents, doc);
|
|
103
|
-
return contents;
|
|
104
|
-
};
|
|
105
|
-
export const de_CreateTokenWithIAMCommand = async (output, context) => {
|
|
106
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
107
|
-
return de_CommandError(output, context);
|
|
108
|
-
}
|
|
109
|
-
const contents = map({
|
|
110
|
-
$metadata: deserializeMetadata(output),
|
|
111
|
-
});
|
|
112
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
113
|
-
const doc = take(data, {
|
|
114
|
-
accessToken: __expectString,
|
|
115
|
-
awsAdditionalDetails: _json,
|
|
116
|
-
expiresIn: __expectInt32,
|
|
117
|
-
idToken: __expectString,
|
|
118
|
-
issuedTokenType: __expectString,
|
|
119
|
-
refreshToken: __expectString,
|
|
120
|
-
scope: _json,
|
|
121
|
-
tokenType: __expectString,
|
|
122
|
-
});
|
|
123
|
-
Object.assign(contents, doc);
|
|
124
|
-
return contents;
|
|
125
|
-
};
|
|
126
|
-
export const de_RegisterClientCommand = async (output, context) => {
|
|
127
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
128
|
-
return de_CommandError(output, context);
|
|
129
|
-
}
|
|
130
|
-
const contents = map({
|
|
131
|
-
$metadata: deserializeMetadata(output),
|
|
132
|
-
});
|
|
133
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
134
|
-
const doc = take(data, {
|
|
135
|
-
authorizationEndpoint: __expectString,
|
|
136
|
-
clientId: __expectString,
|
|
137
|
-
clientIdIssuedAt: __expectLong,
|
|
138
|
-
clientSecret: __expectString,
|
|
139
|
-
clientSecretExpiresAt: __expectLong,
|
|
140
|
-
tokenEndpoint: __expectString,
|
|
141
|
-
});
|
|
142
|
-
Object.assign(contents, doc);
|
|
143
|
-
return contents;
|
|
144
|
-
};
|
|
145
|
-
export const de_StartDeviceAuthorizationCommand = async (output, context) => {
|
|
146
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
147
|
-
return de_CommandError(output, context);
|
|
148
|
-
}
|
|
149
|
-
const contents = map({
|
|
150
|
-
$metadata: deserializeMetadata(output),
|
|
151
|
-
});
|
|
152
|
-
const data = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
153
|
-
const doc = take(data, {
|
|
154
|
-
deviceCode: __expectString,
|
|
155
|
-
expiresIn: __expectInt32,
|
|
156
|
-
interval: __expectInt32,
|
|
157
|
-
userCode: __expectString,
|
|
158
|
-
verificationUri: __expectString,
|
|
159
|
-
verificationUriComplete: __expectString,
|
|
160
|
-
});
|
|
161
|
-
Object.assign(contents, doc);
|
|
162
|
-
return contents;
|
|
163
|
-
};
|
|
164
|
-
const de_CommandError = async (output, context) => {
|
|
165
|
-
const parsedOutput = {
|
|
166
|
-
...output,
|
|
167
|
-
body: await parseErrorBody(output.body, context),
|
|
168
|
-
};
|
|
169
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
170
|
-
switch (errorCode) {
|
|
171
|
-
case "AccessDeniedException":
|
|
172
|
-
case "com.amazonaws.ssooidc#AccessDeniedException":
|
|
173
|
-
throw await de_AccessDeniedExceptionRes(parsedOutput, context);
|
|
174
|
-
case "AuthorizationPendingException":
|
|
175
|
-
case "com.amazonaws.ssooidc#AuthorizationPendingException":
|
|
176
|
-
throw await de_AuthorizationPendingExceptionRes(parsedOutput, context);
|
|
177
|
-
case "ExpiredTokenException":
|
|
178
|
-
case "com.amazonaws.ssooidc#ExpiredTokenException":
|
|
179
|
-
throw await de_ExpiredTokenExceptionRes(parsedOutput, context);
|
|
180
|
-
case "InternalServerException":
|
|
181
|
-
case "com.amazonaws.ssooidc#InternalServerException":
|
|
182
|
-
throw await de_InternalServerExceptionRes(parsedOutput, context);
|
|
183
|
-
case "InvalidClientException":
|
|
184
|
-
case "com.amazonaws.ssooidc#InvalidClientException":
|
|
185
|
-
throw await de_InvalidClientExceptionRes(parsedOutput, context);
|
|
186
|
-
case "InvalidGrantException":
|
|
187
|
-
case "com.amazonaws.ssooidc#InvalidGrantException":
|
|
188
|
-
throw await de_InvalidGrantExceptionRes(parsedOutput, context);
|
|
189
|
-
case "InvalidRequestException":
|
|
190
|
-
case "com.amazonaws.ssooidc#InvalidRequestException":
|
|
191
|
-
throw await de_InvalidRequestExceptionRes(parsedOutput, context);
|
|
192
|
-
case "InvalidScopeException":
|
|
193
|
-
case "com.amazonaws.ssooidc#InvalidScopeException":
|
|
194
|
-
throw await de_InvalidScopeExceptionRes(parsedOutput, context);
|
|
195
|
-
case "SlowDownException":
|
|
196
|
-
case "com.amazonaws.ssooidc#SlowDownException":
|
|
197
|
-
throw await de_SlowDownExceptionRes(parsedOutput, context);
|
|
198
|
-
case "UnauthorizedClientException":
|
|
199
|
-
case "com.amazonaws.ssooidc#UnauthorizedClientException":
|
|
200
|
-
throw await de_UnauthorizedClientExceptionRes(parsedOutput, context);
|
|
201
|
-
case "UnsupportedGrantTypeException":
|
|
202
|
-
case "com.amazonaws.ssooidc#UnsupportedGrantTypeException":
|
|
203
|
-
throw await de_UnsupportedGrantTypeExceptionRes(parsedOutput, context);
|
|
204
|
-
case "InvalidRequestRegionException":
|
|
205
|
-
case "com.amazonaws.ssooidc#InvalidRequestRegionException":
|
|
206
|
-
throw await de_InvalidRequestRegionExceptionRes(parsedOutput, context);
|
|
207
|
-
case "InvalidClientMetadataException":
|
|
208
|
-
case "com.amazonaws.ssooidc#InvalidClientMetadataException":
|
|
209
|
-
throw await de_InvalidClientMetadataExceptionRes(parsedOutput, context);
|
|
210
|
-
case "InvalidRedirectUriException":
|
|
211
|
-
case "com.amazonaws.ssooidc#InvalidRedirectUriException":
|
|
212
|
-
throw await de_InvalidRedirectUriExceptionRes(parsedOutput, context);
|
|
213
|
-
default:
|
|
214
|
-
const parsedBody = parsedOutput.body;
|
|
215
|
-
return throwDefaultError({
|
|
216
|
-
output,
|
|
217
|
-
parsedBody,
|
|
218
|
-
errorCode,
|
|
219
|
-
});
|
|
220
|
-
}
|
|
221
|
-
};
|
|
222
|
-
const throwDefaultError = withBaseException(__BaseException);
|
|
223
|
-
const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
224
|
-
const contents = map({});
|
|
225
|
-
const data = parsedOutput.body;
|
|
226
|
-
const doc = take(data, {
|
|
227
|
-
error: __expectString,
|
|
228
|
-
error_description: __expectString,
|
|
229
|
-
reason: __expectString,
|
|
230
|
-
});
|
|
231
|
-
Object.assign(contents, doc);
|
|
232
|
-
const exception = new AccessDeniedException({
|
|
233
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
234
|
-
...contents,
|
|
235
|
-
});
|
|
236
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
237
|
-
};
|
|
238
|
-
const de_AuthorizationPendingExceptionRes = async (parsedOutput, context) => {
|
|
239
|
-
const contents = map({});
|
|
240
|
-
const data = parsedOutput.body;
|
|
241
|
-
const doc = take(data, {
|
|
242
|
-
error: __expectString,
|
|
243
|
-
error_description: __expectString,
|
|
244
|
-
});
|
|
245
|
-
Object.assign(contents, doc);
|
|
246
|
-
const exception = new AuthorizationPendingException({
|
|
247
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
248
|
-
...contents,
|
|
249
|
-
});
|
|
250
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
251
|
-
};
|
|
252
|
-
const de_ExpiredTokenExceptionRes = async (parsedOutput, context) => {
|
|
253
|
-
const contents = map({});
|
|
254
|
-
const data = parsedOutput.body;
|
|
255
|
-
const doc = take(data, {
|
|
256
|
-
error: __expectString,
|
|
257
|
-
error_description: __expectString,
|
|
258
|
-
});
|
|
259
|
-
Object.assign(contents, doc);
|
|
260
|
-
const exception = new ExpiredTokenException({
|
|
261
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
262
|
-
...contents,
|
|
263
|
-
});
|
|
264
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
265
|
-
};
|
|
266
|
-
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
267
|
-
const contents = map({});
|
|
268
|
-
const data = parsedOutput.body;
|
|
269
|
-
const doc = take(data, {
|
|
270
|
-
error: __expectString,
|
|
271
|
-
error_description: __expectString,
|
|
272
|
-
});
|
|
273
|
-
Object.assign(contents, doc);
|
|
274
|
-
const exception = new InternalServerException({
|
|
275
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
276
|
-
...contents,
|
|
277
|
-
});
|
|
278
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
279
|
-
};
|
|
280
|
-
const de_InvalidClientExceptionRes = async (parsedOutput, context) => {
|
|
281
|
-
const contents = map({});
|
|
282
|
-
const data = parsedOutput.body;
|
|
283
|
-
const doc = take(data, {
|
|
284
|
-
error: __expectString,
|
|
285
|
-
error_description: __expectString,
|
|
286
|
-
});
|
|
287
|
-
Object.assign(contents, doc);
|
|
288
|
-
const exception = new InvalidClientException({
|
|
289
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
290
|
-
...contents,
|
|
291
|
-
});
|
|
292
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
293
|
-
};
|
|
294
|
-
const de_InvalidClientMetadataExceptionRes = async (parsedOutput, context) => {
|
|
295
|
-
const contents = map({});
|
|
296
|
-
const data = parsedOutput.body;
|
|
297
|
-
const doc = take(data, {
|
|
298
|
-
error: __expectString,
|
|
299
|
-
error_description: __expectString,
|
|
300
|
-
});
|
|
301
|
-
Object.assign(contents, doc);
|
|
302
|
-
const exception = new InvalidClientMetadataException({
|
|
303
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
304
|
-
...contents,
|
|
305
|
-
});
|
|
306
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
307
|
-
};
|
|
308
|
-
const de_InvalidGrantExceptionRes = async (parsedOutput, context) => {
|
|
309
|
-
const contents = map({});
|
|
310
|
-
const data = parsedOutput.body;
|
|
311
|
-
const doc = take(data, {
|
|
312
|
-
error: __expectString,
|
|
313
|
-
error_description: __expectString,
|
|
314
|
-
});
|
|
315
|
-
Object.assign(contents, doc);
|
|
316
|
-
const exception = new InvalidGrantException({
|
|
317
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
318
|
-
...contents,
|
|
319
|
-
});
|
|
320
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
321
|
-
};
|
|
322
|
-
const de_InvalidRedirectUriExceptionRes = async (parsedOutput, context) => {
|
|
323
|
-
const contents = map({});
|
|
324
|
-
const data = parsedOutput.body;
|
|
325
|
-
const doc = take(data, {
|
|
326
|
-
error: __expectString,
|
|
327
|
-
error_description: __expectString,
|
|
328
|
-
});
|
|
329
|
-
Object.assign(contents, doc);
|
|
330
|
-
const exception = new InvalidRedirectUriException({
|
|
331
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
332
|
-
...contents,
|
|
333
|
-
});
|
|
334
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
335
|
-
};
|
|
336
|
-
const de_InvalidRequestExceptionRes = async (parsedOutput, context) => {
|
|
337
|
-
const contents = map({});
|
|
338
|
-
const data = parsedOutput.body;
|
|
339
|
-
const doc = take(data, {
|
|
340
|
-
error: __expectString,
|
|
341
|
-
error_description: __expectString,
|
|
342
|
-
reason: __expectString,
|
|
343
|
-
});
|
|
344
|
-
Object.assign(contents, doc);
|
|
345
|
-
const exception = new InvalidRequestException({
|
|
346
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
347
|
-
...contents,
|
|
348
|
-
});
|
|
349
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
350
|
-
};
|
|
351
|
-
const de_InvalidRequestRegionExceptionRes = async (parsedOutput, context) => {
|
|
352
|
-
const contents = map({});
|
|
353
|
-
const data = parsedOutput.body;
|
|
354
|
-
const doc = take(data, {
|
|
355
|
-
endpoint: __expectString,
|
|
356
|
-
error: __expectString,
|
|
357
|
-
error_description: __expectString,
|
|
358
|
-
region: __expectString,
|
|
359
|
-
});
|
|
360
|
-
Object.assign(contents, doc);
|
|
361
|
-
const exception = new InvalidRequestRegionException({
|
|
362
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
363
|
-
...contents,
|
|
364
|
-
});
|
|
365
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
366
|
-
};
|
|
367
|
-
const de_InvalidScopeExceptionRes = async (parsedOutput, context) => {
|
|
368
|
-
const contents = map({});
|
|
369
|
-
const data = parsedOutput.body;
|
|
370
|
-
const doc = take(data, {
|
|
371
|
-
error: __expectString,
|
|
372
|
-
error_description: __expectString,
|
|
373
|
-
});
|
|
374
|
-
Object.assign(contents, doc);
|
|
375
|
-
const exception = new InvalidScopeException({
|
|
376
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
377
|
-
...contents,
|
|
378
|
-
});
|
|
379
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
380
|
-
};
|
|
381
|
-
const de_SlowDownExceptionRes = async (parsedOutput, context) => {
|
|
382
|
-
const contents = map({});
|
|
383
|
-
const data = parsedOutput.body;
|
|
384
|
-
const doc = take(data, {
|
|
385
|
-
error: __expectString,
|
|
386
|
-
error_description: __expectString,
|
|
387
|
-
});
|
|
388
|
-
Object.assign(contents, doc);
|
|
389
|
-
const exception = new SlowDownException({
|
|
390
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
391
|
-
...contents,
|
|
392
|
-
});
|
|
393
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
394
|
-
};
|
|
395
|
-
const de_UnauthorizedClientExceptionRes = async (parsedOutput, context) => {
|
|
396
|
-
const contents = map({});
|
|
397
|
-
const data = parsedOutput.body;
|
|
398
|
-
const doc = take(data, {
|
|
399
|
-
error: __expectString,
|
|
400
|
-
error_description: __expectString,
|
|
401
|
-
});
|
|
402
|
-
Object.assign(contents, doc);
|
|
403
|
-
const exception = new UnauthorizedClientException({
|
|
404
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
405
|
-
...contents,
|
|
406
|
-
});
|
|
407
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
408
|
-
};
|
|
409
|
-
const de_UnsupportedGrantTypeExceptionRes = async (parsedOutput, context) => {
|
|
410
|
-
const contents = map({});
|
|
411
|
-
const data = parsedOutput.body;
|
|
412
|
-
const doc = take(data, {
|
|
413
|
-
error: __expectString,
|
|
414
|
-
error_description: __expectString,
|
|
415
|
-
});
|
|
416
|
-
Object.assign(contents, doc);
|
|
417
|
-
const exception = new UnsupportedGrantTypeException({
|
|
418
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
419
|
-
...contents,
|
|
420
|
-
});
|
|
421
|
-
return __decorateServiceException(exception, parsedOutput.body);
|
|
422
|
-
};
|
|
423
|
-
const deserializeMetadata = (output) => ({
|
|
424
|
-
httpStatusCode: output.statusCode,
|
|
425
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
426
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
427
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
428
|
-
});
|
|
429
|
-
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
430
|
-
const _ai = "aws_iam";
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@smithy/protocol-http";
|
|
2
|
-
import { SerdeContext as __SerdeContext } from "@smithy/types";
|
|
3
|
-
import { CreateTokenCommandInput, CreateTokenCommandOutput } from "../commands/CreateTokenCommand";
|
|
4
|
-
import { CreateTokenWithIAMCommandInput, CreateTokenWithIAMCommandOutput } from "../commands/CreateTokenWithIAMCommand";
|
|
5
|
-
import { RegisterClientCommandInput, RegisterClientCommandOutput } from "../commands/RegisterClientCommand";
|
|
6
|
-
import { StartDeviceAuthorizationCommandInput, StartDeviceAuthorizationCommandOutput } from "../commands/StartDeviceAuthorizationCommand";
|
|
7
|
-
/**
|
|
8
|
-
* serializeAws_restJson1CreateTokenCommand
|
|
9
|
-
*/
|
|
10
|
-
export declare const se_CreateTokenCommand: (input: CreateTokenCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
11
|
-
/**
|
|
12
|
-
* serializeAws_restJson1CreateTokenWithIAMCommand
|
|
13
|
-
*/
|
|
14
|
-
export declare const se_CreateTokenWithIAMCommand: (input: CreateTokenWithIAMCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
15
|
-
/**
|
|
16
|
-
* serializeAws_restJson1RegisterClientCommand
|
|
17
|
-
*/
|
|
18
|
-
export declare const se_RegisterClientCommand: (input: RegisterClientCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
19
|
-
/**
|
|
20
|
-
* serializeAws_restJson1StartDeviceAuthorizationCommand
|
|
21
|
-
*/
|
|
22
|
-
export declare const se_StartDeviceAuthorizationCommand: (input: StartDeviceAuthorizationCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
23
|
-
/**
|
|
24
|
-
* deserializeAws_restJson1CreateTokenCommand
|
|
25
|
-
*/
|
|
26
|
-
export declare const de_CreateTokenCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<CreateTokenCommandOutput>;
|
|
27
|
-
/**
|
|
28
|
-
* deserializeAws_restJson1CreateTokenWithIAMCommand
|
|
29
|
-
*/
|
|
30
|
-
export declare const de_CreateTokenWithIAMCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<CreateTokenWithIAMCommandOutput>;
|
|
31
|
-
/**
|
|
32
|
-
* deserializeAws_restJson1RegisterClientCommand
|
|
33
|
-
*/
|
|
34
|
-
export declare const de_RegisterClientCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<RegisterClientCommandOutput>;
|
|
35
|
-
/**
|
|
36
|
-
* deserializeAws_restJson1StartDeviceAuthorizationCommand
|
|
37
|
-
*/
|
|
38
|
-
export declare const de_StartDeviceAuthorizationCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<StartDeviceAuthorizationCommandOutput>;
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
HttpRequest as __HttpRequest,
|
|
3
|
-
HttpResponse as __HttpResponse,
|
|
4
|
-
} from "@smithy/protocol-http";
|
|
5
|
-
import { SerdeContext as __SerdeContext } from "@smithy/types";
|
|
6
|
-
import {
|
|
7
|
-
CreateTokenCommandInput,
|
|
8
|
-
CreateTokenCommandOutput,
|
|
9
|
-
} from "../commands/CreateTokenCommand";
|
|
10
|
-
import {
|
|
11
|
-
CreateTokenWithIAMCommandInput,
|
|
12
|
-
CreateTokenWithIAMCommandOutput,
|
|
13
|
-
} from "../commands/CreateTokenWithIAMCommand";
|
|
14
|
-
import {
|
|
15
|
-
RegisterClientCommandInput,
|
|
16
|
-
RegisterClientCommandOutput,
|
|
17
|
-
} from "../commands/RegisterClientCommand";
|
|
18
|
-
import {
|
|
19
|
-
StartDeviceAuthorizationCommandInput,
|
|
20
|
-
StartDeviceAuthorizationCommandOutput,
|
|
21
|
-
} from "../commands/StartDeviceAuthorizationCommand";
|
|
22
|
-
export declare const se_CreateTokenCommand: (
|
|
23
|
-
input: CreateTokenCommandInput,
|
|
24
|
-
context: __SerdeContext
|
|
25
|
-
) => Promise<__HttpRequest>;
|
|
26
|
-
export declare const se_CreateTokenWithIAMCommand: (
|
|
27
|
-
input: CreateTokenWithIAMCommandInput,
|
|
28
|
-
context: __SerdeContext
|
|
29
|
-
) => Promise<__HttpRequest>;
|
|
30
|
-
export declare const se_RegisterClientCommand: (
|
|
31
|
-
input: RegisterClientCommandInput,
|
|
32
|
-
context: __SerdeContext
|
|
33
|
-
) => Promise<__HttpRequest>;
|
|
34
|
-
export declare const se_StartDeviceAuthorizationCommand: (
|
|
35
|
-
input: StartDeviceAuthorizationCommandInput,
|
|
36
|
-
context: __SerdeContext
|
|
37
|
-
) => Promise<__HttpRequest>;
|
|
38
|
-
export declare const de_CreateTokenCommand: (
|
|
39
|
-
output: __HttpResponse,
|
|
40
|
-
context: __SerdeContext
|
|
41
|
-
) => Promise<CreateTokenCommandOutput>;
|
|
42
|
-
export declare const de_CreateTokenWithIAMCommand: (
|
|
43
|
-
output: __HttpResponse,
|
|
44
|
-
context: __SerdeContext
|
|
45
|
-
) => Promise<CreateTokenWithIAMCommandOutput>;
|
|
46
|
-
export declare const de_RegisterClientCommand: (
|
|
47
|
-
output: __HttpResponse,
|
|
48
|
-
context: __SerdeContext
|
|
49
|
-
) => Promise<RegisterClientCommandOutput>;
|
|
50
|
-
export declare const de_StartDeviceAuthorizationCommand: (
|
|
51
|
-
output: __HttpResponse,
|
|
52
|
-
context: __SerdeContext
|
|
53
|
-
) => Promise<StartDeviceAuthorizationCommandOutput>;
|