@aws-sdk/client-schemas 3.901.0 → 3.906.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist-cjs/index.js +2098 -2326
  2. package/package.json +5 -5
package/dist-cjs/index.js CHANGED
@@ -1,2378 +1,2150 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
7
- var __export = (target, all) => {
8
- for (var name in all)
9
- __defProp(target, name, { get: all[name], enumerable: true });
10
- };
11
- var __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from === "object" || typeof from === "function") {
13
- for (let key of __getOwnPropNames(from))
14
- if (!__hasOwnProp.call(to, key) && key !== except)
15
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
- }
17
- return to;
18
- };
19
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
-
21
- // src/index.ts
22
- var index_exports = {};
23
- __export(index_exports, {
24
- BadRequestException: () => BadRequestException,
25
- CodeGenerationStatus: () => CodeGenerationStatus,
26
- ConflictException: () => ConflictException,
27
- CreateDiscovererCommand: () => CreateDiscovererCommand,
28
- CreateRegistryCommand: () => CreateRegistryCommand,
29
- CreateSchemaCommand: () => CreateSchemaCommand,
30
- DeleteDiscovererCommand: () => DeleteDiscovererCommand,
31
- DeleteRegistryCommand: () => DeleteRegistryCommand,
32
- DeleteResourcePolicyCommand: () => DeleteResourcePolicyCommand,
33
- DeleteSchemaCommand: () => DeleteSchemaCommand,
34
- DeleteSchemaVersionCommand: () => DeleteSchemaVersionCommand,
35
- DescribeCodeBindingCommand: () => DescribeCodeBindingCommand,
36
- DescribeDiscovererCommand: () => DescribeDiscovererCommand,
37
- DescribeRegistryCommand: () => DescribeRegistryCommand,
38
- DescribeSchemaCommand: () => DescribeSchemaCommand,
39
- DiscovererState: () => DiscovererState,
40
- ExportSchemaCommand: () => ExportSchemaCommand,
41
- ForbiddenException: () => ForbiddenException,
42
- GetCodeBindingSourceCommand: () => GetCodeBindingSourceCommand,
43
- GetDiscoveredSchemaCommand: () => GetDiscoveredSchemaCommand,
44
- GetResourcePolicyCommand: () => GetResourcePolicyCommand,
45
- GoneException: () => GoneException,
46
- InternalServerErrorException: () => InternalServerErrorException,
47
- ListDiscoverersCommand: () => ListDiscoverersCommand,
48
- ListRegistriesCommand: () => ListRegistriesCommand,
49
- ListSchemaVersionsCommand: () => ListSchemaVersionsCommand,
50
- ListSchemasCommand: () => ListSchemasCommand,
51
- ListTagsForResourceCommand: () => ListTagsForResourceCommand,
52
- NotFoundException: () => NotFoundException,
53
- PreconditionFailedException: () => PreconditionFailedException,
54
- PutCodeBindingCommand: () => PutCodeBindingCommand,
55
- PutResourcePolicyCommand: () => PutResourcePolicyCommand,
56
- Schemas: () => Schemas,
57
- SchemasClient: () => SchemasClient,
58
- SchemasServiceException: () => SchemasServiceException,
59
- SearchSchemasCommand: () => SearchSchemasCommand,
60
- ServiceUnavailableException: () => ServiceUnavailableException,
61
- StartDiscovererCommand: () => StartDiscovererCommand,
62
- StopDiscovererCommand: () => StopDiscovererCommand,
63
- TagResourceCommand: () => TagResourceCommand,
64
- TooManyRequestsException: () => TooManyRequestsException,
65
- Type: () => Type,
66
- UnauthorizedException: () => UnauthorizedException,
67
- UntagResourceCommand: () => UntagResourceCommand,
68
- UpdateDiscovererCommand: () => UpdateDiscovererCommand,
69
- UpdateRegistryCommand: () => UpdateRegistryCommand,
70
- UpdateSchemaCommand: () => UpdateSchemaCommand,
71
- __Client: () => import_smithy_client.Client,
72
- paginateListDiscoverers: () => paginateListDiscoverers,
73
- paginateListRegistries: () => paginateListRegistries,
74
- paginateListSchemaVersions: () => paginateListSchemaVersions,
75
- paginateListSchemas: () => paginateListSchemas,
76
- paginateSearchSchemas: () => paginateSearchSchemas,
77
- waitForCodeBindingExists: () => waitForCodeBindingExists,
78
- waitUntilCodeBindingExists: () => waitUntilCodeBindingExists
79
- });
80
- module.exports = __toCommonJS(index_exports);
81
-
82
- // src/SchemasClient.ts
83
- var import_middleware_host_header = require("@aws-sdk/middleware-host-header");
84
- var import_middleware_logger = require("@aws-sdk/middleware-logger");
85
- var import_middleware_recursion_detection = require("@aws-sdk/middleware-recursion-detection");
86
- var import_middleware_user_agent = require("@aws-sdk/middleware-user-agent");
87
- var import_config_resolver = require("@smithy/config-resolver");
88
- var import_core = require("@smithy/core");
89
- var import_middleware_content_length = require("@smithy/middleware-content-length");
90
- var import_middleware_endpoint = require("@smithy/middleware-endpoint");
91
- var import_middleware_retry = require("@smithy/middleware-retry");
92
-
93
- var import_httpAuthSchemeProvider = require("./auth/httpAuthSchemeProvider");
94
-
95
- // src/endpoint/EndpointParameters.ts
96
- var resolveClientEndpointParameters = /* @__PURE__ */ __name((options) => {
97
- return Object.assign(options, {
98
- useDualstackEndpoint: options.useDualstackEndpoint ?? false,
99
- useFipsEndpoint: options.useFipsEndpoint ?? false,
100
- defaultSigningName: "schemas"
101
- });
102
- }, "resolveClientEndpointParameters");
103
- var commonParams = {
104
- UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
105
- Endpoint: { type: "builtInParams", name: "endpoint" },
106
- Region: { type: "builtInParams", name: "region" },
107
- UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }
1
+ 'use strict';
2
+
3
+ var middlewareHostHeader = require('@aws-sdk/middleware-host-header');
4
+ var middlewareLogger = require('@aws-sdk/middleware-logger');
5
+ var middlewareRecursionDetection = require('@aws-sdk/middleware-recursion-detection');
6
+ var middlewareUserAgent = require('@aws-sdk/middleware-user-agent');
7
+ var configResolver = require('@smithy/config-resolver');
8
+ var core = require('@smithy/core');
9
+ var middlewareContentLength = require('@smithy/middleware-content-length');
10
+ var middlewareEndpoint = require('@smithy/middleware-endpoint');
11
+ var middlewareRetry = require('@smithy/middleware-retry');
12
+ var smithyClient = require('@smithy/smithy-client');
13
+ var httpAuthSchemeProvider = require('./auth/httpAuthSchemeProvider');
14
+ var runtimeConfig = require('./runtimeConfig');
15
+ var regionConfigResolver = require('@aws-sdk/region-config-resolver');
16
+ var protocolHttp = require('@smithy/protocol-http');
17
+ var middlewareSerde = require('@smithy/middleware-serde');
18
+ var core$1 = require('@aws-sdk/core');
19
+ var uuid = require('@smithy/uuid');
20
+ var utilWaiter = require('@smithy/util-waiter');
21
+
22
+ const resolveClientEndpointParameters = (options) => {
23
+ return Object.assign(options, {
24
+ useDualstackEndpoint: options.useDualstackEndpoint ?? false,
25
+ useFipsEndpoint: options.useFipsEndpoint ?? false,
26
+ defaultSigningName: "schemas",
27
+ });
28
+ };
29
+ const commonParams = {
30
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
31
+ Endpoint: { type: "builtInParams", name: "endpoint" },
32
+ Region: { type: "builtInParams", name: "region" },
33
+ UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },
108
34
  };
109
35
 
110
- // src/SchemasClient.ts
111
- var import_runtimeConfig = require("././runtimeConfig");
36
+ const getHttpAuthExtensionConfiguration = (runtimeConfig) => {
37
+ const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
38
+ let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
39
+ let _credentials = runtimeConfig.credentials;
40
+ return {
41
+ setHttpAuthScheme(httpAuthScheme) {
42
+ const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);
43
+ if (index === -1) {
44
+ _httpAuthSchemes.push(httpAuthScheme);
45
+ }
46
+ else {
47
+ _httpAuthSchemes.splice(index, 1, httpAuthScheme);
48
+ }
49
+ },
50
+ httpAuthSchemes() {
51
+ return _httpAuthSchemes;
52
+ },
53
+ setHttpAuthSchemeProvider(httpAuthSchemeProvider) {
54
+ _httpAuthSchemeProvider = httpAuthSchemeProvider;
55
+ },
56
+ httpAuthSchemeProvider() {
57
+ return _httpAuthSchemeProvider;
58
+ },
59
+ setCredentials(credentials) {
60
+ _credentials = credentials;
61
+ },
62
+ credentials() {
63
+ return _credentials;
64
+ },
65
+ };
66
+ };
67
+ const resolveHttpAuthRuntimeConfig = (config) => {
68
+ return {
69
+ httpAuthSchemes: config.httpAuthSchemes(),
70
+ httpAuthSchemeProvider: config.httpAuthSchemeProvider(),
71
+ credentials: config.credentials(),
72
+ };
73
+ };
112
74
 
113
- // src/runtimeExtensions.ts
114
- var import_region_config_resolver = require("@aws-sdk/region-config-resolver");
115
- var import_protocol_http = require("@smithy/protocol-http");
116
- var import_smithy_client = require("@smithy/smithy-client");
75
+ const resolveRuntimeExtensions = (runtimeConfig, extensions) => {
76
+ const extensionConfiguration = Object.assign(regionConfigResolver.getAwsRegionExtensionConfiguration(runtimeConfig), smithyClient.getDefaultExtensionConfiguration(runtimeConfig), protocolHttp.getHttpHandlerExtensionConfiguration(runtimeConfig), getHttpAuthExtensionConfiguration(runtimeConfig));
77
+ extensions.forEach((extension) => extension.configure(extensionConfiguration));
78
+ return Object.assign(runtimeConfig, regionConfigResolver.resolveAwsRegionExtensionConfiguration(extensionConfiguration), smithyClient.resolveDefaultRuntimeConfig(extensionConfiguration), protocolHttp.resolveHttpHandlerRuntimeConfig(extensionConfiguration), resolveHttpAuthRuntimeConfig(extensionConfiguration));
79
+ };
117
80
 
118
- // src/auth/httpAuthExtensionConfiguration.ts
119
- var getHttpAuthExtensionConfiguration = /* @__PURE__ */ __name((runtimeConfig) => {
120
- const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
121
- let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
122
- let _credentials = runtimeConfig.credentials;
123
- return {
124
- setHttpAuthScheme(httpAuthScheme) {
125
- const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);
126
- if (index === -1) {
127
- _httpAuthSchemes.push(httpAuthScheme);
128
- } else {
129
- _httpAuthSchemes.splice(index, 1, httpAuthScheme);
130
- }
131
- },
132
- httpAuthSchemes() {
133
- return _httpAuthSchemes;
134
- },
135
- setHttpAuthSchemeProvider(httpAuthSchemeProvider) {
136
- _httpAuthSchemeProvider = httpAuthSchemeProvider;
137
- },
138
- httpAuthSchemeProvider() {
139
- return _httpAuthSchemeProvider;
140
- },
141
- setCredentials(credentials) {
142
- _credentials = credentials;
143
- },
144
- credentials() {
145
- return _credentials;
81
+ class SchemasClient extends smithyClient.Client {
82
+ config;
83
+ constructor(...[configuration]) {
84
+ const _config_0 = runtimeConfig.getRuntimeConfig(configuration || {});
85
+ super(_config_0);
86
+ this.initConfig = _config_0;
87
+ const _config_1 = resolveClientEndpointParameters(_config_0);
88
+ const _config_2 = middlewareUserAgent.resolveUserAgentConfig(_config_1);
89
+ const _config_3 = middlewareRetry.resolveRetryConfig(_config_2);
90
+ const _config_4 = configResolver.resolveRegionConfig(_config_3);
91
+ const _config_5 = middlewareHostHeader.resolveHostHeaderConfig(_config_4);
92
+ const _config_6 = middlewareEndpoint.resolveEndpointConfig(_config_5);
93
+ const _config_7 = httpAuthSchemeProvider.resolveHttpAuthSchemeConfig(_config_6);
94
+ const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
95
+ this.config = _config_8;
96
+ this.middlewareStack.use(middlewareUserAgent.getUserAgentPlugin(this.config));
97
+ this.middlewareStack.use(middlewareRetry.getRetryPlugin(this.config));
98
+ this.middlewareStack.use(middlewareContentLength.getContentLengthPlugin(this.config));
99
+ this.middlewareStack.use(middlewareHostHeader.getHostHeaderPlugin(this.config));
100
+ this.middlewareStack.use(middlewareLogger.getLoggerPlugin(this.config));
101
+ this.middlewareStack.use(middlewareRecursionDetection.getRecursionDetectionPlugin(this.config));
102
+ this.middlewareStack.use(core.getHttpAuthSchemeEndpointRuleSetPlugin(this.config, {
103
+ httpAuthSchemeParametersProvider: httpAuthSchemeProvider.defaultSchemasHttpAuthSchemeParametersProvider,
104
+ identityProviderConfigProvider: async (config) => new core.DefaultIdentityProviderConfig({
105
+ "aws.auth#sigv4": config.credentials,
106
+ }),
107
+ }));
108
+ this.middlewareStack.use(core.getHttpSigningPlugin(this.config));
109
+ }
110
+ destroy() {
111
+ super.destroy();
146
112
  }
147
- };
148
- }, "getHttpAuthExtensionConfiguration");
149
- var resolveHttpAuthRuntimeConfig = /* @__PURE__ */ __name((config) => {
150
- return {
151
- httpAuthSchemes: config.httpAuthSchemes(),
152
- httpAuthSchemeProvider: config.httpAuthSchemeProvider(),
153
- credentials: config.credentials()
154
- };
155
- }, "resolveHttpAuthRuntimeConfig");
113
+ }
156
114
 
157
- // src/runtimeExtensions.ts
158
- var resolveRuntimeExtensions = /* @__PURE__ */ __name((runtimeConfig, extensions) => {
159
- const extensionConfiguration = Object.assign(
160
- (0, import_region_config_resolver.getAwsRegionExtensionConfiguration)(runtimeConfig),
161
- (0, import_smithy_client.getDefaultExtensionConfiguration)(runtimeConfig),
162
- (0, import_protocol_http.getHttpHandlerExtensionConfiguration)(runtimeConfig),
163
- getHttpAuthExtensionConfiguration(runtimeConfig)
164
- );
165
- extensions.forEach((extension) => extension.configure(extensionConfiguration));
166
- return Object.assign(
167
- runtimeConfig,
168
- (0, import_region_config_resolver.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),
169
- (0, import_smithy_client.resolveDefaultRuntimeConfig)(extensionConfiguration),
170
- (0, import_protocol_http.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),
171
- resolveHttpAuthRuntimeConfig(extensionConfiguration)
172
- );
173
- }, "resolveRuntimeExtensions");
115
+ class SchemasServiceException extends smithyClient.ServiceException {
116
+ constructor(options) {
117
+ super(options);
118
+ Object.setPrototypeOf(this, SchemasServiceException.prototype);
119
+ }
120
+ }
174
121
 
175
- // src/SchemasClient.ts
176
- var SchemasClient = class extends import_smithy_client.Client {
177
- static {
178
- __name(this, "SchemasClient");
179
- }
180
- /**
181
- * The resolved configuration of SchemasClient class. This is resolved and normalized from the {@link SchemasClientConfig | constructor configuration interface}.
182
- */
183
- config;
184
- constructor(...[configuration]) {
185
- const _config_0 = (0, import_runtimeConfig.getRuntimeConfig)(configuration || {});
186
- super(_config_0);
187
- this.initConfig = _config_0;
188
- const _config_1 = resolveClientEndpointParameters(_config_0);
189
- const _config_2 = (0, import_middleware_user_agent.resolveUserAgentConfig)(_config_1);
190
- const _config_3 = (0, import_middleware_retry.resolveRetryConfig)(_config_2);
191
- const _config_4 = (0, import_config_resolver.resolveRegionConfig)(_config_3);
192
- const _config_5 = (0, import_middleware_host_header.resolveHostHeaderConfig)(_config_4);
193
- const _config_6 = (0, import_middleware_endpoint.resolveEndpointConfig)(_config_5);
194
- const _config_7 = (0, import_httpAuthSchemeProvider.resolveHttpAuthSchemeConfig)(_config_6);
195
- const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
196
- this.config = _config_8;
197
- this.middlewareStack.use((0, import_middleware_user_agent.getUserAgentPlugin)(this.config));
198
- this.middlewareStack.use((0, import_middleware_retry.getRetryPlugin)(this.config));
199
- this.middlewareStack.use((0, import_middleware_content_length.getContentLengthPlugin)(this.config));
200
- this.middlewareStack.use((0, import_middleware_host_header.getHostHeaderPlugin)(this.config));
201
- this.middlewareStack.use((0, import_middleware_logger.getLoggerPlugin)(this.config));
202
- this.middlewareStack.use((0, import_middleware_recursion_detection.getRecursionDetectionPlugin)(this.config));
203
- this.middlewareStack.use(
204
- (0, import_core.getHttpAuthSchemeEndpointRuleSetPlugin)(this.config, {
205
- httpAuthSchemeParametersProvider: import_httpAuthSchemeProvider.defaultSchemasHttpAuthSchemeParametersProvider,
206
- identityProviderConfigProvider: /* @__PURE__ */ __name(async (config) => new import_core.DefaultIdentityProviderConfig({
207
- "aws.auth#sigv4": config.credentials
208
- }), "identityProviderConfigProvider")
209
- })
210
- );
211
- this.middlewareStack.use((0, import_core.getHttpSigningPlugin)(this.config));
212
- }
213
- /**
214
- * Destroy underlying resources, like sockets. It's usually not necessary to do this.
215
- * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
216
- * Otherwise, sockets might stay open for quite a long time before the server terminates them.
217
- */
218
- destroy() {
219
- super.destroy();
220
- }
122
+ const DiscovererState = {
123
+ STARTED: "STARTED",
124
+ STOPPED: "STOPPED",
221
125
  };
222
-
223
- // src/Schemas.ts
224
-
225
-
226
- // src/commands/CreateDiscovererCommand.ts
227
-
228
- var import_middleware_serde = require("@smithy/middleware-serde");
229
-
230
-
231
- // src/protocols/Aws_restJson1.ts
232
- var import_core2 = require("@aws-sdk/core");
233
-
234
-
235
- var import_uuid = require("@smithy/uuid");
236
-
237
- // src/models/SchemasServiceException.ts
238
-
239
- var SchemasServiceException = class _SchemasServiceException extends import_smithy_client.ServiceException {
240
- static {
241
- __name(this, "SchemasServiceException");
242
- }
243
- /**
244
- * @internal
245
- */
246
- constructor(options) {
247
- super(options);
248
- Object.setPrototypeOf(this, _SchemasServiceException.prototype);
249
- }
126
+ const Type = {
127
+ JSONSchemaDraft4: "JSONSchemaDraft4",
128
+ OpenApi3: "OpenApi3",
250
129
  };
251
-
252
- // src/models/models_0.ts
253
- var DiscovererState = {
254
- STARTED: "STARTED",
255
- STOPPED: "STOPPED"
256
- };
257
- var Type = {
258
- JSONSchemaDraft4: "JSONSchemaDraft4",
259
- OpenApi3: "OpenApi3"
260
- };
261
- var BadRequestException = class _BadRequestException extends SchemasServiceException {
262
- static {
263
- __name(this, "BadRequestException");
264
- }
265
- name = "BadRequestException";
266
- $fault = "client";
267
- /**
268
- * <p>The error code.</p>
269
- * @public
270
- */
271
- Code;
272
- /**
273
- * <p>The message string of the error output.</p>
274
- * @public
275
- */
276
- Message;
277
- /**
278
- * @internal
279
- */
280
- constructor(opts) {
281
- super({
282
- name: "BadRequestException",
283
- $fault: "client",
284
- ...opts
285
- });
286
- Object.setPrototypeOf(this, _BadRequestException.prototype);
287
- this.Code = opts.Code;
288
- this.Message = opts.Message;
289
- }
290
- };
291
- var CodeGenerationStatus = {
292
- CREATE_COMPLETE: "CREATE_COMPLETE",
293
- CREATE_FAILED: "CREATE_FAILED",
294
- CREATE_IN_PROGRESS: "CREATE_IN_PROGRESS"
295
- };
296
- var ConflictException = class _ConflictException extends SchemasServiceException {
297
- static {
298
- __name(this, "ConflictException");
299
- }
300
- name = "ConflictException";
301
- $fault = "client";
302
- /**
303
- * <p>The error code.</p>
304
- * @public
305
- */
306
- Code;
307
- /**
308
- * <p>The message string of the error output.</p>
309
- * @public
310
- */
311
- Message;
312
- /**
313
- * @internal
314
- */
315
- constructor(opts) {
316
- super({
317
- name: "ConflictException",
318
- $fault: "client",
319
- ...opts
320
- });
321
- Object.setPrototypeOf(this, _ConflictException.prototype);
322
- this.Code = opts.Code;
323
- this.Message = opts.Message;
324
- }
325
- };
326
- var ForbiddenException = class _ForbiddenException extends SchemasServiceException {
327
- static {
328
- __name(this, "ForbiddenException");
329
- }
330
- name = "ForbiddenException";
331
- $fault = "client";
332
- /**
333
- * <p>The error code.</p>
334
- * @public
335
- */
336
- Code;
337
- /**
338
- * <p>The message string of the error output.</p>
339
- * @public
340
- */
341
- Message;
342
- /**
343
- * @internal
344
- */
345
- constructor(opts) {
346
- super({
347
- name: "ForbiddenException",
348
- $fault: "client",
349
- ...opts
350
- });
351
- Object.setPrototypeOf(this, _ForbiddenException.prototype);
352
- this.Code = opts.Code;
353
- this.Message = opts.Message;
354
- }
355
- };
356
- var InternalServerErrorException = class _InternalServerErrorException extends SchemasServiceException {
357
- static {
358
- __name(this, "InternalServerErrorException");
359
- }
360
- name = "InternalServerErrorException";
361
- $fault = "server";
362
- /**
363
- * <p>The error code.</p>
364
- * @public
365
- */
366
- Code;
367
- /**
368
- * <p>The message string of the error output.</p>
369
- * @public
370
- */
371
- Message;
372
- /**
373
- * @internal
374
- */
375
- constructor(opts) {
376
- super({
377
- name: "InternalServerErrorException",
378
- $fault: "server",
379
- ...opts
380
- });
381
- Object.setPrototypeOf(this, _InternalServerErrorException.prototype);
382
- this.Code = opts.Code;
383
- this.Message = opts.Message;
384
- }
385
- };
386
- var ServiceUnavailableException = class _ServiceUnavailableException extends SchemasServiceException {
387
- static {
388
- __name(this, "ServiceUnavailableException");
389
- }
390
- name = "ServiceUnavailableException";
391
- $fault = "server";
392
- /**
393
- * <p>The error code.</p>
394
- * @public
395
- */
396
- Code;
397
- /**
398
- * <p>The message string of the error output.</p>
399
- * @public
400
- */
401
- Message;
402
- /**
403
- * @internal
404
- */
405
- constructor(opts) {
406
- super({
407
- name: "ServiceUnavailableException",
408
- $fault: "server",
409
- ...opts
410
- });
411
- Object.setPrototypeOf(this, _ServiceUnavailableException.prototype);
412
- this.Code = opts.Code;
413
- this.Message = opts.Message;
414
- }
415
- };
416
- var UnauthorizedException = class _UnauthorizedException extends SchemasServiceException {
417
- static {
418
- __name(this, "UnauthorizedException");
419
- }
420
- name = "UnauthorizedException";
421
- $fault = "client";
422
- /**
423
- * <p>The error code.</p>
424
- * @public
425
- */
426
- Code;
427
- /**
428
- * <p>The message string of the error output.</p>
429
- * @public
430
- */
431
- Message;
432
- /**
433
- * @internal
434
- */
435
- constructor(opts) {
436
- super({
437
- name: "UnauthorizedException",
438
- $fault: "client",
439
- ...opts
440
- });
441
- Object.setPrototypeOf(this, _UnauthorizedException.prototype);
442
- this.Code = opts.Code;
443
- this.Message = opts.Message;
444
- }
445
- };
446
- var NotFoundException = class _NotFoundException extends SchemasServiceException {
447
- static {
448
- __name(this, "NotFoundException");
449
- }
450
- name = "NotFoundException";
451
- $fault = "client";
452
- /**
453
- * <p>The error code.</p>
454
- * @public
455
- */
456
- Code;
457
- /**
458
- * <p>The message string of the error output.</p>
459
- * @public
460
- */
461
- Message;
462
- /**
463
- * @internal
464
- */
465
- constructor(opts) {
466
- super({
467
- name: "NotFoundException",
468
- $fault: "client",
469
- ...opts
470
- });
471
- Object.setPrototypeOf(this, _NotFoundException.prototype);
472
- this.Code = opts.Code;
473
- this.Message = opts.Message;
474
- }
475
- };
476
- var TooManyRequestsException = class _TooManyRequestsException extends SchemasServiceException {
477
- static {
478
- __name(this, "TooManyRequestsException");
479
- }
480
- name = "TooManyRequestsException";
481
- $fault = "client";
482
- /**
483
- * <p>The error code.</p>
484
- * @public
485
- */
486
- Code;
487
- /**
488
- * <p>The message string of the error output.</p>
489
- * @public
490
- */
491
- Message;
492
- /**
493
- * @internal
494
- */
495
- constructor(opts) {
496
- super({
497
- name: "TooManyRequestsException",
498
- $fault: "client",
499
- ...opts
500
- });
501
- Object.setPrototypeOf(this, _TooManyRequestsException.prototype);
502
- this.Code = opts.Code;
503
- this.Message = opts.Message;
504
- }
505
- };
506
- var GoneException = class _GoneException extends SchemasServiceException {
507
- static {
508
- __name(this, "GoneException");
509
- }
510
- name = "GoneException";
511
- $fault = "client";
512
- /**
513
- * <p>The error code.</p>
514
- * @public
515
- */
516
- Code;
517
- /**
518
- * <p>The message string of the error output.</p>
519
- * @public
520
- */
521
- Message;
522
- /**
523
- * @internal
524
- */
525
- constructor(opts) {
526
- super({
527
- name: "GoneException",
528
- $fault: "client",
529
- ...opts
530
- });
531
- Object.setPrototypeOf(this, _GoneException.prototype);
532
- this.Code = opts.Code;
533
- this.Message = opts.Message;
534
- }
535
- };
536
- var PreconditionFailedException = class _PreconditionFailedException extends SchemasServiceException {
537
- static {
538
- __name(this, "PreconditionFailedException");
539
- }
540
- name = "PreconditionFailedException";
541
- $fault = "client";
542
- /**
543
- * <p>The error code.</p>
544
- * @public
545
- */
546
- Code;
547
- /**
548
- * <p>The message string of the error output.</p>
549
- * @public
550
- */
551
- Message;
552
- /**
553
- * @internal
554
- */
555
- constructor(opts) {
556
- super({
557
- name: "PreconditionFailedException",
558
- $fault: "client",
559
- ...opts
560
- });
561
- Object.setPrototypeOf(this, _PreconditionFailedException.prototype);
562
- this.Code = opts.Code;
563
- this.Message = opts.Message;
564
- }
130
+ class BadRequestException extends SchemasServiceException {
131
+ name = "BadRequestException";
132
+ $fault = "client";
133
+ Code;
134
+ Message;
135
+ constructor(opts) {
136
+ super({
137
+ name: "BadRequestException",
138
+ $fault: "client",
139
+ ...opts,
140
+ });
141
+ Object.setPrototypeOf(this, BadRequestException.prototype);
142
+ this.Code = opts.Code;
143
+ this.Message = opts.Message;
144
+ }
145
+ }
146
+ const CodeGenerationStatus = {
147
+ CREATE_COMPLETE: "CREATE_COMPLETE",
148
+ CREATE_FAILED: "CREATE_FAILED",
149
+ CREATE_IN_PROGRESS: "CREATE_IN_PROGRESS",
565
150
  };
566
-
567
- // src/protocols/Aws_restJson1.ts
568
- var se_CreateDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
569
- const b = (0, import_core.requestBuilder)(input, context);
570
- const headers = {
571
- "content-type": "application/json"
572
- };
573
- b.bp("/v1/discoverers");
574
- let body;
575
- body = JSON.stringify(
576
- (0, import_smithy_client.take)(input, {
577
- CrossAccount: [],
578
- Description: [],
579
- SourceArn: [],
580
- tags: [, (_) => (0, import_smithy_client._json)(_), `Tags`]
581
- })
582
- );
583
- b.m("POST").h(headers).b(body);
584
- return b.build();
585
- }, "se_CreateDiscovererCommand");
586
- var se_CreateRegistryCommand = /* @__PURE__ */ __name(async (input, context) => {
587
- const b = (0, import_core.requestBuilder)(input, context);
588
- const headers = {
589
- "content-type": "application/json"
590
- };
591
- b.bp("/v1/registries/name/{RegistryName}");
592
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
593
- let body;
594
- body = JSON.stringify(
595
- (0, import_smithy_client.take)(input, {
596
- Description: [],
597
- tags: [, (_) => (0, import_smithy_client._json)(_), `Tags`]
598
- })
599
- );
600
- b.m("POST").h(headers).b(body);
601
- return b.build();
602
- }, "se_CreateRegistryCommand");
603
- var se_CreateSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
604
- const b = (0, import_core.requestBuilder)(input, context);
605
- const headers = {
606
- "content-type": "application/json"
607
- };
608
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
609
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
610
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
611
- let body;
612
- body = JSON.stringify(
613
- (0, import_smithy_client.take)(input, {
614
- Content: [],
615
- Description: [],
616
- tags: [, (_) => (0, import_smithy_client._json)(_), `Tags`],
617
- Type: []
618
- })
619
- );
620
- b.m("POST").h(headers).b(body);
621
- return b.build();
622
- }, "se_CreateSchemaCommand");
623
- var se_DeleteDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
624
- const b = (0, import_core.requestBuilder)(input, context);
625
- const headers = {};
626
- b.bp("/v1/discoverers/id/{DiscovererId}");
627
- b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
628
- let body;
629
- b.m("DELETE").h(headers).b(body);
630
- return b.build();
631
- }, "se_DeleteDiscovererCommand");
632
- var se_DeleteRegistryCommand = /* @__PURE__ */ __name(async (input, context) => {
633
- const b = (0, import_core.requestBuilder)(input, context);
634
- const headers = {};
635
- b.bp("/v1/registries/name/{RegistryName}");
636
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
637
- let body;
638
- b.m("DELETE").h(headers).b(body);
639
- return b.build();
640
- }, "se_DeleteRegistryCommand");
641
- var se_DeleteResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
642
- const b = (0, import_core.requestBuilder)(input, context);
643
- const headers = {};
644
- b.bp("/v1/policy");
645
- const query = (0, import_smithy_client.map)({
646
- [_rN]: [, input[_RN]]
647
- });
648
- let body;
649
- b.m("DELETE").h(headers).q(query).b(body);
650
- return b.build();
651
- }, "se_DeleteResourcePolicyCommand");
652
- var se_DeleteSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
653
- const b = (0, import_core.requestBuilder)(input, context);
654
- const headers = {};
655
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
656
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
657
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
658
- let body;
659
- b.m("DELETE").h(headers).b(body);
660
- return b.build();
661
- }, "se_DeleteSchemaCommand");
662
- var se_DeleteSchemaVersionCommand = /* @__PURE__ */ __name(async (input, context) => {
663
- const b = (0, import_core.requestBuilder)(input, context);
664
- const headers = {};
665
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/version/{SchemaVersion}");
666
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
667
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
668
- b.p("SchemaVersion", () => input.SchemaVersion, "{SchemaVersion}", false);
669
- let body;
670
- b.m("DELETE").h(headers).b(body);
671
- return b.build();
672
- }, "se_DeleteSchemaVersionCommand");
673
- var se_DescribeCodeBindingCommand = /* @__PURE__ */ __name(async (input, context) => {
674
- const b = (0, import_core.requestBuilder)(input, context);
675
- const headers = {};
676
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}");
677
- b.p("Language", () => input.Language, "{Language}", false);
678
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
679
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
680
- const query = (0, import_smithy_client.map)({
681
- [_sV]: [, input[_SV]]
682
- });
683
- let body;
684
- b.m("GET").h(headers).q(query).b(body);
685
- return b.build();
686
- }, "se_DescribeCodeBindingCommand");
687
- var se_DescribeDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
688
- const b = (0, import_core.requestBuilder)(input, context);
689
- const headers = {};
690
- b.bp("/v1/discoverers/id/{DiscovererId}");
691
- b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
692
- let body;
693
- b.m("GET").h(headers).b(body);
694
- return b.build();
695
- }, "se_DescribeDiscovererCommand");
696
- var se_DescribeRegistryCommand = /* @__PURE__ */ __name(async (input, context) => {
697
- const b = (0, import_core.requestBuilder)(input, context);
698
- const headers = {};
699
- b.bp("/v1/registries/name/{RegistryName}");
700
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
701
- let body;
702
- b.m("GET").h(headers).b(body);
703
- return b.build();
704
- }, "se_DescribeRegistryCommand");
705
- var se_DescribeSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
706
- const b = (0, import_core.requestBuilder)(input, context);
707
- const headers = {};
708
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
709
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
710
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
711
- const query = (0, import_smithy_client.map)({
712
- [_sV]: [, input[_SV]]
713
- });
714
- let body;
715
- b.m("GET").h(headers).q(query).b(body);
716
- return b.build();
717
- }, "se_DescribeSchemaCommand");
718
- var se_ExportSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
719
- const b = (0, import_core.requestBuilder)(input, context);
720
- const headers = {};
721
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/export");
722
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
723
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
724
- const query = (0, import_smithy_client.map)({
725
- [_sV]: [, input[_SV]],
726
- [_t]: [, (0, import_smithy_client.expectNonNull)(input[_T], `Type`)]
727
- });
728
- let body;
729
- b.m("GET").h(headers).q(query).b(body);
730
- return b.build();
731
- }, "se_ExportSchemaCommand");
732
- var se_GetCodeBindingSourceCommand = /* @__PURE__ */ __name(async (input, context) => {
733
- const b = (0, import_core.requestBuilder)(input, context);
734
- const headers = {};
735
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}/source");
736
- b.p("Language", () => input.Language, "{Language}", false);
737
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
738
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
739
- const query = (0, import_smithy_client.map)({
740
- [_sV]: [, input[_SV]]
741
- });
742
- let body;
743
- b.m("GET").h(headers).q(query).b(body);
744
- return b.build();
745
- }, "se_GetCodeBindingSourceCommand");
746
- var se_GetDiscoveredSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
747
- const b = (0, import_core.requestBuilder)(input, context);
748
- const headers = {
749
- "content-type": "application/json"
750
- };
751
- b.bp("/v1/discover");
752
- let body;
753
- body = JSON.stringify(
754
- (0, import_smithy_client.take)(input, {
755
- Events: /* @__PURE__ */ __name((_) => (0, import_smithy_client._json)(_), "Events"),
756
- Type: []
757
- })
758
- );
759
- b.m("POST").h(headers).b(body);
760
- return b.build();
761
- }, "se_GetDiscoveredSchemaCommand");
762
- var se_GetResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
763
- const b = (0, import_core.requestBuilder)(input, context);
764
- const headers = {};
765
- b.bp("/v1/policy");
766
- const query = (0, import_smithy_client.map)({
767
- [_rN]: [, input[_RN]]
768
- });
769
- let body;
770
- b.m("GET").h(headers).q(query).b(body);
771
- return b.build();
772
- }, "se_GetResourcePolicyCommand");
773
- var se_ListDiscoverersCommand = /* @__PURE__ */ __name(async (input, context) => {
774
- const b = (0, import_core.requestBuilder)(input, context);
775
- const headers = {};
776
- b.bp("/v1/discoverers");
777
- const query = (0, import_smithy_client.map)({
778
- [_dIP]: [, input[_DIP]],
779
- [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
780
- [_nT]: [, input[_NT]],
781
- [_sAP]: [, input[_SAP]]
782
- });
783
- let body;
784
- b.m("GET").h(headers).q(query).b(body);
785
- return b.build();
786
- }, "se_ListDiscoverersCommand");
787
- var se_ListRegistriesCommand = /* @__PURE__ */ __name(async (input, context) => {
788
- const b = (0, import_core.requestBuilder)(input, context);
789
- const headers = {};
790
- b.bp("/v1/registries");
791
- const query = (0, import_smithy_client.map)({
792
- [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
793
- [_nT]: [, input[_NT]],
794
- [_rNP]: [, input[_RNP]],
795
- [_s]: [, input[_S]]
796
- });
797
- let body;
798
- b.m("GET").h(headers).q(query).b(body);
799
- return b.build();
800
- }, "se_ListRegistriesCommand");
801
- var se_ListSchemasCommand = /* @__PURE__ */ __name(async (input, context) => {
802
- const b = (0, import_core.requestBuilder)(input, context);
803
- const headers = {};
804
- b.bp("/v1/registries/name/{RegistryName}/schemas");
805
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
806
- const query = (0, import_smithy_client.map)({
807
- [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
808
- [_nT]: [, input[_NT]],
809
- [_sNP]: [, input[_SNP]]
810
- });
811
- let body;
812
- b.m("GET").h(headers).q(query).b(body);
813
- return b.build();
814
- }, "se_ListSchemasCommand");
815
- var se_ListSchemaVersionsCommand = /* @__PURE__ */ __name(async (input, context) => {
816
- const b = (0, import_core.requestBuilder)(input, context);
817
- const headers = {};
818
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/versions");
819
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
820
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
821
- const query = (0, import_smithy_client.map)({
822
- [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
823
- [_nT]: [, input[_NT]]
824
- });
825
- let body;
826
- b.m("GET").h(headers).q(query).b(body);
827
- return b.build();
828
- }, "se_ListSchemaVersionsCommand");
829
- var se_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (input, context) => {
830
- const b = (0, import_core.requestBuilder)(input, context);
831
- const headers = {};
832
- b.bp("/tags/{ResourceArn}");
833
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
834
- let body;
835
- b.m("GET").h(headers).b(body);
836
- return b.build();
837
- }, "se_ListTagsForResourceCommand");
838
- var se_PutCodeBindingCommand = /* @__PURE__ */ __name(async (input, context) => {
839
- const b = (0, import_core.requestBuilder)(input, context);
840
- const headers = {};
841
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}");
842
- b.p("Language", () => input.Language, "{Language}", false);
843
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
844
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
845
- const query = (0, import_smithy_client.map)({
846
- [_sV]: [, input[_SV]]
847
- });
848
- let body;
849
- b.m("POST").h(headers).q(query).b(body);
850
- return b.build();
851
- }, "se_PutCodeBindingCommand");
852
- var se_PutResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
853
- const b = (0, import_core.requestBuilder)(input, context);
854
- const headers = {
855
- "content-type": "application/json"
856
- };
857
- b.bp("/v1/policy");
858
- const query = (0, import_smithy_client.map)({
859
- [_rN]: [, input[_RN]]
860
- });
861
- let body;
862
- body = JSON.stringify(
863
- (0, import_smithy_client.take)(input, {
864
- Policy: /* @__PURE__ */ __name((_) => import_smithy_client.LazyJsonString.from(_), "Policy"),
865
- RevisionId: []
866
- })
867
- );
868
- b.m("PUT").h(headers).q(query).b(body);
869
- return b.build();
870
- }, "se_PutResourcePolicyCommand");
871
- var se_SearchSchemasCommand = /* @__PURE__ */ __name(async (input, context) => {
872
- const b = (0, import_core.requestBuilder)(input, context);
873
- const headers = {};
874
- b.bp("/v1/registries/name/{RegistryName}/schemas/search");
875
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
876
- const query = (0, import_smithy_client.map)({
877
- [_k]: [, (0, import_smithy_client.expectNonNull)(input[_K], `Keywords`)],
878
- [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
879
- [_nT]: [, input[_NT]]
880
- });
881
- let body;
882
- b.m("GET").h(headers).q(query).b(body);
883
- return b.build();
884
- }, "se_SearchSchemasCommand");
885
- var se_StartDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
886
- const b = (0, import_core.requestBuilder)(input, context);
887
- const headers = {};
888
- b.bp("/v1/discoverers/id/{DiscovererId}/start");
889
- b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
890
- let body;
891
- b.m("POST").h(headers).b(body);
892
- return b.build();
893
- }, "se_StartDiscovererCommand");
894
- var se_StopDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
895
- const b = (0, import_core.requestBuilder)(input, context);
896
- const headers = {};
897
- b.bp("/v1/discoverers/id/{DiscovererId}/stop");
898
- b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
899
- let body;
900
- b.m("POST").h(headers).b(body);
901
- return b.build();
902
- }, "se_StopDiscovererCommand");
903
- var se_TagResourceCommand = /* @__PURE__ */ __name(async (input, context) => {
904
- const b = (0, import_core.requestBuilder)(input, context);
905
- const headers = {
906
- "content-type": "application/json"
907
- };
908
- b.bp("/tags/{ResourceArn}");
909
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
910
- let body;
911
- body = JSON.stringify(
912
- (0, import_smithy_client.take)(input, {
913
- tags: [, (_) => (0, import_smithy_client._json)(_), `Tags`]
914
- })
915
- );
916
- b.m("POST").h(headers).b(body);
917
- return b.build();
918
- }, "se_TagResourceCommand");
919
- var se_UntagResourceCommand = /* @__PURE__ */ __name(async (input, context) => {
920
- const b = (0, import_core.requestBuilder)(input, context);
921
- const headers = {};
922
- b.bp("/tags/{ResourceArn}");
923
- b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
924
- const query = (0, import_smithy_client.map)({
925
- [_tK]: [(0, import_smithy_client.expectNonNull)(input.TagKeys, `TagKeys`) != null, () => input[_TK] || []]
926
- });
927
- let body;
928
- b.m("DELETE").h(headers).q(query).b(body);
929
- return b.build();
930
- }, "se_UntagResourceCommand");
931
- var se_UpdateDiscovererCommand = /* @__PURE__ */ __name(async (input, context) => {
932
- const b = (0, import_core.requestBuilder)(input, context);
933
- const headers = {
934
- "content-type": "application/json"
935
- };
936
- b.bp("/v1/discoverers/id/{DiscovererId}");
937
- b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
938
- let body;
939
- body = JSON.stringify(
940
- (0, import_smithy_client.take)(input, {
941
- CrossAccount: [],
942
- Description: []
943
- })
944
- );
945
- b.m("PUT").h(headers).b(body);
946
- return b.build();
947
- }, "se_UpdateDiscovererCommand");
948
- var se_UpdateRegistryCommand = /* @__PURE__ */ __name(async (input, context) => {
949
- const b = (0, import_core.requestBuilder)(input, context);
950
- const headers = {
951
- "content-type": "application/json"
952
- };
953
- b.bp("/v1/registries/name/{RegistryName}");
954
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
955
- let body;
956
- body = JSON.stringify(
957
- (0, import_smithy_client.take)(input, {
958
- Description: []
959
- })
960
- );
961
- b.m("PUT").h(headers).b(body);
962
- return b.build();
963
- }, "se_UpdateRegistryCommand");
964
- var se_UpdateSchemaCommand = /* @__PURE__ */ __name(async (input, context) => {
965
- const b = (0, import_core.requestBuilder)(input, context);
966
- const headers = {
967
- "content-type": "application/json"
968
- };
969
- b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
970
- b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
971
- b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
972
- let body;
973
- body = JSON.stringify(
974
- (0, import_smithy_client.take)(input, {
975
- ClientTokenId: [true, (_) => _ ?? (0, import_uuid.v4)()],
976
- Content: [],
977
- Description: [],
978
- Type: []
979
- })
980
- );
981
- b.m("PUT").h(headers).b(body);
982
- return b.build();
983
- }, "se_UpdateSchemaCommand");
984
- var de_CreateDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
985
- if (output.statusCode !== 201 && output.statusCode >= 300) {
986
- return de_CommandError(output, context);
987
- }
988
- const contents = (0, import_smithy_client.map)({
989
- $metadata: deserializeMetadata(output)
990
- });
991
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
992
- const doc = (0, import_smithy_client.take)(data, {
993
- CrossAccount: import_smithy_client.expectBoolean,
994
- Description: import_smithy_client.expectString,
995
- DiscovererArn: import_smithy_client.expectString,
996
- DiscovererId: import_smithy_client.expectString,
997
- SourceArn: import_smithy_client.expectString,
998
- State: import_smithy_client.expectString,
999
- Tags: [, import_smithy_client._json, `tags`]
1000
- });
1001
- Object.assign(contents, doc);
1002
- return contents;
1003
- }, "de_CreateDiscovererCommand");
1004
- var de_CreateRegistryCommand = /* @__PURE__ */ __name(async (output, context) => {
1005
- if (output.statusCode !== 201 && output.statusCode >= 300) {
1006
- return de_CommandError(output, context);
1007
- }
1008
- const contents = (0, import_smithy_client.map)({
1009
- $metadata: deserializeMetadata(output)
1010
- });
1011
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1012
- const doc = (0, import_smithy_client.take)(data, {
1013
- Description: import_smithy_client.expectString,
1014
- RegistryArn: import_smithy_client.expectString,
1015
- RegistryName: import_smithy_client.expectString,
1016
- Tags: [, import_smithy_client._json, `tags`]
1017
- });
1018
- Object.assign(contents, doc);
1019
- return contents;
1020
- }, "de_CreateRegistryCommand");
1021
- var de_CreateSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1022
- if (output.statusCode !== 201 && output.statusCode >= 300) {
1023
- return de_CommandError(output, context);
1024
- }
1025
- const contents = (0, import_smithy_client.map)({
1026
- $metadata: deserializeMetadata(output)
1027
- });
1028
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1029
- const doc = (0, import_smithy_client.take)(data, {
1030
- Description: import_smithy_client.expectString,
1031
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1032
- SchemaArn: import_smithy_client.expectString,
1033
- SchemaName: import_smithy_client.expectString,
1034
- SchemaVersion: import_smithy_client.expectString,
1035
- Tags: [, import_smithy_client._json, `tags`],
1036
- Type: import_smithy_client.expectString,
1037
- VersionCreatedDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "VersionCreatedDate")
1038
- });
1039
- Object.assign(contents, doc);
1040
- return contents;
1041
- }, "de_CreateSchemaCommand");
1042
- var de_DeleteDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
1043
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1044
- return de_CommandError(output, context);
1045
- }
1046
- const contents = (0, import_smithy_client.map)({
1047
- $metadata: deserializeMetadata(output)
1048
- });
1049
- await (0, import_smithy_client.collectBody)(output.body, context);
1050
- return contents;
1051
- }, "de_DeleteDiscovererCommand");
1052
- var de_DeleteRegistryCommand = /* @__PURE__ */ __name(async (output, context) => {
1053
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1054
- return de_CommandError(output, context);
1055
- }
1056
- const contents = (0, import_smithy_client.map)({
1057
- $metadata: deserializeMetadata(output)
1058
- });
1059
- await (0, import_smithy_client.collectBody)(output.body, context);
1060
- return contents;
1061
- }, "de_DeleteRegistryCommand");
1062
- var de_DeleteResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
1063
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1064
- return de_CommandError(output, context);
1065
- }
1066
- const contents = (0, import_smithy_client.map)({
1067
- $metadata: deserializeMetadata(output)
1068
- });
1069
- await (0, import_smithy_client.collectBody)(output.body, context);
1070
- return contents;
1071
- }, "de_DeleteResourcePolicyCommand");
1072
- var de_DeleteSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1073
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1074
- return de_CommandError(output, context);
1075
- }
1076
- const contents = (0, import_smithy_client.map)({
1077
- $metadata: deserializeMetadata(output)
1078
- });
1079
- await (0, import_smithy_client.collectBody)(output.body, context);
1080
- return contents;
1081
- }, "de_DeleteSchemaCommand");
1082
- var de_DeleteSchemaVersionCommand = /* @__PURE__ */ __name(async (output, context) => {
1083
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1084
- return de_CommandError(output, context);
1085
- }
1086
- const contents = (0, import_smithy_client.map)({
1087
- $metadata: deserializeMetadata(output)
1088
- });
1089
- await (0, import_smithy_client.collectBody)(output.body, context);
1090
- return contents;
1091
- }, "de_DeleteSchemaVersionCommand");
1092
- var de_DescribeCodeBindingCommand = /* @__PURE__ */ __name(async (output, context) => {
1093
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1094
- return de_CommandError(output, context);
1095
- }
1096
- const contents = (0, import_smithy_client.map)({
1097
- $metadata: deserializeMetadata(output)
1098
- });
1099
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1100
- const doc = (0, import_smithy_client.take)(data, {
1101
- CreationDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "CreationDate"),
1102
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1103
- SchemaVersion: import_smithy_client.expectString,
1104
- Status: import_smithy_client.expectString
1105
- });
1106
- Object.assign(contents, doc);
1107
- return contents;
1108
- }, "de_DescribeCodeBindingCommand");
1109
- var de_DescribeDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
1110
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1111
- return de_CommandError(output, context);
1112
- }
1113
- const contents = (0, import_smithy_client.map)({
1114
- $metadata: deserializeMetadata(output)
1115
- });
1116
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1117
- const doc = (0, import_smithy_client.take)(data, {
1118
- CrossAccount: import_smithy_client.expectBoolean,
1119
- Description: import_smithy_client.expectString,
1120
- DiscovererArn: import_smithy_client.expectString,
1121
- DiscovererId: import_smithy_client.expectString,
1122
- SourceArn: import_smithy_client.expectString,
1123
- State: import_smithy_client.expectString,
1124
- Tags: [, import_smithy_client._json, `tags`]
1125
- });
1126
- Object.assign(contents, doc);
1127
- return contents;
1128
- }, "de_DescribeDiscovererCommand");
1129
- var de_DescribeRegistryCommand = /* @__PURE__ */ __name(async (output, context) => {
1130
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1131
- return de_CommandError(output, context);
1132
- }
1133
- const contents = (0, import_smithy_client.map)({
1134
- $metadata: deserializeMetadata(output)
1135
- });
1136
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1137
- const doc = (0, import_smithy_client.take)(data, {
1138
- Description: import_smithy_client.expectString,
1139
- RegistryArn: import_smithy_client.expectString,
1140
- RegistryName: import_smithy_client.expectString,
1141
- Tags: [, import_smithy_client._json, `tags`]
1142
- });
1143
- Object.assign(contents, doc);
1144
- return contents;
1145
- }, "de_DescribeRegistryCommand");
1146
- var de_DescribeSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1147
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1148
- return de_CommandError(output, context);
1149
- }
1150
- const contents = (0, import_smithy_client.map)({
1151
- $metadata: deserializeMetadata(output)
1152
- });
1153
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1154
- const doc = (0, import_smithy_client.take)(data, {
1155
- Content: import_smithy_client.expectString,
1156
- Description: import_smithy_client.expectString,
1157
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1158
- SchemaArn: import_smithy_client.expectString,
1159
- SchemaName: import_smithy_client.expectString,
1160
- SchemaVersion: import_smithy_client.expectString,
1161
- Tags: [, import_smithy_client._json, `tags`],
1162
- Type: import_smithy_client.expectString,
1163
- VersionCreatedDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "VersionCreatedDate")
1164
- });
1165
- Object.assign(contents, doc);
1166
- return contents;
1167
- }, "de_DescribeSchemaCommand");
1168
- var de_ExportSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1169
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1170
- return de_CommandError(output, context);
1171
- }
1172
- const contents = (0, import_smithy_client.map)({
1173
- $metadata: deserializeMetadata(output)
1174
- });
1175
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1176
- const doc = (0, import_smithy_client.take)(data, {
1177
- Content: import_smithy_client.expectString,
1178
- SchemaArn: import_smithy_client.expectString,
1179
- SchemaName: import_smithy_client.expectString,
1180
- SchemaVersion: import_smithy_client.expectString,
1181
- Type: import_smithy_client.expectString
1182
- });
1183
- Object.assign(contents, doc);
1184
- return contents;
1185
- }, "de_ExportSchemaCommand");
1186
- var de_GetCodeBindingSourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1187
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1188
- return de_CommandError(output, context);
1189
- }
1190
- const contents = (0, import_smithy_client.map)({
1191
- $metadata: deserializeMetadata(output)
1192
- });
1193
- const data = await (0, import_smithy_client.collectBody)(output.body, context);
1194
- contents.Body = data;
1195
- return contents;
1196
- }, "de_GetCodeBindingSourceCommand");
1197
- var de_GetDiscoveredSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1198
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1199
- return de_CommandError(output, context);
1200
- }
1201
- const contents = (0, import_smithy_client.map)({
1202
- $metadata: deserializeMetadata(output)
1203
- });
1204
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1205
- const doc = (0, import_smithy_client.take)(data, {
1206
- Content: import_smithy_client.expectString
1207
- });
1208
- Object.assign(contents, doc);
1209
- return contents;
1210
- }, "de_GetDiscoveredSchemaCommand");
1211
- var de_GetResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
1212
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1213
- return de_CommandError(output, context);
1214
- }
1215
- const contents = (0, import_smithy_client.map)({
1216
- $metadata: deserializeMetadata(output)
1217
- });
1218
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1219
- const doc = (0, import_smithy_client.take)(data, {
1220
- Policy: import_smithy_client.LazyJsonString.from,
1221
- RevisionId: import_smithy_client.expectString
1222
- });
1223
- Object.assign(contents, doc);
1224
- return contents;
1225
- }, "de_GetResourcePolicyCommand");
1226
- var de_ListDiscoverersCommand = /* @__PURE__ */ __name(async (output, context) => {
1227
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1228
- return de_CommandError(output, context);
1229
- }
1230
- const contents = (0, import_smithy_client.map)({
1231
- $metadata: deserializeMetadata(output)
1232
- });
1233
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1234
- const doc = (0, import_smithy_client.take)(data, {
1235
- Discoverers: /* @__PURE__ */ __name((_) => de___listOfDiscovererSummary(_, context), "Discoverers"),
1236
- NextToken: import_smithy_client.expectString
1237
- });
1238
- Object.assign(contents, doc);
1239
- return contents;
1240
- }, "de_ListDiscoverersCommand");
1241
- var de_ListRegistriesCommand = /* @__PURE__ */ __name(async (output, context) => {
1242
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1243
- return de_CommandError(output, context);
1244
- }
1245
- const contents = (0, import_smithy_client.map)({
1246
- $metadata: deserializeMetadata(output)
1247
- });
1248
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1249
- const doc = (0, import_smithy_client.take)(data, {
1250
- NextToken: import_smithy_client.expectString,
1251
- Registries: /* @__PURE__ */ __name((_) => de___listOfRegistrySummary(_, context), "Registries")
1252
- });
1253
- Object.assign(contents, doc);
1254
- return contents;
1255
- }, "de_ListRegistriesCommand");
1256
- var de_ListSchemasCommand = /* @__PURE__ */ __name(async (output, context) => {
1257
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1258
- return de_CommandError(output, context);
1259
- }
1260
- const contents = (0, import_smithy_client.map)({
1261
- $metadata: deserializeMetadata(output)
1262
- });
1263
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1264
- const doc = (0, import_smithy_client.take)(data, {
1265
- NextToken: import_smithy_client.expectString,
1266
- Schemas: /* @__PURE__ */ __name((_) => de___listOfSchemaSummary(_, context), "Schemas")
1267
- });
1268
- Object.assign(contents, doc);
1269
- return contents;
1270
- }, "de_ListSchemasCommand");
1271
- var de_ListSchemaVersionsCommand = /* @__PURE__ */ __name(async (output, context) => {
1272
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1273
- return de_CommandError(output, context);
1274
- }
1275
- const contents = (0, import_smithy_client.map)({
1276
- $metadata: deserializeMetadata(output)
1277
- });
1278
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1279
- const doc = (0, import_smithy_client.take)(data, {
1280
- NextToken: import_smithy_client.expectString,
1281
- SchemaVersions: import_smithy_client._json
1282
- });
1283
- Object.assign(contents, doc);
1284
- return contents;
1285
- }, "de_ListSchemaVersionsCommand");
1286
- var de_ListTagsForResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1287
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1288
- return de_CommandError(output, context);
1289
- }
1290
- const contents = (0, import_smithy_client.map)({
1291
- $metadata: deserializeMetadata(output)
1292
- });
1293
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1294
- const doc = (0, import_smithy_client.take)(data, {
1295
- Tags: [, import_smithy_client._json, `tags`]
1296
- });
1297
- Object.assign(contents, doc);
1298
- return contents;
1299
- }, "de_ListTagsForResourceCommand");
1300
- var de_PutCodeBindingCommand = /* @__PURE__ */ __name(async (output, context) => {
1301
- if (output.statusCode !== 202 && output.statusCode >= 300) {
1302
- return de_CommandError(output, context);
1303
- }
1304
- const contents = (0, import_smithy_client.map)({
1305
- $metadata: deserializeMetadata(output)
1306
- });
1307
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1308
- const doc = (0, import_smithy_client.take)(data, {
1309
- CreationDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "CreationDate"),
1310
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1311
- SchemaVersion: import_smithy_client.expectString,
1312
- Status: import_smithy_client.expectString
1313
- });
1314
- Object.assign(contents, doc);
1315
- return contents;
1316
- }, "de_PutCodeBindingCommand");
1317
- var de_PutResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
1318
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1319
- return de_CommandError(output, context);
1320
- }
1321
- const contents = (0, import_smithy_client.map)({
1322
- $metadata: deserializeMetadata(output)
1323
- });
1324
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1325
- const doc = (0, import_smithy_client.take)(data, {
1326
- Policy: import_smithy_client.LazyJsonString.from,
1327
- RevisionId: import_smithy_client.expectString
1328
- });
1329
- Object.assign(contents, doc);
1330
- return contents;
1331
- }, "de_PutResourcePolicyCommand");
1332
- var de_SearchSchemasCommand = /* @__PURE__ */ __name(async (output, context) => {
1333
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1334
- return de_CommandError(output, context);
1335
- }
1336
- const contents = (0, import_smithy_client.map)({
1337
- $metadata: deserializeMetadata(output)
1338
- });
1339
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1340
- const doc = (0, import_smithy_client.take)(data, {
1341
- NextToken: import_smithy_client.expectString,
1342
- Schemas: /* @__PURE__ */ __name((_) => de___listOfSearchSchemaSummary(_, context), "Schemas")
1343
- });
1344
- Object.assign(contents, doc);
1345
- return contents;
1346
- }, "de_SearchSchemasCommand");
1347
- var de_StartDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
1348
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1349
- return de_CommandError(output, context);
1350
- }
1351
- const contents = (0, import_smithy_client.map)({
1352
- $metadata: deserializeMetadata(output)
1353
- });
1354
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1355
- const doc = (0, import_smithy_client.take)(data, {
1356
- DiscovererId: import_smithy_client.expectString,
1357
- State: import_smithy_client.expectString
1358
- });
1359
- Object.assign(contents, doc);
1360
- return contents;
1361
- }, "de_StartDiscovererCommand");
1362
- var de_StopDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
1363
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1364
- return de_CommandError(output, context);
1365
- }
1366
- const contents = (0, import_smithy_client.map)({
1367
- $metadata: deserializeMetadata(output)
1368
- });
1369
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1370
- const doc = (0, import_smithy_client.take)(data, {
1371
- DiscovererId: import_smithy_client.expectString,
1372
- State: import_smithy_client.expectString
1373
- });
1374
- Object.assign(contents, doc);
1375
- return contents;
1376
- }, "de_StopDiscovererCommand");
1377
- var de_TagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1378
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1379
- return de_CommandError(output, context);
1380
- }
1381
- const contents = (0, import_smithy_client.map)({
1382
- $metadata: deserializeMetadata(output)
1383
- });
1384
- await (0, import_smithy_client.collectBody)(output.body, context);
1385
- return contents;
1386
- }, "de_TagResourceCommand");
1387
- var de_UntagResourceCommand = /* @__PURE__ */ __name(async (output, context) => {
1388
- if (output.statusCode !== 204 && output.statusCode >= 300) {
1389
- return de_CommandError(output, context);
1390
- }
1391
- const contents = (0, import_smithy_client.map)({
1392
- $metadata: deserializeMetadata(output)
1393
- });
1394
- await (0, import_smithy_client.collectBody)(output.body, context);
1395
- return contents;
1396
- }, "de_UntagResourceCommand");
1397
- var de_UpdateDiscovererCommand = /* @__PURE__ */ __name(async (output, context) => {
1398
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1399
- return de_CommandError(output, context);
1400
- }
1401
- const contents = (0, import_smithy_client.map)({
1402
- $metadata: deserializeMetadata(output)
1403
- });
1404
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1405
- const doc = (0, import_smithy_client.take)(data, {
1406
- CrossAccount: import_smithy_client.expectBoolean,
1407
- Description: import_smithy_client.expectString,
1408
- DiscovererArn: import_smithy_client.expectString,
1409
- DiscovererId: import_smithy_client.expectString,
1410
- SourceArn: import_smithy_client.expectString,
1411
- State: import_smithy_client.expectString,
1412
- Tags: [, import_smithy_client._json, `tags`]
1413
- });
1414
- Object.assign(contents, doc);
1415
- return contents;
1416
- }, "de_UpdateDiscovererCommand");
1417
- var de_UpdateRegistryCommand = /* @__PURE__ */ __name(async (output, context) => {
1418
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1419
- return de_CommandError(output, context);
1420
- }
1421
- const contents = (0, import_smithy_client.map)({
1422
- $metadata: deserializeMetadata(output)
1423
- });
1424
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1425
- const doc = (0, import_smithy_client.take)(data, {
1426
- Description: import_smithy_client.expectString,
1427
- RegistryArn: import_smithy_client.expectString,
1428
- RegistryName: import_smithy_client.expectString,
1429
- Tags: [, import_smithy_client._json, `tags`]
1430
- });
1431
- Object.assign(contents, doc);
1432
- return contents;
1433
- }, "de_UpdateRegistryCommand");
1434
- var de_UpdateSchemaCommand = /* @__PURE__ */ __name(async (output, context) => {
1435
- if (output.statusCode !== 200 && output.statusCode >= 300) {
1436
- return de_CommandError(output, context);
1437
- }
1438
- const contents = (0, import_smithy_client.map)({
1439
- $metadata: deserializeMetadata(output)
1440
- });
1441
- const data = (0, import_smithy_client.expectNonNull)((0, import_smithy_client.expectObject)(await (0, import_core2.parseJsonBody)(output.body, context)), "body");
1442
- const doc = (0, import_smithy_client.take)(data, {
1443
- Description: import_smithy_client.expectString,
1444
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1445
- SchemaArn: import_smithy_client.expectString,
1446
- SchemaName: import_smithy_client.expectString,
1447
- SchemaVersion: import_smithy_client.expectString,
1448
- Tags: [, import_smithy_client._json, `tags`],
1449
- Type: import_smithy_client.expectString,
1450
- VersionCreatedDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "VersionCreatedDate")
1451
- });
1452
- Object.assign(contents, doc);
1453
- return contents;
1454
- }, "de_UpdateSchemaCommand");
1455
- var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
1456
- const parsedOutput = {
1457
- ...output,
1458
- body: await (0, import_core2.parseJsonErrorBody)(output.body, context)
1459
- };
1460
- const errorCode = (0, import_core2.loadRestJsonErrorCode)(output, parsedOutput.body);
1461
- switch (errorCode) {
1462
- case "BadRequestException":
1463
- case "com.amazonaws.schemas#BadRequestException":
1464
- throw await de_BadRequestExceptionRes(parsedOutput, context);
1465
- case "ConflictException":
1466
- case "com.amazonaws.schemas#ConflictException":
1467
- throw await de_ConflictExceptionRes(parsedOutput, context);
1468
- case "ForbiddenException":
1469
- case "com.amazonaws.schemas#ForbiddenException":
1470
- throw await de_ForbiddenExceptionRes(parsedOutput, context);
1471
- case "InternalServerErrorException":
1472
- case "com.amazonaws.schemas#InternalServerErrorException":
1473
- throw await de_InternalServerErrorExceptionRes(parsedOutput, context);
1474
- case "ServiceUnavailableException":
1475
- case "com.amazonaws.schemas#ServiceUnavailableException":
1476
- throw await de_ServiceUnavailableExceptionRes(parsedOutput, context);
1477
- case "UnauthorizedException":
1478
- case "com.amazonaws.schemas#UnauthorizedException":
1479
- throw await de_UnauthorizedExceptionRes(parsedOutput, context);
1480
- case "NotFoundException":
1481
- case "com.amazonaws.schemas#NotFoundException":
1482
- throw await de_NotFoundExceptionRes(parsedOutput, context);
1483
- case "TooManyRequestsException":
1484
- case "com.amazonaws.schemas#TooManyRequestsException":
1485
- throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
1486
- case "GoneException":
1487
- case "com.amazonaws.schemas#GoneException":
1488
- throw await de_GoneExceptionRes(parsedOutput, context);
1489
- case "PreconditionFailedException":
1490
- case "com.amazonaws.schemas#PreconditionFailedException":
1491
- throw await de_PreconditionFailedExceptionRes(parsedOutput, context);
1492
- default:
1493
- const parsedBody = parsedOutput.body;
1494
- return throwDefaultError({
1495
- output,
1496
- parsedBody,
1497
- errorCode
1498
- });
1499
- }
1500
- }, "de_CommandError");
1501
- var throwDefaultError = (0, import_smithy_client.withBaseException)(SchemasServiceException);
1502
- var de_BadRequestExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1503
- const contents = (0, import_smithy_client.map)({});
1504
- const data = parsedOutput.body;
1505
- const doc = (0, import_smithy_client.take)(data, {
1506
- Code: import_smithy_client.expectString,
1507
- Message: import_smithy_client.expectString
1508
- });
1509
- Object.assign(contents, doc);
1510
- const exception = new BadRequestException({
1511
- $metadata: deserializeMetadata(parsedOutput),
1512
- ...contents
1513
- });
1514
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1515
- }, "de_BadRequestExceptionRes");
1516
- var de_ConflictExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1517
- const contents = (0, import_smithy_client.map)({});
1518
- const data = parsedOutput.body;
1519
- const doc = (0, import_smithy_client.take)(data, {
1520
- Code: import_smithy_client.expectString,
1521
- Message: import_smithy_client.expectString
1522
- });
1523
- Object.assign(contents, doc);
1524
- const exception = new ConflictException({
1525
- $metadata: deserializeMetadata(parsedOutput),
1526
- ...contents
1527
- });
1528
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1529
- }, "de_ConflictExceptionRes");
1530
- var de_ForbiddenExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1531
- const contents = (0, import_smithy_client.map)({});
1532
- const data = parsedOutput.body;
1533
- const doc = (0, import_smithy_client.take)(data, {
1534
- Code: import_smithy_client.expectString,
1535
- Message: import_smithy_client.expectString
1536
- });
1537
- Object.assign(contents, doc);
1538
- const exception = new ForbiddenException({
1539
- $metadata: deserializeMetadata(parsedOutput),
1540
- ...contents
1541
- });
1542
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1543
- }, "de_ForbiddenExceptionRes");
1544
- var de_GoneExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1545
- const contents = (0, import_smithy_client.map)({});
1546
- const data = parsedOutput.body;
1547
- const doc = (0, import_smithy_client.take)(data, {
1548
- Code: import_smithy_client.expectString,
1549
- Message: import_smithy_client.expectString
1550
- });
1551
- Object.assign(contents, doc);
1552
- const exception = new GoneException({
1553
- $metadata: deserializeMetadata(parsedOutput),
1554
- ...contents
1555
- });
1556
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1557
- }, "de_GoneExceptionRes");
1558
- var de_InternalServerErrorExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1559
- const contents = (0, import_smithy_client.map)({});
1560
- const data = parsedOutput.body;
1561
- const doc = (0, import_smithy_client.take)(data, {
1562
- Code: import_smithy_client.expectString,
1563
- Message: import_smithy_client.expectString
1564
- });
1565
- Object.assign(contents, doc);
1566
- const exception = new InternalServerErrorException({
1567
- $metadata: deserializeMetadata(parsedOutput),
1568
- ...contents
1569
- });
1570
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1571
- }, "de_InternalServerErrorExceptionRes");
1572
- var de_NotFoundExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1573
- const contents = (0, import_smithy_client.map)({});
1574
- const data = parsedOutput.body;
1575
- const doc = (0, import_smithy_client.take)(data, {
1576
- Code: import_smithy_client.expectString,
1577
- Message: import_smithy_client.expectString
1578
- });
1579
- Object.assign(contents, doc);
1580
- const exception = new NotFoundException({
1581
- $metadata: deserializeMetadata(parsedOutput),
1582
- ...contents
1583
- });
1584
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1585
- }, "de_NotFoundExceptionRes");
1586
- var de_PreconditionFailedExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1587
- const contents = (0, import_smithy_client.map)({});
1588
- const data = parsedOutput.body;
1589
- const doc = (0, import_smithy_client.take)(data, {
1590
- Code: import_smithy_client.expectString,
1591
- Message: import_smithy_client.expectString
1592
- });
1593
- Object.assign(contents, doc);
1594
- const exception = new PreconditionFailedException({
1595
- $metadata: deserializeMetadata(parsedOutput),
1596
- ...contents
1597
- });
1598
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1599
- }, "de_PreconditionFailedExceptionRes");
1600
- var de_ServiceUnavailableExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1601
- const contents = (0, import_smithy_client.map)({});
1602
- const data = parsedOutput.body;
1603
- const doc = (0, import_smithy_client.take)(data, {
1604
- Code: import_smithy_client.expectString,
1605
- Message: import_smithy_client.expectString
1606
- });
1607
- Object.assign(contents, doc);
1608
- const exception = new ServiceUnavailableException({
1609
- $metadata: deserializeMetadata(parsedOutput),
1610
- ...contents
1611
- });
1612
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1613
- }, "de_ServiceUnavailableExceptionRes");
1614
- var de_TooManyRequestsExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1615
- const contents = (0, import_smithy_client.map)({});
1616
- const data = parsedOutput.body;
1617
- const doc = (0, import_smithy_client.take)(data, {
1618
- Code: import_smithy_client.expectString,
1619
- Message: import_smithy_client.expectString
1620
- });
1621
- Object.assign(contents, doc);
1622
- const exception = new TooManyRequestsException({
1623
- $metadata: deserializeMetadata(parsedOutput),
1624
- ...contents
1625
- });
1626
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1627
- }, "de_TooManyRequestsExceptionRes");
1628
- var de_UnauthorizedExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
1629
- const contents = (0, import_smithy_client.map)({});
1630
- const data = parsedOutput.body;
1631
- const doc = (0, import_smithy_client.take)(data, {
1632
- Code: import_smithy_client.expectString,
1633
- Message: import_smithy_client.expectString
1634
- });
1635
- Object.assign(contents, doc);
1636
- const exception = new UnauthorizedException({
1637
- $metadata: deserializeMetadata(parsedOutput),
1638
- ...contents
1639
- });
1640
- return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
1641
- }, "de_UnauthorizedExceptionRes");
1642
- var de___listOfDiscovererSummary = /* @__PURE__ */ __name((output, context) => {
1643
- const retVal = (output || []).filter((e) => e != null).map((entry) => {
1644
- return de_DiscovererSummary(entry, context);
1645
- });
1646
- return retVal;
1647
- }, "de___listOfDiscovererSummary");
1648
- var de___listOfRegistrySummary = /* @__PURE__ */ __name((output, context) => {
1649
- const retVal = (output || []).filter((e) => e != null).map((entry) => {
1650
- return de_RegistrySummary(entry, context);
1651
- });
1652
- return retVal;
1653
- }, "de___listOfRegistrySummary");
1654
- var de___listOfSchemaSummary = /* @__PURE__ */ __name((output, context) => {
1655
- const retVal = (output || []).filter((e) => e != null).map((entry) => {
1656
- return de_SchemaSummary(entry, context);
1657
- });
1658
- return retVal;
1659
- }, "de___listOfSchemaSummary");
1660
- var de___listOfSearchSchemaSummary = /* @__PURE__ */ __name((output, context) => {
1661
- const retVal = (output || []).filter((e) => e != null).map((entry) => {
1662
- return de_SearchSchemaSummary(entry, context);
1663
- });
1664
- return retVal;
1665
- }, "de___listOfSearchSchemaSummary");
1666
- var de___listOfSearchSchemaVersionSummary = /* @__PURE__ */ __name((output, context) => {
1667
- const retVal = (output || []).filter((e) => e != null).map((entry) => {
1668
- return de_SearchSchemaVersionSummary(entry, context);
1669
- });
1670
- return retVal;
1671
- }, "de___listOfSearchSchemaVersionSummary");
1672
- var de_DiscovererSummary = /* @__PURE__ */ __name((output, context) => {
1673
- return (0, import_smithy_client.take)(output, {
1674
- CrossAccount: import_smithy_client.expectBoolean,
1675
- DiscovererArn: import_smithy_client.expectString,
1676
- DiscovererId: import_smithy_client.expectString,
1677
- SourceArn: import_smithy_client.expectString,
1678
- State: import_smithy_client.expectString,
1679
- Tags: [, import_smithy_client._json, `tags`]
1680
- });
1681
- }, "de_DiscovererSummary");
1682
- var de_RegistrySummary = /* @__PURE__ */ __name((output, context) => {
1683
- return (0, import_smithy_client.take)(output, {
1684
- RegistryArn: import_smithy_client.expectString,
1685
- RegistryName: import_smithy_client.expectString,
1686
- Tags: [, import_smithy_client._json, `tags`]
1687
- });
1688
- }, "de_RegistrySummary");
1689
- var de_SchemaSummary = /* @__PURE__ */ __name((output, context) => {
1690
- return (0, import_smithy_client.take)(output, {
1691
- LastModified: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "LastModified"),
1692
- SchemaArn: import_smithy_client.expectString,
1693
- SchemaName: import_smithy_client.expectString,
1694
- Tags: [, import_smithy_client._json, `tags`],
1695
- VersionCount: import_smithy_client.expectLong
1696
- });
1697
- }, "de_SchemaSummary");
1698
- var de_SearchSchemaSummary = /* @__PURE__ */ __name((output, context) => {
1699
- return (0, import_smithy_client.take)(output, {
1700
- RegistryName: import_smithy_client.expectString,
1701
- SchemaArn: import_smithy_client.expectString,
1702
- SchemaName: import_smithy_client.expectString,
1703
- SchemaVersions: /* @__PURE__ */ __name((_) => de___listOfSearchSchemaVersionSummary(_, context), "SchemaVersions")
1704
- });
1705
- }, "de_SearchSchemaSummary");
1706
- var de_SearchSchemaVersionSummary = /* @__PURE__ */ __name((output, context) => {
1707
- return (0, import_smithy_client.take)(output, {
1708
- CreatedDate: /* @__PURE__ */ __name((_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseRfc3339DateTimeWithOffset)(_)), "CreatedDate"),
1709
- SchemaVersion: import_smithy_client.expectString,
1710
- Type: import_smithy_client.expectString
1711
- });
1712
- }, "de_SearchSchemaVersionSummary");
1713
- var deserializeMetadata = /* @__PURE__ */ __name((output) => ({
1714
- httpStatusCode: output.statusCode,
1715
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
1716
- extendedRequestId: output.headers["x-amz-id-2"],
1717
- cfId: output.headers["x-amz-cf-id"]
1718
- }), "deserializeMetadata");
1719
- var _DIP = "DiscovererIdPrefix";
1720
- var _K = "Keywords";
1721
- var _L = "Limit";
1722
- var _NT = "NextToken";
1723
- var _RN = "RegistryName";
1724
- var _RNP = "RegistryNamePrefix";
1725
- var _S = "Scope";
1726
- var _SAP = "SourceArnPrefix";
1727
- var _SNP = "SchemaNamePrefix";
1728
- var _SV = "SchemaVersion";
1729
- var _T = "Type";
1730
- var _TK = "TagKeys";
1731
- var _dIP = "discovererIdPrefix";
1732
- var _k = "keywords";
1733
- var _l = "limit";
1734
- var _nT = "nextToken";
1735
- var _rN = "registryName";
1736
- var _rNP = "registryNamePrefix";
1737
- var _s = "scope";
1738
- var _sAP = "sourceArnPrefix";
1739
- var _sNP = "schemaNamePrefix";
1740
- var _sV = "schemaVersion";
1741
- var _t = "type";
1742
- var _tK = "tagKeys";
1743
-
1744
- // src/commands/CreateDiscovererCommand.ts
1745
- var CreateDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1746
- return [
1747
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1748
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1749
- ];
1750
- }).s("schemas", "CreateDiscoverer", {}).n("SchemasClient", "CreateDiscovererCommand").f(void 0, void 0).ser(se_CreateDiscovererCommand).de(de_CreateDiscovererCommand).build() {
1751
- static {
1752
- __name(this, "CreateDiscovererCommand");
1753
- }
151
+ class ConflictException extends SchemasServiceException {
152
+ name = "ConflictException";
153
+ $fault = "client";
154
+ Code;
155
+ Message;
156
+ constructor(opts) {
157
+ super({
158
+ name: "ConflictException",
159
+ $fault: "client",
160
+ ...opts,
161
+ });
162
+ Object.setPrototypeOf(this, ConflictException.prototype);
163
+ this.Code = opts.Code;
164
+ this.Message = opts.Message;
165
+ }
166
+ }
167
+ class ForbiddenException extends SchemasServiceException {
168
+ name = "ForbiddenException";
169
+ $fault = "client";
170
+ Code;
171
+ Message;
172
+ constructor(opts) {
173
+ super({
174
+ name: "ForbiddenException",
175
+ $fault: "client",
176
+ ...opts,
177
+ });
178
+ Object.setPrototypeOf(this, ForbiddenException.prototype);
179
+ this.Code = opts.Code;
180
+ this.Message = opts.Message;
181
+ }
182
+ }
183
+ class InternalServerErrorException extends SchemasServiceException {
184
+ name = "InternalServerErrorException";
185
+ $fault = "server";
186
+ Code;
187
+ Message;
188
+ constructor(opts) {
189
+ super({
190
+ name: "InternalServerErrorException",
191
+ $fault: "server",
192
+ ...opts,
193
+ });
194
+ Object.setPrototypeOf(this, InternalServerErrorException.prototype);
195
+ this.Code = opts.Code;
196
+ this.Message = opts.Message;
197
+ }
198
+ }
199
+ class ServiceUnavailableException extends SchemasServiceException {
200
+ name = "ServiceUnavailableException";
201
+ $fault = "server";
202
+ Code;
203
+ Message;
204
+ constructor(opts) {
205
+ super({
206
+ name: "ServiceUnavailableException",
207
+ $fault: "server",
208
+ ...opts,
209
+ });
210
+ Object.setPrototypeOf(this, ServiceUnavailableException.prototype);
211
+ this.Code = opts.Code;
212
+ this.Message = opts.Message;
213
+ }
214
+ }
215
+ class UnauthorizedException extends SchemasServiceException {
216
+ name = "UnauthorizedException";
217
+ $fault = "client";
218
+ Code;
219
+ Message;
220
+ constructor(opts) {
221
+ super({
222
+ name: "UnauthorizedException",
223
+ $fault: "client",
224
+ ...opts,
225
+ });
226
+ Object.setPrototypeOf(this, UnauthorizedException.prototype);
227
+ this.Code = opts.Code;
228
+ this.Message = opts.Message;
229
+ }
230
+ }
231
+ class NotFoundException extends SchemasServiceException {
232
+ name = "NotFoundException";
233
+ $fault = "client";
234
+ Code;
235
+ Message;
236
+ constructor(opts) {
237
+ super({
238
+ name: "NotFoundException",
239
+ $fault: "client",
240
+ ...opts,
241
+ });
242
+ Object.setPrototypeOf(this, NotFoundException.prototype);
243
+ this.Code = opts.Code;
244
+ this.Message = opts.Message;
245
+ }
246
+ }
247
+ class TooManyRequestsException extends SchemasServiceException {
248
+ name = "TooManyRequestsException";
249
+ $fault = "client";
250
+ Code;
251
+ Message;
252
+ constructor(opts) {
253
+ super({
254
+ name: "TooManyRequestsException",
255
+ $fault: "client",
256
+ ...opts,
257
+ });
258
+ Object.setPrototypeOf(this, TooManyRequestsException.prototype);
259
+ this.Code = opts.Code;
260
+ this.Message = opts.Message;
261
+ }
262
+ }
263
+ class GoneException extends SchemasServiceException {
264
+ name = "GoneException";
265
+ $fault = "client";
266
+ Code;
267
+ Message;
268
+ constructor(opts) {
269
+ super({
270
+ name: "GoneException",
271
+ $fault: "client",
272
+ ...opts,
273
+ });
274
+ Object.setPrototypeOf(this, GoneException.prototype);
275
+ this.Code = opts.Code;
276
+ this.Message = opts.Message;
277
+ }
278
+ }
279
+ class PreconditionFailedException extends SchemasServiceException {
280
+ name = "PreconditionFailedException";
281
+ $fault = "client";
282
+ Code;
283
+ Message;
284
+ constructor(opts) {
285
+ super({
286
+ name: "PreconditionFailedException",
287
+ $fault: "client",
288
+ ...opts,
289
+ });
290
+ Object.setPrototypeOf(this, PreconditionFailedException.prototype);
291
+ this.Code = opts.Code;
292
+ this.Message = opts.Message;
293
+ }
294
+ }
295
+
296
+ const se_CreateDiscovererCommand = async (input, context) => {
297
+ const b = core.requestBuilder(input, context);
298
+ const headers = {
299
+ "content-type": "application/json",
300
+ };
301
+ b.bp("/v1/discoverers");
302
+ let body;
303
+ body = JSON.stringify(smithyClient.take(input, {
304
+ CrossAccount: [],
305
+ Description: [],
306
+ SourceArn: [],
307
+ tags: [, (_) => smithyClient._json(_), `Tags`],
308
+ }));
309
+ b.m("POST").h(headers).b(body);
310
+ return b.build();
1754
311
  };
1755
-
1756
- // src/commands/CreateRegistryCommand.ts
1757
-
1758
-
1759
-
1760
- var CreateRegistryCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1761
- return [
1762
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1763
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1764
- ];
1765
- }).s("schemas", "CreateRegistry", {}).n("SchemasClient", "CreateRegistryCommand").f(void 0, void 0).ser(se_CreateRegistryCommand).de(de_CreateRegistryCommand).build() {
1766
- static {
1767
- __name(this, "CreateRegistryCommand");
1768
- }
312
+ const se_CreateRegistryCommand = async (input, context) => {
313
+ const b = core.requestBuilder(input, context);
314
+ const headers = {
315
+ "content-type": "application/json",
316
+ };
317
+ b.bp("/v1/registries/name/{RegistryName}");
318
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
319
+ let body;
320
+ body = JSON.stringify(smithyClient.take(input, {
321
+ Description: [],
322
+ tags: [, (_) => smithyClient._json(_), `Tags`],
323
+ }));
324
+ b.m("POST").h(headers).b(body);
325
+ return b.build();
1769
326
  };
1770
-
1771
- // src/commands/CreateSchemaCommand.ts
1772
-
1773
-
1774
-
1775
- var CreateSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1776
- return [
1777
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1778
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1779
- ];
1780
- }).s("schemas", "CreateSchema", {}).n("SchemasClient", "CreateSchemaCommand").f(void 0, void 0).ser(se_CreateSchemaCommand).de(de_CreateSchemaCommand).build() {
1781
- static {
1782
- __name(this, "CreateSchemaCommand");
1783
- }
327
+ const se_CreateSchemaCommand = async (input, context) => {
328
+ const b = core.requestBuilder(input, context);
329
+ const headers = {
330
+ "content-type": "application/json",
331
+ };
332
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
333
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
334
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
335
+ let body;
336
+ body = JSON.stringify(smithyClient.take(input, {
337
+ Content: [],
338
+ Description: [],
339
+ tags: [, (_) => smithyClient._json(_), `Tags`],
340
+ Type: [],
341
+ }));
342
+ b.m("POST").h(headers).b(body);
343
+ return b.build();
1784
344
  };
1785
-
1786
- // src/commands/DeleteDiscovererCommand.ts
1787
-
1788
-
1789
-
1790
- var DeleteDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1791
- return [
1792
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1793
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1794
- ];
1795
- }).s("schemas", "DeleteDiscoverer", {}).n("SchemasClient", "DeleteDiscovererCommand").f(void 0, void 0).ser(se_DeleteDiscovererCommand).de(de_DeleteDiscovererCommand).build() {
1796
- static {
1797
- __name(this, "DeleteDiscovererCommand");
1798
- }
345
+ const se_DeleteDiscovererCommand = async (input, context) => {
346
+ const b = core.requestBuilder(input, context);
347
+ const headers = {};
348
+ b.bp("/v1/discoverers/id/{DiscovererId}");
349
+ b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
350
+ let body;
351
+ b.m("DELETE").h(headers).b(body);
352
+ return b.build();
1799
353
  };
1800
-
1801
- // src/commands/DeleteRegistryCommand.ts
1802
-
1803
-
1804
-
1805
- var DeleteRegistryCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1806
- return [
1807
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1808
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1809
- ];
1810
- }).s("schemas", "DeleteRegistry", {}).n("SchemasClient", "DeleteRegistryCommand").f(void 0, void 0).ser(se_DeleteRegistryCommand).de(de_DeleteRegistryCommand).build() {
1811
- static {
1812
- __name(this, "DeleteRegistryCommand");
1813
- }
354
+ const se_DeleteRegistryCommand = async (input, context) => {
355
+ const b = core.requestBuilder(input, context);
356
+ const headers = {};
357
+ b.bp("/v1/registries/name/{RegistryName}");
358
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
359
+ let body;
360
+ b.m("DELETE").h(headers).b(body);
361
+ return b.build();
1814
362
  };
1815
-
1816
- // src/commands/DeleteResourcePolicyCommand.ts
1817
-
1818
-
1819
-
1820
- var DeleteResourcePolicyCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1821
- return [
1822
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1823
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1824
- ];
1825
- }).s("schemas", "DeleteResourcePolicy", {}).n("SchemasClient", "DeleteResourcePolicyCommand").f(void 0, void 0).ser(se_DeleteResourcePolicyCommand).de(de_DeleteResourcePolicyCommand).build() {
1826
- static {
1827
- __name(this, "DeleteResourcePolicyCommand");
1828
- }
363
+ const se_DeleteResourcePolicyCommand = async (input, context) => {
364
+ const b = core.requestBuilder(input, context);
365
+ const headers = {};
366
+ b.bp("/v1/policy");
367
+ const query = smithyClient.map({
368
+ [_rN]: [, input[_RN]],
369
+ });
370
+ let body;
371
+ b.m("DELETE").h(headers).q(query).b(body);
372
+ return b.build();
1829
373
  };
1830
-
1831
- // src/commands/DeleteSchemaCommand.ts
1832
-
1833
-
1834
-
1835
- var DeleteSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1836
- return [
1837
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1838
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1839
- ];
1840
- }).s("schemas", "DeleteSchema", {}).n("SchemasClient", "DeleteSchemaCommand").f(void 0, void 0).ser(se_DeleteSchemaCommand).de(de_DeleteSchemaCommand).build() {
1841
- static {
1842
- __name(this, "DeleteSchemaCommand");
1843
- }
374
+ const se_DeleteSchemaCommand = async (input, context) => {
375
+ const b = core.requestBuilder(input, context);
376
+ const headers = {};
377
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
378
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
379
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
380
+ let body;
381
+ b.m("DELETE").h(headers).b(body);
382
+ return b.build();
1844
383
  };
1845
-
1846
- // src/commands/DeleteSchemaVersionCommand.ts
1847
-
1848
-
1849
-
1850
- var DeleteSchemaVersionCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1851
- return [
1852
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1853
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1854
- ];
1855
- }).s("schemas", "DeleteSchemaVersion", {}).n("SchemasClient", "DeleteSchemaVersionCommand").f(void 0, void 0).ser(se_DeleteSchemaVersionCommand).de(de_DeleteSchemaVersionCommand).build() {
1856
- static {
1857
- __name(this, "DeleteSchemaVersionCommand");
1858
- }
384
+ const se_DeleteSchemaVersionCommand = async (input, context) => {
385
+ const b = core.requestBuilder(input, context);
386
+ const headers = {};
387
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/version/{SchemaVersion}");
388
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
389
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
390
+ b.p("SchemaVersion", () => input.SchemaVersion, "{SchemaVersion}", false);
391
+ let body;
392
+ b.m("DELETE").h(headers).b(body);
393
+ return b.build();
1859
394
  };
1860
-
1861
- // src/commands/DescribeCodeBindingCommand.ts
1862
-
1863
-
1864
-
1865
- var DescribeCodeBindingCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1866
- return [
1867
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1868
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1869
- ];
1870
- }).s("schemas", "DescribeCodeBinding", {}).n("SchemasClient", "DescribeCodeBindingCommand").f(void 0, void 0).ser(se_DescribeCodeBindingCommand).de(de_DescribeCodeBindingCommand).build() {
1871
- static {
1872
- __name(this, "DescribeCodeBindingCommand");
1873
- }
395
+ const se_DescribeCodeBindingCommand = async (input, context) => {
396
+ const b = core.requestBuilder(input, context);
397
+ const headers = {};
398
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}");
399
+ b.p("Language", () => input.Language, "{Language}", false);
400
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
401
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
402
+ const query = smithyClient.map({
403
+ [_sV]: [, input[_SV]],
404
+ });
405
+ let body;
406
+ b.m("GET").h(headers).q(query).b(body);
407
+ return b.build();
1874
408
  };
1875
-
1876
- // src/commands/DescribeDiscovererCommand.ts
1877
-
1878
-
1879
-
1880
- var DescribeDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1881
- return [
1882
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1883
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1884
- ];
1885
- }).s("schemas", "DescribeDiscoverer", {}).n("SchemasClient", "DescribeDiscovererCommand").f(void 0, void 0).ser(se_DescribeDiscovererCommand).de(de_DescribeDiscovererCommand).build() {
1886
- static {
1887
- __name(this, "DescribeDiscovererCommand");
1888
- }
409
+ const se_DescribeDiscovererCommand = async (input, context) => {
410
+ const b = core.requestBuilder(input, context);
411
+ const headers = {};
412
+ b.bp("/v1/discoverers/id/{DiscovererId}");
413
+ b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
414
+ let body;
415
+ b.m("GET").h(headers).b(body);
416
+ return b.build();
1889
417
  };
1890
-
1891
- // src/commands/DescribeRegistryCommand.ts
1892
-
1893
-
1894
-
1895
- var DescribeRegistryCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1896
- return [
1897
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1898
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1899
- ];
1900
- }).s("schemas", "DescribeRegistry", {}).n("SchemasClient", "DescribeRegistryCommand").f(void 0, void 0).ser(se_DescribeRegistryCommand).de(de_DescribeRegistryCommand).build() {
1901
- static {
1902
- __name(this, "DescribeRegistryCommand");
1903
- }
418
+ const se_DescribeRegistryCommand = async (input, context) => {
419
+ const b = core.requestBuilder(input, context);
420
+ const headers = {};
421
+ b.bp("/v1/registries/name/{RegistryName}");
422
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
423
+ let body;
424
+ b.m("GET").h(headers).b(body);
425
+ return b.build();
1904
426
  };
1905
-
1906
- // src/commands/DescribeSchemaCommand.ts
1907
-
1908
-
1909
-
1910
- var DescribeSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1911
- return [
1912
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1913
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1914
- ];
1915
- }).s("schemas", "DescribeSchema", {}).n("SchemasClient", "DescribeSchemaCommand").f(void 0, void 0).ser(se_DescribeSchemaCommand).de(de_DescribeSchemaCommand).build() {
1916
- static {
1917
- __name(this, "DescribeSchemaCommand");
1918
- }
427
+ const se_DescribeSchemaCommand = async (input, context) => {
428
+ const b = core.requestBuilder(input, context);
429
+ const headers = {};
430
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
431
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
432
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
433
+ const query = smithyClient.map({
434
+ [_sV]: [, input[_SV]],
435
+ });
436
+ let body;
437
+ b.m("GET").h(headers).q(query).b(body);
438
+ return b.build();
1919
439
  };
1920
-
1921
- // src/commands/ExportSchemaCommand.ts
1922
-
1923
-
1924
-
1925
- var ExportSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1926
- return [
1927
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1928
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1929
- ];
1930
- }).s("schemas", "ExportSchema", {}).n("SchemasClient", "ExportSchemaCommand").f(void 0, void 0).ser(se_ExportSchemaCommand).de(de_ExportSchemaCommand).build() {
1931
- static {
1932
- __name(this, "ExportSchemaCommand");
1933
- }
440
+ const se_ExportSchemaCommand = async (input, context) => {
441
+ const b = core.requestBuilder(input, context);
442
+ const headers = {};
443
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/export");
444
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
445
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
446
+ const query = smithyClient.map({
447
+ [_sV]: [, input[_SV]],
448
+ [_t]: [, smithyClient.expectNonNull(input[_T], `Type`)],
449
+ });
450
+ let body;
451
+ b.m("GET").h(headers).q(query).b(body);
452
+ return b.build();
1934
453
  };
1935
-
1936
- // src/commands/GetCodeBindingSourceCommand.ts
1937
-
1938
-
1939
-
1940
- var GetCodeBindingSourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1941
- return [
1942
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1943
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1944
- ];
1945
- }).s("schemas", "GetCodeBindingSource", {}).n("SchemasClient", "GetCodeBindingSourceCommand").f(void 0, void 0).ser(se_GetCodeBindingSourceCommand).de(de_GetCodeBindingSourceCommand).build() {
1946
- static {
1947
- __name(this, "GetCodeBindingSourceCommand");
1948
- }
454
+ const se_GetCodeBindingSourceCommand = async (input, context) => {
455
+ const b = core.requestBuilder(input, context);
456
+ const headers = {};
457
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}/source");
458
+ b.p("Language", () => input.Language, "{Language}", false);
459
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
460
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
461
+ const query = smithyClient.map({
462
+ [_sV]: [, input[_SV]],
463
+ });
464
+ let body;
465
+ b.m("GET").h(headers).q(query).b(body);
466
+ return b.build();
1949
467
  };
1950
-
1951
- // src/commands/GetDiscoveredSchemaCommand.ts
1952
-
1953
-
1954
-
1955
- var GetDiscoveredSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1956
- return [
1957
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1958
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1959
- ];
1960
- }).s("schemas", "GetDiscoveredSchema", {}).n("SchemasClient", "GetDiscoveredSchemaCommand").f(void 0, void 0).ser(se_GetDiscoveredSchemaCommand).de(de_GetDiscoveredSchemaCommand).build() {
1961
- static {
1962
- __name(this, "GetDiscoveredSchemaCommand");
1963
- }
468
+ const se_GetDiscoveredSchemaCommand = async (input, context) => {
469
+ const b = core.requestBuilder(input, context);
470
+ const headers = {
471
+ "content-type": "application/json",
472
+ };
473
+ b.bp("/v1/discover");
474
+ let body;
475
+ body = JSON.stringify(smithyClient.take(input, {
476
+ Events: (_) => smithyClient._json(_),
477
+ Type: [],
478
+ }));
479
+ b.m("POST").h(headers).b(body);
480
+ return b.build();
1964
481
  };
1965
-
1966
- // src/commands/GetResourcePolicyCommand.ts
1967
-
1968
-
1969
-
1970
- var GetResourcePolicyCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1971
- return [
1972
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1973
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1974
- ];
1975
- }).s("schemas", "GetResourcePolicy", {}).n("SchemasClient", "GetResourcePolicyCommand").f(void 0, void 0).ser(se_GetResourcePolicyCommand).de(de_GetResourcePolicyCommand).build() {
1976
- static {
1977
- __name(this, "GetResourcePolicyCommand");
1978
- }
482
+ const se_GetResourcePolicyCommand = async (input, context) => {
483
+ const b = core.requestBuilder(input, context);
484
+ const headers = {};
485
+ b.bp("/v1/policy");
486
+ const query = smithyClient.map({
487
+ [_rN]: [, input[_RN]],
488
+ });
489
+ let body;
490
+ b.m("GET").h(headers).q(query).b(body);
491
+ return b.build();
1979
492
  };
1980
-
1981
- // src/commands/ListDiscoverersCommand.ts
1982
-
1983
-
1984
-
1985
- var ListDiscoverersCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
1986
- return [
1987
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1988
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1989
- ];
1990
- }).s("schemas", "ListDiscoverers", {}).n("SchemasClient", "ListDiscoverersCommand").f(void 0, void 0).ser(se_ListDiscoverersCommand).de(de_ListDiscoverersCommand).build() {
1991
- static {
1992
- __name(this, "ListDiscoverersCommand");
1993
- }
493
+ const se_ListDiscoverersCommand = async (input, context) => {
494
+ const b = core.requestBuilder(input, context);
495
+ const headers = {};
496
+ b.bp("/v1/discoverers");
497
+ const query = smithyClient.map({
498
+ [_dIP]: [, input[_DIP]],
499
+ [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
500
+ [_nT]: [, input[_NT]],
501
+ [_sAP]: [, input[_SAP]],
502
+ });
503
+ let body;
504
+ b.m("GET").h(headers).q(query).b(body);
505
+ return b.build();
1994
506
  };
1995
-
1996
- // src/commands/ListRegistriesCommand.ts
1997
-
1998
-
1999
-
2000
- var ListRegistriesCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2001
- return [
2002
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2003
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2004
- ];
2005
- }).s("schemas", "ListRegistries", {}).n("SchemasClient", "ListRegistriesCommand").f(void 0, void 0).ser(se_ListRegistriesCommand).de(de_ListRegistriesCommand).build() {
2006
- static {
2007
- __name(this, "ListRegistriesCommand");
2008
- }
507
+ const se_ListRegistriesCommand = async (input, context) => {
508
+ const b = core.requestBuilder(input, context);
509
+ const headers = {};
510
+ b.bp("/v1/registries");
511
+ const query = smithyClient.map({
512
+ [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
513
+ [_nT]: [, input[_NT]],
514
+ [_rNP]: [, input[_RNP]],
515
+ [_s]: [, input[_S]],
516
+ });
517
+ let body;
518
+ b.m("GET").h(headers).q(query).b(body);
519
+ return b.build();
2009
520
  };
2010
-
2011
- // src/commands/ListSchemasCommand.ts
2012
-
2013
-
2014
-
2015
- var ListSchemasCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2016
- return [
2017
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2018
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2019
- ];
2020
- }).s("schemas", "ListSchemas", {}).n("SchemasClient", "ListSchemasCommand").f(void 0, void 0).ser(se_ListSchemasCommand).de(de_ListSchemasCommand).build() {
2021
- static {
2022
- __name(this, "ListSchemasCommand");
2023
- }
521
+ const se_ListSchemasCommand = async (input, context) => {
522
+ const b = core.requestBuilder(input, context);
523
+ const headers = {};
524
+ b.bp("/v1/registries/name/{RegistryName}/schemas");
525
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
526
+ const query = smithyClient.map({
527
+ [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
528
+ [_nT]: [, input[_NT]],
529
+ [_sNP]: [, input[_SNP]],
530
+ });
531
+ let body;
532
+ b.m("GET").h(headers).q(query).b(body);
533
+ return b.build();
2024
534
  };
2025
-
2026
- // src/commands/ListSchemaVersionsCommand.ts
2027
-
2028
-
2029
-
2030
- var ListSchemaVersionsCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2031
- return [
2032
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2033
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2034
- ];
2035
- }).s("schemas", "ListSchemaVersions", {}).n("SchemasClient", "ListSchemaVersionsCommand").f(void 0, void 0).ser(se_ListSchemaVersionsCommand).de(de_ListSchemaVersionsCommand).build() {
2036
- static {
2037
- __name(this, "ListSchemaVersionsCommand");
2038
- }
535
+ const se_ListSchemaVersionsCommand = async (input, context) => {
536
+ const b = core.requestBuilder(input, context);
537
+ const headers = {};
538
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/versions");
539
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
540
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
541
+ const query = smithyClient.map({
542
+ [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
543
+ [_nT]: [, input[_NT]],
544
+ });
545
+ let body;
546
+ b.m("GET").h(headers).q(query).b(body);
547
+ return b.build();
2039
548
  };
2040
-
2041
- // src/commands/ListTagsForResourceCommand.ts
2042
-
2043
-
2044
-
2045
- var ListTagsForResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2046
- return [
2047
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2048
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2049
- ];
2050
- }).s("schemas", "ListTagsForResource", {}).n("SchemasClient", "ListTagsForResourceCommand").f(void 0, void 0).ser(se_ListTagsForResourceCommand).de(de_ListTagsForResourceCommand).build() {
2051
- static {
2052
- __name(this, "ListTagsForResourceCommand");
2053
- }
549
+ const se_ListTagsForResourceCommand = async (input, context) => {
550
+ const b = core.requestBuilder(input, context);
551
+ const headers = {};
552
+ b.bp("/tags/{ResourceArn}");
553
+ b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
554
+ let body;
555
+ b.m("GET").h(headers).b(body);
556
+ return b.build();
2054
557
  };
2055
-
2056
- // src/commands/PutCodeBindingCommand.ts
2057
-
2058
-
2059
-
2060
- var PutCodeBindingCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2061
- return [
2062
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2063
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2064
- ];
2065
- }).s("schemas", "PutCodeBinding", {}).n("SchemasClient", "PutCodeBindingCommand").f(void 0, void 0).ser(se_PutCodeBindingCommand).de(de_PutCodeBindingCommand).build() {
2066
- static {
2067
- __name(this, "PutCodeBindingCommand");
2068
- }
558
+ const se_PutCodeBindingCommand = async (input, context) => {
559
+ const b = core.requestBuilder(input, context);
560
+ const headers = {};
561
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}/language/{Language}");
562
+ b.p("Language", () => input.Language, "{Language}", false);
563
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
564
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
565
+ const query = smithyClient.map({
566
+ [_sV]: [, input[_SV]],
567
+ });
568
+ let body;
569
+ b.m("POST").h(headers).q(query).b(body);
570
+ return b.build();
2069
571
  };
2070
-
2071
- // src/commands/PutResourcePolicyCommand.ts
2072
-
2073
-
2074
-
2075
- var PutResourcePolicyCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2076
- return [
2077
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2078
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2079
- ];
2080
- }).s("schemas", "PutResourcePolicy", {}).n("SchemasClient", "PutResourcePolicyCommand").f(void 0, void 0).ser(se_PutResourcePolicyCommand).de(de_PutResourcePolicyCommand).build() {
2081
- static {
2082
- __name(this, "PutResourcePolicyCommand");
2083
- }
572
+ const se_PutResourcePolicyCommand = async (input, context) => {
573
+ const b = core.requestBuilder(input, context);
574
+ const headers = {
575
+ "content-type": "application/json",
576
+ };
577
+ b.bp("/v1/policy");
578
+ const query = smithyClient.map({
579
+ [_rN]: [, input[_RN]],
580
+ });
581
+ let body;
582
+ body = JSON.stringify(smithyClient.take(input, {
583
+ Policy: (_) => smithyClient.LazyJsonString.from(_),
584
+ RevisionId: [],
585
+ }));
586
+ b.m("PUT").h(headers).q(query).b(body);
587
+ return b.build();
2084
588
  };
2085
-
2086
- // src/commands/SearchSchemasCommand.ts
2087
-
2088
-
2089
-
2090
- var SearchSchemasCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2091
- return [
2092
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2093
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2094
- ];
2095
- }).s("schemas", "SearchSchemas", {}).n("SchemasClient", "SearchSchemasCommand").f(void 0, void 0).ser(se_SearchSchemasCommand).de(de_SearchSchemasCommand).build() {
2096
- static {
2097
- __name(this, "SearchSchemasCommand");
2098
- }
589
+ const se_SearchSchemasCommand = async (input, context) => {
590
+ const b = core.requestBuilder(input, context);
591
+ const headers = {};
592
+ b.bp("/v1/registries/name/{RegistryName}/schemas/search");
593
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
594
+ const query = smithyClient.map({
595
+ [_k]: [, smithyClient.expectNonNull(input[_K], `Keywords`)],
596
+ [_l]: [() => input.Limit !== void 0, () => input[_L].toString()],
597
+ [_nT]: [, input[_NT]],
598
+ });
599
+ let body;
600
+ b.m("GET").h(headers).q(query).b(body);
601
+ return b.build();
2099
602
  };
2100
-
2101
- // src/commands/StartDiscovererCommand.ts
2102
-
2103
-
2104
-
2105
- var StartDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2106
- return [
2107
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2108
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2109
- ];
2110
- }).s("schemas", "StartDiscoverer", {}).n("SchemasClient", "StartDiscovererCommand").f(void 0, void 0).ser(se_StartDiscovererCommand).de(de_StartDiscovererCommand).build() {
2111
- static {
2112
- __name(this, "StartDiscovererCommand");
2113
- }
603
+ const se_StartDiscovererCommand = async (input, context) => {
604
+ const b = core.requestBuilder(input, context);
605
+ const headers = {};
606
+ b.bp("/v1/discoverers/id/{DiscovererId}/start");
607
+ b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
608
+ let body;
609
+ b.m("POST").h(headers).b(body);
610
+ return b.build();
2114
611
  };
2115
-
2116
- // src/commands/StopDiscovererCommand.ts
2117
-
2118
-
2119
-
2120
- var StopDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2121
- return [
2122
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2123
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2124
- ];
2125
- }).s("schemas", "StopDiscoverer", {}).n("SchemasClient", "StopDiscovererCommand").f(void 0, void 0).ser(se_StopDiscovererCommand).de(de_StopDiscovererCommand).build() {
2126
- static {
2127
- __name(this, "StopDiscovererCommand");
2128
- }
612
+ const se_StopDiscovererCommand = async (input, context) => {
613
+ const b = core.requestBuilder(input, context);
614
+ const headers = {};
615
+ b.bp("/v1/discoverers/id/{DiscovererId}/stop");
616
+ b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
617
+ let body;
618
+ b.m("POST").h(headers).b(body);
619
+ return b.build();
2129
620
  };
2130
-
2131
- // src/commands/TagResourceCommand.ts
2132
-
2133
-
2134
-
2135
- var TagResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2136
- return [
2137
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2138
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2139
- ];
2140
- }).s("schemas", "TagResource", {}).n("SchemasClient", "TagResourceCommand").f(void 0, void 0).ser(se_TagResourceCommand).de(de_TagResourceCommand).build() {
2141
- static {
2142
- __name(this, "TagResourceCommand");
2143
- }
621
+ const se_TagResourceCommand = async (input, context) => {
622
+ const b = core.requestBuilder(input, context);
623
+ const headers = {
624
+ "content-type": "application/json",
625
+ };
626
+ b.bp("/tags/{ResourceArn}");
627
+ b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
628
+ let body;
629
+ body = JSON.stringify(smithyClient.take(input, {
630
+ tags: [, (_) => smithyClient._json(_), `Tags`],
631
+ }));
632
+ b.m("POST").h(headers).b(body);
633
+ return b.build();
2144
634
  };
2145
-
2146
- // src/commands/UntagResourceCommand.ts
2147
-
2148
-
2149
-
2150
- var UntagResourceCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2151
- return [
2152
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2153
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2154
- ];
2155
- }).s("schemas", "UntagResource", {}).n("SchemasClient", "UntagResourceCommand").f(void 0, void 0).ser(se_UntagResourceCommand).de(de_UntagResourceCommand).build() {
2156
- static {
2157
- __name(this, "UntagResourceCommand");
2158
- }
635
+ const se_UntagResourceCommand = async (input, context) => {
636
+ const b = core.requestBuilder(input, context);
637
+ const headers = {};
638
+ b.bp("/tags/{ResourceArn}");
639
+ b.p("ResourceArn", () => input.ResourceArn, "{ResourceArn}", false);
640
+ const query = smithyClient.map({
641
+ [_tK]: [smithyClient.expectNonNull(input.TagKeys, `TagKeys`) != null, () => input[_TK] || []],
642
+ });
643
+ let body;
644
+ b.m("DELETE").h(headers).q(query).b(body);
645
+ return b.build();
2159
646
  };
2160
-
2161
- // src/commands/UpdateDiscovererCommand.ts
2162
-
2163
-
2164
-
2165
- var UpdateDiscovererCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2166
- return [
2167
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2168
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2169
- ];
2170
- }).s("schemas", "UpdateDiscoverer", {}).n("SchemasClient", "UpdateDiscovererCommand").f(void 0, void 0).ser(se_UpdateDiscovererCommand).de(de_UpdateDiscovererCommand).build() {
2171
- static {
2172
- __name(this, "UpdateDiscovererCommand");
2173
- }
647
+ const se_UpdateDiscovererCommand = async (input, context) => {
648
+ const b = core.requestBuilder(input, context);
649
+ const headers = {
650
+ "content-type": "application/json",
651
+ };
652
+ b.bp("/v1/discoverers/id/{DiscovererId}");
653
+ b.p("DiscovererId", () => input.DiscovererId, "{DiscovererId}", false);
654
+ let body;
655
+ body = JSON.stringify(smithyClient.take(input, {
656
+ CrossAccount: [],
657
+ Description: [],
658
+ }));
659
+ b.m("PUT").h(headers).b(body);
660
+ return b.build();
2174
661
  };
2175
-
2176
- // src/commands/UpdateRegistryCommand.ts
2177
-
2178
-
2179
-
2180
- var UpdateRegistryCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2181
- return [
2182
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2183
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2184
- ];
2185
- }).s("schemas", "UpdateRegistry", {}).n("SchemasClient", "UpdateRegistryCommand").f(void 0, void 0).ser(se_UpdateRegistryCommand).de(de_UpdateRegistryCommand).build() {
2186
- static {
2187
- __name(this, "UpdateRegistryCommand");
2188
- }
662
+ const se_UpdateRegistryCommand = async (input, context) => {
663
+ const b = core.requestBuilder(input, context);
664
+ const headers = {
665
+ "content-type": "application/json",
666
+ };
667
+ b.bp("/v1/registries/name/{RegistryName}");
668
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
669
+ let body;
670
+ body = JSON.stringify(smithyClient.take(input, {
671
+ Description: [],
672
+ }));
673
+ b.m("PUT").h(headers).b(body);
674
+ return b.build();
2189
675
  };
2190
-
2191
- // src/commands/UpdateSchemaCommand.ts
2192
-
2193
-
2194
-
2195
- var UpdateSchemaCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
2196
- return [
2197
- (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
2198
- (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
2199
- ];
2200
- }).s("schemas", "UpdateSchema", {}).n("SchemasClient", "UpdateSchemaCommand").f(void 0, void 0).ser(se_UpdateSchemaCommand).de(de_UpdateSchemaCommand).build() {
2201
- static {
2202
- __name(this, "UpdateSchemaCommand");
2203
- }
676
+ const se_UpdateSchemaCommand = async (input, context) => {
677
+ const b = core.requestBuilder(input, context);
678
+ const headers = {
679
+ "content-type": "application/json",
680
+ };
681
+ b.bp("/v1/registries/name/{RegistryName}/schemas/name/{SchemaName}");
682
+ b.p("RegistryName", () => input.RegistryName, "{RegistryName}", false);
683
+ b.p("SchemaName", () => input.SchemaName, "{SchemaName}", false);
684
+ let body;
685
+ body = JSON.stringify(smithyClient.take(input, {
686
+ ClientTokenId: [true, (_) => _ ?? uuid.v4()],
687
+ Content: [],
688
+ Description: [],
689
+ Type: [],
690
+ }));
691
+ b.m("PUT").h(headers).b(body);
692
+ return b.build();
2204
693
  };
694
+ const de_CreateDiscovererCommand = async (output, context) => {
695
+ if (output.statusCode !== 201 && output.statusCode >= 300) {
696
+ return de_CommandError(output, context);
697
+ }
698
+ const contents = smithyClient.map({
699
+ $metadata: deserializeMetadata(output),
700
+ });
701
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
702
+ const doc = smithyClient.take(data, {
703
+ CrossAccount: smithyClient.expectBoolean,
704
+ Description: smithyClient.expectString,
705
+ DiscovererArn: smithyClient.expectString,
706
+ DiscovererId: smithyClient.expectString,
707
+ SourceArn: smithyClient.expectString,
708
+ State: smithyClient.expectString,
709
+ Tags: [, smithyClient._json, `tags`],
710
+ });
711
+ Object.assign(contents, doc);
712
+ return contents;
713
+ };
714
+ const de_CreateRegistryCommand = async (output, context) => {
715
+ if (output.statusCode !== 201 && output.statusCode >= 300) {
716
+ return de_CommandError(output, context);
717
+ }
718
+ const contents = smithyClient.map({
719
+ $metadata: deserializeMetadata(output),
720
+ });
721
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
722
+ const doc = smithyClient.take(data, {
723
+ Description: smithyClient.expectString,
724
+ RegistryArn: smithyClient.expectString,
725
+ RegistryName: smithyClient.expectString,
726
+ Tags: [, smithyClient._json, `tags`],
727
+ });
728
+ Object.assign(contents, doc);
729
+ return contents;
730
+ };
731
+ const de_CreateSchemaCommand = async (output, context) => {
732
+ if (output.statusCode !== 201 && output.statusCode >= 300) {
733
+ return de_CommandError(output, context);
734
+ }
735
+ const contents = smithyClient.map({
736
+ $metadata: deserializeMetadata(output),
737
+ });
738
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
739
+ const doc = smithyClient.take(data, {
740
+ Description: smithyClient.expectString,
741
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
742
+ SchemaArn: smithyClient.expectString,
743
+ SchemaName: smithyClient.expectString,
744
+ SchemaVersion: smithyClient.expectString,
745
+ Tags: [, smithyClient._json, `tags`],
746
+ Type: smithyClient.expectString,
747
+ VersionCreatedDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
748
+ });
749
+ Object.assign(contents, doc);
750
+ return contents;
751
+ };
752
+ const de_DeleteDiscovererCommand = async (output, context) => {
753
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
754
+ return de_CommandError(output, context);
755
+ }
756
+ const contents = smithyClient.map({
757
+ $metadata: deserializeMetadata(output),
758
+ });
759
+ await smithyClient.collectBody(output.body, context);
760
+ return contents;
761
+ };
762
+ const de_DeleteRegistryCommand = async (output, context) => {
763
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
764
+ return de_CommandError(output, context);
765
+ }
766
+ const contents = smithyClient.map({
767
+ $metadata: deserializeMetadata(output),
768
+ });
769
+ await smithyClient.collectBody(output.body, context);
770
+ return contents;
771
+ };
772
+ const de_DeleteResourcePolicyCommand = async (output, context) => {
773
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
774
+ return de_CommandError(output, context);
775
+ }
776
+ const contents = smithyClient.map({
777
+ $metadata: deserializeMetadata(output),
778
+ });
779
+ await smithyClient.collectBody(output.body, context);
780
+ return contents;
781
+ };
782
+ const de_DeleteSchemaCommand = async (output, context) => {
783
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
784
+ return de_CommandError(output, context);
785
+ }
786
+ const contents = smithyClient.map({
787
+ $metadata: deserializeMetadata(output),
788
+ });
789
+ await smithyClient.collectBody(output.body, context);
790
+ return contents;
791
+ };
792
+ const de_DeleteSchemaVersionCommand = async (output, context) => {
793
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
794
+ return de_CommandError(output, context);
795
+ }
796
+ const contents = smithyClient.map({
797
+ $metadata: deserializeMetadata(output),
798
+ });
799
+ await smithyClient.collectBody(output.body, context);
800
+ return contents;
801
+ };
802
+ const de_DescribeCodeBindingCommand = async (output, context) => {
803
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
804
+ return de_CommandError(output, context);
805
+ }
806
+ const contents = smithyClient.map({
807
+ $metadata: deserializeMetadata(output),
808
+ });
809
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
810
+ const doc = smithyClient.take(data, {
811
+ CreationDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
812
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
813
+ SchemaVersion: smithyClient.expectString,
814
+ Status: smithyClient.expectString,
815
+ });
816
+ Object.assign(contents, doc);
817
+ return contents;
818
+ };
819
+ const de_DescribeDiscovererCommand = async (output, context) => {
820
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
821
+ return de_CommandError(output, context);
822
+ }
823
+ const contents = smithyClient.map({
824
+ $metadata: deserializeMetadata(output),
825
+ });
826
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
827
+ const doc = smithyClient.take(data, {
828
+ CrossAccount: smithyClient.expectBoolean,
829
+ Description: smithyClient.expectString,
830
+ DiscovererArn: smithyClient.expectString,
831
+ DiscovererId: smithyClient.expectString,
832
+ SourceArn: smithyClient.expectString,
833
+ State: smithyClient.expectString,
834
+ Tags: [, smithyClient._json, `tags`],
835
+ });
836
+ Object.assign(contents, doc);
837
+ return contents;
838
+ };
839
+ const de_DescribeRegistryCommand = async (output, context) => {
840
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
841
+ return de_CommandError(output, context);
842
+ }
843
+ const contents = smithyClient.map({
844
+ $metadata: deserializeMetadata(output),
845
+ });
846
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
847
+ const doc = smithyClient.take(data, {
848
+ Description: smithyClient.expectString,
849
+ RegistryArn: smithyClient.expectString,
850
+ RegistryName: smithyClient.expectString,
851
+ Tags: [, smithyClient._json, `tags`],
852
+ });
853
+ Object.assign(contents, doc);
854
+ return contents;
855
+ };
856
+ const de_DescribeSchemaCommand = async (output, context) => {
857
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
858
+ return de_CommandError(output, context);
859
+ }
860
+ const contents = smithyClient.map({
861
+ $metadata: deserializeMetadata(output),
862
+ });
863
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
864
+ const doc = smithyClient.take(data, {
865
+ Content: smithyClient.expectString,
866
+ Description: smithyClient.expectString,
867
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
868
+ SchemaArn: smithyClient.expectString,
869
+ SchemaName: smithyClient.expectString,
870
+ SchemaVersion: smithyClient.expectString,
871
+ Tags: [, smithyClient._json, `tags`],
872
+ Type: smithyClient.expectString,
873
+ VersionCreatedDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
874
+ });
875
+ Object.assign(contents, doc);
876
+ return contents;
877
+ };
878
+ const de_ExportSchemaCommand = async (output, context) => {
879
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
880
+ return de_CommandError(output, context);
881
+ }
882
+ const contents = smithyClient.map({
883
+ $metadata: deserializeMetadata(output),
884
+ });
885
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
886
+ const doc = smithyClient.take(data, {
887
+ Content: smithyClient.expectString,
888
+ SchemaArn: smithyClient.expectString,
889
+ SchemaName: smithyClient.expectString,
890
+ SchemaVersion: smithyClient.expectString,
891
+ Type: smithyClient.expectString,
892
+ });
893
+ Object.assign(contents, doc);
894
+ return contents;
895
+ };
896
+ const de_GetCodeBindingSourceCommand = async (output, context) => {
897
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
898
+ return de_CommandError(output, context);
899
+ }
900
+ const contents = smithyClient.map({
901
+ $metadata: deserializeMetadata(output),
902
+ });
903
+ const data = await smithyClient.collectBody(output.body, context);
904
+ contents.Body = data;
905
+ return contents;
906
+ };
907
+ const de_GetDiscoveredSchemaCommand = async (output, context) => {
908
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
909
+ return de_CommandError(output, context);
910
+ }
911
+ const contents = smithyClient.map({
912
+ $metadata: deserializeMetadata(output),
913
+ });
914
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
915
+ const doc = smithyClient.take(data, {
916
+ Content: smithyClient.expectString,
917
+ });
918
+ Object.assign(contents, doc);
919
+ return contents;
920
+ };
921
+ const de_GetResourcePolicyCommand = async (output, context) => {
922
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
923
+ return de_CommandError(output, context);
924
+ }
925
+ const contents = smithyClient.map({
926
+ $metadata: deserializeMetadata(output),
927
+ });
928
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
929
+ const doc = smithyClient.take(data, {
930
+ Policy: smithyClient.LazyJsonString.from,
931
+ RevisionId: smithyClient.expectString,
932
+ });
933
+ Object.assign(contents, doc);
934
+ return contents;
935
+ };
936
+ const de_ListDiscoverersCommand = async (output, context) => {
937
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
938
+ return de_CommandError(output, context);
939
+ }
940
+ const contents = smithyClient.map({
941
+ $metadata: deserializeMetadata(output),
942
+ });
943
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
944
+ const doc = smithyClient.take(data, {
945
+ Discoverers: (_) => de___listOfDiscovererSummary(_),
946
+ NextToken: smithyClient.expectString,
947
+ });
948
+ Object.assign(contents, doc);
949
+ return contents;
950
+ };
951
+ const de_ListRegistriesCommand = async (output, context) => {
952
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
953
+ return de_CommandError(output, context);
954
+ }
955
+ const contents = smithyClient.map({
956
+ $metadata: deserializeMetadata(output),
957
+ });
958
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
959
+ const doc = smithyClient.take(data, {
960
+ NextToken: smithyClient.expectString,
961
+ Registries: (_) => de___listOfRegistrySummary(_),
962
+ });
963
+ Object.assign(contents, doc);
964
+ return contents;
965
+ };
966
+ const de_ListSchemasCommand = async (output, context) => {
967
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
968
+ return de_CommandError(output, context);
969
+ }
970
+ const contents = smithyClient.map({
971
+ $metadata: deserializeMetadata(output),
972
+ });
973
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
974
+ const doc = smithyClient.take(data, {
975
+ NextToken: smithyClient.expectString,
976
+ Schemas: (_) => de___listOfSchemaSummary(_),
977
+ });
978
+ Object.assign(contents, doc);
979
+ return contents;
980
+ };
981
+ const de_ListSchemaVersionsCommand = async (output, context) => {
982
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
983
+ return de_CommandError(output, context);
984
+ }
985
+ const contents = smithyClient.map({
986
+ $metadata: deserializeMetadata(output),
987
+ });
988
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
989
+ const doc = smithyClient.take(data, {
990
+ NextToken: smithyClient.expectString,
991
+ SchemaVersions: smithyClient._json,
992
+ });
993
+ Object.assign(contents, doc);
994
+ return contents;
995
+ };
996
+ const de_ListTagsForResourceCommand = async (output, context) => {
997
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
998
+ return de_CommandError(output, context);
999
+ }
1000
+ const contents = smithyClient.map({
1001
+ $metadata: deserializeMetadata(output),
1002
+ });
1003
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1004
+ const doc = smithyClient.take(data, {
1005
+ Tags: [, smithyClient._json, `tags`],
1006
+ });
1007
+ Object.assign(contents, doc);
1008
+ return contents;
1009
+ };
1010
+ const de_PutCodeBindingCommand = async (output, context) => {
1011
+ if (output.statusCode !== 202 && output.statusCode >= 300) {
1012
+ return de_CommandError(output, context);
1013
+ }
1014
+ const contents = smithyClient.map({
1015
+ $metadata: deserializeMetadata(output),
1016
+ });
1017
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1018
+ const doc = smithyClient.take(data, {
1019
+ CreationDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1020
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1021
+ SchemaVersion: smithyClient.expectString,
1022
+ Status: smithyClient.expectString,
1023
+ });
1024
+ Object.assign(contents, doc);
1025
+ return contents;
1026
+ };
1027
+ const de_PutResourcePolicyCommand = async (output, context) => {
1028
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1029
+ return de_CommandError(output, context);
1030
+ }
1031
+ const contents = smithyClient.map({
1032
+ $metadata: deserializeMetadata(output),
1033
+ });
1034
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1035
+ const doc = smithyClient.take(data, {
1036
+ Policy: smithyClient.LazyJsonString.from,
1037
+ RevisionId: smithyClient.expectString,
1038
+ });
1039
+ Object.assign(contents, doc);
1040
+ return contents;
1041
+ };
1042
+ const de_SearchSchemasCommand = async (output, context) => {
1043
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1044
+ return de_CommandError(output, context);
1045
+ }
1046
+ const contents = smithyClient.map({
1047
+ $metadata: deserializeMetadata(output),
1048
+ });
1049
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1050
+ const doc = smithyClient.take(data, {
1051
+ NextToken: smithyClient.expectString,
1052
+ Schemas: (_) => de___listOfSearchSchemaSummary(_),
1053
+ });
1054
+ Object.assign(contents, doc);
1055
+ return contents;
1056
+ };
1057
+ const de_StartDiscovererCommand = async (output, context) => {
1058
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1059
+ return de_CommandError(output, context);
1060
+ }
1061
+ const contents = smithyClient.map({
1062
+ $metadata: deserializeMetadata(output),
1063
+ });
1064
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1065
+ const doc = smithyClient.take(data, {
1066
+ DiscovererId: smithyClient.expectString,
1067
+ State: smithyClient.expectString,
1068
+ });
1069
+ Object.assign(contents, doc);
1070
+ return contents;
1071
+ };
1072
+ const de_StopDiscovererCommand = async (output, context) => {
1073
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1074
+ return de_CommandError(output, context);
1075
+ }
1076
+ const contents = smithyClient.map({
1077
+ $metadata: deserializeMetadata(output),
1078
+ });
1079
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1080
+ const doc = smithyClient.take(data, {
1081
+ DiscovererId: smithyClient.expectString,
1082
+ State: smithyClient.expectString,
1083
+ });
1084
+ Object.assign(contents, doc);
1085
+ return contents;
1086
+ };
1087
+ const de_TagResourceCommand = async (output, context) => {
1088
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
1089
+ return de_CommandError(output, context);
1090
+ }
1091
+ const contents = smithyClient.map({
1092
+ $metadata: deserializeMetadata(output),
1093
+ });
1094
+ await smithyClient.collectBody(output.body, context);
1095
+ return contents;
1096
+ };
1097
+ const de_UntagResourceCommand = async (output, context) => {
1098
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
1099
+ return de_CommandError(output, context);
1100
+ }
1101
+ const contents = smithyClient.map({
1102
+ $metadata: deserializeMetadata(output),
1103
+ });
1104
+ await smithyClient.collectBody(output.body, context);
1105
+ return contents;
1106
+ };
1107
+ const de_UpdateDiscovererCommand = async (output, context) => {
1108
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1109
+ return de_CommandError(output, context);
1110
+ }
1111
+ const contents = smithyClient.map({
1112
+ $metadata: deserializeMetadata(output),
1113
+ });
1114
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1115
+ const doc = smithyClient.take(data, {
1116
+ CrossAccount: smithyClient.expectBoolean,
1117
+ Description: smithyClient.expectString,
1118
+ DiscovererArn: smithyClient.expectString,
1119
+ DiscovererId: smithyClient.expectString,
1120
+ SourceArn: smithyClient.expectString,
1121
+ State: smithyClient.expectString,
1122
+ Tags: [, smithyClient._json, `tags`],
1123
+ });
1124
+ Object.assign(contents, doc);
1125
+ return contents;
1126
+ };
1127
+ const de_UpdateRegistryCommand = async (output, context) => {
1128
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1129
+ return de_CommandError(output, context);
1130
+ }
1131
+ const contents = smithyClient.map({
1132
+ $metadata: deserializeMetadata(output),
1133
+ });
1134
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1135
+ const doc = smithyClient.take(data, {
1136
+ Description: smithyClient.expectString,
1137
+ RegistryArn: smithyClient.expectString,
1138
+ RegistryName: smithyClient.expectString,
1139
+ Tags: [, smithyClient._json, `tags`],
1140
+ });
1141
+ Object.assign(contents, doc);
1142
+ return contents;
1143
+ };
1144
+ const de_UpdateSchemaCommand = async (output, context) => {
1145
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1146
+ return de_CommandError(output, context);
1147
+ }
1148
+ const contents = smithyClient.map({
1149
+ $metadata: deserializeMetadata(output),
1150
+ });
1151
+ const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
1152
+ const doc = smithyClient.take(data, {
1153
+ Description: smithyClient.expectString,
1154
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1155
+ SchemaArn: smithyClient.expectString,
1156
+ SchemaName: smithyClient.expectString,
1157
+ SchemaVersion: smithyClient.expectString,
1158
+ Tags: [, smithyClient._json, `tags`],
1159
+ Type: smithyClient.expectString,
1160
+ VersionCreatedDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1161
+ });
1162
+ Object.assign(contents, doc);
1163
+ return contents;
1164
+ };
1165
+ const de_CommandError = async (output, context) => {
1166
+ const parsedOutput = {
1167
+ ...output,
1168
+ body: await core$1.parseJsonErrorBody(output.body, context),
1169
+ };
1170
+ const errorCode = core$1.loadRestJsonErrorCode(output, parsedOutput.body);
1171
+ switch (errorCode) {
1172
+ case "BadRequestException":
1173
+ case "com.amazonaws.schemas#BadRequestException":
1174
+ throw await de_BadRequestExceptionRes(parsedOutput);
1175
+ case "ConflictException":
1176
+ case "com.amazonaws.schemas#ConflictException":
1177
+ throw await de_ConflictExceptionRes(parsedOutput);
1178
+ case "ForbiddenException":
1179
+ case "com.amazonaws.schemas#ForbiddenException":
1180
+ throw await de_ForbiddenExceptionRes(parsedOutput);
1181
+ case "InternalServerErrorException":
1182
+ case "com.amazonaws.schemas#InternalServerErrorException":
1183
+ throw await de_InternalServerErrorExceptionRes(parsedOutput);
1184
+ case "ServiceUnavailableException":
1185
+ case "com.amazonaws.schemas#ServiceUnavailableException":
1186
+ throw await de_ServiceUnavailableExceptionRes(parsedOutput);
1187
+ case "UnauthorizedException":
1188
+ case "com.amazonaws.schemas#UnauthorizedException":
1189
+ throw await de_UnauthorizedExceptionRes(parsedOutput);
1190
+ case "NotFoundException":
1191
+ case "com.amazonaws.schemas#NotFoundException":
1192
+ throw await de_NotFoundExceptionRes(parsedOutput);
1193
+ case "TooManyRequestsException":
1194
+ case "com.amazonaws.schemas#TooManyRequestsException":
1195
+ throw await de_TooManyRequestsExceptionRes(parsedOutput);
1196
+ case "GoneException":
1197
+ case "com.amazonaws.schemas#GoneException":
1198
+ throw await de_GoneExceptionRes(parsedOutput);
1199
+ case "PreconditionFailedException":
1200
+ case "com.amazonaws.schemas#PreconditionFailedException":
1201
+ throw await de_PreconditionFailedExceptionRes(parsedOutput);
1202
+ default:
1203
+ const parsedBody = parsedOutput.body;
1204
+ return throwDefaultError({
1205
+ output,
1206
+ parsedBody,
1207
+ errorCode,
1208
+ });
1209
+ }
1210
+ };
1211
+ const throwDefaultError = smithyClient.withBaseException(SchemasServiceException);
1212
+ const de_BadRequestExceptionRes = async (parsedOutput, context) => {
1213
+ const contents = smithyClient.map({});
1214
+ const data = parsedOutput.body;
1215
+ const doc = smithyClient.take(data, {
1216
+ Code: smithyClient.expectString,
1217
+ Message: smithyClient.expectString,
1218
+ });
1219
+ Object.assign(contents, doc);
1220
+ const exception = new BadRequestException({
1221
+ $metadata: deserializeMetadata(parsedOutput),
1222
+ ...contents,
1223
+ });
1224
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1225
+ };
1226
+ const de_ConflictExceptionRes = async (parsedOutput, context) => {
1227
+ const contents = smithyClient.map({});
1228
+ const data = parsedOutput.body;
1229
+ const doc = smithyClient.take(data, {
1230
+ Code: smithyClient.expectString,
1231
+ Message: smithyClient.expectString,
1232
+ });
1233
+ Object.assign(contents, doc);
1234
+ const exception = new ConflictException({
1235
+ $metadata: deserializeMetadata(parsedOutput),
1236
+ ...contents,
1237
+ });
1238
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1239
+ };
1240
+ const de_ForbiddenExceptionRes = async (parsedOutput, context) => {
1241
+ const contents = smithyClient.map({});
1242
+ const data = parsedOutput.body;
1243
+ const doc = smithyClient.take(data, {
1244
+ Code: smithyClient.expectString,
1245
+ Message: smithyClient.expectString,
1246
+ });
1247
+ Object.assign(contents, doc);
1248
+ const exception = new ForbiddenException({
1249
+ $metadata: deserializeMetadata(parsedOutput),
1250
+ ...contents,
1251
+ });
1252
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1253
+ };
1254
+ const de_GoneExceptionRes = async (parsedOutput, context) => {
1255
+ const contents = smithyClient.map({});
1256
+ const data = parsedOutput.body;
1257
+ const doc = smithyClient.take(data, {
1258
+ Code: smithyClient.expectString,
1259
+ Message: smithyClient.expectString,
1260
+ });
1261
+ Object.assign(contents, doc);
1262
+ const exception = new GoneException({
1263
+ $metadata: deserializeMetadata(parsedOutput),
1264
+ ...contents,
1265
+ });
1266
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1267
+ };
1268
+ const de_InternalServerErrorExceptionRes = async (parsedOutput, context) => {
1269
+ const contents = smithyClient.map({});
1270
+ const data = parsedOutput.body;
1271
+ const doc = smithyClient.take(data, {
1272
+ Code: smithyClient.expectString,
1273
+ Message: smithyClient.expectString,
1274
+ });
1275
+ Object.assign(contents, doc);
1276
+ const exception = new InternalServerErrorException({
1277
+ $metadata: deserializeMetadata(parsedOutput),
1278
+ ...contents,
1279
+ });
1280
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1281
+ };
1282
+ const de_NotFoundExceptionRes = async (parsedOutput, context) => {
1283
+ const contents = smithyClient.map({});
1284
+ const data = parsedOutput.body;
1285
+ const doc = smithyClient.take(data, {
1286
+ Code: smithyClient.expectString,
1287
+ Message: smithyClient.expectString,
1288
+ });
1289
+ Object.assign(contents, doc);
1290
+ const exception = new NotFoundException({
1291
+ $metadata: deserializeMetadata(parsedOutput),
1292
+ ...contents,
1293
+ });
1294
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1295
+ };
1296
+ const de_PreconditionFailedExceptionRes = async (parsedOutput, context) => {
1297
+ const contents = smithyClient.map({});
1298
+ const data = parsedOutput.body;
1299
+ const doc = smithyClient.take(data, {
1300
+ Code: smithyClient.expectString,
1301
+ Message: smithyClient.expectString,
1302
+ });
1303
+ Object.assign(contents, doc);
1304
+ const exception = new PreconditionFailedException({
1305
+ $metadata: deserializeMetadata(parsedOutput),
1306
+ ...contents,
1307
+ });
1308
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1309
+ };
1310
+ const de_ServiceUnavailableExceptionRes = async (parsedOutput, context) => {
1311
+ const contents = smithyClient.map({});
1312
+ const data = parsedOutput.body;
1313
+ const doc = smithyClient.take(data, {
1314
+ Code: smithyClient.expectString,
1315
+ Message: smithyClient.expectString,
1316
+ });
1317
+ Object.assign(contents, doc);
1318
+ const exception = new ServiceUnavailableException({
1319
+ $metadata: deserializeMetadata(parsedOutput),
1320
+ ...contents,
1321
+ });
1322
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1323
+ };
1324
+ const de_TooManyRequestsExceptionRes = async (parsedOutput, context) => {
1325
+ const contents = smithyClient.map({});
1326
+ const data = parsedOutput.body;
1327
+ const doc = smithyClient.take(data, {
1328
+ Code: smithyClient.expectString,
1329
+ Message: smithyClient.expectString,
1330
+ });
1331
+ Object.assign(contents, doc);
1332
+ const exception = new TooManyRequestsException({
1333
+ $metadata: deserializeMetadata(parsedOutput),
1334
+ ...contents,
1335
+ });
1336
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1337
+ };
1338
+ const de_UnauthorizedExceptionRes = async (parsedOutput, context) => {
1339
+ const contents = smithyClient.map({});
1340
+ const data = parsedOutput.body;
1341
+ const doc = smithyClient.take(data, {
1342
+ Code: smithyClient.expectString,
1343
+ Message: smithyClient.expectString,
1344
+ });
1345
+ Object.assign(contents, doc);
1346
+ const exception = new UnauthorizedException({
1347
+ $metadata: deserializeMetadata(parsedOutput),
1348
+ ...contents,
1349
+ });
1350
+ return smithyClient.decorateServiceException(exception, parsedOutput.body);
1351
+ };
1352
+ const de___listOfDiscovererSummary = (output, context) => {
1353
+ const retVal = (output || [])
1354
+ .filter((e) => e != null)
1355
+ .map((entry) => {
1356
+ return de_DiscovererSummary(entry);
1357
+ });
1358
+ return retVal;
1359
+ };
1360
+ const de___listOfRegistrySummary = (output, context) => {
1361
+ const retVal = (output || [])
1362
+ .filter((e) => e != null)
1363
+ .map((entry) => {
1364
+ return de_RegistrySummary(entry);
1365
+ });
1366
+ return retVal;
1367
+ };
1368
+ const de___listOfSchemaSummary = (output, context) => {
1369
+ const retVal = (output || [])
1370
+ .filter((e) => e != null)
1371
+ .map((entry) => {
1372
+ return de_SchemaSummary(entry);
1373
+ });
1374
+ return retVal;
1375
+ };
1376
+ const de___listOfSearchSchemaSummary = (output, context) => {
1377
+ const retVal = (output || [])
1378
+ .filter((e) => e != null)
1379
+ .map((entry) => {
1380
+ return de_SearchSchemaSummary(entry);
1381
+ });
1382
+ return retVal;
1383
+ };
1384
+ const de___listOfSearchSchemaVersionSummary = (output, context) => {
1385
+ const retVal = (output || [])
1386
+ .filter((e) => e != null)
1387
+ .map((entry) => {
1388
+ return de_SearchSchemaVersionSummary(entry);
1389
+ });
1390
+ return retVal;
1391
+ };
1392
+ const de_DiscovererSummary = (output, context) => {
1393
+ return smithyClient.take(output, {
1394
+ CrossAccount: smithyClient.expectBoolean,
1395
+ DiscovererArn: smithyClient.expectString,
1396
+ DiscovererId: smithyClient.expectString,
1397
+ SourceArn: smithyClient.expectString,
1398
+ State: smithyClient.expectString,
1399
+ Tags: [, smithyClient._json, `tags`],
1400
+ });
1401
+ };
1402
+ const de_RegistrySummary = (output, context) => {
1403
+ return smithyClient.take(output, {
1404
+ RegistryArn: smithyClient.expectString,
1405
+ RegistryName: smithyClient.expectString,
1406
+ Tags: [, smithyClient._json, `tags`],
1407
+ });
1408
+ };
1409
+ const de_SchemaSummary = (output, context) => {
1410
+ return smithyClient.take(output, {
1411
+ LastModified: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1412
+ SchemaArn: smithyClient.expectString,
1413
+ SchemaName: smithyClient.expectString,
1414
+ Tags: [, smithyClient._json, `tags`],
1415
+ VersionCount: smithyClient.expectLong,
1416
+ });
1417
+ };
1418
+ const de_SearchSchemaSummary = (output, context) => {
1419
+ return smithyClient.take(output, {
1420
+ RegistryName: smithyClient.expectString,
1421
+ SchemaArn: smithyClient.expectString,
1422
+ SchemaName: smithyClient.expectString,
1423
+ SchemaVersions: (_) => de___listOfSearchSchemaVersionSummary(_),
1424
+ });
1425
+ };
1426
+ const de_SearchSchemaVersionSummary = (output, context) => {
1427
+ return smithyClient.take(output, {
1428
+ CreatedDate: (_) => smithyClient.expectNonNull(smithyClient.parseRfc3339DateTimeWithOffset(_)),
1429
+ SchemaVersion: smithyClient.expectString,
1430
+ Type: smithyClient.expectString,
1431
+ });
1432
+ };
1433
+ const deserializeMetadata = (output) => ({
1434
+ httpStatusCode: output.statusCode,
1435
+ requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
1436
+ extendedRequestId: output.headers["x-amz-id-2"],
1437
+ cfId: output.headers["x-amz-cf-id"],
1438
+ });
1439
+ const _DIP = "DiscovererIdPrefix";
1440
+ const _K = "Keywords";
1441
+ const _L = "Limit";
1442
+ const _NT = "NextToken";
1443
+ const _RN = "RegistryName";
1444
+ const _RNP = "RegistryNamePrefix";
1445
+ const _S = "Scope";
1446
+ const _SAP = "SourceArnPrefix";
1447
+ const _SNP = "SchemaNamePrefix";
1448
+ const _SV = "SchemaVersion";
1449
+ const _T = "Type";
1450
+ const _TK = "TagKeys";
1451
+ const _dIP = "discovererIdPrefix";
1452
+ const _k = "keywords";
1453
+ const _l = "limit";
1454
+ const _nT = "nextToken";
1455
+ const _rN = "registryName";
1456
+ const _rNP = "registryNamePrefix";
1457
+ const _s = "scope";
1458
+ const _sAP = "sourceArnPrefix";
1459
+ const _sNP = "schemaNamePrefix";
1460
+ const _sV = "schemaVersion";
1461
+ const _t = "type";
1462
+ const _tK = "tagKeys";
1463
+
1464
+ class CreateDiscovererCommand extends smithyClient.Command
1465
+ .classBuilder()
1466
+ .ep(commonParams)
1467
+ .m(function (Command, cs, config, o) {
1468
+ return [
1469
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1470
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1471
+ ];
1472
+ })
1473
+ .s("schemas", "CreateDiscoverer", {})
1474
+ .n("SchemasClient", "CreateDiscovererCommand")
1475
+ .f(void 0, void 0)
1476
+ .ser(se_CreateDiscovererCommand)
1477
+ .de(de_CreateDiscovererCommand)
1478
+ .build() {
1479
+ }
1480
+
1481
+ class CreateRegistryCommand extends smithyClient.Command
1482
+ .classBuilder()
1483
+ .ep(commonParams)
1484
+ .m(function (Command, cs, config, o) {
1485
+ return [
1486
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1487
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1488
+ ];
1489
+ })
1490
+ .s("schemas", "CreateRegistry", {})
1491
+ .n("SchemasClient", "CreateRegistryCommand")
1492
+ .f(void 0, void 0)
1493
+ .ser(se_CreateRegistryCommand)
1494
+ .de(de_CreateRegistryCommand)
1495
+ .build() {
1496
+ }
1497
+
1498
+ class CreateSchemaCommand extends smithyClient.Command
1499
+ .classBuilder()
1500
+ .ep(commonParams)
1501
+ .m(function (Command, cs, config, o) {
1502
+ return [
1503
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1504
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1505
+ ];
1506
+ })
1507
+ .s("schemas", "CreateSchema", {})
1508
+ .n("SchemasClient", "CreateSchemaCommand")
1509
+ .f(void 0, void 0)
1510
+ .ser(se_CreateSchemaCommand)
1511
+ .de(de_CreateSchemaCommand)
1512
+ .build() {
1513
+ }
1514
+
1515
+ class DeleteDiscovererCommand extends smithyClient.Command
1516
+ .classBuilder()
1517
+ .ep(commonParams)
1518
+ .m(function (Command, cs, config, o) {
1519
+ return [
1520
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1521
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1522
+ ];
1523
+ })
1524
+ .s("schemas", "DeleteDiscoverer", {})
1525
+ .n("SchemasClient", "DeleteDiscovererCommand")
1526
+ .f(void 0, void 0)
1527
+ .ser(se_DeleteDiscovererCommand)
1528
+ .de(de_DeleteDiscovererCommand)
1529
+ .build() {
1530
+ }
1531
+
1532
+ class DeleteRegistryCommand extends smithyClient.Command
1533
+ .classBuilder()
1534
+ .ep(commonParams)
1535
+ .m(function (Command, cs, config, o) {
1536
+ return [
1537
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1538
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1539
+ ];
1540
+ })
1541
+ .s("schemas", "DeleteRegistry", {})
1542
+ .n("SchemasClient", "DeleteRegistryCommand")
1543
+ .f(void 0, void 0)
1544
+ .ser(se_DeleteRegistryCommand)
1545
+ .de(de_DeleteRegistryCommand)
1546
+ .build() {
1547
+ }
1548
+
1549
+ class DeleteResourcePolicyCommand extends smithyClient.Command
1550
+ .classBuilder()
1551
+ .ep(commonParams)
1552
+ .m(function (Command, cs, config, o) {
1553
+ return [
1554
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1555
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1556
+ ];
1557
+ })
1558
+ .s("schemas", "DeleteResourcePolicy", {})
1559
+ .n("SchemasClient", "DeleteResourcePolicyCommand")
1560
+ .f(void 0, void 0)
1561
+ .ser(se_DeleteResourcePolicyCommand)
1562
+ .de(de_DeleteResourcePolicyCommand)
1563
+ .build() {
1564
+ }
1565
+
1566
+ class DeleteSchemaCommand extends smithyClient.Command
1567
+ .classBuilder()
1568
+ .ep(commonParams)
1569
+ .m(function (Command, cs, config, o) {
1570
+ return [
1571
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1572
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1573
+ ];
1574
+ })
1575
+ .s("schemas", "DeleteSchema", {})
1576
+ .n("SchemasClient", "DeleteSchemaCommand")
1577
+ .f(void 0, void 0)
1578
+ .ser(se_DeleteSchemaCommand)
1579
+ .de(de_DeleteSchemaCommand)
1580
+ .build() {
1581
+ }
1582
+
1583
+ class DeleteSchemaVersionCommand extends smithyClient.Command
1584
+ .classBuilder()
1585
+ .ep(commonParams)
1586
+ .m(function (Command, cs, config, o) {
1587
+ return [
1588
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1589
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1590
+ ];
1591
+ })
1592
+ .s("schemas", "DeleteSchemaVersion", {})
1593
+ .n("SchemasClient", "DeleteSchemaVersionCommand")
1594
+ .f(void 0, void 0)
1595
+ .ser(se_DeleteSchemaVersionCommand)
1596
+ .de(de_DeleteSchemaVersionCommand)
1597
+ .build() {
1598
+ }
1599
+
1600
+ class DescribeCodeBindingCommand extends smithyClient.Command
1601
+ .classBuilder()
1602
+ .ep(commonParams)
1603
+ .m(function (Command, cs, config, o) {
1604
+ return [
1605
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1606
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1607
+ ];
1608
+ })
1609
+ .s("schemas", "DescribeCodeBinding", {})
1610
+ .n("SchemasClient", "DescribeCodeBindingCommand")
1611
+ .f(void 0, void 0)
1612
+ .ser(se_DescribeCodeBindingCommand)
1613
+ .de(de_DescribeCodeBindingCommand)
1614
+ .build() {
1615
+ }
1616
+
1617
+ class DescribeDiscovererCommand extends smithyClient.Command
1618
+ .classBuilder()
1619
+ .ep(commonParams)
1620
+ .m(function (Command, cs, config, o) {
1621
+ return [
1622
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1623
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1624
+ ];
1625
+ })
1626
+ .s("schemas", "DescribeDiscoverer", {})
1627
+ .n("SchemasClient", "DescribeDiscovererCommand")
1628
+ .f(void 0, void 0)
1629
+ .ser(se_DescribeDiscovererCommand)
1630
+ .de(de_DescribeDiscovererCommand)
1631
+ .build() {
1632
+ }
1633
+
1634
+ class DescribeRegistryCommand extends smithyClient.Command
1635
+ .classBuilder()
1636
+ .ep(commonParams)
1637
+ .m(function (Command, cs, config, o) {
1638
+ return [
1639
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1640
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1641
+ ];
1642
+ })
1643
+ .s("schemas", "DescribeRegistry", {})
1644
+ .n("SchemasClient", "DescribeRegistryCommand")
1645
+ .f(void 0, void 0)
1646
+ .ser(se_DescribeRegistryCommand)
1647
+ .de(de_DescribeRegistryCommand)
1648
+ .build() {
1649
+ }
1650
+
1651
+ class DescribeSchemaCommand extends smithyClient.Command
1652
+ .classBuilder()
1653
+ .ep(commonParams)
1654
+ .m(function (Command, cs, config, o) {
1655
+ return [
1656
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1657
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1658
+ ];
1659
+ })
1660
+ .s("schemas", "DescribeSchema", {})
1661
+ .n("SchemasClient", "DescribeSchemaCommand")
1662
+ .f(void 0, void 0)
1663
+ .ser(se_DescribeSchemaCommand)
1664
+ .de(de_DescribeSchemaCommand)
1665
+ .build() {
1666
+ }
1667
+
1668
+ class ExportSchemaCommand extends smithyClient.Command
1669
+ .classBuilder()
1670
+ .ep(commonParams)
1671
+ .m(function (Command, cs, config, o) {
1672
+ return [
1673
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1674
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1675
+ ];
1676
+ })
1677
+ .s("schemas", "ExportSchema", {})
1678
+ .n("SchemasClient", "ExportSchemaCommand")
1679
+ .f(void 0, void 0)
1680
+ .ser(se_ExportSchemaCommand)
1681
+ .de(de_ExportSchemaCommand)
1682
+ .build() {
1683
+ }
1684
+
1685
+ class GetCodeBindingSourceCommand extends smithyClient.Command
1686
+ .classBuilder()
1687
+ .ep(commonParams)
1688
+ .m(function (Command, cs, config, o) {
1689
+ return [
1690
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1691
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1692
+ ];
1693
+ })
1694
+ .s("schemas", "GetCodeBindingSource", {})
1695
+ .n("SchemasClient", "GetCodeBindingSourceCommand")
1696
+ .f(void 0, void 0)
1697
+ .ser(se_GetCodeBindingSourceCommand)
1698
+ .de(de_GetCodeBindingSourceCommand)
1699
+ .build() {
1700
+ }
1701
+
1702
+ class GetDiscoveredSchemaCommand extends smithyClient.Command
1703
+ .classBuilder()
1704
+ .ep(commonParams)
1705
+ .m(function (Command, cs, config, o) {
1706
+ return [
1707
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1708
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1709
+ ];
1710
+ })
1711
+ .s("schemas", "GetDiscoveredSchema", {})
1712
+ .n("SchemasClient", "GetDiscoveredSchemaCommand")
1713
+ .f(void 0, void 0)
1714
+ .ser(se_GetDiscoveredSchemaCommand)
1715
+ .de(de_GetDiscoveredSchemaCommand)
1716
+ .build() {
1717
+ }
1718
+
1719
+ class GetResourcePolicyCommand extends smithyClient.Command
1720
+ .classBuilder()
1721
+ .ep(commonParams)
1722
+ .m(function (Command, cs, config, o) {
1723
+ return [
1724
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1725
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1726
+ ];
1727
+ })
1728
+ .s("schemas", "GetResourcePolicy", {})
1729
+ .n("SchemasClient", "GetResourcePolicyCommand")
1730
+ .f(void 0, void 0)
1731
+ .ser(se_GetResourcePolicyCommand)
1732
+ .de(de_GetResourcePolicyCommand)
1733
+ .build() {
1734
+ }
1735
+
1736
+ class ListDiscoverersCommand extends smithyClient.Command
1737
+ .classBuilder()
1738
+ .ep(commonParams)
1739
+ .m(function (Command, cs, config, o) {
1740
+ return [
1741
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1742
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1743
+ ];
1744
+ })
1745
+ .s("schemas", "ListDiscoverers", {})
1746
+ .n("SchemasClient", "ListDiscoverersCommand")
1747
+ .f(void 0, void 0)
1748
+ .ser(se_ListDiscoverersCommand)
1749
+ .de(de_ListDiscoverersCommand)
1750
+ .build() {
1751
+ }
1752
+
1753
+ class ListRegistriesCommand extends smithyClient.Command
1754
+ .classBuilder()
1755
+ .ep(commonParams)
1756
+ .m(function (Command, cs, config, o) {
1757
+ return [
1758
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1759
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1760
+ ];
1761
+ })
1762
+ .s("schemas", "ListRegistries", {})
1763
+ .n("SchemasClient", "ListRegistriesCommand")
1764
+ .f(void 0, void 0)
1765
+ .ser(se_ListRegistriesCommand)
1766
+ .de(de_ListRegistriesCommand)
1767
+ .build() {
1768
+ }
1769
+
1770
+ class ListSchemasCommand extends smithyClient.Command
1771
+ .classBuilder()
1772
+ .ep(commonParams)
1773
+ .m(function (Command, cs, config, o) {
1774
+ return [
1775
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1776
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1777
+ ];
1778
+ })
1779
+ .s("schemas", "ListSchemas", {})
1780
+ .n("SchemasClient", "ListSchemasCommand")
1781
+ .f(void 0, void 0)
1782
+ .ser(se_ListSchemasCommand)
1783
+ .de(de_ListSchemasCommand)
1784
+ .build() {
1785
+ }
1786
+
1787
+ class ListSchemaVersionsCommand extends smithyClient.Command
1788
+ .classBuilder()
1789
+ .ep(commonParams)
1790
+ .m(function (Command, cs, config, o) {
1791
+ return [
1792
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1793
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1794
+ ];
1795
+ })
1796
+ .s("schemas", "ListSchemaVersions", {})
1797
+ .n("SchemasClient", "ListSchemaVersionsCommand")
1798
+ .f(void 0, void 0)
1799
+ .ser(se_ListSchemaVersionsCommand)
1800
+ .de(de_ListSchemaVersionsCommand)
1801
+ .build() {
1802
+ }
1803
+
1804
+ class ListTagsForResourceCommand extends smithyClient.Command
1805
+ .classBuilder()
1806
+ .ep(commonParams)
1807
+ .m(function (Command, cs, config, o) {
1808
+ return [
1809
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1810
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1811
+ ];
1812
+ })
1813
+ .s("schemas", "ListTagsForResource", {})
1814
+ .n("SchemasClient", "ListTagsForResourceCommand")
1815
+ .f(void 0, void 0)
1816
+ .ser(se_ListTagsForResourceCommand)
1817
+ .de(de_ListTagsForResourceCommand)
1818
+ .build() {
1819
+ }
1820
+
1821
+ class PutCodeBindingCommand extends smithyClient.Command
1822
+ .classBuilder()
1823
+ .ep(commonParams)
1824
+ .m(function (Command, cs, config, o) {
1825
+ return [
1826
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1827
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1828
+ ];
1829
+ })
1830
+ .s("schemas", "PutCodeBinding", {})
1831
+ .n("SchemasClient", "PutCodeBindingCommand")
1832
+ .f(void 0, void 0)
1833
+ .ser(se_PutCodeBindingCommand)
1834
+ .de(de_PutCodeBindingCommand)
1835
+ .build() {
1836
+ }
1837
+
1838
+ class PutResourcePolicyCommand extends smithyClient.Command
1839
+ .classBuilder()
1840
+ .ep(commonParams)
1841
+ .m(function (Command, cs, config, o) {
1842
+ return [
1843
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1844
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1845
+ ];
1846
+ })
1847
+ .s("schemas", "PutResourcePolicy", {})
1848
+ .n("SchemasClient", "PutResourcePolicyCommand")
1849
+ .f(void 0, void 0)
1850
+ .ser(se_PutResourcePolicyCommand)
1851
+ .de(de_PutResourcePolicyCommand)
1852
+ .build() {
1853
+ }
1854
+
1855
+ class SearchSchemasCommand extends smithyClient.Command
1856
+ .classBuilder()
1857
+ .ep(commonParams)
1858
+ .m(function (Command, cs, config, o) {
1859
+ return [
1860
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1861
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1862
+ ];
1863
+ })
1864
+ .s("schemas", "SearchSchemas", {})
1865
+ .n("SchemasClient", "SearchSchemasCommand")
1866
+ .f(void 0, void 0)
1867
+ .ser(se_SearchSchemasCommand)
1868
+ .de(de_SearchSchemasCommand)
1869
+ .build() {
1870
+ }
1871
+
1872
+ class StartDiscovererCommand extends smithyClient.Command
1873
+ .classBuilder()
1874
+ .ep(commonParams)
1875
+ .m(function (Command, cs, config, o) {
1876
+ return [
1877
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1878
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1879
+ ];
1880
+ })
1881
+ .s("schemas", "StartDiscoverer", {})
1882
+ .n("SchemasClient", "StartDiscovererCommand")
1883
+ .f(void 0, void 0)
1884
+ .ser(se_StartDiscovererCommand)
1885
+ .de(de_StartDiscovererCommand)
1886
+ .build() {
1887
+ }
1888
+
1889
+ class StopDiscovererCommand extends smithyClient.Command
1890
+ .classBuilder()
1891
+ .ep(commonParams)
1892
+ .m(function (Command, cs, config, o) {
1893
+ return [
1894
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1895
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1896
+ ];
1897
+ })
1898
+ .s("schemas", "StopDiscoverer", {})
1899
+ .n("SchemasClient", "StopDiscovererCommand")
1900
+ .f(void 0, void 0)
1901
+ .ser(se_StopDiscovererCommand)
1902
+ .de(de_StopDiscovererCommand)
1903
+ .build() {
1904
+ }
1905
+
1906
+ class TagResourceCommand extends smithyClient.Command
1907
+ .classBuilder()
1908
+ .ep(commonParams)
1909
+ .m(function (Command, cs, config, o) {
1910
+ return [
1911
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1912
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1913
+ ];
1914
+ })
1915
+ .s("schemas", "TagResource", {})
1916
+ .n("SchemasClient", "TagResourceCommand")
1917
+ .f(void 0, void 0)
1918
+ .ser(se_TagResourceCommand)
1919
+ .de(de_TagResourceCommand)
1920
+ .build() {
1921
+ }
1922
+
1923
+ class UntagResourceCommand extends smithyClient.Command
1924
+ .classBuilder()
1925
+ .ep(commonParams)
1926
+ .m(function (Command, cs, config, o) {
1927
+ return [
1928
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1929
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1930
+ ];
1931
+ })
1932
+ .s("schemas", "UntagResource", {})
1933
+ .n("SchemasClient", "UntagResourceCommand")
1934
+ .f(void 0, void 0)
1935
+ .ser(se_UntagResourceCommand)
1936
+ .de(de_UntagResourceCommand)
1937
+ .build() {
1938
+ }
1939
+
1940
+ class UpdateDiscovererCommand extends smithyClient.Command
1941
+ .classBuilder()
1942
+ .ep(commonParams)
1943
+ .m(function (Command, cs, config, o) {
1944
+ return [
1945
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1946
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1947
+ ];
1948
+ })
1949
+ .s("schemas", "UpdateDiscoverer", {})
1950
+ .n("SchemasClient", "UpdateDiscovererCommand")
1951
+ .f(void 0, void 0)
1952
+ .ser(se_UpdateDiscovererCommand)
1953
+ .de(de_UpdateDiscovererCommand)
1954
+ .build() {
1955
+ }
1956
+
1957
+ class UpdateRegistryCommand extends smithyClient.Command
1958
+ .classBuilder()
1959
+ .ep(commonParams)
1960
+ .m(function (Command, cs, config, o) {
1961
+ return [
1962
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1963
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1964
+ ];
1965
+ })
1966
+ .s("schemas", "UpdateRegistry", {})
1967
+ .n("SchemasClient", "UpdateRegistryCommand")
1968
+ .f(void 0, void 0)
1969
+ .ser(se_UpdateRegistryCommand)
1970
+ .de(de_UpdateRegistryCommand)
1971
+ .build() {
1972
+ }
1973
+
1974
+ class UpdateSchemaCommand extends smithyClient.Command
1975
+ .classBuilder()
1976
+ .ep(commonParams)
1977
+ .m(function (Command, cs, config, o) {
1978
+ return [
1979
+ middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1980
+ middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1981
+ ];
1982
+ })
1983
+ .s("schemas", "UpdateSchema", {})
1984
+ .n("SchemasClient", "UpdateSchemaCommand")
1985
+ .f(void 0, void 0)
1986
+ .ser(se_UpdateSchemaCommand)
1987
+ .de(de_UpdateSchemaCommand)
1988
+ .build() {
1989
+ }
1990
+
1991
+ const commands = {
1992
+ CreateDiscovererCommand,
1993
+ CreateRegistryCommand,
1994
+ CreateSchemaCommand,
1995
+ DeleteDiscovererCommand,
1996
+ DeleteRegistryCommand,
1997
+ DeleteResourcePolicyCommand,
1998
+ DeleteSchemaCommand,
1999
+ DeleteSchemaVersionCommand,
2000
+ DescribeCodeBindingCommand,
2001
+ DescribeDiscovererCommand,
2002
+ DescribeRegistryCommand,
2003
+ DescribeSchemaCommand,
2004
+ ExportSchemaCommand,
2005
+ GetCodeBindingSourceCommand,
2006
+ GetDiscoveredSchemaCommand,
2007
+ GetResourcePolicyCommand,
2008
+ ListDiscoverersCommand,
2009
+ ListRegistriesCommand,
2010
+ ListSchemasCommand,
2011
+ ListSchemaVersionsCommand,
2012
+ ListTagsForResourceCommand,
2013
+ PutCodeBindingCommand,
2014
+ PutResourcePolicyCommand,
2015
+ SearchSchemasCommand,
2016
+ StartDiscovererCommand,
2017
+ StopDiscovererCommand,
2018
+ TagResourceCommand,
2019
+ UntagResourceCommand,
2020
+ UpdateDiscovererCommand,
2021
+ UpdateRegistryCommand,
2022
+ UpdateSchemaCommand,
2023
+ };
2024
+ class Schemas extends SchemasClient {
2025
+ }
2026
+ smithyClient.createAggregatedClient(commands, Schemas);
2205
2027
 
2206
- // src/Schemas.ts
2207
- var commands = {
2208
- CreateDiscovererCommand,
2209
- CreateRegistryCommand,
2210
- CreateSchemaCommand,
2211
- DeleteDiscovererCommand,
2212
- DeleteRegistryCommand,
2213
- DeleteResourcePolicyCommand,
2214
- DeleteSchemaCommand,
2215
- DeleteSchemaVersionCommand,
2216
- DescribeCodeBindingCommand,
2217
- DescribeDiscovererCommand,
2218
- DescribeRegistryCommand,
2219
- DescribeSchemaCommand,
2220
- ExportSchemaCommand,
2221
- GetCodeBindingSourceCommand,
2222
- GetDiscoveredSchemaCommand,
2223
- GetResourcePolicyCommand,
2224
- ListDiscoverersCommand,
2225
- ListRegistriesCommand,
2226
- ListSchemasCommand,
2227
- ListSchemaVersionsCommand,
2228
- ListTagsForResourceCommand,
2229
- PutCodeBindingCommand,
2230
- PutResourcePolicyCommand,
2231
- SearchSchemasCommand,
2232
- StartDiscovererCommand,
2233
- StopDiscovererCommand,
2234
- TagResourceCommand,
2235
- UntagResourceCommand,
2236
- UpdateDiscovererCommand,
2237
- UpdateRegistryCommand,
2238
- UpdateSchemaCommand
2239
- };
2240
- var Schemas = class extends SchemasClient {
2241
- static {
2242
- __name(this, "Schemas");
2243
- }
2244
- };
2245
- (0, import_smithy_client.createAggregatedClient)(commands, Schemas);
2246
-
2247
- // src/pagination/ListDiscoverersPaginator.ts
2248
-
2249
- var paginateListDiscoverers = (0, import_core.createPaginator)(SchemasClient, ListDiscoverersCommand, "NextToken", "NextToken", "Limit");
2250
-
2251
- // src/pagination/ListRegistriesPaginator.ts
2252
-
2253
- var paginateListRegistries = (0, import_core.createPaginator)(SchemasClient, ListRegistriesCommand, "NextToken", "NextToken", "Limit");
2254
-
2255
- // src/pagination/ListSchemaVersionsPaginator.ts
2256
-
2257
- var paginateListSchemaVersions = (0, import_core.createPaginator)(SchemasClient, ListSchemaVersionsCommand, "NextToken", "NextToken", "Limit");
2028
+ const paginateListDiscoverers = core.createPaginator(SchemasClient, ListDiscoverersCommand, "NextToken", "NextToken", "Limit");
2258
2029
 
2259
- // src/pagination/ListSchemasPaginator.ts
2030
+ const paginateListRegistries = core.createPaginator(SchemasClient, ListRegistriesCommand, "NextToken", "NextToken", "Limit");
2260
2031
 
2261
- var paginateListSchemas = (0, import_core.createPaginator)(SchemasClient, ListSchemasCommand, "NextToken", "NextToken", "Limit");
2032
+ const paginateListSchemaVersions = core.createPaginator(SchemasClient, ListSchemaVersionsCommand, "NextToken", "NextToken", "Limit");
2262
2033
 
2263
- // src/pagination/SearchSchemasPaginator.ts
2034
+ const paginateListSchemas = core.createPaginator(SchemasClient, ListSchemasCommand, "NextToken", "NextToken", "Limit");
2264
2035
 
2265
- var paginateSearchSchemas = (0, import_core.createPaginator)(SchemasClient, SearchSchemasCommand, "NextToken", "NextToken", "Limit");
2036
+ const paginateSearchSchemas = core.createPaginator(SchemasClient, SearchSchemasCommand, "NextToken", "NextToken", "Limit");
2266
2037
 
2267
- // src/waiters/waitForCodeBindingExists.ts
2268
- var import_util_waiter = require("@smithy/util-waiter");
2269
- var checkState = /* @__PURE__ */ __name(async (client, input) => {
2270
- let reason;
2271
- try {
2272
- const result = await client.send(new DescribeCodeBindingCommand(input));
2273
- reason = result;
2274
- try {
2275
- const returnComparator = /* @__PURE__ */ __name(() => {
2276
- return result.Status;
2277
- }, "returnComparator");
2278
- if (returnComparator() === "CREATE_COMPLETE") {
2279
- return { state: import_util_waiter.WaiterState.SUCCESS, reason };
2280
- }
2281
- } catch (e) {
2282
- }
2283
- try {
2284
- const returnComparator = /* @__PURE__ */ __name(() => {
2285
- return result.Status;
2286
- }, "returnComparator");
2287
- if (returnComparator() === "CREATE_IN_PROGRESS") {
2288
- return { state: import_util_waiter.WaiterState.RETRY, reason };
2289
- }
2290
- } catch (e) {
2291
- }
2038
+ const checkState = async (client, input) => {
2039
+ let reason;
2292
2040
  try {
2293
- const returnComparator = /* @__PURE__ */ __name(() => {
2294
- return result.Status;
2295
- }, "returnComparator");
2296
- if (returnComparator() === "CREATE_FAILED") {
2297
- return { state: import_util_waiter.WaiterState.FAILURE, reason };
2298
- }
2299
- } catch (e) {
2041
+ const result = await client.send(new DescribeCodeBindingCommand(input));
2042
+ reason = result;
2043
+ try {
2044
+ const returnComparator = () => {
2045
+ return result.Status;
2046
+ };
2047
+ if (returnComparator() === "CREATE_COMPLETE") {
2048
+ return { state: utilWaiter.WaiterState.SUCCESS, reason };
2049
+ }
2050
+ }
2051
+ catch (e) { }
2052
+ try {
2053
+ const returnComparator = () => {
2054
+ return result.Status;
2055
+ };
2056
+ if (returnComparator() === "CREATE_IN_PROGRESS") {
2057
+ return { state: utilWaiter.WaiterState.RETRY, reason };
2058
+ }
2059
+ }
2060
+ catch (e) { }
2061
+ try {
2062
+ const returnComparator = () => {
2063
+ return result.Status;
2064
+ };
2065
+ if (returnComparator() === "CREATE_FAILED") {
2066
+ return { state: utilWaiter.WaiterState.FAILURE, reason };
2067
+ }
2068
+ }
2069
+ catch (e) { }
2300
2070
  }
2301
- } catch (exception) {
2302
- reason = exception;
2303
- if (exception.name && exception.name == "NotFoundException") {
2304
- return { state: import_util_waiter.WaiterState.FAILURE, reason };
2071
+ catch (exception) {
2072
+ reason = exception;
2073
+ if (exception.name && exception.name == "NotFoundException") {
2074
+ return { state: utilWaiter.WaiterState.FAILURE, reason };
2075
+ }
2305
2076
  }
2306
- }
2307
- return { state: import_util_waiter.WaiterState.RETRY, reason };
2308
- }, "checkState");
2309
- var waitForCodeBindingExists = /* @__PURE__ */ __name(async (params, input) => {
2310
- const serviceDefaults = { minDelay: 2, maxDelay: 120 };
2311
- return (0, import_util_waiter.createWaiter)({ ...serviceDefaults, ...params }, input, checkState);
2312
- }, "waitForCodeBindingExists");
2313
- var waitUntilCodeBindingExists = /* @__PURE__ */ __name(async (params, input) => {
2314
- const serviceDefaults = { minDelay: 2, maxDelay: 120 };
2315
- const result = await (0, import_util_waiter.createWaiter)({ ...serviceDefaults, ...params }, input, checkState);
2316
- return (0, import_util_waiter.checkExceptions)(result);
2317
- }, "waitUntilCodeBindingExists");
2318
- // Annotate the CommonJS export names for ESM import in node:
2077
+ return { state: utilWaiter.WaiterState.RETRY, reason };
2078
+ };
2079
+ const waitForCodeBindingExists = async (params, input) => {
2080
+ const serviceDefaults = { minDelay: 2, maxDelay: 120 };
2081
+ return utilWaiter.createWaiter({ ...serviceDefaults, ...params }, input, checkState);
2082
+ };
2083
+ const waitUntilCodeBindingExists = async (params, input) => {
2084
+ const serviceDefaults = { minDelay: 2, maxDelay: 120 };
2085
+ const result = await utilWaiter.createWaiter({ ...serviceDefaults, ...params }, input, checkState);
2086
+ return utilWaiter.checkExceptions(result);
2087
+ };
2319
2088
 
2320
- 0 && (module.exports = {
2321
- SchemasServiceException,
2322
- __Client,
2323
- SchemasClient,
2324
- Schemas,
2325
- $Command,
2326
- CreateDiscovererCommand,
2327
- CreateRegistryCommand,
2328
- CreateSchemaCommand,
2329
- DeleteDiscovererCommand,
2330
- DeleteRegistryCommand,
2331
- DeleteResourcePolicyCommand,
2332
- DeleteSchemaCommand,
2333
- DeleteSchemaVersionCommand,
2334
- DescribeCodeBindingCommand,
2335
- DescribeDiscovererCommand,
2336
- DescribeRegistryCommand,
2337
- DescribeSchemaCommand,
2338
- ExportSchemaCommand,
2339
- GetCodeBindingSourceCommand,
2340
- GetDiscoveredSchemaCommand,
2341
- GetResourcePolicyCommand,
2342
- ListDiscoverersCommand,
2343
- ListRegistriesCommand,
2344
- ListSchemaVersionsCommand,
2345
- ListSchemasCommand,
2346
- ListTagsForResourceCommand,
2347
- PutCodeBindingCommand,
2348
- PutResourcePolicyCommand,
2349
- SearchSchemasCommand,
2350
- StartDiscovererCommand,
2351
- StopDiscovererCommand,
2352
- TagResourceCommand,
2353
- UntagResourceCommand,
2354
- UpdateDiscovererCommand,
2355
- UpdateRegistryCommand,
2356
- UpdateSchemaCommand,
2357
- paginateListDiscoverers,
2358
- paginateListRegistries,
2359
- paginateListSchemaVersions,
2360
- paginateListSchemas,
2361
- paginateSearchSchemas,
2362
- waitForCodeBindingExists,
2363
- waitUntilCodeBindingExists,
2364
- DiscovererState,
2365
- Type,
2366
- BadRequestException,
2367
- CodeGenerationStatus,
2368
- ConflictException,
2369
- ForbiddenException,
2370
- InternalServerErrorException,
2371
- ServiceUnavailableException,
2372
- UnauthorizedException,
2373
- NotFoundException,
2374
- TooManyRequestsException,
2375
- GoneException,
2376
- PreconditionFailedException
2089
+ Object.defineProperty(exports, "$Command", {
2090
+ enumerable: true,
2091
+ get: function () { return smithyClient.Command; }
2377
2092
  });
2378
-
2093
+ Object.defineProperty(exports, "__Client", {
2094
+ enumerable: true,
2095
+ get: function () { return smithyClient.Client; }
2096
+ });
2097
+ exports.BadRequestException = BadRequestException;
2098
+ exports.CodeGenerationStatus = CodeGenerationStatus;
2099
+ exports.ConflictException = ConflictException;
2100
+ exports.CreateDiscovererCommand = CreateDiscovererCommand;
2101
+ exports.CreateRegistryCommand = CreateRegistryCommand;
2102
+ exports.CreateSchemaCommand = CreateSchemaCommand;
2103
+ exports.DeleteDiscovererCommand = DeleteDiscovererCommand;
2104
+ exports.DeleteRegistryCommand = DeleteRegistryCommand;
2105
+ exports.DeleteResourcePolicyCommand = DeleteResourcePolicyCommand;
2106
+ exports.DeleteSchemaCommand = DeleteSchemaCommand;
2107
+ exports.DeleteSchemaVersionCommand = DeleteSchemaVersionCommand;
2108
+ exports.DescribeCodeBindingCommand = DescribeCodeBindingCommand;
2109
+ exports.DescribeDiscovererCommand = DescribeDiscovererCommand;
2110
+ exports.DescribeRegistryCommand = DescribeRegistryCommand;
2111
+ exports.DescribeSchemaCommand = DescribeSchemaCommand;
2112
+ exports.DiscovererState = DiscovererState;
2113
+ exports.ExportSchemaCommand = ExportSchemaCommand;
2114
+ exports.ForbiddenException = ForbiddenException;
2115
+ exports.GetCodeBindingSourceCommand = GetCodeBindingSourceCommand;
2116
+ exports.GetDiscoveredSchemaCommand = GetDiscoveredSchemaCommand;
2117
+ exports.GetResourcePolicyCommand = GetResourcePolicyCommand;
2118
+ exports.GoneException = GoneException;
2119
+ exports.InternalServerErrorException = InternalServerErrorException;
2120
+ exports.ListDiscoverersCommand = ListDiscoverersCommand;
2121
+ exports.ListRegistriesCommand = ListRegistriesCommand;
2122
+ exports.ListSchemaVersionsCommand = ListSchemaVersionsCommand;
2123
+ exports.ListSchemasCommand = ListSchemasCommand;
2124
+ exports.ListTagsForResourceCommand = ListTagsForResourceCommand;
2125
+ exports.NotFoundException = NotFoundException;
2126
+ exports.PreconditionFailedException = PreconditionFailedException;
2127
+ exports.PutCodeBindingCommand = PutCodeBindingCommand;
2128
+ exports.PutResourcePolicyCommand = PutResourcePolicyCommand;
2129
+ exports.Schemas = Schemas;
2130
+ exports.SchemasClient = SchemasClient;
2131
+ exports.SchemasServiceException = SchemasServiceException;
2132
+ exports.SearchSchemasCommand = SearchSchemasCommand;
2133
+ exports.ServiceUnavailableException = ServiceUnavailableException;
2134
+ exports.StartDiscovererCommand = StartDiscovererCommand;
2135
+ exports.StopDiscovererCommand = StopDiscovererCommand;
2136
+ exports.TagResourceCommand = TagResourceCommand;
2137
+ exports.TooManyRequestsException = TooManyRequestsException;
2138
+ exports.Type = Type;
2139
+ exports.UnauthorizedException = UnauthorizedException;
2140
+ exports.UntagResourceCommand = UntagResourceCommand;
2141
+ exports.UpdateDiscovererCommand = UpdateDiscovererCommand;
2142
+ exports.UpdateRegistryCommand = UpdateRegistryCommand;
2143
+ exports.UpdateSchemaCommand = UpdateSchemaCommand;
2144
+ exports.paginateListDiscoverers = paginateListDiscoverers;
2145
+ exports.paginateListRegistries = paginateListRegistries;
2146
+ exports.paginateListSchemaVersions = paginateListSchemaVersions;
2147
+ exports.paginateListSchemas = paginateListSchemas;
2148
+ exports.paginateSearchSchemas = paginateSearchSchemas;
2149
+ exports.waitForCodeBindingExists = waitForCodeBindingExists;
2150
+ exports.waitUntilCodeBindingExists = waitUntilCodeBindingExists;