@aws-sdk/client-global-accelerator 3.310.0 → 3.312.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.
@@ -8,490 +8,343 @@ const uuid_1 = require("uuid");
8
8
  const GlobalAcceleratorServiceException_1 = require("../models/GlobalAcceleratorServiceException");
9
9
  const models_0_1 = require("../models/models_0");
10
10
  const se_AddCustomRoutingEndpointsCommand = async (input, context) => {
11
- const headers = {
12
- "content-type": "application/x-amz-json-1.1",
13
- "x-amz-target": "GlobalAccelerator_V20180706.AddCustomRoutingEndpoints",
14
- };
11
+ const headers = sharedHeaders("AddCustomRoutingEndpoints");
15
12
  let body;
16
13
  body = JSON.stringify(se_AddCustomRoutingEndpointsRequest(input, context));
17
14
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
18
15
  };
19
16
  exports.se_AddCustomRoutingEndpointsCommand = se_AddCustomRoutingEndpointsCommand;
20
17
  const se_AddEndpointsCommand = async (input, context) => {
21
- const headers = {
22
- "content-type": "application/x-amz-json-1.1",
23
- "x-amz-target": "GlobalAccelerator_V20180706.AddEndpoints",
24
- };
18
+ const headers = sharedHeaders("AddEndpoints");
25
19
  let body;
26
20
  body = JSON.stringify(se_AddEndpointsRequest(input, context));
27
21
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
28
22
  };
29
23
  exports.se_AddEndpointsCommand = se_AddEndpointsCommand;
30
24
  const se_AdvertiseByoipCidrCommand = async (input, context) => {
31
- const headers = {
32
- "content-type": "application/x-amz-json-1.1",
33
- "x-amz-target": "GlobalAccelerator_V20180706.AdvertiseByoipCidr",
34
- };
25
+ const headers = sharedHeaders("AdvertiseByoipCidr");
35
26
  let body;
36
27
  body = JSON.stringify(se_AdvertiseByoipCidrRequest(input, context));
37
28
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
38
29
  };
39
30
  exports.se_AdvertiseByoipCidrCommand = se_AdvertiseByoipCidrCommand;
40
31
  const se_AllowCustomRoutingTrafficCommand = async (input, context) => {
41
- const headers = {
42
- "content-type": "application/x-amz-json-1.1",
43
- "x-amz-target": "GlobalAccelerator_V20180706.AllowCustomRoutingTraffic",
44
- };
32
+ const headers = sharedHeaders("AllowCustomRoutingTraffic");
45
33
  let body;
46
34
  body = JSON.stringify(se_AllowCustomRoutingTrafficRequest(input, context));
47
35
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
48
36
  };
49
37
  exports.se_AllowCustomRoutingTrafficCommand = se_AllowCustomRoutingTrafficCommand;
50
38
  const se_CreateAcceleratorCommand = async (input, context) => {
51
- const headers = {
52
- "content-type": "application/x-amz-json-1.1",
53
- "x-amz-target": "GlobalAccelerator_V20180706.CreateAccelerator",
54
- };
39
+ const headers = sharedHeaders("CreateAccelerator");
55
40
  let body;
56
41
  body = JSON.stringify(se_CreateAcceleratorRequest(input, context));
57
42
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
58
43
  };
59
44
  exports.se_CreateAcceleratorCommand = se_CreateAcceleratorCommand;
60
45
  const se_CreateCustomRoutingAcceleratorCommand = async (input, context) => {
61
- const headers = {
62
- "content-type": "application/x-amz-json-1.1",
63
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingAccelerator",
64
- };
46
+ const headers = sharedHeaders("CreateCustomRoutingAccelerator");
65
47
  let body;
66
48
  body = JSON.stringify(se_CreateCustomRoutingAcceleratorRequest(input, context));
67
49
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
68
50
  };
69
51
  exports.se_CreateCustomRoutingAcceleratorCommand = se_CreateCustomRoutingAcceleratorCommand;
70
52
  const se_CreateCustomRoutingEndpointGroupCommand = async (input, context) => {
71
- const headers = {
72
- "content-type": "application/x-amz-json-1.1",
73
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingEndpointGroup",
74
- };
53
+ const headers = sharedHeaders("CreateCustomRoutingEndpointGroup");
75
54
  let body;
76
55
  body = JSON.stringify(se_CreateCustomRoutingEndpointGroupRequest(input, context));
77
56
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
78
57
  };
79
58
  exports.se_CreateCustomRoutingEndpointGroupCommand = se_CreateCustomRoutingEndpointGroupCommand;
80
59
  const se_CreateCustomRoutingListenerCommand = async (input, context) => {
81
- const headers = {
82
- "content-type": "application/x-amz-json-1.1",
83
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingListener",
84
- };
60
+ const headers = sharedHeaders("CreateCustomRoutingListener");
85
61
  let body;
86
62
  body = JSON.stringify(se_CreateCustomRoutingListenerRequest(input, context));
87
63
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
88
64
  };
89
65
  exports.se_CreateCustomRoutingListenerCommand = se_CreateCustomRoutingListenerCommand;
90
66
  const se_CreateEndpointGroupCommand = async (input, context) => {
91
- const headers = {
92
- "content-type": "application/x-amz-json-1.1",
93
- "x-amz-target": "GlobalAccelerator_V20180706.CreateEndpointGroup",
94
- };
67
+ const headers = sharedHeaders("CreateEndpointGroup");
95
68
  let body;
96
69
  body = JSON.stringify(se_CreateEndpointGroupRequest(input, context));
97
70
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
98
71
  };
99
72
  exports.se_CreateEndpointGroupCommand = se_CreateEndpointGroupCommand;
100
73
  const se_CreateListenerCommand = async (input, context) => {
101
- const headers = {
102
- "content-type": "application/x-amz-json-1.1",
103
- "x-amz-target": "GlobalAccelerator_V20180706.CreateListener",
104
- };
74
+ const headers = sharedHeaders("CreateListener");
105
75
  let body;
106
76
  body = JSON.stringify(se_CreateListenerRequest(input, context));
107
77
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
108
78
  };
109
79
  exports.se_CreateListenerCommand = se_CreateListenerCommand;
110
80
  const se_DeleteAcceleratorCommand = async (input, context) => {
111
- const headers = {
112
- "content-type": "application/x-amz-json-1.1",
113
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteAccelerator",
114
- };
81
+ const headers = sharedHeaders("DeleteAccelerator");
115
82
  let body;
116
83
  body = JSON.stringify(se_DeleteAcceleratorRequest(input, context));
117
84
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
118
85
  };
119
86
  exports.se_DeleteAcceleratorCommand = se_DeleteAcceleratorCommand;
120
87
  const se_DeleteCustomRoutingAcceleratorCommand = async (input, context) => {
121
- const headers = {
122
- "content-type": "application/x-amz-json-1.1",
123
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingAccelerator",
124
- };
88
+ const headers = sharedHeaders("DeleteCustomRoutingAccelerator");
125
89
  let body;
126
90
  body = JSON.stringify(se_DeleteCustomRoutingAcceleratorRequest(input, context));
127
91
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
128
92
  };
129
93
  exports.se_DeleteCustomRoutingAcceleratorCommand = se_DeleteCustomRoutingAcceleratorCommand;
130
94
  const se_DeleteCustomRoutingEndpointGroupCommand = async (input, context) => {
131
- const headers = {
132
- "content-type": "application/x-amz-json-1.1",
133
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingEndpointGroup",
134
- };
95
+ const headers = sharedHeaders("DeleteCustomRoutingEndpointGroup");
135
96
  let body;
136
97
  body = JSON.stringify(se_DeleteCustomRoutingEndpointGroupRequest(input, context));
137
98
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
138
99
  };
139
100
  exports.se_DeleteCustomRoutingEndpointGroupCommand = se_DeleteCustomRoutingEndpointGroupCommand;
140
101
  const se_DeleteCustomRoutingListenerCommand = async (input, context) => {
141
- const headers = {
142
- "content-type": "application/x-amz-json-1.1",
143
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingListener",
144
- };
102
+ const headers = sharedHeaders("DeleteCustomRoutingListener");
145
103
  let body;
146
104
  body = JSON.stringify(se_DeleteCustomRoutingListenerRequest(input, context));
147
105
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
148
106
  };
149
107
  exports.se_DeleteCustomRoutingListenerCommand = se_DeleteCustomRoutingListenerCommand;
150
108
  const se_DeleteEndpointGroupCommand = async (input, context) => {
151
- const headers = {
152
- "content-type": "application/x-amz-json-1.1",
153
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteEndpointGroup",
154
- };
109
+ const headers = sharedHeaders("DeleteEndpointGroup");
155
110
  let body;
156
111
  body = JSON.stringify(se_DeleteEndpointGroupRequest(input, context));
157
112
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
158
113
  };
159
114
  exports.se_DeleteEndpointGroupCommand = se_DeleteEndpointGroupCommand;
160
115
  const se_DeleteListenerCommand = async (input, context) => {
161
- const headers = {
162
- "content-type": "application/x-amz-json-1.1",
163
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteListener",
164
- };
116
+ const headers = sharedHeaders("DeleteListener");
165
117
  let body;
166
118
  body = JSON.stringify(se_DeleteListenerRequest(input, context));
167
119
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
168
120
  };
169
121
  exports.se_DeleteListenerCommand = se_DeleteListenerCommand;
170
122
  const se_DenyCustomRoutingTrafficCommand = async (input, context) => {
171
- const headers = {
172
- "content-type": "application/x-amz-json-1.1",
173
- "x-amz-target": "GlobalAccelerator_V20180706.DenyCustomRoutingTraffic",
174
- };
123
+ const headers = sharedHeaders("DenyCustomRoutingTraffic");
175
124
  let body;
176
125
  body = JSON.stringify(se_DenyCustomRoutingTrafficRequest(input, context));
177
126
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
178
127
  };
179
128
  exports.se_DenyCustomRoutingTrafficCommand = se_DenyCustomRoutingTrafficCommand;
180
129
  const se_DeprovisionByoipCidrCommand = async (input, context) => {
181
- const headers = {
182
- "content-type": "application/x-amz-json-1.1",
183
- "x-amz-target": "GlobalAccelerator_V20180706.DeprovisionByoipCidr",
184
- };
130
+ const headers = sharedHeaders("DeprovisionByoipCidr");
185
131
  let body;
186
132
  body = JSON.stringify(se_DeprovisionByoipCidrRequest(input, context));
187
133
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
188
134
  };
189
135
  exports.se_DeprovisionByoipCidrCommand = se_DeprovisionByoipCidrCommand;
190
136
  const se_DescribeAcceleratorCommand = async (input, context) => {
191
- const headers = {
192
- "content-type": "application/x-amz-json-1.1",
193
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeAccelerator",
194
- };
137
+ const headers = sharedHeaders("DescribeAccelerator");
195
138
  let body;
196
139
  body = JSON.stringify(se_DescribeAcceleratorRequest(input, context));
197
140
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
198
141
  };
199
142
  exports.se_DescribeAcceleratorCommand = se_DescribeAcceleratorCommand;
200
143
  const se_DescribeAcceleratorAttributesCommand = async (input, context) => {
201
- const headers = {
202
- "content-type": "application/x-amz-json-1.1",
203
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeAcceleratorAttributes",
204
- };
144
+ const headers = sharedHeaders("DescribeAcceleratorAttributes");
205
145
  let body;
206
146
  body = JSON.stringify(se_DescribeAcceleratorAttributesRequest(input, context));
207
147
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
208
148
  };
209
149
  exports.se_DescribeAcceleratorAttributesCommand = se_DescribeAcceleratorAttributesCommand;
210
150
  const se_DescribeCustomRoutingAcceleratorCommand = async (input, context) => {
211
- const headers = {
212
- "content-type": "application/x-amz-json-1.1",
213
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingAccelerator",
214
- };
151
+ const headers = sharedHeaders("DescribeCustomRoutingAccelerator");
215
152
  let body;
216
153
  body = JSON.stringify(se_DescribeCustomRoutingAcceleratorRequest(input, context));
217
154
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
218
155
  };
219
156
  exports.se_DescribeCustomRoutingAcceleratorCommand = se_DescribeCustomRoutingAcceleratorCommand;
220
157
  const se_DescribeCustomRoutingAcceleratorAttributesCommand = async (input, context) => {
221
- const headers = {
222
- "content-type": "application/x-amz-json-1.1",
223
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingAcceleratorAttributes",
224
- };
158
+ const headers = sharedHeaders("DescribeCustomRoutingAcceleratorAttributes");
225
159
  let body;
226
160
  body = JSON.stringify(se_DescribeCustomRoutingAcceleratorAttributesRequest(input, context));
227
161
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
228
162
  };
229
163
  exports.se_DescribeCustomRoutingAcceleratorAttributesCommand = se_DescribeCustomRoutingAcceleratorAttributesCommand;
230
164
  const se_DescribeCustomRoutingEndpointGroupCommand = async (input, context) => {
231
- const headers = {
232
- "content-type": "application/x-amz-json-1.1",
233
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingEndpointGroup",
234
- };
165
+ const headers = sharedHeaders("DescribeCustomRoutingEndpointGroup");
235
166
  let body;
236
167
  body = JSON.stringify(se_DescribeCustomRoutingEndpointGroupRequest(input, context));
237
168
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
238
169
  };
239
170
  exports.se_DescribeCustomRoutingEndpointGroupCommand = se_DescribeCustomRoutingEndpointGroupCommand;
240
171
  const se_DescribeCustomRoutingListenerCommand = async (input, context) => {
241
- const headers = {
242
- "content-type": "application/x-amz-json-1.1",
243
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingListener",
244
- };
172
+ const headers = sharedHeaders("DescribeCustomRoutingListener");
245
173
  let body;
246
174
  body = JSON.stringify(se_DescribeCustomRoutingListenerRequest(input, context));
247
175
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
248
176
  };
249
177
  exports.se_DescribeCustomRoutingListenerCommand = se_DescribeCustomRoutingListenerCommand;
250
178
  const se_DescribeEndpointGroupCommand = async (input, context) => {
251
- const headers = {
252
- "content-type": "application/x-amz-json-1.1",
253
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeEndpointGroup",
254
- };
179
+ const headers = sharedHeaders("DescribeEndpointGroup");
255
180
  let body;
256
181
  body = JSON.stringify(se_DescribeEndpointGroupRequest(input, context));
257
182
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
258
183
  };
259
184
  exports.se_DescribeEndpointGroupCommand = se_DescribeEndpointGroupCommand;
260
185
  const se_DescribeListenerCommand = async (input, context) => {
261
- const headers = {
262
- "content-type": "application/x-amz-json-1.1",
263
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeListener",
264
- };
186
+ const headers = sharedHeaders("DescribeListener");
265
187
  let body;
266
188
  body = JSON.stringify(se_DescribeListenerRequest(input, context));
267
189
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
268
190
  };
269
191
  exports.se_DescribeListenerCommand = se_DescribeListenerCommand;
270
192
  const se_ListAcceleratorsCommand = async (input, context) => {
271
- const headers = {
272
- "content-type": "application/x-amz-json-1.1",
273
- "x-amz-target": "GlobalAccelerator_V20180706.ListAccelerators",
274
- };
193
+ const headers = sharedHeaders("ListAccelerators");
275
194
  let body;
276
195
  body = JSON.stringify(se_ListAcceleratorsRequest(input, context));
277
196
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
278
197
  };
279
198
  exports.se_ListAcceleratorsCommand = se_ListAcceleratorsCommand;
280
199
  const se_ListByoipCidrsCommand = async (input, context) => {
281
- const headers = {
282
- "content-type": "application/x-amz-json-1.1",
283
- "x-amz-target": "GlobalAccelerator_V20180706.ListByoipCidrs",
284
- };
200
+ const headers = sharedHeaders("ListByoipCidrs");
285
201
  let body;
286
202
  body = JSON.stringify(se_ListByoipCidrsRequest(input, context));
287
203
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
288
204
  };
289
205
  exports.se_ListByoipCidrsCommand = se_ListByoipCidrsCommand;
290
206
  const se_ListCustomRoutingAcceleratorsCommand = async (input, context) => {
291
- const headers = {
292
- "content-type": "application/x-amz-json-1.1",
293
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingAccelerators",
294
- };
207
+ const headers = sharedHeaders("ListCustomRoutingAccelerators");
295
208
  let body;
296
209
  body = JSON.stringify(se_ListCustomRoutingAcceleratorsRequest(input, context));
297
210
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
298
211
  };
299
212
  exports.se_ListCustomRoutingAcceleratorsCommand = se_ListCustomRoutingAcceleratorsCommand;
300
213
  const se_ListCustomRoutingEndpointGroupsCommand = async (input, context) => {
301
- const headers = {
302
- "content-type": "application/x-amz-json-1.1",
303
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingEndpointGroups",
304
- };
214
+ const headers = sharedHeaders("ListCustomRoutingEndpointGroups");
305
215
  let body;
306
216
  body = JSON.stringify(se_ListCustomRoutingEndpointGroupsRequest(input, context));
307
217
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
308
218
  };
309
219
  exports.se_ListCustomRoutingEndpointGroupsCommand = se_ListCustomRoutingEndpointGroupsCommand;
310
220
  const se_ListCustomRoutingListenersCommand = async (input, context) => {
311
- const headers = {
312
- "content-type": "application/x-amz-json-1.1",
313
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingListeners",
314
- };
221
+ const headers = sharedHeaders("ListCustomRoutingListeners");
315
222
  let body;
316
223
  body = JSON.stringify(se_ListCustomRoutingListenersRequest(input, context));
317
224
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
318
225
  };
319
226
  exports.se_ListCustomRoutingListenersCommand = se_ListCustomRoutingListenersCommand;
320
227
  const se_ListCustomRoutingPortMappingsCommand = async (input, context) => {
321
- const headers = {
322
- "content-type": "application/x-amz-json-1.1",
323
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingPortMappings",
324
- };
228
+ const headers = sharedHeaders("ListCustomRoutingPortMappings");
325
229
  let body;
326
230
  body = JSON.stringify(se_ListCustomRoutingPortMappingsRequest(input, context));
327
231
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
328
232
  };
329
233
  exports.se_ListCustomRoutingPortMappingsCommand = se_ListCustomRoutingPortMappingsCommand;
330
234
  const se_ListCustomRoutingPortMappingsByDestinationCommand = async (input, context) => {
331
- const headers = {
332
- "content-type": "application/x-amz-json-1.1",
333
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingPortMappingsByDestination",
334
- };
235
+ const headers = sharedHeaders("ListCustomRoutingPortMappingsByDestination");
335
236
  let body;
336
237
  body = JSON.stringify(se_ListCustomRoutingPortMappingsByDestinationRequest(input, context));
337
238
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
338
239
  };
339
240
  exports.se_ListCustomRoutingPortMappingsByDestinationCommand = se_ListCustomRoutingPortMappingsByDestinationCommand;
340
241
  const se_ListEndpointGroupsCommand = async (input, context) => {
341
- const headers = {
342
- "content-type": "application/x-amz-json-1.1",
343
- "x-amz-target": "GlobalAccelerator_V20180706.ListEndpointGroups",
344
- };
242
+ const headers = sharedHeaders("ListEndpointGroups");
345
243
  let body;
346
244
  body = JSON.stringify(se_ListEndpointGroupsRequest(input, context));
347
245
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
348
246
  };
349
247
  exports.se_ListEndpointGroupsCommand = se_ListEndpointGroupsCommand;
350
248
  const se_ListListenersCommand = async (input, context) => {
351
- const headers = {
352
- "content-type": "application/x-amz-json-1.1",
353
- "x-amz-target": "GlobalAccelerator_V20180706.ListListeners",
354
- };
249
+ const headers = sharedHeaders("ListListeners");
355
250
  let body;
356
251
  body = JSON.stringify(se_ListListenersRequest(input, context));
357
252
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
358
253
  };
359
254
  exports.se_ListListenersCommand = se_ListListenersCommand;
360
255
  const se_ListTagsForResourceCommand = async (input, context) => {
361
- const headers = {
362
- "content-type": "application/x-amz-json-1.1",
363
- "x-amz-target": "GlobalAccelerator_V20180706.ListTagsForResource",
364
- };
256
+ const headers = sharedHeaders("ListTagsForResource");
365
257
  let body;
366
258
  body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
367
259
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
368
260
  };
369
261
  exports.se_ListTagsForResourceCommand = se_ListTagsForResourceCommand;
370
262
  const se_ProvisionByoipCidrCommand = async (input, context) => {
371
- const headers = {
372
- "content-type": "application/x-amz-json-1.1",
373
- "x-amz-target": "GlobalAccelerator_V20180706.ProvisionByoipCidr",
374
- };
263
+ const headers = sharedHeaders("ProvisionByoipCidr");
375
264
  let body;
376
265
  body = JSON.stringify(se_ProvisionByoipCidrRequest(input, context));
377
266
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
378
267
  };
379
268
  exports.se_ProvisionByoipCidrCommand = se_ProvisionByoipCidrCommand;
380
269
  const se_RemoveCustomRoutingEndpointsCommand = async (input, context) => {
381
- const headers = {
382
- "content-type": "application/x-amz-json-1.1",
383
- "x-amz-target": "GlobalAccelerator_V20180706.RemoveCustomRoutingEndpoints",
384
- };
270
+ const headers = sharedHeaders("RemoveCustomRoutingEndpoints");
385
271
  let body;
386
272
  body = JSON.stringify(se_RemoveCustomRoutingEndpointsRequest(input, context));
387
273
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
388
274
  };
389
275
  exports.se_RemoveCustomRoutingEndpointsCommand = se_RemoveCustomRoutingEndpointsCommand;
390
276
  const se_RemoveEndpointsCommand = async (input, context) => {
391
- const headers = {
392
- "content-type": "application/x-amz-json-1.1",
393
- "x-amz-target": "GlobalAccelerator_V20180706.RemoveEndpoints",
394
- };
277
+ const headers = sharedHeaders("RemoveEndpoints");
395
278
  let body;
396
279
  body = JSON.stringify(se_RemoveEndpointsRequest(input, context));
397
280
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
398
281
  };
399
282
  exports.se_RemoveEndpointsCommand = se_RemoveEndpointsCommand;
400
283
  const se_TagResourceCommand = async (input, context) => {
401
- const headers = {
402
- "content-type": "application/x-amz-json-1.1",
403
- "x-amz-target": "GlobalAccelerator_V20180706.TagResource",
404
- };
284
+ const headers = sharedHeaders("TagResource");
405
285
  let body;
406
286
  body = JSON.stringify(se_TagResourceRequest(input, context));
407
287
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
408
288
  };
409
289
  exports.se_TagResourceCommand = se_TagResourceCommand;
410
290
  const se_UntagResourceCommand = async (input, context) => {
411
- const headers = {
412
- "content-type": "application/x-amz-json-1.1",
413
- "x-amz-target": "GlobalAccelerator_V20180706.UntagResource",
414
- };
291
+ const headers = sharedHeaders("UntagResource");
415
292
  let body;
416
293
  body = JSON.stringify(se_UntagResourceRequest(input, context));
417
294
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
418
295
  };
419
296
  exports.se_UntagResourceCommand = se_UntagResourceCommand;
420
297
  const se_UpdateAcceleratorCommand = async (input, context) => {
421
- const headers = {
422
- "content-type": "application/x-amz-json-1.1",
423
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateAccelerator",
424
- };
298
+ const headers = sharedHeaders("UpdateAccelerator");
425
299
  let body;
426
300
  body = JSON.stringify(se_UpdateAcceleratorRequest(input, context));
427
301
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
428
302
  };
429
303
  exports.se_UpdateAcceleratorCommand = se_UpdateAcceleratorCommand;
430
304
  const se_UpdateAcceleratorAttributesCommand = async (input, context) => {
431
- const headers = {
432
- "content-type": "application/x-amz-json-1.1",
433
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateAcceleratorAttributes",
434
- };
305
+ const headers = sharedHeaders("UpdateAcceleratorAttributes");
435
306
  let body;
436
307
  body = JSON.stringify(se_UpdateAcceleratorAttributesRequest(input, context));
437
308
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
438
309
  };
439
310
  exports.se_UpdateAcceleratorAttributesCommand = se_UpdateAcceleratorAttributesCommand;
440
311
  const se_UpdateCustomRoutingAcceleratorCommand = async (input, context) => {
441
- const headers = {
442
- "content-type": "application/x-amz-json-1.1",
443
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingAccelerator",
444
- };
312
+ const headers = sharedHeaders("UpdateCustomRoutingAccelerator");
445
313
  let body;
446
314
  body = JSON.stringify(se_UpdateCustomRoutingAcceleratorRequest(input, context));
447
315
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
448
316
  };
449
317
  exports.se_UpdateCustomRoutingAcceleratorCommand = se_UpdateCustomRoutingAcceleratorCommand;
450
318
  const se_UpdateCustomRoutingAcceleratorAttributesCommand = async (input, context) => {
451
- const headers = {
452
- "content-type": "application/x-amz-json-1.1",
453
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingAcceleratorAttributes",
454
- };
319
+ const headers = sharedHeaders("UpdateCustomRoutingAcceleratorAttributes");
455
320
  let body;
456
321
  body = JSON.stringify(se_UpdateCustomRoutingAcceleratorAttributesRequest(input, context));
457
322
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
458
323
  };
459
324
  exports.se_UpdateCustomRoutingAcceleratorAttributesCommand = se_UpdateCustomRoutingAcceleratorAttributesCommand;
460
325
  const se_UpdateCustomRoutingListenerCommand = async (input, context) => {
461
- const headers = {
462
- "content-type": "application/x-amz-json-1.1",
463
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingListener",
464
- };
326
+ const headers = sharedHeaders("UpdateCustomRoutingListener");
465
327
  let body;
466
328
  body = JSON.stringify(se_UpdateCustomRoutingListenerRequest(input, context));
467
329
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
468
330
  };
469
331
  exports.se_UpdateCustomRoutingListenerCommand = se_UpdateCustomRoutingListenerCommand;
470
332
  const se_UpdateEndpointGroupCommand = async (input, context) => {
471
- const headers = {
472
- "content-type": "application/x-amz-json-1.1",
473
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateEndpointGroup",
474
- };
333
+ const headers = sharedHeaders("UpdateEndpointGroup");
475
334
  let body;
476
335
  body = JSON.stringify(se_UpdateEndpointGroupRequest(input, context));
477
336
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
478
337
  };
479
338
  exports.se_UpdateEndpointGroupCommand = se_UpdateEndpointGroupCommand;
480
339
  const se_UpdateListenerCommand = async (input, context) => {
481
- const headers = {
482
- "content-type": "application/x-amz-json-1.1",
483
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateListener",
484
- };
340
+ const headers = sharedHeaders("UpdateListener");
485
341
  let body;
486
342
  body = JSON.stringify(se_UpdateListenerRequest(input, context));
487
343
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
488
344
  };
489
345
  exports.se_UpdateListenerCommand = se_UpdateListenerCommand;
490
346
  const se_WithdrawByoipCidrCommand = async (input, context) => {
491
- const headers = {
492
- "content-type": "application/x-amz-json-1.1",
493
- "x-amz-target": "GlobalAccelerator_V20180706.WithdrawByoipCidr",
494
- };
347
+ const headers = sharedHeaders("WithdrawByoipCidr");
495
348
  let body;
496
349
  body = JSON.stringify(se_WithdrawByoipCidrRequest(input, context));
497
350
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
@@ -4032,6 +3885,12 @@ const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, bod
4032
3885
  }
4033
3886
  return new protocol_http_1.HttpRequest(contents);
4034
3887
  };
3888
+ function sharedHeaders(operation) {
3889
+ return {
3890
+ "content-type": "application/x-amz-json-1.1",
3891
+ "x-amz-target": `GlobalAccelerator_V20180706.${operation}`,
3892
+ };
3893
+ }
4035
3894
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
4036
3895
  if (encoded.length) {
4037
3896
  return JSON.parse(encoded);
@@ -4,442 +4,295 @@ import { v4 as generateIdempotencyToken } from "uuid";
4
4
  import { GlobalAcceleratorServiceException as __BaseException } from "../models/GlobalAcceleratorServiceException";
5
5
  import { AcceleratorNotDisabledException, AcceleratorNotFoundException, AccessDeniedException, AssociatedEndpointGroupFoundException, AssociatedListenerFoundException, ByoipCidrNotFoundException, ConflictException, EndpointAlreadyExistsException, EndpointGroupAlreadyExistsException, EndpointGroupNotFoundException, EndpointNotFoundException, IncorrectCidrStateException, InternalServiceErrorException, InvalidArgumentException, InvalidNextTokenException, InvalidPortRangeException, LimitExceededException, ListenerNotFoundException, TransactionInProgressException, } from "../models/models_0";
6
6
  export const se_AddCustomRoutingEndpointsCommand = async (input, context) => {
7
- const headers = {
8
- "content-type": "application/x-amz-json-1.1",
9
- "x-amz-target": "GlobalAccelerator_V20180706.AddCustomRoutingEndpoints",
10
- };
7
+ const headers = sharedHeaders("AddCustomRoutingEndpoints");
11
8
  let body;
12
9
  body = JSON.stringify(se_AddCustomRoutingEndpointsRequest(input, context));
13
10
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
14
11
  };
15
12
  export const se_AddEndpointsCommand = async (input, context) => {
16
- const headers = {
17
- "content-type": "application/x-amz-json-1.1",
18
- "x-amz-target": "GlobalAccelerator_V20180706.AddEndpoints",
19
- };
13
+ const headers = sharedHeaders("AddEndpoints");
20
14
  let body;
21
15
  body = JSON.stringify(se_AddEndpointsRequest(input, context));
22
16
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
23
17
  };
24
18
  export const se_AdvertiseByoipCidrCommand = async (input, context) => {
25
- const headers = {
26
- "content-type": "application/x-amz-json-1.1",
27
- "x-amz-target": "GlobalAccelerator_V20180706.AdvertiseByoipCidr",
28
- };
19
+ const headers = sharedHeaders("AdvertiseByoipCidr");
29
20
  let body;
30
21
  body = JSON.stringify(se_AdvertiseByoipCidrRequest(input, context));
31
22
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
32
23
  };
33
24
  export const se_AllowCustomRoutingTrafficCommand = async (input, context) => {
34
- const headers = {
35
- "content-type": "application/x-amz-json-1.1",
36
- "x-amz-target": "GlobalAccelerator_V20180706.AllowCustomRoutingTraffic",
37
- };
25
+ const headers = sharedHeaders("AllowCustomRoutingTraffic");
38
26
  let body;
39
27
  body = JSON.stringify(se_AllowCustomRoutingTrafficRequest(input, context));
40
28
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
41
29
  };
42
30
  export const se_CreateAcceleratorCommand = async (input, context) => {
43
- const headers = {
44
- "content-type": "application/x-amz-json-1.1",
45
- "x-amz-target": "GlobalAccelerator_V20180706.CreateAccelerator",
46
- };
31
+ const headers = sharedHeaders("CreateAccelerator");
47
32
  let body;
48
33
  body = JSON.stringify(se_CreateAcceleratorRequest(input, context));
49
34
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
50
35
  };
51
36
  export const se_CreateCustomRoutingAcceleratorCommand = async (input, context) => {
52
- const headers = {
53
- "content-type": "application/x-amz-json-1.1",
54
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingAccelerator",
55
- };
37
+ const headers = sharedHeaders("CreateCustomRoutingAccelerator");
56
38
  let body;
57
39
  body = JSON.stringify(se_CreateCustomRoutingAcceleratorRequest(input, context));
58
40
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
59
41
  };
60
42
  export const se_CreateCustomRoutingEndpointGroupCommand = async (input, context) => {
61
- const headers = {
62
- "content-type": "application/x-amz-json-1.1",
63
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingEndpointGroup",
64
- };
43
+ const headers = sharedHeaders("CreateCustomRoutingEndpointGroup");
65
44
  let body;
66
45
  body = JSON.stringify(se_CreateCustomRoutingEndpointGroupRequest(input, context));
67
46
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
68
47
  };
69
48
  export const se_CreateCustomRoutingListenerCommand = async (input, context) => {
70
- const headers = {
71
- "content-type": "application/x-amz-json-1.1",
72
- "x-amz-target": "GlobalAccelerator_V20180706.CreateCustomRoutingListener",
73
- };
49
+ const headers = sharedHeaders("CreateCustomRoutingListener");
74
50
  let body;
75
51
  body = JSON.stringify(se_CreateCustomRoutingListenerRequest(input, context));
76
52
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
77
53
  };
78
54
  export const se_CreateEndpointGroupCommand = async (input, context) => {
79
- const headers = {
80
- "content-type": "application/x-amz-json-1.1",
81
- "x-amz-target": "GlobalAccelerator_V20180706.CreateEndpointGroup",
82
- };
55
+ const headers = sharedHeaders("CreateEndpointGroup");
83
56
  let body;
84
57
  body = JSON.stringify(se_CreateEndpointGroupRequest(input, context));
85
58
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
86
59
  };
87
60
  export const se_CreateListenerCommand = async (input, context) => {
88
- const headers = {
89
- "content-type": "application/x-amz-json-1.1",
90
- "x-amz-target": "GlobalAccelerator_V20180706.CreateListener",
91
- };
61
+ const headers = sharedHeaders("CreateListener");
92
62
  let body;
93
63
  body = JSON.stringify(se_CreateListenerRequest(input, context));
94
64
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
95
65
  };
96
66
  export const se_DeleteAcceleratorCommand = async (input, context) => {
97
- const headers = {
98
- "content-type": "application/x-amz-json-1.1",
99
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteAccelerator",
100
- };
67
+ const headers = sharedHeaders("DeleteAccelerator");
101
68
  let body;
102
69
  body = JSON.stringify(se_DeleteAcceleratorRequest(input, context));
103
70
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
104
71
  };
105
72
  export const se_DeleteCustomRoutingAcceleratorCommand = async (input, context) => {
106
- const headers = {
107
- "content-type": "application/x-amz-json-1.1",
108
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingAccelerator",
109
- };
73
+ const headers = sharedHeaders("DeleteCustomRoutingAccelerator");
110
74
  let body;
111
75
  body = JSON.stringify(se_DeleteCustomRoutingAcceleratorRequest(input, context));
112
76
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
113
77
  };
114
78
  export const se_DeleteCustomRoutingEndpointGroupCommand = async (input, context) => {
115
- const headers = {
116
- "content-type": "application/x-amz-json-1.1",
117
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingEndpointGroup",
118
- };
79
+ const headers = sharedHeaders("DeleteCustomRoutingEndpointGroup");
119
80
  let body;
120
81
  body = JSON.stringify(se_DeleteCustomRoutingEndpointGroupRequest(input, context));
121
82
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
122
83
  };
123
84
  export const se_DeleteCustomRoutingListenerCommand = async (input, context) => {
124
- const headers = {
125
- "content-type": "application/x-amz-json-1.1",
126
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteCustomRoutingListener",
127
- };
85
+ const headers = sharedHeaders("DeleteCustomRoutingListener");
128
86
  let body;
129
87
  body = JSON.stringify(se_DeleteCustomRoutingListenerRequest(input, context));
130
88
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
131
89
  };
132
90
  export const se_DeleteEndpointGroupCommand = async (input, context) => {
133
- const headers = {
134
- "content-type": "application/x-amz-json-1.1",
135
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteEndpointGroup",
136
- };
91
+ const headers = sharedHeaders("DeleteEndpointGroup");
137
92
  let body;
138
93
  body = JSON.stringify(se_DeleteEndpointGroupRequest(input, context));
139
94
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
140
95
  };
141
96
  export const se_DeleteListenerCommand = async (input, context) => {
142
- const headers = {
143
- "content-type": "application/x-amz-json-1.1",
144
- "x-amz-target": "GlobalAccelerator_V20180706.DeleteListener",
145
- };
97
+ const headers = sharedHeaders("DeleteListener");
146
98
  let body;
147
99
  body = JSON.stringify(se_DeleteListenerRequest(input, context));
148
100
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
149
101
  };
150
102
  export const se_DenyCustomRoutingTrafficCommand = async (input, context) => {
151
- const headers = {
152
- "content-type": "application/x-amz-json-1.1",
153
- "x-amz-target": "GlobalAccelerator_V20180706.DenyCustomRoutingTraffic",
154
- };
103
+ const headers = sharedHeaders("DenyCustomRoutingTraffic");
155
104
  let body;
156
105
  body = JSON.stringify(se_DenyCustomRoutingTrafficRequest(input, context));
157
106
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
158
107
  };
159
108
  export const se_DeprovisionByoipCidrCommand = async (input, context) => {
160
- const headers = {
161
- "content-type": "application/x-amz-json-1.1",
162
- "x-amz-target": "GlobalAccelerator_V20180706.DeprovisionByoipCidr",
163
- };
109
+ const headers = sharedHeaders("DeprovisionByoipCidr");
164
110
  let body;
165
111
  body = JSON.stringify(se_DeprovisionByoipCidrRequest(input, context));
166
112
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
167
113
  };
168
114
  export const se_DescribeAcceleratorCommand = async (input, context) => {
169
- const headers = {
170
- "content-type": "application/x-amz-json-1.1",
171
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeAccelerator",
172
- };
115
+ const headers = sharedHeaders("DescribeAccelerator");
173
116
  let body;
174
117
  body = JSON.stringify(se_DescribeAcceleratorRequest(input, context));
175
118
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
176
119
  };
177
120
  export const se_DescribeAcceleratorAttributesCommand = async (input, context) => {
178
- const headers = {
179
- "content-type": "application/x-amz-json-1.1",
180
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeAcceleratorAttributes",
181
- };
121
+ const headers = sharedHeaders("DescribeAcceleratorAttributes");
182
122
  let body;
183
123
  body = JSON.stringify(se_DescribeAcceleratorAttributesRequest(input, context));
184
124
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
185
125
  };
186
126
  export const se_DescribeCustomRoutingAcceleratorCommand = async (input, context) => {
187
- const headers = {
188
- "content-type": "application/x-amz-json-1.1",
189
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingAccelerator",
190
- };
127
+ const headers = sharedHeaders("DescribeCustomRoutingAccelerator");
191
128
  let body;
192
129
  body = JSON.stringify(se_DescribeCustomRoutingAcceleratorRequest(input, context));
193
130
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
194
131
  };
195
132
  export const se_DescribeCustomRoutingAcceleratorAttributesCommand = async (input, context) => {
196
- const headers = {
197
- "content-type": "application/x-amz-json-1.1",
198
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingAcceleratorAttributes",
199
- };
133
+ const headers = sharedHeaders("DescribeCustomRoutingAcceleratorAttributes");
200
134
  let body;
201
135
  body = JSON.stringify(se_DescribeCustomRoutingAcceleratorAttributesRequest(input, context));
202
136
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
203
137
  };
204
138
  export const se_DescribeCustomRoutingEndpointGroupCommand = async (input, context) => {
205
- const headers = {
206
- "content-type": "application/x-amz-json-1.1",
207
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingEndpointGroup",
208
- };
139
+ const headers = sharedHeaders("DescribeCustomRoutingEndpointGroup");
209
140
  let body;
210
141
  body = JSON.stringify(se_DescribeCustomRoutingEndpointGroupRequest(input, context));
211
142
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
212
143
  };
213
144
  export const se_DescribeCustomRoutingListenerCommand = async (input, context) => {
214
- const headers = {
215
- "content-type": "application/x-amz-json-1.1",
216
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeCustomRoutingListener",
217
- };
145
+ const headers = sharedHeaders("DescribeCustomRoutingListener");
218
146
  let body;
219
147
  body = JSON.stringify(se_DescribeCustomRoutingListenerRequest(input, context));
220
148
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
221
149
  };
222
150
  export const se_DescribeEndpointGroupCommand = async (input, context) => {
223
- const headers = {
224
- "content-type": "application/x-amz-json-1.1",
225
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeEndpointGroup",
226
- };
151
+ const headers = sharedHeaders("DescribeEndpointGroup");
227
152
  let body;
228
153
  body = JSON.stringify(se_DescribeEndpointGroupRequest(input, context));
229
154
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
230
155
  };
231
156
  export const se_DescribeListenerCommand = async (input, context) => {
232
- const headers = {
233
- "content-type": "application/x-amz-json-1.1",
234
- "x-amz-target": "GlobalAccelerator_V20180706.DescribeListener",
235
- };
157
+ const headers = sharedHeaders("DescribeListener");
236
158
  let body;
237
159
  body = JSON.stringify(se_DescribeListenerRequest(input, context));
238
160
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
239
161
  };
240
162
  export const se_ListAcceleratorsCommand = async (input, context) => {
241
- const headers = {
242
- "content-type": "application/x-amz-json-1.1",
243
- "x-amz-target": "GlobalAccelerator_V20180706.ListAccelerators",
244
- };
163
+ const headers = sharedHeaders("ListAccelerators");
245
164
  let body;
246
165
  body = JSON.stringify(se_ListAcceleratorsRequest(input, context));
247
166
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
248
167
  };
249
168
  export const se_ListByoipCidrsCommand = async (input, context) => {
250
- const headers = {
251
- "content-type": "application/x-amz-json-1.1",
252
- "x-amz-target": "GlobalAccelerator_V20180706.ListByoipCidrs",
253
- };
169
+ const headers = sharedHeaders("ListByoipCidrs");
254
170
  let body;
255
171
  body = JSON.stringify(se_ListByoipCidrsRequest(input, context));
256
172
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
257
173
  };
258
174
  export const se_ListCustomRoutingAcceleratorsCommand = async (input, context) => {
259
- const headers = {
260
- "content-type": "application/x-amz-json-1.1",
261
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingAccelerators",
262
- };
175
+ const headers = sharedHeaders("ListCustomRoutingAccelerators");
263
176
  let body;
264
177
  body = JSON.stringify(se_ListCustomRoutingAcceleratorsRequest(input, context));
265
178
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
266
179
  };
267
180
  export const se_ListCustomRoutingEndpointGroupsCommand = async (input, context) => {
268
- const headers = {
269
- "content-type": "application/x-amz-json-1.1",
270
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingEndpointGroups",
271
- };
181
+ const headers = sharedHeaders("ListCustomRoutingEndpointGroups");
272
182
  let body;
273
183
  body = JSON.stringify(se_ListCustomRoutingEndpointGroupsRequest(input, context));
274
184
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
275
185
  };
276
186
  export const se_ListCustomRoutingListenersCommand = async (input, context) => {
277
- const headers = {
278
- "content-type": "application/x-amz-json-1.1",
279
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingListeners",
280
- };
187
+ const headers = sharedHeaders("ListCustomRoutingListeners");
281
188
  let body;
282
189
  body = JSON.stringify(se_ListCustomRoutingListenersRequest(input, context));
283
190
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
284
191
  };
285
192
  export const se_ListCustomRoutingPortMappingsCommand = async (input, context) => {
286
- const headers = {
287
- "content-type": "application/x-amz-json-1.1",
288
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingPortMappings",
289
- };
193
+ const headers = sharedHeaders("ListCustomRoutingPortMappings");
290
194
  let body;
291
195
  body = JSON.stringify(se_ListCustomRoutingPortMappingsRequest(input, context));
292
196
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
293
197
  };
294
198
  export const se_ListCustomRoutingPortMappingsByDestinationCommand = async (input, context) => {
295
- const headers = {
296
- "content-type": "application/x-amz-json-1.1",
297
- "x-amz-target": "GlobalAccelerator_V20180706.ListCustomRoutingPortMappingsByDestination",
298
- };
199
+ const headers = sharedHeaders("ListCustomRoutingPortMappingsByDestination");
299
200
  let body;
300
201
  body = JSON.stringify(se_ListCustomRoutingPortMappingsByDestinationRequest(input, context));
301
202
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
302
203
  };
303
204
  export const se_ListEndpointGroupsCommand = async (input, context) => {
304
- const headers = {
305
- "content-type": "application/x-amz-json-1.1",
306
- "x-amz-target": "GlobalAccelerator_V20180706.ListEndpointGroups",
307
- };
205
+ const headers = sharedHeaders("ListEndpointGroups");
308
206
  let body;
309
207
  body = JSON.stringify(se_ListEndpointGroupsRequest(input, context));
310
208
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
311
209
  };
312
210
  export const se_ListListenersCommand = async (input, context) => {
313
- const headers = {
314
- "content-type": "application/x-amz-json-1.1",
315
- "x-amz-target": "GlobalAccelerator_V20180706.ListListeners",
316
- };
211
+ const headers = sharedHeaders("ListListeners");
317
212
  let body;
318
213
  body = JSON.stringify(se_ListListenersRequest(input, context));
319
214
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
320
215
  };
321
216
  export const se_ListTagsForResourceCommand = async (input, context) => {
322
- const headers = {
323
- "content-type": "application/x-amz-json-1.1",
324
- "x-amz-target": "GlobalAccelerator_V20180706.ListTagsForResource",
325
- };
217
+ const headers = sharedHeaders("ListTagsForResource");
326
218
  let body;
327
219
  body = JSON.stringify(se_ListTagsForResourceRequest(input, context));
328
220
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
329
221
  };
330
222
  export const se_ProvisionByoipCidrCommand = async (input, context) => {
331
- const headers = {
332
- "content-type": "application/x-amz-json-1.1",
333
- "x-amz-target": "GlobalAccelerator_V20180706.ProvisionByoipCidr",
334
- };
223
+ const headers = sharedHeaders("ProvisionByoipCidr");
335
224
  let body;
336
225
  body = JSON.stringify(se_ProvisionByoipCidrRequest(input, context));
337
226
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
338
227
  };
339
228
  export const se_RemoveCustomRoutingEndpointsCommand = async (input, context) => {
340
- const headers = {
341
- "content-type": "application/x-amz-json-1.1",
342
- "x-amz-target": "GlobalAccelerator_V20180706.RemoveCustomRoutingEndpoints",
343
- };
229
+ const headers = sharedHeaders("RemoveCustomRoutingEndpoints");
344
230
  let body;
345
231
  body = JSON.stringify(se_RemoveCustomRoutingEndpointsRequest(input, context));
346
232
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
347
233
  };
348
234
  export const se_RemoveEndpointsCommand = async (input, context) => {
349
- const headers = {
350
- "content-type": "application/x-amz-json-1.1",
351
- "x-amz-target": "GlobalAccelerator_V20180706.RemoveEndpoints",
352
- };
235
+ const headers = sharedHeaders("RemoveEndpoints");
353
236
  let body;
354
237
  body = JSON.stringify(se_RemoveEndpointsRequest(input, context));
355
238
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
356
239
  };
357
240
  export const se_TagResourceCommand = async (input, context) => {
358
- const headers = {
359
- "content-type": "application/x-amz-json-1.1",
360
- "x-amz-target": "GlobalAccelerator_V20180706.TagResource",
361
- };
241
+ const headers = sharedHeaders("TagResource");
362
242
  let body;
363
243
  body = JSON.stringify(se_TagResourceRequest(input, context));
364
244
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
365
245
  };
366
246
  export const se_UntagResourceCommand = async (input, context) => {
367
- const headers = {
368
- "content-type": "application/x-amz-json-1.1",
369
- "x-amz-target": "GlobalAccelerator_V20180706.UntagResource",
370
- };
247
+ const headers = sharedHeaders("UntagResource");
371
248
  let body;
372
249
  body = JSON.stringify(se_UntagResourceRequest(input, context));
373
250
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
374
251
  };
375
252
  export const se_UpdateAcceleratorCommand = async (input, context) => {
376
- const headers = {
377
- "content-type": "application/x-amz-json-1.1",
378
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateAccelerator",
379
- };
253
+ const headers = sharedHeaders("UpdateAccelerator");
380
254
  let body;
381
255
  body = JSON.stringify(se_UpdateAcceleratorRequest(input, context));
382
256
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
383
257
  };
384
258
  export const se_UpdateAcceleratorAttributesCommand = async (input, context) => {
385
- const headers = {
386
- "content-type": "application/x-amz-json-1.1",
387
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateAcceleratorAttributes",
388
- };
259
+ const headers = sharedHeaders("UpdateAcceleratorAttributes");
389
260
  let body;
390
261
  body = JSON.stringify(se_UpdateAcceleratorAttributesRequest(input, context));
391
262
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
392
263
  };
393
264
  export const se_UpdateCustomRoutingAcceleratorCommand = async (input, context) => {
394
- const headers = {
395
- "content-type": "application/x-amz-json-1.1",
396
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingAccelerator",
397
- };
265
+ const headers = sharedHeaders("UpdateCustomRoutingAccelerator");
398
266
  let body;
399
267
  body = JSON.stringify(se_UpdateCustomRoutingAcceleratorRequest(input, context));
400
268
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
401
269
  };
402
270
  export const se_UpdateCustomRoutingAcceleratorAttributesCommand = async (input, context) => {
403
- const headers = {
404
- "content-type": "application/x-amz-json-1.1",
405
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingAcceleratorAttributes",
406
- };
271
+ const headers = sharedHeaders("UpdateCustomRoutingAcceleratorAttributes");
407
272
  let body;
408
273
  body = JSON.stringify(se_UpdateCustomRoutingAcceleratorAttributesRequest(input, context));
409
274
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
410
275
  };
411
276
  export const se_UpdateCustomRoutingListenerCommand = async (input, context) => {
412
- const headers = {
413
- "content-type": "application/x-amz-json-1.1",
414
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateCustomRoutingListener",
415
- };
277
+ const headers = sharedHeaders("UpdateCustomRoutingListener");
416
278
  let body;
417
279
  body = JSON.stringify(se_UpdateCustomRoutingListenerRequest(input, context));
418
280
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
419
281
  };
420
282
  export const se_UpdateEndpointGroupCommand = async (input, context) => {
421
- const headers = {
422
- "content-type": "application/x-amz-json-1.1",
423
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateEndpointGroup",
424
- };
283
+ const headers = sharedHeaders("UpdateEndpointGroup");
425
284
  let body;
426
285
  body = JSON.stringify(se_UpdateEndpointGroupRequest(input, context));
427
286
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
428
287
  };
429
288
  export const se_UpdateListenerCommand = async (input, context) => {
430
- const headers = {
431
- "content-type": "application/x-amz-json-1.1",
432
- "x-amz-target": "GlobalAccelerator_V20180706.UpdateListener",
433
- };
289
+ const headers = sharedHeaders("UpdateListener");
434
290
  let body;
435
291
  body = JSON.stringify(se_UpdateListenerRequest(input, context));
436
292
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
437
293
  };
438
294
  export const se_WithdrawByoipCidrCommand = async (input, context) => {
439
- const headers = {
440
- "content-type": "application/x-amz-json-1.1",
441
- "x-amz-target": "GlobalAccelerator_V20180706.WithdrawByoipCidr",
442
- };
295
+ const headers = sharedHeaders("WithdrawByoipCidr");
443
296
  let body;
444
297
  body = JSON.stringify(se_WithdrawByoipCidrRequest(input, context));
445
298
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
@@ -3930,6 +3783,12 @@ const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, bod
3930
3783
  }
3931
3784
  return new __HttpRequest(contents);
3932
3785
  };
3786
+ function sharedHeaders(operation) {
3787
+ return {
3788
+ "content-type": "application/x-amz-json-1.1",
3789
+ "x-amz-target": `GlobalAccelerator_V20180706.${operation}`,
3790
+ };
3791
+ }
3933
3792
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
3934
3793
  if (encoded.length) {
3935
3794
  return JSON.parse(encoded);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-global-accelerator",
3
3
  "description": "AWS SDK for JavaScript Global Accelerator Client for Node.js, Browser and React Native",
4
- "version": "3.310.0",
4
+ "version": "3.312.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -21,7 +21,7 @@
21
21
  "dependencies": {
22
22
  "@aws-crypto/sha256-browser": "3.0.0",
23
23
  "@aws-crypto/sha256-js": "3.0.0",
24
- "@aws-sdk/client-sts": "3.310.0",
24
+ "@aws-sdk/client-sts": "3.312.0",
25
25
  "@aws-sdk/config-resolver": "3.310.0",
26
26
  "@aws-sdk/credential-provider-node": "3.310.0",
27
27
  "@aws-sdk/fetch-http-handler": "3.310.0",