@aws-sdk/client-workspaces 3.490.0 → 3.495.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.
Files changed (92) hide show
  1. package/dist-cjs/WorkSpaces.js +1 -157
  2. package/dist-cjs/WorkSpacesClient.js +1 -43
  3. package/dist-cjs/commands/AssociateConnectionAliasCommand.js +1 -28
  4. package/dist-cjs/commands/AssociateIpGroupsCommand.js +1 -28
  5. package/dist-cjs/commands/AssociateWorkspaceApplicationCommand.js +1 -28
  6. package/dist-cjs/commands/AuthorizeIpRulesCommand.js +1 -28
  7. package/dist-cjs/commands/CopyWorkspaceImageCommand.js +1 -28
  8. package/dist-cjs/commands/CreateConnectClientAddInCommand.js +1 -28
  9. package/dist-cjs/commands/CreateConnectionAliasCommand.js +1 -28
  10. package/dist-cjs/commands/CreateIpGroupCommand.js +1 -28
  11. package/dist-cjs/commands/CreateStandbyWorkspacesCommand.js +1 -28
  12. package/dist-cjs/commands/CreateTagsCommand.js +1 -28
  13. package/dist-cjs/commands/CreateUpdatedWorkspaceImageCommand.js +1 -28
  14. package/dist-cjs/commands/CreateWorkspaceBundleCommand.js +1 -28
  15. package/dist-cjs/commands/CreateWorkspaceImageCommand.js +1 -28
  16. package/dist-cjs/commands/CreateWorkspacesCommand.js +1 -28
  17. package/dist-cjs/commands/DeleteClientBrandingCommand.js +1 -28
  18. package/dist-cjs/commands/DeleteConnectClientAddInCommand.js +1 -28
  19. package/dist-cjs/commands/DeleteConnectionAliasCommand.js +1 -28
  20. package/dist-cjs/commands/DeleteIpGroupCommand.js +1 -28
  21. package/dist-cjs/commands/DeleteTagsCommand.js +1 -28
  22. package/dist-cjs/commands/DeleteWorkspaceBundleCommand.js +1 -28
  23. package/dist-cjs/commands/DeleteWorkspaceImageCommand.js +1 -28
  24. package/dist-cjs/commands/DeployWorkspaceApplicationsCommand.js +1 -28
  25. package/dist-cjs/commands/DeregisterWorkspaceDirectoryCommand.js +1 -28
  26. package/dist-cjs/commands/DescribeAccountCommand.js +1 -28
  27. package/dist-cjs/commands/DescribeAccountModificationsCommand.js +1 -28
  28. package/dist-cjs/commands/DescribeApplicationAssociationsCommand.js +1 -28
  29. package/dist-cjs/commands/DescribeApplicationsCommand.js +1 -28
  30. package/dist-cjs/commands/DescribeBundleAssociationsCommand.js +1 -28
  31. package/dist-cjs/commands/DescribeClientBrandingCommand.js +1 -28
  32. package/dist-cjs/commands/DescribeClientPropertiesCommand.js +1 -28
  33. package/dist-cjs/commands/DescribeConnectClientAddInsCommand.js +1 -28
  34. package/dist-cjs/commands/DescribeConnectionAliasPermissionsCommand.js +1 -28
  35. package/dist-cjs/commands/DescribeConnectionAliasesCommand.js +1 -28
  36. package/dist-cjs/commands/DescribeImageAssociationsCommand.js +1 -28
  37. package/dist-cjs/commands/DescribeIpGroupsCommand.js +1 -28
  38. package/dist-cjs/commands/DescribeTagsCommand.js +1 -28
  39. package/dist-cjs/commands/DescribeWorkspaceAssociationsCommand.js +1 -28
  40. package/dist-cjs/commands/DescribeWorkspaceBundlesCommand.js +1 -28
  41. package/dist-cjs/commands/DescribeWorkspaceDirectoriesCommand.js +1 -28
  42. package/dist-cjs/commands/DescribeWorkspaceImagePermissionsCommand.js +1 -28
  43. package/dist-cjs/commands/DescribeWorkspaceImagesCommand.js +1 -28
  44. package/dist-cjs/commands/DescribeWorkspaceSnapshotsCommand.js +1 -28
  45. package/dist-cjs/commands/DescribeWorkspacesCommand.js +1 -28
  46. package/dist-cjs/commands/DescribeWorkspacesConnectionStatusCommand.js +1 -28
  47. package/dist-cjs/commands/DisassociateConnectionAliasCommand.js +1 -28
  48. package/dist-cjs/commands/DisassociateIpGroupsCommand.js +1 -28
  49. package/dist-cjs/commands/DisassociateWorkspaceApplicationCommand.js +1 -28
  50. package/dist-cjs/commands/ImportClientBrandingCommand.js +1 -28
  51. package/dist-cjs/commands/ImportWorkspaceImageCommand.js +1 -28
  52. package/dist-cjs/commands/ListAvailableManagementCidrRangesCommand.js +1 -28
  53. package/dist-cjs/commands/MigrateWorkspaceCommand.js +1 -28
  54. package/dist-cjs/commands/ModifyAccountCommand.js +1 -28
  55. package/dist-cjs/commands/ModifyCertificateBasedAuthPropertiesCommand.js +1 -28
  56. package/dist-cjs/commands/ModifyClientPropertiesCommand.js +1 -28
  57. package/dist-cjs/commands/ModifySamlPropertiesCommand.js +1 -28
  58. package/dist-cjs/commands/ModifySelfservicePermissionsCommand.js +1 -28
  59. package/dist-cjs/commands/ModifyWorkspaceAccessPropertiesCommand.js +1 -28
  60. package/dist-cjs/commands/ModifyWorkspaceCreationPropertiesCommand.js +1 -28
  61. package/dist-cjs/commands/ModifyWorkspacePropertiesCommand.js +1 -28
  62. package/dist-cjs/commands/ModifyWorkspaceStateCommand.js +1 -28
  63. package/dist-cjs/commands/RebootWorkspacesCommand.js +1 -28
  64. package/dist-cjs/commands/RebuildWorkspacesCommand.js +1 -28
  65. package/dist-cjs/commands/RegisterWorkspaceDirectoryCommand.js +1 -28
  66. package/dist-cjs/commands/RestoreWorkspaceCommand.js +1 -28
  67. package/dist-cjs/commands/RevokeIpRulesCommand.js +1 -28
  68. package/dist-cjs/commands/StartWorkspacesCommand.js +1 -28
  69. package/dist-cjs/commands/StopWorkspacesCommand.js +1 -28
  70. package/dist-cjs/commands/TerminateWorkspacesCommand.js +1 -28
  71. package/dist-cjs/commands/UpdateConnectClientAddInCommand.js +1 -28
  72. package/dist-cjs/commands/UpdateConnectionAliasPermissionCommand.js +1 -28
  73. package/dist-cjs/commands/UpdateRulesOfIpGroupCommand.js +1 -28
  74. package/dist-cjs/commands/UpdateWorkspaceBundleCommand.js +1 -28
  75. package/dist-cjs/commands/UpdateWorkspaceImagePermissionCommand.js +1 -28
  76. package/dist-cjs/commands/index.js +1 -76
  77. package/dist-cjs/endpoint/EndpointParameters.js +1 -18
  78. package/dist-cjs/extensionConfiguration.js +1 -2
  79. package/dist-cjs/index.js +6350 -11
  80. package/dist-cjs/models/WorkSpacesServiceException.js +1 -12
  81. package/dist-cjs/models/index.js +1 -4
  82. package/dist-cjs/models/models_0.js +1 -518
  83. package/dist-cjs/pagination/DescribeApplicationAssociationsPaginator.js +1 -7
  84. package/dist-cjs/pagination/DescribeApplicationsPaginator.js +1 -7
  85. package/dist-cjs/pagination/DescribeWorkspaceBundlesPaginator.js +1 -7
  86. package/dist-cjs/pagination/DescribeWorkspaceDirectoriesPaginator.js +1 -7
  87. package/dist-cjs/pagination/DescribeWorkspacesPaginator.js +1 -7
  88. package/dist-cjs/pagination/Interfaces.js +1 -2
  89. package/dist-cjs/pagination/index.js +1 -9
  90. package/dist-cjs/protocols/Aws_json1_1.js +1 -4164
  91. package/dist-cjs/runtimeExtensions.js +1 -22
  92. package/package.json +40 -40
@@ -1,4164 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.se_ListAvailableManagementCidrRangesCommand = exports.se_ImportWorkspaceImageCommand = exports.se_ImportClientBrandingCommand = exports.se_DisassociateWorkspaceApplicationCommand = exports.se_DisassociateIpGroupsCommand = exports.se_DisassociateConnectionAliasCommand = exports.se_DescribeWorkspaceSnapshotsCommand = exports.se_DescribeWorkspacesConnectionStatusCommand = exports.se_DescribeWorkspacesCommand = exports.se_DescribeWorkspaceImagesCommand = exports.se_DescribeWorkspaceImagePermissionsCommand = exports.se_DescribeWorkspaceDirectoriesCommand = exports.se_DescribeWorkspaceBundlesCommand = exports.se_DescribeWorkspaceAssociationsCommand = exports.se_DescribeTagsCommand = exports.se_DescribeIpGroupsCommand = exports.se_DescribeImageAssociationsCommand = exports.se_DescribeConnectionAliasPermissionsCommand = exports.se_DescribeConnectionAliasesCommand = exports.se_DescribeConnectClientAddInsCommand = exports.se_DescribeClientPropertiesCommand = exports.se_DescribeClientBrandingCommand = exports.se_DescribeBundleAssociationsCommand = exports.se_DescribeApplicationsCommand = exports.se_DescribeApplicationAssociationsCommand = exports.se_DescribeAccountModificationsCommand = exports.se_DescribeAccountCommand = exports.se_DeregisterWorkspaceDirectoryCommand = exports.se_DeployWorkspaceApplicationsCommand = exports.se_DeleteWorkspaceImageCommand = exports.se_DeleteWorkspaceBundleCommand = exports.se_DeleteTagsCommand = exports.se_DeleteIpGroupCommand = exports.se_DeleteConnectionAliasCommand = exports.se_DeleteConnectClientAddInCommand = exports.se_DeleteClientBrandingCommand = exports.se_CreateWorkspacesCommand = exports.se_CreateWorkspaceImageCommand = exports.se_CreateWorkspaceBundleCommand = exports.se_CreateUpdatedWorkspaceImageCommand = exports.se_CreateTagsCommand = exports.se_CreateStandbyWorkspacesCommand = exports.se_CreateIpGroupCommand = exports.se_CreateConnectionAliasCommand = exports.se_CreateConnectClientAddInCommand = exports.se_CopyWorkspaceImageCommand = exports.se_AuthorizeIpRulesCommand = exports.se_AssociateWorkspaceApplicationCommand = exports.se_AssociateIpGroupsCommand = exports.se_AssociateConnectionAliasCommand = void 0;
4
- exports.de_DescribeApplicationsCommand = exports.de_DescribeApplicationAssociationsCommand = exports.de_DescribeAccountModificationsCommand = exports.de_DescribeAccountCommand = exports.de_DeregisterWorkspaceDirectoryCommand = exports.de_DeployWorkspaceApplicationsCommand = exports.de_DeleteWorkspaceImageCommand = exports.de_DeleteWorkspaceBundleCommand = exports.de_DeleteTagsCommand = exports.de_DeleteIpGroupCommand = exports.de_DeleteConnectionAliasCommand = exports.de_DeleteConnectClientAddInCommand = exports.de_DeleteClientBrandingCommand = exports.de_CreateWorkspacesCommand = exports.de_CreateWorkspaceImageCommand = exports.de_CreateWorkspaceBundleCommand = exports.de_CreateUpdatedWorkspaceImageCommand = exports.de_CreateTagsCommand = exports.de_CreateStandbyWorkspacesCommand = exports.de_CreateIpGroupCommand = exports.de_CreateConnectionAliasCommand = exports.de_CreateConnectClientAddInCommand = exports.de_CopyWorkspaceImageCommand = exports.de_AuthorizeIpRulesCommand = exports.de_AssociateWorkspaceApplicationCommand = exports.de_AssociateIpGroupsCommand = exports.de_AssociateConnectionAliasCommand = exports.se_UpdateWorkspaceImagePermissionCommand = exports.se_UpdateWorkspaceBundleCommand = exports.se_UpdateRulesOfIpGroupCommand = exports.se_UpdateConnectionAliasPermissionCommand = exports.se_UpdateConnectClientAddInCommand = exports.se_TerminateWorkspacesCommand = exports.se_StopWorkspacesCommand = exports.se_StartWorkspacesCommand = exports.se_RevokeIpRulesCommand = exports.se_RestoreWorkspaceCommand = exports.se_RegisterWorkspaceDirectoryCommand = exports.se_RebuildWorkspacesCommand = exports.se_RebootWorkspacesCommand = exports.se_ModifyWorkspaceStateCommand = exports.se_ModifyWorkspacePropertiesCommand = exports.se_ModifyWorkspaceCreationPropertiesCommand = exports.se_ModifyWorkspaceAccessPropertiesCommand = exports.se_ModifySelfservicePermissionsCommand = exports.se_ModifySamlPropertiesCommand = exports.se_ModifyClientPropertiesCommand = exports.se_ModifyCertificateBasedAuthPropertiesCommand = exports.se_ModifyAccountCommand = exports.se_MigrateWorkspaceCommand = void 0;
5
- exports.de_UpdateWorkspaceImagePermissionCommand = exports.de_UpdateWorkspaceBundleCommand = exports.de_UpdateRulesOfIpGroupCommand = exports.de_UpdateConnectionAliasPermissionCommand = exports.de_UpdateConnectClientAddInCommand = exports.de_TerminateWorkspacesCommand = exports.de_StopWorkspacesCommand = exports.de_StartWorkspacesCommand = exports.de_RevokeIpRulesCommand = exports.de_RestoreWorkspaceCommand = exports.de_RegisterWorkspaceDirectoryCommand = exports.de_RebuildWorkspacesCommand = exports.de_RebootWorkspacesCommand = exports.de_ModifyWorkspaceStateCommand = exports.de_ModifyWorkspacePropertiesCommand = exports.de_ModifyWorkspaceCreationPropertiesCommand = exports.de_ModifyWorkspaceAccessPropertiesCommand = exports.de_ModifySelfservicePermissionsCommand = exports.de_ModifySamlPropertiesCommand = exports.de_ModifyClientPropertiesCommand = exports.de_ModifyCertificateBasedAuthPropertiesCommand = exports.de_ModifyAccountCommand = exports.de_MigrateWorkspaceCommand = exports.de_ListAvailableManagementCidrRangesCommand = exports.de_ImportWorkspaceImageCommand = exports.de_ImportClientBrandingCommand = exports.de_DisassociateWorkspaceApplicationCommand = exports.de_DisassociateIpGroupsCommand = exports.de_DisassociateConnectionAliasCommand = exports.de_DescribeWorkspaceSnapshotsCommand = exports.de_DescribeWorkspacesConnectionStatusCommand = exports.de_DescribeWorkspacesCommand = exports.de_DescribeWorkspaceImagesCommand = exports.de_DescribeWorkspaceImagePermissionsCommand = exports.de_DescribeWorkspaceDirectoriesCommand = exports.de_DescribeWorkspaceBundlesCommand = exports.de_DescribeWorkspaceAssociationsCommand = exports.de_DescribeTagsCommand = exports.de_DescribeIpGroupsCommand = exports.de_DescribeImageAssociationsCommand = exports.de_DescribeConnectionAliasPermissionsCommand = exports.de_DescribeConnectionAliasesCommand = exports.de_DescribeConnectClientAddInsCommand = exports.de_DescribeClientPropertiesCommand = exports.de_DescribeClientBrandingCommand = exports.de_DescribeBundleAssociationsCommand = void 0;
6
- const protocol_http_1 = require("@smithy/protocol-http");
7
- const smithy_client_1 = require("@smithy/smithy-client");
8
- const models_0_1 = require("../models/models_0");
9
- const WorkSpacesServiceException_1 = require("../models/WorkSpacesServiceException");
10
- const se_AssociateConnectionAliasCommand = async (input, context) => {
11
- const headers = sharedHeaders("AssociateConnectionAlias");
12
- let body;
13
- body = JSON.stringify((0, smithy_client_1._json)(input));
14
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
15
- };
16
- exports.se_AssociateConnectionAliasCommand = se_AssociateConnectionAliasCommand;
17
- const se_AssociateIpGroupsCommand = async (input, context) => {
18
- const headers = sharedHeaders("AssociateIpGroups");
19
- let body;
20
- body = JSON.stringify((0, smithy_client_1._json)(input));
21
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
22
- };
23
- exports.se_AssociateIpGroupsCommand = se_AssociateIpGroupsCommand;
24
- const se_AssociateWorkspaceApplicationCommand = async (input, context) => {
25
- const headers = sharedHeaders("AssociateWorkspaceApplication");
26
- let body;
27
- body = JSON.stringify((0, smithy_client_1._json)(input));
28
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
29
- };
30
- exports.se_AssociateWorkspaceApplicationCommand = se_AssociateWorkspaceApplicationCommand;
31
- const se_AuthorizeIpRulesCommand = async (input, context) => {
32
- const headers = sharedHeaders("AuthorizeIpRules");
33
- let body;
34
- body = JSON.stringify((0, smithy_client_1._json)(input));
35
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
36
- };
37
- exports.se_AuthorizeIpRulesCommand = se_AuthorizeIpRulesCommand;
38
- const se_CopyWorkspaceImageCommand = async (input, context) => {
39
- const headers = sharedHeaders("CopyWorkspaceImage");
40
- let body;
41
- body = JSON.stringify((0, smithy_client_1._json)(input));
42
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
43
- };
44
- exports.se_CopyWorkspaceImageCommand = se_CopyWorkspaceImageCommand;
45
- const se_CreateConnectClientAddInCommand = async (input, context) => {
46
- const headers = sharedHeaders("CreateConnectClientAddIn");
47
- let body;
48
- body = JSON.stringify((0, smithy_client_1._json)(input));
49
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
50
- };
51
- exports.se_CreateConnectClientAddInCommand = se_CreateConnectClientAddInCommand;
52
- const se_CreateConnectionAliasCommand = async (input, context) => {
53
- const headers = sharedHeaders("CreateConnectionAlias");
54
- let body;
55
- body = JSON.stringify((0, smithy_client_1._json)(input));
56
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
57
- };
58
- exports.se_CreateConnectionAliasCommand = se_CreateConnectionAliasCommand;
59
- const se_CreateIpGroupCommand = async (input, context) => {
60
- const headers = sharedHeaders("CreateIpGroup");
61
- let body;
62
- body = JSON.stringify((0, smithy_client_1._json)(input));
63
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
64
- };
65
- exports.se_CreateIpGroupCommand = se_CreateIpGroupCommand;
66
- const se_CreateStandbyWorkspacesCommand = async (input, context) => {
67
- const headers = sharedHeaders("CreateStandbyWorkspaces");
68
- let body;
69
- body = JSON.stringify((0, smithy_client_1._json)(input));
70
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
71
- };
72
- exports.se_CreateStandbyWorkspacesCommand = se_CreateStandbyWorkspacesCommand;
73
- const se_CreateTagsCommand = async (input, context) => {
74
- const headers = sharedHeaders("CreateTags");
75
- let body;
76
- body = JSON.stringify((0, smithy_client_1._json)(input));
77
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
78
- };
79
- exports.se_CreateTagsCommand = se_CreateTagsCommand;
80
- const se_CreateUpdatedWorkspaceImageCommand = async (input, context) => {
81
- const headers = sharedHeaders("CreateUpdatedWorkspaceImage");
82
- let body;
83
- body = JSON.stringify((0, smithy_client_1._json)(input));
84
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
85
- };
86
- exports.se_CreateUpdatedWorkspaceImageCommand = se_CreateUpdatedWorkspaceImageCommand;
87
- const se_CreateWorkspaceBundleCommand = async (input, context) => {
88
- const headers = sharedHeaders("CreateWorkspaceBundle");
89
- let body;
90
- body = JSON.stringify((0, smithy_client_1._json)(input));
91
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
92
- };
93
- exports.se_CreateWorkspaceBundleCommand = se_CreateWorkspaceBundleCommand;
94
- const se_CreateWorkspaceImageCommand = async (input, context) => {
95
- const headers = sharedHeaders("CreateWorkspaceImage");
96
- let body;
97
- body = JSON.stringify((0, smithy_client_1._json)(input));
98
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
99
- };
100
- exports.se_CreateWorkspaceImageCommand = se_CreateWorkspaceImageCommand;
101
- const se_CreateWorkspacesCommand = async (input, context) => {
102
- const headers = sharedHeaders("CreateWorkspaces");
103
- let body;
104
- body = JSON.stringify((0, smithy_client_1._json)(input));
105
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
106
- };
107
- exports.se_CreateWorkspacesCommand = se_CreateWorkspacesCommand;
108
- const se_DeleteClientBrandingCommand = async (input, context) => {
109
- const headers = sharedHeaders("DeleteClientBranding");
110
- let body;
111
- body = JSON.stringify((0, smithy_client_1._json)(input));
112
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
113
- };
114
- exports.se_DeleteClientBrandingCommand = se_DeleteClientBrandingCommand;
115
- const se_DeleteConnectClientAddInCommand = async (input, context) => {
116
- const headers = sharedHeaders("DeleteConnectClientAddIn");
117
- let body;
118
- body = JSON.stringify((0, smithy_client_1._json)(input));
119
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
120
- };
121
- exports.se_DeleteConnectClientAddInCommand = se_DeleteConnectClientAddInCommand;
122
- const se_DeleteConnectionAliasCommand = async (input, context) => {
123
- const headers = sharedHeaders("DeleteConnectionAlias");
124
- let body;
125
- body = JSON.stringify((0, smithy_client_1._json)(input));
126
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
127
- };
128
- exports.se_DeleteConnectionAliasCommand = se_DeleteConnectionAliasCommand;
129
- const se_DeleteIpGroupCommand = async (input, context) => {
130
- const headers = sharedHeaders("DeleteIpGroup");
131
- let body;
132
- body = JSON.stringify((0, smithy_client_1._json)(input));
133
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
134
- };
135
- exports.se_DeleteIpGroupCommand = se_DeleteIpGroupCommand;
136
- const se_DeleteTagsCommand = async (input, context) => {
137
- const headers = sharedHeaders("DeleteTags");
138
- let body;
139
- body = JSON.stringify((0, smithy_client_1._json)(input));
140
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
141
- };
142
- exports.se_DeleteTagsCommand = se_DeleteTagsCommand;
143
- const se_DeleteWorkspaceBundleCommand = async (input, context) => {
144
- const headers = sharedHeaders("DeleteWorkspaceBundle");
145
- let body;
146
- body = JSON.stringify((0, smithy_client_1._json)(input));
147
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
148
- };
149
- exports.se_DeleteWorkspaceBundleCommand = se_DeleteWorkspaceBundleCommand;
150
- const se_DeleteWorkspaceImageCommand = async (input, context) => {
151
- const headers = sharedHeaders("DeleteWorkspaceImage");
152
- let body;
153
- body = JSON.stringify((0, smithy_client_1._json)(input));
154
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
155
- };
156
- exports.se_DeleteWorkspaceImageCommand = se_DeleteWorkspaceImageCommand;
157
- const se_DeployWorkspaceApplicationsCommand = async (input, context) => {
158
- const headers = sharedHeaders("DeployWorkspaceApplications");
159
- let body;
160
- body = JSON.stringify((0, smithy_client_1._json)(input));
161
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
162
- };
163
- exports.se_DeployWorkspaceApplicationsCommand = se_DeployWorkspaceApplicationsCommand;
164
- const se_DeregisterWorkspaceDirectoryCommand = async (input, context) => {
165
- const headers = sharedHeaders("DeregisterWorkspaceDirectory");
166
- let body;
167
- body = JSON.stringify((0, smithy_client_1._json)(input));
168
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
169
- };
170
- exports.se_DeregisterWorkspaceDirectoryCommand = se_DeregisterWorkspaceDirectoryCommand;
171
- const se_DescribeAccountCommand = async (input, context) => {
172
- const headers = sharedHeaders("DescribeAccount");
173
- let body;
174
- body = JSON.stringify((0, smithy_client_1._json)(input));
175
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
176
- };
177
- exports.se_DescribeAccountCommand = se_DescribeAccountCommand;
178
- const se_DescribeAccountModificationsCommand = async (input, context) => {
179
- const headers = sharedHeaders("DescribeAccountModifications");
180
- let body;
181
- body = JSON.stringify((0, smithy_client_1._json)(input));
182
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
183
- };
184
- exports.se_DescribeAccountModificationsCommand = se_DescribeAccountModificationsCommand;
185
- const se_DescribeApplicationAssociationsCommand = async (input, context) => {
186
- const headers = sharedHeaders("DescribeApplicationAssociations");
187
- let body;
188
- body = JSON.stringify((0, smithy_client_1._json)(input));
189
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
190
- };
191
- exports.se_DescribeApplicationAssociationsCommand = se_DescribeApplicationAssociationsCommand;
192
- const se_DescribeApplicationsCommand = async (input, context) => {
193
- const headers = sharedHeaders("DescribeApplications");
194
- let body;
195
- body = JSON.stringify((0, smithy_client_1._json)(input));
196
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
197
- };
198
- exports.se_DescribeApplicationsCommand = se_DescribeApplicationsCommand;
199
- const se_DescribeBundleAssociationsCommand = async (input, context) => {
200
- const headers = sharedHeaders("DescribeBundleAssociations");
201
- let body;
202
- body = JSON.stringify((0, smithy_client_1._json)(input));
203
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
204
- };
205
- exports.se_DescribeBundleAssociationsCommand = se_DescribeBundleAssociationsCommand;
206
- const se_DescribeClientBrandingCommand = async (input, context) => {
207
- const headers = sharedHeaders("DescribeClientBranding");
208
- let body;
209
- body = JSON.stringify((0, smithy_client_1._json)(input));
210
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
211
- };
212
- exports.se_DescribeClientBrandingCommand = se_DescribeClientBrandingCommand;
213
- const se_DescribeClientPropertiesCommand = async (input, context) => {
214
- const headers = sharedHeaders("DescribeClientProperties");
215
- let body;
216
- body = JSON.stringify((0, smithy_client_1._json)(input));
217
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
218
- };
219
- exports.se_DescribeClientPropertiesCommand = se_DescribeClientPropertiesCommand;
220
- const se_DescribeConnectClientAddInsCommand = async (input, context) => {
221
- const headers = sharedHeaders("DescribeConnectClientAddIns");
222
- let body;
223
- body = JSON.stringify((0, smithy_client_1._json)(input));
224
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
225
- };
226
- exports.se_DescribeConnectClientAddInsCommand = se_DescribeConnectClientAddInsCommand;
227
- const se_DescribeConnectionAliasesCommand = async (input, context) => {
228
- const headers = sharedHeaders("DescribeConnectionAliases");
229
- let body;
230
- body = JSON.stringify((0, smithy_client_1._json)(input));
231
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
232
- };
233
- exports.se_DescribeConnectionAliasesCommand = se_DescribeConnectionAliasesCommand;
234
- const se_DescribeConnectionAliasPermissionsCommand = async (input, context) => {
235
- const headers = sharedHeaders("DescribeConnectionAliasPermissions");
236
- let body;
237
- body = JSON.stringify((0, smithy_client_1._json)(input));
238
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
239
- };
240
- exports.se_DescribeConnectionAliasPermissionsCommand = se_DescribeConnectionAliasPermissionsCommand;
241
- const se_DescribeImageAssociationsCommand = async (input, context) => {
242
- const headers = sharedHeaders("DescribeImageAssociations");
243
- let body;
244
- body = JSON.stringify((0, smithy_client_1._json)(input));
245
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
246
- };
247
- exports.se_DescribeImageAssociationsCommand = se_DescribeImageAssociationsCommand;
248
- const se_DescribeIpGroupsCommand = async (input, context) => {
249
- const headers = sharedHeaders("DescribeIpGroups");
250
- let body;
251
- body = JSON.stringify((0, smithy_client_1._json)(input));
252
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
253
- };
254
- exports.se_DescribeIpGroupsCommand = se_DescribeIpGroupsCommand;
255
- const se_DescribeTagsCommand = async (input, context) => {
256
- const headers = sharedHeaders("DescribeTags");
257
- let body;
258
- body = JSON.stringify((0, smithy_client_1._json)(input));
259
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
260
- };
261
- exports.se_DescribeTagsCommand = se_DescribeTagsCommand;
262
- const se_DescribeWorkspaceAssociationsCommand = async (input, context) => {
263
- const headers = sharedHeaders("DescribeWorkspaceAssociations");
264
- let body;
265
- body = JSON.stringify((0, smithy_client_1._json)(input));
266
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
267
- };
268
- exports.se_DescribeWorkspaceAssociationsCommand = se_DescribeWorkspaceAssociationsCommand;
269
- const se_DescribeWorkspaceBundlesCommand = async (input, context) => {
270
- const headers = sharedHeaders("DescribeWorkspaceBundles");
271
- let body;
272
- body = JSON.stringify((0, smithy_client_1._json)(input));
273
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
274
- };
275
- exports.se_DescribeWorkspaceBundlesCommand = se_DescribeWorkspaceBundlesCommand;
276
- const se_DescribeWorkspaceDirectoriesCommand = async (input, context) => {
277
- const headers = sharedHeaders("DescribeWorkspaceDirectories");
278
- let body;
279
- body = JSON.stringify((0, smithy_client_1._json)(input));
280
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
281
- };
282
- exports.se_DescribeWorkspaceDirectoriesCommand = se_DescribeWorkspaceDirectoriesCommand;
283
- const se_DescribeWorkspaceImagePermissionsCommand = async (input, context) => {
284
- const headers = sharedHeaders("DescribeWorkspaceImagePermissions");
285
- let body;
286
- body = JSON.stringify((0, smithy_client_1._json)(input));
287
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
288
- };
289
- exports.se_DescribeWorkspaceImagePermissionsCommand = se_DescribeWorkspaceImagePermissionsCommand;
290
- const se_DescribeWorkspaceImagesCommand = async (input, context) => {
291
- const headers = sharedHeaders("DescribeWorkspaceImages");
292
- let body;
293
- body = JSON.stringify((0, smithy_client_1._json)(input));
294
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
295
- };
296
- exports.se_DescribeWorkspaceImagesCommand = se_DescribeWorkspaceImagesCommand;
297
- const se_DescribeWorkspacesCommand = async (input, context) => {
298
- const headers = sharedHeaders("DescribeWorkspaces");
299
- let body;
300
- body = JSON.stringify((0, smithy_client_1._json)(input));
301
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
302
- };
303
- exports.se_DescribeWorkspacesCommand = se_DescribeWorkspacesCommand;
304
- const se_DescribeWorkspacesConnectionStatusCommand = async (input, context) => {
305
- const headers = sharedHeaders("DescribeWorkspacesConnectionStatus");
306
- let body;
307
- body = JSON.stringify((0, smithy_client_1._json)(input));
308
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
309
- };
310
- exports.se_DescribeWorkspacesConnectionStatusCommand = se_DescribeWorkspacesConnectionStatusCommand;
311
- const se_DescribeWorkspaceSnapshotsCommand = async (input, context) => {
312
- const headers = sharedHeaders("DescribeWorkspaceSnapshots");
313
- let body;
314
- body = JSON.stringify((0, smithy_client_1._json)(input));
315
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
316
- };
317
- exports.se_DescribeWorkspaceSnapshotsCommand = se_DescribeWorkspaceSnapshotsCommand;
318
- const se_DisassociateConnectionAliasCommand = async (input, context) => {
319
- const headers = sharedHeaders("DisassociateConnectionAlias");
320
- let body;
321
- body = JSON.stringify((0, smithy_client_1._json)(input));
322
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
323
- };
324
- exports.se_DisassociateConnectionAliasCommand = se_DisassociateConnectionAliasCommand;
325
- const se_DisassociateIpGroupsCommand = async (input, context) => {
326
- const headers = sharedHeaders("DisassociateIpGroups");
327
- let body;
328
- body = JSON.stringify((0, smithy_client_1._json)(input));
329
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
330
- };
331
- exports.se_DisassociateIpGroupsCommand = se_DisassociateIpGroupsCommand;
332
- const se_DisassociateWorkspaceApplicationCommand = async (input, context) => {
333
- const headers = sharedHeaders("DisassociateWorkspaceApplication");
334
- let body;
335
- body = JSON.stringify((0, smithy_client_1._json)(input));
336
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
337
- };
338
- exports.se_DisassociateWorkspaceApplicationCommand = se_DisassociateWorkspaceApplicationCommand;
339
- const se_ImportClientBrandingCommand = async (input, context) => {
340
- const headers = sharedHeaders("ImportClientBranding");
341
- let body;
342
- body = JSON.stringify(se_ImportClientBrandingRequest(input, context));
343
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
344
- };
345
- exports.se_ImportClientBrandingCommand = se_ImportClientBrandingCommand;
346
- const se_ImportWorkspaceImageCommand = async (input, context) => {
347
- const headers = sharedHeaders("ImportWorkspaceImage");
348
- let body;
349
- body = JSON.stringify((0, smithy_client_1._json)(input));
350
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
351
- };
352
- exports.se_ImportWorkspaceImageCommand = se_ImportWorkspaceImageCommand;
353
- const se_ListAvailableManagementCidrRangesCommand = async (input, context) => {
354
- const headers = sharedHeaders("ListAvailableManagementCidrRanges");
355
- let body;
356
- body = JSON.stringify((0, smithy_client_1._json)(input));
357
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
358
- };
359
- exports.se_ListAvailableManagementCidrRangesCommand = se_ListAvailableManagementCidrRangesCommand;
360
- const se_MigrateWorkspaceCommand = async (input, context) => {
361
- const headers = sharedHeaders("MigrateWorkspace");
362
- let body;
363
- body = JSON.stringify((0, smithy_client_1._json)(input));
364
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
365
- };
366
- exports.se_MigrateWorkspaceCommand = se_MigrateWorkspaceCommand;
367
- const se_ModifyAccountCommand = async (input, context) => {
368
- const headers = sharedHeaders("ModifyAccount");
369
- let body;
370
- body = JSON.stringify((0, smithy_client_1._json)(input));
371
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
372
- };
373
- exports.se_ModifyAccountCommand = se_ModifyAccountCommand;
374
- const se_ModifyCertificateBasedAuthPropertiesCommand = async (input, context) => {
375
- const headers = sharedHeaders("ModifyCertificateBasedAuthProperties");
376
- let body;
377
- body = JSON.stringify((0, smithy_client_1._json)(input));
378
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
379
- };
380
- exports.se_ModifyCertificateBasedAuthPropertiesCommand = se_ModifyCertificateBasedAuthPropertiesCommand;
381
- const se_ModifyClientPropertiesCommand = async (input, context) => {
382
- const headers = sharedHeaders("ModifyClientProperties");
383
- let body;
384
- body = JSON.stringify((0, smithy_client_1._json)(input));
385
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
386
- };
387
- exports.se_ModifyClientPropertiesCommand = se_ModifyClientPropertiesCommand;
388
- const se_ModifySamlPropertiesCommand = async (input, context) => {
389
- const headers = sharedHeaders("ModifySamlProperties");
390
- let body;
391
- body = JSON.stringify((0, smithy_client_1._json)(input));
392
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
393
- };
394
- exports.se_ModifySamlPropertiesCommand = se_ModifySamlPropertiesCommand;
395
- const se_ModifySelfservicePermissionsCommand = async (input, context) => {
396
- const headers = sharedHeaders("ModifySelfservicePermissions");
397
- let body;
398
- body = JSON.stringify((0, smithy_client_1._json)(input));
399
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
400
- };
401
- exports.se_ModifySelfservicePermissionsCommand = se_ModifySelfservicePermissionsCommand;
402
- const se_ModifyWorkspaceAccessPropertiesCommand = async (input, context) => {
403
- const headers = sharedHeaders("ModifyWorkspaceAccessProperties");
404
- let body;
405
- body = JSON.stringify((0, smithy_client_1._json)(input));
406
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
407
- };
408
- exports.se_ModifyWorkspaceAccessPropertiesCommand = se_ModifyWorkspaceAccessPropertiesCommand;
409
- const se_ModifyWorkspaceCreationPropertiesCommand = async (input, context) => {
410
- const headers = sharedHeaders("ModifyWorkspaceCreationProperties");
411
- let body;
412
- body = JSON.stringify((0, smithy_client_1._json)(input));
413
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
414
- };
415
- exports.se_ModifyWorkspaceCreationPropertiesCommand = se_ModifyWorkspaceCreationPropertiesCommand;
416
- const se_ModifyWorkspacePropertiesCommand = async (input, context) => {
417
- const headers = sharedHeaders("ModifyWorkspaceProperties");
418
- let body;
419
- body = JSON.stringify((0, smithy_client_1._json)(input));
420
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
421
- };
422
- exports.se_ModifyWorkspacePropertiesCommand = se_ModifyWorkspacePropertiesCommand;
423
- const se_ModifyWorkspaceStateCommand = async (input, context) => {
424
- const headers = sharedHeaders("ModifyWorkspaceState");
425
- let body;
426
- body = JSON.stringify((0, smithy_client_1._json)(input));
427
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
428
- };
429
- exports.se_ModifyWorkspaceStateCommand = se_ModifyWorkspaceStateCommand;
430
- const se_RebootWorkspacesCommand = async (input, context) => {
431
- const headers = sharedHeaders("RebootWorkspaces");
432
- let body;
433
- body = JSON.stringify((0, smithy_client_1._json)(input));
434
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
435
- };
436
- exports.se_RebootWorkspacesCommand = se_RebootWorkspacesCommand;
437
- const se_RebuildWorkspacesCommand = async (input, context) => {
438
- const headers = sharedHeaders("RebuildWorkspaces");
439
- let body;
440
- body = JSON.stringify((0, smithy_client_1._json)(input));
441
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
442
- };
443
- exports.se_RebuildWorkspacesCommand = se_RebuildWorkspacesCommand;
444
- const se_RegisterWorkspaceDirectoryCommand = async (input, context) => {
445
- const headers = sharedHeaders("RegisterWorkspaceDirectory");
446
- let body;
447
- body = JSON.stringify((0, smithy_client_1._json)(input));
448
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
449
- };
450
- exports.se_RegisterWorkspaceDirectoryCommand = se_RegisterWorkspaceDirectoryCommand;
451
- const se_RestoreWorkspaceCommand = async (input, context) => {
452
- const headers = sharedHeaders("RestoreWorkspace");
453
- let body;
454
- body = JSON.stringify((0, smithy_client_1._json)(input));
455
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
456
- };
457
- exports.se_RestoreWorkspaceCommand = se_RestoreWorkspaceCommand;
458
- const se_RevokeIpRulesCommand = async (input, context) => {
459
- const headers = sharedHeaders("RevokeIpRules");
460
- let body;
461
- body = JSON.stringify((0, smithy_client_1._json)(input));
462
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
463
- };
464
- exports.se_RevokeIpRulesCommand = se_RevokeIpRulesCommand;
465
- const se_StartWorkspacesCommand = async (input, context) => {
466
- const headers = sharedHeaders("StartWorkspaces");
467
- let body;
468
- body = JSON.stringify((0, smithy_client_1._json)(input));
469
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
470
- };
471
- exports.se_StartWorkspacesCommand = se_StartWorkspacesCommand;
472
- const se_StopWorkspacesCommand = async (input, context) => {
473
- const headers = sharedHeaders("StopWorkspaces");
474
- let body;
475
- body = JSON.stringify((0, smithy_client_1._json)(input));
476
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
477
- };
478
- exports.se_StopWorkspacesCommand = se_StopWorkspacesCommand;
479
- const se_TerminateWorkspacesCommand = async (input, context) => {
480
- const headers = sharedHeaders("TerminateWorkspaces");
481
- let body;
482
- body = JSON.stringify((0, smithy_client_1._json)(input));
483
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
484
- };
485
- exports.se_TerminateWorkspacesCommand = se_TerminateWorkspacesCommand;
486
- const se_UpdateConnectClientAddInCommand = async (input, context) => {
487
- const headers = sharedHeaders("UpdateConnectClientAddIn");
488
- let body;
489
- body = JSON.stringify((0, smithy_client_1._json)(input));
490
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
491
- };
492
- exports.se_UpdateConnectClientAddInCommand = se_UpdateConnectClientAddInCommand;
493
- const se_UpdateConnectionAliasPermissionCommand = async (input, context) => {
494
- const headers = sharedHeaders("UpdateConnectionAliasPermission");
495
- let body;
496
- body = JSON.stringify((0, smithy_client_1._json)(input));
497
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
498
- };
499
- exports.se_UpdateConnectionAliasPermissionCommand = se_UpdateConnectionAliasPermissionCommand;
500
- const se_UpdateRulesOfIpGroupCommand = async (input, context) => {
501
- const headers = sharedHeaders("UpdateRulesOfIpGroup");
502
- let body;
503
- body = JSON.stringify((0, smithy_client_1._json)(input));
504
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
505
- };
506
- exports.se_UpdateRulesOfIpGroupCommand = se_UpdateRulesOfIpGroupCommand;
507
- const se_UpdateWorkspaceBundleCommand = async (input, context) => {
508
- const headers = sharedHeaders("UpdateWorkspaceBundle");
509
- let body;
510
- body = JSON.stringify((0, smithy_client_1._json)(input));
511
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
512
- };
513
- exports.se_UpdateWorkspaceBundleCommand = se_UpdateWorkspaceBundleCommand;
514
- const se_UpdateWorkspaceImagePermissionCommand = async (input, context) => {
515
- const headers = sharedHeaders("UpdateWorkspaceImagePermission");
516
- let body;
517
- body = JSON.stringify((0, smithy_client_1._json)(input));
518
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
519
- };
520
- exports.se_UpdateWorkspaceImagePermissionCommand = se_UpdateWorkspaceImagePermissionCommand;
521
- const de_AssociateConnectionAliasCommand = async (output, context) => {
522
- if (output.statusCode >= 300) {
523
- return de_AssociateConnectionAliasCommandError(output, context);
524
- }
525
- const data = await parseBody(output.body, context);
526
- let contents = {};
527
- contents = (0, smithy_client_1._json)(data);
528
- const response = {
529
- $metadata: deserializeMetadata(output),
530
- ...contents,
531
- };
532
- return response;
533
- };
534
- exports.de_AssociateConnectionAliasCommand = de_AssociateConnectionAliasCommand;
535
- const de_AssociateConnectionAliasCommandError = async (output, context) => {
536
- const parsedOutput = {
537
- ...output,
538
- body: await parseErrorBody(output.body, context),
539
- };
540
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
541
- switch (errorCode) {
542
- case "AccessDeniedException":
543
- case "com.amazonaws.workspaces#AccessDeniedException":
544
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
545
- case "InvalidParameterValuesException":
546
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
547
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
548
- case "InvalidResourceStateException":
549
- case "com.amazonaws.workspaces#InvalidResourceStateException":
550
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
551
- case "OperationNotSupportedException":
552
- case "com.amazonaws.workspaces#OperationNotSupportedException":
553
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
554
- case "ResourceAssociatedException":
555
- case "com.amazonaws.workspaces#ResourceAssociatedException":
556
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
557
- case "ResourceNotFoundException":
558
- case "com.amazonaws.workspaces#ResourceNotFoundException":
559
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
560
- default:
561
- const parsedBody = parsedOutput.body;
562
- return throwDefaultError({
563
- output,
564
- parsedBody,
565
- errorCode,
566
- });
567
- }
568
- };
569
- const de_AssociateIpGroupsCommand = async (output, context) => {
570
- if (output.statusCode >= 300) {
571
- return de_AssociateIpGroupsCommandError(output, context);
572
- }
573
- const data = await parseBody(output.body, context);
574
- let contents = {};
575
- contents = (0, smithy_client_1._json)(data);
576
- const response = {
577
- $metadata: deserializeMetadata(output),
578
- ...contents,
579
- };
580
- return response;
581
- };
582
- exports.de_AssociateIpGroupsCommand = de_AssociateIpGroupsCommand;
583
- const de_AssociateIpGroupsCommandError = async (output, context) => {
584
- const parsedOutput = {
585
- ...output,
586
- body: await parseErrorBody(output.body, context),
587
- };
588
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
589
- switch (errorCode) {
590
- case "AccessDeniedException":
591
- case "com.amazonaws.workspaces#AccessDeniedException":
592
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
593
- case "InvalidParameterValuesException":
594
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
595
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
596
- case "InvalidResourceStateException":
597
- case "com.amazonaws.workspaces#InvalidResourceStateException":
598
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
599
- case "OperationNotSupportedException":
600
- case "com.amazonaws.workspaces#OperationNotSupportedException":
601
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
602
- case "ResourceLimitExceededException":
603
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
604
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
605
- case "ResourceNotFoundException":
606
- case "com.amazonaws.workspaces#ResourceNotFoundException":
607
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
608
- default:
609
- const parsedBody = parsedOutput.body;
610
- return throwDefaultError({
611
- output,
612
- parsedBody,
613
- errorCode,
614
- });
615
- }
616
- };
617
- const de_AssociateWorkspaceApplicationCommand = async (output, context) => {
618
- if (output.statusCode >= 300) {
619
- return de_AssociateWorkspaceApplicationCommandError(output, context);
620
- }
621
- const data = await parseBody(output.body, context);
622
- let contents = {};
623
- contents = de_AssociateWorkspaceApplicationResult(data, context);
624
- const response = {
625
- $metadata: deserializeMetadata(output),
626
- ...contents,
627
- };
628
- return response;
629
- };
630
- exports.de_AssociateWorkspaceApplicationCommand = de_AssociateWorkspaceApplicationCommand;
631
- const de_AssociateWorkspaceApplicationCommandError = async (output, context) => {
632
- const parsedOutput = {
633
- ...output,
634
- body: await parseErrorBody(output.body, context),
635
- };
636
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
637
- switch (errorCode) {
638
- case "AccessDeniedException":
639
- case "com.amazonaws.workspaces#AccessDeniedException":
640
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
641
- case "ApplicationNotSupportedException":
642
- case "com.amazonaws.workspaces#ApplicationNotSupportedException":
643
- throw await de_ApplicationNotSupportedExceptionRes(parsedOutput, context);
644
- case "ComputeNotCompatibleException":
645
- case "com.amazonaws.workspaces#ComputeNotCompatibleException":
646
- throw await de_ComputeNotCompatibleExceptionRes(parsedOutput, context);
647
- case "IncompatibleApplicationsException":
648
- case "com.amazonaws.workspaces#IncompatibleApplicationsException":
649
- throw await de_IncompatibleApplicationsExceptionRes(parsedOutput, context);
650
- case "InvalidParameterValuesException":
651
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
652
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
653
- case "OperatingSystemNotCompatibleException":
654
- case "com.amazonaws.workspaces#OperatingSystemNotCompatibleException":
655
- throw await de_OperatingSystemNotCompatibleExceptionRes(parsedOutput, context);
656
- case "OperationNotSupportedException":
657
- case "com.amazonaws.workspaces#OperationNotSupportedException":
658
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
659
- case "ResourceAlreadyExistsException":
660
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
661
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
662
- case "ResourceInUseException":
663
- case "com.amazonaws.workspaces#ResourceInUseException":
664
- throw await de_ResourceInUseExceptionRes(parsedOutput, context);
665
- case "ResourceNotFoundException":
666
- case "com.amazonaws.workspaces#ResourceNotFoundException":
667
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
668
- default:
669
- const parsedBody = parsedOutput.body;
670
- return throwDefaultError({
671
- output,
672
- parsedBody,
673
- errorCode,
674
- });
675
- }
676
- };
677
- const de_AuthorizeIpRulesCommand = async (output, context) => {
678
- if (output.statusCode >= 300) {
679
- return de_AuthorizeIpRulesCommandError(output, context);
680
- }
681
- const data = await parseBody(output.body, context);
682
- let contents = {};
683
- contents = (0, smithy_client_1._json)(data);
684
- const response = {
685
- $metadata: deserializeMetadata(output),
686
- ...contents,
687
- };
688
- return response;
689
- };
690
- exports.de_AuthorizeIpRulesCommand = de_AuthorizeIpRulesCommand;
691
- const de_AuthorizeIpRulesCommandError = async (output, context) => {
692
- const parsedOutput = {
693
- ...output,
694
- body: await parseErrorBody(output.body, context),
695
- };
696
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
697
- switch (errorCode) {
698
- case "AccessDeniedException":
699
- case "com.amazonaws.workspaces#AccessDeniedException":
700
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
701
- case "InvalidParameterValuesException":
702
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
703
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
704
- case "InvalidResourceStateException":
705
- case "com.amazonaws.workspaces#InvalidResourceStateException":
706
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
707
- case "ResourceLimitExceededException":
708
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
709
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
710
- case "ResourceNotFoundException":
711
- case "com.amazonaws.workspaces#ResourceNotFoundException":
712
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
713
- default:
714
- const parsedBody = parsedOutput.body;
715
- return throwDefaultError({
716
- output,
717
- parsedBody,
718
- errorCode,
719
- });
720
- }
721
- };
722
- const de_CopyWorkspaceImageCommand = async (output, context) => {
723
- if (output.statusCode >= 300) {
724
- return de_CopyWorkspaceImageCommandError(output, context);
725
- }
726
- const data = await parseBody(output.body, context);
727
- let contents = {};
728
- contents = (0, smithy_client_1._json)(data);
729
- const response = {
730
- $metadata: deserializeMetadata(output),
731
- ...contents,
732
- };
733
- return response;
734
- };
735
- exports.de_CopyWorkspaceImageCommand = de_CopyWorkspaceImageCommand;
736
- const de_CopyWorkspaceImageCommandError = async (output, context) => {
737
- const parsedOutput = {
738
- ...output,
739
- body: await parseErrorBody(output.body, context),
740
- };
741
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
742
- switch (errorCode) {
743
- case "AccessDeniedException":
744
- case "com.amazonaws.workspaces#AccessDeniedException":
745
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
746
- case "InvalidParameterValuesException":
747
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
748
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
749
- case "OperationNotSupportedException":
750
- case "com.amazonaws.workspaces#OperationNotSupportedException":
751
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
752
- case "ResourceAlreadyExistsException":
753
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
754
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
755
- case "ResourceLimitExceededException":
756
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
757
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
758
- case "ResourceNotFoundException":
759
- case "com.amazonaws.workspaces#ResourceNotFoundException":
760
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
761
- case "ResourceUnavailableException":
762
- case "com.amazonaws.workspaces#ResourceUnavailableException":
763
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
764
- default:
765
- const parsedBody = parsedOutput.body;
766
- return throwDefaultError({
767
- output,
768
- parsedBody,
769
- errorCode,
770
- });
771
- }
772
- };
773
- const de_CreateConnectClientAddInCommand = async (output, context) => {
774
- if (output.statusCode >= 300) {
775
- return de_CreateConnectClientAddInCommandError(output, context);
776
- }
777
- const data = await parseBody(output.body, context);
778
- let contents = {};
779
- contents = (0, smithy_client_1._json)(data);
780
- const response = {
781
- $metadata: deserializeMetadata(output),
782
- ...contents,
783
- };
784
- return response;
785
- };
786
- exports.de_CreateConnectClientAddInCommand = de_CreateConnectClientAddInCommand;
787
- const de_CreateConnectClientAddInCommandError = async (output, context) => {
788
- const parsedOutput = {
789
- ...output,
790
- body: await parseErrorBody(output.body, context),
791
- };
792
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
793
- switch (errorCode) {
794
- case "AccessDeniedException":
795
- case "com.amazonaws.workspaces#AccessDeniedException":
796
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
797
- case "InvalidParameterValuesException":
798
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
799
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
800
- case "ResourceAlreadyExistsException":
801
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
802
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
803
- case "ResourceCreationFailedException":
804
- case "com.amazonaws.workspaces#ResourceCreationFailedException":
805
- throw await de_ResourceCreationFailedExceptionRes(parsedOutput, context);
806
- case "ResourceNotFoundException":
807
- case "com.amazonaws.workspaces#ResourceNotFoundException":
808
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
809
- default:
810
- const parsedBody = parsedOutput.body;
811
- return throwDefaultError({
812
- output,
813
- parsedBody,
814
- errorCode,
815
- });
816
- }
817
- };
818
- const de_CreateConnectionAliasCommand = async (output, context) => {
819
- if (output.statusCode >= 300) {
820
- return de_CreateConnectionAliasCommandError(output, context);
821
- }
822
- const data = await parseBody(output.body, context);
823
- let contents = {};
824
- contents = (0, smithy_client_1._json)(data);
825
- const response = {
826
- $metadata: deserializeMetadata(output),
827
- ...contents,
828
- };
829
- return response;
830
- };
831
- exports.de_CreateConnectionAliasCommand = de_CreateConnectionAliasCommand;
832
- const de_CreateConnectionAliasCommandError = async (output, context) => {
833
- const parsedOutput = {
834
- ...output,
835
- body: await parseErrorBody(output.body, context),
836
- };
837
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
838
- switch (errorCode) {
839
- case "AccessDeniedException":
840
- case "com.amazonaws.workspaces#AccessDeniedException":
841
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
842
- case "InvalidParameterValuesException":
843
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
844
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
845
- case "InvalidResourceStateException":
846
- case "com.amazonaws.workspaces#InvalidResourceStateException":
847
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
848
- case "OperationNotSupportedException":
849
- case "com.amazonaws.workspaces#OperationNotSupportedException":
850
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
851
- case "ResourceAlreadyExistsException":
852
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
853
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
854
- case "ResourceLimitExceededException":
855
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
856
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
857
- default:
858
- const parsedBody = parsedOutput.body;
859
- return throwDefaultError({
860
- output,
861
- parsedBody,
862
- errorCode,
863
- });
864
- }
865
- };
866
- const de_CreateIpGroupCommand = async (output, context) => {
867
- if (output.statusCode >= 300) {
868
- return de_CreateIpGroupCommandError(output, context);
869
- }
870
- const data = await parseBody(output.body, context);
871
- let contents = {};
872
- contents = (0, smithy_client_1._json)(data);
873
- const response = {
874
- $metadata: deserializeMetadata(output),
875
- ...contents,
876
- };
877
- return response;
878
- };
879
- exports.de_CreateIpGroupCommand = de_CreateIpGroupCommand;
880
- const de_CreateIpGroupCommandError = async (output, context) => {
881
- const parsedOutput = {
882
- ...output,
883
- body: await parseErrorBody(output.body, context),
884
- };
885
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
886
- switch (errorCode) {
887
- case "AccessDeniedException":
888
- case "com.amazonaws.workspaces#AccessDeniedException":
889
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
890
- case "InvalidParameterValuesException":
891
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
892
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
893
- case "ResourceAlreadyExistsException":
894
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
895
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
896
- case "ResourceCreationFailedException":
897
- case "com.amazonaws.workspaces#ResourceCreationFailedException":
898
- throw await de_ResourceCreationFailedExceptionRes(parsedOutput, context);
899
- case "ResourceLimitExceededException":
900
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
901
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
902
- default:
903
- const parsedBody = parsedOutput.body;
904
- return throwDefaultError({
905
- output,
906
- parsedBody,
907
- errorCode,
908
- });
909
- }
910
- };
911
- const de_CreateStandbyWorkspacesCommand = async (output, context) => {
912
- if (output.statusCode >= 300) {
913
- return de_CreateStandbyWorkspacesCommandError(output, context);
914
- }
915
- const data = await parseBody(output.body, context);
916
- let contents = {};
917
- contents = (0, smithy_client_1._json)(data);
918
- const response = {
919
- $metadata: deserializeMetadata(output),
920
- ...contents,
921
- };
922
- return response;
923
- };
924
- exports.de_CreateStandbyWorkspacesCommand = de_CreateStandbyWorkspacesCommand;
925
- const de_CreateStandbyWorkspacesCommandError = async (output, context) => {
926
- const parsedOutput = {
927
- ...output,
928
- body: await parseErrorBody(output.body, context),
929
- };
930
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
931
- switch (errorCode) {
932
- case "AccessDeniedException":
933
- case "com.amazonaws.workspaces#AccessDeniedException":
934
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
935
- case "InvalidParameterValuesException":
936
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
937
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
938
- case "OperationNotSupportedException":
939
- case "com.amazonaws.workspaces#OperationNotSupportedException":
940
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
941
- case "ResourceLimitExceededException":
942
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
943
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
944
- case "ResourceNotFoundException":
945
- case "com.amazonaws.workspaces#ResourceNotFoundException":
946
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
947
- default:
948
- const parsedBody = parsedOutput.body;
949
- return throwDefaultError({
950
- output,
951
- parsedBody,
952
- errorCode,
953
- });
954
- }
955
- };
956
- const de_CreateTagsCommand = async (output, context) => {
957
- if (output.statusCode >= 300) {
958
- return de_CreateTagsCommandError(output, context);
959
- }
960
- const data = await parseBody(output.body, context);
961
- let contents = {};
962
- contents = (0, smithy_client_1._json)(data);
963
- const response = {
964
- $metadata: deserializeMetadata(output),
965
- ...contents,
966
- };
967
- return response;
968
- };
969
- exports.de_CreateTagsCommand = de_CreateTagsCommand;
970
- const de_CreateTagsCommandError = async (output, context) => {
971
- const parsedOutput = {
972
- ...output,
973
- body: await parseErrorBody(output.body, context),
974
- };
975
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
976
- switch (errorCode) {
977
- case "InvalidParameterValuesException":
978
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
979
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
980
- case "ResourceLimitExceededException":
981
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
982
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
983
- case "ResourceNotFoundException":
984
- case "com.amazonaws.workspaces#ResourceNotFoundException":
985
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
986
- default:
987
- const parsedBody = parsedOutput.body;
988
- return throwDefaultError({
989
- output,
990
- parsedBody,
991
- errorCode,
992
- });
993
- }
994
- };
995
- const de_CreateUpdatedWorkspaceImageCommand = async (output, context) => {
996
- if (output.statusCode >= 300) {
997
- return de_CreateUpdatedWorkspaceImageCommandError(output, context);
998
- }
999
- const data = await parseBody(output.body, context);
1000
- let contents = {};
1001
- contents = (0, smithy_client_1._json)(data);
1002
- const response = {
1003
- $metadata: deserializeMetadata(output),
1004
- ...contents,
1005
- };
1006
- return response;
1007
- };
1008
- exports.de_CreateUpdatedWorkspaceImageCommand = de_CreateUpdatedWorkspaceImageCommand;
1009
- const de_CreateUpdatedWorkspaceImageCommandError = async (output, context) => {
1010
- const parsedOutput = {
1011
- ...output,
1012
- body: await parseErrorBody(output.body, context),
1013
- };
1014
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1015
- switch (errorCode) {
1016
- case "AccessDeniedException":
1017
- case "com.amazonaws.workspaces#AccessDeniedException":
1018
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1019
- case "InvalidParameterValuesException":
1020
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1021
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1022
- case "InvalidResourceStateException":
1023
- case "com.amazonaws.workspaces#InvalidResourceStateException":
1024
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
1025
- case "OperationNotSupportedException":
1026
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1027
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1028
- case "ResourceAlreadyExistsException":
1029
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
1030
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1031
- case "ResourceLimitExceededException":
1032
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
1033
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
1034
- case "ResourceNotFoundException":
1035
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1036
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1037
- default:
1038
- const parsedBody = parsedOutput.body;
1039
- return throwDefaultError({
1040
- output,
1041
- parsedBody,
1042
- errorCode,
1043
- });
1044
- }
1045
- };
1046
- const de_CreateWorkspaceBundleCommand = async (output, context) => {
1047
- if (output.statusCode >= 300) {
1048
- return de_CreateWorkspaceBundleCommandError(output, context);
1049
- }
1050
- const data = await parseBody(output.body, context);
1051
- let contents = {};
1052
- contents = de_CreateWorkspaceBundleResult(data, context);
1053
- const response = {
1054
- $metadata: deserializeMetadata(output),
1055
- ...contents,
1056
- };
1057
- return response;
1058
- };
1059
- exports.de_CreateWorkspaceBundleCommand = de_CreateWorkspaceBundleCommand;
1060
- const de_CreateWorkspaceBundleCommandError = async (output, context) => {
1061
- const parsedOutput = {
1062
- ...output,
1063
- body: await parseErrorBody(output.body, context),
1064
- };
1065
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1066
- switch (errorCode) {
1067
- case "AccessDeniedException":
1068
- case "com.amazonaws.workspaces#AccessDeniedException":
1069
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1070
- case "InvalidParameterValuesException":
1071
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1072
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1073
- case "ResourceAlreadyExistsException":
1074
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
1075
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1076
- case "ResourceLimitExceededException":
1077
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
1078
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
1079
- case "ResourceNotFoundException":
1080
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1081
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1082
- case "ResourceUnavailableException":
1083
- case "com.amazonaws.workspaces#ResourceUnavailableException":
1084
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
1085
- default:
1086
- const parsedBody = parsedOutput.body;
1087
- return throwDefaultError({
1088
- output,
1089
- parsedBody,
1090
- errorCode,
1091
- });
1092
- }
1093
- };
1094
- const de_CreateWorkspaceImageCommand = async (output, context) => {
1095
- if (output.statusCode >= 300) {
1096
- return de_CreateWorkspaceImageCommandError(output, context);
1097
- }
1098
- const data = await parseBody(output.body, context);
1099
- let contents = {};
1100
- contents = de_CreateWorkspaceImageResult(data, context);
1101
- const response = {
1102
- $metadata: deserializeMetadata(output),
1103
- ...contents,
1104
- };
1105
- return response;
1106
- };
1107
- exports.de_CreateWorkspaceImageCommand = de_CreateWorkspaceImageCommand;
1108
- const de_CreateWorkspaceImageCommandError = async (output, context) => {
1109
- const parsedOutput = {
1110
- ...output,
1111
- body: await parseErrorBody(output.body, context),
1112
- };
1113
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1114
- switch (errorCode) {
1115
- case "AccessDeniedException":
1116
- case "com.amazonaws.workspaces#AccessDeniedException":
1117
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1118
- case "InvalidParameterValuesException":
1119
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1120
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1121
- case "InvalidResourceStateException":
1122
- case "com.amazonaws.workspaces#InvalidResourceStateException":
1123
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
1124
- case "OperationNotSupportedException":
1125
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1126
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1127
- case "ResourceAlreadyExistsException":
1128
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
1129
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
1130
- case "ResourceLimitExceededException":
1131
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
1132
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
1133
- case "ResourceNotFoundException":
1134
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1135
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1136
- default:
1137
- const parsedBody = parsedOutput.body;
1138
- return throwDefaultError({
1139
- output,
1140
- parsedBody,
1141
- errorCode,
1142
- });
1143
- }
1144
- };
1145
- const de_CreateWorkspacesCommand = async (output, context) => {
1146
- if (output.statusCode >= 300) {
1147
- return de_CreateWorkspacesCommandError(output, context);
1148
- }
1149
- const data = await parseBody(output.body, context);
1150
- let contents = {};
1151
- contents = de_CreateWorkspacesResult(data, context);
1152
- const response = {
1153
- $metadata: deserializeMetadata(output),
1154
- ...contents,
1155
- };
1156
- return response;
1157
- };
1158
- exports.de_CreateWorkspacesCommand = de_CreateWorkspacesCommand;
1159
- const de_CreateWorkspacesCommandError = async (output, context) => {
1160
- const parsedOutput = {
1161
- ...output,
1162
- body: await parseErrorBody(output.body, context),
1163
- };
1164
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1165
- switch (errorCode) {
1166
- case "InvalidParameterValuesException":
1167
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1168
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1169
- case "ResourceLimitExceededException":
1170
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
1171
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
1172
- default:
1173
- const parsedBody = parsedOutput.body;
1174
- return throwDefaultError({
1175
- output,
1176
- parsedBody,
1177
- errorCode,
1178
- });
1179
- }
1180
- };
1181
- const de_DeleteClientBrandingCommand = async (output, context) => {
1182
- if (output.statusCode >= 300) {
1183
- return de_DeleteClientBrandingCommandError(output, context);
1184
- }
1185
- const data = await parseBody(output.body, context);
1186
- let contents = {};
1187
- contents = (0, smithy_client_1._json)(data);
1188
- const response = {
1189
- $metadata: deserializeMetadata(output),
1190
- ...contents,
1191
- };
1192
- return response;
1193
- };
1194
- exports.de_DeleteClientBrandingCommand = de_DeleteClientBrandingCommand;
1195
- const de_DeleteClientBrandingCommandError = async (output, context) => {
1196
- const parsedOutput = {
1197
- ...output,
1198
- body: await parseErrorBody(output.body, context),
1199
- };
1200
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1201
- switch (errorCode) {
1202
- case "AccessDeniedException":
1203
- case "com.amazonaws.workspaces#AccessDeniedException":
1204
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1205
- case "InvalidParameterValuesException":
1206
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1207
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1208
- case "ResourceNotFoundException":
1209
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1210
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1211
- default:
1212
- const parsedBody = parsedOutput.body;
1213
- return throwDefaultError({
1214
- output,
1215
- parsedBody,
1216
- errorCode,
1217
- });
1218
- }
1219
- };
1220
- const de_DeleteConnectClientAddInCommand = async (output, context) => {
1221
- if (output.statusCode >= 300) {
1222
- return de_DeleteConnectClientAddInCommandError(output, context);
1223
- }
1224
- const data = await parseBody(output.body, context);
1225
- let contents = {};
1226
- contents = (0, smithy_client_1._json)(data);
1227
- const response = {
1228
- $metadata: deserializeMetadata(output),
1229
- ...contents,
1230
- };
1231
- return response;
1232
- };
1233
- exports.de_DeleteConnectClientAddInCommand = de_DeleteConnectClientAddInCommand;
1234
- const de_DeleteConnectClientAddInCommandError = async (output, context) => {
1235
- const parsedOutput = {
1236
- ...output,
1237
- body: await parseErrorBody(output.body, context),
1238
- };
1239
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1240
- switch (errorCode) {
1241
- case "AccessDeniedException":
1242
- case "com.amazonaws.workspaces#AccessDeniedException":
1243
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1244
- case "InvalidParameterValuesException":
1245
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1246
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1247
- case "ResourceNotFoundException":
1248
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1249
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1250
- default:
1251
- const parsedBody = parsedOutput.body;
1252
- return throwDefaultError({
1253
- output,
1254
- parsedBody,
1255
- errorCode,
1256
- });
1257
- }
1258
- };
1259
- const de_DeleteConnectionAliasCommand = async (output, context) => {
1260
- if (output.statusCode >= 300) {
1261
- return de_DeleteConnectionAliasCommandError(output, context);
1262
- }
1263
- const data = await parseBody(output.body, context);
1264
- let contents = {};
1265
- contents = (0, smithy_client_1._json)(data);
1266
- const response = {
1267
- $metadata: deserializeMetadata(output),
1268
- ...contents,
1269
- };
1270
- return response;
1271
- };
1272
- exports.de_DeleteConnectionAliasCommand = de_DeleteConnectionAliasCommand;
1273
- const de_DeleteConnectionAliasCommandError = async (output, context) => {
1274
- const parsedOutput = {
1275
- ...output,
1276
- body: await parseErrorBody(output.body, context),
1277
- };
1278
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1279
- switch (errorCode) {
1280
- case "AccessDeniedException":
1281
- case "com.amazonaws.workspaces#AccessDeniedException":
1282
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1283
- case "InvalidParameterValuesException":
1284
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1285
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1286
- case "InvalidResourceStateException":
1287
- case "com.amazonaws.workspaces#InvalidResourceStateException":
1288
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
1289
- case "OperationNotSupportedException":
1290
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1291
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1292
- case "ResourceAssociatedException":
1293
- case "com.amazonaws.workspaces#ResourceAssociatedException":
1294
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
1295
- case "ResourceNotFoundException":
1296
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1297
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1298
- default:
1299
- const parsedBody = parsedOutput.body;
1300
- return throwDefaultError({
1301
- output,
1302
- parsedBody,
1303
- errorCode,
1304
- });
1305
- }
1306
- };
1307
- const de_DeleteIpGroupCommand = async (output, context) => {
1308
- if (output.statusCode >= 300) {
1309
- return de_DeleteIpGroupCommandError(output, context);
1310
- }
1311
- const data = await parseBody(output.body, context);
1312
- let contents = {};
1313
- contents = (0, smithy_client_1._json)(data);
1314
- const response = {
1315
- $metadata: deserializeMetadata(output),
1316
- ...contents,
1317
- };
1318
- return response;
1319
- };
1320
- exports.de_DeleteIpGroupCommand = de_DeleteIpGroupCommand;
1321
- const de_DeleteIpGroupCommandError = async (output, context) => {
1322
- const parsedOutput = {
1323
- ...output,
1324
- body: await parseErrorBody(output.body, context),
1325
- };
1326
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1327
- switch (errorCode) {
1328
- case "AccessDeniedException":
1329
- case "com.amazonaws.workspaces#AccessDeniedException":
1330
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1331
- case "InvalidParameterValuesException":
1332
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1333
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1334
- case "ResourceAssociatedException":
1335
- case "com.amazonaws.workspaces#ResourceAssociatedException":
1336
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
1337
- case "ResourceNotFoundException":
1338
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1339
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1340
- default:
1341
- const parsedBody = parsedOutput.body;
1342
- return throwDefaultError({
1343
- output,
1344
- parsedBody,
1345
- errorCode,
1346
- });
1347
- }
1348
- };
1349
- const de_DeleteTagsCommand = async (output, context) => {
1350
- if (output.statusCode >= 300) {
1351
- return de_DeleteTagsCommandError(output, context);
1352
- }
1353
- const data = await parseBody(output.body, context);
1354
- let contents = {};
1355
- contents = (0, smithy_client_1._json)(data);
1356
- const response = {
1357
- $metadata: deserializeMetadata(output),
1358
- ...contents,
1359
- };
1360
- return response;
1361
- };
1362
- exports.de_DeleteTagsCommand = de_DeleteTagsCommand;
1363
- const de_DeleteTagsCommandError = async (output, context) => {
1364
- const parsedOutput = {
1365
- ...output,
1366
- body: await parseErrorBody(output.body, context),
1367
- };
1368
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1369
- switch (errorCode) {
1370
- case "InvalidParameterValuesException":
1371
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1372
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1373
- case "ResourceNotFoundException":
1374
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1375
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1376
- default:
1377
- const parsedBody = parsedOutput.body;
1378
- return throwDefaultError({
1379
- output,
1380
- parsedBody,
1381
- errorCode,
1382
- });
1383
- }
1384
- };
1385
- const de_DeleteWorkspaceBundleCommand = async (output, context) => {
1386
- if (output.statusCode >= 300) {
1387
- return de_DeleteWorkspaceBundleCommandError(output, context);
1388
- }
1389
- const data = await parseBody(output.body, context);
1390
- let contents = {};
1391
- contents = (0, smithy_client_1._json)(data);
1392
- const response = {
1393
- $metadata: deserializeMetadata(output),
1394
- ...contents,
1395
- };
1396
- return response;
1397
- };
1398
- exports.de_DeleteWorkspaceBundleCommand = de_DeleteWorkspaceBundleCommand;
1399
- const de_DeleteWorkspaceBundleCommandError = async (output, context) => {
1400
- const parsedOutput = {
1401
- ...output,
1402
- body: await parseErrorBody(output.body, context),
1403
- };
1404
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1405
- switch (errorCode) {
1406
- case "AccessDeniedException":
1407
- case "com.amazonaws.workspaces#AccessDeniedException":
1408
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1409
- case "InvalidParameterValuesException":
1410
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1411
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1412
- case "ResourceAssociatedException":
1413
- case "com.amazonaws.workspaces#ResourceAssociatedException":
1414
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
1415
- case "ResourceNotFoundException":
1416
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1417
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1418
- default:
1419
- const parsedBody = parsedOutput.body;
1420
- return throwDefaultError({
1421
- output,
1422
- parsedBody,
1423
- errorCode,
1424
- });
1425
- }
1426
- };
1427
- const de_DeleteWorkspaceImageCommand = async (output, context) => {
1428
- if (output.statusCode >= 300) {
1429
- return de_DeleteWorkspaceImageCommandError(output, context);
1430
- }
1431
- const data = await parseBody(output.body, context);
1432
- let contents = {};
1433
- contents = (0, smithy_client_1._json)(data);
1434
- const response = {
1435
- $metadata: deserializeMetadata(output),
1436
- ...contents,
1437
- };
1438
- return response;
1439
- };
1440
- exports.de_DeleteWorkspaceImageCommand = de_DeleteWorkspaceImageCommand;
1441
- const de_DeleteWorkspaceImageCommandError = async (output, context) => {
1442
- const parsedOutput = {
1443
- ...output,
1444
- body: await parseErrorBody(output.body, context),
1445
- };
1446
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1447
- switch (errorCode) {
1448
- case "AccessDeniedException":
1449
- case "com.amazonaws.workspaces#AccessDeniedException":
1450
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1451
- case "InvalidResourceStateException":
1452
- case "com.amazonaws.workspaces#InvalidResourceStateException":
1453
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
1454
- case "ResourceAssociatedException":
1455
- case "com.amazonaws.workspaces#ResourceAssociatedException":
1456
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
1457
- default:
1458
- const parsedBody = parsedOutput.body;
1459
- return throwDefaultError({
1460
- output,
1461
- parsedBody,
1462
- errorCode,
1463
- });
1464
- }
1465
- };
1466
- const de_DeployWorkspaceApplicationsCommand = async (output, context) => {
1467
- if (output.statusCode >= 300) {
1468
- return de_DeployWorkspaceApplicationsCommandError(output, context);
1469
- }
1470
- const data = await parseBody(output.body, context);
1471
- let contents = {};
1472
- contents = de_DeployWorkspaceApplicationsResult(data, context);
1473
- const response = {
1474
- $metadata: deserializeMetadata(output),
1475
- ...contents,
1476
- };
1477
- return response;
1478
- };
1479
- exports.de_DeployWorkspaceApplicationsCommand = de_DeployWorkspaceApplicationsCommand;
1480
- const de_DeployWorkspaceApplicationsCommandError = async (output, context) => {
1481
- const parsedOutput = {
1482
- ...output,
1483
- body: await parseErrorBody(output.body, context),
1484
- };
1485
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1486
- switch (errorCode) {
1487
- case "AccessDeniedException":
1488
- case "com.amazonaws.workspaces#AccessDeniedException":
1489
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1490
- case "IncompatibleApplicationsException":
1491
- case "com.amazonaws.workspaces#IncompatibleApplicationsException":
1492
- throw await de_IncompatibleApplicationsExceptionRes(parsedOutput, context);
1493
- case "InvalidParameterValuesException":
1494
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1495
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1496
- case "OperationNotSupportedException":
1497
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1498
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1499
- case "ResourceInUseException":
1500
- case "com.amazonaws.workspaces#ResourceInUseException":
1501
- throw await de_ResourceInUseExceptionRes(parsedOutput, context);
1502
- case "ResourceNotFoundException":
1503
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1504
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1505
- default:
1506
- const parsedBody = parsedOutput.body;
1507
- return throwDefaultError({
1508
- output,
1509
- parsedBody,
1510
- errorCode,
1511
- });
1512
- }
1513
- };
1514
- const de_DeregisterWorkspaceDirectoryCommand = async (output, context) => {
1515
- if (output.statusCode >= 300) {
1516
- return de_DeregisterWorkspaceDirectoryCommandError(output, context);
1517
- }
1518
- const data = await parseBody(output.body, context);
1519
- let contents = {};
1520
- contents = (0, smithy_client_1._json)(data);
1521
- const response = {
1522
- $metadata: deserializeMetadata(output),
1523
- ...contents,
1524
- };
1525
- return response;
1526
- };
1527
- exports.de_DeregisterWorkspaceDirectoryCommand = de_DeregisterWorkspaceDirectoryCommand;
1528
- const de_DeregisterWorkspaceDirectoryCommandError = async (output, context) => {
1529
- const parsedOutput = {
1530
- ...output,
1531
- body: await parseErrorBody(output.body, context),
1532
- };
1533
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1534
- switch (errorCode) {
1535
- case "AccessDeniedException":
1536
- case "com.amazonaws.workspaces#AccessDeniedException":
1537
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1538
- case "InvalidParameterValuesException":
1539
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1540
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1541
- case "InvalidResourceStateException":
1542
- case "com.amazonaws.workspaces#InvalidResourceStateException":
1543
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
1544
- case "OperationNotSupportedException":
1545
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1546
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1547
- case "ResourceNotFoundException":
1548
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1549
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1550
- default:
1551
- const parsedBody = parsedOutput.body;
1552
- return throwDefaultError({
1553
- output,
1554
- parsedBody,
1555
- errorCode,
1556
- });
1557
- }
1558
- };
1559
- const de_DescribeAccountCommand = async (output, context) => {
1560
- if (output.statusCode >= 300) {
1561
- return de_DescribeAccountCommandError(output, context);
1562
- }
1563
- const data = await parseBody(output.body, context);
1564
- let contents = {};
1565
- contents = (0, smithy_client_1._json)(data);
1566
- const response = {
1567
- $metadata: deserializeMetadata(output),
1568
- ...contents,
1569
- };
1570
- return response;
1571
- };
1572
- exports.de_DescribeAccountCommand = de_DescribeAccountCommand;
1573
- const de_DescribeAccountCommandError = async (output, context) => {
1574
- const parsedOutput = {
1575
- ...output,
1576
- body: await parseErrorBody(output.body, context),
1577
- };
1578
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1579
- switch (errorCode) {
1580
- case "AccessDeniedException":
1581
- case "com.amazonaws.workspaces#AccessDeniedException":
1582
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1583
- default:
1584
- const parsedBody = parsedOutput.body;
1585
- return throwDefaultError({
1586
- output,
1587
- parsedBody,
1588
- errorCode,
1589
- });
1590
- }
1591
- };
1592
- const de_DescribeAccountModificationsCommand = async (output, context) => {
1593
- if (output.statusCode >= 300) {
1594
- return de_DescribeAccountModificationsCommandError(output, context);
1595
- }
1596
- const data = await parseBody(output.body, context);
1597
- let contents = {};
1598
- contents = de_DescribeAccountModificationsResult(data, context);
1599
- const response = {
1600
- $metadata: deserializeMetadata(output),
1601
- ...contents,
1602
- };
1603
- return response;
1604
- };
1605
- exports.de_DescribeAccountModificationsCommand = de_DescribeAccountModificationsCommand;
1606
- const de_DescribeAccountModificationsCommandError = async (output, context) => {
1607
- const parsedOutput = {
1608
- ...output,
1609
- body: await parseErrorBody(output.body, context),
1610
- };
1611
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1612
- switch (errorCode) {
1613
- case "AccessDeniedException":
1614
- case "com.amazonaws.workspaces#AccessDeniedException":
1615
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1616
- default:
1617
- const parsedBody = parsedOutput.body;
1618
- return throwDefaultError({
1619
- output,
1620
- parsedBody,
1621
- errorCode,
1622
- });
1623
- }
1624
- };
1625
- const de_DescribeApplicationAssociationsCommand = async (output, context) => {
1626
- if (output.statusCode >= 300) {
1627
- return de_DescribeApplicationAssociationsCommandError(output, context);
1628
- }
1629
- const data = await parseBody(output.body, context);
1630
- let contents = {};
1631
- contents = de_DescribeApplicationAssociationsResult(data, context);
1632
- const response = {
1633
- $metadata: deserializeMetadata(output),
1634
- ...contents,
1635
- };
1636
- return response;
1637
- };
1638
- exports.de_DescribeApplicationAssociationsCommand = de_DescribeApplicationAssociationsCommand;
1639
- const de_DescribeApplicationAssociationsCommandError = async (output, context) => {
1640
- const parsedOutput = {
1641
- ...output,
1642
- body: await parseErrorBody(output.body, context),
1643
- };
1644
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1645
- switch (errorCode) {
1646
- case "AccessDeniedException":
1647
- case "com.amazonaws.workspaces#AccessDeniedException":
1648
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1649
- case "InvalidParameterValuesException":
1650
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1651
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1652
- case "OperationNotSupportedException":
1653
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1654
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1655
- case "ResourceNotFoundException":
1656
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1657
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1658
- default:
1659
- const parsedBody = parsedOutput.body;
1660
- return throwDefaultError({
1661
- output,
1662
- parsedBody,
1663
- errorCode,
1664
- });
1665
- }
1666
- };
1667
- const de_DescribeApplicationsCommand = async (output, context) => {
1668
- if (output.statusCode >= 300) {
1669
- return de_DescribeApplicationsCommandError(output, context);
1670
- }
1671
- const data = await parseBody(output.body, context);
1672
- let contents = {};
1673
- contents = de_DescribeApplicationsResult(data, context);
1674
- const response = {
1675
- $metadata: deserializeMetadata(output),
1676
- ...contents,
1677
- };
1678
- return response;
1679
- };
1680
- exports.de_DescribeApplicationsCommand = de_DescribeApplicationsCommand;
1681
- const de_DescribeApplicationsCommandError = async (output, context) => {
1682
- const parsedOutput = {
1683
- ...output,
1684
- body: await parseErrorBody(output.body, context),
1685
- };
1686
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1687
- switch (errorCode) {
1688
- case "AccessDeniedException":
1689
- case "com.amazonaws.workspaces#AccessDeniedException":
1690
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1691
- case "InvalidParameterValuesException":
1692
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1693
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1694
- case "OperationNotSupportedException":
1695
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1696
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1697
- case "ResourceNotFoundException":
1698
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1699
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1700
- default:
1701
- const parsedBody = parsedOutput.body;
1702
- return throwDefaultError({
1703
- output,
1704
- parsedBody,
1705
- errorCode,
1706
- });
1707
- }
1708
- };
1709
- const de_DescribeBundleAssociationsCommand = async (output, context) => {
1710
- if (output.statusCode >= 300) {
1711
- return de_DescribeBundleAssociationsCommandError(output, context);
1712
- }
1713
- const data = await parseBody(output.body, context);
1714
- let contents = {};
1715
- contents = de_DescribeBundleAssociationsResult(data, context);
1716
- const response = {
1717
- $metadata: deserializeMetadata(output),
1718
- ...contents,
1719
- };
1720
- return response;
1721
- };
1722
- exports.de_DescribeBundleAssociationsCommand = de_DescribeBundleAssociationsCommand;
1723
- const de_DescribeBundleAssociationsCommandError = async (output, context) => {
1724
- const parsedOutput = {
1725
- ...output,
1726
- body: await parseErrorBody(output.body, context),
1727
- };
1728
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1729
- switch (errorCode) {
1730
- case "AccessDeniedException":
1731
- case "com.amazonaws.workspaces#AccessDeniedException":
1732
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1733
- case "InvalidParameterValuesException":
1734
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1735
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1736
- case "OperationNotSupportedException":
1737
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1738
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1739
- case "ResourceNotFoundException":
1740
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1741
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1742
- default:
1743
- const parsedBody = parsedOutput.body;
1744
- return throwDefaultError({
1745
- output,
1746
- parsedBody,
1747
- errorCode,
1748
- });
1749
- }
1750
- };
1751
- const de_DescribeClientBrandingCommand = async (output, context) => {
1752
- if (output.statusCode >= 300) {
1753
- return de_DescribeClientBrandingCommandError(output, context);
1754
- }
1755
- const data = await parseBody(output.body, context);
1756
- let contents = {};
1757
- contents = (0, smithy_client_1._json)(data);
1758
- const response = {
1759
- $metadata: deserializeMetadata(output),
1760
- ...contents,
1761
- };
1762
- return response;
1763
- };
1764
- exports.de_DescribeClientBrandingCommand = de_DescribeClientBrandingCommand;
1765
- const de_DescribeClientBrandingCommandError = async (output, context) => {
1766
- const parsedOutput = {
1767
- ...output,
1768
- body: await parseErrorBody(output.body, context),
1769
- };
1770
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1771
- switch (errorCode) {
1772
- case "AccessDeniedException":
1773
- case "com.amazonaws.workspaces#AccessDeniedException":
1774
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1775
- case "InvalidParameterValuesException":
1776
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1777
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1778
- case "ResourceNotFoundException":
1779
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1780
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1781
- default:
1782
- const parsedBody = parsedOutput.body;
1783
- return throwDefaultError({
1784
- output,
1785
- parsedBody,
1786
- errorCode,
1787
- });
1788
- }
1789
- };
1790
- const de_DescribeClientPropertiesCommand = async (output, context) => {
1791
- if (output.statusCode >= 300) {
1792
- return de_DescribeClientPropertiesCommandError(output, context);
1793
- }
1794
- const data = await parseBody(output.body, context);
1795
- let contents = {};
1796
- contents = (0, smithy_client_1._json)(data);
1797
- const response = {
1798
- $metadata: deserializeMetadata(output),
1799
- ...contents,
1800
- };
1801
- return response;
1802
- };
1803
- exports.de_DescribeClientPropertiesCommand = de_DescribeClientPropertiesCommand;
1804
- const de_DescribeClientPropertiesCommandError = async (output, context) => {
1805
- const parsedOutput = {
1806
- ...output,
1807
- body: await parseErrorBody(output.body, context),
1808
- };
1809
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1810
- switch (errorCode) {
1811
- case "AccessDeniedException":
1812
- case "com.amazonaws.workspaces#AccessDeniedException":
1813
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1814
- case "InvalidParameterValuesException":
1815
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1816
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1817
- case "ResourceNotFoundException":
1818
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1819
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1820
- default:
1821
- const parsedBody = parsedOutput.body;
1822
- return throwDefaultError({
1823
- output,
1824
- parsedBody,
1825
- errorCode,
1826
- });
1827
- }
1828
- };
1829
- const de_DescribeConnectClientAddInsCommand = async (output, context) => {
1830
- if (output.statusCode >= 300) {
1831
- return de_DescribeConnectClientAddInsCommandError(output, context);
1832
- }
1833
- const data = await parseBody(output.body, context);
1834
- let contents = {};
1835
- contents = (0, smithy_client_1._json)(data);
1836
- const response = {
1837
- $metadata: deserializeMetadata(output),
1838
- ...contents,
1839
- };
1840
- return response;
1841
- };
1842
- exports.de_DescribeConnectClientAddInsCommand = de_DescribeConnectClientAddInsCommand;
1843
- const de_DescribeConnectClientAddInsCommandError = async (output, context) => {
1844
- const parsedOutput = {
1845
- ...output,
1846
- body: await parseErrorBody(output.body, context),
1847
- };
1848
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1849
- switch (errorCode) {
1850
- case "AccessDeniedException":
1851
- case "com.amazonaws.workspaces#AccessDeniedException":
1852
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1853
- case "InvalidParameterValuesException":
1854
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1855
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1856
- case "ResourceNotFoundException":
1857
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1858
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1859
- default:
1860
- const parsedBody = parsedOutput.body;
1861
- return throwDefaultError({
1862
- output,
1863
- parsedBody,
1864
- errorCode,
1865
- });
1866
- }
1867
- };
1868
- const de_DescribeConnectionAliasesCommand = async (output, context) => {
1869
- if (output.statusCode >= 300) {
1870
- return de_DescribeConnectionAliasesCommandError(output, context);
1871
- }
1872
- const data = await parseBody(output.body, context);
1873
- let contents = {};
1874
- contents = (0, smithy_client_1._json)(data);
1875
- const response = {
1876
- $metadata: deserializeMetadata(output),
1877
- ...contents,
1878
- };
1879
- return response;
1880
- };
1881
- exports.de_DescribeConnectionAliasesCommand = de_DescribeConnectionAliasesCommand;
1882
- const de_DescribeConnectionAliasesCommandError = async (output, context) => {
1883
- const parsedOutput = {
1884
- ...output,
1885
- body: await parseErrorBody(output.body, context),
1886
- };
1887
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1888
- switch (errorCode) {
1889
- case "AccessDeniedException":
1890
- case "com.amazonaws.workspaces#AccessDeniedException":
1891
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1892
- case "InvalidParameterValuesException":
1893
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1894
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1895
- case "OperationNotSupportedException":
1896
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1897
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1898
- default:
1899
- const parsedBody = parsedOutput.body;
1900
- return throwDefaultError({
1901
- output,
1902
- parsedBody,
1903
- errorCode,
1904
- });
1905
- }
1906
- };
1907
- const de_DescribeConnectionAliasPermissionsCommand = async (output, context) => {
1908
- if (output.statusCode >= 300) {
1909
- return de_DescribeConnectionAliasPermissionsCommandError(output, context);
1910
- }
1911
- const data = await parseBody(output.body, context);
1912
- let contents = {};
1913
- contents = (0, smithy_client_1._json)(data);
1914
- const response = {
1915
- $metadata: deserializeMetadata(output),
1916
- ...contents,
1917
- };
1918
- return response;
1919
- };
1920
- exports.de_DescribeConnectionAliasPermissionsCommand = de_DescribeConnectionAliasPermissionsCommand;
1921
- const de_DescribeConnectionAliasPermissionsCommandError = async (output, context) => {
1922
- const parsedOutput = {
1923
- ...output,
1924
- body: await parseErrorBody(output.body, context),
1925
- };
1926
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1927
- switch (errorCode) {
1928
- case "AccessDeniedException":
1929
- case "com.amazonaws.workspaces#AccessDeniedException":
1930
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1931
- case "InvalidParameterValuesException":
1932
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1933
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1934
- case "OperationNotSupportedException":
1935
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1936
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1937
- case "ResourceNotFoundException":
1938
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1939
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1940
- default:
1941
- const parsedBody = parsedOutput.body;
1942
- return throwDefaultError({
1943
- output,
1944
- parsedBody,
1945
- errorCode,
1946
- });
1947
- }
1948
- };
1949
- const de_DescribeImageAssociationsCommand = async (output, context) => {
1950
- if (output.statusCode >= 300) {
1951
- return de_DescribeImageAssociationsCommandError(output, context);
1952
- }
1953
- const data = await parseBody(output.body, context);
1954
- let contents = {};
1955
- contents = de_DescribeImageAssociationsResult(data, context);
1956
- const response = {
1957
- $metadata: deserializeMetadata(output),
1958
- ...contents,
1959
- };
1960
- return response;
1961
- };
1962
- exports.de_DescribeImageAssociationsCommand = de_DescribeImageAssociationsCommand;
1963
- const de_DescribeImageAssociationsCommandError = async (output, context) => {
1964
- const parsedOutput = {
1965
- ...output,
1966
- body: await parseErrorBody(output.body, context),
1967
- };
1968
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1969
- switch (errorCode) {
1970
- case "AccessDeniedException":
1971
- case "com.amazonaws.workspaces#AccessDeniedException":
1972
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
1973
- case "InvalidParameterValuesException":
1974
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
1975
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
1976
- case "OperationNotSupportedException":
1977
- case "com.amazonaws.workspaces#OperationNotSupportedException":
1978
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
1979
- case "ResourceNotFoundException":
1980
- case "com.amazonaws.workspaces#ResourceNotFoundException":
1981
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
1982
- default:
1983
- const parsedBody = parsedOutput.body;
1984
- return throwDefaultError({
1985
- output,
1986
- parsedBody,
1987
- errorCode,
1988
- });
1989
- }
1990
- };
1991
- const de_DescribeIpGroupsCommand = async (output, context) => {
1992
- if (output.statusCode >= 300) {
1993
- return de_DescribeIpGroupsCommandError(output, context);
1994
- }
1995
- const data = await parseBody(output.body, context);
1996
- let contents = {};
1997
- contents = (0, smithy_client_1._json)(data);
1998
- const response = {
1999
- $metadata: deserializeMetadata(output),
2000
- ...contents,
2001
- };
2002
- return response;
2003
- };
2004
- exports.de_DescribeIpGroupsCommand = de_DescribeIpGroupsCommand;
2005
- const de_DescribeIpGroupsCommandError = async (output, context) => {
2006
- const parsedOutput = {
2007
- ...output,
2008
- body: await parseErrorBody(output.body, context),
2009
- };
2010
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2011
- switch (errorCode) {
2012
- case "AccessDeniedException":
2013
- case "com.amazonaws.workspaces#AccessDeniedException":
2014
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2015
- case "InvalidParameterValuesException":
2016
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2017
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2018
- default:
2019
- const parsedBody = parsedOutput.body;
2020
- return throwDefaultError({
2021
- output,
2022
- parsedBody,
2023
- errorCode,
2024
- });
2025
- }
2026
- };
2027
- const de_DescribeTagsCommand = async (output, context) => {
2028
- if (output.statusCode >= 300) {
2029
- return de_DescribeTagsCommandError(output, context);
2030
- }
2031
- const data = await parseBody(output.body, context);
2032
- let contents = {};
2033
- contents = (0, smithy_client_1._json)(data);
2034
- const response = {
2035
- $metadata: deserializeMetadata(output),
2036
- ...contents,
2037
- };
2038
- return response;
2039
- };
2040
- exports.de_DescribeTagsCommand = de_DescribeTagsCommand;
2041
- const de_DescribeTagsCommandError = async (output, context) => {
2042
- const parsedOutput = {
2043
- ...output,
2044
- body: await parseErrorBody(output.body, context),
2045
- };
2046
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2047
- switch (errorCode) {
2048
- case "ResourceNotFoundException":
2049
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2050
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2051
- default:
2052
- const parsedBody = parsedOutput.body;
2053
- return throwDefaultError({
2054
- output,
2055
- parsedBody,
2056
- errorCode,
2057
- });
2058
- }
2059
- };
2060
- const de_DescribeWorkspaceAssociationsCommand = async (output, context) => {
2061
- if (output.statusCode >= 300) {
2062
- return de_DescribeWorkspaceAssociationsCommandError(output, context);
2063
- }
2064
- const data = await parseBody(output.body, context);
2065
- let contents = {};
2066
- contents = de_DescribeWorkspaceAssociationsResult(data, context);
2067
- const response = {
2068
- $metadata: deserializeMetadata(output),
2069
- ...contents,
2070
- };
2071
- return response;
2072
- };
2073
- exports.de_DescribeWorkspaceAssociationsCommand = de_DescribeWorkspaceAssociationsCommand;
2074
- const de_DescribeWorkspaceAssociationsCommandError = async (output, context) => {
2075
- const parsedOutput = {
2076
- ...output,
2077
- body: await parseErrorBody(output.body, context),
2078
- };
2079
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2080
- switch (errorCode) {
2081
- case "AccessDeniedException":
2082
- case "com.amazonaws.workspaces#AccessDeniedException":
2083
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2084
- case "InvalidParameterValuesException":
2085
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2086
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2087
- case "OperationNotSupportedException":
2088
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2089
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2090
- case "ResourceNotFoundException":
2091
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2092
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2093
- default:
2094
- const parsedBody = parsedOutput.body;
2095
- return throwDefaultError({
2096
- output,
2097
- parsedBody,
2098
- errorCode,
2099
- });
2100
- }
2101
- };
2102
- const de_DescribeWorkspaceBundlesCommand = async (output, context) => {
2103
- if (output.statusCode >= 300) {
2104
- return de_DescribeWorkspaceBundlesCommandError(output, context);
2105
- }
2106
- const data = await parseBody(output.body, context);
2107
- let contents = {};
2108
- contents = de_DescribeWorkspaceBundlesResult(data, context);
2109
- const response = {
2110
- $metadata: deserializeMetadata(output),
2111
- ...contents,
2112
- };
2113
- return response;
2114
- };
2115
- exports.de_DescribeWorkspaceBundlesCommand = de_DescribeWorkspaceBundlesCommand;
2116
- const de_DescribeWorkspaceBundlesCommandError = async (output, context) => {
2117
- const parsedOutput = {
2118
- ...output,
2119
- body: await parseErrorBody(output.body, context),
2120
- };
2121
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2122
- switch (errorCode) {
2123
- case "InvalidParameterValuesException":
2124
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2125
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2126
- default:
2127
- const parsedBody = parsedOutput.body;
2128
- return throwDefaultError({
2129
- output,
2130
- parsedBody,
2131
- errorCode,
2132
- });
2133
- }
2134
- };
2135
- const de_DescribeWorkspaceDirectoriesCommand = async (output, context) => {
2136
- if (output.statusCode >= 300) {
2137
- return de_DescribeWorkspaceDirectoriesCommandError(output, context);
2138
- }
2139
- const data = await parseBody(output.body, context);
2140
- let contents = {};
2141
- contents = (0, smithy_client_1._json)(data);
2142
- const response = {
2143
- $metadata: deserializeMetadata(output),
2144
- ...contents,
2145
- };
2146
- return response;
2147
- };
2148
- exports.de_DescribeWorkspaceDirectoriesCommand = de_DescribeWorkspaceDirectoriesCommand;
2149
- const de_DescribeWorkspaceDirectoriesCommandError = async (output, context) => {
2150
- const parsedOutput = {
2151
- ...output,
2152
- body: await parseErrorBody(output.body, context),
2153
- };
2154
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2155
- switch (errorCode) {
2156
- case "InvalidParameterValuesException":
2157
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2158
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2159
- default:
2160
- const parsedBody = parsedOutput.body;
2161
- return throwDefaultError({
2162
- output,
2163
- parsedBody,
2164
- errorCode,
2165
- });
2166
- }
2167
- };
2168
- const de_DescribeWorkspaceImagePermissionsCommand = async (output, context) => {
2169
- if (output.statusCode >= 300) {
2170
- return de_DescribeWorkspaceImagePermissionsCommandError(output, context);
2171
- }
2172
- const data = await parseBody(output.body, context);
2173
- let contents = {};
2174
- contents = (0, smithy_client_1._json)(data);
2175
- const response = {
2176
- $metadata: deserializeMetadata(output),
2177
- ...contents,
2178
- };
2179
- return response;
2180
- };
2181
- exports.de_DescribeWorkspaceImagePermissionsCommand = de_DescribeWorkspaceImagePermissionsCommand;
2182
- const de_DescribeWorkspaceImagePermissionsCommandError = async (output, context) => {
2183
- const parsedOutput = {
2184
- ...output,
2185
- body: await parseErrorBody(output.body, context),
2186
- };
2187
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2188
- switch (errorCode) {
2189
- case "AccessDeniedException":
2190
- case "com.amazonaws.workspaces#AccessDeniedException":
2191
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2192
- case "InvalidParameterValuesException":
2193
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2194
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2195
- case "ResourceNotFoundException":
2196
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2197
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2198
- default:
2199
- const parsedBody = parsedOutput.body;
2200
- return throwDefaultError({
2201
- output,
2202
- parsedBody,
2203
- errorCode,
2204
- });
2205
- }
2206
- };
2207
- const de_DescribeWorkspaceImagesCommand = async (output, context) => {
2208
- if (output.statusCode >= 300) {
2209
- return de_DescribeWorkspaceImagesCommandError(output, context);
2210
- }
2211
- const data = await parseBody(output.body, context);
2212
- let contents = {};
2213
- contents = de_DescribeWorkspaceImagesResult(data, context);
2214
- const response = {
2215
- $metadata: deserializeMetadata(output),
2216
- ...contents,
2217
- };
2218
- return response;
2219
- };
2220
- exports.de_DescribeWorkspaceImagesCommand = de_DescribeWorkspaceImagesCommand;
2221
- const de_DescribeWorkspaceImagesCommandError = async (output, context) => {
2222
- const parsedOutput = {
2223
- ...output,
2224
- body: await parseErrorBody(output.body, context),
2225
- };
2226
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2227
- switch (errorCode) {
2228
- case "AccessDeniedException":
2229
- case "com.amazonaws.workspaces#AccessDeniedException":
2230
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2231
- default:
2232
- const parsedBody = parsedOutput.body;
2233
- return throwDefaultError({
2234
- output,
2235
- parsedBody,
2236
- errorCode,
2237
- });
2238
- }
2239
- };
2240
- const de_DescribeWorkspacesCommand = async (output, context) => {
2241
- if (output.statusCode >= 300) {
2242
- return de_DescribeWorkspacesCommandError(output, context);
2243
- }
2244
- const data = await parseBody(output.body, context);
2245
- let contents = {};
2246
- contents = de_DescribeWorkspacesResult(data, context);
2247
- const response = {
2248
- $metadata: deserializeMetadata(output),
2249
- ...contents,
2250
- };
2251
- return response;
2252
- };
2253
- exports.de_DescribeWorkspacesCommand = de_DescribeWorkspacesCommand;
2254
- const de_DescribeWorkspacesCommandError = async (output, context) => {
2255
- const parsedOutput = {
2256
- ...output,
2257
- body: await parseErrorBody(output.body, context),
2258
- };
2259
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2260
- switch (errorCode) {
2261
- case "InvalidParameterValuesException":
2262
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2263
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2264
- case "ResourceUnavailableException":
2265
- case "com.amazonaws.workspaces#ResourceUnavailableException":
2266
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
2267
- default:
2268
- const parsedBody = parsedOutput.body;
2269
- return throwDefaultError({
2270
- output,
2271
- parsedBody,
2272
- errorCode,
2273
- });
2274
- }
2275
- };
2276
- const de_DescribeWorkspacesConnectionStatusCommand = async (output, context) => {
2277
- if (output.statusCode >= 300) {
2278
- return de_DescribeWorkspacesConnectionStatusCommandError(output, context);
2279
- }
2280
- const data = await parseBody(output.body, context);
2281
- let contents = {};
2282
- contents = de_DescribeWorkspacesConnectionStatusResult(data, context);
2283
- const response = {
2284
- $metadata: deserializeMetadata(output),
2285
- ...contents,
2286
- };
2287
- return response;
2288
- };
2289
- exports.de_DescribeWorkspacesConnectionStatusCommand = de_DescribeWorkspacesConnectionStatusCommand;
2290
- const de_DescribeWorkspacesConnectionStatusCommandError = async (output, context) => {
2291
- const parsedOutput = {
2292
- ...output,
2293
- body: await parseErrorBody(output.body, context),
2294
- };
2295
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2296
- switch (errorCode) {
2297
- case "InvalidParameterValuesException":
2298
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2299
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2300
- default:
2301
- const parsedBody = parsedOutput.body;
2302
- return throwDefaultError({
2303
- output,
2304
- parsedBody,
2305
- errorCode,
2306
- });
2307
- }
2308
- };
2309
- const de_DescribeWorkspaceSnapshotsCommand = async (output, context) => {
2310
- if (output.statusCode >= 300) {
2311
- return de_DescribeWorkspaceSnapshotsCommandError(output, context);
2312
- }
2313
- const data = await parseBody(output.body, context);
2314
- let contents = {};
2315
- contents = de_DescribeWorkspaceSnapshotsResult(data, context);
2316
- const response = {
2317
- $metadata: deserializeMetadata(output),
2318
- ...contents,
2319
- };
2320
- return response;
2321
- };
2322
- exports.de_DescribeWorkspaceSnapshotsCommand = de_DescribeWorkspaceSnapshotsCommand;
2323
- const de_DescribeWorkspaceSnapshotsCommandError = async (output, context) => {
2324
- const parsedOutput = {
2325
- ...output,
2326
- body: await parseErrorBody(output.body, context),
2327
- };
2328
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2329
- switch (errorCode) {
2330
- case "AccessDeniedException":
2331
- case "com.amazonaws.workspaces#AccessDeniedException":
2332
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2333
- case "InvalidParameterValuesException":
2334
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2335
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2336
- case "ResourceNotFoundException":
2337
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2338
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2339
- default:
2340
- const parsedBody = parsedOutput.body;
2341
- return throwDefaultError({
2342
- output,
2343
- parsedBody,
2344
- errorCode,
2345
- });
2346
- }
2347
- };
2348
- const de_DisassociateConnectionAliasCommand = async (output, context) => {
2349
- if (output.statusCode >= 300) {
2350
- return de_DisassociateConnectionAliasCommandError(output, context);
2351
- }
2352
- const data = await parseBody(output.body, context);
2353
- let contents = {};
2354
- contents = (0, smithy_client_1._json)(data);
2355
- const response = {
2356
- $metadata: deserializeMetadata(output),
2357
- ...contents,
2358
- };
2359
- return response;
2360
- };
2361
- exports.de_DisassociateConnectionAliasCommand = de_DisassociateConnectionAliasCommand;
2362
- const de_DisassociateConnectionAliasCommandError = async (output, context) => {
2363
- const parsedOutput = {
2364
- ...output,
2365
- body: await parseErrorBody(output.body, context),
2366
- };
2367
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2368
- switch (errorCode) {
2369
- case "AccessDeniedException":
2370
- case "com.amazonaws.workspaces#AccessDeniedException":
2371
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2372
- case "InvalidParameterValuesException":
2373
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2374
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2375
- case "InvalidResourceStateException":
2376
- case "com.amazonaws.workspaces#InvalidResourceStateException":
2377
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
2378
- case "OperationNotSupportedException":
2379
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2380
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2381
- case "ResourceNotFoundException":
2382
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2383
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2384
- default:
2385
- const parsedBody = parsedOutput.body;
2386
- return throwDefaultError({
2387
- output,
2388
- parsedBody,
2389
- errorCode,
2390
- });
2391
- }
2392
- };
2393
- const de_DisassociateIpGroupsCommand = async (output, context) => {
2394
- if (output.statusCode >= 300) {
2395
- return de_DisassociateIpGroupsCommandError(output, context);
2396
- }
2397
- const data = await parseBody(output.body, context);
2398
- let contents = {};
2399
- contents = (0, smithy_client_1._json)(data);
2400
- const response = {
2401
- $metadata: deserializeMetadata(output),
2402
- ...contents,
2403
- };
2404
- return response;
2405
- };
2406
- exports.de_DisassociateIpGroupsCommand = de_DisassociateIpGroupsCommand;
2407
- const de_DisassociateIpGroupsCommandError = async (output, context) => {
2408
- const parsedOutput = {
2409
- ...output,
2410
- body: await parseErrorBody(output.body, context),
2411
- };
2412
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2413
- switch (errorCode) {
2414
- case "AccessDeniedException":
2415
- case "com.amazonaws.workspaces#AccessDeniedException":
2416
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2417
- case "InvalidParameterValuesException":
2418
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2419
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2420
- case "InvalidResourceStateException":
2421
- case "com.amazonaws.workspaces#InvalidResourceStateException":
2422
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
2423
- case "ResourceNotFoundException":
2424
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2425
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2426
- default:
2427
- const parsedBody = parsedOutput.body;
2428
- return throwDefaultError({
2429
- output,
2430
- parsedBody,
2431
- errorCode,
2432
- });
2433
- }
2434
- };
2435
- const de_DisassociateWorkspaceApplicationCommand = async (output, context) => {
2436
- if (output.statusCode >= 300) {
2437
- return de_DisassociateWorkspaceApplicationCommandError(output, context);
2438
- }
2439
- const data = await parseBody(output.body, context);
2440
- let contents = {};
2441
- contents = de_DisassociateWorkspaceApplicationResult(data, context);
2442
- const response = {
2443
- $metadata: deserializeMetadata(output),
2444
- ...contents,
2445
- };
2446
- return response;
2447
- };
2448
- exports.de_DisassociateWorkspaceApplicationCommand = de_DisassociateWorkspaceApplicationCommand;
2449
- const de_DisassociateWorkspaceApplicationCommandError = async (output, context) => {
2450
- const parsedOutput = {
2451
- ...output,
2452
- body: await parseErrorBody(output.body, context),
2453
- };
2454
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2455
- switch (errorCode) {
2456
- case "AccessDeniedException":
2457
- case "com.amazonaws.workspaces#AccessDeniedException":
2458
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2459
- case "InvalidParameterValuesException":
2460
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2461
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2462
- case "OperationNotSupportedException":
2463
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2464
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2465
- case "ResourceInUseException":
2466
- case "com.amazonaws.workspaces#ResourceInUseException":
2467
- throw await de_ResourceInUseExceptionRes(parsedOutput, context);
2468
- case "ResourceNotFoundException":
2469
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2470
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2471
- default:
2472
- const parsedBody = parsedOutput.body;
2473
- return throwDefaultError({
2474
- output,
2475
- parsedBody,
2476
- errorCode,
2477
- });
2478
- }
2479
- };
2480
- const de_ImportClientBrandingCommand = async (output, context) => {
2481
- if (output.statusCode >= 300) {
2482
- return de_ImportClientBrandingCommandError(output, context);
2483
- }
2484
- const data = await parseBody(output.body, context);
2485
- let contents = {};
2486
- contents = (0, smithy_client_1._json)(data);
2487
- const response = {
2488
- $metadata: deserializeMetadata(output),
2489
- ...contents,
2490
- };
2491
- return response;
2492
- };
2493
- exports.de_ImportClientBrandingCommand = de_ImportClientBrandingCommand;
2494
- const de_ImportClientBrandingCommandError = async (output, context) => {
2495
- const parsedOutput = {
2496
- ...output,
2497
- body: await parseErrorBody(output.body, context),
2498
- };
2499
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2500
- switch (errorCode) {
2501
- case "AccessDeniedException":
2502
- case "com.amazonaws.workspaces#AccessDeniedException":
2503
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2504
- case "InvalidParameterValuesException":
2505
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2506
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2507
- case "ResourceLimitExceededException":
2508
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
2509
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
2510
- case "ResourceNotFoundException":
2511
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2512
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2513
- default:
2514
- const parsedBody = parsedOutput.body;
2515
- return throwDefaultError({
2516
- output,
2517
- parsedBody,
2518
- errorCode,
2519
- });
2520
- }
2521
- };
2522
- const de_ImportWorkspaceImageCommand = async (output, context) => {
2523
- if (output.statusCode >= 300) {
2524
- return de_ImportWorkspaceImageCommandError(output, context);
2525
- }
2526
- const data = await parseBody(output.body, context);
2527
- let contents = {};
2528
- contents = (0, smithy_client_1._json)(data);
2529
- const response = {
2530
- $metadata: deserializeMetadata(output),
2531
- ...contents,
2532
- };
2533
- return response;
2534
- };
2535
- exports.de_ImportWorkspaceImageCommand = de_ImportWorkspaceImageCommand;
2536
- const de_ImportWorkspaceImageCommandError = async (output, context) => {
2537
- const parsedOutput = {
2538
- ...output,
2539
- body: await parseErrorBody(output.body, context),
2540
- };
2541
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2542
- switch (errorCode) {
2543
- case "AccessDeniedException":
2544
- case "com.amazonaws.workspaces#AccessDeniedException":
2545
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2546
- case "InvalidParameterValuesException":
2547
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2548
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2549
- case "OperationNotSupportedException":
2550
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2551
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2552
- case "ResourceAlreadyExistsException":
2553
- case "com.amazonaws.workspaces#ResourceAlreadyExistsException":
2554
- throw await de_ResourceAlreadyExistsExceptionRes(parsedOutput, context);
2555
- case "ResourceLimitExceededException":
2556
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
2557
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
2558
- case "ResourceNotFoundException":
2559
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2560
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2561
- default:
2562
- const parsedBody = parsedOutput.body;
2563
- return throwDefaultError({
2564
- output,
2565
- parsedBody,
2566
- errorCode,
2567
- });
2568
- }
2569
- };
2570
- const de_ListAvailableManagementCidrRangesCommand = async (output, context) => {
2571
- if (output.statusCode >= 300) {
2572
- return de_ListAvailableManagementCidrRangesCommandError(output, context);
2573
- }
2574
- const data = await parseBody(output.body, context);
2575
- let contents = {};
2576
- contents = (0, smithy_client_1._json)(data);
2577
- const response = {
2578
- $metadata: deserializeMetadata(output),
2579
- ...contents,
2580
- };
2581
- return response;
2582
- };
2583
- exports.de_ListAvailableManagementCidrRangesCommand = de_ListAvailableManagementCidrRangesCommand;
2584
- const de_ListAvailableManagementCidrRangesCommandError = async (output, context) => {
2585
- const parsedOutput = {
2586
- ...output,
2587
- body: await parseErrorBody(output.body, context),
2588
- };
2589
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2590
- switch (errorCode) {
2591
- case "AccessDeniedException":
2592
- case "com.amazonaws.workspaces#AccessDeniedException":
2593
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2594
- case "InvalidParameterValuesException":
2595
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2596
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2597
- default:
2598
- const parsedBody = parsedOutput.body;
2599
- return throwDefaultError({
2600
- output,
2601
- parsedBody,
2602
- errorCode,
2603
- });
2604
- }
2605
- };
2606
- const de_MigrateWorkspaceCommand = async (output, context) => {
2607
- if (output.statusCode >= 300) {
2608
- return de_MigrateWorkspaceCommandError(output, context);
2609
- }
2610
- const data = await parseBody(output.body, context);
2611
- let contents = {};
2612
- contents = (0, smithy_client_1._json)(data);
2613
- const response = {
2614
- $metadata: deserializeMetadata(output),
2615
- ...contents,
2616
- };
2617
- return response;
2618
- };
2619
- exports.de_MigrateWorkspaceCommand = de_MigrateWorkspaceCommand;
2620
- const de_MigrateWorkspaceCommandError = async (output, context) => {
2621
- const parsedOutput = {
2622
- ...output,
2623
- body: await parseErrorBody(output.body, context),
2624
- };
2625
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2626
- switch (errorCode) {
2627
- case "AccessDeniedException":
2628
- case "com.amazonaws.workspaces#AccessDeniedException":
2629
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2630
- case "InvalidParameterValuesException":
2631
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2632
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2633
- case "OperationInProgressException":
2634
- case "com.amazonaws.workspaces#OperationInProgressException":
2635
- throw await de_OperationInProgressExceptionRes(parsedOutput, context);
2636
- case "OperationNotSupportedException":
2637
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2638
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2639
- case "ResourceNotFoundException":
2640
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2641
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2642
- case "ResourceUnavailableException":
2643
- case "com.amazonaws.workspaces#ResourceUnavailableException":
2644
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
2645
- default:
2646
- const parsedBody = parsedOutput.body;
2647
- return throwDefaultError({
2648
- output,
2649
- parsedBody,
2650
- errorCode,
2651
- });
2652
- }
2653
- };
2654
- const de_ModifyAccountCommand = async (output, context) => {
2655
- if (output.statusCode >= 300) {
2656
- return de_ModifyAccountCommandError(output, context);
2657
- }
2658
- const data = await parseBody(output.body, context);
2659
- let contents = {};
2660
- contents = (0, smithy_client_1._json)(data);
2661
- const response = {
2662
- $metadata: deserializeMetadata(output),
2663
- ...contents,
2664
- };
2665
- return response;
2666
- };
2667
- exports.de_ModifyAccountCommand = de_ModifyAccountCommand;
2668
- const de_ModifyAccountCommandError = async (output, context) => {
2669
- const parsedOutput = {
2670
- ...output,
2671
- body: await parseErrorBody(output.body, context),
2672
- };
2673
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2674
- switch (errorCode) {
2675
- case "AccessDeniedException":
2676
- case "com.amazonaws.workspaces#AccessDeniedException":
2677
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2678
- case "InvalidParameterValuesException":
2679
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2680
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2681
- case "InvalidResourceStateException":
2682
- case "com.amazonaws.workspaces#InvalidResourceStateException":
2683
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
2684
- case "ResourceNotFoundException":
2685
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2686
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2687
- case "ResourceUnavailableException":
2688
- case "com.amazonaws.workspaces#ResourceUnavailableException":
2689
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
2690
- default:
2691
- const parsedBody = parsedOutput.body;
2692
- return throwDefaultError({
2693
- output,
2694
- parsedBody,
2695
- errorCode,
2696
- });
2697
- }
2698
- };
2699
- const de_ModifyCertificateBasedAuthPropertiesCommand = async (output, context) => {
2700
- if (output.statusCode >= 300) {
2701
- return de_ModifyCertificateBasedAuthPropertiesCommandError(output, context);
2702
- }
2703
- const data = await parseBody(output.body, context);
2704
- let contents = {};
2705
- contents = (0, smithy_client_1._json)(data);
2706
- const response = {
2707
- $metadata: deserializeMetadata(output),
2708
- ...contents,
2709
- };
2710
- return response;
2711
- };
2712
- exports.de_ModifyCertificateBasedAuthPropertiesCommand = de_ModifyCertificateBasedAuthPropertiesCommand;
2713
- const de_ModifyCertificateBasedAuthPropertiesCommandError = async (output, context) => {
2714
- const parsedOutput = {
2715
- ...output,
2716
- body: await parseErrorBody(output.body, context),
2717
- };
2718
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2719
- switch (errorCode) {
2720
- case "AccessDeniedException":
2721
- case "com.amazonaws.workspaces#AccessDeniedException":
2722
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2723
- case "InvalidParameterValuesException":
2724
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2725
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2726
- case "OperationNotSupportedException":
2727
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2728
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2729
- case "ResourceNotFoundException":
2730
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2731
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2732
- default:
2733
- const parsedBody = parsedOutput.body;
2734
- return throwDefaultError({
2735
- output,
2736
- parsedBody,
2737
- errorCode,
2738
- });
2739
- }
2740
- };
2741
- const de_ModifyClientPropertiesCommand = async (output, context) => {
2742
- if (output.statusCode >= 300) {
2743
- return de_ModifyClientPropertiesCommandError(output, context);
2744
- }
2745
- const data = await parseBody(output.body, context);
2746
- let contents = {};
2747
- contents = (0, smithy_client_1._json)(data);
2748
- const response = {
2749
- $metadata: deserializeMetadata(output),
2750
- ...contents,
2751
- };
2752
- return response;
2753
- };
2754
- exports.de_ModifyClientPropertiesCommand = de_ModifyClientPropertiesCommand;
2755
- const de_ModifyClientPropertiesCommandError = async (output, context) => {
2756
- const parsedOutput = {
2757
- ...output,
2758
- body: await parseErrorBody(output.body, context),
2759
- };
2760
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2761
- switch (errorCode) {
2762
- case "AccessDeniedException":
2763
- case "com.amazonaws.workspaces#AccessDeniedException":
2764
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2765
- case "InvalidParameterValuesException":
2766
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2767
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2768
- case "ResourceNotFoundException":
2769
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2770
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2771
- default:
2772
- const parsedBody = parsedOutput.body;
2773
- return throwDefaultError({
2774
- output,
2775
- parsedBody,
2776
- errorCode,
2777
- });
2778
- }
2779
- };
2780
- const de_ModifySamlPropertiesCommand = async (output, context) => {
2781
- if (output.statusCode >= 300) {
2782
- return de_ModifySamlPropertiesCommandError(output, context);
2783
- }
2784
- const data = await parseBody(output.body, context);
2785
- let contents = {};
2786
- contents = (0, smithy_client_1._json)(data);
2787
- const response = {
2788
- $metadata: deserializeMetadata(output),
2789
- ...contents,
2790
- };
2791
- return response;
2792
- };
2793
- exports.de_ModifySamlPropertiesCommand = de_ModifySamlPropertiesCommand;
2794
- const de_ModifySamlPropertiesCommandError = async (output, context) => {
2795
- const parsedOutput = {
2796
- ...output,
2797
- body: await parseErrorBody(output.body, context),
2798
- };
2799
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2800
- switch (errorCode) {
2801
- case "AccessDeniedException":
2802
- case "com.amazonaws.workspaces#AccessDeniedException":
2803
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2804
- case "InvalidParameterValuesException":
2805
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2806
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2807
- case "OperationNotSupportedException":
2808
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2809
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2810
- case "ResourceNotFoundException":
2811
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2812
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2813
- default:
2814
- const parsedBody = parsedOutput.body;
2815
- return throwDefaultError({
2816
- output,
2817
- parsedBody,
2818
- errorCode,
2819
- });
2820
- }
2821
- };
2822
- const de_ModifySelfservicePermissionsCommand = async (output, context) => {
2823
- if (output.statusCode >= 300) {
2824
- return de_ModifySelfservicePermissionsCommandError(output, context);
2825
- }
2826
- const data = await parseBody(output.body, context);
2827
- let contents = {};
2828
- contents = (0, smithy_client_1._json)(data);
2829
- const response = {
2830
- $metadata: deserializeMetadata(output),
2831
- ...contents,
2832
- };
2833
- return response;
2834
- };
2835
- exports.de_ModifySelfservicePermissionsCommand = de_ModifySelfservicePermissionsCommand;
2836
- const de_ModifySelfservicePermissionsCommandError = async (output, context) => {
2837
- const parsedOutput = {
2838
- ...output,
2839
- body: await parseErrorBody(output.body, context),
2840
- };
2841
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2842
- switch (errorCode) {
2843
- case "AccessDeniedException":
2844
- case "com.amazonaws.workspaces#AccessDeniedException":
2845
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2846
- case "InvalidParameterValuesException":
2847
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2848
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2849
- case "ResourceNotFoundException":
2850
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2851
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2852
- default:
2853
- const parsedBody = parsedOutput.body;
2854
- return throwDefaultError({
2855
- output,
2856
- parsedBody,
2857
- errorCode,
2858
- });
2859
- }
2860
- };
2861
- const de_ModifyWorkspaceAccessPropertiesCommand = async (output, context) => {
2862
- if (output.statusCode >= 300) {
2863
- return de_ModifyWorkspaceAccessPropertiesCommandError(output, context);
2864
- }
2865
- const data = await parseBody(output.body, context);
2866
- let contents = {};
2867
- contents = (0, smithy_client_1._json)(data);
2868
- const response = {
2869
- $metadata: deserializeMetadata(output),
2870
- ...contents,
2871
- };
2872
- return response;
2873
- };
2874
- exports.de_ModifyWorkspaceAccessPropertiesCommand = de_ModifyWorkspaceAccessPropertiesCommand;
2875
- const de_ModifyWorkspaceAccessPropertiesCommandError = async (output, context) => {
2876
- const parsedOutput = {
2877
- ...output,
2878
- body: await parseErrorBody(output.body, context),
2879
- };
2880
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2881
- switch (errorCode) {
2882
- case "AccessDeniedException":
2883
- case "com.amazonaws.workspaces#AccessDeniedException":
2884
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2885
- case "ResourceNotFoundException":
2886
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2887
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2888
- default:
2889
- const parsedBody = parsedOutput.body;
2890
- return throwDefaultError({
2891
- output,
2892
- parsedBody,
2893
- errorCode,
2894
- });
2895
- }
2896
- };
2897
- const de_ModifyWorkspaceCreationPropertiesCommand = async (output, context) => {
2898
- if (output.statusCode >= 300) {
2899
- return de_ModifyWorkspaceCreationPropertiesCommandError(output, context);
2900
- }
2901
- const data = await parseBody(output.body, context);
2902
- let contents = {};
2903
- contents = (0, smithy_client_1._json)(data);
2904
- const response = {
2905
- $metadata: deserializeMetadata(output),
2906
- ...contents,
2907
- };
2908
- return response;
2909
- };
2910
- exports.de_ModifyWorkspaceCreationPropertiesCommand = de_ModifyWorkspaceCreationPropertiesCommand;
2911
- const de_ModifyWorkspaceCreationPropertiesCommandError = async (output, context) => {
2912
- const parsedOutput = {
2913
- ...output,
2914
- body: await parseErrorBody(output.body, context),
2915
- };
2916
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2917
- switch (errorCode) {
2918
- case "AccessDeniedException":
2919
- case "com.amazonaws.workspaces#AccessDeniedException":
2920
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2921
- case "InvalidParameterValuesException":
2922
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2923
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2924
- case "OperationNotSupportedException":
2925
- case "com.amazonaws.workspaces#OperationNotSupportedException":
2926
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
2927
- case "ResourceNotFoundException":
2928
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2929
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2930
- default:
2931
- const parsedBody = parsedOutput.body;
2932
- return throwDefaultError({
2933
- output,
2934
- parsedBody,
2935
- errorCode,
2936
- });
2937
- }
2938
- };
2939
- const de_ModifyWorkspacePropertiesCommand = async (output, context) => {
2940
- if (output.statusCode >= 300) {
2941
- return de_ModifyWorkspacePropertiesCommandError(output, context);
2942
- }
2943
- const data = await parseBody(output.body, context);
2944
- let contents = {};
2945
- contents = (0, smithy_client_1._json)(data);
2946
- const response = {
2947
- $metadata: deserializeMetadata(output),
2948
- ...contents,
2949
- };
2950
- return response;
2951
- };
2952
- exports.de_ModifyWorkspacePropertiesCommand = de_ModifyWorkspacePropertiesCommand;
2953
- const de_ModifyWorkspacePropertiesCommandError = async (output, context) => {
2954
- const parsedOutput = {
2955
- ...output,
2956
- body: await parseErrorBody(output.body, context),
2957
- };
2958
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2959
- switch (errorCode) {
2960
- case "AccessDeniedException":
2961
- case "com.amazonaws.workspaces#AccessDeniedException":
2962
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
2963
- case "InvalidParameterValuesException":
2964
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
2965
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
2966
- case "InvalidResourceStateException":
2967
- case "com.amazonaws.workspaces#InvalidResourceStateException":
2968
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
2969
- case "OperationInProgressException":
2970
- case "com.amazonaws.workspaces#OperationInProgressException":
2971
- throw await de_OperationInProgressExceptionRes(parsedOutput, context);
2972
- case "ResourceNotFoundException":
2973
- case "com.amazonaws.workspaces#ResourceNotFoundException":
2974
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
2975
- case "ResourceUnavailableException":
2976
- case "com.amazonaws.workspaces#ResourceUnavailableException":
2977
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
2978
- case "UnsupportedWorkspaceConfigurationException":
2979
- case "com.amazonaws.workspaces#UnsupportedWorkspaceConfigurationException":
2980
- throw await de_UnsupportedWorkspaceConfigurationExceptionRes(parsedOutput, context);
2981
- default:
2982
- const parsedBody = parsedOutput.body;
2983
- return throwDefaultError({
2984
- output,
2985
- parsedBody,
2986
- errorCode,
2987
- });
2988
- }
2989
- };
2990
- const de_ModifyWorkspaceStateCommand = async (output, context) => {
2991
- if (output.statusCode >= 300) {
2992
- return de_ModifyWorkspaceStateCommandError(output, context);
2993
- }
2994
- const data = await parseBody(output.body, context);
2995
- let contents = {};
2996
- contents = (0, smithy_client_1._json)(data);
2997
- const response = {
2998
- $metadata: deserializeMetadata(output),
2999
- ...contents,
3000
- };
3001
- return response;
3002
- };
3003
- exports.de_ModifyWorkspaceStateCommand = de_ModifyWorkspaceStateCommand;
3004
- const de_ModifyWorkspaceStateCommandError = async (output, context) => {
3005
- const parsedOutput = {
3006
- ...output,
3007
- body: await parseErrorBody(output.body, context),
3008
- };
3009
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3010
- switch (errorCode) {
3011
- case "InvalidParameterValuesException":
3012
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3013
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3014
- case "InvalidResourceStateException":
3015
- case "com.amazonaws.workspaces#InvalidResourceStateException":
3016
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
3017
- case "OperationNotSupportedException":
3018
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3019
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3020
- case "ResourceNotFoundException":
3021
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3022
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3023
- default:
3024
- const parsedBody = parsedOutput.body;
3025
- return throwDefaultError({
3026
- output,
3027
- parsedBody,
3028
- errorCode,
3029
- });
3030
- }
3031
- };
3032
- const de_RebootWorkspacesCommand = async (output, context) => {
3033
- if (output.statusCode >= 300) {
3034
- return de_RebootWorkspacesCommandError(output, context);
3035
- }
3036
- const data = await parseBody(output.body, context);
3037
- let contents = {};
3038
- contents = (0, smithy_client_1._json)(data);
3039
- const response = {
3040
- $metadata: deserializeMetadata(output),
3041
- ...contents,
3042
- };
3043
- return response;
3044
- };
3045
- exports.de_RebootWorkspacesCommand = de_RebootWorkspacesCommand;
3046
- const de_RebootWorkspacesCommandError = async (output, context) => {
3047
- const parsedOutput = {
3048
- ...output,
3049
- body: await parseErrorBody(output.body, context),
3050
- };
3051
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3052
- switch (errorCode) {
3053
- case "OperationNotSupportedException":
3054
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3055
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3056
- default:
3057
- const parsedBody = parsedOutput.body;
3058
- return throwDefaultError({
3059
- output,
3060
- parsedBody,
3061
- errorCode,
3062
- });
3063
- }
3064
- };
3065
- const de_RebuildWorkspacesCommand = async (output, context) => {
3066
- if (output.statusCode >= 300) {
3067
- return de_RebuildWorkspacesCommandError(output, context);
3068
- }
3069
- const data = await parseBody(output.body, context);
3070
- let contents = {};
3071
- contents = (0, smithy_client_1._json)(data);
3072
- const response = {
3073
- $metadata: deserializeMetadata(output),
3074
- ...contents,
3075
- };
3076
- return response;
3077
- };
3078
- exports.de_RebuildWorkspacesCommand = de_RebuildWorkspacesCommand;
3079
- const de_RebuildWorkspacesCommandError = async (output, context) => {
3080
- const parsedOutput = {
3081
- ...output,
3082
- body: await parseErrorBody(output.body, context),
3083
- };
3084
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3085
- switch (errorCode) {
3086
- case "OperationNotSupportedException":
3087
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3088
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3089
- default:
3090
- const parsedBody = parsedOutput.body;
3091
- return throwDefaultError({
3092
- output,
3093
- parsedBody,
3094
- errorCode,
3095
- });
3096
- }
3097
- };
3098
- const de_RegisterWorkspaceDirectoryCommand = async (output, context) => {
3099
- if (output.statusCode >= 300) {
3100
- return de_RegisterWorkspaceDirectoryCommandError(output, context);
3101
- }
3102
- const data = await parseBody(output.body, context);
3103
- let contents = {};
3104
- contents = (0, smithy_client_1._json)(data);
3105
- const response = {
3106
- $metadata: deserializeMetadata(output),
3107
- ...contents,
3108
- };
3109
- return response;
3110
- };
3111
- exports.de_RegisterWorkspaceDirectoryCommand = de_RegisterWorkspaceDirectoryCommand;
3112
- const de_RegisterWorkspaceDirectoryCommandError = async (output, context) => {
3113
- const parsedOutput = {
3114
- ...output,
3115
- body: await parseErrorBody(output.body, context),
3116
- };
3117
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3118
- switch (errorCode) {
3119
- case "AccessDeniedException":
3120
- case "com.amazonaws.workspaces#AccessDeniedException":
3121
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3122
- case "InvalidParameterValuesException":
3123
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3124
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3125
- case "InvalidResourceStateException":
3126
- case "com.amazonaws.workspaces#InvalidResourceStateException":
3127
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
3128
- case "OperationNotSupportedException":
3129
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3130
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3131
- case "ResourceLimitExceededException":
3132
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
3133
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
3134
- case "ResourceNotFoundException":
3135
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3136
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3137
- case "UnsupportedNetworkConfigurationException":
3138
- case "com.amazonaws.workspaces#UnsupportedNetworkConfigurationException":
3139
- throw await de_UnsupportedNetworkConfigurationExceptionRes(parsedOutput, context);
3140
- case "WorkspacesDefaultRoleNotFoundException":
3141
- case "com.amazonaws.workspaces#WorkspacesDefaultRoleNotFoundException":
3142
- throw await de_WorkspacesDefaultRoleNotFoundExceptionRes(parsedOutput, context);
3143
- default:
3144
- const parsedBody = parsedOutput.body;
3145
- return throwDefaultError({
3146
- output,
3147
- parsedBody,
3148
- errorCode,
3149
- });
3150
- }
3151
- };
3152
- const de_RestoreWorkspaceCommand = async (output, context) => {
3153
- if (output.statusCode >= 300) {
3154
- return de_RestoreWorkspaceCommandError(output, context);
3155
- }
3156
- const data = await parseBody(output.body, context);
3157
- let contents = {};
3158
- contents = (0, smithy_client_1._json)(data);
3159
- const response = {
3160
- $metadata: deserializeMetadata(output),
3161
- ...contents,
3162
- };
3163
- return response;
3164
- };
3165
- exports.de_RestoreWorkspaceCommand = de_RestoreWorkspaceCommand;
3166
- const de_RestoreWorkspaceCommandError = async (output, context) => {
3167
- const parsedOutput = {
3168
- ...output,
3169
- body: await parseErrorBody(output.body, context),
3170
- };
3171
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3172
- switch (errorCode) {
3173
- case "AccessDeniedException":
3174
- case "com.amazonaws.workspaces#AccessDeniedException":
3175
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3176
- case "InvalidParameterValuesException":
3177
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3178
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3179
- case "OperationNotSupportedException":
3180
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3181
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3182
- case "ResourceNotFoundException":
3183
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3184
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3185
- default:
3186
- const parsedBody = parsedOutput.body;
3187
- return throwDefaultError({
3188
- output,
3189
- parsedBody,
3190
- errorCode,
3191
- });
3192
- }
3193
- };
3194
- const de_RevokeIpRulesCommand = async (output, context) => {
3195
- if (output.statusCode >= 300) {
3196
- return de_RevokeIpRulesCommandError(output, context);
3197
- }
3198
- const data = await parseBody(output.body, context);
3199
- let contents = {};
3200
- contents = (0, smithy_client_1._json)(data);
3201
- const response = {
3202
- $metadata: deserializeMetadata(output),
3203
- ...contents,
3204
- };
3205
- return response;
3206
- };
3207
- exports.de_RevokeIpRulesCommand = de_RevokeIpRulesCommand;
3208
- const de_RevokeIpRulesCommandError = async (output, context) => {
3209
- const parsedOutput = {
3210
- ...output,
3211
- body: await parseErrorBody(output.body, context),
3212
- };
3213
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3214
- switch (errorCode) {
3215
- case "AccessDeniedException":
3216
- case "com.amazonaws.workspaces#AccessDeniedException":
3217
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3218
- case "InvalidParameterValuesException":
3219
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3220
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3221
- case "InvalidResourceStateException":
3222
- case "com.amazonaws.workspaces#InvalidResourceStateException":
3223
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
3224
- case "ResourceNotFoundException":
3225
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3226
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3227
- default:
3228
- const parsedBody = parsedOutput.body;
3229
- return throwDefaultError({
3230
- output,
3231
- parsedBody,
3232
- errorCode,
3233
- });
3234
- }
3235
- };
3236
- const de_StartWorkspacesCommand = async (output, context) => {
3237
- if (output.statusCode >= 300) {
3238
- return de_StartWorkspacesCommandError(output, context);
3239
- }
3240
- const data = await parseBody(output.body, context);
3241
- let contents = {};
3242
- contents = (0, smithy_client_1._json)(data);
3243
- const response = {
3244
- $metadata: deserializeMetadata(output),
3245
- ...contents,
3246
- };
3247
- return response;
3248
- };
3249
- exports.de_StartWorkspacesCommand = de_StartWorkspacesCommand;
3250
- const de_StartWorkspacesCommandError = async (output, context) => {
3251
- const parsedOutput = {
3252
- ...output,
3253
- body: await parseErrorBody(output.body, context),
3254
- };
3255
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3256
- const parsedBody = parsedOutput.body;
3257
- return throwDefaultError({
3258
- output,
3259
- parsedBody,
3260
- errorCode,
3261
- });
3262
- };
3263
- const de_StopWorkspacesCommand = async (output, context) => {
3264
- if (output.statusCode >= 300) {
3265
- return de_StopWorkspacesCommandError(output, context);
3266
- }
3267
- const data = await parseBody(output.body, context);
3268
- let contents = {};
3269
- contents = (0, smithy_client_1._json)(data);
3270
- const response = {
3271
- $metadata: deserializeMetadata(output),
3272
- ...contents,
3273
- };
3274
- return response;
3275
- };
3276
- exports.de_StopWorkspacesCommand = de_StopWorkspacesCommand;
3277
- const de_StopWorkspacesCommandError = async (output, context) => {
3278
- const parsedOutput = {
3279
- ...output,
3280
- body: await parseErrorBody(output.body, context),
3281
- };
3282
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3283
- const parsedBody = parsedOutput.body;
3284
- return throwDefaultError({
3285
- output,
3286
- parsedBody,
3287
- errorCode,
3288
- });
3289
- };
3290
- const de_TerminateWorkspacesCommand = async (output, context) => {
3291
- if (output.statusCode >= 300) {
3292
- return de_TerminateWorkspacesCommandError(output, context);
3293
- }
3294
- const data = await parseBody(output.body, context);
3295
- let contents = {};
3296
- contents = (0, smithy_client_1._json)(data);
3297
- const response = {
3298
- $metadata: deserializeMetadata(output),
3299
- ...contents,
3300
- };
3301
- return response;
3302
- };
3303
- exports.de_TerminateWorkspacesCommand = de_TerminateWorkspacesCommand;
3304
- const de_TerminateWorkspacesCommandError = async (output, context) => {
3305
- const parsedOutput = {
3306
- ...output,
3307
- body: await parseErrorBody(output.body, context),
3308
- };
3309
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3310
- const parsedBody = parsedOutput.body;
3311
- return throwDefaultError({
3312
- output,
3313
- parsedBody,
3314
- errorCode,
3315
- });
3316
- };
3317
- const de_UpdateConnectClientAddInCommand = async (output, context) => {
3318
- if (output.statusCode >= 300) {
3319
- return de_UpdateConnectClientAddInCommandError(output, context);
3320
- }
3321
- const data = await parseBody(output.body, context);
3322
- let contents = {};
3323
- contents = (0, smithy_client_1._json)(data);
3324
- const response = {
3325
- $metadata: deserializeMetadata(output),
3326
- ...contents,
3327
- };
3328
- return response;
3329
- };
3330
- exports.de_UpdateConnectClientAddInCommand = de_UpdateConnectClientAddInCommand;
3331
- const de_UpdateConnectClientAddInCommandError = async (output, context) => {
3332
- const parsedOutput = {
3333
- ...output,
3334
- body: await parseErrorBody(output.body, context),
3335
- };
3336
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3337
- switch (errorCode) {
3338
- case "AccessDeniedException":
3339
- case "com.amazonaws.workspaces#AccessDeniedException":
3340
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3341
- case "InvalidParameterValuesException":
3342
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3343
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3344
- case "ResourceNotFoundException":
3345
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3346
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3347
- default:
3348
- const parsedBody = parsedOutput.body;
3349
- return throwDefaultError({
3350
- output,
3351
- parsedBody,
3352
- errorCode,
3353
- });
3354
- }
3355
- };
3356
- const de_UpdateConnectionAliasPermissionCommand = async (output, context) => {
3357
- if (output.statusCode >= 300) {
3358
- return de_UpdateConnectionAliasPermissionCommandError(output, context);
3359
- }
3360
- const data = await parseBody(output.body, context);
3361
- let contents = {};
3362
- contents = (0, smithy_client_1._json)(data);
3363
- const response = {
3364
- $metadata: deserializeMetadata(output),
3365
- ...contents,
3366
- };
3367
- return response;
3368
- };
3369
- exports.de_UpdateConnectionAliasPermissionCommand = de_UpdateConnectionAliasPermissionCommand;
3370
- const de_UpdateConnectionAliasPermissionCommandError = async (output, context) => {
3371
- const parsedOutput = {
3372
- ...output,
3373
- body: await parseErrorBody(output.body, context),
3374
- };
3375
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3376
- switch (errorCode) {
3377
- case "AccessDeniedException":
3378
- case "com.amazonaws.workspaces#AccessDeniedException":
3379
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3380
- case "InvalidParameterValuesException":
3381
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3382
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3383
- case "InvalidResourceStateException":
3384
- case "com.amazonaws.workspaces#InvalidResourceStateException":
3385
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
3386
- case "OperationNotSupportedException":
3387
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3388
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3389
- case "ResourceAssociatedException":
3390
- case "com.amazonaws.workspaces#ResourceAssociatedException":
3391
- throw await de_ResourceAssociatedExceptionRes(parsedOutput, context);
3392
- case "ResourceLimitExceededException":
3393
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
3394
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
3395
- case "ResourceNotFoundException":
3396
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3397
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3398
- default:
3399
- const parsedBody = parsedOutput.body;
3400
- return throwDefaultError({
3401
- output,
3402
- parsedBody,
3403
- errorCode,
3404
- });
3405
- }
3406
- };
3407
- const de_UpdateRulesOfIpGroupCommand = async (output, context) => {
3408
- if (output.statusCode >= 300) {
3409
- return de_UpdateRulesOfIpGroupCommandError(output, context);
3410
- }
3411
- const data = await parseBody(output.body, context);
3412
- let contents = {};
3413
- contents = (0, smithy_client_1._json)(data);
3414
- const response = {
3415
- $metadata: deserializeMetadata(output),
3416
- ...contents,
3417
- };
3418
- return response;
3419
- };
3420
- exports.de_UpdateRulesOfIpGroupCommand = de_UpdateRulesOfIpGroupCommand;
3421
- const de_UpdateRulesOfIpGroupCommandError = async (output, context) => {
3422
- const parsedOutput = {
3423
- ...output,
3424
- body: await parseErrorBody(output.body, context),
3425
- };
3426
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3427
- switch (errorCode) {
3428
- case "AccessDeniedException":
3429
- case "com.amazonaws.workspaces#AccessDeniedException":
3430
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3431
- case "InvalidParameterValuesException":
3432
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3433
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3434
- case "InvalidResourceStateException":
3435
- case "com.amazonaws.workspaces#InvalidResourceStateException":
3436
- throw await de_InvalidResourceStateExceptionRes(parsedOutput, context);
3437
- case "ResourceLimitExceededException":
3438
- case "com.amazonaws.workspaces#ResourceLimitExceededException":
3439
- throw await de_ResourceLimitExceededExceptionRes(parsedOutput, context);
3440
- case "ResourceNotFoundException":
3441
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3442
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3443
- default:
3444
- const parsedBody = parsedOutput.body;
3445
- return throwDefaultError({
3446
- output,
3447
- parsedBody,
3448
- errorCode,
3449
- });
3450
- }
3451
- };
3452
- const de_UpdateWorkspaceBundleCommand = async (output, context) => {
3453
- if (output.statusCode >= 300) {
3454
- return de_UpdateWorkspaceBundleCommandError(output, context);
3455
- }
3456
- const data = await parseBody(output.body, context);
3457
- let contents = {};
3458
- contents = (0, smithy_client_1._json)(data);
3459
- const response = {
3460
- $metadata: deserializeMetadata(output),
3461
- ...contents,
3462
- };
3463
- return response;
3464
- };
3465
- exports.de_UpdateWorkspaceBundleCommand = de_UpdateWorkspaceBundleCommand;
3466
- const de_UpdateWorkspaceBundleCommandError = async (output, context) => {
3467
- const parsedOutput = {
3468
- ...output,
3469
- body: await parseErrorBody(output.body, context),
3470
- };
3471
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3472
- switch (errorCode) {
3473
- case "AccessDeniedException":
3474
- case "com.amazonaws.workspaces#AccessDeniedException":
3475
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3476
- case "InvalidParameterValuesException":
3477
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3478
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3479
- case "OperationNotSupportedException":
3480
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3481
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3482
- case "ResourceNotFoundException":
3483
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3484
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3485
- case "ResourceUnavailableException":
3486
- case "com.amazonaws.workspaces#ResourceUnavailableException":
3487
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
3488
- default:
3489
- const parsedBody = parsedOutput.body;
3490
- return throwDefaultError({
3491
- output,
3492
- parsedBody,
3493
- errorCode,
3494
- });
3495
- }
3496
- };
3497
- const de_UpdateWorkspaceImagePermissionCommand = async (output, context) => {
3498
- if (output.statusCode >= 300) {
3499
- return de_UpdateWorkspaceImagePermissionCommandError(output, context);
3500
- }
3501
- const data = await parseBody(output.body, context);
3502
- let contents = {};
3503
- contents = (0, smithy_client_1._json)(data);
3504
- const response = {
3505
- $metadata: deserializeMetadata(output),
3506
- ...contents,
3507
- };
3508
- return response;
3509
- };
3510
- exports.de_UpdateWorkspaceImagePermissionCommand = de_UpdateWorkspaceImagePermissionCommand;
3511
- const de_UpdateWorkspaceImagePermissionCommandError = async (output, context) => {
3512
- const parsedOutput = {
3513
- ...output,
3514
- body: await parseErrorBody(output.body, context),
3515
- };
3516
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3517
- switch (errorCode) {
3518
- case "AccessDeniedException":
3519
- case "com.amazonaws.workspaces#AccessDeniedException":
3520
- throw await de_AccessDeniedExceptionRes(parsedOutput, context);
3521
- case "InvalidParameterValuesException":
3522
- case "com.amazonaws.workspaces#InvalidParameterValuesException":
3523
- throw await de_InvalidParameterValuesExceptionRes(parsedOutput, context);
3524
- case "OperationNotSupportedException":
3525
- case "com.amazonaws.workspaces#OperationNotSupportedException":
3526
- throw await de_OperationNotSupportedExceptionRes(parsedOutput, context);
3527
- case "ResourceNotFoundException":
3528
- case "com.amazonaws.workspaces#ResourceNotFoundException":
3529
- throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
3530
- case "ResourceUnavailableException":
3531
- case "com.amazonaws.workspaces#ResourceUnavailableException":
3532
- throw await de_ResourceUnavailableExceptionRes(parsedOutput, context);
3533
- default:
3534
- const parsedBody = parsedOutput.body;
3535
- return throwDefaultError({
3536
- output,
3537
- parsedBody,
3538
- errorCode,
3539
- });
3540
- }
3541
- };
3542
- const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
3543
- const body = parsedOutput.body;
3544
- const deserialized = (0, smithy_client_1._json)(body);
3545
- const exception = new models_0_1.AccessDeniedException({
3546
- $metadata: deserializeMetadata(parsedOutput),
3547
- ...deserialized,
3548
- });
3549
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3550
- };
3551
- const de_ApplicationNotSupportedExceptionRes = async (parsedOutput, context) => {
3552
- const body = parsedOutput.body;
3553
- const deserialized = (0, smithy_client_1._json)(body);
3554
- const exception = new models_0_1.ApplicationNotSupportedException({
3555
- $metadata: deserializeMetadata(parsedOutput),
3556
- ...deserialized,
3557
- });
3558
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3559
- };
3560
- const de_ComputeNotCompatibleExceptionRes = async (parsedOutput, context) => {
3561
- const body = parsedOutput.body;
3562
- const deserialized = (0, smithy_client_1._json)(body);
3563
- const exception = new models_0_1.ComputeNotCompatibleException({
3564
- $metadata: deserializeMetadata(parsedOutput),
3565
- ...deserialized,
3566
- });
3567
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3568
- };
3569
- const de_IncompatibleApplicationsExceptionRes = async (parsedOutput, context) => {
3570
- const body = parsedOutput.body;
3571
- const deserialized = (0, smithy_client_1._json)(body);
3572
- const exception = new models_0_1.IncompatibleApplicationsException({
3573
- $metadata: deserializeMetadata(parsedOutput),
3574
- ...deserialized,
3575
- });
3576
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3577
- };
3578
- const de_InvalidParameterValuesExceptionRes = async (parsedOutput, context) => {
3579
- const body = parsedOutput.body;
3580
- const deserialized = (0, smithy_client_1._json)(body);
3581
- const exception = new models_0_1.InvalidParameterValuesException({
3582
- $metadata: deserializeMetadata(parsedOutput),
3583
- ...deserialized,
3584
- });
3585
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3586
- };
3587
- const de_InvalidResourceStateExceptionRes = async (parsedOutput, context) => {
3588
- const body = parsedOutput.body;
3589
- const deserialized = (0, smithy_client_1._json)(body);
3590
- const exception = new models_0_1.InvalidResourceStateException({
3591
- $metadata: deserializeMetadata(parsedOutput),
3592
- ...deserialized,
3593
- });
3594
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3595
- };
3596
- const de_OperatingSystemNotCompatibleExceptionRes = async (parsedOutput, context) => {
3597
- const body = parsedOutput.body;
3598
- const deserialized = (0, smithy_client_1._json)(body);
3599
- const exception = new models_0_1.OperatingSystemNotCompatibleException({
3600
- $metadata: deserializeMetadata(parsedOutput),
3601
- ...deserialized,
3602
- });
3603
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3604
- };
3605
- const de_OperationInProgressExceptionRes = async (parsedOutput, context) => {
3606
- const body = parsedOutput.body;
3607
- const deserialized = (0, smithy_client_1._json)(body);
3608
- const exception = new models_0_1.OperationInProgressException({
3609
- $metadata: deserializeMetadata(parsedOutput),
3610
- ...deserialized,
3611
- });
3612
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3613
- };
3614
- const de_OperationNotSupportedExceptionRes = async (parsedOutput, context) => {
3615
- const body = parsedOutput.body;
3616
- const deserialized = (0, smithy_client_1._json)(body);
3617
- const exception = new models_0_1.OperationNotSupportedException({
3618
- $metadata: deserializeMetadata(parsedOutput),
3619
- ...deserialized,
3620
- });
3621
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3622
- };
3623
- const de_ResourceAlreadyExistsExceptionRes = async (parsedOutput, context) => {
3624
- const body = parsedOutput.body;
3625
- const deserialized = (0, smithy_client_1._json)(body);
3626
- const exception = new models_0_1.ResourceAlreadyExistsException({
3627
- $metadata: deserializeMetadata(parsedOutput),
3628
- ...deserialized,
3629
- });
3630
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3631
- };
3632
- const de_ResourceAssociatedExceptionRes = async (parsedOutput, context) => {
3633
- const body = parsedOutput.body;
3634
- const deserialized = (0, smithy_client_1._json)(body);
3635
- const exception = new models_0_1.ResourceAssociatedException({
3636
- $metadata: deserializeMetadata(parsedOutput),
3637
- ...deserialized,
3638
- });
3639
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3640
- };
3641
- const de_ResourceCreationFailedExceptionRes = async (parsedOutput, context) => {
3642
- const body = parsedOutput.body;
3643
- const deserialized = (0, smithy_client_1._json)(body);
3644
- const exception = new models_0_1.ResourceCreationFailedException({
3645
- $metadata: deserializeMetadata(parsedOutput),
3646
- ...deserialized,
3647
- });
3648
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3649
- };
3650
- const de_ResourceInUseExceptionRes = async (parsedOutput, context) => {
3651
- const body = parsedOutput.body;
3652
- const deserialized = (0, smithy_client_1._json)(body);
3653
- const exception = new models_0_1.ResourceInUseException({
3654
- $metadata: deserializeMetadata(parsedOutput),
3655
- ...deserialized,
3656
- });
3657
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3658
- };
3659
- const de_ResourceLimitExceededExceptionRes = async (parsedOutput, context) => {
3660
- const body = parsedOutput.body;
3661
- const deserialized = (0, smithy_client_1._json)(body);
3662
- const exception = new models_0_1.ResourceLimitExceededException({
3663
- $metadata: deserializeMetadata(parsedOutput),
3664
- ...deserialized,
3665
- });
3666
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3667
- };
3668
- const de_ResourceNotFoundExceptionRes = async (parsedOutput, context) => {
3669
- const body = parsedOutput.body;
3670
- const deserialized = (0, smithy_client_1._json)(body);
3671
- const exception = new models_0_1.ResourceNotFoundException({
3672
- $metadata: deserializeMetadata(parsedOutput),
3673
- ...deserialized,
3674
- });
3675
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3676
- };
3677
- const de_ResourceUnavailableExceptionRes = async (parsedOutput, context) => {
3678
- const body = parsedOutput.body;
3679
- const deserialized = (0, smithy_client_1._json)(body);
3680
- const exception = new models_0_1.ResourceUnavailableException({
3681
- $metadata: deserializeMetadata(parsedOutput),
3682
- ...deserialized,
3683
- });
3684
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3685
- };
3686
- const de_UnsupportedNetworkConfigurationExceptionRes = async (parsedOutput, context) => {
3687
- const body = parsedOutput.body;
3688
- const deserialized = (0, smithy_client_1._json)(body);
3689
- const exception = new models_0_1.UnsupportedNetworkConfigurationException({
3690
- $metadata: deserializeMetadata(parsedOutput),
3691
- ...deserialized,
3692
- });
3693
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3694
- };
3695
- const de_UnsupportedWorkspaceConfigurationExceptionRes = async (parsedOutput, context) => {
3696
- const body = parsedOutput.body;
3697
- const deserialized = (0, smithy_client_1._json)(body);
3698
- const exception = new models_0_1.UnsupportedWorkspaceConfigurationException({
3699
- $metadata: deserializeMetadata(parsedOutput),
3700
- ...deserialized,
3701
- });
3702
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3703
- };
3704
- const de_WorkspacesDefaultRoleNotFoundExceptionRes = async (parsedOutput, context) => {
3705
- const body = parsedOutput.body;
3706
- const deserialized = (0, smithy_client_1._json)(body);
3707
- const exception = new models_0_1.WorkspacesDefaultRoleNotFoundException({
3708
- $metadata: deserializeMetadata(parsedOutput),
3709
- ...deserialized,
3710
- });
3711
- return (0, smithy_client_1.decorateServiceException)(exception, body);
3712
- };
3713
- const se_DefaultImportClientBrandingAttributes = (input, context) => {
3714
- return (0, smithy_client_1.take)(input, {
3715
- ForgotPasswordLink: [],
3716
- LoginMessage: smithy_client_1._json,
3717
- Logo: context.base64Encoder,
3718
- SupportEmail: [],
3719
- SupportLink: [],
3720
- });
3721
- };
3722
- const se_ImportClientBrandingRequest = (input, context) => {
3723
- return (0, smithy_client_1.take)(input, {
3724
- DeviceTypeAndroid: (_) => se_DefaultImportClientBrandingAttributes(_, context),
3725
- DeviceTypeIos: (_) => se_IosImportClientBrandingAttributes(_, context),
3726
- DeviceTypeLinux: (_) => se_DefaultImportClientBrandingAttributes(_, context),
3727
- DeviceTypeOsx: (_) => se_DefaultImportClientBrandingAttributes(_, context),
3728
- DeviceTypeWeb: (_) => se_DefaultImportClientBrandingAttributes(_, context),
3729
- DeviceTypeWindows: (_) => se_DefaultImportClientBrandingAttributes(_, context),
3730
- ResourceId: [],
3731
- });
3732
- };
3733
- const se_IosImportClientBrandingAttributes = (input, context) => {
3734
- return (0, smithy_client_1.take)(input, {
3735
- ForgotPasswordLink: [],
3736
- LoginMessage: smithy_client_1._json,
3737
- Logo: context.base64Encoder,
3738
- Logo2x: context.base64Encoder,
3739
- Logo3x: context.base64Encoder,
3740
- SupportEmail: [],
3741
- SupportLink: [],
3742
- });
3743
- };
3744
- const de_AccountModification = (output, context) => {
3745
- return (0, smithy_client_1.take)(output, {
3746
- DedicatedTenancyManagementCidrRange: smithy_client_1.expectString,
3747
- DedicatedTenancySupport: smithy_client_1.expectString,
3748
- ErrorCode: smithy_client_1.expectString,
3749
- ErrorMessage: smithy_client_1.expectString,
3750
- ModificationState: smithy_client_1.expectString,
3751
- StartTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3752
- });
3753
- };
3754
- const de_AccountModificationList = (output, context) => {
3755
- const retVal = (output || [])
3756
- .filter((e) => e != null)
3757
- .map((entry) => {
3758
- return de_AccountModification(entry, context);
3759
- });
3760
- return retVal;
3761
- };
3762
- const de_ApplicationResourceAssociation = (output, context) => {
3763
- return (0, smithy_client_1.take)(output, {
3764
- ApplicationId: smithy_client_1.expectString,
3765
- AssociatedResourceId: smithy_client_1.expectString,
3766
- AssociatedResourceType: smithy_client_1.expectString,
3767
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3768
- LastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3769
- State: smithy_client_1.expectString,
3770
- StateReason: smithy_client_1._json,
3771
- });
3772
- };
3773
- const de_ApplicationResourceAssociationList = (output, context) => {
3774
- const retVal = (output || [])
3775
- .filter((e) => e != null)
3776
- .map((entry) => {
3777
- return de_ApplicationResourceAssociation(entry, context);
3778
- });
3779
- return retVal;
3780
- };
3781
- const de_AssociateWorkspaceApplicationResult = (output, context) => {
3782
- return (0, smithy_client_1.take)(output, {
3783
- Association: (_) => de_WorkspaceResourceAssociation(_, context),
3784
- });
3785
- };
3786
- const de_BundleList = (output, context) => {
3787
- const retVal = (output || [])
3788
- .filter((e) => e != null)
3789
- .map((entry) => {
3790
- return de_WorkspaceBundle(entry, context);
3791
- });
3792
- return retVal;
3793
- };
3794
- const de_BundleResourceAssociation = (output, context) => {
3795
- return (0, smithy_client_1.take)(output, {
3796
- AssociatedResourceId: smithy_client_1.expectString,
3797
- AssociatedResourceType: smithy_client_1.expectString,
3798
- BundleId: smithy_client_1.expectString,
3799
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3800
- LastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3801
- State: smithy_client_1.expectString,
3802
- StateReason: smithy_client_1._json,
3803
- });
3804
- };
3805
- const de_BundleResourceAssociationList = (output, context) => {
3806
- const retVal = (output || [])
3807
- .filter((e) => e != null)
3808
- .map((entry) => {
3809
- return de_BundleResourceAssociation(entry, context);
3810
- });
3811
- return retVal;
3812
- };
3813
- const de_CreateWorkspaceBundleResult = (output, context) => {
3814
- return (0, smithy_client_1.take)(output, {
3815
- WorkspaceBundle: (_) => de_WorkspaceBundle(_, context),
3816
- });
3817
- };
3818
- const de_CreateWorkspaceImageResult = (output, context) => {
3819
- return (0, smithy_client_1.take)(output, {
3820
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3821
- Description: smithy_client_1.expectString,
3822
- ImageId: smithy_client_1.expectString,
3823
- Name: smithy_client_1.expectString,
3824
- OperatingSystem: smithy_client_1._json,
3825
- OwnerAccountId: smithy_client_1.expectString,
3826
- RequiredTenancy: smithy_client_1.expectString,
3827
- State: smithy_client_1.expectString,
3828
- });
3829
- };
3830
- const de_CreateWorkspacesResult = (output, context) => {
3831
- return (0, smithy_client_1.take)(output, {
3832
- FailedRequests: smithy_client_1._json,
3833
- PendingRequests: (_) => de_WorkspaceList(_, context),
3834
- });
3835
- };
3836
- const de_DataReplicationSettings = (output, context) => {
3837
- return (0, smithy_client_1.take)(output, {
3838
- DataReplication: smithy_client_1.expectString,
3839
- RecoverySnapshotTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3840
- });
3841
- };
3842
- const de_DeployWorkspaceApplicationsResult = (output, context) => {
3843
- return (0, smithy_client_1.take)(output, {
3844
- Deployment: (_) => de_WorkSpaceApplicationDeployment(_, context),
3845
- });
3846
- };
3847
- const de_DescribeAccountModificationsResult = (output, context) => {
3848
- return (0, smithy_client_1.take)(output, {
3849
- AccountModifications: (_) => de_AccountModificationList(_, context),
3850
- NextToken: smithy_client_1.expectString,
3851
- });
3852
- };
3853
- const de_DescribeApplicationAssociationsResult = (output, context) => {
3854
- return (0, smithy_client_1.take)(output, {
3855
- Associations: (_) => de_ApplicationResourceAssociationList(_, context),
3856
- NextToken: smithy_client_1.expectString,
3857
- });
3858
- };
3859
- const de_DescribeApplicationsResult = (output, context) => {
3860
- return (0, smithy_client_1.take)(output, {
3861
- Applications: (_) => de_WorkSpaceApplicationList(_, context),
3862
- NextToken: smithy_client_1.expectString,
3863
- });
3864
- };
3865
- const de_DescribeBundleAssociationsResult = (output, context) => {
3866
- return (0, smithy_client_1.take)(output, {
3867
- Associations: (_) => de_BundleResourceAssociationList(_, context),
3868
- });
3869
- };
3870
- const de_DescribeImageAssociationsResult = (output, context) => {
3871
- return (0, smithy_client_1.take)(output, {
3872
- Associations: (_) => de_ImageResourceAssociationList(_, context),
3873
- });
3874
- };
3875
- const de_DescribeWorkspaceAssociationsResult = (output, context) => {
3876
- return (0, smithy_client_1.take)(output, {
3877
- Associations: (_) => de_WorkspaceResourceAssociationList(_, context),
3878
- });
3879
- };
3880
- const de_DescribeWorkspaceBundlesResult = (output, context) => {
3881
- return (0, smithy_client_1.take)(output, {
3882
- Bundles: (_) => de_BundleList(_, context),
3883
- NextToken: smithy_client_1.expectString,
3884
- });
3885
- };
3886
- const de_DescribeWorkspaceImagesResult = (output, context) => {
3887
- return (0, smithy_client_1.take)(output, {
3888
- Images: (_) => de_WorkspaceImageList(_, context),
3889
- NextToken: smithy_client_1.expectString,
3890
- });
3891
- };
3892
- const de_DescribeWorkspacesConnectionStatusResult = (output, context) => {
3893
- return (0, smithy_client_1.take)(output, {
3894
- NextToken: smithy_client_1.expectString,
3895
- WorkspacesConnectionStatus: (_) => de_WorkspaceConnectionStatusList(_, context),
3896
- });
3897
- };
3898
- const de_DescribeWorkspaceSnapshotsResult = (output, context) => {
3899
- return (0, smithy_client_1.take)(output, {
3900
- RebuildSnapshots: (_) => de_SnapshotList(_, context),
3901
- RestoreSnapshots: (_) => de_SnapshotList(_, context),
3902
- });
3903
- };
3904
- const de_DescribeWorkspacesResult = (output, context) => {
3905
- return (0, smithy_client_1.take)(output, {
3906
- NextToken: smithy_client_1.expectString,
3907
- Workspaces: (_) => de_WorkspaceList(_, context),
3908
- });
3909
- };
3910
- const de_DisassociateWorkspaceApplicationResult = (output, context) => {
3911
- return (0, smithy_client_1.take)(output, {
3912
- Association: (_) => de_WorkspaceResourceAssociation(_, context),
3913
- });
3914
- };
3915
- const de_ImageResourceAssociation = (output, context) => {
3916
- return (0, smithy_client_1.take)(output, {
3917
- AssociatedResourceId: smithy_client_1.expectString,
3918
- AssociatedResourceType: smithy_client_1.expectString,
3919
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3920
- ImageId: smithy_client_1.expectString,
3921
- LastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3922
- State: smithy_client_1.expectString,
3923
- StateReason: smithy_client_1._json,
3924
- });
3925
- };
3926
- const de_ImageResourceAssociationList = (output, context) => {
3927
- const retVal = (output || [])
3928
- .filter((e) => e != null)
3929
- .map((entry) => {
3930
- return de_ImageResourceAssociation(entry, context);
3931
- });
3932
- return retVal;
3933
- };
3934
- const de_Snapshot = (output, context) => {
3935
- return (0, smithy_client_1.take)(output, {
3936
- SnapshotTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3937
- });
3938
- };
3939
- const de_SnapshotList = (output, context) => {
3940
- const retVal = (output || [])
3941
- .filter((e) => e != null)
3942
- .map((entry) => {
3943
- return de_Snapshot(entry, context);
3944
- });
3945
- return retVal;
3946
- };
3947
- const de_StandbyWorkspacesProperties = (output, context) => {
3948
- return (0, smithy_client_1.take)(output, {
3949
- DataReplication: smithy_client_1.expectString,
3950
- RecoverySnapshotTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3951
- StandbyWorkspaceId: smithy_client_1.expectString,
3952
- });
3953
- };
3954
- const de_StandbyWorkspacesPropertiesList = (output, context) => {
3955
- const retVal = (output || [])
3956
- .filter((e) => e != null)
3957
- .map((entry) => {
3958
- return de_StandbyWorkspacesProperties(entry, context);
3959
- });
3960
- return retVal;
3961
- };
3962
- const de_Workspace = (output, context) => {
3963
- return (0, smithy_client_1.take)(output, {
3964
- BundleId: smithy_client_1.expectString,
3965
- ComputerName: smithy_client_1.expectString,
3966
- DataReplicationSettings: (_) => de_DataReplicationSettings(_, context),
3967
- DirectoryId: smithy_client_1.expectString,
3968
- ErrorCode: smithy_client_1.expectString,
3969
- ErrorMessage: smithy_client_1.expectString,
3970
- IpAddress: smithy_client_1.expectString,
3971
- ModificationStates: smithy_client_1._json,
3972
- RelatedWorkspaces: smithy_client_1._json,
3973
- RootVolumeEncryptionEnabled: smithy_client_1.expectBoolean,
3974
- StandbyWorkspacesProperties: (_) => de_StandbyWorkspacesPropertiesList(_, context),
3975
- State: smithy_client_1.expectString,
3976
- SubnetId: smithy_client_1.expectString,
3977
- UserName: smithy_client_1.expectString,
3978
- UserVolumeEncryptionEnabled: smithy_client_1.expectBoolean,
3979
- VolumeEncryptionKey: smithy_client_1.expectString,
3980
- WorkspaceId: smithy_client_1.expectString,
3981
- WorkspaceProperties: smithy_client_1._json,
3982
- });
3983
- };
3984
- const de_WorkSpaceApplication = (output, context) => {
3985
- return (0, smithy_client_1.take)(output, {
3986
- ApplicationId: smithy_client_1.expectString,
3987
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
3988
- Description: smithy_client_1.expectString,
3989
- LicenseType: smithy_client_1.expectString,
3990
- Name: smithy_client_1.expectString,
3991
- Owner: smithy_client_1.expectString,
3992
- State: smithy_client_1.expectString,
3993
- SupportedComputeTypeNames: smithy_client_1._json,
3994
- SupportedOperatingSystemNames: smithy_client_1._json,
3995
- });
3996
- };
3997
- const de_WorkSpaceApplicationDeployment = (output, context) => {
3998
- return (0, smithy_client_1.take)(output, {
3999
- Associations: (_) => de_WorkspaceResourceAssociationList(_, context),
4000
- });
4001
- };
4002
- const de_WorkSpaceApplicationList = (output, context) => {
4003
- const retVal = (output || [])
4004
- .filter((e) => e != null)
4005
- .map((entry) => {
4006
- return de_WorkSpaceApplication(entry, context);
4007
- });
4008
- return retVal;
4009
- };
4010
- const de_WorkspaceBundle = (output, context) => {
4011
- return (0, smithy_client_1.take)(output, {
4012
- BundleId: smithy_client_1.expectString,
4013
- BundleType: smithy_client_1.expectString,
4014
- ComputeType: smithy_client_1._json,
4015
- CreationTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4016
- Description: smithy_client_1.expectString,
4017
- ImageId: smithy_client_1.expectString,
4018
- LastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4019
- Name: smithy_client_1.expectString,
4020
- Owner: smithy_client_1.expectString,
4021
- RootStorage: smithy_client_1._json,
4022
- State: smithy_client_1.expectString,
4023
- UserStorage: smithy_client_1._json,
4024
- });
4025
- };
4026
- const de_WorkspaceConnectionStatus = (output, context) => {
4027
- return (0, smithy_client_1.take)(output, {
4028
- ConnectionState: smithy_client_1.expectString,
4029
- ConnectionStateCheckTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4030
- LastKnownUserConnectionTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4031
- WorkspaceId: smithy_client_1.expectString,
4032
- });
4033
- };
4034
- const de_WorkspaceConnectionStatusList = (output, context) => {
4035
- const retVal = (output || [])
4036
- .filter((e) => e != null)
4037
- .map((entry) => {
4038
- return de_WorkspaceConnectionStatus(entry, context);
4039
- });
4040
- return retVal;
4041
- };
4042
- const de_WorkspaceImage = (output, context) => {
4043
- return (0, smithy_client_1.take)(output, {
4044
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4045
- Description: smithy_client_1.expectString,
4046
- ErrorCode: smithy_client_1.expectString,
4047
- ErrorDetails: smithy_client_1._json,
4048
- ErrorMessage: smithy_client_1.expectString,
4049
- ImageId: smithy_client_1.expectString,
4050
- Name: smithy_client_1.expectString,
4051
- OperatingSystem: smithy_client_1._json,
4052
- OwnerAccountId: smithy_client_1.expectString,
4053
- RequiredTenancy: smithy_client_1.expectString,
4054
- State: smithy_client_1.expectString,
4055
- Updates: smithy_client_1._json,
4056
- });
4057
- };
4058
- const de_WorkspaceImageList = (output, context) => {
4059
- const retVal = (output || [])
4060
- .filter((e) => e != null)
4061
- .map((entry) => {
4062
- return de_WorkspaceImage(entry, context);
4063
- });
4064
- return retVal;
4065
- };
4066
- const de_WorkspaceList = (output, context) => {
4067
- const retVal = (output || [])
4068
- .filter((e) => e != null)
4069
- .map((entry) => {
4070
- return de_Workspace(entry, context);
4071
- });
4072
- return retVal;
4073
- };
4074
- const de_WorkspaceResourceAssociation = (output, context) => {
4075
- return (0, smithy_client_1.take)(output, {
4076
- AssociatedResourceId: smithy_client_1.expectString,
4077
- AssociatedResourceType: smithy_client_1.expectString,
4078
- Created: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4079
- LastUpdatedTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4080
- State: smithy_client_1.expectString,
4081
- StateReason: smithy_client_1._json,
4082
- WorkspaceId: smithy_client_1.expectString,
4083
- });
4084
- };
4085
- const de_WorkspaceResourceAssociationList = (output, context) => {
4086
- const retVal = (output || [])
4087
- .filter((e) => e != null)
4088
- .map((entry) => {
4089
- return de_WorkspaceResourceAssociation(entry, context);
4090
- });
4091
- return retVal;
4092
- };
4093
- const deserializeMetadata = (output) => ({
4094
- httpStatusCode: output.statusCode,
4095
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
4096
- extendedRequestId: output.headers["x-amz-id-2"],
4097
- cfId: output.headers["x-amz-cf-id"],
4098
- });
4099
- const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
4100
- const throwDefaultError = (0, smithy_client_1.withBaseException)(WorkSpacesServiceException_1.WorkSpacesServiceException);
4101
- const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
4102
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
4103
- const contents = {
4104
- protocol,
4105
- hostname,
4106
- port,
4107
- method: "POST",
4108
- path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
4109
- headers,
4110
- };
4111
- if (resolvedHostname !== undefined) {
4112
- contents.hostname = resolvedHostname;
4113
- }
4114
- if (body !== undefined) {
4115
- contents.body = body;
4116
- }
4117
- return new protocol_http_1.HttpRequest(contents);
4118
- };
4119
- function sharedHeaders(operation) {
4120
- return {
4121
- "content-type": "application/x-amz-json-1.1",
4122
- "x-amz-target": `WorkspacesService.${operation}`,
4123
- };
4124
- }
4125
- const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
4126
- if (encoded.length) {
4127
- return JSON.parse(encoded);
4128
- }
4129
- return {};
4130
- });
4131
- const parseErrorBody = async (errorBody, context) => {
4132
- const value = await parseBody(errorBody, context);
4133
- value.message = value.message ?? value.Message;
4134
- return value;
4135
- };
4136
- const loadRestJsonErrorCode = (output, data) => {
4137
- const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
4138
- const sanitizeErrorCode = (rawValue) => {
4139
- let cleanValue = rawValue;
4140
- if (typeof cleanValue === "number") {
4141
- cleanValue = cleanValue.toString();
4142
- }
4143
- if (cleanValue.indexOf(",") >= 0) {
4144
- cleanValue = cleanValue.split(",")[0];
4145
- }
4146
- if (cleanValue.indexOf(":") >= 0) {
4147
- cleanValue = cleanValue.split(":")[0];
4148
- }
4149
- if (cleanValue.indexOf("#") >= 0) {
4150
- cleanValue = cleanValue.split("#")[1];
4151
- }
4152
- return cleanValue;
4153
- };
4154
- const headerKey = findKey(output.headers, "x-amzn-errortype");
4155
- if (headerKey !== undefined) {
4156
- return sanitizeErrorCode(output.headers[headerKey]);
4157
- }
4158
- if (data.code !== undefined) {
4159
- return sanitizeErrorCode(data.code);
4160
- }
4161
- if (data["__type"] !== undefined) {
4162
- return sanitizeErrorCode(data["__type"]);
4163
- }
4164
- };
1
+ module.exports = require("../index.js");