@aws-sdk/client-ivs-realtime 3.474.0 → 3.477.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.
@@ -1,36 +1,29 @@
1
- import { HttpRequest as __HttpRequest } from "@smithy/protocol-http";
2
- import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, limitedParseFloat32 as __limitedParseFloat32, map, parseRfc3339DateTimeWithOffset as __parseRfc3339DateTimeWithOffset, resolvedPath as __resolvedPath, serializeFloat as __serializeFloat, take, withBaseException, } from "@smithy/smithy-client";
1
+ import { requestBuilder as rb } from "@smithy/core";
2
+ import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, limitedParseFloat32 as __limitedParseFloat32, map, parseRfc3339DateTimeWithOffset as __parseRfc3339DateTimeWithOffset, serializeFloat as __serializeFloat, take, withBaseException, } from "@smithy/smithy-client";
3
3
  import { v4 as generateIdempotencyToken } from "uuid";
4
4
  import { IVSRealTimeServiceException as __BaseException } from "../models/IVSRealTimeServiceException";
5
5
  import { AccessDeniedException, ConflictException, InternalServerException, PendingVerification, ResourceNotFoundException, ServiceQuotaExceededException, ValidationException, } from "../models/models_0";
6
6
  export const se_CreateEncoderConfigurationCommand = async (input, context) => {
7
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
7
+ const b = rb(input, context);
8
8
  const headers = {
9
9
  "content-type": "application/json",
10
10
  };
11
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateEncoderConfiguration";
11
+ b.bp("/CreateEncoderConfiguration");
12
12
  let body;
13
13
  body = JSON.stringify(take(input, {
14
14
  name: [],
15
15
  tags: (_) => _json(_),
16
16
  video: (_) => se_Video(_, context),
17
17
  }));
18
- return new __HttpRequest({
19
- protocol,
20
- hostname,
21
- port,
22
- method: "POST",
23
- headers,
24
- path: resolvedPath,
25
- body,
26
- });
18
+ b.m("POST").h(headers).b(body);
19
+ return b.build();
27
20
  };
28
21
  export const se_CreateParticipantTokenCommand = async (input, context) => {
29
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
22
+ const b = rb(input, context);
30
23
  const headers = {
31
24
  "content-type": "application/json",
32
25
  };
33
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateParticipantToken";
26
+ b.bp("/CreateParticipantToken");
34
27
  let body;
35
28
  body = JSON.stringify(take(input, {
36
29
  attributes: (_) => _json(_),
@@ -39,271 +32,180 @@ export const se_CreateParticipantTokenCommand = async (input, context) => {
39
32
  stageArn: [],
40
33
  userId: [],
41
34
  }));
42
- return new __HttpRequest({
43
- protocol,
44
- hostname,
45
- port,
46
- method: "POST",
47
- headers,
48
- path: resolvedPath,
49
- body,
50
- });
35
+ b.m("POST").h(headers).b(body);
36
+ return b.build();
51
37
  };
52
38
  export const se_CreateStageCommand = async (input, context) => {
53
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
39
+ const b = rb(input, context);
54
40
  const headers = {
55
41
  "content-type": "application/json",
56
42
  };
57
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateStage";
43
+ b.bp("/CreateStage");
58
44
  let body;
59
45
  body = JSON.stringify(take(input, {
60
46
  name: [],
61
47
  participantTokenConfigurations: (_) => _json(_),
62
48
  tags: (_) => _json(_),
63
49
  }));
64
- return new __HttpRequest({
65
- protocol,
66
- hostname,
67
- port,
68
- method: "POST",
69
- headers,
70
- path: resolvedPath,
71
- body,
72
- });
50
+ b.m("POST").h(headers).b(body);
51
+ return b.build();
73
52
  };
74
53
  export const se_CreateStorageConfigurationCommand = async (input, context) => {
75
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
54
+ const b = rb(input, context);
76
55
  const headers = {
77
56
  "content-type": "application/json",
78
57
  };
79
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CreateStorageConfiguration";
58
+ b.bp("/CreateStorageConfiguration");
80
59
  let body;
81
60
  body = JSON.stringify(take(input, {
82
61
  name: [],
83
62
  s3: (_) => _json(_),
84
63
  tags: (_) => _json(_),
85
64
  }));
86
- return new __HttpRequest({
87
- protocol,
88
- hostname,
89
- port,
90
- method: "POST",
91
- headers,
92
- path: resolvedPath,
93
- body,
94
- });
65
+ b.m("POST").h(headers).b(body);
66
+ return b.build();
95
67
  };
96
68
  export const se_DeleteEncoderConfigurationCommand = async (input, context) => {
97
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
69
+ const b = rb(input, context);
98
70
  const headers = {
99
71
  "content-type": "application/json",
100
72
  };
101
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteEncoderConfiguration";
73
+ b.bp("/DeleteEncoderConfiguration");
102
74
  let body;
103
75
  body = JSON.stringify(take(input, {
104
76
  arn: [],
105
77
  }));
106
- return new __HttpRequest({
107
- protocol,
108
- hostname,
109
- port,
110
- method: "POST",
111
- headers,
112
- path: resolvedPath,
113
- body,
114
- });
78
+ b.m("POST").h(headers).b(body);
79
+ return b.build();
115
80
  };
116
81
  export const se_DeleteStageCommand = async (input, context) => {
117
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
82
+ const b = rb(input, context);
118
83
  const headers = {
119
84
  "content-type": "application/json",
120
85
  };
121
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteStage";
86
+ b.bp("/DeleteStage");
122
87
  let body;
123
88
  body = JSON.stringify(take(input, {
124
89
  arn: [],
125
90
  }));
126
- return new __HttpRequest({
127
- protocol,
128
- hostname,
129
- port,
130
- method: "POST",
131
- headers,
132
- path: resolvedPath,
133
- body,
134
- });
91
+ b.m("POST").h(headers).b(body);
92
+ return b.build();
135
93
  };
136
94
  export const se_DeleteStorageConfigurationCommand = async (input, context) => {
137
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
95
+ const b = rb(input, context);
138
96
  const headers = {
139
97
  "content-type": "application/json",
140
98
  };
141
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteStorageConfiguration";
99
+ b.bp("/DeleteStorageConfiguration");
142
100
  let body;
143
101
  body = JSON.stringify(take(input, {
144
102
  arn: [],
145
103
  }));
146
- return new __HttpRequest({
147
- protocol,
148
- hostname,
149
- port,
150
- method: "POST",
151
- headers,
152
- path: resolvedPath,
153
- body,
154
- });
104
+ b.m("POST").h(headers).b(body);
105
+ return b.build();
155
106
  };
156
107
  export const se_DisconnectParticipantCommand = async (input, context) => {
157
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
108
+ const b = rb(input, context);
158
109
  const headers = {
159
110
  "content-type": "application/json",
160
111
  };
161
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DisconnectParticipant";
112
+ b.bp("/DisconnectParticipant");
162
113
  let body;
163
114
  body = JSON.stringify(take(input, {
164
115
  participantId: [],
165
116
  reason: [],
166
117
  stageArn: [],
167
118
  }));
168
- return new __HttpRequest({
169
- protocol,
170
- hostname,
171
- port,
172
- method: "POST",
173
- headers,
174
- path: resolvedPath,
175
- body,
176
- });
119
+ b.m("POST").h(headers).b(body);
120
+ return b.build();
177
121
  };
178
122
  export const se_GetCompositionCommand = async (input, context) => {
179
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
123
+ const b = rb(input, context);
180
124
  const headers = {
181
125
  "content-type": "application/json",
182
126
  };
183
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetComposition";
127
+ b.bp("/GetComposition");
184
128
  let body;
185
129
  body = JSON.stringify(take(input, {
186
130
  arn: [],
187
131
  }));
188
- return new __HttpRequest({
189
- protocol,
190
- hostname,
191
- port,
192
- method: "POST",
193
- headers,
194
- path: resolvedPath,
195
- body,
196
- });
132
+ b.m("POST").h(headers).b(body);
133
+ return b.build();
197
134
  };
198
135
  export const se_GetEncoderConfigurationCommand = async (input, context) => {
199
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
136
+ const b = rb(input, context);
200
137
  const headers = {
201
138
  "content-type": "application/json",
202
139
  };
203
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetEncoderConfiguration";
140
+ b.bp("/GetEncoderConfiguration");
204
141
  let body;
205
142
  body = JSON.stringify(take(input, {
206
143
  arn: [],
207
144
  }));
208
- return new __HttpRequest({
209
- protocol,
210
- hostname,
211
- port,
212
- method: "POST",
213
- headers,
214
- path: resolvedPath,
215
- body,
216
- });
145
+ b.m("POST").h(headers).b(body);
146
+ return b.build();
217
147
  };
218
148
  export const se_GetParticipantCommand = async (input, context) => {
219
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
149
+ const b = rb(input, context);
220
150
  const headers = {
221
151
  "content-type": "application/json",
222
152
  };
223
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetParticipant";
153
+ b.bp("/GetParticipant");
224
154
  let body;
225
155
  body = JSON.stringify(take(input, {
226
156
  participantId: [],
227
157
  sessionId: [],
228
158
  stageArn: [],
229
159
  }));
230
- return new __HttpRequest({
231
- protocol,
232
- hostname,
233
- port,
234
- method: "POST",
235
- headers,
236
- path: resolvedPath,
237
- body,
238
- });
160
+ b.m("POST").h(headers).b(body);
161
+ return b.build();
239
162
  };
240
163
  export const se_GetStageCommand = async (input, context) => {
241
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
164
+ const b = rb(input, context);
242
165
  const headers = {
243
166
  "content-type": "application/json",
244
167
  };
245
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetStage";
168
+ b.bp("/GetStage");
246
169
  let body;
247
170
  body = JSON.stringify(take(input, {
248
171
  arn: [],
249
172
  }));
250
- return new __HttpRequest({
251
- protocol,
252
- hostname,
253
- port,
254
- method: "POST",
255
- headers,
256
- path: resolvedPath,
257
- body,
258
- });
173
+ b.m("POST").h(headers).b(body);
174
+ return b.build();
259
175
  };
260
176
  export const se_GetStageSessionCommand = async (input, context) => {
261
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
177
+ const b = rb(input, context);
262
178
  const headers = {
263
179
  "content-type": "application/json",
264
180
  };
265
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetStageSession";
181
+ b.bp("/GetStageSession");
266
182
  let body;
267
183
  body = JSON.stringify(take(input, {
268
184
  sessionId: [],
269
185
  stageArn: [],
270
186
  }));
271
- return new __HttpRequest({
272
- protocol,
273
- hostname,
274
- port,
275
- method: "POST",
276
- headers,
277
- path: resolvedPath,
278
- body,
279
- });
187
+ b.m("POST").h(headers).b(body);
188
+ return b.build();
280
189
  };
281
190
  export const se_GetStorageConfigurationCommand = async (input, context) => {
282
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
191
+ const b = rb(input, context);
283
192
  const headers = {
284
193
  "content-type": "application/json",
285
194
  };
286
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetStorageConfiguration";
195
+ b.bp("/GetStorageConfiguration");
287
196
  let body;
288
197
  body = JSON.stringify(take(input, {
289
198
  arn: [],
290
199
  }));
291
- return new __HttpRequest({
292
- protocol,
293
- hostname,
294
- port,
295
- method: "POST",
296
- headers,
297
- path: resolvedPath,
298
- body,
299
- });
200
+ b.m("POST").h(headers).b(body);
201
+ return b.build();
300
202
  };
301
203
  export const se_ListCompositionsCommand = async (input, context) => {
302
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
204
+ const b = rb(input, context);
303
205
  const headers = {
304
206
  "content-type": "application/json",
305
207
  };
306
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListCompositions";
208
+ b.bp("/ListCompositions");
307
209
  let body;
308
210
  body = JSON.stringify(take(input, {
309
211
  filterByEncoderConfigurationArn: [],
@@ -311,43 +213,29 @@ export const se_ListCompositionsCommand = async (input, context) => {
311
213
  maxResults: [],
312
214
  nextToken: [],
313
215
  }));
314
- return new __HttpRequest({
315
- protocol,
316
- hostname,
317
- port,
318
- method: "POST",
319
- headers,
320
- path: resolvedPath,
321
- body,
322
- });
216
+ b.m("POST").h(headers).b(body);
217
+ return b.build();
323
218
  };
324
219
  export const se_ListEncoderConfigurationsCommand = async (input, context) => {
325
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
220
+ const b = rb(input, context);
326
221
  const headers = {
327
222
  "content-type": "application/json",
328
223
  };
329
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListEncoderConfigurations";
224
+ b.bp("/ListEncoderConfigurations");
330
225
  let body;
331
226
  body = JSON.stringify(take(input, {
332
227
  maxResults: [],
333
228
  nextToken: [],
334
229
  }));
335
- return new __HttpRequest({
336
- protocol,
337
- hostname,
338
- port,
339
- method: "POST",
340
- headers,
341
- path: resolvedPath,
342
- body,
343
- });
230
+ b.m("POST").h(headers).b(body);
231
+ return b.build();
344
232
  };
345
233
  export const se_ListParticipantEventsCommand = async (input, context) => {
346
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
234
+ const b = rb(input, context);
347
235
  const headers = {
348
236
  "content-type": "application/json",
349
237
  };
350
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListParticipantEvents";
238
+ b.bp("/ListParticipantEvents");
351
239
  let body;
352
240
  body = JSON.stringify(take(input, {
353
241
  maxResults: [],
@@ -356,22 +244,15 @@ export const se_ListParticipantEventsCommand = async (input, context) => {
356
244
  sessionId: [],
357
245
  stageArn: [],
358
246
  }));
359
- return new __HttpRequest({
360
- protocol,
361
- hostname,
362
- port,
363
- method: "POST",
364
- headers,
365
- path: resolvedPath,
366
- body,
367
- });
247
+ b.m("POST").h(headers).b(body);
248
+ return b.build();
368
249
  };
369
250
  export const se_ListParticipantsCommand = async (input, context) => {
370
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
251
+ const b = rb(input, context);
371
252
  const headers = {
372
253
  "content-type": "application/json",
373
254
  };
374
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListParticipants";
255
+ b.bp("/ListParticipants");
375
256
  let body;
376
257
  body = JSON.stringify(take(input, {
377
258
  filterByPublished: [],
@@ -382,102 +263,67 @@ export const se_ListParticipantsCommand = async (input, context) => {
382
263
  sessionId: [],
383
264
  stageArn: [],
384
265
  }));
385
- return new __HttpRequest({
386
- protocol,
387
- hostname,
388
- port,
389
- method: "POST",
390
- headers,
391
- path: resolvedPath,
392
- body,
393
- });
266
+ b.m("POST").h(headers).b(body);
267
+ return b.build();
394
268
  };
395
269
  export const se_ListStagesCommand = async (input, context) => {
396
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
270
+ const b = rb(input, context);
397
271
  const headers = {
398
272
  "content-type": "application/json",
399
273
  };
400
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListStages";
274
+ b.bp("/ListStages");
401
275
  let body;
402
276
  body = JSON.stringify(take(input, {
403
277
  maxResults: [],
404
278
  nextToken: [],
405
279
  }));
406
- return new __HttpRequest({
407
- protocol,
408
- hostname,
409
- port,
410
- method: "POST",
411
- headers,
412
- path: resolvedPath,
413
- body,
414
- });
280
+ b.m("POST").h(headers).b(body);
281
+ return b.build();
415
282
  };
416
283
  export const se_ListStageSessionsCommand = async (input, context) => {
417
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
284
+ const b = rb(input, context);
418
285
  const headers = {
419
286
  "content-type": "application/json",
420
287
  };
421
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListStageSessions";
288
+ b.bp("/ListStageSessions");
422
289
  let body;
423
290
  body = JSON.stringify(take(input, {
424
291
  maxResults: [],
425
292
  nextToken: [],
426
293
  stageArn: [],
427
294
  }));
428
- return new __HttpRequest({
429
- protocol,
430
- hostname,
431
- port,
432
- method: "POST",
433
- headers,
434
- path: resolvedPath,
435
- body,
436
- });
295
+ b.m("POST").h(headers).b(body);
296
+ return b.build();
437
297
  };
438
298
  export const se_ListStorageConfigurationsCommand = async (input, context) => {
439
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
299
+ const b = rb(input, context);
440
300
  const headers = {
441
301
  "content-type": "application/json",
442
302
  };
443
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListStorageConfigurations";
303
+ b.bp("/ListStorageConfigurations");
444
304
  let body;
445
305
  body = JSON.stringify(take(input, {
446
306
  maxResults: [],
447
307
  nextToken: [],
448
308
  }));
449
- return new __HttpRequest({
450
- protocol,
451
- hostname,
452
- port,
453
- method: "POST",
454
- headers,
455
- path: resolvedPath,
456
- body,
457
- });
309
+ b.m("POST").h(headers).b(body);
310
+ return b.build();
458
311
  };
459
312
  export const se_ListTagsForResourceCommand = async (input, context) => {
460
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
313
+ const b = rb(input, context);
461
314
  const headers = {};
462
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
463
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
315
+ b.bp("/tags/{resourceArn}");
316
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
464
317
  let body;
465
- return new __HttpRequest({
466
- protocol,
467
- hostname,
468
- port,
469
- method: "GET",
470
- headers,
471
- path: resolvedPath,
472
- body,
473
- });
318
+ b.m("GET").h(headers).b(body);
319
+ return b.build();
474
320
  };
475
321
  export const se_StartCompositionCommand = async (input, context) => {
476
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
322
+ const b = rb(input, context);
477
323
  const headers = {
478
324
  "content-type": "application/json",
479
325
  };
480
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/StartComposition";
326
+ b.bp("/StartComposition");
481
327
  let body;
482
328
  body = JSON.stringify(take(input, {
483
329
  destinations: (_) => _json(_),
@@ -486,100 +332,64 @@ export const se_StartCompositionCommand = async (input, context) => {
486
332
  stageArn: [],
487
333
  tags: (_) => _json(_),
488
334
  }));
489
- return new __HttpRequest({
490
- protocol,
491
- hostname,
492
- port,
493
- method: "POST",
494
- headers,
495
- path: resolvedPath,
496
- body,
497
- });
335
+ b.m("POST").h(headers).b(body);
336
+ return b.build();
498
337
  };
499
338
  export const se_StopCompositionCommand = async (input, context) => {
500
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
339
+ const b = rb(input, context);
501
340
  const headers = {
502
341
  "content-type": "application/json",
503
342
  };
504
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/StopComposition";
343
+ b.bp("/StopComposition");
505
344
  let body;
506
345
  body = JSON.stringify(take(input, {
507
346
  arn: [],
508
347
  }));
509
- return new __HttpRequest({
510
- protocol,
511
- hostname,
512
- port,
513
- method: "POST",
514
- headers,
515
- path: resolvedPath,
516
- body,
517
- });
348
+ b.m("POST").h(headers).b(body);
349
+ return b.build();
518
350
  };
519
351
  export const se_TagResourceCommand = async (input, context) => {
520
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
352
+ const b = rb(input, context);
521
353
  const headers = {
522
354
  "content-type": "application/json",
523
355
  };
524
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
525
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
356
+ b.bp("/tags/{resourceArn}");
357
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
526
358
  let body;
527
359
  body = JSON.stringify(take(input, {
528
360
  tags: (_) => _json(_),
529
361
  }));
530
- return new __HttpRequest({
531
- protocol,
532
- hostname,
533
- port,
534
- method: "POST",
535
- headers,
536
- path: resolvedPath,
537
- body,
538
- });
362
+ b.m("POST").h(headers).b(body);
363
+ return b.build();
539
364
  };
540
365
  export const se_UntagResourceCommand = async (input, context) => {
541
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
366
+ const b = rb(input, context);
542
367
  const headers = {};
543
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
544
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
368
+ b.bp("/tags/{resourceArn}");
369
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
545
370
  const query = map({
546
- tagKeys: [
371
+ [_tK]: [
547
372
  __expectNonNull(input.tagKeys, `tagKeys`) != null,
548
- () => (input.tagKeys || []).map((_entry) => _entry),
373
+ () => (input[_tK] || []).map((_entry) => _entry),
549
374
  ],
550
375
  });
551
376
  let body;
552
- return new __HttpRequest({
553
- protocol,
554
- hostname,
555
- port,
556
- method: "DELETE",
557
- headers,
558
- path: resolvedPath,
559
- query,
560
- body,
561
- });
377
+ b.m("DELETE").h(headers).q(query).b(body);
378
+ return b.build();
562
379
  };
563
380
  export const se_UpdateStageCommand = async (input, context) => {
564
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
381
+ const b = rb(input, context);
565
382
  const headers = {
566
383
  "content-type": "application/json",
567
384
  };
568
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/UpdateStage";
385
+ b.bp("/UpdateStage");
569
386
  let body;
570
387
  body = JSON.stringify(take(input, {
571
388
  arn: [],
572
389
  name: [],
573
390
  }));
574
- return new __HttpRequest({
575
- protocol,
576
- hostname,
577
- port,
578
- method: "POST",
579
- headers,
580
- path: resolvedPath,
581
- body,
582
- });
391
+ b.m("POST").h(headers).b(body);
392
+ return b.build();
583
393
  };
584
394
  export const de_CreateEncoderConfigurationCommand = async (output, context) => {
585
395
  if (output.statusCode !== 200 && output.statusCode >= 300) {
@@ -2021,6 +1831,7 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
2021
1831
  value !== "" &&
2022
1832
  (!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
2023
1833
  (!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
1834
+ const _tK = "tagKeys";
2024
1835
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
2025
1836
  if (encoded.length) {
2026
1837
  return JSON.parse(encoded);