@aws-sdk/client-m2 3.476.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,33 +1,25 @@
1
1
  import { awsExpectUnion as __expectUnion } from "@aws-sdk/core";
2
- import { HttpRequest as __HttpRequest } from "@smithy/protocol-http";
3
- import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, map, parseEpochTimestamp as __parseEpochTimestamp, resolvedPath as __resolvedPath, strictParseInt32 as __strictParseInt32, take, withBaseException, } from "@smithy/smithy-client";
2
+ import { requestBuilder as rb } from "@smithy/core";
3
+ import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, map, parseEpochTimestamp as __parseEpochTimestamp, strictParseInt32 as __strictParseInt32, take, withBaseException, } from "@smithy/smithy-client";
4
4
  import { v4 as generateIdempotencyToken } from "uuid";
5
5
  import { M2ServiceException as __BaseException } from "../models/M2ServiceException";
6
6
  import { AccessDeniedException, ConflictException, ExecutionTimeoutException, InternalServerException, ResourceNotFoundException, ServiceQuotaExceededException, ServiceUnavailableException, StorageConfiguration, ThrottlingException, ValidationException, } from "../models/models_0";
7
7
  export const se_CancelBatchJobExecutionCommand = async (input, context) => {
8
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
8
+ const b = rb(input, context);
9
9
  const headers = {};
10
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
11
- "/applications/{applicationId}/batch-job-executions/{executionId}/cancel";
12
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
13
- resolvedPath = __resolvedPath(resolvedPath, input, "executionId", () => input.executionId, "{executionId}", false);
10
+ b.bp("/applications/{applicationId}/batch-job-executions/{executionId}/cancel");
11
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
12
+ b.p("executionId", () => input.executionId, "{executionId}", false);
14
13
  let body;
15
- return new __HttpRequest({
16
- protocol,
17
- hostname,
18
- port,
19
- method: "POST",
20
- headers,
21
- path: resolvedPath,
22
- body,
23
- });
14
+ b.m("POST").h(headers).b(body);
15
+ return b.build();
24
16
  };
25
17
  export const se_CreateApplicationCommand = async (input, context) => {
26
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
18
+ const b = rb(input, context);
27
19
  const headers = {
28
20
  "content-type": "application/json",
29
21
  };
30
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications";
22
+ b.bp("/applications");
31
23
  let body;
32
24
  body = JSON.stringify(take(input, {
33
25
  clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
@@ -39,68 +31,46 @@ export const se_CreateApplicationCommand = async (input, context) => {
39
31
  roleArn: [],
40
32
  tags: (_) => _json(_),
41
33
  }));
42
- return new __HttpRequest({
43
- protocol,
44
- hostname,
45
- port,
46
- method: "POST",
47
- headers,
48
- path: resolvedPath,
49
- body,
50
- });
34
+ b.m("POST").h(headers).b(body);
35
+ return b.build();
51
36
  };
52
37
  export const se_CreateDataSetImportTaskCommand = async (input, context) => {
53
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
38
+ const b = rb(input, context);
54
39
  const headers = {
55
40
  "content-type": "application/json",
56
41
  };
57
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
58
- "/applications/{applicationId}/dataset-import-task";
59
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
42
+ b.bp("/applications/{applicationId}/dataset-import-task");
43
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
60
44
  let body;
61
45
  body = JSON.stringify(take(input, {
62
46
  clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
63
47
  importConfig: (_) => _json(_),
64
48
  }));
65
- return new __HttpRequest({
66
- protocol,
67
- hostname,
68
- port,
69
- method: "POST",
70
- headers,
71
- path: resolvedPath,
72
- body,
73
- });
49
+ b.m("POST").h(headers).b(body);
50
+ return b.build();
74
51
  };
75
52
  export const se_CreateDeploymentCommand = async (input, context) => {
76
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
53
+ const b = rb(input, context);
77
54
  const headers = {
78
55
  "content-type": "application/json",
79
56
  };
80
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/deployments";
81
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
57
+ b.bp("/applications/{applicationId}/deployments");
58
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
82
59
  let body;
83
60
  body = JSON.stringify(take(input, {
84
61
  applicationVersion: [],
85
62
  clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
86
63
  environmentId: [],
87
64
  }));
88
- return new __HttpRequest({
89
- protocol,
90
- hostname,
91
- port,
92
- method: "POST",
93
- headers,
94
- path: resolvedPath,
95
- body,
96
- });
65
+ b.m("POST").h(headers).b(body);
66
+ return b.build();
97
67
  };
98
68
  export const se_CreateEnvironmentCommand = async (input, context) => {
99
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
69
+ const b = rb(input, context);
100
70
  const headers = {
101
71
  "content-type": "application/json",
102
72
  };
103
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/environments";
73
+ b.bp("/environments");
104
74
  let body;
105
75
  body = JSON.stringify(take(input, {
106
76
  clientToken: [true, (_) => _ ?? generateIdempotencyToken()],
@@ -118,566 +88,342 @@ export const se_CreateEnvironmentCommand = async (input, context) => {
118
88
  subnetIds: (_) => _json(_),
119
89
  tags: (_) => _json(_),
120
90
  }));
121
- return new __HttpRequest({
122
- protocol,
123
- hostname,
124
- port,
125
- method: "POST",
126
- headers,
127
- path: resolvedPath,
128
- body,
129
- });
91
+ b.m("POST").h(headers).b(body);
92
+ return b.build();
130
93
  };
131
94
  export const se_DeleteApplicationCommand = async (input, context) => {
132
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
95
+ const b = rb(input, context);
133
96
  const headers = {};
134
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}";
135
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
97
+ b.bp("/applications/{applicationId}");
98
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
136
99
  let body;
137
- return new __HttpRequest({
138
- protocol,
139
- hostname,
140
- port,
141
- method: "DELETE",
142
- headers,
143
- path: resolvedPath,
144
- body,
145
- });
100
+ b.m("DELETE").h(headers).b(body);
101
+ return b.build();
146
102
  };
147
103
  export const se_DeleteApplicationFromEnvironmentCommand = async (input, context) => {
148
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
104
+ const b = rb(input, context);
149
105
  const headers = {};
150
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
151
- "/applications/{applicationId}/environment/{environmentId}";
152
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
153
- resolvedPath = __resolvedPath(resolvedPath, input, "environmentId", () => input.environmentId, "{environmentId}", false);
106
+ b.bp("/applications/{applicationId}/environment/{environmentId}");
107
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
108
+ b.p("environmentId", () => input.environmentId, "{environmentId}", false);
154
109
  let body;
155
- return new __HttpRequest({
156
- protocol,
157
- hostname,
158
- port,
159
- method: "DELETE",
160
- headers,
161
- path: resolvedPath,
162
- body,
163
- });
110
+ b.m("DELETE").h(headers).b(body);
111
+ return b.build();
164
112
  };
165
113
  export const se_DeleteEnvironmentCommand = async (input, context) => {
166
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
114
+ const b = rb(input, context);
167
115
  const headers = {};
168
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/environments/{environmentId}";
169
- resolvedPath = __resolvedPath(resolvedPath, input, "environmentId", () => input.environmentId, "{environmentId}", false);
116
+ b.bp("/environments/{environmentId}");
117
+ b.p("environmentId", () => input.environmentId, "{environmentId}", false);
170
118
  let body;
171
- return new __HttpRequest({
172
- protocol,
173
- hostname,
174
- port,
175
- method: "DELETE",
176
- headers,
177
- path: resolvedPath,
178
- body,
179
- });
119
+ b.m("DELETE").h(headers).b(body);
120
+ return b.build();
180
121
  };
181
122
  export const se_GetApplicationCommand = async (input, context) => {
182
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
123
+ const b = rb(input, context);
183
124
  const headers = {};
184
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}";
185
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
125
+ b.bp("/applications/{applicationId}");
126
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
186
127
  let body;
187
- return new __HttpRequest({
188
- protocol,
189
- hostname,
190
- port,
191
- method: "GET",
192
- headers,
193
- path: resolvedPath,
194
- body,
195
- });
128
+ b.m("GET").h(headers).b(body);
129
+ return b.build();
196
130
  };
197
131
  export const se_GetApplicationVersionCommand = async (input, context) => {
198
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
132
+ const b = rb(input, context);
199
133
  const headers = {};
200
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
201
- "/applications/{applicationId}/versions/{applicationVersion}";
202
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
203
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationVersion", () => input.applicationVersion.toString(), "{applicationVersion}", false);
134
+ b.bp("/applications/{applicationId}/versions/{applicationVersion}");
135
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
136
+ b.p("applicationVersion", () => input.applicationVersion.toString(), "{applicationVersion}", false);
204
137
  let body;
205
- return new __HttpRequest({
206
- protocol,
207
- hostname,
208
- port,
209
- method: "GET",
210
- headers,
211
- path: resolvedPath,
212
- body,
213
- });
138
+ b.m("GET").h(headers).b(body);
139
+ return b.build();
214
140
  };
215
141
  export const se_GetBatchJobExecutionCommand = async (input, context) => {
216
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
142
+ const b = rb(input, context);
217
143
  const headers = {};
218
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
219
- "/applications/{applicationId}/batch-job-executions/{executionId}";
220
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
221
- resolvedPath = __resolvedPath(resolvedPath, input, "executionId", () => input.executionId, "{executionId}", false);
144
+ b.bp("/applications/{applicationId}/batch-job-executions/{executionId}");
145
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
146
+ b.p("executionId", () => input.executionId, "{executionId}", false);
222
147
  let body;
223
- return new __HttpRequest({
224
- protocol,
225
- hostname,
226
- port,
227
- method: "GET",
228
- headers,
229
- path: resolvedPath,
230
- body,
231
- });
148
+ b.m("GET").h(headers).b(body);
149
+ return b.build();
232
150
  };
233
151
  export const se_GetDataSetDetailsCommand = async (input, context) => {
234
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
152
+ const b = rb(input, context);
235
153
  const headers = {};
236
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
237
- "/applications/{applicationId}/datasets/{dataSetName}";
238
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
239
- resolvedPath = __resolvedPath(resolvedPath, input, "dataSetName", () => input.dataSetName, "{dataSetName}", false);
154
+ b.bp("/applications/{applicationId}/datasets/{dataSetName}");
155
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
156
+ b.p("dataSetName", () => input.dataSetName, "{dataSetName}", false);
240
157
  let body;
241
- return new __HttpRequest({
242
- protocol,
243
- hostname,
244
- port,
245
- method: "GET",
246
- headers,
247
- path: resolvedPath,
248
- body,
249
- });
158
+ b.m("GET").h(headers).b(body);
159
+ return b.build();
250
160
  };
251
161
  export const se_GetDataSetImportTaskCommand = async (input, context) => {
252
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
162
+ const b = rb(input, context);
253
163
  const headers = {};
254
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
255
- "/applications/{applicationId}/dataset-import-tasks/{taskId}";
256
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
257
- resolvedPath = __resolvedPath(resolvedPath, input, "taskId", () => input.taskId, "{taskId}", false);
164
+ b.bp("/applications/{applicationId}/dataset-import-tasks/{taskId}");
165
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
166
+ b.p("taskId", () => input.taskId, "{taskId}", false);
258
167
  let body;
259
- return new __HttpRequest({
260
- protocol,
261
- hostname,
262
- port,
263
- method: "GET",
264
- headers,
265
- path: resolvedPath,
266
- body,
267
- });
168
+ b.m("GET").h(headers).b(body);
169
+ return b.build();
268
170
  };
269
171
  export const se_GetDeploymentCommand = async (input, context) => {
270
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
172
+ const b = rb(input, context);
271
173
  const headers = {};
272
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
273
- "/applications/{applicationId}/deployments/{deploymentId}";
274
- resolvedPath = __resolvedPath(resolvedPath, input, "deploymentId", () => input.deploymentId, "{deploymentId}", false);
275
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
174
+ b.bp("/applications/{applicationId}/deployments/{deploymentId}");
175
+ b.p("deploymentId", () => input.deploymentId, "{deploymentId}", false);
176
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
276
177
  let body;
277
- return new __HttpRequest({
278
- protocol,
279
- hostname,
280
- port,
281
- method: "GET",
282
- headers,
283
- path: resolvedPath,
284
- body,
285
- });
178
+ b.m("GET").h(headers).b(body);
179
+ return b.build();
286
180
  };
287
181
  export const se_GetEnvironmentCommand = async (input, context) => {
288
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
182
+ const b = rb(input, context);
289
183
  const headers = {};
290
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/environments/{environmentId}";
291
- resolvedPath = __resolvedPath(resolvedPath, input, "environmentId", () => input.environmentId, "{environmentId}", false);
184
+ b.bp("/environments/{environmentId}");
185
+ b.p("environmentId", () => input.environmentId, "{environmentId}", false);
292
186
  let body;
293
- return new __HttpRequest({
294
- protocol,
295
- hostname,
296
- port,
297
- method: "GET",
298
- headers,
299
- path: resolvedPath,
300
- body,
301
- });
187
+ b.m("GET").h(headers).b(body);
188
+ return b.build();
302
189
  };
303
190
  export const se_GetSignedBluinsightsUrlCommand = async (input, context) => {
304
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
191
+ const b = rb(input, context);
305
192
  const headers = {
306
193
  "content-type": "application/json",
307
194
  };
308
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/signed-bi-url";
195
+ b.bp("/signed-bi-url");
309
196
  let body;
310
197
  body = "";
311
- return new __HttpRequest({
312
- protocol,
313
- hostname,
314
- port,
315
- method: "GET",
316
- headers,
317
- path: resolvedPath,
318
- body,
319
- });
198
+ b.m("GET").h(headers).b(body);
199
+ return b.build();
320
200
  };
321
201
  export const se_ListApplicationsCommand = async (input, context) => {
322
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
202
+ const b = rb(input, context);
323
203
  const headers = {};
324
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications";
204
+ b.bp("/applications");
325
205
  const query = map({
326
- nextToken: [, input.nextToken],
327
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
328
- names: [() => input.names !== void 0, () => (input.names || []).map((_entry) => _entry)],
329
- environmentId: [, input.environmentId],
206
+ [_nT]: [, input[_nT]],
207
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
208
+ [_n]: [() => input.names !== void 0, () => (input[_n] || []).map((_entry) => _entry)],
209
+ [_eI]: [, input[_eI]],
330
210
  });
331
211
  let body;
332
- return new __HttpRequest({
333
- protocol,
334
- hostname,
335
- port,
336
- method: "GET",
337
- headers,
338
- path: resolvedPath,
339
- query,
340
- body,
341
- });
212
+ b.m("GET").h(headers).q(query).b(body);
213
+ return b.build();
342
214
  };
343
215
  export const se_ListApplicationVersionsCommand = async (input, context) => {
344
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
216
+ const b = rb(input, context);
345
217
  const headers = {};
346
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/versions";
347
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
218
+ b.bp("/applications/{applicationId}/versions");
219
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
348
220
  const query = map({
349
- nextToken: [, input.nextToken],
350
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
221
+ [_nT]: [, input[_nT]],
222
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
351
223
  });
352
224
  let body;
353
- return new __HttpRequest({
354
- protocol,
355
- hostname,
356
- port,
357
- method: "GET",
358
- headers,
359
- path: resolvedPath,
360
- query,
361
- body,
362
- });
225
+ b.m("GET").h(headers).q(query).b(body);
226
+ return b.build();
363
227
  };
364
228
  export const se_ListBatchJobDefinitionsCommand = async (input, context) => {
365
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
229
+ const b = rb(input, context);
366
230
  const headers = {};
367
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
368
- "/applications/{applicationId}/batch-job-definitions";
369
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
231
+ b.bp("/applications/{applicationId}/batch-job-definitions");
232
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
370
233
  const query = map({
371
- nextToken: [, input.nextToken],
372
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
373
- prefix: [, input.prefix],
234
+ [_nT]: [, input[_nT]],
235
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
236
+ [_p]: [, input[_p]],
374
237
  });
375
238
  let body;
376
- return new __HttpRequest({
377
- protocol,
378
- hostname,
379
- port,
380
- method: "GET",
381
- headers,
382
- path: resolvedPath,
383
- query,
384
- body,
385
- });
239
+ b.m("GET").h(headers).q(query).b(body);
240
+ return b.build();
386
241
  };
387
242
  export const se_ListBatchJobExecutionsCommand = async (input, context) => {
388
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
243
+ const b = rb(input, context);
389
244
  const headers = {};
390
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
391
- "/applications/{applicationId}/batch-job-executions";
392
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
245
+ b.bp("/applications/{applicationId}/batch-job-executions");
246
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
393
247
  const query = map({
394
- nextToken: [, input.nextToken],
395
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
396
- executionIds: [
397
- () => input.executionIds !== void 0,
398
- () => (input.executionIds || []).map((_entry) => _entry),
399
- ],
400
- jobName: [, input.jobName],
401
- status: [, input.status],
402
- startedAfter: [
403
- () => input.startedAfter !== void 0,
404
- () => (input.startedAfter.toISOString().split(".")[0] + "Z").toString(),
405
- ],
406
- startedBefore: [
407
- () => input.startedBefore !== void 0,
408
- () => (input.startedBefore.toISOString().split(".")[0] + "Z").toString(),
409
- ],
248
+ [_nT]: [, input[_nT]],
249
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
250
+ [_eIx]: [() => input.executionIds !== void 0, () => (input[_eIx] || []).map((_entry) => _entry)],
251
+ [_jN]: [, input[_jN]],
252
+ [_s]: [, input[_s]],
253
+ [_sA]: [() => input.startedAfter !== void 0, () => (input[_sA].toISOString().split(".")[0] + "Z").toString()],
254
+ [_sB]: [() => input.startedBefore !== void 0, () => (input[_sB].toISOString().split(".")[0] + "Z").toString()],
410
255
  });
411
256
  let body;
412
- return new __HttpRequest({
413
- protocol,
414
- hostname,
415
- port,
416
- method: "GET",
417
- headers,
418
- path: resolvedPath,
419
- query,
420
- body,
421
- });
257
+ b.m("GET").h(headers).q(query).b(body);
258
+ return b.build();
422
259
  };
423
260
  export const se_ListDataSetImportHistoryCommand = async (input, context) => {
424
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
261
+ const b = rb(input, context);
425
262
  const headers = {};
426
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
427
- "/applications/{applicationId}/dataset-import-tasks";
428
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
263
+ b.bp("/applications/{applicationId}/dataset-import-tasks");
264
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
429
265
  const query = map({
430
- nextToken: [, input.nextToken],
431
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
266
+ [_nT]: [, input[_nT]],
267
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
432
268
  });
433
269
  let body;
434
- return new __HttpRequest({
435
- protocol,
436
- hostname,
437
- port,
438
- method: "GET",
439
- headers,
440
- path: resolvedPath,
441
- query,
442
- body,
443
- });
270
+ b.m("GET").h(headers).q(query).b(body);
271
+ return b.build();
444
272
  };
445
273
  export const se_ListDataSetsCommand = async (input, context) => {
446
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
274
+ const b = rb(input, context);
447
275
  const headers = {};
448
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/datasets";
449
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
276
+ b.bp("/applications/{applicationId}/datasets");
277
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
450
278
  const query = map({
451
- nextToken: [, input.nextToken],
452
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
453
- prefix: [, input.prefix],
454
- nameFilter: [, input.nameFilter],
279
+ [_nT]: [, input[_nT]],
280
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
281
+ [_p]: [, input[_p]],
282
+ [_nF]: [, input[_nF]],
455
283
  });
456
284
  let body;
457
- return new __HttpRequest({
458
- protocol,
459
- hostname,
460
- port,
461
- method: "GET",
462
- headers,
463
- path: resolvedPath,
464
- query,
465
- body,
466
- });
285
+ b.m("GET").h(headers).q(query).b(body);
286
+ return b.build();
467
287
  };
468
288
  export const se_ListDeploymentsCommand = async (input, context) => {
469
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
289
+ const b = rb(input, context);
470
290
  const headers = {};
471
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/deployments";
472
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
291
+ b.bp("/applications/{applicationId}/deployments");
292
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
473
293
  const query = map({
474
- nextToken: [, input.nextToken],
475
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
294
+ [_nT]: [, input[_nT]],
295
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
476
296
  });
477
297
  let body;
478
- return new __HttpRequest({
479
- protocol,
480
- hostname,
481
- port,
482
- method: "GET",
483
- headers,
484
- path: resolvedPath,
485
- query,
486
- body,
487
- });
298
+ b.m("GET").h(headers).q(query).b(body);
299
+ return b.build();
488
300
  };
489
301
  export const se_ListEngineVersionsCommand = async (input, context) => {
490
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
302
+ const b = rb(input, context);
491
303
  const headers = {};
492
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/engine-versions";
304
+ b.bp("/engine-versions");
493
305
  const query = map({
494
- engineType: [, input.engineType],
495
- nextToken: [, input.nextToken],
496
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
306
+ [_eT]: [, input[_eT]],
307
+ [_nT]: [, input[_nT]],
308
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
497
309
  });
498
310
  let body;
499
- return new __HttpRequest({
500
- protocol,
501
- hostname,
502
- port,
503
- method: "GET",
504
- headers,
505
- path: resolvedPath,
506
- query,
507
- body,
508
- });
311
+ b.m("GET").h(headers).q(query).b(body);
312
+ return b.build();
509
313
  };
510
314
  export const se_ListEnvironmentsCommand = async (input, context) => {
511
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
315
+ const b = rb(input, context);
512
316
  const headers = {};
513
- const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/environments";
317
+ b.bp("/environments");
514
318
  const query = map({
515
- nextToken: [, input.nextToken],
516
- maxResults: [() => input.maxResults !== void 0, () => input.maxResults.toString()],
517
- names: [() => input.names !== void 0, () => (input.names || []).map((_entry) => _entry)],
518
- engineType: [, input.engineType],
319
+ [_nT]: [, input[_nT]],
320
+ [_mR]: [() => input.maxResults !== void 0, () => input[_mR].toString()],
321
+ [_n]: [() => input.names !== void 0, () => (input[_n] || []).map((_entry) => _entry)],
322
+ [_eT]: [, input[_eT]],
519
323
  });
520
324
  let body;
521
- return new __HttpRequest({
522
- protocol,
523
- hostname,
524
- port,
525
- method: "GET",
526
- headers,
527
- path: resolvedPath,
528
- query,
529
- body,
530
- });
325
+ b.m("GET").h(headers).q(query).b(body);
326
+ return b.build();
531
327
  };
532
328
  export const se_ListTagsForResourceCommand = async (input, context) => {
533
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
329
+ const b = rb(input, context);
534
330
  const headers = {};
535
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
536
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
331
+ b.bp("/tags/{resourceArn}");
332
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
537
333
  let body;
538
- return new __HttpRequest({
539
- protocol,
540
- hostname,
541
- port,
542
- method: "GET",
543
- headers,
544
- path: resolvedPath,
545
- body,
546
- });
334
+ b.m("GET").h(headers).b(body);
335
+ return b.build();
547
336
  };
548
337
  export const se_StartApplicationCommand = async (input, context) => {
549
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
338
+ const b = rb(input, context);
550
339
  const headers = {};
551
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/start";
552
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
340
+ b.bp("/applications/{applicationId}/start");
341
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
553
342
  let body;
554
- return new __HttpRequest({
555
- protocol,
556
- hostname,
557
- port,
558
- method: "POST",
559
- headers,
560
- path: resolvedPath,
561
- body,
562
- });
343
+ b.m("POST").h(headers).b(body);
344
+ return b.build();
563
345
  };
564
346
  export const se_StartBatchJobCommand = async (input, context) => {
565
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
347
+ const b = rb(input, context);
566
348
  const headers = {
567
349
  "content-type": "application/json",
568
350
  };
569
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/batch-job";
570
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
351
+ b.bp("/applications/{applicationId}/batch-job");
352
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
571
353
  let body;
572
354
  body = JSON.stringify(take(input, {
573
355
  batchJobIdentifier: (_) => _json(_),
574
356
  jobParams: (_) => _json(_),
575
357
  }));
576
- return new __HttpRequest({
577
- protocol,
578
- hostname,
579
- port,
580
- method: "POST",
581
- headers,
582
- path: resolvedPath,
583
- body,
584
- });
358
+ b.m("POST").h(headers).b(body);
359
+ return b.build();
585
360
  };
586
361
  export const se_StopApplicationCommand = async (input, context) => {
587
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
362
+ const b = rb(input, context);
588
363
  const headers = {
589
364
  "content-type": "application/json",
590
365
  };
591
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}/stop";
592
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
366
+ b.bp("/applications/{applicationId}/stop");
367
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
593
368
  let body;
594
369
  body = JSON.stringify(take(input, {
595
370
  forceStop: [],
596
371
  }));
597
- return new __HttpRequest({
598
- protocol,
599
- hostname,
600
- port,
601
- method: "POST",
602
- headers,
603
- path: resolvedPath,
604
- body,
605
- });
372
+ b.m("POST").h(headers).b(body);
373
+ return b.build();
606
374
  };
607
375
  export const se_TagResourceCommand = async (input, context) => {
608
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
376
+ const b = rb(input, context);
609
377
  const headers = {
610
378
  "content-type": "application/json",
611
379
  };
612
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
613
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
380
+ b.bp("/tags/{resourceArn}");
381
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
614
382
  let body;
615
383
  body = JSON.stringify(take(input, {
616
384
  tags: (_) => _json(_),
617
385
  }));
618
- return new __HttpRequest({
619
- protocol,
620
- hostname,
621
- port,
622
- method: "POST",
623
- headers,
624
- path: resolvedPath,
625
- body,
626
- });
386
+ b.m("POST").h(headers).b(body);
387
+ return b.build();
627
388
  };
628
389
  export const se_UntagResourceCommand = async (input, context) => {
629
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
390
+ const b = rb(input, context);
630
391
  const headers = {};
631
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}";
632
- resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn, "{resourceArn}", false);
392
+ b.bp("/tags/{resourceArn}");
393
+ b.p("resourceArn", () => input.resourceArn, "{resourceArn}", false);
633
394
  const query = map({
634
- tagKeys: [
395
+ [_tK]: [
635
396
  __expectNonNull(input.tagKeys, `tagKeys`) != null,
636
- () => (input.tagKeys || []).map((_entry) => _entry),
397
+ () => (input[_tK] || []).map((_entry) => _entry),
637
398
  ],
638
399
  });
639
400
  let body;
640
- return new __HttpRequest({
641
- protocol,
642
- hostname,
643
- port,
644
- method: "DELETE",
645
- headers,
646
- path: resolvedPath,
647
- query,
648
- body,
649
- });
401
+ b.m("DELETE").h(headers).q(query).b(body);
402
+ return b.build();
650
403
  };
651
404
  export const se_UpdateApplicationCommand = async (input, context) => {
652
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
405
+ const b = rb(input, context);
653
406
  const headers = {
654
407
  "content-type": "application/json",
655
408
  };
656
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/applications/{applicationId}";
657
- resolvedPath = __resolvedPath(resolvedPath, input, "applicationId", () => input.applicationId, "{applicationId}", false);
409
+ b.bp("/applications/{applicationId}");
410
+ b.p("applicationId", () => input.applicationId, "{applicationId}", false);
658
411
  let body;
659
412
  body = JSON.stringify(take(input, {
660
413
  currentApplicationVersion: [],
661
414
  definition: (_) => _json(_),
662
415
  description: [],
663
416
  }));
664
- return new __HttpRequest({
665
- protocol,
666
- hostname,
667
- port,
668
- method: "PATCH",
669
- headers,
670
- path: resolvedPath,
671
- body,
672
- });
417
+ b.m("PATCH").h(headers).b(body);
418
+ return b.build();
673
419
  };
674
420
  export const se_UpdateEnvironmentCommand = async (input, context) => {
675
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
421
+ const b = rb(input, context);
676
422
  const headers = {
677
423
  "content-type": "application/json",
678
424
  };
679
- let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/environments/{environmentId}";
680
- resolvedPath = __resolvedPath(resolvedPath, input, "environmentId", () => input.environmentId, "{environmentId}", false);
425
+ b.bp("/environments/{environmentId}");
426
+ b.p("environmentId", () => input.environmentId, "{environmentId}", false);
681
427
  let body;
682
428
  body = JSON.stringify(take(input, {
683
429
  applyDuringMaintenanceWindow: [],
@@ -687,15 +433,8 @@ export const se_UpdateEnvironmentCommand = async (input, context) => {
687
433
  instanceType: [],
688
434
  preferredMaintenanceWindow: [],
689
435
  }));
690
- return new __HttpRequest({
691
- protocol,
692
- hostname,
693
- port,
694
- method: "PATCH",
695
- headers,
696
- path: resolvedPath,
697
- body,
698
- });
436
+ b.m("PATCH").h(headers).b(body);
437
+ return b.build();
699
438
  };
700
439
  export const de_CancelBatchJobExecutionCommand = async (output, context) => {
701
440
  if (output.statusCode !== 200 && output.statusCode >= 300) {
@@ -2326,10 +2065,7 @@ const de_ExecutionTimeoutExceptionRes = async (parsedOutput, context) => {
2326
2065
  };
2327
2066
  const de_InternalServerExceptionRes = async (parsedOutput, context) => {
2328
2067
  const contents = map({
2329
- retryAfterSeconds: [
2330
- () => void 0 !== parsedOutput.headers["retry-after"],
2331
- () => __strictParseInt32(parsedOutput.headers["retry-after"]),
2332
- ],
2068
+ [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
2333
2069
  });
2334
2070
  const data = parsedOutput.body;
2335
2071
  const doc = take(data, {
@@ -2389,10 +2125,7 @@ const de_ServiceUnavailableExceptionRes = async (parsedOutput, context) => {
2389
2125
  };
2390
2126
  const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
2391
2127
  const contents = map({
2392
- retryAfterSeconds: [
2393
- () => void 0 !== parsedOutput.headers["retry-after"],
2394
- () => __strictParseInt32(parsedOutput.headers["retry-after"]),
2395
- ],
2128
+ [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
2396
2129
  });
2397
2130
  const data = parsedOutput.body;
2398
2131
  const doc = take(data, {
@@ -2625,6 +2358,21 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
2625
2358
  value !== "" &&
2626
2359
  (!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
2627
2360
  (!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
2361
+ const _eI = "environmentId";
2362
+ const _eIx = "executionIds";
2363
+ const _eT = "engineType";
2364
+ const _jN = "jobName";
2365
+ const _mR = "maxResults";
2366
+ const _n = "names";
2367
+ const _nF = "nameFilter";
2368
+ const _nT = "nextToken";
2369
+ const _p = "prefix";
2370
+ const _rAS = "retryAfterSeconds";
2371
+ const _ra = "retry-after";
2372
+ const _s = "status";
2373
+ const _sA = "startedAfter";
2374
+ const _sB = "startedBefore";
2375
+ const _tK = "tagKeys";
2628
2376
  const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
2629
2377
  if (encoded.length) {
2630
2378
  return JSON.parse(encoded);