@aws-sdk/client-ram 3.315.0 → 3.316.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/README.md +76 -5
- package/dist-cjs/RAM.js +47 -350
- package/dist-cjs/commands/CreatePermissionCommand.js +45 -0
- package/dist-cjs/commands/CreatePermissionVersionCommand.js +45 -0
- package/dist-cjs/commands/DeletePermissionCommand.js +45 -0
- package/dist-cjs/commands/DeletePermissionVersionCommand.js +45 -0
- package/dist-cjs/commands/ListPermissionAssociationsCommand.js +45 -0
- package/dist-cjs/commands/ListReplacePermissionAssociationsWorkCommand.js +45 -0
- package/dist-cjs/commands/PromotePermissionCreatedFromPolicyCommand.js +45 -0
- package/dist-cjs/commands/ReplacePermissionAssociationsCommand.js +45 -0
- package/dist-cjs/commands/SetDefaultPermissionVersionCommand.js +45 -0
- package/dist-cjs/commands/index.js +9 -0
- package/dist-cjs/endpoint/ruleset.js +3 -3
- package/dist-cjs/models/models_0.js +104 -1
- package/dist-cjs/pagination/ListPermissionAssociationsPaginator.js +29 -0
- package/dist-cjs/pagination/ListReplacePermissionAssociationsWorkPaginator.js +29 -0
- package/dist-cjs/pagination/index.js +2 -0
- package/dist-cjs/protocols/Aws_restJson1.js +976 -129
- package/dist-es/RAM.js +47 -350
- package/dist-es/commands/CreatePermissionCommand.js +41 -0
- package/dist-es/commands/CreatePermissionVersionCommand.js +41 -0
- package/dist-es/commands/DeletePermissionCommand.js +41 -0
- package/dist-es/commands/DeletePermissionVersionCommand.js +41 -0
- package/dist-es/commands/ListPermissionAssociationsCommand.js +41 -0
- package/dist-es/commands/ListReplacePermissionAssociationsWorkCommand.js +41 -0
- package/dist-es/commands/PromotePermissionCreatedFromPolicyCommand.js +41 -0
- package/dist-es/commands/ReplacePermissionAssociationsCommand.js +41 -0
- package/dist-es/commands/SetDefaultPermissionVersionCommand.js +41 -0
- package/dist-es/commands/index.js +9 -0
- package/dist-es/endpoint/ruleset.js +3 -3
- package/dist-es/models/models_0.js +97 -0
- package/dist-es/pagination/ListPermissionAssociationsPaginator.js +25 -0
- package/dist-es/pagination/ListReplacePermissionAssociationsWorkPaginator.js +25 -0
- package/dist-es/pagination/index.js +2 -0
- package/dist-es/protocols/Aws_restJson1.js +949 -121
- package/dist-types/RAM.d.ts +114 -113
- package/dist-types/RAMClient.d.ts +15 -7
- package/dist-types/commands/AcceptResourceShareInvitationCommand.d.ts +16 -12
- package/dist-types/commands/AssociateResourceShareCommand.d.ts +19 -14
- package/dist-types/commands/AssociateResourceSharePermissionCommand.d.ts +9 -7
- package/dist-types/commands/CreatePermissionCommand.d.ts +109 -0
- package/dist-types/commands/CreatePermissionVersionCommand.d.ts +106 -0
- package/dist-types/commands/CreateResourceShareCommand.d.ts +19 -13
- package/dist-types/commands/DeletePermissionCommand.d.ts +91 -0
- package/dist-types/commands/DeletePermissionVersionCommand.d.ts +96 -0
- package/dist-types/commands/DeleteResourceShareCommand.d.ts +19 -14
- package/dist-types/commands/DisassociateResourceShareCommand.d.ts +19 -13
- package/dist-types/commands/DisassociateResourceSharePermissionCommand.d.ts +14 -11
- package/dist-types/commands/EnableSharingWithAwsOrganizationCommand.d.ts +14 -11
- package/dist-types/commands/GetPermissionCommand.d.ts +9 -7
- package/dist-types/commands/GetResourcePoliciesCommand.d.ts +10 -6
- package/dist-types/commands/GetResourceShareAssociationsCommand.d.ts +13 -8
- package/dist-types/commands/GetResourceShareInvitationsCommand.d.ts +14 -8
- package/dist-types/commands/GetResourceSharesCommand.d.ts +11 -6
- package/dist-types/commands/ListPendingInvitationResourcesCommand.d.ts +15 -9
- package/dist-types/commands/ListPermissionAssociationsCommand.d.ts +91 -0
- package/dist-types/commands/ListPermissionVersionsCommand.d.ts +11 -7
- package/dist-types/commands/ListPermissionsCommand.d.ts +9 -5
- package/dist-types/commands/ListPrincipalsCommand.d.ts +10 -6
- package/dist-types/commands/ListReplacePermissionAssociationsWorkCommand.d.ts +84 -0
- package/dist-types/commands/ListResourceSharePermissionsCommand.d.ts +11 -7
- package/dist-types/commands/ListResourceTypesCommand.d.ts +7 -4
- package/dist-types/commands/ListResourcesCommand.d.ts +11 -7
- package/dist-types/commands/PromotePermissionCreatedFromPolicyCommand.d.ts +119 -0
- package/dist-types/commands/PromoteResourceShareCreatedFromPolicyCommand.d.ts +34 -14
- package/dist-types/commands/RejectResourceShareInvitationCommand.d.ts +16 -12
- package/dist-types/commands/ReplacePermissionAssociationsCommand.d.ts +108 -0
- package/dist-types/commands/SetDefaultPermissionVersionCommand.d.ts +92 -0
- package/dist-types/commands/TagResourceCommand.d.ts +17 -11
- package/dist-types/commands/UntagResourceCommand.d.ts +14 -5
- package/dist-types/commands/UpdateResourceShareCommand.d.ts +13 -11
- package/dist-types/commands/index.d.ts +9 -0
- package/dist-types/endpoint/EndpointParameters.d.ts +1 -1
- package/dist-types/models/models_0.d.ts +1286 -195
- package/dist-types/pagination/ListPermissionAssociationsPaginator.d.ts +7 -0
- package/dist-types/pagination/ListReplacePermissionAssociationsWorkPaginator.d.ts +7 -0
- package/dist-types/pagination/index.d.ts +2 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +81 -0
- package/dist-types/ts3.4/RAM.d.ts +167 -1
- package/dist-types/ts3.4/RAMClient.d.ts +54 -0
- package/dist-types/ts3.4/commands/CreatePermissionCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/CreatePermissionVersionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/DeletePermissionCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DeletePermissionVersionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListPermissionAssociationsCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListReplacePermissionAssociationsWorkCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/PromotePermissionCreatedFromPolicyCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ReplacePermissionAssociationsCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/SetDefaultPermissionVersionCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/index.d.ts +9 -0
- package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +1 -1
- package/dist-types/ts3.4/models/models_0.d.ts +234 -19
- package/dist-types/ts3.4/pagination/ListPermissionAssociationsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListReplacePermissionAssociationsWorkPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +2 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +108 -0
- package/package.json +6 -6
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.de_GetResourceShareInvitationsCommand = exports.de_GetResourceShareAssociationsCommand = exports.de_GetResourcePoliciesCommand = exports.de_GetPermissionCommand = exports.de_EnableSharingWithAwsOrganizationCommand = exports.de_DisassociateResourceSharePermissionCommand = exports.de_DisassociateResourceShareCommand = exports.de_DeleteResourceShareCommand = exports.de_DeletePermissionVersionCommand = exports.de_DeletePermissionCommand = exports.de_CreateResourceShareCommand = exports.de_CreatePermissionVersionCommand = exports.de_CreatePermissionCommand = exports.de_AssociateResourceSharePermissionCommand = exports.de_AssociateResourceShareCommand = exports.de_AcceptResourceShareInvitationCommand = exports.se_UpdateResourceShareCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_SetDefaultPermissionVersionCommand = exports.se_ReplacePermissionAssociationsCommand = exports.se_RejectResourceShareInvitationCommand = exports.se_PromoteResourceShareCreatedFromPolicyCommand = exports.se_PromotePermissionCreatedFromPolicyCommand = exports.se_ListResourceTypesCommand = exports.se_ListResourceSharePermissionsCommand = exports.se_ListResourcesCommand = exports.se_ListReplacePermissionAssociationsWorkCommand = exports.se_ListPrincipalsCommand = exports.se_ListPermissionVersionsCommand = exports.se_ListPermissionsCommand = exports.se_ListPermissionAssociationsCommand = exports.se_ListPendingInvitationResourcesCommand = exports.se_GetResourceSharesCommand = exports.se_GetResourceShareInvitationsCommand = exports.se_GetResourceShareAssociationsCommand = exports.se_GetResourcePoliciesCommand = exports.se_GetPermissionCommand = exports.se_EnableSharingWithAwsOrganizationCommand = exports.se_DisassociateResourceSharePermissionCommand = exports.se_DisassociateResourceShareCommand = exports.se_DeleteResourceShareCommand = exports.se_DeletePermissionVersionCommand = exports.se_DeletePermissionCommand = exports.se_CreateResourceShareCommand = exports.se_CreatePermissionVersionCommand = exports.se_CreatePermissionCommand = exports.se_AssociateResourceSharePermissionCommand = exports.se_AssociateResourceShareCommand = exports.se_AcceptResourceShareInvitationCommand = void 0;
|
|
4
|
+
exports.de_UpdateResourceShareCommand = exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_SetDefaultPermissionVersionCommand = exports.de_ReplacePermissionAssociationsCommand = exports.de_RejectResourceShareInvitationCommand = exports.de_PromoteResourceShareCreatedFromPolicyCommand = exports.de_PromotePermissionCreatedFromPolicyCommand = exports.de_ListResourceTypesCommand = exports.de_ListResourceSharePermissionsCommand = exports.de_ListResourcesCommand = exports.de_ListReplacePermissionAssociationsWorkCommand = exports.de_ListPrincipalsCommand = exports.de_ListPermissionVersionsCommand = exports.de_ListPermissionsCommand = exports.de_ListPermissionAssociationsCommand = exports.de_ListPendingInvitationResourcesCommand = exports.de_GetResourceSharesCommand = void 0;
|
|
4
5
|
const protocol_http_1 = require("@aws-sdk/protocol-http");
|
|
5
6
|
const smithy_client_1 = require("@aws-sdk/smithy-client");
|
|
6
7
|
const models_0_1 = require("../models/models_0");
|
|
@@ -76,6 +77,54 @@ const se_AssociateResourceSharePermissionCommand = async (input, context) => {
|
|
|
76
77
|
});
|
|
77
78
|
};
|
|
78
79
|
exports.se_AssociateResourceSharePermissionCommand = se_AssociateResourceSharePermissionCommand;
|
|
80
|
+
const se_CreatePermissionCommand = async (input, context) => {
|
|
81
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
82
|
+
const headers = {
|
|
83
|
+
"content-type": "application/json",
|
|
84
|
+
};
|
|
85
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/createpermission";
|
|
86
|
+
let body;
|
|
87
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
88
|
+
clientToken: [],
|
|
89
|
+
name: [],
|
|
90
|
+
policyTemplate: [],
|
|
91
|
+
resourceType: [],
|
|
92
|
+
tags: (_) => (0, smithy_client_1._json)(_),
|
|
93
|
+
}));
|
|
94
|
+
return new protocol_http_1.HttpRequest({
|
|
95
|
+
protocol,
|
|
96
|
+
hostname,
|
|
97
|
+
port,
|
|
98
|
+
method: "POST",
|
|
99
|
+
headers,
|
|
100
|
+
path: resolvedPath,
|
|
101
|
+
body,
|
|
102
|
+
});
|
|
103
|
+
};
|
|
104
|
+
exports.se_CreatePermissionCommand = se_CreatePermissionCommand;
|
|
105
|
+
const se_CreatePermissionVersionCommand = async (input, context) => {
|
|
106
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
107
|
+
const headers = {
|
|
108
|
+
"content-type": "application/json",
|
|
109
|
+
};
|
|
110
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/createpermissionversion";
|
|
111
|
+
let body;
|
|
112
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
113
|
+
clientToken: [],
|
|
114
|
+
permissionArn: [],
|
|
115
|
+
policyTemplate: [],
|
|
116
|
+
}));
|
|
117
|
+
return new protocol_http_1.HttpRequest({
|
|
118
|
+
protocol,
|
|
119
|
+
hostname,
|
|
120
|
+
port,
|
|
121
|
+
method: "POST",
|
|
122
|
+
headers,
|
|
123
|
+
path: resolvedPath,
|
|
124
|
+
body,
|
|
125
|
+
});
|
|
126
|
+
};
|
|
127
|
+
exports.se_CreatePermissionVersionCommand = se_CreatePermissionVersionCommand;
|
|
79
128
|
const se_CreateResourceShareCommand = async (input, context) => {
|
|
80
129
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
81
130
|
const headers = {
|
|
@@ -103,6 +152,52 @@ const se_CreateResourceShareCommand = async (input, context) => {
|
|
|
103
152
|
});
|
|
104
153
|
};
|
|
105
154
|
exports.se_CreateResourceShareCommand = se_CreateResourceShareCommand;
|
|
155
|
+
const se_DeletePermissionCommand = async (input, context) => {
|
|
156
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
157
|
+
const headers = {};
|
|
158
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/deletepermission";
|
|
159
|
+
const query = (0, smithy_client_1.map)({
|
|
160
|
+
permissionArn: [, (0, smithy_client_1.expectNonNull)(input.permissionArn, `permissionArn`)],
|
|
161
|
+
clientToken: [, input.clientToken],
|
|
162
|
+
});
|
|
163
|
+
let body;
|
|
164
|
+
return new protocol_http_1.HttpRequest({
|
|
165
|
+
protocol,
|
|
166
|
+
hostname,
|
|
167
|
+
port,
|
|
168
|
+
method: "DELETE",
|
|
169
|
+
headers,
|
|
170
|
+
path: resolvedPath,
|
|
171
|
+
query,
|
|
172
|
+
body,
|
|
173
|
+
});
|
|
174
|
+
};
|
|
175
|
+
exports.se_DeletePermissionCommand = se_DeletePermissionCommand;
|
|
176
|
+
const se_DeletePermissionVersionCommand = async (input, context) => {
|
|
177
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
178
|
+
const headers = {};
|
|
179
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/deletepermissionversion";
|
|
180
|
+
const query = (0, smithy_client_1.map)({
|
|
181
|
+
permissionArn: [, (0, smithy_client_1.expectNonNull)(input.permissionArn, `permissionArn`)],
|
|
182
|
+
permissionVersion: [
|
|
183
|
+
(0, smithy_client_1.expectNonNull)(input.permissionVersion, `permissionVersion`) != null,
|
|
184
|
+
() => input.permissionVersion.toString(),
|
|
185
|
+
],
|
|
186
|
+
clientToken: [, input.clientToken],
|
|
187
|
+
});
|
|
188
|
+
let body;
|
|
189
|
+
return new protocol_http_1.HttpRequest({
|
|
190
|
+
protocol,
|
|
191
|
+
hostname,
|
|
192
|
+
port,
|
|
193
|
+
method: "DELETE",
|
|
194
|
+
headers,
|
|
195
|
+
path: resolvedPath,
|
|
196
|
+
query,
|
|
197
|
+
body,
|
|
198
|
+
});
|
|
199
|
+
};
|
|
200
|
+
exports.se_DeletePermissionVersionCommand = se_DeletePermissionVersionCommand;
|
|
106
201
|
const se_DeleteResourceShareCommand = async (input, context) => {
|
|
107
202
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
108
203
|
const headers = {};
|
|
@@ -299,6 +394,7 @@ const se_GetResourceSharesCommand = async (input, context) => {
|
|
|
299
394
|
name: [],
|
|
300
395
|
nextToken: [],
|
|
301
396
|
permissionArn: [],
|
|
397
|
+
permissionVersion: [],
|
|
302
398
|
resourceOwner: [],
|
|
303
399
|
resourceShareArns: (_) => (0, smithy_client_1._json)(_),
|
|
304
400
|
resourceShareStatus: [],
|
|
@@ -339,6 +435,34 @@ const se_ListPendingInvitationResourcesCommand = async (input, context) => {
|
|
|
339
435
|
});
|
|
340
436
|
};
|
|
341
437
|
exports.se_ListPendingInvitationResourcesCommand = se_ListPendingInvitationResourcesCommand;
|
|
438
|
+
const se_ListPermissionAssociationsCommand = async (input, context) => {
|
|
439
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
440
|
+
const headers = {
|
|
441
|
+
"content-type": "application/json",
|
|
442
|
+
};
|
|
443
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/listpermissionassociations";
|
|
444
|
+
let body;
|
|
445
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
446
|
+
associationStatus: [],
|
|
447
|
+
defaultVersion: [],
|
|
448
|
+
featureSet: [],
|
|
449
|
+
maxResults: [],
|
|
450
|
+
nextToken: [],
|
|
451
|
+
permissionArn: [],
|
|
452
|
+
permissionVersion: [],
|
|
453
|
+
resourceType: [],
|
|
454
|
+
}));
|
|
455
|
+
return new protocol_http_1.HttpRequest({
|
|
456
|
+
protocol,
|
|
457
|
+
hostname,
|
|
458
|
+
port,
|
|
459
|
+
method: "POST",
|
|
460
|
+
headers,
|
|
461
|
+
path: resolvedPath,
|
|
462
|
+
body,
|
|
463
|
+
});
|
|
464
|
+
};
|
|
465
|
+
exports.se_ListPermissionAssociationsCommand = se_ListPermissionAssociationsCommand;
|
|
342
466
|
const se_ListPermissionsCommand = async (input, context) => {
|
|
343
467
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
344
468
|
const headers = {
|
|
@@ -349,6 +473,7 @@ const se_ListPermissionsCommand = async (input, context) => {
|
|
|
349
473
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
350
474
|
maxResults: [],
|
|
351
475
|
nextToken: [],
|
|
476
|
+
permissionType: [],
|
|
352
477
|
resourceType: [],
|
|
353
478
|
}));
|
|
354
479
|
return new protocol_http_1.HttpRequest({
|
|
@@ -412,6 +537,30 @@ const se_ListPrincipalsCommand = async (input, context) => {
|
|
|
412
537
|
});
|
|
413
538
|
};
|
|
414
539
|
exports.se_ListPrincipalsCommand = se_ListPrincipalsCommand;
|
|
540
|
+
const se_ListReplacePermissionAssociationsWorkCommand = async (input, context) => {
|
|
541
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
542
|
+
const headers = {
|
|
543
|
+
"content-type": "application/json",
|
|
544
|
+
};
|
|
545
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/listreplacepermissionassociationswork";
|
|
546
|
+
let body;
|
|
547
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
548
|
+
maxResults: [],
|
|
549
|
+
nextToken: [],
|
|
550
|
+
status: [],
|
|
551
|
+
workIds: (_) => (0, smithy_client_1._json)(_),
|
|
552
|
+
}));
|
|
553
|
+
return new protocol_http_1.HttpRequest({
|
|
554
|
+
protocol,
|
|
555
|
+
hostname,
|
|
556
|
+
port,
|
|
557
|
+
method: "POST",
|
|
558
|
+
headers,
|
|
559
|
+
path: resolvedPath,
|
|
560
|
+
body,
|
|
561
|
+
});
|
|
562
|
+
};
|
|
563
|
+
exports.se_ListReplacePermissionAssociationsWorkCommand = se_ListReplacePermissionAssociationsWorkCommand;
|
|
415
564
|
const se_ListResourcesCommand = async (input, context) => {
|
|
416
565
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
417
566
|
const headers = {
|
|
@@ -486,6 +635,29 @@ const se_ListResourceTypesCommand = async (input, context) => {
|
|
|
486
635
|
});
|
|
487
636
|
};
|
|
488
637
|
exports.se_ListResourceTypesCommand = se_ListResourceTypesCommand;
|
|
638
|
+
const se_PromotePermissionCreatedFromPolicyCommand = async (input, context) => {
|
|
639
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
640
|
+
const headers = {
|
|
641
|
+
"content-type": "application/json",
|
|
642
|
+
};
|
|
643
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/promotepermissioncreatedfrompolicy";
|
|
644
|
+
let body;
|
|
645
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
646
|
+
clientToken: [],
|
|
647
|
+
name: [],
|
|
648
|
+
permissionArn: [],
|
|
649
|
+
}));
|
|
650
|
+
return new protocol_http_1.HttpRequest({
|
|
651
|
+
protocol,
|
|
652
|
+
hostname,
|
|
653
|
+
port,
|
|
654
|
+
method: "POST",
|
|
655
|
+
headers,
|
|
656
|
+
path: resolvedPath,
|
|
657
|
+
body,
|
|
658
|
+
});
|
|
659
|
+
};
|
|
660
|
+
exports.se_PromotePermissionCreatedFromPolicyCommand = se_PromotePermissionCreatedFromPolicyCommand;
|
|
489
661
|
const se_PromoteResourceShareCreatedFromPolicyCommand = async (input, context) => {
|
|
490
662
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
491
663
|
const headers = {};
|
|
@@ -528,6 +700,53 @@ const se_RejectResourceShareInvitationCommand = async (input, context) => {
|
|
|
528
700
|
});
|
|
529
701
|
};
|
|
530
702
|
exports.se_RejectResourceShareInvitationCommand = se_RejectResourceShareInvitationCommand;
|
|
703
|
+
const se_ReplacePermissionAssociationsCommand = async (input, context) => {
|
|
704
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
705
|
+
const headers = {
|
|
706
|
+
"content-type": "application/json",
|
|
707
|
+
};
|
|
708
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/replacepermissionassociations";
|
|
709
|
+
let body;
|
|
710
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
711
|
+
clientToken: [],
|
|
712
|
+
fromPermissionArn: [],
|
|
713
|
+
fromPermissionVersion: [],
|
|
714
|
+
toPermissionArn: [],
|
|
715
|
+
}));
|
|
716
|
+
return new protocol_http_1.HttpRequest({
|
|
717
|
+
protocol,
|
|
718
|
+
hostname,
|
|
719
|
+
port,
|
|
720
|
+
method: "POST",
|
|
721
|
+
headers,
|
|
722
|
+
path: resolvedPath,
|
|
723
|
+
body,
|
|
724
|
+
});
|
|
725
|
+
};
|
|
726
|
+
exports.se_ReplacePermissionAssociationsCommand = se_ReplacePermissionAssociationsCommand;
|
|
727
|
+
const se_SetDefaultPermissionVersionCommand = async (input, context) => {
|
|
728
|
+
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
729
|
+
const headers = {
|
|
730
|
+
"content-type": "application/json",
|
|
731
|
+
};
|
|
732
|
+
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/setdefaultpermissionversion";
|
|
733
|
+
let body;
|
|
734
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
735
|
+
clientToken: [],
|
|
736
|
+
permissionArn: [],
|
|
737
|
+
permissionVersion: [],
|
|
738
|
+
}));
|
|
739
|
+
return new protocol_http_1.HttpRequest({
|
|
740
|
+
protocol,
|
|
741
|
+
hostname,
|
|
742
|
+
port,
|
|
743
|
+
method: "POST",
|
|
744
|
+
headers,
|
|
745
|
+
path: resolvedPath,
|
|
746
|
+
body,
|
|
747
|
+
});
|
|
748
|
+
};
|
|
749
|
+
exports.se_SetDefaultPermissionVersionCommand = se_SetDefaultPermissionVersionCommand;
|
|
531
750
|
const se_TagResourceCommand = async (input, context) => {
|
|
532
751
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
533
752
|
const headers = {
|
|
@@ -536,6 +755,7 @@ const se_TagResourceCommand = async (input, context) => {
|
|
|
536
755
|
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tagresource";
|
|
537
756
|
let body;
|
|
538
757
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
758
|
+
resourceArn: [],
|
|
539
759
|
resourceShareArn: [],
|
|
540
760
|
tags: (_) => (0, smithy_client_1._json)(_),
|
|
541
761
|
}));
|
|
@@ -558,6 +778,7 @@ const se_UntagResourceCommand = async (input, context) => {
|
|
|
558
778
|
const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/untagresource";
|
|
559
779
|
let body;
|
|
560
780
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
781
|
+
resourceArn: [],
|
|
561
782
|
resourceShareArn: [],
|
|
562
783
|
tagKeys: (_) => (0, smithy_client_1._json)(_),
|
|
563
784
|
}));
|
|
@@ -776,9 +997,9 @@ const de_AssociateResourceSharePermissionCommandError = async (output, context)
|
|
|
776
997
|
});
|
|
777
998
|
}
|
|
778
999
|
};
|
|
779
|
-
const
|
|
1000
|
+
const de_CreatePermissionCommand = async (output, context) => {
|
|
780
1001
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
781
|
-
return
|
|
1002
|
+
return de_CreatePermissionCommandError(output, context);
|
|
782
1003
|
}
|
|
783
1004
|
const contents = (0, smithy_client_1.map)({
|
|
784
1005
|
$metadata: deserializeMetadata(output),
|
|
@@ -786,13 +1007,13 @@ const de_CreateResourceShareCommand = async (output, context) => {
|
|
|
786
1007
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
787
1008
|
const doc = (0, smithy_client_1.take)(data, {
|
|
788
1009
|
clientToken: smithy_client_1.expectString,
|
|
789
|
-
|
|
1010
|
+
permission: (_) => de_ResourceSharePermissionSummary(_, context),
|
|
790
1011
|
});
|
|
791
1012
|
Object.assign(contents, doc);
|
|
792
1013
|
return contents;
|
|
793
1014
|
};
|
|
794
|
-
exports.
|
|
795
|
-
const
|
|
1015
|
+
exports.de_CreatePermissionCommand = de_CreatePermissionCommand;
|
|
1016
|
+
const de_CreatePermissionCommandError = async (output, context) => {
|
|
796
1017
|
const parsedOutput = {
|
|
797
1018
|
...output,
|
|
798
1019
|
body: await parseErrorBody(output.body, context),
|
|
@@ -808,30 +1029,27 @@ const de_CreateResourceShareCommandError = async (output, context) => {
|
|
|
808
1029
|
case "InvalidParameterException":
|
|
809
1030
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
810
1031
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
811
|
-
case "
|
|
812
|
-
case "com.amazonaws.ram#
|
|
813
|
-
throw await
|
|
814
|
-
case "
|
|
815
|
-
case "com.amazonaws.ram#
|
|
816
|
-
throw await
|
|
1032
|
+
case "InvalidPolicyException":
|
|
1033
|
+
case "com.amazonaws.ram#InvalidPolicyException":
|
|
1034
|
+
throw await de_InvalidPolicyExceptionRes(parsedOutput, context);
|
|
1035
|
+
case "MalformedPolicyTemplateException":
|
|
1036
|
+
case "com.amazonaws.ram#MalformedPolicyTemplateException":
|
|
1037
|
+
throw await de_MalformedPolicyTemplateExceptionRes(parsedOutput, context);
|
|
817
1038
|
case "OperationNotPermittedException":
|
|
818
1039
|
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
819
1040
|
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
820
|
-
case "
|
|
821
|
-
case "com.amazonaws.ram#
|
|
822
|
-
throw await
|
|
1041
|
+
case "PermissionAlreadyExistsException":
|
|
1042
|
+
case "com.amazonaws.ram#PermissionAlreadyExistsException":
|
|
1043
|
+
throw await de_PermissionAlreadyExistsExceptionRes(parsedOutput, context);
|
|
1044
|
+
case "PermissionLimitExceededException":
|
|
1045
|
+
case "com.amazonaws.ram#PermissionLimitExceededException":
|
|
1046
|
+
throw await de_PermissionLimitExceededExceptionRes(parsedOutput, context);
|
|
823
1047
|
case "ServerInternalException":
|
|
824
1048
|
case "com.amazonaws.ram#ServerInternalException":
|
|
825
1049
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
826
1050
|
case "ServiceUnavailableException":
|
|
827
1051
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
828
1052
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
829
|
-
case "TagPolicyViolationException":
|
|
830
|
-
case "com.amazonaws.ram#TagPolicyViolationException":
|
|
831
|
-
throw await de_TagPolicyViolationExceptionRes(parsedOutput, context);
|
|
832
|
-
case "UnknownResourceException":
|
|
833
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
834
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
835
1053
|
default:
|
|
836
1054
|
const parsedBody = parsedOutput.body;
|
|
837
1055
|
return throwDefaultError({
|
|
@@ -841,9 +1059,9 @@ const de_CreateResourceShareCommandError = async (output, context) => {
|
|
|
841
1059
|
});
|
|
842
1060
|
}
|
|
843
1061
|
};
|
|
844
|
-
const
|
|
1062
|
+
const de_CreatePermissionVersionCommand = async (output, context) => {
|
|
845
1063
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
846
|
-
return
|
|
1064
|
+
return de_CreatePermissionVersionCommandError(output, context);
|
|
847
1065
|
}
|
|
848
1066
|
const contents = (0, smithy_client_1.map)({
|
|
849
1067
|
$metadata: deserializeMetadata(output),
|
|
@@ -851,13 +1069,13 @@ const de_DeleteResourceShareCommand = async (output, context) => {
|
|
|
851
1069
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
852
1070
|
const doc = (0, smithy_client_1.take)(data, {
|
|
853
1071
|
clientToken: smithy_client_1.expectString,
|
|
854
|
-
|
|
1072
|
+
permission: (_) => de_ResourceSharePermissionDetail(_, context),
|
|
855
1073
|
});
|
|
856
1074
|
Object.assign(contents, doc);
|
|
857
1075
|
return contents;
|
|
858
1076
|
};
|
|
859
|
-
exports.
|
|
860
|
-
const
|
|
1077
|
+
exports.de_CreatePermissionVersionCommand = de_CreatePermissionVersionCommand;
|
|
1078
|
+
const de_CreatePermissionVersionCommandError = async (output, context) => {
|
|
861
1079
|
const parsedOutput = {
|
|
862
1080
|
...output,
|
|
863
1081
|
body: await parseErrorBody(output.body, context),
|
|
@@ -873,15 +1091,18 @@ const de_DeleteResourceShareCommandError = async (output, context) => {
|
|
|
873
1091
|
case "InvalidParameterException":
|
|
874
1092
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
875
1093
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
876
|
-
case "
|
|
877
|
-
case "com.amazonaws.ram#
|
|
878
|
-
throw await
|
|
1094
|
+
case "InvalidPolicyException":
|
|
1095
|
+
case "com.amazonaws.ram#InvalidPolicyException":
|
|
1096
|
+
throw await de_InvalidPolicyExceptionRes(parsedOutput, context);
|
|
879
1097
|
case "MalformedArnException":
|
|
880
1098
|
case "com.amazonaws.ram#MalformedArnException":
|
|
881
1099
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
882
|
-
case "
|
|
883
|
-
case "com.amazonaws.ram#
|
|
884
|
-
throw await
|
|
1100
|
+
case "MalformedPolicyTemplateException":
|
|
1101
|
+
case "com.amazonaws.ram#MalformedPolicyTemplateException":
|
|
1102
|
+
throw await de_MalformedPolicyTemplateExceptionRes(parsedOutput, context);
|
|
1103
|
+
case "PermissionVersionsLimitExceededException":
|
|
1104
|
+
case "com.amazonaws.ram#PermissionVersionsLimitExceededException":
|
|
1105
|
+
throw await de_PermissionVersionsLimitExceededExceptionRes(parsedOutput, context);
|
|
885
1106
|
case "ServerInternalException":
|
|
886
1107
|
case "com.amazonaws.ram#ServerInternalException":
|
|
887
1108
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
@@ -900,9 +1121,9 @@ const de_DeleteResourceShareCommandError = async (output, context) => {
|
|
|
900
1121
|
});
|
|
901
1122
|
}
|
|
902
1123
|
};
|
|
903
|
-
const
|
|
1124
|
+
const de_CreateResourceShareCommand = async (output, context) => {
|
|
904
1125
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
905
|
-
return
|
|
1126
|
+
return de_CreateResourceShareCommandError(output, context);
|
|
906
1127
|
}
|
|
907
1128
|
const contents = (0, smithy_client_1.map)({
|
|
908
1129
|
$metadata: deserializeMetadata(output),
|
|
@@ -910,13 +1131,13 @@ const de_DisassociateResourceShareCommand = async (output, context) => {
|
|
|
910
1131
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
911
1132
|
const doc = (0, smithy_client_1.take)(data, {
|
|
912
1133
|
clientToken: smithy_client_1.expectString,
|
|
913
|
-
|
|
1134
|
+
resourceShare: (_) => de_ResourceShare(_, context),
|
|
914
1135
|
});
|
|
915
1136
|
Object.assign(contents, doc);
|
|
916
1137
|
return contents;
|
|
917
1138
|
};
|
|
918
|
-
exports.
|
|
919
|
-
const
|
|
1139
|
+
exports.de_CreateResourceShareCommand = de_CreateResourceShareCommand;
|
|
1140
|
+
const de_CreateResourceShareCommandError = async (output, context) => {
|
|
920
1141
|
const parsedOutput = {
|
|
921
1142
|
...output,
|
|
922
1143
|
body: await parseErrorBody(output.body, context),
|
|
@@ -950,6 +1171,9 @@ const de_DisassociateResourceShareCommandError = async (output, context) => {
|
|
|
950
1171
|
case "ServiceUnavailableException":
|
|
951
1172
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
952
1173
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1174
|
+
case "TagPolicyViolationException":
|
|
1175
|
+
case "com.amazonaws.ram#TagPolicyViolationException":
|
|
1176
|
+
throw await de_TagPolicyViolationExceptionRes(parsedOutput, context);
|
|
953
1177
|
case "UnknownResourceException":
|
|
954
1178
|
case "com.amazonaws.ram#UnknownResourceException":
|
|
955
1179
|
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
@@ -962,9 +1186,9 @@ const de_DisassociateResourceShareCommandError = async (output, context) => {
|
|
|
962
1186
|
});
|
|
963
1187
|
}
|
|
964
1188
|
};
|
|
965
|
-
const
|
|
1189
|
+
const de_DeletePermissionCommand = async (output, context) => {
|
|
966
1190
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
967
|
-
return
|
|
1191
|
+
return de_DeletePermissionCommandError(output, context);
|
|
968
1192
|
}
|
|
969
1193
|
const contents = (0, smithy_client_1.map)({
|
|
970
1194
|
$metadata: deserializeMetadata(output),
|
|
@@ -972,28 +1196,26 @@ const de_DisassociateResourceSharePermissionCommand = async (output, context) =>
|
|
|
972
1196
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
973
1197
|
const doc = (0, smithy_client_1.take)(data, {
|
|
974
1198
|
clientToken: smithy_client_1.expectString,
|
|
1199
|
+
permissionStatus: smithy_client_1.expectString,
|
|
975
1200
|
returnValue: smithy_client_1.expectBoolean,
|
|
976
1201
|
});
|
|
977
1202
|
Object.assign(contents, doc);
|
|
978
1203
|
return contents;
|
|
979
1204
|
};
|
|
980
|
-
exports.
|
|
981
|
-
const
|
|
1205
|
+
exports.de_DeletePermissionCommand = de_DeletePermissionCommand;
|
|
1206
|
+
const de_DeletePermissionCommandError = async (output, context) => {
|
|
982
1207
|
const parsedOutput = {
|
|
983
1208
|
...output,
|
|
984
1209
|
body: await parseErrorBody(output.body, context),
|
|
985
1210
|
};
|
|
986
1211
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
987
1212
|
switch (errorCode) {
|
|
1213
|
+
case "IdempotentParameterMismatchException":
|
|
1214
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1215
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
988
1216
|
case "InvalidClientTokenException":
|
|
989
1217
|
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
990
1218
|
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
991
|
-
case "InvalidParameterException":
|
|
992
|
-
case "com.amazonaws.ram#InvalidParameterException":
|
|
993
|
-
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
994
|
-
case "InvalidStateTransitionException":
|
|
995
|
-
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
996
|
-
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
997
1219
|
case "MalformedArnException":
|
|
998
1220
|
case "com.amazonaws.ram#MalformedArnException":
|
|
999
1221
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
@@ -1018,28 +1240,42 @@ const de_DisassociateResourceSharePermissionCommandError = async (output, contex
|
|
|
1018
1240
|
});
|
|
1019
1241
|
}
|
|
1020
1242
|
};
|
|
1021
|
-
const
|
|
1243
|
+
const de_DeletePermissionVersionCommand = async (output, context) => {
|
|
1022
1244
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1023
|
-
return
|
|
1245
|
+
return de_DeletePermissionVersionCommandError(output, context);
|
|
1024
1246
|
}
|
|
1025
1247
|
const contents = (0, smithy_client_1.map)({
|
|
1026
1248
|
$metadata: deserializeMetadata(output),
|
|
1027
1249
|
});
|
|
1028
1250
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1029
1251
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1252
|
+
clientToken: smithy_client_1.expectString,
|
|
1253
|
+
permissionStatus: smithy_client_1.expectString,
|
|
1030
1254
|
returnValue: smithy_client_1.expectBoolean,
|
|
1031
1255
|
});
|
|
1032
1256
|
Object.assign(contents, doc);
|
|
1033
1257
|
return contents;
|
|
1034
1258
|
};
|
|
1035
|
-
exports.
|
|
1036
|
-
const
|
|
1259
|
+
exports.de_DeletePermissionVersionCommand = de_DeletePermissionVersionCommand;
|
|
1260
|
+
const de_DeletePermissionVersionCommandError = async (output, context) => {
|
|
1037
1261
|
const parsedOutput = {
|
|
1038
1262
|
...output,
|
|
1039
1263
|
body: await parseErrorBody(output.body, context),
|
|
1040
1264
|
};
|
|
1041
1265
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1042
1266
|
switch (errorCode) {
|
|
1267
|
+
case "IdempotentParameterMismatchException":
|
|
1268
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1269
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
1270
|
+
case "InvalidClientTokenException":
|
|
1271
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1272
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1273
|
+
case "InvalidParameterException":
|
|
1274
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1275
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1276
|
+
case "MalformedArnException":
|
|
1277
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1278
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1043
1279
|
case "OperationNotPermittedException":
|
|
1044
1280
|
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1045
1281
|
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
@@ -1049,6 +1285,9 @@ const de_EnableSharingWithAwsOrganizationCommandError = async (output, context)
|
|
|
1049
1285
|
case "ServiceUnavailableException":
|
|
1050
1286
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1051
1287
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1288
|
+
case "UnknownResourceException":
|
|
1289
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
1290
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1052
1291
|
default:
|
|
1053
1292
|
const parsedBody = parsedOutput.body;
|
|
1054
1293
|
return throwDefaultError({
|
|
@@ -1058,7 +1297,224 @@ const de_EnableSharingWithAwsOrganizationCommandError = async (output, context)
|
|
|
1058
1297
|
});
|
|
1059
1298
|
}
|
|
1060
1299
|
};
|
|
1061
|
-
const
|
|
1300
|
+
const de_DeleteResourceShareCommand = async (output, context) => {
|
|
1301
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1302
|
+
return de_DeleteResourceShareCommandError(output, context);
|
|
1303
|
+
}
|
|
1304
|
+
const contents = (0, smithy_client_1.map)({
|
|
1305
|
+
$metadata: deserializeMetadata(output),
|
|
1306
|
+
});
|
|
1307
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1308
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1309
|
+
clientToken: smithy_client_1.expectString,
|
|
1310
|
+
returnValue: smithy_client_1.expectBoolean,
|
|
1311
|
+
});
|
|
1312
|
+
Object.assign(contents, doc);
|
|
1313
|
+
return contents;
|
|
1314
|
+
};
|
|
1315
|
+
exports.de_DeleteResourceShareCommand = de_DeleteResourceShareCommand;
|
|
1316
|
+
const de_DeleteResourceShareCommandError = async (output, context) => {
|
|
1317
|
+
const parsedOutput = {
|
|
1318
|
+
...output,
|
|
1319
|
+
body: await parseErrorBody(output.body, context),
|
|
1320
|
+
};
|
|
1321
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1322
|
+
switch (errorCode) {
|
|
1323
|
+
case "IdempotentParameterMismatchException":
|
|
1324
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1325
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
1326
|
+
case "InvalidClientTokenException":
|
|
1327
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1328
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1329
|
+
case "InvalidParameterException":
|
|
1330
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1331
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1332
|
+
case "InvalidStateTransitionException":
|
|
1333
|
+
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1334
|
+
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1335
|
+
case "MalformedArnException":
|
|
1336
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1337
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1338
|
+
case "OperationNotPermittedException":
|
|
1339
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1340
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1341
|
+
case "ServerInternalException":
|
|
1342
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1343
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1344
|
+
case "ServiceUnavailableException":
|
|
1345
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1346
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1347
|
+
case "UnknownResourceException":
|
|
1348
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
1349
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1350
|
+
default:
|
|
1351
|
+
const parsedBody = parsedOutput.body;
|
|
1352
|
+
return throwDefaultError({
|
|
1353
|
+
output,
|
|
1354
|
+
parsedBody,
|
|
1355
|
+
errorCode,
|
|
1356
|
+
});
|
|
1357
|
+
}
|
|
1358
|
+
};
|
|
1359
|
+
const de_DisassociateResourceShareCommand = async (output, context) => {
|
|
1360
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1361
|
+
return de_DisassociateResourceShareCommandError(output, context);
|
|
1362
|
+
}
|
|
1363
|
+
const contents = (0, smithy_client_1.map)({
|
|
1364
|
+
$metadata: deserializeMetadata(output),
|
|
1365
|
+
});
|
|
1366
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1367
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1368
|
+
clientToken: smithy_client_1.expectString,
|
|
1369
|
+
resourceShareAssociations: (_) => de_ResourceShareAssociationList(_, context),
|
|
1370
|
+
});
|
|
1371
|
+
Object.assign(contents, doc);
|
|
1372
|
+
return contents;
|
|
1373
|
+
};
|
|
1374
|
+
exports.de_DisassociateResourceShareCommand = de_DisassociateResourceShareCommand;
|
|
1375
|
+
const de_DisassociateResourceShareCommandError = async (output, context) => {
|
|
1376
|
+
const parsedOutput = {
|
|
1377
|
+
...output,
|
|
1378
|
+
body: await parseErrorBody(output.body, context),
|
|
1379
|
+
};
|
|
1380
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1381
|
+
switch (errorCode) {
|
|
1382
|
+
case "IdempotentParameterMismatchException":
|
|
1383
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
1384
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
1385
|
+
case "InvalidClientTokenException":
|
|
1386
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1387
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1388
|
+
case "InvalidParameterException":
|
|
1389
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1390
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1391
|
+
case "InvalidStateTransitionException":
|
|
1392
|
+
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1393
|
+
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1394
|
+
case "MalformedArnException":
|
|
1395
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1396
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1397
|
+
case "OperationNotPermittedException":
|
|
1398
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1399
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1400
|
+
case "ResourceShareLimitExceededException":
|
|
1401
|
+
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
1402
|
+
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
1403
|
+
case "ServerInternalException":
|
|
1404
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1405
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1406
|
+
case "ServiceUnavailableException":
|
|
1407
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1408
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1409
|
+
case "UnknownResourceException":
|
|
1410
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
1411
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1412
|
+
default:
|
|
1413
|
+
const parsedBody = parsedOutput.body;
|
|
1414
|
+
return throwDefaultError({
|
|
1415
|
+
output,
|
|
1416
|
+
parsedBody,
|
|
1417
|
+
errorCode,
|
|
1418
|
+
});
|
|
1419
|
+
}
|
|
1420
|
+
};
|
|
1421
|
+
const de_DisassociateResourceSharePermissionCommand = async (output, context) => {
|
|
1422
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1423
|
+
return de_DisassociateResourceSharePermissionCommandError(output, context);
|
|
1424
|
+
}
|
|
1425
|
+
const contents = (0, smithy_client_1.map)({
|
|
1426
|
+
$metadata: deserializeMetadata(output),
|
|
1427
|
+
});
|
|
1428
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1429
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1430
|
+
clientToken: smithy_client_1.expectString,
|
|
1431
|
+
returnValue: smithy_client_1.expectBoolean,
|
|
1432
|
+
});
|
|
1433
|
+
Object.assign(contents, doc);
|
|
1434
|
+
return contents;
|
|
1435
|
+
};
|
|
1436
|
+
exports.de_DisassociateResourceSharePermissionCommand = de_DisassociateResourceSharePermissionCommand;
|
|
1437
|
+
const de_DisassociateResourceSharePermissionCommandError = async (output, context) => {
|
|
1438
|
+
const parsedOutput = {
|
|
1439
|
+
...output,
|
|
1440
|
+
body: await parseErrorBody(output.body, context),
|
|
1441
|
+
};
|
|
1442
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1443
|
+
switch (errorCode) {
|
|
1444
|
+
case "InvalidClientTokenException":
|
|
1445
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1446
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1447
|
+
case "InvalidParameterException":
|
|
1448
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1449
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1450
|
+
case "InvalidStateTransitionException":
|
|
1451
|
+
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
1452
|
+
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1453
|
+
case "MalformedArnException":
|
|
1454
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1455
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1456
|
+
case "OperationNotPermittedException":
|
|
1457
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1458
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1459
|
+
case "ServerInternalException":
|
|
1460
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1461
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1462
|
+
case "ServiceUnavailableException":
|
|
1463
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1464
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1465
|
+
case "UnknownResourceException":
|
|
1466
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
1467
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1468
|
+
default:
|
|
1469
|
+
const parsedBody = parsedOutput.body;
|
|
1470
|
+
return throwDefaultError({
|
|
1471
|
+
output,
|
|
1472
|
+
parsedBody,
|
|
1473
|
+
errorCode,
|
|
1474
|
+
});
|
|
1475
|
+
}
|
|
1476
|
+
};
|
|
1477
|
+
const de_EnableSharingWithAwsOrganizationCommand = async (output, context) => {
|
|
1478
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1479
|
+
return de_EnableSharingWithAwsOrganizationCommandError(output, context);
|
|
1480
|
+
}
|
|
1481
|
+
const contents = (0, smithy_client_1.map)({
|
|
1482
|
+
$metadata: deserializeMetadata(output),
|
|
1483
|
+
});
|
|
1484
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1485
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1486
|
+
returnValue: smithy_client_1.expectBoolean,
|
|
1487
|
+
});
|
|
1488
|
+
Object.assign(contents, doc);
|
|
1489
|
+
return contents;
|
|
1490
|
+
};
|
|
1491
|
+
exports.de_EnableSharingWithAwsOrganizationCommand = de_EnableSharingWithAwsOrganizationCommand;
|
|
1492
|
+
const de_EnableSharingWithAwsOrganizationCommandError = async (output, context) => {
|
|
1493
|
+
const parsedOutput = {
|
|
1494
|
+
...output,
|
|
1495
|
+
body: await parseErrorBody(output.body, context),
|
|
1496
|
+
};
|
|
1497
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1498
|
+
switch (errorCode) {
|
|
1499
|
+
case "OperationNotPermittedException":
|
|
1500
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1501
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1502
|
+
case "ServerInternalException":
|
|
1503
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1504
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1505
|
+
case "ServiceUnavailableException":
|
|
1506
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1507
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1508
|
+
default:
|
|
1509
|
+
const parsedBody = parsedOutput.body;
|
|
1510
|
+
return throwDefaultError({
|
|
1511
|
+
output,
|
|
1512
|
+
parsedBody,
|
|
1513
|
+
errorCode,
|
|
1514
|
+
});
|
|
1515
|
+
}
|
|
1516
|
+
};
|
|
1517
|
+
const de_GetPermissionCommand = async (output, context) => {
|
|
1062
1518
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1063
1519
|
return de_GetPermissionCommandError(output, context);
|
|
1064
1520
|
}
|
|
@@ -1375,6 +1831,53 @@ const de_ListPendingInvitationResourcesCommandError = async (output, context) =>
|
|
|
1375
1831
|
});
|
|
1376
1832
|
}
|
|
1377
1833
|
};
|
|
1834
|
+
const de_ListPermissionAssociationsCommand = async (output, context) => {
|
|
1835
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1836
|
+
return de_ListPermissionAssociationsCommandError(output, context);
|
|
1837
|
+
}
|
|
1838
|
+
const contents = (0, smithy_client_1.map)({
|
|
1839
|
+
$metadata: deserializeMetadata(output),
|
|
1840
|
+
});
|
|
1841
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1842
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1843
|
+
nextToken: smithy_client_1.expectString,
|
|
1844
|
+
permissions: (_) => de_AssociatedPermissionList(_, context),
|
|
1845
|
+
});
|
|
1846
|
+
Object.assign(contents, doc);
|
|
1847
|
+
return contents;
|
|
1848
|
+
};
|
|
1849
|
+
exports.de_ListPermissionAssociationsCommand = de_ListPermissionAssociationsCommand;
|
|
1850
|
+
const de_ListPermissionAssociationsCommandError = async (output, context) => {
|
|
1851
|
+
const parsedOutput = {
|
|
1852
|
+
...output,
|
|
1853
|
+
body: await parseErrorBody(output.body, context),
|
|
1854
|
+
};
|
|
1855
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1856
|
+
switch (errorCode) {
|
|
1857
|
+
case "InvalidNextTokenException":
|
|
1858
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1859
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1860
|
+
case "InvalidParameterException":
|
|
1861
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1862
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1863
|
+
case "MalformedArnException":
|
|
1864
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1865
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1866
|
+
case "ServerInternalException":
|
|
1867
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1868
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1869
|
+
case "ServiceUnavailableException":
|
|
1870
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1871
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1872
|
+
default:
|
|
1873
|
+
const parsedBody = parsedOutput.body;
|
|
1874
|
+
return throwDefaultError({
|
|
1875
|
+
output,
|
|
1876
|
+
parsedBody,
|
|
1877
|
+
errorCode,
|
|
1878
|
+
});
|
|
1879
|
+
}
|
|
1880
|
+
};
|
|
1378
1881
|
const de_ListPermissionsCommand = async (output, context) => {
|
|
1379
1882
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1380
1883
|
return de_ListPermissionsCommandError(output, context);
|
|
@@ -1437,8 +1940,208 @@ const de_ListPermissionVersionsCommand = async (output, context) => {
|
|
|
1437
1940
|
Object.assign(contents, doc);
|
|
1438
1941
|
return contents;
|
|
1439
1942
|
};
|
|
1440
|
-
exports.de_ListPermissionVersionsCommand = de_ListPermissionVersionsCommand;
|
|
1441
|
-
const de_ListPermissionVersionsCommandError = async (output, context) => {
|
|
1943
|
+
exports.de_ListPermissionVersionsCommand = de_ListPermissionVersionsCommand;
|
|
1944
|
+
const de_ListPermissionVersionsCommandError = async (output, context) => {
|
|
1945
|
+
const parsedOutput = {
|
|
1946
|
+
...output,
|
|
1947
|
+
body: await parseErrorBody(output.body, context),
|
|
1948
|
+
};
|
|
1949
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1950
|
+
switch (errorCode) {
|
|
1951
|
+
case "InvalidNextTokenException":
|
|
1952
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1953
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1954
|
+
case "InvalidParameterException":
|
|
1955
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
1956
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1957
|
+
case "MalformedArnException":
|
|
1958
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
1959
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1960
|
+
case "OperationNotPermittedException":
|
|
1961
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1962
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1963
|
+
case "ServerInternalException":
|
|
1964
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
1965
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1966
|
+
case "ServiceUnavailableException":
|
|
1967
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1968
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1969
|
+
case "UnknownResourceException":
|
|
1970
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
1971
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1972
|
+
default:
|
|
1973
|
+
const parsedBody = parsedOutput.body;
|
|
1974
|
+
return throwDefaultError({
|
|
1975
|
+
output,
|
|
1976
|
+
parsedBody,
|
|
1977
|
+
errorCode,
|
|
1978
|
+
});
|
|
1979
|
+
}
|
|
1980
|
+
};
|
|
1981
|
+
const de_ListPrincipalsCommand = async (output, context) => {
|
|
1982
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1983
|
+
return de_ListPrincipalsCommandError(output, context);
|
|
1984
|
+
}
|
|
1985
|
+
const contents = (0, smithy_client_1.map)({
|
|
1986
|
+
$metadata: deserializeMetadata(output),
|
|
1987
|
+
});
|
|
1988
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1989
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1990
|
+
nextToken: smithy_client_1.expectString,
|
|
1991
|
+
principals: (_) => de_PrincipalList(_, context),
|
|
1992
|
+
});
|
|
1993
|
+
Object.assign(contents, doc);
|
|
1994
|
+
return contents;
|
|
1995
|
+
};
|
|
1996
|
+
exports.de_ListPrincipalsCommand = de_ListPrincipalsCommand;
|
|
1997
|
+
const de_ListPrincipalsCommandError = async (output, context) => {
|
|
1998
|
+
const parsedOutput = {
|
|
1999
|
+
...output,
|
|
2000
|
+
body: await parseErrorBody(output.body, context),
|
|
2001
|
+
};
|
|
2002
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2003
|
+
switch (errorCode) {
|
|
2004
|
+
case "InvalidNextTokenException":
|
|
2005
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
2006
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
2007
|
+
case "InvalidParameterException":
|
|
2008
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
2009
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2010
|
+
case "MalformedArnException":
|
|
2011
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
2012
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2013
|
+
case "ServerInternalException":
|
|
2014
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
2015
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2016
|
+
case "ServiceUnavailableException":
|
|
2017
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2018
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2019
|
+
case "UnknownResourceException":
|
|
2020
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
2021
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2022
|
+
default:
|
|
2023
|
+
const parsedBody = parsedOutput.body;
|
|
2024
|
+
return throwDefaultError({
|
|
2025
|
+
output,
|
|
2026
|
+
parsedBody,
|
|
2027
|
+
errorCode,
|
|
2028
|
+
});
|
|
2029
|
+
}
|
|
2030
|
+
};
|
|
2031
|
+
const de_ListReplacePermissionAssociationsWorkCommand = async (output, context) => {
|
|
2032
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2033
|
+
return de_ListReplacePermissionAssociationsWorkCommandError(output, context);
|
|
2034
|
+
}
|
|
2035
|
+
const contents = (0, smithy_client_1.map)({
|
|
2036
|
+
$metadata: deserializeMetadata(output),
|
|
2037
|
+
});
|
|
2038
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
2039
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2040
|
+
nextToken: smithy_client_1.expectString,
|
|
2041
|
+
replacePermissionAssociationsWorks: (_) => de_ReplacePermissionAssociationsWorkList(_, context),
|
|
2042
|
+
});
|
|
2043
|
+
Object.assign(contents, doc);
|
|
2044
|
+
return contents;
|
|
2045
|
+
};
|
|
2046
|
+
exports.de_ListReplacePermissionAssociationsWorkCommand = de_ListReplacePermissionAssociationsWorkCommand;
|
|
2047
|
+
const de_ListReplacePermissionAssociationsWorkCommandError = async (output, context) => {
|
|
2048
|
+
const parsedOutput = {
|
|
2049
|
+
...output,
|
|
2050
|
+
body: await parseErrorBody(output.body, context),
|
|
2051
|
+
};
|
|
2052
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2053
|
+
switch (errorCode) {
|
|
2054
|
+
case "InvalidNextTokenException":
|
|
2055
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
2056
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
2057
|
+
case "InvalidParameterException":
|
|
2058
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
2059
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2060
|
+
case "ServerInternalException":
|
|
2061
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
2062
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2063
|
+
case "ServiceUnavailableException":
|
|
2064
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2065
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2066
|
+
default:
|
|
2067
|
+
const parsedBody = parsedOutput.body;
|
|
2068
|
+
return throwDefaultError({
|
|
2069
|
+
output,
|
|
2070
|
+
parsedBody,
|
|
2071
|
+
errorCode,
|
|
2072
|
+
});
|
|
2073
|
+
}
|
|
2074
|
+
};
|
|
2075
|
+
const de_ListResourcesCommand = async (output, context) => {
|
|
2076
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2077
|
+
return de_ListResourcesCommandError(output, context);
|
|
2078
|
+
}
|
|
2079
|
+
const contents = (0, smithy_client_1.map)({
|
|
2080
|
+
$metadata: deserializeMetadata(output),
|
|
2081
|
+
});
|
|
2082
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
2083
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2084
|
+
nextToken: smithy_client_1.expectString,
|
|
2085
|
+
resources: (_) => de_ResourceList(_, context),
|
|
2086
|
+
});
|
|
2087
|
+
Object.assign(contents, doc);
|
|
2088
|
+
return contents;
|
|
2089
|
+
};
|
|
2090
|
+
exports.de_ListResourcesCommand = de_ListResourcesCommand;
|
|
2091
|
+
const de_ListResourcesCommandError = async (output, context) => {
|
|
2092
|
+
const parsedOutput = {
|
|
2093
|
+
...output,
|
|
2094
|
+
body: await parseErrorBody(output.body, context),
|
|
2095
|
+
};
|
|
2096
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2097
|
+
switch (errorCode) {
|
|
2098
|
+
case "InvalidNextTokenException":
|
|
2099
|
+
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
2100
|
+
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
2101
|
+
case "InvalidParameterException":
|
|
2102
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
2103
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2104
|
+
case "InvalidResourceTypeException":
|
|
2105
|
+
case "com.amazonaws.ram#InvalidResourceTypeException":
|
|
2106
|
+
throw await de_InvalidResourceTypeExceptionRes(parsedOutput, context);
|
|
2107
|
+
case "MalformedArnException":
|
|
2108
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
2109
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2110
|
+
case "ServerInternalException":
|
|
2111
|
+
case "com.amazonaws.ram#ServerInternalException":
|
|
2112
|
+
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
2113
|
+
case "ServiceUnavailableException":
|
|
2114
|
+
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
2115
|
+
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2116
|
+
case "UnknownResourceException":
|
|
2117
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
2118
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2119
|
+
default:
|
|
2120
|
+
const parsedBody = parsedOutput.body;
|
|
2121
|
+
return throwDefaultError({
|
|
2122
|
+
output,
|
|
2123
|
+
parsedBody,
|
|
2124
|
+
errorCode,
|
|
2125
|
+
});
|
|
2126
|
+
}
|
|
2127
|
+
};
|
|
2128
|
+
const de_ListResourceSharePermissionsCommand = async (output, context) => {
|
|
2129
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2130
|
+
return de_ListResourceSharePermissionsCommandError(output, context);
|
|
2131
|
+
}
|
|
2132
|
+
const contents = (0, smithy_client_1.map)({
|
|
2133
|
+
$metadata: deserializeMetadata(output),
|
|
2134
|
+
});
|
|
2135
|
+
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
2136
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2137
|
+
nextToken: smithy_client_1.expectString,
|
|
2138
|
+
permissions: (_) => de_ResourceSharePermissionList(_, context),
|
|
2139
|
+
});
|
|
2140
|
+
Object.assign(contents, doc);
|
|
2141
|
+
return contents;
|
|
2142
|
+
};
|
|
2143
|
+
exports.de_ListResourceSharePermissionsCommand = de_ListResourceSharePermissionsCommand;
|
|
2144
|
+
const de_ListResourceSharePermissionsCommandError = async (output, context) => {
|
|
1442
2145
|
const parsedOutput = {
|
|
1443
2146
|
...output,
|
|
1444
2147
|
body: await parseErrorBody(output.body, context),
|
|
@@ -1475,9 +2178,9 @@ const de_ListPermissionVersionsCommandError = async (output, context) => {
|
|
|
1475
2178
|
});
|
|
1476
2179
|
}
|
|
1477
2180
|
};
|
|
1478
|
-
const
|
|
2181
|
+
const de_ListResourceTypesCommand = async (output, context) => {
|
|
1479
2182
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1480
|
-
return
|
|
2183
|
+
return de_ListResourceTypesCommandError(output, context);
|
|
1481
2184
|
}
|
|
1482
2185
|
const contents = (0, smithy_client_1.map)({
|
|
1483
2186
|
$metadata: deserializeMetadata(output),
|
|
@@ -1485,13 +2188,13 @@ const de_ListPrincipalsCommand = async (output, context) => {
|
|
|
1485
2188
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1486
2189
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1487
2190
|
nextToken: smithy_client_1.expectString,
|
|
1488
|
-
|
|
2191
|
+
resourceTypes: smithy_client_1._json,
|
|
1489
2192
|
});
|
|
1490
2193
|
Object.assign(contents, doc);
|
|
1491
2194
|
return contents;
|
|
1492
2195
|
};
|
|
1493
|
-
exports.
|
|
1494
|
-
const
|
|
2196
|
+
exports.de_ListResourceTypesCommand = de_ListResourceTypesCommand;
|
|
2197
|
+
const de_ListResourceTypesCommandError = async (output, context) => {
|
|
1495
2198
|
const parsedOutput = {
|
|
1496
2199
|
...output,
|
|
1497
2200
|
body: await parseErrorBody(output.body, context),
|
|
@@ -1504,18 +2207,12 @@ const de_ListPrincipalsCommandError = async (output, context) => {
|
|
|
1504
2207
|
case "InvalidParameterException":
|
|
1505
2208
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
1506
2209
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1507
|
-
case "MalformedArnException":
|
|
1508
|
-
case "com.amazonaws.ram#MalformedArnException":
|
|
1509
|
-
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1510
2210
|
case "ServerInternalException":
|
|
1511
2211
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1512
2212
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1513
2213
|
case "ServiceUnavailableException":
|
|
1514
2214
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1515
2215
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
1516
|
-
case "UnknownResourceException":
|
|
1517
|
-
case "com.amazonaws.ram#UnknownResourceException":
|
|
1518
|
-
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1519
2216
|
default:
|
|
1520
2217
|
const parsedBody = parsedOutput.body;
|
|
1521
2218
|
return throwDefaultError({
|
|
@@ -1525,41 +2222,41 @@ const de_ListPrincipalsCommandError = async (output, context) => {
|
|
|
1525
2222
|
});
|
|
1526
2223
|
}
|
|
1527
2224
|
};
|
|
1528
|
-
const
|
|
2225
|
+
const de_PromotePermissionCreatedFromPolicyCommand = async (output, context) => {
|
|
1529
2226
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1530
|
-
return
|
|
2227
|
+
return de_PromotePermissionCreatedFromPolicyCommandError(output, context);
|
|
1531
2228
|
}
|
|
1532
2229
|
const contents = (0, smithy_client_1.map)({
|
|
1533
2230
|
$metadata: deserializeMetadata(output),
|
|
1534
2231
|
});
|
|
1535
2232
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1536
2233
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1537
|
-
|
|
1538
|
-
|
|
2234
|
+
clientToken: smithy_client_1.expectString,
|
|
2235
|
+
permission: (_) => de_ResourceSharePermissionSummary(_, context),
|
|
1539
2236
|
});
|
|
1540
2237
|
Object.assign(contents, doc);
|
|
1541
2238
|
return contents;
|
|
1542
2239
|
};
|
|
1543
|
-
exports.
|
|
1544
|
-
const
|
|
2240
|
+
exports.de_PromotePermissionCreatedFromPolicyCommand = de_PromotePermissionCreatedFromPolicyCommand;
|
|
2241
|
+
const de_PromotePermissionCreatedFromPolicyCommandError = async (output, context) => {
|
|
1545
2242
|
const parsedOutput = {
|
|
1546
2243
|
...output,
|
|
1547
2244
|
body: await parseErrorBody(output.body, context),
|
|
1548
2245
|
};
|
|
1549
2246
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1550
2247
|
switch (errorCode) {
|
|
1551
|
-
case "InvalidNextTokenException":
|
|
1552
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1553
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1554
2248
|
case "InvalidParameterException":
|
|
1555
2249
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
1556
2250
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1557
|
-
case "InvalidResourceTypeException":
|
|
1558
|
-
case "com.amazonaws.ram#InvalidResourceTypeException":
|
|
1559
|
-
throw await de_InvalidResourceTypeExceptionRes(parsedOutput, context);
|
|
1560
2251
|
case "MalformedArnException":
|
|
1561
2252
|
case "com.amazonaws.ram#MalformedArnException":
|
|
1562
2253
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2254
|
+
case "MissingRequiredParameterException":
|
|
2255
|
+
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
2256
|
+
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
2257
|
+
case "OperationNotPermittedException":
|
|
2258
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2259
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1563
2260
|
case "ServerInternalException":
|
|
1564
2261
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1565
2262
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
@@ -1578,41 +2275,46 @@ const de_ListResourcesCommandError = async (output, context) => {
|
|
|
1578
2275
|
});
|
|
1579
2276
|
}
|
|
1580
2277
|
};
|
|
1581
|
-
const
|
|
2278
|
+
const de_PromoteResourceShareCreatedFromPolicyCommand = async (output, context) => {
|
|
1582
2279
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1583
|
-
return
|
|
2280
|
+
return de_PromoteResourceShareCreatedFromPolicyCommandError(output, context);
|
|
1584
2281
|
}
|
|
1585
2282
|
const contents = (0, smithy_client_1.map)({
|
|
1586
2283
|
$metadata: deserializeMetadata(output),
|
|
1587
2284
|
});
|
|
1588
2285
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1589
2286
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1590
|
-
|
|
1591
|
-
permissions: (_) => de_ResourceSharePermissionList(_, context),
|
|
2287
|
+
returnValue: smithy_client_1.expectBoolean,
|
|
1592
2288
|
});
|
|
1593
2289
|
Object.assign(contents, doc);
|
|
1594
2290
|
return contents;
|
|
1595
2291
|
};
|
|
1596
|
-
exports.
|
|
1597
|
-
const
|
|
2292
|
+
exports.de_PromoteResourceShareCreatedFromPolicyCommand = de_PromoteResourceShareCreatedFromPolicyCommand;
|
|
2293
|
+
const de_PromoteResourceShareCreatedFromPolicyCommandError = async (output, context) => {
|
|
1598
2294
|
const parsedOutput = {
|
|
1599
2295
|
...output,
|
|
1600
2296
|
body: await parseErrorBody(output.body, context),
|
|
1601
2297
|
};
|
|
1602
2298
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1603
2299
|
switch (errorCode) {
|
|
1604
|
-
case "InvalidNextTokenException":
|
|
1605
|
-
case "com.amazonaws.ram#InvalidNextTokenException":
|
|
1606
|
-
throw await de_InvalidNextTokenExceptionRes(parsedOutput, context);
|
|
1607
2300
|
case "InvalidParameterException":
|
|
1608
2301
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
1609
2302
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2303
|
+
case "InvalidStateTransitionException":
|
|
2304
|
+
case "com.amazonaws.ram#InvalidStateTransitionException":
|
|
2305
|
+
throw await de_InvalidStateTransitionExceptionRes(parsedOutput, context);
|
|
1610
2306
|
case "MalformedArnException":
|
|
1611
2307
|
case "com.amazonaws.ram#MalformedArnException":
|
|
1612
2308
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2309
|
+
case "MissingRequiredParameterException":
|
|
2310
|
+
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
2311
|
+
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
1613
2312
|
case "OperationNotPermittedException":
|
|
1614
2313
|
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1615
2314
|
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
2315
|
+
case "ResourceShareLimitExceededException":
|
|
2316
|
+
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
2317
|
+
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
1616
2318
|
case "ServerInternalException":
|
|
1617
2319
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1618
2320
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
@@ -1622,6 +2324,9 @@ const de_ListResourceSharePermissionsCommandError = async (output, context) => {
|
|
|
1622
2324
|
case "UnknownResourceException":
|
|
1623
2325
|
case "com.amazonaws.ram#UnknownResourceException":
|
|
1624
2326
|
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
2327
|
+
case "UnmatchedPolicyPermissionException":
|
|
2328
|
+
case "com.amazonaws.ram#UnmatchedPolicyPermissionException":
|
|
2329
|
+
throw await de_UnmatchedPolicyPermissionExceptionRes(parsedOutput, context);
|
|
1625
2330
|
default:
|
|
1626
2331
|
const parsedBody = parsedOutput.body;
|
|
1627
2332
|
return throwDefaultError({
|
|
@@ -1631,35 +2336,53 @@ const de_ListResourceSharePermissionsCommandError = async (output, context) => {
|
|
|
1631
2336
|
});
|
|
1632
2337
|
}
|
|
1633
2338
|
};
|
|
1634
|
-
const
|
|
2339
|
+
const de_RejectResourceShareInvitationCommand = async (output, context) => {
|
|
1635
2340
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1636
|
-
return
|
|
2341
|
+
return de_RejectResourceShareInvitationCommandError(output, context);
|
|
1637
2342
|
}
|
|
1638
2343
|
const contents = (0, smithy_client_1.map)({
|
|
1639
2344
|
$metadata: deserializeMetadata(output),
|
|
1640
2345
|
});
|
|
1641
2346
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1642
2347
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1643
|
-
|
|
1644
|
-
|
|
2348
|
+
clientToken: smithy_client_1.expectString,
|
|
2349
|
+
resourceShareInvitation: (_) => de_ResourceShareInvitation(_, context),
|
|
1645
2350
|
});
|
|
1646
2351
|
Object.assign(contents, doc);
|
|
1647
2352
|
return contents;
|
|
1648
2353
|
};
|
|
1649
|
-
exports.
|
|
1650
|
-
const
|
|
2354
|
+
exports.de_RejectResourceShareInvitationCommand = de_RejectResourceShareInvitationCommand;
|
|
2355
|
+
const de_RejectResourceShareInvitationCommandError = async (output, context) => {
|
|
1651
2356
|
const parsedOutput = {
|
|
1652
2357
|
...output,
|
|
1653
2358
|
body: await parseErrorBody(output.body, context),
|
|
1654
2359
|
};
|
|
1655
2360
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1656
2361
|
switch (errorCode) {
|
|
1657
|
-
case "
|
|
1658
|
-
case "com.amazonaws.ram#
|
|
1659
|
-
throw await
|
|
1660
|
-
case "
|
|
1661
|
-
case "com.amazonaws.ram#
|
|
1662
|
-
throw await
|
|
2362
|
+
case "IdempotentParameterMismatchException":
|
|
2363
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
2364
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
2365
|
+
case "InvalidClientTokenException":
|
|
2366
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2367
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2368
|
+
case "MalformedArnException":
|
|
2369
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
2370
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
2371
|
+
case "OperationNotPermittedException":
|
|
2372
|
+
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
2373
|
+
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
2374
|
+
case "ResourceShareInvitationAlreadyAcceptedException":
|
|
2375
|
+
case "com.amazonaws.ram#ResourceShareInvitationAlreadyAcceptedException":
|
|
2376
|
+
throw await de_ResourceShareInvitationAlreadyAcceptedExceptionRes(parsedOutput, context);
|
|
2377
|
+
case "ResourceShareInvitationAlreadyRejectedException":
|
|
2378
|
+
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
2379
|
+
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
2380
|
+
case "ResourceShareInvitationArnNotFoundException":
|
|
2381
|
+
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
2382
|
+
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
2383
|
+
case "ResourceShareInvitationExpiredException":
|
|
2384
|
+
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
2385
|
+
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
1663
2386
|
case "ServerInternalException":
|
|
1664
2387
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1665
2388
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
@@ -1675,43 +2398,44 @@ const de_ListResourceTypesCommandError = async (output, context) => {
|
|
|
1675
2398
|
});
|
|
1676
2399
|
}
|
|
1677
2400
|
};
|
|
1678
|
-
const
|
|
2401
|
+
const de_ReplacePermissionAssociationsCommand = async (output, context) => {
|
|
1679
2402
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1680
|
-
return
|
|
2403
|
+
return de_ReplacePermissionAssociationsCommandError(output, context);
|
|
1681
2404
|
}
|
|
1682
2405
|
const contents = (0, smithy_client_1.map)({
|
|
1683
2406
|
$metadata: deserializeMetadata(output),
|
|
1684
2407
|
});
|
|
1685
2408
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1686
2409
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1687
|
-
|
|
2410
|
+
clientToken: smithy_client_1.expectString,
|
|
2411
|
+
replacePermissionAssociationsWork: (_) => de_ReplacePermissionAssociationsWork(_, context),
|
|
1688
2412
|
});
|
|
1689
2413
|
Object.assign(contents, doc);
|
|
1690
2414
|
return contents;
|
|
1691
2415
|
};
|
|
1692
|
-
exports.
|
|
1693
|
-
const
|
|
2416
|
+
exports.de_ReplacePermissionAssociationsCommand = de_ReplacePermissionAssociationsCommand;
|
|
2417
|
+
const de_ReplacePermissionAssociationsCommandError = async (output, context) => {
|
|
1694
2418
|
const parsedOutput = {
|
|
1695
2419
|
...output,
|
|
1696
2420
|
body: await parseErrorBody(output.body, context),
|
|
1697
2421
|
};
|
|
1698
2422
|
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1699
2423
|
switch (errorCode) {
|
|
2424
|
+
case "IdempotentParameterMismatchException":
|
|
2425
|
+
case "com.amazonaws.ram#IdempotentParameterMismatchException":
|
|
2426
|
+
throw await de_IdempotentParameterMismatchExceptionRes(parsedOutput, context);
|
|
2427
|
+
case "InvalidClientTokenException":
|
|
2428
|
+
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
2429
|
+
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
1700
2430
|
case "InvalidParameterException":
|
|
1701
2431
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
1702
2432
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1703
2433
|
case "MalformedArnException":
|
|
1704
2434
|
case "com.amazonaws.ram#MalformedArnException":
|
|
1705
2435
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1706
|
-
case "MissingRequiredParameterException":
|
|
1707
|
-
case "com.amazonaws.ram#MissingRequiredParameterException":
|
|
1708
|
-
throw await de_MissingRequiredParameterExceptionRes(parsedOutput, context);
|
|
1709
2436
|
case "OperationNotPermittedException":
|
|
1710
2437
|
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1711
2438
|
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1712
|
-
case "ResourceShareLimitExceededException":
|
|
1713
|
-
case "com.amazonaws.ram#ResourceShareLimitExceededException":
|
|
1714
|
-
throw await de_ResourceShareLimitExceededExceptionRes(parsedOutput, context);
|
|
1715
2439
|
case "ServerInternalException":
|
|
1716
2440
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1717
2441
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
@@ -1730,9 +2454,9 @@ const de_PromoteResourceShareCreatedFromPolicyCommandError = async (output, cont
|
|
|
1730
2454
|
});
|
|
1731
2455
|
}
|
|
1732
2456
|
};
|
|
1733
|
-
const
|
|
2457
|
+
const de_SetDefaultPermissionVersionCommand = async (output, context) => {
|
|
1734
2458
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1735
|
-
return
|
|
2459
|
+
return de_SetDefaultPermissionVersionCommandError(output, context);
|
|
1736
2460
|
}
|
|
1737
2461
|
const contents = (0, smithy_client_1.map)({
|
|
1738
2462
|
$metadata: deserializeMetadata(output),
|
|
@@ -1740,13 +2464,13 @@ const de_RejectResourceShareInvitationCommand = async (output, context) => {
|
|
|
1740
2464
|
const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
|
|
1741
2465
|
const doc = (0, smithy_client_1.take)(data, {
|
|
1742
2466
|
clientToken: smithy_client_1.expectString,
|
|
1743
|
-
|
|
2467
|
+
returnValue: smithy_client_1.expectBoolean,
|
|
1744
2468
|
});
|
|
1745
2469
|
Object.assign(contents, doc);
|
|
1746
2470
|
return contents;
|
|
1747
2471
|
};
|
|
1748
|
-
exports.
|
|
1749
|
-
const
|
|
2472
|
+
exports.de_SetDefaultPermissionVersionCommand = de_SetDefaultPermissionVersionCommand;
|
|
2473
|
+
const de_SetDefaultPermissionVersionCommandError = async (output, context) => {
|
|
1750
2474
|
const parsedOutput = {
|
|
1751
2475
|
...output,
|
|
1752
2476
|
body: await parseErrorBody(output.body, context),
|
|
@@ -1759,30 +2483,21 @@ const de_RejectResourceShareInvitationCommandError = async (output, context) =>
|
|
|
1759
2483
|
case "InvalidClientTokenException":
|
|
1760
2484
|
case "com.amazonaws.ram#InvalidClientTokenException":
|
|
1761
2485
|
throw await de_InvalidClientTokenExceptionRes(parsedOutput, context);
|
|
2486
|
+
case "InvalidParameterException":
|
|
2487
|
+
case "com.amazonaws.ram#InvalidParameterException":
|
|
2488
|
+
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
1762
2489
|
case "MalformedArnException":
|
|
1763
2490
|
case "com.amazonaws.ram#MalformedArnException":
|
|
1764
2491
|
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1765
|
-
case "OperationNotPermittedException":
|
|
1766
|
-
case "com.amazonaws.ram#OperationNotPermittedException":
|
|
1767
|
-
throw await de_OperationNotPermittedExceptionRes(parsedOutput, context);
|
|
1768
|
-
case "ResourceShareInvitationAlreadyAcceptedException":
|
|
1769
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyAcceptedException":
|
|
1770
|
-
throw await de_ResourceShareInvitationAlreadyAcceptedExceptionRes(parsedOutput, context);
|
|
1771
|
-
case "ResourceShareInvitationAlreadyRejectedException":
|
|
1772
|
-
case "com.amazonaws.ram#ResourceShareInvitationAlreadyRejectedException":
|
|
1773
|
-
throw await de_ResourceShareInvitationAlreadyRejectedExceptionRes(parsedOutput, context);
|
|
1774
|
-
case "ResourceShareInvitationArnNotFoundException":
|
|
1775
|
-
case "com.amazonaws.ram#ResourceShareInvitationArnNotFoundException":
|
|
1776
|
-
throw await de_ResourceShareInvitationArnNotFoundExceptionRes(parsedOutput, context);
|
|
1777
|
-
case "ResourceShareInvitationExpiredException":
|
|
1778
|
-
case "com.amazonaws.ram#ResourceShareInvitationExpiredException":
|
|
1779
|
-
throw await de_ResourceShareInvitationExpiredExceptionRes(parsedOutput, context);
|
|
1780
2492
|
case "ServerInternalException":
|
|
1781
2493
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1782
2494
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1783
2495
|
case "ServiceUnavailableException":
|
|
1784
2496
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1785
2497
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2498
|
+
case "UnknownResourceException":
|
|
2499
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
2500
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1786
2501
|
default:
|
|
1787
2502
|
const parsedBody = parsedOutput.body;
|
|
1788
2503
|
return throwDefaultError({
|
|
@@ -1864,12 +2579,18 @@ const de_UntagResourceCommandError = async (output, context) => {
|
|
|
1864
2579
|
case "InvalidParameterException":
|
|
1865
2580
|
case "com.amazonaws.ram#InvalidParameterException":
|
|
1866
2581
|
throw await de_InvalidParameterExceptionRes(parsedOutput, context);
|
|
2582
|
+
case "MalformedArnException":
|
|
2583
|
+
case "com.amazonaws.ram#MalformedArnException":
|
|
2584
|
+
throw await de_MalformedArnExceptionRes(parsedOutput, context);
|
|
1867
2585
|
case "ServerInternalException":
|
|
1868
2586
|
case "com.amazonaws.ram#ServerInternalException":
|
|
1869
2587
|
throw await de_ServerInternalExceptionRes(parsedOutput, context);
|
|
1870
2588
|
case "ServiceUnavailableException":
|
|
1871
2589
|
case "com.amazonaws.ram#ServiceUnavailableException":
|
|
1872
2590
|
throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
|
|
2591
|
+
case "UnknownResourceException":
|
|
2592
|
+
case "com.amazonaws.ram#UnknownResourceException":
|
|
2593
|
+
throw await de_UnknownResourceExceptionRes(parsedOutput, context);
|
|
1873
2594
|
default:
|
|
1874
2595
|
const parsedBody = parsedOutput.body;
|
|
1875
2596
|
return throwDefaultError({
|
|
@@ -2004,6 +2725,19 @@ const de_InvalidParameterExceptionRes = async (parsedOutput, context) => {
|
|
|
2004
2725
|
});
|
|
2005
2726
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2006
2727
|
};
|
|
2728
|
+
const de_InvalidPolicyExceptionRes = async (parsedOutput, context) => {
|
|
2729
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2730
|
+
const data = parsedOutput.body;
|
|
2731
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2732
|
+
message: smithy_client_1.expectString,
|
|
2733
|
+
});
|
|
2734
|
+
Object.assign(contents, doc);
|
|
2735
|
+
const exception = new models_0_1.InvalidPolicyException({
|
|
2736
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2737
|
+
...contents,
|
|
2738
|
+
});
|
|
2739
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2740
|
+
};
|
|
2007
2741
|
const de_InvalidResourceTypeExceptionRes = async (parsedOutput, context) => {
|
|
2008
2742
|
const contents = (0, smithy_client_1.map)({});
|
|
2009
2743
|
const data = parsedOutput.body;
|
|
@@ -2043,6 +2777,19 @@ const de_MalformedArnExceptionRes = async (parsedOutput, context) => {
|
|
|
2043
2777
|
});
|
|
2044
2778
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2045
2779
|
};
|
|
2780
|
+
const de_MalformedPolicyTemplateExceptionRes = async (parsedOutput, context) => {
|
|
2781
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2782
|
+
const data = parsedOutput.body;
|
|
2783
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2784
|
+
message: smithy_client_1.expectString,
|
|
2785
|
+
});
|
|
2786
|
+
Object.assign(contents, doc);
|
|
2787
|
+
const exception = new models_0_1.MalformedPolicyTemplateException({
|
|
2788
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2789
|
+
...contents,
|
|
2790
|
+
});
|
|
2791
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2792
|
+
};
|
|
2046
2793
|
const de_MissingRequiredParameterExceptionRes = async (parsedOutput, context) => {
|
|
2047
2794
|
const contents = (0, smithy_client_1.map)({});
|
|
2048
2795
|
const data = parsedOutput.body;
|
|
@@ -2069,6 +2816,45 @@ const de_OperationNotPermittedExceptionRes = async (parsedOutput, context) => {
|
|
|
2069
2816
|
});
|
|
2070
2817
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2071
2818
|
};
|
|
2819
|
+
const de_PermissionAlreadyExistsExceptionRes = async (parsedOutput, context) => {
|
|
2820
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2821
|
+
const data = parsedOutput.body;
|
|
2822
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2823
|
+
message: smithy_client_1.expectString,
|
|
2824
|
+
});
|
|
2825
|
+
Object.assign(contents, doc);
|
|
2826
|
+
const exception = new models_0_1.PermissionAlreadyExistsException({
|
|
2827
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2828
|
+
...contents,
|
|
2829
|
+
});
|
|
2830
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2831
|
+
};
|
|
2832
|
+
const de_PermissionLimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
2833
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2834
|
+
const data = parsedOutput.body;
|
|
2835
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2836
|
+
message: smithy_client_1.expectString,
|
|
2837
|
+
});
|
|
2838
|
+
Object.assign(contents, doc);
|
|
2839
|
+
const exception = new models_0_1.PermissionLimitExceededException({
|
|
2840
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2841
|
+
...contents,
|
|
2842
|
+
});
|
|
2843
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2844
|
+
};
|
|
2845
|
+
const de_PermissionVersionsLimitExceededExceptionRes = async (parsedOutput, context) => {
|
|
2846
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2847
|
+
const data = parsedOutput.body;
|
|
2848
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2849
|
+
message: smithy_client_1.expectString,
|
|
2850
|
+
});
|
|
2851
|
+
Object.assign(contents, doc);
|
|
2852
|
+
const exception = new models_0_1.PermissionVersionsLimitExceededException({
|
|
2853
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2854
|
+
...contents,
|
|
2855
|
+
});
|
|
2856
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2857
|
+
};
|
|
2072
2858
|
const de_ResourceArnNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
2073
2859
|
const contents = (0, smithy_client_1.map)({});
|
|
2074
2860
|
const data = parsedOutput.body;
|
|
@@ -2225,6 +3011,39 @@ const de_UnknownResourceExceptionRes = async (parsedOutput, context) => {
|
|
|
2225
3011
|
});
|
|
2226
3012
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2227
3013
|
};
|
|
3014
|
+
const de_UnmatchedPolicyPermissionExceptionRes = async (parsedOutput, context) => {
|
|
3015
|
+
const contents = (0, smithy_client_1.map)({});
|
|
3016
|
+
const data = parsedOutput.body;
|
|
3017
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
3018
|
+
message: smithy_client_1.expectString,
|
|
3019
|
+
});
|
|
3020
|
+
Object.assign(contents, doc);
|
|
3021
|
+
const exception = new models_0_1.UnmatchedPolicyPermissionException({
|
|
3022
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
3023
|
+
...contents,
|
|
3024
|
+
});
|
|
3025
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
3026
|
+
};
|
|
3027
|
+
const de_AssociatedPermission = (output, context) => {
|
|
3028
|
+
return (0, smithy_client_1.take)(output, {
|
|
3029
|
+
arn: smithy_client_1.expectString,
|
|
3030
|
+
defaultVersion: smithy_client_1.expectBoolean,
|
|
3031
|
+
featureSet: smithy_client_1.expectString,
|
|
3032
|
+
lastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
3033
|
+
permissionVersion: smithy_client_1.expectString,
|
|
3034
|
+
resourceShareArn: smithy_client_1.expectString,
|
|
3035
|
+
resourceType: smithy_client_1.expectString,
|
|
3036
|
+
status: smithy_client_1.expectString,
|
|
3037
|
+
});
|
|
3038
|
+
};
|
|
3039
|
+
const de_AssociatedPermissionList = (output, context) => {
|
|
3040
|
+
const retVal = (output || [])
|
|
3041
|
+
.filter((e) => e != null)
|
|
3042
|
+
.map((entry) => {
|
|
3043
|
+
return de_AssociatedPermission(entry, context);
|
|
3044
|
+
});
|
|
3045
|
+
return retVal;
|
|
3046
|
+
};
|
|
2228
3047
|
const de_Principal = (output, context) => {
|
|
2229
3048
|
return (0, smithy_client_1.take)(output, {
|
|
2230
3049
|
creationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
@@ -2242,6 +3061,27 @@ const de_PrincipalList = (output, context) => {
|
|
|
2242
3061
|
});
|
|
2243
3062
|
return retVal;
|
|
2244
3063
|
};
|
|
3064
|
+
const de_ReplacePermissionAssociationsWork = (output, context) => {
|
|
3065
|
+
return (0, smithy_client_1.take)(output, {
|
|
3066
|
+
creationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
3067
|
+
fromPermissionArn: smithy_client_1.expectString,
|
|
3068
|
+
fromPermissionVersion: smithy_client_1.expectString,
|
|
3069
|
+
id: smithy_client_1.expectString,
|
|
3070
|
+
lastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
3071
|
+
status: smithy_client_1.expectString,
|
|
3072
|
+
statusMessage: smithy_client_1.expectString,
|
|
3073
|
+
toPermissionArn: smithy_client_1.expectString,
|
|
3074
|
+
toPermissionVersion: smithy_client_1.expectString,
|
|
3075
|
+
});
|
|
3076
|
+
};
|
|
3077
|
+
const de_ReplacePermissionAssociationsWorkList = (output, context) => {
|
|
3078
|
+
const retVal = (output || [])
|
|
3079
|
+
.filter((e) => e != null)
|
|
3080
|
+
.map((entry) => {
|
|
3081
|
+
return de_ReplacePermissionAssociationsWork(entry, context);
|
|
3082
|
+
});
|
|
3083
|
+
return retVal;
|
|
3084
|
+
};
|
|
2245
3085
|
const de_Resource = (output, context) => {
|
|
2246
3086
|
return (0, smithy_client_1.take)(output, {
|
|
2247
3087
|
arn: smithy_client_1.expectString,
|
|
@@ -2332,11 +3172,15 @@ const de_ResourceSharePermissionDetail = (output, context) => {
|
|
|
2332
3172
|
arn: smithy_client_1.expectString,
|
|
2333
3173
|
creationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
2334
3174
|
defaultVersion: smithy_client_1.expectBoolean,
|
|
3175
|
+
featureSet: smithy_client_1.expectString,
|
|
2335
3176
|
isResourceTypeDefault: smithy_client_1.expectBoolean,
|
|
2336
3177
|
lastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
2337
3178
|
name: smithy_client_1.expectString,
|
|
2338
3179
|
permission: smithy_client_1.expectString,
|
|
3180
|
+
permissionType: smithy_client_1.expectString,
|
|
2339
3181
|
resourceType: smithy_client_1.expectString,
|
|
3182
|
+
status: smithy_client_1.expectString,
|
|
3183
|
+
tags: smithy_client_1._json,
|
|
2340
3184
|
version: smithy_client_1.expectString,
|
|
2341
3185
|
});
|
|
2342
3186
|
};
|
|
@@ -2353,11 +3197,14 @@ const de_ResourceSharePermissionSummary = (output, context) => {
|
|
|
2353
3197
|
arn: smithy_client_1.expectString,
|
|
2354
3198
|
creationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
2355
3199
|
defaultVersion: smithy_client_1.expectBoolean,
|
|
3200
|
+
featureSet: smithy_client_1.expectString,
|
|
2356
3201
|
isResourceTypeDefault: smithy_client_1.expectBoolean,
|
|
2357
3202
|
lastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
2358
3203
|
name: smithy_client_1.expectString,
|
|
3204
|
+
permissionType: smithy_client_1.expectString,
|
|
2359
3205
|
resourceType: smithy_client_1.expectString,
|
|
2360
3206
|
status: smithy_client_1.expectString,
|
|
3207
|
+
tags: smithy_client_1._json,
|
|
2361
3208
|
version: smithy_client_1.expectString,
|
|
2362
3209
|
});
|
|
2363
3210
|
};
|