@aws-sdk/client-waf-regional 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 (93) hide show
  1. package/dist-cjs/WAFRegional.js +1 -173
  2. package/dist-cjs/WAFRegionalClient.js +1 -43
  3. package/dist-cjs/commands/AssociateWebACLCommand.js +1 -28
  4. package/dist-cjs/commands/CreateByteMatchSetCommand.js +1 -28
  5. package/dist-cjs/commands/CreateGeoMatchSetCommand.js +1 -28
  6. package/dist-cjs/commands/CreateIPSetCommand.js +1 -28
  7. package/dist-cjs/commands/CreateRateBasedRuleCommand.js +1 -28
  8. package/dist-cjs/commands/CreateRegexMatchSetCommand.js +1 -28
  9. package/dist-cjs/commands/CreateRegexPatternSetCommand.js +1 -28
  10. package/dist-cjs/commands/CreateRuleCommand.js +1 -28
  11. package/dist-cjs/commands/CreateRuleGroupCommand.js +1 -28
  12. package/dist-cjs/commands/CreateSizeConstraintSetCommand.js +1 -28
  13. package/dist-cjs/commands/CreateSqlInjectionMatchSetCommand.js +1 -28
  14. package/dist-cjs/commands/CreateWebACLCommand.js +1 -28
  15. package/dist-cjs/commands/CreateWebACLMigrationStackCommand.js +1 -28
  16. package/dist-cjs/commands/CreateXssMatchSetCommand.js +1 -28
  17. package/dist-cjs/commands/DeleteByteMatchSetCommand.js +1 -28
  18. package/dist-cjs/commands/DeleteGeoMatchSetCommand.js +1 -28
  19. package/dist-cjs/commands/DeleteIPSetCommand.js +1 -28
  20. package/dist-cjs/commands/DeleteLoggingConfigurationCommand.js +1 -28
  21. package/dist-cjs/commands/DeletePermissionPolicyCommand.js +1 -28
  22. package/dist-cjs/commands/DeleteRateBasedRuleCommand.js +1 -28
  23. package/dist-cjs/commands/DeleteRegexMatchSetCommand.js +1 -28
  24. package/dist-cjs/commands/DeleteRegexPatternSetCommand.js +1 -28
  25. package/dist-cjs/commands/DeleteRuleCommand.js +1 -28
  26. package/dist-cjs/commands/DeleteRuleGroupCommand.js +1 -28
  27. package/dist-cjs/commands/DeleteSizeConstraintSetCommand.js +1 -28
  28. package/dist-cjs/commands/DeleteSqlInjectionMatchSetCommand.js +1 -28
  29. package/dist-cjs/commands/DeleteWebACLCommand.js +1 -28
  30. package/dist-cjs/commands/DeleteXssMatchSetCommand.js +1 -28
  31. package/dist-cjs/commands/DisassociateWebACLCommand.js +1 -28
  32. package/dist-cjs/commands/GetByteMatchSetCommand.js +1 -28
  33. package/dist-cjs/commands/GetChangeTokenCommand.js +1 -28
  34. package/dist-cjs/commands/GetChangeTokenStatusCommand.js +1 -28
  35. package/dist-cjs/commands/GetGeoMatchSetCommand.js +1 -28
  36. package/dist-cjs/commands/GetIPSetCommand.js +1 -28
  37. package/dist-cjs/commands/GetLoggingConfigurationCommand.js +1 -28
  38. package/dist-cjs/commands/GetPermissionPolicyCommand.js +1 -28
  39. package/dist-cjs/commands/GetRateBasedRuleCommand.js +1 -28
  40. package/dist-cjs/commands/GetRateBasedRuleManagedKeysCommand.js +1 -28
  41. package/dist-cjs/commands/GetRegexMatchSetCommand.js +1 -28
  42. package/dist-cjs/commands/GetRegexPatternSetCommand.js +1 -28
  43. package/dist-cjs/commands/GetRuleCommand.js +1 -28
  44. package/dist-cjs/commands/GetRuleGroupCommand.js +1 -28
  45. package/dist-cjs/commands/GetSampledRequestsCommand.js +1 -28
  46. package/dist-cjs/commands/GetSizeConstraintSetCommand.js +1 -28
  47. package/dist-cjs/commands/GetSqlInjectionMatchSetCommand.js +1 -28
  48. package/dist-cjs/commands/GetWebACLCommand.js +1 -28
  49. package/dist-cjs/commands/GetWebACLForResourceCommand.js +1 -28
  50. package/dist-cjs/commands/GetXssMatchSetCommand.js +1 -28
  51. package/dist-cjs/commands/ListActivatedRulesInRuleGroupCommand.js +1 -28
  52. package/dist-cjs/commands/ListByteMatchSetsCommand.js +1 -28
  53. package/dist-cjs/commands/ListGeoMatchSetsCommand.js +1 -28
  54. package/dist-cjs/commands/ListIPSetsCommand.js +1 -28
  55. package/dist-cjs/commands/ListLoggingConfigurationsCommand.js +1 -28
  56. package/dist-cjs/commands/ListRateBasedRulesCommand.js +1 -28
  57. package/dist-cjs/commands/ListRegexMatchSetsCommand.js +1 -28
  58. package/dist-cjs/commands/ListRegexPatternSetsCommand.js +1 -28
  59. package/dist-cjs/commands/ListResourcesForWebACLCommand.js +1 -28
  60. package/dist-cjs/commands/ListRuleGroupsCommand.js +1 -28
  61. package/dist-cjs/commands/ListRulesCommand.js +1 -28
  62. package/dist-cjs/commands/ListSizeConstraintSetsCommand.js +1 -28
  63. package/dist-cjs/commands/ListSqlInjectionMatchSetsCommand.js +1 -28
  64. package/dist-cjs/commands/ListSubscribedRuleGroupsCommand.js +1 -28
  65. package/dist-cjs/commands/ListTagsForResourceCommand.js +1 -28
  66. package/dist-cjs/commands/ListWebACLsCommand.js +1 -28
  67. package/dist-cjs/commands/ListXssMatchSetsCommand.js +1 -28
  68. package/dist-cjs/commands/PutLoggingConfigurationCommand.js +1 -28
  69. package/dist-cjs/commands/PutPermissionPolicyCommand.js +1 -28
  70. package/dist-cjs/commands/TagResourceCommand.js +1 -28
  71. package/dist-cjs/commands/UntagResourceCommand.js +1 -28
  72. package/dist-cjs/commands/UpdateByteMatchSetCommand.js +1 -28
  73. package/dist-cjs/commands/UpdateGeoMatchSetCommand.js +1 -28
  74. package/dist-cjs/commands/UpdateIPSetCommand.js +1 -28
  75. package/dist-cjs/commands/UpdateRateBasedRuleCommand.js +1 -28
  76. package/dist-cjs/commands/UpdateRegexMatchSetCommand.js +1 -28
  77. package/dist-cjs/commands/UpdateRegexPatternSetCommand.js +1 -28
  78. package/dist-cjs/commands/UpdateRuleCommand.js +1 -28
  79. package/dist-cjs/commands/UpdateRuleGroupCommand.js +1 -28
  80. package/dist-cjs/commands/UpdateSizeConstraintSetCommand.js +1 -28
  81. package/dist-cjs/commands/UpdateSqlInjectionMatchSetCommand.js +1 -28
  82. package/dist-cjs/commands/UpdateWebACLCommand.js +1 -28
  83. package/dist-cjs/commands/UpdateXssMatchSetCommand.js +1 -28
  84. package/dist-cjs/commands/index.js +1 -84
  85. package/dist-cjs/endpoint/EndpointParameters.js +1 -18
  86. package/dist-cjs/extensionConfiguration.js +1 -2
  87. package/dist-cjs/index.js +6931 -10
  88. package/dist-cjs/models/WAFRegionalServiceException.js +1 -12
  89. package/dist-cjs/models/index.js +1 -4
  90. package/dist-cjs/models/models_0.js +1 -633
  91. package/dist-cjs/protocols/Aws_json1_1.js +1 -4544
  92. package/dist-cjs/runtimeExtensions.js +1 -22
  93. package/package.json +39 -39
@@ -1,4544 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.se_ListByteMatchSetsCommand = exports.se_ListActivatedRulesInRuleGroupCommand = exports.se_GetXssMatchSetCommand = exports.se_GetWebACLForResourceCommand = exports.se_GetWebACLCommand = exports.se_GetSqlInjectionMatchSetCommand = exports.se_GetSizeConstraintSetCommand = exports.se_GetSampledRequestsCommand = exports.se_GetRuleGroupCommand = exports.se_GetRuleCommand = exports.se_GetRegexPatternSetCommand = exports.se_GetRegexMatchSetCommand = exports.se_GetRateBasedRuleManagedKeysCommand = exports.se_GetRateBasedRuleCommand = exports.se_GetPermissionPolicyCommand = exports.se_GetLoggingConfigurationCommand = exports.se_GetIPSetCommand = exports.se_GetGeoMatchSetCommand = exports.se_GetChangeTokenStatusCommand = exports.se_GetChangeTokenCommand = exports.se_GetByteMatchSetCommand = exports.se_DisassociateWebACLCommand = exports.se_DeleteXssMatchSetCommand = exports.se_DeleteWebACLCommand = exports.se_DeleteSqlInjectionMatchSetCommand = exports.se_DeleteSizeConstraintSetCommand = exports.se_DeleteRuleGroupCommand = exports.se_DeleteRuleCommand = exports.se_DeleteRegexPatternSetCommand = exports.se_DeleteRegexMatchSetCommand = exports.se_DeleteRateBasedRuleCommand = exports.se_DeletePermissionPolicyCommand = exports.se_DeleteLoggingConfigurationCommand = exports.se_DeleteIPSetCommand = exports.se_DeleteGeoMatchSetCommand = exports.se_DeleteByteMatchSetCommand = exports.se_CreateXssMatchSetCommand = exports.se_CreateWebACLMigrationStackCommand = exports.se_CreateWebACLCommand = exports.se_CreateSqlInjectionMatchSetCommand = exports.se_CreateSizeConstraintSetCommand = exports.se_CreateRuleGroupCommand = exports.se_CreateRuleCommand = exports.se_CreateRegexPatternSetCommand = exports.se_CreateRegexMatchSetCommand = exports.se_CreateRateBasedRuleCommand = exports.se_CreateIPSetCommand = exports.se_CreateGeoMatchSetCommand = exports.se_CreateByteMatchSetCommand = exports.se_AssociateWebACLCommand = void 0;
4
- exports.de_DeletePermissionPolicyCommand = exports.de_DeleteLoggingConfigurationCommand = exports.de_DeleteIPSetCommand = exports.de_DeleteGeoMatchSetCommand = exports.de_DeleteByteMatchSetCommand = exports.de_CreateXssMatchSetCommand = exports.de_CreateWebACLMigrationStackCommand = exports.de_CreateWebACLCommand = exports.de_CreateSqlInjectionMatchSetCommand = exports.de_CreateSizeConstraintSetCommand = exports.de_CreateRuleGroupCommand = exports.de_CreateRuleCommand = exports.de_CreateRegexPatternSetCommand = exports.de_CreateRegexMatchSetCommand = exports.de_CreateRateBasedRuleCommand = exports.de_CreateIPSetCommand = exports.de_CreateGeoMatchSetCommand = exports.de_CreateByteMatchSetCommand = exports.de_AssociateWebACLCommand = exports.se_UpdateXssMatchSetCommand = exports.se_UpdateWebACLCommand = exports.se_UpdateSqlInjectionMatchSetCommand = exports.se_UpdateSizeConstraintSetCommand = exports.se_UpdateRuleGroupCommand = exports.se_UpdateRuleCommand = exports.se_UpdateRegexPatternSetCommand = exports.se_UpdateRegexMatchSetCommand = exports.se_UpdateRateBasedRuleCommand = exports.se_UpdateIPSetCommand = exports.se_UpdateGeoMatchSetCommand = exports.se_UpdateByteMatchSetCommand = exports.se_UntagResourceCommand = exports.se_TagResourceCommand = exports.se_PutPermissionPolicyCommand = exports.se_PutLoggingConfigurationCommand = exports.se_ListXssMatchSetsCommand = exports.se_ListWebACLsCommand = exports.se_ListTagsForResourceCommand = exports.se_ListSubscribedRuleGroupsCommand = exports.se_ListSqlInjectionMatchSetsCommand = exports.se_ListSizeConstraintSetsCommand = exports.se_ListRulesCommand = exports.se_ListRuleGroupsCommand = exports.se_ListResourcesForWebACLCommand = exports.se_ListRegexPatternSetsCommand = exports.se_ListRegexMatchSetsCommand = exports.se_ListRateBasedRulesCommand = exports.se_ListLoggingConfigurationsCommand = exports.se_ListIPSetsCommand = exports.se_ListGeoMatchSetsCommand = void 0;
5
- exports.de_UntagResourceCommand = exports.de_TagResourceCommand = exports.de_PutPermissionPolicyCommand = exports.de_PutLoggingConfigurationCommand = exports.de_ListXssMatchSetsCommand = exports.de_ListWebACLsCommand = exports.de_ListTagsForResourceCommand = exports.de_ListSubscribedRuleGroupsCommand = exports.de_ListSqlInjectionMatchSetsCommand = exports.de_ListSizeConstraintSetsCommand = exports.de_ListRulesCommand = exports.de_ListRuleGroupsCommand = exports.de_ListResourcesForWebACLCommand = exports.de_ListRegexPatternSetsCommand = exports.de_ListRegexMatchSetsCommand = exports.de_ListRateBasedRulesCommand = exports.de_ListLoggingConfigurationsCommand = exports.de_ListIPSetsCommand = exports.de_ListGeoMatchSetsCommand = exports.de_ListByteMatchSetsCommand = exports.de_ListActivatedRulesInRuleGroupCommand = exports.de_GetXssMatchSetCommand = exports.de_GetWebACLForResourceCommand = exports.de_GetWebACLCommand = exports.de_GetSqlInjectionMatchSetCommand = exports.de_GetSizeConstraintSetCommand = exports.de_GetSampledRequestsCommand = exports.de_GetRuleGroupCommand = exports.de_GetRuleCommand = exports.de_GetRegexPatternSetCommand = exports.de_GetRegexMatchSetCommand = exports.de_GetRateBasedRuleManagedKeysCommand = exports.de_GetRateBasedRuleCommand = exports.de_GetPermissionPolicyCommand = exports.de_GetLoggingConfigurationCommand = exports.de_GetIPSetCommand = exports.de_GetGeoMatchSetCommand = exports.de_GetChangeTokenStatusCommand = exports.de_GetChangeTokenCommand = exports.de_GetByteMatchSetCommand = exports.de_DisassociateWebACLCommand = exports.de_DeleteXssMatchSetCommand = exports.de_DeleteWebACLCommand = exports.de_DeleteSqlInjectionMatchSetCommand = exports.de_DeleteSizeConstraintSetCommand = exports.de_DeleteRuleGroupCommand = exports.de_DeleteRuleCommand = exports.de_DeleteRegexPatternSetCommand = exports.de_DeleteRegexMatchSetCommand = exports.de_DeleteRateBasedRuleCommand = void 0;
6
- exports.de_UpdateXssMatchSetCommand = exports.de_UpdateWebACLCommand = exports.de_UpdateSqlInjectionMatchSetCommand = exports.de_UpdateSizeConstraintSetCommand = exports.de_UpdateRuleGroupCommand = exports.de_UpdateRuleCommand = exports.de_UpdateRegexPatternSetCommand = exports.de_UpdateRegexMatchSetCommand = exports.de_UpdateRateBasedRuleCommand = exports.de_UpdateIPSetCommand = exports.de_UpdateGeoMatchSetCommand = exports.de_UpdateByteMatchSetCommand = void 0;
7
- const protocol_http_1 = require("@smithy/protocol-http");
8
- const smithy_client_1 = require("@smithy/smithy-client");
9
- const models_0_1 = require("../models/models_0");
10
- const WAFRegionalServiceException_1 = require("../models/WAFRegionalServiceException");
11
- const se_AssociateWebACLCommand = async (input, context) => {
12
- const headers = sharedHeaders("AssociateWebACL");
13
- let body;
14
- body = JSON.stringify((0, smithy_client_1._json)(input));
15
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
16
- };
17
- exports.se_AssociateWebACLCommand = se_AssociateWebACLCommand;
18
- const se_CreateByteMatchSetCommand = async (input, context) => {
19
- const headers = sharedHeaders("CreateByteMatchSet");
20
- let body;
21
- body = JSON.stringify((0, smithy_client_1._json)(input));
22
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
23
- };
24
- exports.se_CreateByteMatchSetCommand = se_CreateByteMatchSetCommand;
25
- const se_CreateGeoMatchSetCommand = async (input, context) => {
26
- const headers = sharedHeaders("CreateGeoMatchSet");
27
- let body;
28
- body = JSON.stringify((0, smithy_client_1._json)(input));
29
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
30
- };
31
- exports.se_CreateGeoMatchSetCommand = se_CreateGeoMatchSetCommand;
32
- const se_CreateIPSetCommand = async (input, context) => {
33
- const headers = sharedHeaders("CreateIPSet");
34
- let body;
35
- body = JSON.stringify((0, smithy_client_1._json)(input));
36
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
37
- };
38
- exports.se_CreateIPSetCommand = se_CreateIPSetCommand;
39
- const se_CreateRateBasedRuleCommand = async (input, context) => {
40
- const headers = sharedHeaders("CreateRateBasedRule");
41
- let body;
42
- body = JSON.stringify((0, smithy_client_1._json)(input));
43
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
44
- };
45
- exports.se_CreateRateBasedRuleCommand = se_CreateRateBasedRuleCommand;
46
- const se_CreateRegexMatchSetCommand = async (input, context) => {
47
- const headers = sharedHeaders("CreateRegexMatchSet");
48
- let body;
49
- body = JSON.stringify((0, smithy_client_1._json)(input));
50
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
51
- };
52
- exports.se_CreateRegexMatchSetCommand = se_CreateRegexMatchSetCommand;
53
- const se_CreateRegexPatternSetCommand = async (input, context) => {
54
- const headers = sharedHeaders("CreateRegexPatternSet");
55
- let body;
56
- body = JSON.stringify((0, smithy_client_1._json)(input));
57
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
58
- };
59
- exports.se_CreateRegexPatternSetCommand = se_CreateRegexPatternSetCommand;
60
- const se_CreateRuleCommand = async (input, context) => {
61
- const headers = sharedHeaders("CreateRule");
62
- let body;
63
- body = JSON.stringify((0, smithy_client_1._json)(input));
64
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
65
- };
66
- exports.se_CreateRuleCommand = se_CreateRuleCommand;
67
- const se_CreateRuleGroupCommand = async (input, context) => {
68
- const headers = sharedHeaders("CreateRuleGroup");
69
- let body;
70
- body = JSON.stringify((0, smithy_client_1._json)(input));
71
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
72
- };
73
- exports.se_CreateRuleGroupCommand = se_CreateRuleGroupCommand;
74
- const se_CreateSizeConstraintSetCommand = async (input, context) => {
75
- const headers = sharedHeaders("CreateSizeConstraintSet");
76
- let body;
77
- body = JSON.stringify((0, smithy_client_1._json)(input));
78
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
79
- };
80
- exports.se_CreateSizeConstraintSetCommand = se_CreateSizeConstraintSetCommand;
81
- const se_CreateSqlInjectionMatchSetCommand = async (input, context) => {
82
- const headers = sharedHeaders("CreateSqlInjectionMatchSet");
83
- let body;
84
- body = JSON.stringify((0, smithy_client_1._json)(input));
85
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
86
- };
87
- exports.se_CreateSqlInjectionMatchSetCommand = se_CreateSqlInjectionMatchSetCommand;
88
- const se_CreateWebACLCommand = async (input, context) => {
89
- const headers = sharedHeaders("CreateWebACL");
90
- let body;
91
- body = JSON.stringify((0, smithy_client_1._json)(input));
92
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
93
- };
94
- exports.se_CreateWebACLCommand = se_CreateWebACLCommand;
95
- const se_CreateWebACLMigrationStackCommand = async (input, context) => {
96
- const headers = sharedHeaders("CreateWebACLMigrationStack");
97
- let body;
98
- body = JSON.stringify((0, smithy_client_1._json)(input));
99
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
100
- };
101
- exports.se_CreateWebACLMigrationStackCommand = se_CreateWebACLMigrationStackCommand;
102
- const se_CreateXssMatchSetCommand = async (input, context) => {
103
- const headers = sharedHeaders("CreateXssMatchSet");
104
- let body;
105
- body = JSON.stringify((0, smithy_client_1._json)(input));
106
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
107
- };
108
- exports.se_CreateXssMatchSetCommand = se_CreateXssMatchSetCommand;
109
- const se_DeleteByteMatchSetCommand = async (input, context) => {
110
- const headers = sharedHeaders("DeleteByteMatchSet");
111
- let body;
112
- body = JSON.stringify((0, smithy_client_1._json)(input));
113
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
114
- };
115
- exports.se_DeleteByteMatchSetCommand = se_DeleteByteMatchSetCommand;
116
- const se_DeleteGeoMatchSetCommand = async (input, context) => {
117
- const headers = sharedHeaders("DeleteGeoMatchSet");
118
- let body;
119
- body = JSON.stringify((0, smithy_client_1._json)(input));
120
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
121
- };
122
- exports.se_DeleteGeoMatchSetCommand = se_DeleteGeoMatchSetCommand;
123
- const se_DeleteIPSetCommand = async (input, context) => {
124
- const headers = sharedHeaders("DeleteIPSet");
125
- let body;
126
- body = JSON.stringify((0, smithy_client_1._json)(input));
127
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
128
- };
129
- exports.se_DeleteIPSetCommand = se_DeleteIPSetCommand;
130
- const se_DeleteLoggingConfigurationCommand = async (input, context) => {
131
- const headers = sharedHeaders("DeleteLoggingConfiguration");
132
- let body;
133
- body = JSON.stringify((0, smithy_client_1._json)(input));
134
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
135
- };
136
- exports.se_DeleteLoggingConfigurationCommand = se_DeleteLoggingConfigurationCommand;
137
- const se_DeletePermissionPolicyCommand = async (input, context) => {
138
- const headers = sharedHeaders("DeletePermissionPolicy");
139
- let body;
140
- body = JSON.stringify((0, smithy_client_1._json)(input));
141
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
142
- };
143
- exports.se_DeletePermissionPolicyCommand = se_DeletePermissionPolicyCommand;
144
- const se_DeleteRateBasedRuleCommand = async (input, context) => {
145
- const headers = sharedHeaders("DeleteRateBasedRule");
146
- let body;
147
- body = JSON.stringify((0, smithy_client_1._json)(input));
148
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
149
- };
150
- exports.se_DeleteRateBasedRuleCommand = se_DeleteRateBasedRuleCommand;
151
- const se_DeleteRegexMatchSetCommand = async (input, context) => {
152
- const headers = sharedHeaders("DeleteRegexMatchSet");
153
- let body;
154
- body = JSON.stringify((0, smithy_client_1._json)(input));
155
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
156
- };
157
- exports.se_DeleteRegexMatchSetCommand = se_DeleteRegexMatchSetCommand;
158
- const se_DeleteRegexPatternSetCommand = async (input, context) => {
159
- const headers = sharedHeaders("DeleteRegexPatternSet");
160
- let body;
161
- body = JSON.stringify((0, smithy_client_1._json)(input));
162
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
163
- };
164
- exports.se_DeleteRegexPatternSetCommand = se_DeleteRegexPatternSetCommand;
165
- const se_DeleteRuleCommand = async (input, context) => {
166
- const headers = sharedHeaders("DeleteRule");
167
- let body;
168
- body = JSON.stringify((0, smithy_client_1._json)(input));
169
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
170
- };
171
- exports.se_DeleteRuleCommand = se_DeleteRuleCommand;
172
- const se_DeleteRuleGroupCommand = async (input, context) => {
173
- const headers = sharedHeaders("DeleteRuleGroup");
174
- let body;
175
- body = JSON.stringify((0, smithy_client_1._json)(input));
176
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
177
- };
178
- exports.se_DeleteRuleGroupCommand = se_DeleteRuleGroupCommand;
179
- const se_DeleteSizeConstraintSetCommand = async (input, context) => {
180
- const headers = sharedHeaders("DeleteSizeConstraintSet");
181
- let body;
182
- body = JSON.stringify((0, smithy_client_1._json)(input));
183
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
184
- };
185
- exports.se_DeleteSizeConstraintSetCommand = se_DeleteSizeConstraintSetCommand;
186
- const se_DeleteSqlInjectionMatchSetCommand = async (input, context) => {
187
- const headers = sharedHeaders("DeleteSqlInjectionMatchSet");
188
- let body;
189
- body = JSON.stringify((0, smithy_client_1._json)(input));
190
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
191
- };
192
- exports.se_DeleteSqlInjectionMatchSetCommand = se_DeleteSqlInjectionMatchSetCommand;
193
- const se_DeleteWebACLCommand = async (input, context) => {
194
- const headers = sharedHeaders("DeleteWebACL");
195
- let body;
196
- body = JSON.stringify((0, smithy_client_1._json)(input));
197
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
198
- };
199
- exports.se_DeleteWebACLCommand = se_DeleteWebACLCommand;
200
- const se_DeleteXssMatchSetCommand = async (input, context) => {
201
- const headers = sharedHeaders("DeleteXssMatchSet");
202
- let body;
203
- body = JSON.stringify((0, smithy_client_1._json)(input));
204
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
205
- };
206
- exports.se_DeleteXssMatchSetCommand = se_DeleteXssMatchSetCommand;
207
- const se_DisassociateWebACLCommand = async (input, context) => {
208
- const headers = sharedHeaders("DisassociateWebACL");
209
- let body;
210
- body = JSON.stringify((0, smithy_client_1._json)(input));
211
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
212
- };
213
- exports.se_DisassociateWebACLCommand = se_DisassociateWebACLCommand;
214
- const se_GetByteMatchSetCommand = async (input, context) => {
215
- const headers = sharedHeaders("GetByteMatchSet");
216
- let body;
217
- body = JSON.stringify((0, smithy_client_1._json)(input));
218
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
219
- };
220
- exports.se_GetByteMatchSetCommand = se_GetByteMatchSetCommand;
221
- const se_GetChangeTokenCommand = async (input, context) => {
222
- const headers = sharedHeaders("GetChangeToken");
223
- let body;
224
- body = JSON.stringify((0, smithy_client_1._json)(input));
225
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
226
- };
227
- exports.se_GetChangeTokenCommand = se_GetChangeTokenCommand;
228
- const se_GetChangeTokenStatusCommand = async (input, context) => {
229
- const headers = sharedHeaders("GetChangeTokenStatus");
230
- let body;
231
- body = JSON.stringify((0, smithy_client_1._json)(input));
232
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
233
- };
234
- exports.se_GetChangeTokenStatusCommand = se_GetChangeTokenStatusCommand;
235
- const se_GetGeoMatchSetCommand = async (input, context) => {
236
- const headers = sharedHeaders("GetGeoMatchSet");
237
- let body;
238
- body = JSON.stringify((0, smithy_client_1._json)(input));
239
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
240
- };
241
- exports.se_GetGeoMatchSetCommand = se_GetGeoMatchSetCommand;
242
- const se_GetIPSetCommand = async (input, context) => {
243
- const headers = sharedHeaders("GetIPSet");
244
- let body;
245
- body = JSON.stringify((0, smithy_client_1._json)(input));
246
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
247
- };
248
- exports.se_GetIPSetCommand = se_GetIPSetCommand;
249
- const se_GetLoggingConfigurationCommand = async (input, context) => {
250
- const headers = sharedHeaders("GetLoggingConfiguration");
251
- let body;
252
- body = JSON.stringify((0, smithy_client_1._json)(input));
253
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
254
- };
255
- exports.se_GetLoggingConfigurationCommand = se_GetLoggingConfigurationCommand;
256
- const se_GetPermissionPolicyCommand = async (input, context) => {
257
- const headers = sharedHeaders("GetPermissionPolicy");
258
- let body;
259
- body = JSON.stringify((0, smithy_client_1._json)(input));
260
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
261
- };
262
- exports.se_GetPermissionPolicyCommand = se_GetPermissionPolicyCommand;
263
- const se_GetRateBasedRuleCommand = async (input, context) => {
264
- const headers = sharedHeaders("GetRateBasedRule");
265
- let body;
266
- body = JSON.stringify((0, smithy_client_1._json)(input));
267
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
268
- };
269
- exports.se_GetRateBasedRuleCommand = se_GetRateBasedRuleCommand;
270
- const se_GetRateBasedRuleManagedKeysCommand = async (input, context) => {
271
- const headers = sharedHeaders("GetRateBasedRuleManagedKeys");
272
- let body;
273
- body = JSON.stringify((0, smithy_client_1._json)(input));
274
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
275
- };
276
- exports.se_GetRateBasedRuleManagedKeysCommand = se_GetRateBasedRuleManagedKeysCommand;
277
- const se_GetRegexMatchSetCommand = async (input, context) => {
278
- const headers = sharedHeaders("GetRegexMatchSet");
279
- let body;
280
- body = JSON.stringify((0, smithy_client_1._json)(input));
281
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
282
- };
283
- exports.se_GetRegexMatchSetCommand = se_GetRegexMatchSetCommand;
284
- const se_GetRegexPatternSetCommand = async (input, context) => {
285
- const headers = sharedHeaders("GetRegexPatternSet");
286
- let body;
287
- body = JSON.stringify((0, smithy_client_1._json)(input));
288
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
289
- };
290
- exports.se_GetRegexPatternSetCommand = se_GetRegexPatternSetCommand;
291
- const se_GetRuleCommand = async (input, context) => {
292
- const headers = sharedHeaders("GetRule");
293
- let body;
294
- body = JSON.stringify((0, smithy_client_1._json)(input));
295
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
296
- };
297
- exports.se_GetRuleCommand = se_GetRuleCommand;
298
- const se_GetRuleGroupCommand = async (input, context) => {
299
- const headers = sharedHeaders("GetRuleGroup");
300
- let body;
301
- body = JSON.stringify((0, smithy_client_1._json)(input));
302
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
303
- };
304
- exports.se_GetRuleGroupCommand = se_GetRuleGroupCommand;
305
- const se_GetSampledRequestsCommand = async (input, context) => {
306
- const headers = sharedHeaders("GetSampledRequests");
307
- let body;
308
- body = JSON.stringify(se_GetSampledRequestsRequest(input, context));
309
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
310
- };
311
- exports.se_GetSampledRequestsCommand = se_GetSampledRequestsCommand;
312
- const se_GetSizeConstraintSetCommand = async (input, context) => {
313
- const headers = sharedHeaders("GetSizeConstraintSet");
314
- let body;
315
- body = JSON.stringify((0, smithy_client_1._json)(input));
316
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
317
- };
318
- exports.se_GetSizeConstraintSetCommand = se_GetSizeConstraintSetCommand;
319
- const se_GetSqlInjectionMatchSetCommand = async (input, context) => {
320
- const headers = sharedHeaders("GetSqlInjectionMatchSet");
321
- let body;
322
- body = JSON.stringify((0, smithy_client_1._json)(input));
323
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
324
- };
325
- exports.se_GetSqlInjectionMatchSetCommand = se_GetSqlInjectionMatchSetCommand;
326
- const se_GetWebACLCommand = async (input, context) => {
327
- const headers = sharedHeaders("GetWebACL");
328
- let body;
329
- body = JSON.stringify((0, smithy_client_1._json)(input));
330
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
331
- };
332
- exports.se_GetWebACLCommand = se_GetWebACLCommand;
333
- const se_GetWebACLForResourceCommand = async (input, context) => {
334
- const headers = sharedHeaders("GetWebACLForResource");
335
- let body;
336
- body = JSON.stringify((0, smithy_client_1._json)(input));
337
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
338
- };
339
- exports.se_GetWebACLForResourceCommand = se_GetWebACLForResourceCommand;
340
- const se_GetXssMatchSetCommand = async (input, context) => {
341
- const headers = sharedHeaders("GetXssMatchSet");
342
- let body;
343
- body = JSON.stringify((0, smithy_client_1._json)(input));
344
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
345
- };
346
- exports.se_GetXssMatchSetCommand = se_GetXssMatchSetCommand;
347
- const se_ListActivatedRulesInRuleGroupCommand = async (input, context) => {
348
- const headers = sharedHeaders("ListActivatedRulesInRuleGroup");
349
- let body;
350
- body = JSON.stringify((0, smithy_client_1._json)(input));
351
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
352
- };
353
- exports.se_ListActivatedRulesInRuleGroupCommand = se_ListActivatedRulesInRuleGroupCommand;
354
- const se_ListByteMatchSetsCommand = async (input, context) => {
355
- const headers = sharedHeaders("ListByteMatchSets");
356
- let body;
357
- body = JSON.stringify((0, smithy_client_1._json)(input));
358
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
359
- };
360
- exports.se_ListByteMatchSetsCommand = se_ListByteMatchSetsCommand;
361
- const se_ListGeoMatchSetsCommand = async (input, context) => {
362
- const headers = sharedHeaders("ListGeoMatchSets");
363
- let body;
364
- body = JSON.stringify((0, smithy_client_1._json)(input));
365
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
366
- };
367
- exports.se_ListGeoMatchSetsCommand = se_ListGeoMatchSetsCommand;
368
- const se_ListIPSetsCommand = async (input, context) => {
369
- const headers = sharedHeaders("ListIPSets");
370
- let body;
371
- body = JSON.stringify((0, smithy_client_1._json)(input));
372
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
373
- };
374
- exports.se_ListIPSetsCommand = se_ListIPSetsCommand;
375
- const se_ListLoggingConfigurationsCommand = async (input, context) => {
376
- const headers = sharedHeaders("ListLoggingConfigurations");
377
- let body;
378
- body = JSON.stringify((0, smithy_client_1._json)(input));
379
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
380
- };
381
- exports.se_ListLoggingConfigurationsCommand = se_ListLoggingConfigurationsCommand;
382
- const se_ListRateBasedRulesCommand = async (input, context) => {
383
- const headers = sharedHeaders("ListRateBasedRules");
384
- let body;
385
- body = JSON.stringify((0, smithy_client_1._json)(input));
386
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
387
- };
388
- exports.se_ListRateBasedRulesCommand = se_ListRateBasedRulesCommand;
389
- const se_ListRegexMatchSetsCommand = async (input, context) => {
390
- const headers = sharedHeaders("ListRegexMatchSets");
391
- let body;
392
- body = JSON.stringify((0, smithy_client_1._json)(input));
393
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
394
- };
395
- exports.se_ListRegexMatchSetsCommand = se_ListRegexMatchSetsCommand;
396
- const se_ListRegexPatternSetsCommand = async (input, context) => {
397
- const headers = sharedHeaders("ListRegexPatternSets");
398
- let body;
399
- body = JSON.stringify((0, smithy_client_1._json)(input));
400
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
401
- };
402
- exports.se_ListRegexPatternSetsCommand = se_ListRegexPatternSetsCommand;
403
- const se_ListResourcesForWebACLCommand = async (input, context) => {
404
- const headers = sharedHeaders("ListResourcesForWebACL");
405
- let body;
406
- body = JSON.stringify((0, smithy_client_1._json)(input));
407
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
408
- };
409
- exports.se_ListResourcesForWebACLCommand = se_ListResourcesForWebACLCommand;
410
- const se_ListRuleGroupsCommand = async (input, context) => {
411
- const headers = sharedHeaders("ListRuleGroups");
412
- let body;
413
- body = JSON.stringify((0, smithy_client_1._json)(input));
414
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
415
- };
416
- exports.se_ListRuleGroupsCommand = se_ListRuleGroupsCommand;
417
- const se_ListRulesCommand = async (input, context) => {
418
- const headers = sharedHeaders("ListRules");
419
- let body;
420
- body = JSON.stringify((0, smithy_client_1._json)(input));
421
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
422
- };
423
- exports.se_ListRulesCommand = se_ListRulesCommand;
424
- const se_ListSizeConstraintSetsCommand = async (input, context) => {
425
- const headers = sharedHeaders("ListSizeConstraintSets");
426
- let body;
427
- body = JSON.stringify((0, smithy_client_1._json)(input));
428
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
429
- };
430
- exports.se_ListSizeConstraintSetsCommand = se_ListSizeConstraintSetsCommand;
431
- const se_ListSqlInjectionMatchSetsCommand = async (input, context) => {
432
- const headers = sharedHeaders("ListSqlInjectionMatchSets");
433
- let body;
434
- body = JSON.stringify((0, smithy_client_1._json)(input));
435
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
436
- };
437
- exports.se_ListSqlInjectionMatchSetsCommand = se_ListSqlInjectionMatchSetsCommand;
438
- const se_ListSubscribedRuleGroupsCommand = async (input, context) => {
439
- const headers = sharedHeaders("ListSubscribedRuleGroups");
440
- let body;
441
- body = JSON.stringify((0, smithy_client_1._json)(input));
442
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
443
- };
444
- exports.se_ListSubscribedRuleGroupsCommand = se_ListSubscribedRuleGroupsCommand;
445
- const se_ListTagsForResourceCommand = async (input, context) => {
446
- const headers = sharedHeaders("ListTagsForResource");
447
- let body;
448
- body = JSON.stringify((0, smithy_client_1._json)(input));
449
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
450
- };
451
- exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
452
- const se_ListWebACLsCommand = async (input, context) => {
453
- const headers = sharedHeaders("ListWebACLs");
454
- let body;
455
- body = JSON.stringify((0, smithy_client_1._json)(input));
456
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
457
- };
458
- exports.se_ListWebACLsCommand = se_ListWebACLsCommand;
459
- const se_ListXssMatchSetsCommand = async (input, context) => {
460
- const headers = sharedHeaders("ListXssMatchSets");
461
- let body;
462
- body = JSON.stringify((0, smithy_client_1._json)(input));
463
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
464
- };
465
- exports.se_ListXssMatchSetsCommand = se_ListXssMatchSetsCommand;
466
- const se_PutLoggingConfigurationCommand = async (input, context) => {
467
- const headers = sharedHeaders("PutLoggingConfiguration");
468
- let body;
469
- body = JSON.stringify((0, smithy_client_1._json)(input));
470
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
471
- };
472
- exports.se_PutLoggingConfigurationCommand = se_PutLoggingConfigurationCommand;
473
- const se_PutPermissionPolicyCommand = async (input, context) => {
474
- const headers = sharedHeaders("PutPermissionPolicy");
475
- let body;
476
- body = JSON.stringify((0, smithy_client_1._json)(input));
477
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
478
- };
479
- exports.se_PutPermissionPolicyCommand = se_PutPermissionPolicyCommand;
480
- const se_TagResourceCommand = async (input, context) => {
481
- const headers = sharedHeaders("TagResource");
482
- let body;
483
- body = JSON.stringify((0, smithy_client_1._json)(input));
484
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
485
- };
486
- exports.se_TagResourceCommand = se_TagResourceCommand;
487
- const se_UntagResourceCommand = async (input, context) => {
488
- const headers = sharedHeaders("UntagResource");
489
- let body;
490
- body = JSON.stringify((0, smithy_client_1._json)(input));
491
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
492
- };
493
- exports.se_UntagResourceCommand = se_UntagResourceCommand;
494
- const se_UpdateByteMatchSetCommand = async (input, context) => {
495
- const headers = sharedHeaders("UpdateByteMatchSet");
496
- let body;
497
- body = JSON.stringify(se_UpdateByteMatchSetRequest(input, context));
498
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
499
- };
500
- exports.se_UpdateByteMatchSetCommand = se_UpdateByteMatchSetCommand;
501
- const se_UpdateGeoMatchSetCommand = async (input, context) => {
502
- const headers = sharedHeaders("UpdateGeoMatchSet");
503
- let body;
504
- body = JSON.stringify((0, smithy_client_1._json)(input));
505
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
506
- };
507
- exports.se_UpdateGeoMatchSetCommand = se_UpdateGeoMatchSetCommand;
508
- const se_UpdateIPSetCommand = async (input, context) => {
509
- const headers = sharedHeaders("UpdateIPSet");
510
- let body;
511
- body = JSON.stringify((0, smithy_client_1._json)(input));
512
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
513
- };
514
- exports.se_UpdateIPSetCommand = se_UpdateIPSetCommand;
515
- const se_UpdateRateBasedRuleCommand = async (input, context) => {
516
- const headers = sharedHeaders("UpdateRateBasedRule");
517
- let body;
518
- body = JSON.stringify((0, smithy_client_1._json)(input));
519
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
520
- };
521
- exports.se_UpdateRateBasedRuleCommand = se_UpdateRateBasedRuleCommand;
522
- const se_UpdateRegexMatchSetCommand = async (input, context) => {
523
- const headers = sharedHeaders("UpdateRegexMatchSet");
524
- let body;
525
- body = JSON.stringify((0, smithy_client_1._json)(input));
526
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
527
- };
528
- exports.se_UpdateRegexMatchSetCommand = se_UpdateRegexMatchSetCommand;
529
- const se_UpdateRegexPatternSetCommand = async (input, context) => {
530
- const headers = sharedHeaders("UpdateRegexPatternSet");
531
- let body;
532
- body = JSON.stringify((0, smithy_client_1._json)(input));
533
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
534
- };
535
- exports.se_UpdateRegexPatternSetCommand = se_UpdateRegexPatternSetCommand;
536
- const se_UpdateRuleCommand = async (input, context) => {
537
- const headers = sharedHeaders("UpdateRule");
538
- let body;
539
- body = JSON.stringify((0, smithy_client_1._json)(input));
540
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
541
- };
542
- exports.se_UpdateRuleCommand = se_UpdateRuleCommand;
543
- const se_UpdateRuleGroupCommand = async (input, context) => {
544
- const headers = sharedHeaders("UpdateRuleGroup");
545
- let body;
546
- body = JSON.stringify((0, smithy_client_1._json)(input));
547
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
548
- };
549
- exports.se_UpdateRuleGroupCommand = se_UpdateRuleGroupCommand;
550
- const se_UpdateSizeConstraintSetCommand = async (input, context) => {
551
- const headers = sharedHeaders("UpdateSizeConstraintSet");
552
- let body;
553
- body = JSON.stringify((0, smithy_client_1._json)(input));
554
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
555
- };
556
- exports.se_UpdateSizeConstraintSetCommand = se_UpdateSizeConstraintSetCommand;
557
- const se_UpdateSqlInjectionMatchSetCommand = async (input, context) => {
558
- const headers = sharedHeaders("UpdateSqlInjectionMatchSet");
559
- let body;
560
- body = JSON.stringify((0, smithy_client_1._json)(input));
561
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
562
- };
563
- exports.se_UpdateSqlInjectionMatchSetCommand = se_UpdateSqlInjectionMatchSetCommand;
564
- const se_UpdateWebACLCommand = async (input, context) => {
565
- const headers = sharedHeaders("UpdateWebACL");
566
- let body;
567
- body = JSON.stringify((0, smithy_client_1._json)(input));
568
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
569
- };
570
- exports.se_UpdateWebACLCommand = se_UpdateWebACLCommand;
571
- const se_UpdateXssMatchSetCommand = async (input, context) => {
572
- const headers = sharedHeaders("UpdateXssMatchSet");
573
- let body;
574
- body = JSON.stringify((0, smithy_client_1._json)(input));
575
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
576
- };
577
- exports.se_UpdateXssMatchSetCommand = se_UpdateXssMatchSetCommand;
578
- const de_AssociateWebACLCommand = async (output, context) => {
579
- if (output.statusCode >= 300) {
580
- return de_AssociateWebACLCommandError(output, context);
581
- }
582
- const data = await parseBody(output.body, context);
583
- let contents = {};
584
- contents = (0, smithy_client_1._json)(data);
585
- const response = {
586
- $metadata: deserializeMetadata(output),
587
- ...contents,
588
- };
589
- return response;
590
- };
591
- exports.de_AssociateWebACLCommand = de_AssociateWebACLCommand;
592
- const de_AssociateWebACLCommandError = async (output, context) => {
593
- const parsedOutput = {
594
- ...output,
595
- body: await parseErrorBody(output.body, context),
596
- };
597
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
598
- switch (errorCode) {
599
- case "WAFInternalErrorException":
600
- case "com.amazonaws.wafregional#WAFInternalErrorException":
601
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
602
- case "WAFInvalidAccountException":
603
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
604
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
605
- case "WAFInvalidParameterException":
606
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
607
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
608
- case "WAFNonexistentItemException":
609
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
610
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
611
- case "WAFUnavailableEntityException":
612
- case "com.amazonaws.wafregional#WAFUnavailableEntityException":
613
- throw await de_WAFUnavailableEntityExceptionRes(parsedOutput, context);
614
- default:
615
- const parsedBody = parsedOutput.body;
616
- return throwDefaultError({
617
- output,
618
- parsedBody,
619
- errorCode,
620
- });
621
- }
622
- };
623
- const de_CreateByteMatchSetCommand = async (output, context) => {
624
- if (output.statusCode >= 300) {
625
- return de_CreateByteMatchSetCommandError(output, context);
626
- }
627
- const data = await parseBody(output.body, context);
628
- let contents = {};
629
- contents = de_CreateByteMatchSetResponse(data, context);
630
- const response = {
631
- $metadata: deserializeMetadata(output),
632
- ...contents,
633
- };
634
- return response;
635
- };
636
- exports.de_CreateByteMatchSetCommand = de_CreateByteMatchSetCommand;
637
- const de_CreateByteMatchSetCommandError = async (output, context) => {
638
- const parsedOutput = {
639
- ...output,
640
- body: await parseErrorBody(output.body, context),
641
- };
642
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
643
- switch (errorCode) {
644
- case "WAFDisallowedNameException":
645
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
646
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
647
- case "WAFInternalErrorException":
648
- case "com.amazonaws.wafregional#WAFInternalErrorException":
649
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
650
- case "WAFInvalidAccountException":
651
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
652
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
653
- case "WAFInvalidParameterException":
654
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
655
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
656
- case "WAFLimitsExceededException":
657
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
658
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
659
- case "WAFStaleDataException":
660
- case "com.amazonaws.wafregional#WAFStaleDataException":
661
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
662
- default:
663
- const parsedBody = parsedOutput.body;
664
- return throwDefaultError({
665
- output,
666
- parsedBody,
667
- errorCode,
668
- });
669
- }
670
- };
671
- const de_CreateGeoMatchSetCommand = async (output, context) => {
672
- if (output.statusCode >= 300) {
673
- return de_CreateGeoMatchSetCommandError(output, context);
674
- }
675
- const data = await parseBody(output.body, context);
676
- let contents = {};
677
- contents = (0, smithy_client_1._json)(data);
678
- const response = {
679
- $metadata: deserializeMetadata(output),
680
- ...contents,
681
- };
682
- return response;
683
- };
684
- exports.de_CreateGeoMatchSetCommand = de_CreateGeoMatchSetCommand;
685
- const de_CreateGeoMatchSetCommandError = async (output, context) => {
686
- const parsedOutput = {
687
- ...output,
688
- body: await parseErrorBody(output.body, context),
689
- };
690
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
691
- switch (errorCode) {
692
- case "WAFDisallowedNameException":
693
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
694
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
695
- case "WAFInternalErrorException":
696
- case "com.amazonaws.wafregional#WAFInternalErrorException":
697
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
698
- case "WAFInvalidAccountException":
699
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
700
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
701
- case "WAFInvalidParameterException":
702
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
703
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
704
- case "WAFLimitsExceededException":
705
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
706
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
707
- case "WAFStaleDataException":
708
- case "com.amazonaws.wafregional#WAFStaleDataException":
709
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
710
- default:
711
- const parsedBody = parsedOutput.body;
712
- return throwDefaultError({
713
- output,
714
- parsedBody,
715
- errorCode,
716
- });
717
- }
718
- };
719
- const de_CreateIPSetCommand = async (output, context) => {
720
- if (output.statusCode >= 300) {
721
- return de_CreateIPSetCommandError(output, context);
722
- }
723
- const data = await parseBody(output.body, context);
724
- let contents = {};
725
- contents = (0, smithy_client_1._json)(data);
726
- const response = {
727
- $metadata: deserializeMetadata(output),
728
- ...contents,
729
- };
730
- return response;
731
- };
732
- exports.de_CreateIPSetCommand = de_CreateIPSetCommand;
733
- const de_CreateIPSetCommandError = async (output, context) => {
734
- const parsedOutput = {
735
- ...output,
736
- body: await parseErrorBody(output.body, context),
737
- };
738
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
739
- switch (errorCode) {
740
- case "WAFDisallowedNameException":
741
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
742
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
743
- case "WAFInternalErrorException":
744
- case "com.amazonaws.wafregional#WAFInternalErrorException":
745
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
746
- case "WAFInvalidAccountException":
747
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
748
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
749
- case "WAFInvalidParameterException":
750
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
751
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
752
- case "WAFLimitsExceededException":
753
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
754
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
755
- case "WAFStaleDataException":
756
- case "com.amazonaws.wafregional#WAFStaleDataException":
757
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
758
- default:
759
- const parsedBody = parsedOutput.body;
760
- return throwDefaultError({
761
- output,
762
- parsedBody,
763
- errorCode,
764
- });
765
- }
766
- };
767
- const de_CreateRateBasedRuleCommand = async (output, context) => {
768
- if (output.statusCode >= 300) {
769
- return de_CreateRateBasedRuleCommandError(output, context);
770
- }
771
- const data = await parseBody(output.body, context);
772
- let contents = {};
773
- contents = (0, smithy_client_1._json)(data);
774
- const response = {
775
- $metadata: deserializeMetadata(output),
776
- ...contents,
777
- };
778
- return response;
779
- };
780
- exports.de_CreateRateBasedRuleCommand = de_CreateRateBasedRuleCommand;
781
- const de_CreateRateBasedRuleCommandError = async (output, context) => {
782
- const parsedOutput = {
783
- ...output,
784
- body: await parseErrorBody(output.body, context),
785
- };
786
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
787
- switch (errorCode) {
788
- case "WAFBadRequestException":
789
- case "com.amazonaws.wafregional#WAFBadRequestException":
790
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
791
- case "WAFDisallowedNameException":
792
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
793
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
794
- case "WAFInternalErrorException":
795
- case "com.amazonaws.wafregional#WAFInternalErrorException":
796
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
797
- case "WAFInvalidParameterException":
798
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
799
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
800
- case "WAFLimitsExceededException":
801
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
802
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
803
- case "WAFStaleDataException":
804
- case "com.amazonaws.wafregional#WAFStaleDataException":
805
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
806
- case "WAFTagOperationException":
807
- case "com.amazonaws.wafregional#WAFTagOperationException":
808
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
809
- case "WAFTagOperationInternalErrorException":
810
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
811
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
812
- default:
813
- const parsedBody = parsedOutput.body;
814
- return throwDefaultError({
815
- output,
816
- parsedBody,
817
- errorCode,
818
- });
819
- }
820
- };
821
- const de_CreateRegexMatchSetCommand = async (output, context) => {
822
- if (output.statusCode >= 300) {
823
- return de_CreateRegexMatchSetCommandError(output, context);
824
- }
825
- const data = await parseBody(output.body, context);
826
- let contents = {};
827
- contents = (0, smithy_client_1._json)(data);
828
- const response = {
829
- $metadata: deserializeMetadata(output),
830
- ...contents,
831
- };
832
- return response;
833
- };
834
- exports.de_CreateRegexMatchSetCommand = de_CreateRegexMatchSetCommand;
835
- const de_CreateRegexMatchSetCommandError = async (output, context) => {
836
- const parsedOutput = {
837
- ...output,
838
- body: await parseErrorBody(output.body, context),
839
- };
840
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
841
- switch (errorCode) {
842
- case "WAFDisallowedNameException":
843
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
844
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
845
- case "WAFInternalErrorException":
846
- case "com.amazonaws.wafregional#WAFInternalErrorException":
847
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
848
- case "WAFLimitsExceededException":
849
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
850
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
851
- case "WAFStaleDataException":
852
- case "com.amazonaws.wafregional#WAFStaleDataException":
853
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
854
- default:
855
- const parsedBody = parsedOutput.body;
856
- return throwDefaultError({
857
- output,
858
- parsedBody,
859
- errorCode,
860
- });
861
- }
862
- };
863
- const de_CreateRegexPatternSetCommand = async (output, context) => {
864
- if (output.statusCode >= 300) {
865
- return de_CreateRegexPatternSetCommandError(output, context);
866
- }
867
- const data = await parseBody(output.body, context);
868
- let contents = {};
869
- contents = (0, smithy_client_1._json)(data);
870
- const response = {
871
- $metadata: deserializeMetadata(output),
872
- ...contents,
873
- };
874
- return response;
875
- };
876
- exports.de_CreateRegexPatternSetCommand = de_CreateRegexPatternSetCommand;
877
- const de_CreateRegexPatternSetCommandError = async (output, context) => {
878
- const parsedOutput = {
879
- ...output,
880
- body: await parseErrorBody(output.body, context),
881
- };
882
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
883
- switch (errorCode) {
884
- case "WAFDisallowedNameException":
885
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
886
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
887
- case "WAFInternalErrorException":
888
- case "com.amazonaws.wafregional#WAFInternalErrorException":
889
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
890
- case "WAFLimitsExceededException":
891
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
892
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
893
- case "WAFStaleDataException":
894
- case "com.amazonaws.wafregional#WAFStaleDataException":
895
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
896
- default:
897
- const parsedBody = parsedOutput.body;
898
- return throwDefaultError({
899
- output,
900
- parsedBody,
901
- errorCode,
902
- });
903
- }
904
- };
905
- const de_CreateRuleCommand = async (output, context) => {
906
- if (output.statusCode >= 300) {
907
- return de_CreateRuleCommandError(output, context);
908
- }
909
- const data = await parseBody(output.body, context);
910
- let contents = {};
911
- contents = (0, smithy_client_1._json)(data);
912
- const response = {
913
- $metadata: deserializeMetadata(output),
914
- ...contents,
915
- };
916
- return response;
917
- };
918
- exports.de_CreateRuleCommand = de_CreateRuleCommand;
919
- const de_CreateRuleCommandError = async (output, context) => {
920
- const parsedOutput = {
921
- ...output,
922
- body: await parseErrorBody(output.body, context),
923
- };
924
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
925
- switch (errorCode) {
926
- case "WAFBadRequestException":
927
- case "com.amazonaws.wafregional#WAFBadRequestException":
928
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
929
- case "WAFDisallowedNameException":
930
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
931
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
932
- case "WAFInternalErrorException":
933
- case "com.amazonaws.wafregional#WAFInternalErrorException":
934
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
935
- case "WAFInvalidParameterException":
936
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
937
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
938
- case "WAFLimitsExceededException":
939
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
940
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
941
- case "WAFStaleDataException":
942
- case "com.amazonaws.wafregional#WAFStaleDataException":
943
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
944
- case "WAFTagOperationException":
945
- case "com.amazonaws.wafregional#WAFTagOperationException":
946
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
947
- case "WAFTagOperationInternalErrorException":
948
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
949
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
950
- default:
951
- const parsedBody = parsedOutput.body;
952
- return throwDefaultError({
953
- output,
954
- parsedBody,
955
- errorCode,
956
- });
957
- }
958
- };
959
- const de_CreateRuleGroupCommand = async (output, context) => {
960
- if (output.statusCode >= 300) {
961
- return de_CreateRuleGroupCommandError(output, context);
962
- }
963
- const data = await parseBody(output.body, context);
964
- let contents = {};
965
- contents = (0, smithy_client_1._json)(data);
966
- const response = {
967
- $metadata: deserializeMetadata(output),
968
- ...contents,
969
- };
970
- return response;
971
- };
972
- exports.de_CreateRuleGroupCommand = de_CreateRuleGroupCommand;
973
- const de_CreateRuleGroupCommandError = async (output, context) => {
974
- const parsedOutput = {
975
- ...output,
976
- body: await parseErrorBody(output.body, context),
977
- };
978
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
979
- switch (errorCode) {
980
- case "WAFBadRequestException":
981
- case "com.amazonaws.wafregional#WAFBadRequestException":
982
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
983
- case "WAFDisallowedNameException":
984
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
985
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
986
- case "WAFInternalErrorException":
987
- case "com.amazonaws.wafregional#WAFInternalErrorException":
988
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
989
- case "WAFLimitsExceededException":
990
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
991
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
992
- case "WAFStaleDataException":
993
- case "com.amazonaws.wafregional#WAFStaleDataException":
994
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
995
- case "WAFTagOperationException":
996
- case "com.amazonaws.wafregional#WAFTagOperationException":
997
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
998
- case "WAFTagOperationInternalErrorException":
999
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1000
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1001
- default:
1002
- const parsedBody = parsedOutput.body;
1003
- return throwDefaultError({
1004
- output,
1005
- parsedBody,
1006
- errorCode,
1007
- });
1008
- }
1009
- };
1010
- const de_CreateSizeConstraintSetCommand = async (output, context) => {
1011
- if (output.statusCode >= 300) {
1012
- return de_CreateSizeConstraintSetCommandError(output, context);
1013
- }
1014
- const data = await parseBody(output.body, context);
1015
- let contents = {};
1016
- contents = (0, smithy_client_1._json)(data);
1017
- const response = {
1018
- $metadata: deserializeMetadata(output),
1019
- ...contents,
1020
- };
1021
- return response;
1022
- };
1023
- exports.de_CreateSizeConstraintSetCommand = de_CreateSizeConstraintSetCommand;
1024
- const de_CreateSizeConstraintSetCommandError = async (output, context) => {
1025
- const parsedOutput = {
1026
- ...output,
1027
- body: await parseErrorBody(output.body, context),
1028
- };
1029
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1030
- switch (errorCode) {
1031
- case "WAFDisallowedNameException":
1032
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
1033
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
1034
- case "WAFInternalErrorException":
1035
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1036
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1037
- case "WAFInvalidAccountException":
1038
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1039
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1040
- case "WAFInvalidParameterException":
1041
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1042
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1043
- case "WAFLimitsExceededException":
1044
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
1045
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
1046
- case "WAFStaleDataException":
1047
- case "com.amazonaws.wafregional#WAFStaleDataException":
1048
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1049
- default:
1050
- const parsedBody = parsedOutput.body;
1051
- return throwDefaultError({
1052
- output,
1053
- parsedBody,
1054
- errorCode,
1055
- });
1056
- }
1057
- };
1058
- const de_CreateSqlInjectionMatchSetCommand = async (output, context) => {
1059
- if (output.statusCode >= 300) {
1060
- return de_CreateSqlInjectionMatchSetCommandError(output, context);
1061
- }
1062
- const data = await parseBody(output.body, context);
1063
- let contents = {};
1064
- contents = (0, smithy_client_1._json)(data);
1065
- const response = {
1066
- $metadata: deserializeMetadata(output),
1067
- ...contents,
1068
- };
1069
- return response;
1070
- };
1071
- exports.de_CreateSqlInjectionMatchSetCommand = de_CreateSqlInjectionMatchSetCommand;
1072
- const de_CreateSqlInjectionMatchSetCommandError = async (output, context) => {
1073
- const parsedOutput = {
1074
- ...output,
1075
- body: await parseErrorBody(output.body, context),
1076
- };
1077
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1078
- switch (errorCode) {
1079
- case "WAFDisallowedNameException":
1080
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
1081
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
1082
- case "WAFInternalErrorException":
1083
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1084
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1085
- case "WAFInvalidAccountException":
1086
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1087
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1088
- case "WAFInvalidParameterException":
1089
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1090
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1091
- case "WAFLimitsExceededException":
1092
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
1093
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
1094
- case "WAFStaleDataException":
1095
- case "com.amazonaws.wafregional#WAFStaleDataException":
1096
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1097
- default:
1098
- const parsedBody = parsedOutput.body;
1099
- return throwDefaultError({
1100
- output,
1101
- parsedBody,
1102
- errorCode,
1103
- });
1104
- }
1105
- };
1106
- const de_CreateWebACLCommand = async (output, context) => {
1107
- if (output.statusCode >= 300) {
1108
- return de_CreateWebACLCommandError(output, context);
1109
- }
1110
- const data = await parseBody(output.body, context);
1111
- let contents = {};
1112
- contents = (0, smithy_client_1._json)(data);
1113
- const response = {
1114
- $metadata: deserializeMetadata(output),
1115
- ...contents,
1116
- };
1117
- return response;
1118
- };
1119
- exports.de_CreateWebACLCommand = de_CreateWebACLCommand;
1120
- const de_CreateWebACLCommandError = async (output, context) => {
1121
- const parsedOutput = {
1122
- ...output,
1123
- body: await parseErrorBody(output.body, context),
1124
- };
1125
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1126
- switch (errorCode) {
1127
- case "WAFBadRequestException":
1128
- case "com.amazonaws.wafregional#WAFBadRequestException":
1129
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
1130
- case "WAFDisallowedNameException":
1131
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
1132
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
1133
- case "WAFInternalErrorException":
1134
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1135
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1136
- case "WAFInvalidAccountException":
1137
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1138
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1139
- case "WAFInvalidParameterException":
1140
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1141
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1142
- case "WAFLimitsExceededException":
1143
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
1144
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
1145
- case "WAFStaleDataException":
1146
- case "com.amazonaws.wafregional#WAFStaleDataException":
1147
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1148
- case "WAFTagOperationException":
1149
- case "com.amazonaws.wafregional#WAFTagOperationException":
1150
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
1151
- case "WAFTagOperationInternalErrorException":
1152
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1153
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1154
- default:
1155
- const parsedBody = parsedOutput.body;
1156
- return throwDefaultError({
1157
- output,
1158
- parsedBody,
1159
- errorCode,
1160
- });
1161
- }
1162
- };
1163
- const de_CreateWebACLMigrationStackCommand = async (output, context) => {
1164
- if (output.statusCode >= 300) {
1165
- return de_CreateWebACLMigrationStackCommandError(output, context);
1166
- }
1167
- const data = await parseBody(output.body, context);
1168
- let contents = {};
1169
- contents = (0, smithy_client_1._json)(data);
1170
- const response = {
1171
- $metadata: deserializeMetadata(output),
1172
- ...contents,
1173
- };
1174
- return response;
1175
- };
1176
- exports.de_CreateWebACLMigrationStackCommand = de_CreateWebACLMigrationStackCommand;
1177
- const de_CreateWebACLMigrationStackCommandError = async (output, context) => {
1178
- const parsedOutput = {
1179
- ...output,
1180
- body: await parseErrorBody(output.body, context),
1181
- };
1182
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1183
- switch (errorCode) {
1184
- case "WAFEntityMigrationException":
1185
- case "com.amazonaws.wafregional#WAFEntityMigrationException":
1186
- throw await de_WAFEntityMigrationExceptionRes(parsedOutput, context);
1187
- case "WAFInternalErrorException":
1188
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1189
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1190
- case "WAFInvalidOperationException":
1191
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
1192
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
1193
- case "WAFInvalidParameterException":
1194
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1195
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1196
- case "WAFNonexistentItemException":
1197
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1198
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1199
- default:
1200
- const parsedBody = parsedOutput.body;
1201
- return throwDefaultError({
1202
- output,
1203
- parsedBody,
1204
- errorCode,
1205
- });
1206
- }
1207
- };
1208
- const de_CreateXssMatchSetCommand = async (output, context) => {
1209
- if (output.statusCode >= 300) {
1210
- return de_CreateXssMatchSetCommandError(output, context);
1211
- }
1212
- const data = await parseBody(output.body, context);
1213
- let contents = {};
1214
- contents = (0, smithy_client_1._json)(data);
1215
- const response = {
1216
- $metadata: deserializeMetadata(output),
1217
- ...contents,
1218
- };
1219
- return response;
1220
- };
1221
- exports.de_CreateXssMatchSetCommand = de_CreateXssMatchSetCommand;
1222
- const de_CreateXssMatchSetCommandError = async (output, context) => {
1223
- const parsedOutput = {
1224
- ...output,
1225
- body: await parseErrorBody(output.body, context),
1226
- };
1227
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1228
- switch (errorCode) {
1229
- case "WAFDisallowedNameException":
1230
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
1231
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
1232
- case "WAFInternalErrorException":
1233
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1234
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1235
- case "WAFInvalidAccountException":
1236
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1237
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1238
- case "WAFInvalidParameterException":
1239
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1240
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1241
- case "WAFLimitsExceededException":
1242
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
1243
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
1244
- case "WAFStaleDataException":
1245
- case "com.amazonaws.wafregional#WAFStaleDataException":
1246
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1247
- default:
1248
- const parsedBody = parsedOutput.body;
1249
- return throwDefaultError({
1250
- output,
1251
- parsedBody,
1252
- errorCode,
1253
- });
1254
- }
1255
- };
1256
- const de_DeleteByteMatchSetCommand = async (output, context) => {
1257
- if (output.statusCode >= 300) {
1258
- return de_DeleteByteMatchSetCommandError(output, context);
1259
- }
1260
- const data = await parseBody(output.body, context);
1261
- let contents = {};
1262
- contents = (0, smithy_client_1._json)(data);
1263
- const response = {
1264
- $metadata: deserializeMetadata(output),
1265
- ...contents,
1266
- };
1267
- return response;
1268
- };
1269
- exports.de_DeleteByteMatchSetCommand = de_DeleteByteMatchSetCommand;
1270
- const de_DeleteByteMatchSetCommandError = async (output, context) => {
1271
- const parsedOutput = {
1272
- ...output,
1273
- body: await parseErrorBody(output.body, context),
1274
- };
1275
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1276
- switch (errorCode) {
1277
- case "WAFInternalErrorException":
1278
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1279
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1280
- case "WAFInvalidAccountException":
1281
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1282
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1283
- case "WAFNonEmptyEntityException":
1284
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1285
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1286
- case "WAFNonexistentItemException":
1287
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1288
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1289
- case "WAFReferencedItemException":
1290
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1291
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1292
- case "WAFStaleDataException":
1293
- case "com.amazonaws.wafregional#WAFStaleDataException":
1294
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1295
- default:
1296
- const parsedBody = parsedOutput.body;
1297
- return throwDefaultError({
1298
- output,
1299
- parsedBody,
1300
- errorCode,
1301
- });
1302
- }
1303
- };
1304
- const de_DeleteGeoMatchSetCommand = async (output, context) => {
1305
- if (output.statusCode >= 300) {
1306
- return de_DeleteGeoMatchSetCommandError(output, context);
1307
- }
1308
- const data = await parseBody(output.body, context);
1309
- let contents = {};
1310
- contents = (0, smithy_client_1._json)(data);
1311
- const response = {
1312
- $metadata: deserializeMetadata(output),
1313
- ...contents,
1314
- };
1315
- return response;
1316
- };
1317
- exports.de_DeleteGeoMatchSetCommand = de_DeleteGeoMatchSetCommand;
1318
- const de_DeleteGeoMatchSetCommandError = async (output, context) => {
1319
- const parsedOutput = {
1320
- ...output,
1321
- body: await parseErrorBody(output.body, context),
1322
- };
1323
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1324
- switch (errorCode) {
1325
- case "WAFInternalErrorException":
1326
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1327
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1328
- case "WAFInvalidAccountException":
1329
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1330
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1331
- case "WAFNonEmptyEntityException":
1332
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1333
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1334
- case "WAFNonexistentItemException":
1335
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1336
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1337
- case "WAFReferencedItemException":
1338
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1339
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1340
- case "WAFStaleDataException":
1341
- case "com.amazonaws.wafregional#WAFStaleDataException":
1342
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1343
- default:
1344
- const parsedBody = parsedOutput.body;
1345
- return throwDefaultError({
1346
- output,
1347
- parsedBody,
1348
- errorCode,
1349
- });
1350
- }
1351
- };
1352
- const de_DeleteIPSetCommand = async (output, context) => {
1353
- if (output.statusCode >= 300) {
1354
- return de_DeleteIPSetCommandError(output, context);
1355
- }
1356
- const data = await parseBody(output.body, context);
1357
- let contents = {};
1358
- contents = (0, smithy_client_1._json)(data);
1359
- const response = {
1360
- $metadata: deserializeMetadata(output),
1361
- ...contents,
1362
- };
1363
- return response;
1364
- };
1365
- exports.de_DeleteIPSetCommand = de_DeleteIPSetCommand;
1366
- const de_DeleteIPSetCommandError = async (output, context) => {
1367
- const parsedOutput = {
1368
- ...output,
1369
- body: await parseErrorBody(output.body, context),
1370
- };
1371
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1372
- switch (errorCode) {
1373
- case "WAFInternalErrorException":
1374
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1375
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1376
- case "WAFInvalidAccountException":
1377
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1378
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1379
- case "WAFNonEmptyEntityException":
1380
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1381
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1382
- case "WAFNonexistentItemException":
1383
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1384
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1385
- case "WAFReferencedItemException":
1386
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1387
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1388
- case "WAFStaleDataException":
1389
- case "com.amazonaws.wafregional#WAFStaleDataException":
1390
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1391
- default:
1392
- const parsedBody = parsedOutput.body;
1393
- return throwDefaultError({
1394
- output,
1395
- parsedBody,
1396
- errorCode,
1397
- });
1398
- }
1399
- };
1400
- const de_DeleteLoggingConfigurationCommand = async (output, context) => {
1401
- if (output.statusCode >= 300) {
1402
- return de_DeleteLoggingConfigurationCommandError(output, context);
1403
- }
1404
- const data = await parseBody(output.body, context);
1405
- let contents = {};
1406
- contents = (0, smithy_client_1._json)(data);
1407
- const response = {
1408
- $metadata: deserializeMetadata(output),
1409
- ...contents,
1410
- };
1411
- return response;
1412
- };
1413
- exports.de_DeleteLoggingConfigurationCommand = de_DeleteLoggingConfigurationCommand;
1414
- const de_DeleteLoggingConfigurationCommandError = async (output, context) => {
1415
- const parsedOutput = {
1416
- ...output,
1417
- body: await parseErrorBody(output.body, context),
1418
- };
1419
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1420
- switch (errorCode) {
1421
- case "WAFInternalErrorException":
1422
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1423
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1424
- case "WAFNonexistentItemException":
1425
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1426
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1427
- case "WAFStaleDataException":
1428
- case "com.amazonaws.wafregional#WAFStaleDataException":
1429
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1430
- default:
1431
- const parsedBody = parsedOutput.body;
1432
- return throwDefaultError({
1433
- output,
1434
- parsedBody,
1435
- errorCode,
1436
- });
1437
- }
1438
- };
1439
- const de_DeletePermissionPolicyCommand = async (output, context) => {
1440
- if (output.statusCode >= 300) {
1441
- return de_DeletePermissionPolicyCommandError(output, context);
1442
- }
1443
- const data = await parseBody(output.body, context);
1444
- let contents = {};
1445
- contents = (0, smithy_client_1._json)(data);
1446
- const response = {
1447
- $metadata: deserializeMetadata(output),
1448
- ...contents,
1449
- };
1450
- return response;
1451
- };
1452
- exports.de_DeletePermissionPolicyCommand = de_DeletePermissionPolicyCommand;
1453
- const de_DeletePermissionPolicyCommandError = async (output, context) => {
1454
- const parsedOutput = {
1455
- ...output,
1456
- body: await parseErrorBody(output.body, context),
1457
- };
1458
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1459
- switch (errorCode) {
1460
- case "WAFInternalErrorException":
1461
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1462
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1463
- case "WAFNonexistentItemException":
1464
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1465
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1466
- case "WAFStaleDataException":
1467
- case "com.amazonaws.wafregional#WAFStaleDataException":
1468
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1469
- default:
1470
- const parsedBody = parsedOutput.body;
1471
- return throwDefaultError({
1472
- output,
1473
- parsedBody,
1474
- errorCode,
1475
- });
1476
- }
1477
- };
1478
- const de_DeleteRateBasedRuleCommand = async (output, context) => {
1479
- if (output.statusCode >= 300) {
1480
- return de_DeleteRateBasedRuleCommandError(output, context);
1481
- }
1482
- const data = await parseBody(output.body, context);
1483
- let contents = {};
1484
- contents = (0, smithy_client_1._json)(data);
1485
- const response = {
1486
- $metadata: deserializeMetadata(output),
1487
- ...contents,
1488
- };
1489
- return response;
1490
- };
1491
- exports.de_DeleteRateBasedRuleCommand = de_DeleteRateBasedRuleCommand;
1492
- const de_DeleteRateBasedRuleCommandError = async (output, context) => {
1493
- const parsedOutput = {
1494
- ...output,
1495
- body: await parseErrorBody(output.body, context),
1496
- };
1497
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1498
- switch (errorCode) {
1499
- case "WAFInternalErrorException":
1500
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1501
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1502
- case "WAFInvalidAccountException":
1503
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1504
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1505
- case "WAFNonEmptyEntityException":
1506
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1507
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1508
- case "WAFNonexistentItemException":
1509
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1510
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1511
- case "WAFReferencedItemException":
1512
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1513
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1514
- case "WAFStaleDataException":
1515
- case "com.amazonaws.wafregional#WAFStaleDataException":
1516
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1517
- case "WAFTagOperationException":
1518
- case "com.amazonaws.wafregional#WAFTagOperationException":
1519
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
1520
- case "WAFTagOperationInternalErrorException":
1521
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1522
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1523
- default:
1524
- const parsedBody = parsedOutput.body;
1525
- return throwDefaultError({
1526
- output,
1527
- parsedBody,
1528
- errorCode,
1529
- });
1530
- }
1531
- };
1532
- const de_DeleteRegexMatchSetCommand = async (output, context) => {
1533
- if (output.statusCode >= 300) {
1534
- return de_DeleteRegexMatchSetCommandError(output, context);
1535
- }
1536
- const data = await parseBody(output.body, context);
1537
- let contents = {};
1538
- contents = (0, smithy_client_1._json)(data);
1539
- const response = {
1540
- $metadata: deserializeMetadata(output),
1541
- ...contents,
1542
- };
1543
- return response;
1544
- };
1545
- exports.de_DeleteRegexMatchSetCommand = de_DeleteRegexMatchSetCommand;
1546
- const de_DeleteRegexMatchSetCommandError = async (output, context) => {
1547
- const parsedOutput = {
1548
- ...output,
1549
- body: await parseErrorBody(output.body, context),
1550
- };
1551
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1552
- switch (errorCode) {
1553
- case "WAFInternalErrorException":
1554
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1555
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1556
- case "WAFInvalidAccountException":
1557
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1558
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1559
- case "WAFNonEmptyEntityException":
1560
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1561
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1562
- case "WAFNonexistentItemException":
1563
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1564
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1565
- case "WAFReferencedItemException":
1566
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1567
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1568
- case "WAFStaleDataException":
1569
- case "com.amazonaws.wafregional#WAFStaleDataException":
1570
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1571
- default:
1572
- const parsedBody = parsedOutput.body;
1573
- return throwDefaultError({
1574
- output,
1575
- parsedBody,
1576
- errorCode,
1577
- });
1578
- }
1579
- };
1580
- const de_DeleteRegexPatternSetCommand = async (output, context) => {
1581
- if (output.statusCode >= 300) {
1582
- return de_DeleteRegexPatternSetCommandError(output, context);
1583
- }
1584
- const data = await parseBody(output.body, context);
1585
- let contents = {};
1586
- contents = (0, smithy_client_1._json)(data);
1587
- const response = {
1588
- $metadata: deserializeMetadata(output),
1589
- ...contents,
1590
- };
1591
- return response;
1592
- };
1593
- exports.de_DeleteRegexPatternSetCommand = de_DeleteRegexPatternSetCommand;
1594
- const de_DeleteRegexPatternSetCommandError = async (output, context) => {
1595
- const parsedOutput = {
1596
- ...output,
1597
- body: await parseErrorBody(output.body, context),
1598
- };
1599
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1600
- switch (errorCode) {
1601
- case "WAFInternalErrorException":
1602
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1603
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1604
- case "WAFInvalidAccountException":
1605
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1606
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1607
- case "WAFNonEmptyEntityException":
1608
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1609
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1610
- case "WAFNonexistentItemException":
1611
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1612
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1613
- case "WAFReferencedItemException":
1614
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1615
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1616
- case "WAFStaleDataException":
1617
- case "com.amazonaws.wafregional#WAFStaleDataException":
1618
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1619
- default:
1620
- const parsedBody = parsedOutput.body;
1621
- return throwDefaultError({
1622
- output,
1623
- parsedBody,
1624
- errorCode,
1625
- });
1626
- }
1627
- };
1628
- const de_DeleteRuleCommand = async (output, context) => {
1629
- if (output.statusCode >= 300) {
1630
- return de_DeleteRuleCommandError(output, context);
1631
- }
1632
- const data = await parseBody(output.body, context);
1633
- let contents = {};
1634
- contents = (0, smithy_client_1._json)(data);
1635
- const response = {
1636
- $metadata: deserializeMetadata(output),
1637
- ...contents,
1638
- };
1639
- return response;
1640
- };
1641
- exports.de_DeleteRuleCommand = de_DeleteRuleCommand;
1642
- const de_DeleteRuleCommandError = async (output, context) => {
1643
- const parsedOutput = {
1644
- ...output,
1645
- body: await parseErrorBody(output.body, context),
1646
- };
1647
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1648
- switch (errorCode) {
1649
- case "WAFInternalErrorException":
1650
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1651
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1652
- case "WAFInvalidAccountException":
1653
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1654
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1655
- case "WAFNonEmptyEntityException":
1656
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1657
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1658
- case "WAFNonexistentItemException":
1659
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1660
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1661
- case "WAFReferencedItemException":
1662
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1663
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1664
- case "WAFStaleDataException":
1665
- case "com.amazonaws.wafregional#WAFStaleDataException":
1666
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1667
- case "WAFTagOperationException":
1668
- case "com.amazonaws.wafregional#WAFTagOperationException":
1669
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
1670
- case "WAFTagOperationInternalErrorException":
1671
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1672
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1673
- default:
1674
- const parsedBody = parsedOutput.body;
1675
- return throwDefaultError({
1676
- output,
1677
- parsedBody,
1678
- errorCode,
1679
- });
1680
- }
1681
- };
1682
- const de_DeleteRuleGroupCommand = async (output, context) => {
1683
- if (output.statusCode >= 300) {
1684
- return de_DeleteRuleGroupCommandError(output, context);
1685
- }
1686
- const data = await parseBody(output.body, context);
1687
- let contents = {};
1688
- contents = (0, smithy_client_1._json)(data);
1689
- const response = {
1690
- $metadata: deserializeMetadata(output),
1691
- ...contents,
1692
- };
1693
- return response;
1694
- };
1695
- exports.de_DeleteRuleGroupCommand = de_DeleteRuleGroupCommand;
1696
- const de_DeleteRuleGroupCommandError = async (output, context) => {
1697
- const parsedOutput = {
1698
- ...output,
1699
- body: await parseErrorBody(output.body, context),
1700
- };
1701
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1702
- switch (errorCode) {
1703
- case "WAFInternalErrorException":
1704
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1705
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1706
- case "WAFInvalidOperationException":
1707
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
1708
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
1709
- case "WAFNonEmptyEntityException":
1710
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1711
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1712
- case "WAFNonexistentItemException":
1713
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1714
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1715
- case "WAFReferencedItemException":
1716
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1717
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1718
- case "WAFStaleDataException":
1719
- case "com.amazonaws.wafregional#WAFStaleDataException":
1720
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1721
- case "WAFTagOperationException":
1722
- case "com.amazonaws.wafregional#WAFTagOperationException":
1723
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
1724
- case "WAFTagOperationInternalErrorException":
1725
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1726
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1727
- default:
1728
- const parsedBody = parsedOutput.body;
1729
- return throwDefaultError({
1730
- output,
1731
- parsedBody,
1732
- errorCode,
1733
- });
1734
- }
1735
- };
1736
- const de_DeleteSizeConstraintSetCommand = async (output, context) => {
1737
- if (output.statusCode >= 300) {
1738
- return de_DeleteSizeConstraintSetCommandError(output, context);
1739
- }
1740
- const data = await parseBody(output.body, context);
1741
- let contents = {};
1742
- contents = (0, smithy_client_1._json)(data);
1743
- const response = {
1744
- $metadata: deserializeMetadata(output),
1745
- ...contents,
1746
- };
1747
- return response;
1748
- };
1749
- exports.de_DeleteSizeConstraintSetCommand = de_DeleteSizeConstraintSetCommand;
1750
- const de_DeleteSizeConstraintSetCommandError = async (output, context) => {
1751
- const parsedOutput = {
1752
- ...output,
1753
- body: await parseErrorBody(output.body, context),
1754
- };
1755
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1756
- switch (errorCode) {
1757
- case "WAFInternalErrorException":
1758
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1759
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1760
- case "WAFInvalidAccountException":
1761
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1762
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1763
- case "WAFNonEmptyEntityException":
1764
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1765
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1766
- case "WAFNonexistentItemException":
1767
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1768
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1769
- case "WAFReferencedItemException":
1770
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1771
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1772
- case "WAFStaleDataException":
1773
- case "com.amazonaws.wafregional#WAFStaleDataException":
1774
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1775
- default:
1776
- const parsedBody = parsedOutput.body;
1777
- return throwDefaultError({
1778
- output,
1779
- parsedBody,
1780
- errorCode,
1781
- });
1782
- }
1783
- };
1784
- const de_DeleteSqlInjectionMatchSetCommand = async (output, context) => {
1785
- if (output.statusCode >= 300) {
1786
- return de_DeleteSqlInjectionMatchSetCommandError(output, context);
1787
- }
1788
- const data = await parseBody(output.body, context);
1789
- let contents = {};
1790
- contents = (0, smithy_client_1._json)(data);
1791
- const response = {
1792
- $metadata: deserializeMetadata(output),
1793
- ...contents,
1794
- };
1795
- return response;
1796
- };
1797
- exports.de_DeleteSqlInjectionMatchSetCommand = de_DeleteSqlInjectionMatchSetCommand;
1798
- const de_DeleteSqlInjectionMatchSetCommandError = async (output, context) => {
1799
- const parsedOutput = {
1800
- ...output,
1801
- body: await parseErrorBody(output.body, context),
1802
- };
1803
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1804
- switch (errorCode) {
1805
- case "WAFInternalErrorException":
1806
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1807
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1808
- case "WAFInvalidAccountException":
1809
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1810
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1811
- case "WAFNonEmptyEntityException":
1812
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1813
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1814
- case "WAFNonexistentItemException":
1815
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1816
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1817
- case "WAFReferencedItemException":
1818
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1819
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1820
- case "WAFStaleDataException":
1821
- case "com.amazonaws.wafregional#WAFStaleDataException":
1822
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1823
- default:
1824
- const parsedBody = parsedOutput.body;
1825
- return throwDefaultError({
1826
- output,
1827
- parsedBody,
1828
- errorCode,
1829
- });
1830
- }
1831
- };
1832
- const de_DeleteWebACLCommand = async (output, context) => {
1833
- if (output.statusCode >= 300) {
1834
- return de_DeleteWebACLCommandError(output, context);
1835
- }
1836
- const data = await parseBody(output.body, context);
1837
- let contents = {};
1838
- contents = (0, smithy_client_1._json)(data);
1839
- const response = {
1840
- $metadata: deserializeMetadata(output),
1841
- ...contents,
1842
- };
1843
- return response;
1844
- };
1845
- exports.de_DeleteWebACLCommand = de_DeleteWebACLCommand;
1846
- const de_DeleteWebACLCommandError = async (output, context) => {
1847
- const parsedOutput = {
1848
- ...output,
1849
- body: await parseErrorBody(output.body, context),
1850
- };
1851
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1852
- switch (errorCode) {
1853
- case "WAFInternalErrorException":
1854
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1855
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1856
- case "WAFInvalidAccountException":
1857
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1858
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1859
- case "WAFNonEmptyEntityException":
1860
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1861
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1862
- case "WAFNonexistentItemException":
1863
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1864
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1865
- case "WAFReferencedItemException":
1866
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1867
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1868
- case "WAFStaleDataException":
1869
- case "com.amazonaws.wafregional#WAFStaleDataException":
1870
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1871
- case "WAFTagOperationException":
1872
- case "com.amazonaws.wafregional#WAFTagOperationException":
1873
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
1874
- case "WAFTagOperationInternalErrorException":
1875
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
1876
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
1877
- default:
1878
- const parsedBody = parsedOutput.body;
1879
- return throwDefaultError({
1880
- output,
1881
- parsedBody,
1882
- errorCode,
1883
- });
1884
- }
1885
- };
1886
- const de_DeleteXssMatchSetCommand = async (output, context) => {
1887
- if (output.statusCode >= 300) {
1888
- return de_DeleteXssMatchSetCommandError(output, context);
1889
- }
1890
- const data = await parseBody(output.body, context);
1891
- let contents = {};
1892
- contents = (0, smithy_client_1._json)(data);
1893
- const response = {
1894
- $metadata: deserializeMetadata(output),
1895
- ...contents,
1896
- };
1897
- return response;
1898
- };
1899
- exports.de_DeleteXssMatchSetCommand = de_DeleteXssMatchSetCommand;
1900
- const de_DeleteXssMatchSetCommandError = async (output, context) => {
1901
- const parsedOutput = {
1902
- ...output,
1903
- body: await parseErrorBody(output.body, context),
1904
- };
1905
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1906
- switch (errorCode) {
1907
- case "WAFInternalErrorException":
1908
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1909
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1910
- case "WAFInvalidAccountException":
1911
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1912
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1913
- case "WAFNonEmptyEntityException":
1914
- case "com.amazonaws.wafregional#WAFNonEmptyEntityException":
1915
- throw await de_WAFNonEmptyEntityExceptionRes(parsedOutput, context);
1916
- case "WAFNonexistentItemException":
1917
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1918
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1919
- case "WAFReferencedItemException":
1920
- case "com.amazonaws.wafregional#WAFReferencedItemException":
1921
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
1922
- case "WAFStaleDataException":
1923
- case "com.amazonaws.wafregional#WAFStaleDataException":
1924
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
1925
- default:
1926
- const parsedBody = parsedOutput.body;
1927
- return throwDefaultError({
1928
- output,
1929
- parsedBody,
1930
- errorCode,
1931
- });
1932
- }
1933
- };
1934
- const de_DisassociateWebACLCommand = async (output, context) => {
1935
- if (output.statusCode >= 300) {
1936
- return de_DisassociateWebACLCommandError(output, context);
1937
- }
1938
- const data = await parseBody(output.body, context);
1939
- let contents = {};
1940
- contents = (0, smithy_client_1._json)(data);
1941
- const response = {
1942
- $metadata: deserializeMetadata(output),
1943
- ...contents,
1944
- };
1945
- return response;
1946
- };
1947
- exports.de_DisassociateWebACLCommand = de_DisassociateWebACLCommand;
1948
- const de_DisassociateWebACLCommandError = async (output, context) => {
1949
- const parsedOutput = {
1950
- ...output,
1951
- body: await parseErrorBody(output.body, context),
1952
- };
1953
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1954
- switch (errorCode) {
1955
- case "WAFInternalErrorException":
1956
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1957
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
1958
- case "WAFInvalidAccountException":
1959
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
1960
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
1961
- case "WAFInvalidParameterException":
1962
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
1963
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
1964
- case "WAFNonexistentItemException":
1965
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
1966
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
1967
- default:
1968
- const parsedBody = parsedOutput.body;
1969
- return throwDefaultError({
1970
- output,
1971
- parsedBody,
1972
- errorCode,
1973
- });
1974
- }
1975
- };
1976
- const de_GetByteMatchSetCommand = async (output, context) => {
1977
- if (output.statusCode >= 300) {
1978
- return de_GetByteMatchSetCommandError(output, context);
1979
- }
1980
- const data = await parseBody(output.body, context);
1981
- let contents = {};
1982
- contents = de_GetByteMatchSetResponse(data, context);
1983
- const response = {
1984
- $metadata: deserializeMetadata(output),
1985
- ...contents,
1986
- };
1987
- return response;
1988
- };
1989
- exports.de_GetByteMatchSetCommand = de_GetByteMatchSetCommand;
1990
- const de_GetByteMatchSetCommandError = async (output, context) => {
1991
- const parsedOutput = {
1992
- ...output,
1993
- body: await parseErrorBody(output.body, context),
1994
- };
1995
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1996
- switch (errorCode) {
1997
- case "WAFInternalErrorException":
1998
- case "com.amazonaws.wafregional#WAFInternalErrorException":
1999
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2000
- case "WAFInvalidAccountException":
2001
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2002
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2003
- case "WAFNonexistentItemException":
2004
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2005
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2006
- default:
2007
- const parsedBody = parsedOutput.body;
2008
- return throwDefaultError({
2009
- output,
2010
- parsedBody,
2011
- errorCode,
2012
- });
2013
- }
2014
- };
2015
- const de_GetChangeTokenCommand = async (output, context) => {
2016
- if (output.statusCode >= 300) {
2017
- return de_GetChangeTokenCommandError(output, context);
2018
- }
2019
- const data = await parseBody(output.body, context);
2020
- let contents = {};
2021
- contents = (0, smithy_client_1._json)(data);
2022
- const response = {
2023
- $metadata: deserializeMetadata(output),
2024
- ...contents,
2025
- };
2026
- return response;
2027
- };
2028
- exports.de_GetChangeTokenCommand = de_GetChangeTokenCommand;
2029
- const de_GetChangeTokenCommandError = async (output, context) => {
2030
- const parsedOutput = {
2031
- ...output,
2032
- body: await parseErrorBody(output.body, context),
2033
- };
2034
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2035
- switch (errorCode) {
2036
- case "WAFInternalErrorException":
2037
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2038
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2039
- default:
2040
- const parsedBody = parsedOutput.body;
2041
- return throwDefaultError({
2042
- output,
2043
- parsedBody,
2044
- errorCode,
2045
- });
2046
- }
2047
- };
2048
- const de_GetChangeTokenStatusCommand = async (output, context) => {
2049
- if (output.statusCode >= 300) {
2050
- return de_GetChangeTokenStatusCommandError(output, context);
2051
- }
2052
- const data = await parseBody(output.body, context);
2053
- let contents = {};
2054
- contents = (0, smithy_client_1._json)(data);
2055
- const response = {
2056
- $metadata: deserializeMetadata(output),
2057
- ...contents,
2058
- };
2059
- return response;
2060
- };
2061
- exports.de_GetChangeTokenStatusCommand = de_GetChangeTokenStatusCommand;
2062
- const de_GetChangeTokenStatusCommandError = async (output, context) => {
2063
- const parsedOutput = {
2064
- ...output,
2065
- body: await parseErrorBody(output.body, context),
2066
- };
2067
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2068
- switch (errorCode) {
2069
- case "WAFInternalErrorException":
2070
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2071
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2072
- case "WAFNonexistentItemException":
2073
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2074
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2075
- default:
2076
- const parsedBody = parsedOutput.body;
2077
- return throwDefaultError({
2078
- output,
2079
- parsedBody,
2080
- errorCode,
2081
- });
2082
- }
2083
- };
2084
- const de_GetGeoMatchSetCommand = async (output, context) => {
2085
- if (output.statusCode >= 300) {
2086
- return de_GetGeoMatchSetCommandError(output, context);
2087
- }
2088
- const data = await parseBody(output.body, context);
2089
- let contents = {};
2090
- contents = (0, smithy_client_1._json)(data);
2091
- const response = {
2092
- $metadata: deserializeMetadata(output),
2093
- ...contents,
2094
- };
2095
- return response;
2096
- };
2097
- exports.de_GetGeoMatchSetCommand = de_GetGeoMatchSetCommand;
2098
- const de_GetGeoMatchSetCommandError = async (output, context) => {
2099
- const parsedOutput = {
2100
- ...output,
2101
- body: await parseErrorBody(output.body, context),
2102
- };
2103
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2104
- switch (errorCode) {
2105
- case "WAFInternalErrorException":
2106
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2107
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2108
- case "WAFInvalidAccountException":
2109
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2110
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2111
- case "WAFNonexistentItemException":
2112
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2113
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2114
- default:
2115
- const parsedBody = parsedOutput.body;
2116
- return throwDefaultError({
2117
- output,
2118
- parsedBody,
2119
- errorCode,
2120
- });
2121
- }
2122
- };
2123
- const de_GetIPSetCommand = async (output, context) => {
2124
- if (output.statusCode >= 300) {
2125
- return de_GetIPSetCommandError(output, context);
2126
- }
2127
- const data = await parseBody(output.body, context);
2128
- let contents = {};
2129
- contents = (0, smithy_client_1._json)(data);
2130
- const response = {
2131
- $metadata: deserializeMetadata(output),
2132
- ...contents,
2133
- };
2134
- return response;
2135
- };
2136
- exports.de_GetIPSetCommand = de_GetIPSetCommand;
2137
- const de_GetIPSetCommandError = async (output, context) => {
2138
- const parsedOutput = {
2139
- ...output,
2140
- body: await parseErrorBody(output.body, context),
2141
- };
2142
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2143
- switch (errorCode) {
2144
- case "WAFInternalErrorException":
2145
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2146
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2147
- case "WAFInvalidAccountException":
2148
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2149
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2150
- case "WAFNonexistentItemException":
2151
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2152
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2153
- default:
2154
- const parsedBody = parsedOutput.body;
2155
- return throwDefaultError({
2156
- output,
2157
- parsedBody,
2158
- errorCode,
2159
- });
2160
- }
2161
- };
2162
- const de_GetLoggingConfigurationCommand = async (output, context) => {
2163
- if (output.statusCode >= 300) {
2164
- return de_GetLoggingConfigurationCommandError(output, context);
2165
- }
2166
- const data = await parseBody(output.body, context);
2167
- let contents = {};
2168
- contents = (0, smithy_client_1._json)(data);
2169
- const response = {
2170
- $metadata: deserializeMetadata(output),
2171
- ...contents,
2172
- };
2173
- return response;
2174
- };
2175
- exports.de_GetLoggingConfigurationCommand = de_GetLoggingConfigurationCommand;
2176
- const de_GetLoggingConfigurationCommandError = async (output, context) => {
2177
- const parsedOutput = {
2178
- ...output,
2179
- body: await parseErrorBody(output.body, context),
2180
- };
2181
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2182
- switch (errorCode) {
2183
- case "WAFInternalErrorException":
2184
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2185
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2186
- case "WAFNonexistentItemException":
2187
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2188
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2189
- default:
2190
- const parsedBody = parsedOutput.body;
2191
- return throwDefaultError({
2192
- output,
2193
- parsedBody,
2194
- errorCode,
2195
- });
2196
- }
2197
- };
2198
- const de_GetPermissionPolicyCommand = async (output, context) => {
2199
- if (output.statusCode >= 300) {
2200
- return de_GetPermissionPolicyCommandError(output, context);
2201
- }
2202
- const data = await parseBody(output.body, context);
2203
- let contents = {};
2204
- contents = (0, smithy_client_1._json)(data);
2205
- const response = {
2206
- $metadata: deserializeMetadata(output),
2207
- ...contents,
2208
- };
2209
- return response;
2210
- };
2211
- exports.de_GetPermissionPolicyCommand = de_GetPermissionPolicyCommand;
2212
- const de_GetPermissionPolicyCommandError = async (output, context) => {
2213
- const parsedOutput = {
2214
- ...output,
2215
- body: await parseErrorBody(output.body, context),
2216
- };
2217
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2218
- switch (errorCode) {
2219
- case "WAFInternalErrorException":
2220
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2221
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2222
- case "WAFNonexistentItemException":
2223
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2224
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2225
- default:
2226
- const parsedBody = parsedOutput.body;
2227
- return throwDefaultError({
2228
- output,
2229
- parsedBody,
2230
- errorCode,
2231
- });
2232
- }
2233
- };
2234
- const de_GetRateBasedRuleCommand = async (output, context) => {
2235
- if (output.statusCode >= 300) {
2236
- return de_GetRateBasedRuleCommandError(output, context);
2237
- }
2238
- const data = await parseBody(output.body, context);
2239
- let contents = {};
2240
- contents = (0, smithy_client_1._json)(data);
2241
- const response = {
2242
- $metadata: deserializeMetadata(output),
2243
- ...contents,
2244
- };
2245
- return response;
2246
- };
2247
- exports.de_GetRateBasedRuleCommand = de_GetRateBasedRuleCommand;
2248
- const de_GetRateBasedRuleCommandError = async (output, context) => {
2249
- const parsedOutput = {
2250
- ...output,
2251
- body: await parseErrorBody(output.body, context),
2252
- };
2253
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2254
- switch (errorCode) {
2255
- case "WAFInternalErrorException":
2256
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2257
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2258
- case "WAFInvalidAccountException":
2259
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2260
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2261
- case "WAFNonexistentItemException":
2262
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2263
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2264
- default:
2265
- const parsedBody = parsedOutput.body;
2266
- return throwDefaultError({
2267
- output,
2268
- parsedBody,
2269
- errorCode,
2270
- });
2271
- }
2272
- };
2273
- const de_GetRateBasedRuleManagedKeysCommand = async (output, context) => {
2274
- if (output.statusCode >= 300) {
2275
- return de_GetRateBasedRuleManagedKeysCommandError(output, context);
2276
- }
2277
- const data = await parseBody(output.body, context);
2278
- let contents = {};
2279
- contents = (0, smithy_client_1._json)(data);
2280
- const response = {
2281
- $metadata: deserializeMetadata(output),
2282
- ...contents,
2283
- };
2284
- return response;
2285
- };
2286
- exports.de_GetRateBasedRuleManagedKeysCommand = de_GetRateBasedRuleManagedKeysCommand;
2287
- const de_GetRateBasedRuleManagedKeysCommandError = async (output, context) => {
2288
- const parsedOutput = {
2289
- ...output,
2290
- body: await parseErrorBody(output.body, context),
2291
- };
2292
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2293
- switch (errorCode) {
2294
- case "WAFInternalErrorException":
2295
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2296
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2297
- case "WAFInvalidAccountException":
2298
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2299
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2300
- case "WAFInvalidParameterException":
2301
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
2302
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
2303
- case "WAFNonexistentItemException":
2304
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2305
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2306
- default:
2307
- const parsedBody = parsedOutput.body;
2308
- return throwDefaultError({
2309
- output,
2310
- parsedBody,
2311
- errorCode,
2312
- });
2313
- }
2314
- };
2315
- const de_GetRegexMatchSetCommand = async (output, context) => {
2316
- if (output.statusCode >= 300) {
2317
- return de_GetRegexMatchSetCommandError(output, context);
2318
- }
2319
- const data = await parseBody(output.body, context);
2320
- let contents = {};
2321
- contents = (0, smithy_client_1._json)(data);
2322
- const response = {
2323
- $metadata: deserializeMetadata(output),
2324
- ...contents,
2325
- };
2326
- return response;
2327
- };
2328
- exports.de_GetRegexMatchSetCommand = de_GetRegexMatchSetCommand;
2329
- const de_GetRegexMatchSetCommandError = async (output, context) => {
2330
- const parsedOutput = {
2331
- ...output,
2332
- body: await parseErrorBody(output.body, context),
2333
- };
2334
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2335
- switch (errorCode) {
2336
- case "WAFInternalErrorException":
2337
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2338
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2339
- case "WAFInvalidAccountException":
2340
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2341
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2342
- case "WAFNonexistentItemException":
2343
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2344
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2345
- default:
2346
- const parsedBody = parsedOutput.body;
2347
- return throwDefaultError({
2348
- output,
2349
- parsedBody,
2350
- errorCode,
2351
- });
2352
- }
2353
- };
2354
- const de_GetRegexPatternSetCommand = async (output, context) => {
2355
- if (output.statusCode >= 300) {
2356
- return de_GetRegexPatternSetCommandError(output, context);
2357
- }
2358
- const data = await parseBody(output.body, context);
2359
- let contents = {};
2360
- contents = (0, smithy_client_1._json)(data);
2361
- const response = {
2362
- $metadata: deserializeMetadata(output),
2363
- ...contents,
2364
- };
2365
- return response;
2366
- };
2367
- exports.de_GetRegexPatternSetCommand = de_GetRegexPatternSetCommand;
2368
- const de_GetRegexPatternSetCommandError = async (output, context) => {
2369
- const parsedOutput = {
2370
- ...output,
2371
- body: await parseErrorBody(output.body, context),
2372
- };
2373
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2374
- switch (errorCode) {
2375
- case "WAFInternalErrorException":
2376
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2377
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2378
- case "WAFInvalidAccountException":
2379
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2380
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2381
- case "WAFNonexistentItemException":
2382
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2383
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2384
- default:
2385
- const parsedBody = parsedOutput.body;
2386
- return throwDefaultError({
2387
- output,
2388
- parsedBody,
2389
- errorCode,
2390
- });
2391
- }
2392
- };
2393
- const de_GetRuleCommand = async (output, context) => {
2394
- if (output.statusCode >= 300) {
2395
- return de_GetRuleCommandError(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_GetRuleCommand = de_GetRuleCommand;
2407
- const de_GetRuleCommandError = 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 "WAFInternalErrorException":
2415
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2416
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2417
- case "WAFInvalidAccountException":
2418
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2419
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2420
- case "WAFNonexistentItemException":
2421
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2422
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2423
- default:
2424
- const parsedBody = parsedOutput.body;
2425
- return throwDefaultError({
2426
- output,
2427
- parsedBody,
2428
- errorCode,
2429
- });
2430
- }
2431
- };
2432
- const de_GetRuleGroupCommand = async (output, context) => {
2433
- if (output.statusCode >= 300) {
2434
- return de_GetRuleGroupCommandError(output, context);
2435
- }
2436
- const data = await parseBody(output.body, context);
2437
- let contents = {};
2438
- contents = (0, smithy_client_1._json)(data);
2439
- const response = {
2440
- $metadata: deserializeMetadata(output),
2441
- ...contents,
2442
- };
2443
- return response;
2444
- };
2445
- exports.de_GetRuleGroupCommand = de_GetRuleGroupCommand;
2446
- const de_GetRuleGroupCommandError = async (output, context) => {
2447
- const parsedOutput = {
2448
- ...output,
2449
- body: await parseErrorBody(output.body, context),
2450
- };
2451
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2452
- switch (errorCode) {
2453
- case "WAFInternalErrorException":
2454
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2455
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2456
- case "WAFNonexistentItemException":
2457
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2458
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2459
- default:
2460
- const parsedBody = parsedOutput.body;
2461
- return throwDefaultError({
2462
- output,
2463
- parsedBody,
2464
- errorCode,
2465
- });
2466
- }
2467
- };
2468
- const de_GetSampledRequestsCommand = async (output, context) => {
2469
- if (output.statusCode >= 300) {
2470
- return de_GetSampledRequestsCommandError(output, context);
2471
- }
2472
- const data = await parseBody(output.body, context);
2473
- let contents = {};
2474
- contents = de_GetSampledRequestsResponse(data, context);
2475
- const response = {
2476
- $metadata: deserializeMetadata(output),
2477
- ...contents,
2478
- };
2479
- return response;
2480
- };
2481
- exports.de_GetSampledRequestsCommand = de_GetSampledRequestsCommand;
2482
- const de_GetSampledRequestsCommandError = async (output, context) => {
2483
- const parsedOutput = {
2484
- ...output,
2485
- body: await parseErrorBody(output.body, context),
2486
- };
2487
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2488
- switch (errorCode) {
2489
- case "WAFInternalErrorException":
2490
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2491
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2492
- case "WAFNonexistentItemException":
2493
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2494
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2495
- default:
2496
- const parsedBody = parsedOutput.body;
2497
- return throwDefaultError({
2498
- output,
2499
- parsedBody,
2500
- errorCode,
2501
- });
2502
- }
2503
- };
2504
- const de_GetSizeConstraintSetCommand = async (output, context) => {
2505
- if (output.statusCode >= 300) {
2506
- return de_GetSizeConstraintSetCommandError(output, context);
2507
- }
2508
- const data = await parseBody(output.body, context);
2509
- let contents = {};
2510
- contents = (0, smithy_client_1._json)(data);
2511
- const response = {
2512
- $metadata: deserializeMetadata(output),
2513
- ...contents,
2514
- };
2515
- return response;
2516
- };
2517
- exports.de_GetSizeConstraintSetCommand = de_GetSizeConstraintSetCommand;
2518
- const de_GetSizeConstraintSetCommandError = async (output, context) => {
2519
- const parsedOutput = {
2520
- ...output,
2521
- body: await parseErrorBody(output.body, context),
2522
- };
2523
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2524
- switch (errorCode) {
2525
- case "WAFInternalErrorException":
2526
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2527
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2528
- case "WAFInvalidAccountException":
2529
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2530
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2531
- case "WAFNonexistentItemException":
2532
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2533
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2534
- default:
2535
- const parsedBody = parsedOutput.body;
2536
- return throwDefaultError({
2537
- output,
2538
- parsedBody,
2539
- errorCode,
2540
- });
2541
- }
2542
- };
2543
- const de_GetSqlInjectionMatchSetCommand = async (output, context) => {
2544
- if (output.statusCode >= 300) {
2545
- return de_GetSqlInjectionMatchSetCommandError(output, context);
2546
- }
2547
- const data = await parseBody(output.body, context);
2548
- let contents = {};
2549
- contents = (0, smithy_client_1._json)(data);
2550
- const response = {
2551
- $metadata: deserializeMetadata(output),
2552
- ...contents,
2553
- };
2554
- return response;
2555
- };
2556
- exports.de_GetSqlInjectionMatchSetCommand = de_GetSqlInjectionMatchSetCommand;
2557
- const de_GetSqlInjectionMatchSetCommandError = async (output, context) => {
2558
- const parsedOutput = {
2559
- ...output,
2560
- body: await parseErrorBody(output.body, context),
2561
- };
2562
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2563
- switch (errorCode) {
2564
- case "WAFInternalErrorException":
2565
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2566
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2567
- case "WAFInvalidAccountException":
2568
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2569
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2570
- case "WAFNonexistentItemException":
2571
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2572
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2573
- default:
2574
- const parsedBody = parsedOutput.body;
2575
- return throwDefaultError({
2576
- output,
2577
- parsedBody,
2578
- errorCode,
2579
- });
2580
- }
2581
- };
2582
- const de_GetWebACLCommand = async (output, context) => {
2583
- if (output.statusCode >= 300) {
2584
- return de_GetWebACLCommandError(output, context);
2585
- }
2586
- const data = await parseBody(output.body, context);
2587
- let contents = {};
2588
- contents = (0, smithy_client_1._json)(data);
2589
- const response = {
2590
- $metadata: deserializeMetadata(output),
2591
- ...contents,
2592
- };
2593
- return response;
2594
- };
2595
- exports.de_GetWebACLCommand = de_GetWebACLCommand;
2596
- const de_GetWebACLCommandError = async (output, context) => {
2597
- const parsedOutput = {
2598
- ...output,
2599
- body: await parseErrorBody(output.body, context),
2600
- };
2601
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2602
- switch (errorCode) {
2603
- case "WAFInternalErrorException":
2604
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2605
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2606
- case "WAFInvalidAccountException":
2607
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2608
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2609
- case "WAFNonexistentItemException":
2610
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2611
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2612
- default:
2613
- const parsedBody = parsedOutput.body;
2614
- return throwDefaultError({
2615
- output,
2616
- parsedBody,
2617
- errorCode,
2618
- });
2619
- }
2620
- };
2621
- const de_GetWebACLForResourceCommand = async (output, context) => {
2622
- if (output.statusCode >= 300) {
2623
- return de_GetWebACLForResourceCommandError(output, context);
2624
- }
2625
- const data = await parseBody(output.body, context);
2626
- let contents = {};
2627
- contents = (0, smithy_client_1._json)(data);
2628
- const response = {
2629
- $metadata: deserializeMetadata(output),
2630
- ...contents,
2631
- };
2632
- return response;
2633
- };
2634
- exports.de_GetWebACLForResourceCommand = de_GetWebACLForResourceCommand;
2635
- const de_GetWebACLForResourceCommandError = async (output, context) => {
2636
- const parsedOutput = {
2637
- ...output,
2638
- body: await parseErrorBody(output.body, context),
2639
- };
2640
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2641
- switch (errorCode) {
2642
- case "WAFInternalErrorException":
2643
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2644
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2645
- case "WAFInvalidAccountException":
2646
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2647
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2648
- case "WAFInvalidParameterException":
2649
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
2650
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
2651
- case "WAFNonexistentItemException":
2652
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2653
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2654
- case "WAFUnavailableEntityException":
2655
- case "com.amazonaws.wafregional#WAFUnavailableEntityException":
2656
- throw await de_WAFUnavailableEntityExceptionRes(parsedOutput, context);
2657
- default:
2658
- const parsedBody = parsedOutput.body;
2659
- return throwDefaultError({
2660
- output,
2661
- parsedBody,
2662
- errorCode,
2663
- });
2664
- }
2665
- };
2666
- const de_GetXssMatchSetCommand = async (output, context) => {
2667
- if (output.statusCode >= 300) {
2668
- return de_GetXssMatchSetCommandError(output, context);
2669
- }
2670
- const data = await parseBody(output.body, context);
2671
- let contents = {};
2672
- contents = (0, smithy_client_1._json)(data);
2673
- const response = {
2674
- $metadata: deserializeMetadata(output),
2675
- ...contents,
2676
- };
2677
- return response;
2678
- };
2679
- exports.de_GetXssMatchSetCommand = de_GetXssMatchSetCommand;
2680
- const de_GetXssMatchSetCommandError = async (output, context) => {
2681
- const parsedOutput = {
2682
- ...output,
2683
- body: await parseErrorBody(output.body, context),
2684
- };
2685
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2686
- switch (errorCode) {
2687
- case "WAFInternalErrorException":
2688
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2689
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2690
- case "WAFInvalidAccountException":
2691
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2692
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2693
- case "WAFNonexistentItemException":
2694
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2695
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2696
- default:
2697
- const parsedBody = parsedOutput.body;
2698
- return throwDefaultError({
2699
- output,
2700
- parsedBody,
2701
- errorCode,
2702
- });
2703
- }
2704
- };
2705
- const de_ListActivatedRulesInRuleGroupCommand = async (output, context) => {
2706
- if (output.statusCode >= 300) {
2707
- return de_ListActivatedRulesInRuleGroupCommandError(output, context);
2708
- }
2709
- const data = await parseBody(output.body, context);
2710
- let contents = {};
2711
- contents = (0, smithy_client_1._json)(data);
2712
- const response = {
2713
- $metadata: deserializeMetadata(output),
2714
- ...contents,
2715
- };
2716
- return response;
2717
- };
2718
- exports.de_ListActivatedRulesInRuleGroupCommand = de_ListActivatedRulesInRuleGroupCommand;
2719
- const de_ListActivatedRulesInRuleGroupCommandError = async (output, context) => {
2720
- const parsedOutput = {
2721
- ...output,
2722
- body: await parseErrorBody(output.body, context),
2723
- };
2724
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2725
- switch (errorCode) {
2726
- case "WAFInternalErrorException":
2727
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2728
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2729
- case "WAFInvalidParameterException":
2730
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
2731
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
2732
- case "WAFNonexistentItemException":
2733
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2734
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2735
- default:
2736
- const parsedBody = parsedOutput.body;
2737
- return throwDefaultError({
2738
- output,
2739
- parsedBody,
2740
- errorCode,
2741
- });
2742
- }
2743
- };
2744
- const de_ListByteMatchSetsCommand = async (output, context) => {
2745
- if (output.statusCode >= 300) {
2746
- return de_ListByteMatchSetsCommandError(output, context);
2747
- }
2748
- const data = await parseBody(output.body, context);
2749
- let contents = {};
2750
- contents = (0, smithy_client_1._json)(data);
2751
- const response = {
2752
- $metadata: deserializeMetadata(output),
2753
- ...contents,
2754
- };
2755
- return response;
2756
- };
2757
- exports.de_ListByteMatchSetsCommand = de_ListByteMatchSetsCommand;
2758
- const de_ListByteMatchSetsCommandError = async (output, context) => {
2759
- const parsedOutput = {
2760
- ...output,
2761
- body: await parseErrorBody(output.body, context),
2762
- };
2763
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2764
- switch (errorCode) {
2765
- case "WAFInternalErrorException":
2766
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2767
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2768
- case "WAFInvalidAccountException":
2769
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2770
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2771
- default:
2772
- const parsedBody = parsedOutput.body;
2773
- return throwDefaultError({
2774
- output,
2775
- parsedBody,
2776
- errorCode,
2777
- });
2778
- }
2779
- };
2780
- const de_ListGeoMatchSetsCommand = async (output, context) => {
2781
- if (output.statusCode >= 300) {
2782
- return de_ListGeoMatchSetsCommandError(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_ListGeoMatchSetsCommand = de_ListGeoMatchSetsCommand;
2794
- const de_ListGeoMatchSetsCommandError = 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 "WAFInternalErrorException":
2802
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2803
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2804
- case "WAFInvalidAccountException":
2805
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2806
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2807
- default:
2808
- const parsedBody = parsedOutput.body;
2809
- return throwDefaultError({
2810
- output,
2811
- parsedBody,
2812
- errorCode,
2813
- });
2814
- }
2815
- };
2816
- const de_ListIPSetsCommand = async (output, context) => {
2817
- if (output.statusCode >= 300) {
2818
- return de_ListIPSetsCommandError(output, context);
2819
- }
2820
- const data = await parseBody(output.body, context);
2821
- let contents = {};
2822
- contents = (0, smithy_client_1._json)(data);
2823
- const response = {
2824
- $metadata: deserializeMetadata(output),
2825
- ...contents,
2826
- };
2827
- return response;
2828
- };
2829
- exports.de_ListIPSetsCommand = de_ListIPSetsCommand;
2830
- const de_ListIPSetsCommandError = async (output, context) => {
2831
- const parsedOutput = {
2832
- ...output,
2833
- body: await parseErrorBody(output.body, context),
2834
- };
2835
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2836
- switch (errorCode) {
2837
- case "WAFInternalErrorException":
2838
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2839
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2840
- case "WAFInvalidAccountException":
2841
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2842
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2843
- default:
2844
- const parsedBody = parsedOutput.body;
2845
- return throwDefaultError({
2846
- output,
2847
- parsedBody,
2848
- errorCode,
2849
- });
2850
- }
2851
- };
2852
- const de_ListLoggingConfigurationsCommand = async (output, context) => {
2853
- if (output.statusCode >= 300) {
2854
- return de_ListLoggingConfigurationsCommandError(output, context);
2855
- }
2856
- const data = await parseBody(output.body, context);
2857
- let contents = {};
2858
- contents = (0, smithy_client_1._json)(data);
2859
- const response = {
2860
- $metadata: deserializeMetadata(output),
2861
- ...contents,
2862
- };
2863
- return response;
2864
- };
2865
- exports.de_ListLoggingConfigurationsCommand = de_ListLoggingConfigurationsCommand;
2866
- const de_ListLoggingConfigurationsCommandError = async (output, context) => {
2867
- const parsedOutput = {
2868
- ...output,
2869
- body: await parseErrorBody(output.body, context),
2870
- };
2871
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2872
- switch (errorCode) {
2873
- case "WAFInternalErrorException":
2874
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2875
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2876
- case "WAFInvalidParameterException":
2877
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
2878
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
2879
- case "WAFNonexistentItemException":
2880
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
2881
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
2882
- default:
2883
- const parsedBody = parsedOutput.body;
2884
- return throwDefaultError({
2885
- output,
2886
- parsedBody,
2887
- errorCode,
2888
- });
2889
- }
2890
- };
2891
- const de_ListRateBasedRulesCommand = async (output, context) => {
2892
- if (output.statusCode >= 300) {
2893
- return de_ListRateBasedRulesCommandError(output, context);
2894
- }
2895
- const data = await parseBody(output.body, context);
2896
- let contents = {};
2897
- contents = (0, smithy_client_1._json)(data);
2898
- const response = {
2899
- $metadata: deserializeMetadata(output),
2900
- ...contents,
2901
- };
2902
- return response;
2903
- };
2904
- exports.de_ListRateBasedRulesCommand = de_ListRateBasedRulesCommand;
2905
- const de_ListRateBasedRulesCommandError = async (output, context) => {
2906
- const parsedOutput = {
2907
- ...output,
2908
- body: await parseErrorBody(output.body, context),
2909
- };
2910
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2911
- switch (errorCode) {
2912
- case "WAFInternalErrorException":
2913
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2914
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2915
- case "WAFInvalidAccountException":
2916
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2917
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2918
- default:
2919
- const parsedBody = parsedOutput.body;
2920
- return throwDefaultError({
2921
- output,
2922
- parsedBody,
2923
- errorCode,
2924
- });
2925
- }
2926
- };
2927
- const de_ListRegexMatchSetsCommand = async (output, context) => {
2928
- if (output.statusCode >= 300) {
2929
- return de_ListRegexMatchSetsCommandError(output, context);
2930
- }
2931
- const data = await parseBody(output.body, context);
2932
- let contents = {};
2933
- contents = (0, smithy_client_1._json)(data);
2934
- const response = {
2935
- $metadata: deserializeMetadata(output),
2936
- ...contents,
2937
- };
2938
- return response;
2939
- };
2940
- exports.de_ListRegexMatchSetsCommand = de_ListRegexMatchSetsCommand;
2941
- const de_ListRegexMatchSetsCommandError = async (output, context) => {
2942
- const parsedOutput = {
2943
- ...output,
2944
- body: await parseErrorBody(output.body, context),
2945
- };
2946
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2947
- switch (errorCode) {
2948
- case "WAFInternalErrorException":
2949
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2950
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2951
- case "WAFInvalidAccountException":
2952
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2953
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2954
- default:
2955
- const parsedBody = parsedOutput.body;
2956
- return throwDefaultError({
2957
- output,
2958
- parsedBody,
2959
- errorCode,
2960
- });
2961
- }
2962
- };
2963
- const de_ListRegexPatternSetsCommand = async (output, context) => {
2964
- if (output.statusCode >= 300) {
2965
- return de_ListRegexPatternSetsCommandError(output, context);
2966
- }
2967
- const data = await parseBody(output.body, context);
2968
- let contents = {};
2969
- contents = (0, smithy_client_1._json)(data);
2970
- const response = {
2971
- $metadata: deserializeMetadata(output),
2972
- ...contents,
2973
- };
2974
- return response;
2975
- };
2976
- exports.de_ListRegexPatternSetsCommand = de_ListRegexPatternSetsCommand;
2977
- const de_ListRegexPatternSetsCommandError = async (output, context) => {
2978
- const parsedOutput = {
2979
- ...output,
2980
- body: await parseErrorBody(output.body, context),
2981
- };
2982
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2983
- switch (errorCode) {
2984
- case "WAFInternalErrorException":
2985
- case "com.amazonaws.wafregional#WAFInternalErrorException":
2986
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
2987
- case "WAFInvalidAccountException":
2988
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
2989
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
2990
- default:
2991
- const parsedBody = parsedOutput.body;
2992
- return throwDefaultError({
2993
- output,
2994
- parsedBody,
2995
- errorCode,
2996
- });
2997
- }
2998
- };
2999
- const de_ListResourcesForWebACLCommand = async (output, context) => {
3000
- if (output.statusCode >= 300) {
3001
- return de_ListResourcesForWebACLCommandError(output, context);
3002
- }
3003
- const data = await parseBody(output.body, context);
3004
- let contents = {};
3005
- contents = (0, smithy_client_1._json)(data);
3006
- const response = {
3007
- $metadata: deserializeMetadata(output),
3008
- ...contents,
3009
- };
3010
- return response;
3011
- };
3012
- exports.de_ListResourcesForWebACLCommand = de_ListResourcesForWebACLCommand;
3013
- const de_ListResourcesForWebACLCommandError = async (output, context) => {
3014
- const parsedOutput = {
3015
- ...output,
3016
- body: await parseErrorBody(output.body, context),
3017
- };
3018
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3019
- switch (errorCode) {
3020
- case "WAFInternalErrorException":
3021
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3022
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3023
- case "WAFInvalidAccountException":
3024
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3025
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3026
- case "WAFInvalidParameterException":
3027
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3028
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3029
- case "WAFNonexistentItemException":
3030
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3031
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3032
- default:
3033
- const parsedBody = parsedOutput.body;
3034
- return throwDefaultError({
3035
- output,
3036
- parsedBody,
3037
- errorCode,
3038
- });
3039
- }
3040
- };
3041
- const de_ListRuleGroupsCommand = async (output, context) => {
3042
- if (output.statusCode >= 300) {
3043
- return de_ListRuleGroupsCommandError(output, context);
3044
- }
3045
- const data = await parseBody(output.body, context);
3046
- let contents = {};
3047
- contents = (0, smithy_client_1._json)(data);
3048
- const response = {
3049
- $metadata: deserializeMetadata(output),
3050
- ...contents,
3051
- };
3052
- return response;
3053
- };
3054
- exports.de_ListRuleGroupsCommand = de_ListRuleGroupsCommand;
3055
- const de_ListRuleGroupsCommandError = async (output, context) => {
3056
- const parsedOutput = {
3057
- ...output,
3058
- body: await parseErrorBody(output.body, context),
3059
- };
3060
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3061
- switch (errorCode) {
3062
- case "WAFInternalErrorException":
3063
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3064
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3065
- default:
3066
- const parsedBody = parsedOutput.body;
3067
- return throwDefaultError({
3068
- output,
3069
- parsedBody,
3070
- errorCode,
3071
- });
3072
- }
3073
- };
3074
- const de_ListRulesCommand = async (output, context) => {
3075
- if (output.statusCode >= 300) {
3076
- return de_ListRulesCommandError(output, context);
3077
- }
3078
- const data = await parseBody(output.body, context);
3079
- let contents = {};
3080
- contents = (0, smithy_client_1._json)(data);
3081
- const response = {
3082
- $metadata: deserializeMetadata(output),
3083
- ...contents,
3084
- };
3085
- return response;
3086
- };
3087
- exports.de_ListRulesCommand = de_ListRulesCommand;
3088
- const de_ListRulesCommandError = async (output, context) => {
3089
- const parsedOutput = {
3090
- ...output,
3091
- body: await parseErrorBody(output.body, context),
3092
- };
3093
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3094
- switch (errorCode) {
3095
- case "WAFInternalErrorException":
3096
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3097
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3098
- case "WAFInvalidAccountException":
3099
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3100
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3101
- default:
3102
- const parsedBody = parsedOutput.body;
3103
- return throwDefaultError({
3104
- output,
3105
- parsedBody,
3106
- errorCode,
3107
- });
3108
- }
3109
- };
3110
- const de_ListSizeConstraintSetsCommand = async (output, context) => {
3111
- if (output.statusCode >= 300) {
3112
- return de_ListSizeConstraintSetsCommandError(output, context);
3113
- }
3114
- const data = await parseBody(output.body, context);
3115
- let contents = {};
3116
- contents = (0, smithy_client_1._json)(data);
3117
- const response = {
3118
- $metadata: deserializeMetadata(output),
3119
- ...contents,
3120
- };
3121
- return response;
3122
- };
3123
- exports.de_ListSizeConstraintSetsCommand = de_ListSizeConstraintSetsCommand;
3124
- const de_ListSizeConstraintSetsCommandError = async (output, context) => {
3125
- const parsedOutput = {
3126
- ...output,
3127
- body: await parseErrorBody(output.body, context),
3128
- };
3129
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3130
- switch (errorCode) {
3131
- case "WAFInternalErrorException":
3132
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3133
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3134
- case "WAFInvalidAccountException":
3135
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3136
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3137
- default:
3138
- const parsedBody = parsedOutput.body;
3139
- return throwDefaultError({
3140
- output,
3141
- parsedBody,
3142
- errorCode,
3143
- });
3144
- }
3145
- };
3146
- const de_ListSqlInjectionMatchSetsCommand = async (output, context) => {
3147
- if (output.statusCode >= 300) {
3148
- return de_ListSqlInjectionMatchSetsCommandError(output, context);
3149
- }
3150
- const data = await parseBody(output.body, context);
3151
- let contents = {};
3152
- contents = (0, smithy_client_1._json)(data);
3153
- const response = {
3154
- $metadata: deserializeMetadata(output),
3155
- ...contents,
3156
- };
3157
- return response;
3158
- };
3159
- exports.de_ListSqlInjectionMatchSetsCommand = de_ListSqlInjectionMatchSetsCommand;
3160
- const de_ListSqlInjectionMatchSetsCommandError = async (output, context) => {
3161
- const parsedOutput = {
3162
- ...output,
3163
- body: await parseErrorBody(output.body, context),
3164
- };
3165
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3166
- switch (errorCode) {
3167
- case "WAFInternalErrorException":
3168
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3169
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3170
- case "WAFInvalidAccountException":
3171
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3172
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3173
- default:
3174
- const parsedBody = parsedOutput.body;
3175
- return throwDefaultError({
3176
- output,
3177
- parsedBody,
3178
- errorCode,
3179
- });
3180
- }
3181
- };
3182
- const de_ListSubscribedRuleGroupsCommand = async (output, context) => {
3183
- if (output.statusCode >= 300) {
3184
- return de_ListSubscribedRuleGroupsCommandError(output, context);
3185
- }
3186
- const data = await parseBody(output.body, context);
3187
- let contents = {};
3188
- contents = (0, smithy_client_1._json)(data);
3189
- const response = {
3190
- $metadata: deserializeMetadata(output),
3191
- ...contents,
3192
- };
3193
- return response;
3194
- };
3195
- exports.de_ListSubscribedRuleGroupsCommand = de_ListSubscribedRuleGroupsCommand;
3196
- const de_ListSubscribedRuleGroupsCommandError = async (output, context) => {
3197
- const parsedOutput = {
3198
- ...output,
3199
- body: await parseErrorBody(output.body, context),
3200
- };
3201
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3202
- switch (errorCode) {
3203
- case "WAFInternalErrorException":
3204
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3205
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3206
- case "WAFNonexistentItemException":
3207
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3208
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3209
- default:
3210
- const parsedBody = parsedOutput.body;
3211
- return throwDefaultError({
3212
- output,
3213
- parsedBody,
3214
- errorCode,
3215
- });
3216
- }
3217
- };
3218
- const de_ListTagsForResourceCommand = async (output, context) => {
3219
- if (output.statusCode >= 300) {
3220
- return de_ListTagsForResourceCommandError(output, context);
3221
- }
3222
- const data = await parseBody(output.body, context);
3223
- let contents = {};
3224
- contents = (0, smithy_client_1._json)(data);
3225
- const response = {
3226
- $metadata: deserializeMetadata(output),
3227
- ...contents,
3228
- };
3229
- return response;
3230
- };
3231
- exports.de_ListTagsForResourceCommand = de_ListTagsForResourceCommand;
3232
- const de_ListTagsForResourceCommandError = async (output, context) => {
3233
- const parsedOutput = {
3234
- ...output,
3235
- body: await parseErrorBody(output.body, context),
3236
- };
3237
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3238
- switch (errorCode) {
3239
- case "WAFBadRequestException":
3240
- case "com.amazonaws.wafregional#WAFBadRequestException":
3241
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
3242
- case "WAFInternalErrorException":
3243
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3244
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3245
- case "WAFInvalidParameterException":
3246
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3247
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3248
- case "WAFNonexistentItemException":
3249
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3250
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3251
- case "WAFTagOperationException":
3252
- case "com.amazonaws.wafregional#WAFTagOperationException":
3253
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
3254
- case "WAFTagOperationInternalErrorException":
3255
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
3256
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
3257
- default:
3258
- const parsedBody = parsedOutput.body;
3259
- return throwDefaultError({
3260
- output,
3261
- parsedBody,
3262
- errorCode,
3263
- });
3264
- }
3265
- };
3266
- const de_ListWebACLsCommand = async (output, context) => {
3267
- if (output.statusCode >= 300) {
3268
- return de_ListWebACLsCommandError(output, context);
3269
- }
3270
- const data = await parseBody(output.body, context);
3271
- let contents = {};
3272
- contents = (0, smithy_client_1._json)(data);
3273
- const response = {
3274
- $metadata: deserializeMetadata(output),
3275
- ...contents,
3276
- };
3277
- return response;
3278
- };
3279
- exports.de_ListWebACLsCommand = de_ListWebACLsCommand;
3280
- const de_ListWebACLsCommandError = async (output, context) => {
3281
- const parsedOutput = {
3282
- ...output,
3283
- body: await parseErrorBody(output.body, context),
3284
- };
3285
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3286
- switch (errorCode) {
3287
- case "WAFInternalErrorException":
3288
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3289
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3290
- case "WAFInvalidAccountException":
3291
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3292
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3293
- default:
3294
- const parsedBody = parsedOutput.body;
3295
- return throwDefaultError({
3296
- output,
3297
- parsedBody,
3298
- errorCode,
3299
- });
3300
- }
3301
- };
3302
- const de_ListXssMatchSetsCommand = async (output, context) => {
3303
- if (output.statusCode >= 300) {
3304
- return de_ListXssMatchSetsCommandError(output, context);
3305
- }
3306
- const data = await parseBody(output.body, context);
3307
- let contents = {};
3308
- contents = (0, smithy_client_1._json)(data);
3309
- const response = {
3310
- $metadata: deserializeMetadata(output),
3311
- ...contents,
3312
- };
3313
- return response;
3314
- };
3315
- exports.de_ListXssMatchSetsCommand = de_ListXssMatchSetsCommand;
3316
- const de_ListXssMatchSetsCommandError = async (output, context) => {
3317
- const parsedOutput = {
3318
- ...output,
3319
- body: await parseErrorBody(output.body, context),
3320
- };
3321
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3322
- switch (errorCode) {
3323
- case "WAFInternalErrorException":
3324
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3325
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3326
- case "WAFInvalidAccountException":
3327
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3328
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3329
- default:
3330
- const parsedBody = parsedOutput.body;
3331
- return throwDefaultError({
3332
- output,
3333
- parsedBody,
3334
- errorCode,
3335
- });
3336
- }
3337
- };
3338
- const de_PutLoggingConfigurationCommand = async (output, context) => {
3339
- if (output.statusCode >= 300) {
3340
- return de_PutLoggingConfigurationCommandError(output, context);
3341
- }
3342
- const data = await parseBody(output.body, context);
3343
- let contents = {};
3344
- contents = (0, smithy_client_1._json)(data);
3345
- const response = {
3346
- $metadata: deserializeMetadata(output),
3347
- ...contents,
3348
- };
3349
- return response;
3350
- };
3351
- exports.de_PutLoggingConfigurationCommand = de_PutLoggingConfigurationCommand;
3352
- const de_PutLoggingConfigurationCommandError = async (output, context) => {
3353
- const parsedOutput = {
3354
- ...output,
3355
- body: await parseErrorBody(output.body, context),
3356
- };
3357
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3358
- switch (errorCode) {
3359
- case "WAFInternalErrorException":
3360
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3361
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3362
- case "WAFNonexistentItemException":
3363
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3364
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3365
- case "WAFServiceLinkedRoleErrorException":
3366
- case "com.amazonaws.wafregional#WAFServiceLinkedRoleErrorException":
3367
- throw await de_WAFServiceLinkedRoleErrorExceptionRes(parsedOutput, context);
3368
- case "WAFStaleDataException":
3369
- case "com.amazonaws.wafregional#WAFStaleDataException":
3370
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3371
- default:
3372
- const parsedBody = parsedOutput.body;
3373
- return throwDefaultError({
3374
- output,
3375
- parsedBody,
3376
- errorCode,
3377
- });
3378
- }
3379
- };
3380
- const de_PutPermissionPolicyCommand = async (output, context) => {
3381
- if (output.statusCode >= 300) {
3382
- return de_PutPermissionPolicyCommandError(output, context);
3383
- }
3384
- const data = await parseBody(output.body, context);
3385
- let contents = {};
3386
- contents = (0, smithy_client_1._json)(data);
3387
- const response = {
3388
- $metadata: deserializeMetadata(output),
3389
- ...contents,
3390
- };
3391
- return response;
3392
- };
3393
- exports.de_PutPermissionPolicyCommand = de_PutPermissionPolicyCommand;
3394
- const de_PutPermissionPolicyCommandError = async (output, context) => {
3395
- const parsedOutput = {
3396
- ...output,
3397
- body: await parseErrorBody(output.body, context),
3398
- };
3399
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3400
- switch (errorCode) {
3401
- case "WAFInternalErrorException":
3402
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3403
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3404
- case "WAFInvalidPermissionPolicyException":
3405
- case "com.amazonaws.wafregional#WAFInvalidPermissionPolicyException":
3406
- throw await de_WAFInvalidPermissionPolicyExceptionRes(parsedOutput, context);
3407
- case "WAFNonexistentItemException":
3408
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3409
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3410
- case "WAFStaleDataException":
3411
- case "com.amazonaws.wafregional#WAFStaleDataException":
3412
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3413
- default:
3414
- const parsedBody = parsedOutput.body;
3415
- return throwDefaultError({
3416
- output,
3417
- parsedBody,
3418
- errorCode,
3419
- });
3420
- }
3421
- };
3422
- const de_TagResourceCommand = async (output, context) => {
3423
- if (output.statusCode >= 300) {
3424
- return de_TagResourceCommandError(output, context);
3425
- }
3426
- const data = await parseBody(output.body, context);
3427
- let contents = {};
3428
- contents = (0, smithy_client_1._json)(data);
3429
- const response = {
3430
- $metadata: deserializeMetadata(output),
3431
- ...contents,
3432
- };
3433
- return response;
3434
- };
3435
- exports.de_TagResourceCommand = de_TagResourceCommand;
3436
- const de_TagResourceCommandError = async (output, context) => {
3437
- const parsedOutput = {
3438
- ...output,
3439
- body: await parseErrorBody(output.body, context),
3440
- };
3441
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3442
- switch (errorCode) {
3443
- case "WAFBadRequestException":
3444
- case "com.amazonaws.wafregional#WAFBadRequestException":
3445
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
3446
- case "WAFInternalErrorException":
3447
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3448
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3449
- case "WAFInvalidParameterException":
3450
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3451
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3452
- case "WAFLimitsExceededException":
3453
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3454
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3455
- case "WAFNonexistentItemException":
3456
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3457
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3458
- case "WAFTagOperationException":
3459
- case "com.amazonaws.wafregional#WAFTagOperationException":
3460
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
3461
- case "WAFTagOperationInternalErrorException":
3462
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
3463
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
3464
- default:
3465
- const parsedBody = parsedOutput.body;
3466
- return throwDefaultError({
3467
- output,
3468
- parsedBody,
3469
- errorCode,
3470
- });
3471
- }
3472
- };
3473
- const de_UntagResourceCommand = async (output, context) => {
3474
- if (output.statusCode >= 300) {
3475
- return de_UntagResourceCommandError(output, context);
3476
- }
3477
- const data = await parseBody(output.body, context);
3478
- let contents = {};
3479
- contents = (0, smithy_client_1._json)(data);
3480
- const response = {
3481
- $metadata: deserializeMetadata(output),
3482
- ...contents,
3483
- };
3484
- return response;
3485
- };
3486
- exports.de_UntagResourceCommand = de_UntagResourceCommand;
3487
- const de_UntagResourceCommandError = async (output, context) => {
3488
- const parsedOutput = {
3489
- ...output,
3490
- body: await parseErrorBody(output.body, context),
3491
- };
3492
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3493
- switch (errorCode) {
3494
- case "WAFBadRequestException":
3495
- case "com.amazonaws.wafregional#WAFBadRequestException":
3496
- throw await de_WAFBadRequestExceptionRes(parsedOutput, context);
3497
- case "WAFInternalErrorException":
3498
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3499
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3500
- case "WAFInvalidParameterException":
3501
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3502
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3503
- case "WAFNonexistentItemException":
3504
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3505
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3506
- case "WAFTagOperationException":
3507
- case "com.amazonaws.wafregional#WAFTagOperationException":
3508
- throw await de_WAFTagOperationExceptionRes(parsedOutput, context);
3509
- case "WAFTagOperationInternalErrorException":
3510
- case "com.amazonaws.wafregional#WAFTagOperationInternalErrorException":
3511
- throw await de_WAFTagOperationInternalErrorExceptionRes(parsedOutput, context);
3512
- default:
3513
- const parsedBody = parsedOutput.body;
3514
- return throwDefaultError({
3515
- output,
3516
- parsedBody,
3517
- errorCode,
3518
- });
3519
- }
3520
- };
3521
- const de_UpdateByteMatchSetCommand = async (output, context) => {
3522
- if (output.statusCode >= 300) {
3523
- return de_UpdateByteMatchSetCommandError(output, context);
3524
- }
3525
- const data = await parseBody(output.body, context);
3526
- let contents = {};
3527
- contents = (0, smithy_client_1._json)(data);
3528
- const response = {
3529
- $metadata: deserializeMetadata(output),
3530
- ...contents,
3531
- };
3532
- return response;
3533
- };
3534
- exports.de_UpdateByteMatchSetCommand = de_UpdateByteMatchSetCommand;
3535
- const de_UpdateByteMatchSetCommandError = async (output, context) => {
3536
- const parsedOutput = {
3537
- ...output,
3538
- body: await parseErrorBody(output.body, context),
3539
- };
3540
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3541
- switch (errorCode) {
3542
- case "WAFInternalErrorException":
3543
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3544
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3545
- case "WAFInvalidAccountException":
3546
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3547
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3548
- case "WAFInvalidOperationException":
3549
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3550
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3551
- case "WAFInvalidParameterException":
3552
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3553
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3554
- case "WAFLimitsExceededException":
3555
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3556
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3557
- case "WAFNonexistentContainerException":
3558
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3559
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3560
- case "WAFNonexistentItemException":
3561
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3562
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3563
- case "WAFStaleDataException":
3564
- case "com.amazonaws.wafregional#WAFStaleDataException":
3565
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3566
- default:
3567
- const parsedBody = parsedOutput.body;
3568
- return throwDefaultError({
3569
- output,
3570
- parsedBody,
3571
- errorCode,
3572
- });
3573
- }
3574
- };
3575
- const de_UpdateGeoMatchSetCommand = async (output, context) => {
3576
- if (output.statusCode >= 300) {
3577
- return de_UpdateGeoMatchSetCommandError(output, context);
3578
- }
3579
- const data = await parseBody(output.body, context);
3580
- let contents = {};
3581
- contents = (0, smithy_client_1._json)(data);
3582
- const response = {
3583
- $metadata: deserializeMetadata(output),
3584
- ...contents,
3585
- };
3586
- return response;
3587
- };
3588
- exports.de_UpdateGeoMatchSetCommand = de_UpdateGeoMatchSetCommand;
3589
- const de_UpdateGeoMatchSetCommandError = async (output, context) => {
3590
- const parsedOutput = {
3591
- ...output,
3592
- body: await parseErrorBody(output.body, context),
3593
- };
3594
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3595
- switch (errorCode) {
3596
- case "WAFInternalErrorException":
3597
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3598
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3599
- case "WAFInvalidAccountException":
3600
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3601
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3602
- case "WAFInvalidOperationException":
3603
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3604
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3605
- case "WAFInvalidParameterException":
3606
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3607
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3608
- case "WAFLimitsExceededException":
3609
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3610
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3611
- case "WAFNonexistentContainerException":
3612
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3613
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3614
- case "WAFNonexistentItemException":
3615
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3616
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3617
- case "WAFReferencedItemException":
3618
- case "com.amazonaws.wafregional#WAFReferencedItemException":
3619
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
3620
- case "WAFStaleDataException":
3621
- case "com.amazonaws.wafregional#WAFStaleDataException":
3622
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3623
- default:
3624
- const parsedBody = parsedOutput.body;
3625
- return throwDefaultError({
3626
- output,
3627
- parsedBody,
3628
- errorCode,
3629
- });
3630
- }
3631
- };
3632
- const de_UpdateIPSetCommand = async (output, context) => {
3633
- if (output.statusCode >= 300) {
3634
- return de_UpdateIPSetCommandError(output, context);
3635
- }
3636
- const data = await parseBody(output.body, context);
3637
- let contents = {};
3638
- contents = (0, smithy_client_1._json)(data);
3639
- const response = {
3640
- $metadata: deserializeMetadata(output),
3641
- ...contents,
3642
- };
3643
- return response;
3644
- };
3645
- exports.de_UpdateIPSetCommand = de_UpdateIPSetCommand;
3646
- const de_UpdateIPSetCommandError = async (output, context) => {
3647
- const parsedOutput = {
3648
- ...output,
3649
- body: await parseErrorBody(output.body, context),
3650
- };
3651
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3652
- switch (errorCode) {
3653
- case "WAFInternalErrorException":
3654
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3655
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3656
- case "WAFInvalidAccountException":
3657
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3658
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3659
- case "WAFInvalidOperationException":
3660
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3661
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3662
- case "WAFInvalidParameterException":
3663
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3664
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3665
- case "WAFLimitsExceededException":
3666
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3667
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3668
- case "WAFNonexistentContainerException":
3669
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3670
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3671
- case "WAFNonexistentItemException":
3672
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3673
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3674
- case "WAFReferencedItemException":
3675
- case "com.amazonaws.wafregional#WAFReferencedItemException":
3676
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
3677
- case "WAFStaleDataException":
3678
- case "com.amazonaws.wafregional#WAFStaleDataException":
3679
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3680
- default:
3681
- const parsedBody = parsedOutput.body;
3682
- return throwDefaultError({
3683
- output,
3684
- parsedBody,
3685
- errorCode,
3686
- });
3687
- }
3688
- };
3689
- const de_UpdateRateBasedRuleCommand = async (output, context) => {
3690
- if (output.statusCode >= 300) {
3691
- return de_UpdateRateBasedRuleCommandError(output, context);
3692
- }
3693
- const data = await parseBody(output.body, context);
3694
- let contents = {};
3695
- contents = (0, smithy_client_1._json)(data);
3696
- const response = {
3697
- $metadata: deserializeMetadata(output),
3698
- ...contents,
3699
- };
3700
- return response;
3701
- };
3702
- exports.de_UpdateRateBasedRuleCommand = de_UpdateRateBasedRuleCommand;
3703
- const de_UpdateRateBasedRuleCommandError = async (output, context) => {
3704
- const parsedOutput = {
3705
- ...output,
3706
- body: await parseErrorBody(output.body, context),
3707
- };
3708
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3709
- switch (errorCode) {
3710
- case "WAFInternalErrorException":
3711
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3712
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3713
- case "WAFInvalidAccountException":
3714
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3715
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3716
- case "WAFInvalidOperationException":
3717
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3718
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3719
- case "WAFInvalidParameterException":
3720
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3721
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3722
- case "WAFLimitsExceededException":
3723
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3724
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3725
- case "WAFNonexistentContainerException":
3726
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3727
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3728
- case "WAFNonexistentItemException":
3729
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3730
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3731
- case "WAFReferencedItemException":
3732
- case "com.amazonaws.wafregional#WAFReferencedItemException":
3733
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
3734
- case "WAFStaleDataException":
3735
- case "com.amazonaws.wafregional#WAFStaleDataException":
3736
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3737
- default:
3738
- const parsedBody = parsedOutput.body;
3739
- return throwDefaultError({
3740
- output,
3741
- parsedBody,
3742
- errorCode,
3743
- });
3744
- }
3745
- };
3746
- const de_UpdateRegexMatchSetCommand = async (output, context) => {
3747
- if (output.statusCode >= 300) {
3748
- return de_UpdateRegexMatchSetCommandError(output, context);
3749
- }
3750
- const data = await parseBody(output.body, context);
3751
- let contents = {};
3752
- contents = (0, smithy_client_1._json)(data);
3753
- const response = {
3754
- $metadata: deserializeMetadata(output),
3755
- ...contents,
3756
- };
3757
- return response;
3758
- };
3759
- exports.de_UpdateRegexMatchSetCommand = de_UpdateRegexMatchSetCommand;
3760
- const de_UpdateRegexMatchSetCommandError = async (output, context) => {
3761
- const parsedOutput = {
3762
- ...output,
3763
- body: await parseErrorBody(output.body, context),
3764
- };
3765
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3766
- switch (errorCode) {
3767
- case "WAFDisallowedNameException":
3768
- case "com.amazonaws.wafregional#WAFDisallowedNameException":
3769
- throw await de_WAFDisallowedNameExceptionRes(parsedOutput, context);
3770
- case "WAFInternalErrorException":
3771
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3772
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3773
- case "WAFInvalidAccountException":
3774
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3775
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3776
- case "WAFInvalidOperationException":
3777
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3778
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3779
- case "WAFLimitsExceededException":
3780
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3781
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3782
- case "WAFNonexistentContainerException":
3783
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3784
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3785
- case "WAFNonexistentItemException":
3786
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3787
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3788
- case "WAFStaleDataException":
3789
- case "com.amazonaws.wafregional#WAFStaleDataException":
3790
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3791
- default:
3792
- const parsedBody = parsedOutput.body;
3793
- return throwDefaultError({
3794
- output,
3795
- parsedBody,
3796
- errorCode,
3797
- });
3798
- }
3799
- };
3800
- const de_UpdateRegexPatternSetCommand = async (output, context) => {
3801
- if (output.statusCode >= 300) {
3802
- return de_UpdateRegexPatternSetCommandError(output, context);
3803
- }
3804
- const data = await parseBody(output.body, context);
3805
- let contents = {};
3806
- contents = (0, smithy_client_1._json)(data);
3807
- const response = {
3808
- $metadata: deserializeMetadata(output),
3809
- ...contents,
3810
- };
3811
- return response;
3812
- };
3813
- exports.de_UpdateRegexPatternSetCommand = de_UpdateRegexPatternSetCommand;
3814
- const de_UpdateRegexPatternSetCommandError = async (output, context) => {
3815
- const parsedOutput = {
3816
- ...output,
3817
- body: await parseErrorBody(output.body, context),
3818
- };
3819
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3820
- switch (errorCode) {
3821
- case "WAFInternalErrorException":
3822
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3823
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3824
- case "WAFInvalidAccountException":
3825
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3826
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3827
- case "WAFInvalidOperationException":
3828
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3829
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3830
- case "WAFInvalidRegexPatternException":
3831
- case "com.amazonaws.wafregional#WAFInvalidRegexPatternException":
3832
- throw await de_WAFInvalidRegexPatternExceptionRes(parsedOutput, context);
3833
- case "WAFLimitsExceededException":
3834
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3835
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3836
- case "WAFNonexistentContainerException":
3837
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3838
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3839
- case "WAFNonexistentItemException":
3840
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3841
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3842
- case "WAFStaleDataException":
3843
- case "com.amazonaws.wafregional#WAFStaleDataException":
3844
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3845
- default:
3846
- const parsedBody = parsedOutput.body;
3847
- return throwDefaultError({
3848
- output,
3849
- parsedBody,
3850
- errorCode,
3851
- });
3852
- }
3853
- };
3854
- const de_UpdateRuleCommand = async (output, context) => {
3855
- if (output.statusCode >= 300) {
3856
- return de_UpdateRuleCommandError(output, context);
3857
- }
3858
- const data = await parseBody(output.body, context);
3859
- let contents = {};
3860
- contents = (0, smithy_client_1._json)(data);
3861
- const response = {
3862
- $metadata: deserializeMetadata(output),
3863
- ...contents,
3864
- };
3865
- return response;
3866
- };
3867
- exports.de_UpdateRuleCommand = de_UpdateRuleCommand;
3868
- const de_UpdateRuleCommandError = async (output, context) => {
3869
- const parsedOutput = {
3870
- ...output,
3871
- body: await parseErrorBody(output.body, context),
3872
- };
3873
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3874
- switch (errorCode) {
3875
- case "WAFInternalErrorException":
3876
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3877
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3878
- case "WAFInvalidAccountException":
3879
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3880
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3881
- case "WAFInvalidOperationException":
3882
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3883
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3884
- case "WAFInvalidParameterException":
3885
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3886
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3887
- case "WAFLimitsExceededException":
3888
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3889
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3890
- case "WAFNonexistentContainerException":
3891
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3892
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3893
- case "WAFNonexistentItemException":
3894
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3895
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3896
- case "WAFReferencedItemException":
3897
- case "com.amazonaws.wafregional#WAFReferencedItemException":
3898
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
3899
- case "WAFStaleDataException":
3900
- case "com.amazonaws.wafregional#WAFStaleDataException":
3901
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3902
- default:
3903
- const parsedBody = parsedOutput.body;
3904
- return throwDefaultError({
3905
- output,
3906
- parsedBody,
3907
- errorCode,
3908
- });
3909
- }
3910
- };
3911
- const de_UpdateRuleGroupCommand = async (output, context) => {
3912
- if (output.statusCode >= 300) {
3913
- return de_UpdateRuleGroupCommandError(output, context);
3914
- }
3915
- const data = await parseBody(output.body, context);
3916
- let contents = {};
3917
- contents = (0, smithy_client_1._json)(data);
3918
- const response = {
3919
- $metadata: deserializeMetadata(output),
3920
- ...contents,
3921
- };
3922
- return response;
3923
- };
3924
- exports.de_UpdateRuleGroupCommand = de_UpdateRuleGroupCommand;
3925
- const de_UpdateRuleGroupCommandError = async (output, context) => {
3926
- const parsedOutput = {
3927
- ...output,
3928
- body: await parseErrorBody(output.body, context),
3929
- };
3930
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3931
- switch (errorCode) {
3932
- case "WAFInternalErrorException":
3933
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3934
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3935
- case "WAFInvalidOperationException":
3936
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3937
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3938
- case "WAFInvalidParameterException":
3939
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3940
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3941
- case "WAFLimitsExceededException":
3942
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3943
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3944
- case "WAFNonexistentContainerException":
3945
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
3946
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
3947
- case "WAFNonexistentItemException":
3948
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
3949
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
3950
- case "WAFStaleDataException":
3951
- case "com.amazonaws.wafregional#WAFStaleDataException":
3952
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
3953
- default:
3954
- const parsedBody = parsedOutput.body;
3955
- return throwDefaultError({
3956
- output,
3957
- parsedBody,
3958
- errorCode,
3959
- });
3960
- }
3961
- };
3962
- const de_UpdateSizeConstraintSetCommand = async (output, context) => {
3963
- if (output.statusCode >= 300) {
3964
- return de_UpdateSizeConstraintSetCommandError(output, context);
3965
- }
3966
- const data = await parseBody(output.body, context);
3967
- let contents = {};
3968
- contents = (0, smithy_client_1._json)(data);
3969
- const response = {
3970
- $metadata: deserializeMetadata(output),
3971
- ...contents,
3972
- };
3973
- return response;
3974
- };
3975
- exports.de_UpdateSizeConstraintSetCommand = de_UpdateSizeConstraintSetCommand;
3976
- const de_UpdateSizeConstraintSetCommandError = async (output, context) => {
3977
- const parsedOutput = {
3978
- ...output,
3979
- body: await parseErrorBody(output.body, context),
3980
- };
3981
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3982
- switch (errorCode) {
3983
- case "WAFInternalErrorException":
3984
- case "com.amazonaws.wafregional#WAFInternalErrorException":
3985
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
3986
- case "WAFInvalidAccountException":
3987
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
3988
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
3989
- case "WAFInvalidOperationException":
3990
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
3991
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
3992
- case "WAFInvalidParameterException":
3993
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
3994
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
3995
- case "WAFLimitsExceededException":
3996
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
3997
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
3998
- case "WAFNonexistentContainerException":
3999
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
4000
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
4001
- case "WAFNonexistentItemException":
4002
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
4003
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
4004
- case "WAFReferencedItemException":
4005
- case "com.amazonaws.wafregional#WAFReferencedItemException":
4006
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
4007
- case "WAFStaleDataException":
4008
- case "com.amazonaws.wafregional#WAFStaleDataException":
4009
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
4010
- default:
4011
- const parsedBody = parsedOutput.body;
4012
- return throwDefaultError({
4013
- output,
4014
- parsedBody,
4015
- errorCode,
4016
- });
4017
- }
4018
- };
4019
- const de_UpdateSqlInjectionMatchSetCommand = async (output, context) => {
4020
- if (output.statusCode >= 300) {
4021
- return de_UpdateSqlInjectionMatchSetCommandError(output, context);
4022
- }
4023
- const data = await parseBody(output.body, context);
4024
- let contents = {};
4025
- contents = (0, smithy_client_1._json)(data);
4026
- const response = {
4027
- $metadata: deserializeMetadata(output),
4028
- ...contents,
4029
- };
4030
- return response;
4031
- };
4032
- exports.de_UpdateSqlInjectionMatchSetCommand = de_UpdateSqlInjectionMatchSetCommand;
4033
- const de_UpdateSqlInjectionMatchSetCommandError = async (output, context) => {
4034
- const parsedOutput = {
4035
- ...output,
4036
- body: await parseErrorBody(output.body, context),
4037
- };
4038
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4039
- switch (errorCode) {
4040
- case "WAFInternalErrorException":
4041
- case "com.amazonaws.wafregional#WAFInternalErrorException":
4042
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
4043
- case "WAFInvalidAccountException":
4044
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
4045
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
4046
- case "WAFInvalidOperationException":
4047
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
4048
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
4049
- case "WAFInvalidParameterException":
4050
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
4051
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
4052
- case "WAFLimitsExceededException":
4053
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
4054
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
4055
- case "WAFNonexistentContainerException":
4056
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
4057
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
4058
- case "WAFNonexistentItemException":
4059
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
4060
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
4061
- case "WAFStaleDataException":
4062
- case "com.amazonaws.wafregional#WAFStaleDataException":
4063
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
4064
- default:
4065
- const parsedBody = parsedOutput.body;
4066
- return throwDefaultError({
4067
- output,
4068
- parsedBody,
4069
- errorCode,
4070
- });
4071
- }
4072
- };
4073
- const de_UpdateWebACLCommand = async (output, context) => {
4074
- if (output.statusCode >= 300) {
4075
- return de_UpdateWebACLCommandError(output, context);
4076
- }
4077
- const data = await parseBody(output.body, context);
4078
- let contents = {};
4079
- contents = (0, smithy_client_1._json)(data);
4080
- const response = {
4081
- $metadata: deserializeMetadata(output),
4082
- ...contents,
4083
- };
4084
- return response;
4085
- };
4086
- exports.de_UpdateWebACLCommand = de_UpdateWebACLCommand;
4087
- const de_UpdateWebACLCommandError = async (output, context) => {
4088
- const parsedOutput = {
4089
- ...output,
4090
- body: await parseErrorBody(output.body, context),
4091
- };
4092
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4093
- switch (errorCode) {
4094
- case "WAFInternalErrorException":
4095
- case "com.amazonaws.wafregional#WAFInternalErrorException":
4096
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
4097
- case "WAFInvalidAccountException":
4098
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
4099
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
4100
- case "WAFInvalidOperationException":
4101
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
4102
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
4103
- case "WAFInvalidParameterException":
4104
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
4105
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
4106
- case "WAFLimitsExceededException":
4107
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
4108
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
4109
- case "WAFNonexistentContainerException":
4110
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
4111
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
4112
- case "WAFNonexistentItemException":
4113
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
4114
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
4115
- case "WAFReferencedItemException":
4116
- case "com.amazonaws.wafregional#WAFReferencedItemException":
4117
- throw await de_WAFReferencedItemExceptionRes(parsedOutput, context);
4118
- case "WAFStaleDataException":
4119
- case "com.amazonaws.wafregional#WAFStaleDataException":
4120
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
4121
- case "WAFSubscriptionNotFoundException":
4122
- case "com.amazonaws.wafregional#WAFSubscriptionNotFoundException":
4123
- throw await de_WAFSubscriptionNotFoundExceptionRes(parsedOutput, context);
4124
- default:
4125
- const parsedBody = parsedOutput.body;
4126
- return throwDefaultError({
4127
- output,
4128
- parsedBody,
4129
- errorCode,
4130
- });
4131
- }
4132
- };
4133
- const de_UpdateXssMatchSetCommand = async (output, context) => {
4134
- if (output.statusCode >= 300) {
4135
- return de_UpdateXssMatchSetCommandError(output, context);
4136
- }
4137
- const data = await parseBody(output.body, context);
4138
- let contents = {};
4139
- contents = (0, smithy_client_1._json)(data);
4140
- const response = {
4141
- $metadata: deserializeMetadata(output),
4142
- ...contents,
4143
- };
4144
- return response;
4145
- };
4146
- exports.de_UpdateXssMatchSetCommand = de_UpdateXssMatchSetCommand;
4147
- const de_UpdateXssMatchSetCommandError = async (output, context) => {
4148
- const parsedOutput = {
4149
- ...output,
4150
- body: await parseErrorBody(output.body, context),
4151
- };
4152
- const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4153
- switch (errorCode) {
4154
- case "WAFInternalErrorException":
4155
- case "com.amazonaws.wafregional#WAFInternalErrorException":
4156
- throw await de_WAFInternalErrorExceptionRes(parsedOutput, context);
4157
- case "WAFInvalidAccountException":
4158
- case "com.amazonaws.wafregional#WAFInvalidAccountException":
4159
- throw await de_WAFInvalidAccountExceptionRes(parsedOutput, context);
4160
- case "WAFInvalidOperationException":
4161
- case "com.amazonaws.wafregional#WAFInvalidOperationException":
4162
- throw await de_WAFInvalidOperationExceptionRes(parsedOutput, context);
4163
- case "WAFInvalidParameterException":
4164
- case "com.amazonaws.wafregional#WAFInvalidParameterException":
4165
- throw await de_WAFInvalidParameterExceptionRes(parsedOutput, context);
4166
- case "WAFLimitsExceededException":
4167
- case "com.amazonaws.wafregional#WAFLimitsExceededException":
4168
- throw await de_WAFLimitsExceededExceptionRes(parsedOutput, context);
4169
- case "WAFNonexistentContainerException":
4170
- case "com.amazonaws.wafregional#WAFNonexistentContainerException":
4171
- throw await de_WAFNonexistentContainerExceptionRes(parsedOutput, context);
4172
- case "WAFNonexistentItemException":
4173
- case "com.amazonaws.wafregional#WAFNonexistentItemException":
4174
- throw await de_WAFNonexistentItemExceptionRes(parsedOutput, context);
4175
- case "WAFStaleDataException":
4176
- case "com.amazonaws.wafregional#WAFStaleDataException":
4177
- throw await de_WAFStaleDataExceptionRes(parsedOutput, context);
4178
- default:
4179
- const parsedBody = parsedOutput.body;
4180
- return throwDefaultError({
4181
- output,
4182
- parsedBody,
4183
- errorCode,
4184
- });
4185
- }
4186
- };
4187
- const de_WAFBadRequestExceptionRes = async (parsedOutput, context) => {
4188
- const body = parsedOutput.body;
4189
- const deserialized = (0, smithy_client_1._json)(body);
4190
- const exception = new models_0_1.WAFBadRequestException({
4191
- $metadata: deserializeMetadata(parsedOutput),
4192
- ...deserialized,
4193
- });
4194
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4195
- };
4196
- const de_WAFDisallowedNameExceptionRes = async (parsedOutput, context) => {
4197
- const body = parsedOutput.body;
4198
- const deserialized = (0, smithy_client_1._json)(body);
4199
- const exception = new models_0_1.WAFDisallowedNameException({
4200
- $metadata: deserializeMetadata(parsedOutput),
4201
- ...deserialized,
4202
- });
4203
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4204
- };
4205
- const de_WAFEntityMigrationExceptionRes = async (parsedOutput, context) => {
4206
- const body = parsedOutput.body;
4207
- const deserialized = (0, smithy_client_1._json)(body);
4208
- const exception = new models_0_1.WAFEntityMigrationException({
4209
- $metadata: deserializeMetadata(parsedOutput),
4210
- ...deserialized,
4211
- });
4212
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4213
- };
4214
- const de_WAFInternalErrorExceptionRes = async (parsedOutput, context) => {
4215
- const body = parsedOutput.body;
4216
- const deserialized = (0, smithy_client_1._json)(body);
4217
- const exception = new models_0_1.WAFInternalErrorException({
4218
- $metadata: deserializeMetadata(parsedOutput),
4219
- ...deserialized,
4220
- });
4221
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4222
- };
4223
- const de_WAFInvalidAccountExceptionRes = async (parsedOutput, context) => {
4224
- const body = parsedOutput.body;
4225
- const deserialized = (0, smithy_client_1._json)(body);
4226
- const exception = new models_0_1.WAFInvalidAccountException({
4227
- $metadata: deserializeMetadata(parsedOutput),
4228
- ...deserialized,
4229
- });
4230
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4231
- };
4232
- const de_WAFInvalidOperationExceptionRes = async (parsedOutput, context) => {
4233
- const body = parsedOutput.body;
4234
- const deserialized = (0, smithy_client_1._json)(body);
4235
- const exception = new models_0_1.WAFInvalidOperationException({
4236
- $metadata: deserializeMetadata(parsedOutput),
4237
- ...deserialized,
4238
- });
4239
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4240
- };
4241
- const de_WAFInvalidParameterExceptionRes = async (parsedOutput, context) => {
4242
- const body = parsedOutput.body;
4243
- const deserialized = (0, smithy_client_1._json)(body);
4244
- const exception = new models_0_1.WAFInvalidParameterException({
4245
- $metadata: deserializeMetadata(parsedOutput),
4246
- ...deserialized,
4247
- });
4248
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4249
- };
4250
- const de_WAFInvalidPermissionPolicyExceptionRes = async (parsedOutput, context) => {
4251
- const body = parsedOutput.body;
4252
- const deserialized = (0, smithy_client_1._json)(body);
4253
- const exception = new models_0_1.WAFInvalidPermissionPolicyException({
4254
- $metadata: deserializeMetadata(parsedOutput),
4255
- ...deserialized,
4256
- });
4257
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4258
- };
4259
- const de_WAFInvalidRegexPatternExceptionRes = async (parsedOutput, context) => {
4260
- const body = parsedOutput.body;
4261
- const deserialized = (0, smithy_client_1._json)(body);
4262
- const exception = new models_0_1.WAFInvalidRegexPatternException({
4263
- $metadata: deserializeMetadata(parsedOutput),
4264
- ...deserialized,
4265
- });
4266
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4267
- };
4268
- const de_WAFLimitsExceededExceptionRes = async (parsedOutput, context) => {
4269
- const body = parsedOutput.body;
4270
- const deserialized = (0, smithy_client_1._json)(body);
4271
- const exception = new models_0_1.WAFLimitsExceededException({
4272
- $metadata: deserializeMetadata(parsedOutput),
4273
- ...deserialized,
4274
- });
4275
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4276
- };
4277
- const de_WAFNonEmptyEntityExceptionRes = async (parsedOutput, context) => {
4278
- const body = parsedOutput.body;
4279
- const deserialized = (0, smithy_client_1._json)(body);
4280
- const exception = new models_0_1.WAFNonEmptyEntityException({
4281
- $metadata: deserializeMetadata(parsedOutput),
4282
- ...deserialized,
4283
- });
4284
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4285
- };
4286
- const de_WAFNonexistentContainerExceptionRes = async (parsedOutput, context) => {
4287
- const body = parsedOutput.body;
4288
- const deserialized = (0, smithy_client_1._json)(body);
4289
- const exception = new models_0_1.WAFNonexistentContainerException({
4290
- $metadata: deserializeMetadata(parsedOutput),
4291
- ...deserialized,
4292
- });
4293
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4294
- };
4295
- const de_WAFNonexistentItemExceptionRes = async (parsedOutput, context) => {
4296
- const body = parsedOutput.body;
4297
- const deserialized = (0, smithy_client_1._json)(body);
4298
- const exception = new models_0_1.WAFNonexistentItemException({
4299
- $metadata: deserializeMetadata(parsedOutput),
4300
- ...deserialized,
4301
- });
4302
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4303
- };
4304
- const de_WAFReferencedItemExceptionRes = async (parsedOutput, context) => {
4305
- const body = parsedOutput.body;
4306
- const deserialized = (0, smithy_client_1._json)(body);
4307
- const exception = new models_0_1.WAFReferencedItemException({
4308
- $metadata: deserializeMetadata(parsedOutput),
4309
- ...deserialized,
4310
- });
4311
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4312
- };
4313
- const de_WAFServiceLinkedRoleErrorExceptionRes = async (parsedOutput, context) => {
4314
- const body = parsedOutput.body;
4315
- const deserialized = (0, smithy_client_1._json)(body);
4316
- const exception = new models_0_1.WAFServiceLinkedRoleErrorException({
4317
- $metadata: deserializeMetadata(parsedOutput),
4318
- ...deserialized,
4319
- });
4320
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4321
- };
4322
- const de_WAFStaleDataExceptionRes = async (parsedOutput, context) => {
4323
- const body = parsedOutput.body;
4324
- const deserialized = (0, smithy_client_1._json)(body);
4325
- const exception = new models_0_1.WAFStaleDataException({
4326
- $metadata: deserializeMetadata(parsedOutput),
4327
- ...deserialized,
4328
- });
4329
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4330
- };
4331
- const de_WAFSubscriptionNotFoundExceptionRes = async (parsedOutput, context) => {
4332
- const body = parsedOutput.body;
4333
- const deserialized = (0, smithy_client_1._json)(body);
4334
- const exception = new models_0_1.WAFSubscriptionNotFoundException({
4335
- $metadata: deserializeMetadata(parsedOutput),
4336
- ...deserialized,
4337
- });
4338
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4339
- };
4340
- const de_WAFTagOperationExceptionRes = async (parsedOutput, context) => {
4341
- const body = parsedOutput.body;
4342
- const deserialized = (0, smithy_client_1._json)(body);
4343
- const exception = new models_0_1.WAFTagOperationException({
4344
- $metadata: deserializeMetadata(parsedOutput),
4345
- ...deserialized,
4346
- });
4347
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4348
- };
4349
- const de_WAFTagOperationInternalErrorExceptionRes = async (parsedOutput, context) => {
4350
- const body = parsedOutput.body;
4351
- const deserialized = (0, smithy_client_1._json)(body);
4352
- const exception = new models_0_1.WAFTagOperationInternalErrorException({
4353
- $metadata: deserializeMetadata(parsedOutput),
4354
- ...deserialized,
4355
- });
4356
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4357
- };
4358
- const de_WAFUnavailableEntityExceptionRes = async (parsedOutput, context) => {
4359
- const body = parsedOutput.body;
4360
- const deserialized = (0, smithy_client_1._json)(body);
4361
- const exception = new models_0_1.WAFUnavailableEntityException({
4362
- $metadata: deserializeMetadata(parsedOutput),
4363
- ...deserialized,
4364
- });
4365
- return (0, smithy_client_1.decorateServiceException)(exception, body);
4366
- };
4367
- const se_ByteMatchSetUpdate = (input, context) => {
4368
- return (0, smithy_client_1.take)(input, {
4369
- Action: [],
4370
- ByteMatchTuple: (_) => se_ByteMatchTuple(_, context),
4371
- });
4372
- };
4373
- const se_ByteMatchSetUpdates = (input, context) => {
4374
- return input
4375
- .filter((e) => e != null)
4376
- .map((entry) => {
4377
- return se_ByteMatchSetUpdate(entry, context);
4378
- });
4379
- };
4380
- const se_ByteMatchTuple = (input, context) => {
4381
- return (0, smithy_client_1.take)(input, {
4382
- FieldToMatch: smithy_client_1._json,
4383
- PositionalConstraint: [],
4384
- TargetString: context.base64Encoder,
4385
- TextTransformation: [],
4386
- });
4387
- };
4388
- const se_GetSampledRequestsRequest = (input, context) => {
4389
- return (0, smithy_client_1.take)(input, {
4390
- MaxItems: [],
4391
- RuleId: [],
4392
- TimeWindow: (_) => se_TimeWindow(_, context),
4393
- WebAclId: [],
4394
- });
4395
- };
4396
- const se_TimeWindow = (input, context) => {
4397
- return (0, smithy_client_1.take)(input, {
4398
- EndTime: (_) => Math.round(_.getTime() / 1000),
4399
- StartTime: (_) => Math.round(_.getTime() / 1000),
4400
- });
4401
- };
4402
- const se_UpdateByteMatchSetRequest = (input, context) => {
4403
- return (0, smithy_client_1.take)(input, {
4404
- ByteMatchSetId: [],
4405
- ChangeToken: [],
4406
- Updates: (_) => se_ByteMatchSetUpdates(_, context),
4407
- });
4408
- };
4409
- const de_ByteMatchSet = (output, context) => {
4410
- return (0, smithy_client_1.take)(output, {
4411
- ByteMatchSetId: smithy_client_1.expectString,
4412
- ByteMatchTuples: (_) => de_ByteMatchTuples(_, context),
4413
- Name: smithy_client_1.expectString,
4414
- });
4415
- };
4416
- const de_ByteMatchTuple = (output, context) => {
4417
- return (0, smithy_client_1.take)(output, {
4418
- FieldToMatch: smithy_client_1._json,
4419
- PositionalConstraint: smithy_client_1.expectString,
4420
- TargetString: context.base64Decoder,
4421
- TextTransformation: smithy_client_1.expectString,
4422
- });
4423
- };
4424
- const de_ByteMatchTuples = (output, context) => {
4425
- const retVal = (output || [])
4426
- .filter((e) => e != null)
4427
- .map((entry) => {
4428
- return de_ByteMatchTuple(entry, context);
4429
- });
4430
- return retVal;
4431
- };
4432
- const de_CreateByteMatchSetResponse = (output, context) => {
4433
- return (0, smithy_client_1.take)(output, {
4434
- ByteMatchSet: (_) => de_ByteMatchSet(_, context),
4435
- ChangeToken: smithy_client_1.expectString,
4436
- });
4437
- };
4438
- const de_GetByteMatchSetResponse = (output, context) => {
4439
- return (0, smithy_client_1.take)(output, {
4440
- ByteMatchSet: (_) => de_ByteMatchSet(_, context),
4441
- });
4442
- };
4443
- const de_GetSampledRequestsResponse = (output, context) => {
4444
- return (0, smithy_client_1.take)(output, {
4445
- PopulationSize: smithy_client_1.expectLong,
4446
- SampledRequests: (_) => de_SampledHTTPRequests(_, context),
4447
- TimeWindow: (_) => de_TimeWindow(_, context),
4448
- });
4449
- };
4450
- const de_SampledHTTPRequest = (output, context) => {
4451
- return (0, smithy_client_1.take)(output, {
4452
- Action: smithy_client_1.expectString,
4453
- Request: smithy_client_1._json,
4454
- RuleWithinRuleGroup: smithy_client_1.expectString,
4455
- Timestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4456
- Weight: smithy_client_1.expectLong,
4457
- });
4458
- };
4459
- const de_SampledHTTPRequests = (output, context) => {
4460
- const retVal = (output || [])
4461
- .filter((e) => e != null)
4462
- .map((entry) => {
4463
- return de_SampledHTTPRequest(entry, context);
4464
- });
4465
- return retVal;
4466
- };
4467
- const de_TimeWindow = (output, context) => {
4468
- return (0, smithy_client_1.take)(output, {
4469
- EndTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4470
- StartTime: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
4471
- });
4472
- };
4473
- const deserializeMetadata = (output) => ({
4474
- httpStatusCode: output.statusCode,
4475
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
4476
- extendedRequestId: output.headers["x-amz-id-2"],
4477
- cfId: output.headers["x-amz-cf-id"],
4478
- });
4479
- const collectBodyString = (streamBody, context) => (0, smithy_client_1.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body));
4480
- const throwDefaultError = (0, smithy_client_1.withBaseException)(WAFRegionalServiceException_1.WAFRegionalServiceException);
4481
- const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
4482
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
4483
- const contents = {
4484
- protocol,
4485
- hostname,
4486
- port,
4487
- method: "POST",
4488
- path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
4489
- headers,
4490
- };
4491
- if (resolvedHostname !== undefined) {
4492
- contents.hostname = resolvedHostname;
4493
- }
4494
- if (body !== undefined) {
4495
- contents.body = body;
4496
- }
4497
- return new protocol_http_1.HttpRequest(contents);
4498
- };
4499
- function sharedHeaders(operation) {
4500
- return {
4501
- "content-type": "application/x-amz-json-1.1",
4502
- "x-amz-target": `AWSWAF_Regional_20161128.${operation}`,
4503
- };
4504
- }
4505
- const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
4506
- if (encoded.length) {
4507
- return JSON.parse(encoded);
4508
- }
4509
- return {};
4510
- });
4511
- const parseErrorBody = async (errorBody, context) => {
4512
- const value = await parseBody(errorBody, context);
4513
- value.message = value.message ?? value.Message;
4514
- return value;
4515
- };
4516
- const loadRestJsonErrorCode = (output, data) => {
4517
- const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
4518
- const sanitizeErrorCode = (rawValue) => {
4519
- let cleanValue = rawValue;
4520
- if (typeof cleanValue === "number") {
4521
- cleanValue = cleanValue.toString();
4522
- }
4523
- if (cleanValue.indexOf(",") >= 0) {
4524
- cleanValue = cleanValue.split(",")[0];
4525
- }
4526
- if (cleanValue.indexOf(":") >= 0) {
4527
- cleanValue = cleanValue.split(":")[0];
4528
- }
4529
- if (cleanValue.indexOf("#") >= 0) {
4530
- cleanValue = cleanValue.split("#")[1];
4531
- }
4532
- return cleanValue;
4533
- };
4534
- const headerKey = findKey(output.headers, "x-amzn-errortype");
4535
- if (headerKey !== undefined) {
4536
- return sanitizeErrorCode(output.headers[headerKey]);
4537
- }
4538
- if (data.code !== undefined) {
4539
- return sanitizeErrorCode(data.code);
4540
- }
4541
- if (data["__type"] !== undefined) {
4542
- return sanitizeErrorCode(data["__type"]);
4543
- }
4544
- };
1
+ module.exports = require("../index.js");