@aws-sdk/client-geo-maps 3.893.0 → 3.895.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.
package/dist-cjs/index.js CHANGED
@@ -1,10 +1,860 @@
1
1
  "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GeoMapsServiceException = void 0;
4
- const tslib_1 = require("tslib");
5
- tslib_1.__exportStar(require("./GeoMapsClient"), exports);
6
- tslib_1.__exportStar(require("./GeoMaps"), exports);
7
- tslib_1.__exportStar(require("./commands"), exports);
8
- tslib_1.__exportStar(require("./models"), exports);
9
- var GeoMapsServiceException_1 = require("./models/GeoMapsServiceException");
10
- Object.defineProperty(exports, "GeoMapsServiceException", { enumerable: true, get: function () { return GeoMapsServiceException_1.GeoMapsServiceException; } });
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
+ AccessDeniedException: () => AccessDeniedException,
25
+ ColorScheme: () => ColorScheme,
26
+ GeoMaps: () => GeoMaps,
27
+ GeoMapsClient: () => GeoMapsClient,
28
+ GeoMapsServiceException: () => GeoMapsServiceException,
29
+ GetGlyphsCommand: () => GetGlyphsCommand,
30
+ GetSpritesCommand: () => GetSpritesCommand,
31
+ GetStaticMapCommand: () => GetStaticMapCommand,
32
+ GetStaticMapRequestFilterSensitiveLog: () => GetStaticMapRequestFilterSensitiveLog,
33
+ GetStyleDescriptorCommand: () => GetStyleDescriptorCommand,
34
+ GetStyleDescriptorRequestFilterSensitiveLog: () => GetStyleDescriptorRequestFilterSensitiveLog,
35
+ GetTileCommand: () => GetTileCommand,
36
+ GetTileRequestFilterSensitiveLog: () => GetTileRequestFilterSensitiveLog,
37
+ InternalServerException: () => InternalServerException,
38
+ LabelSize: () => LabelSize,
39
+ MapFeatureMode: () => MapFeatureMode,
40
+ MapStyle: () => MapStyle,
41
+ ResourceNotFoundException: () => ResourceNotFoundException,
42
+ ScaleBarUnit: () => ScaleBarUnit,
43
+ StaticMapStyle: () => StaticMapStyle,
44
+ ThrottlingException: () => ThrottlingException,
45
+ ValidationException: () => ValidationException,
46
+ ValidationExceptionReason: () => ValidationExceptionReason,
47
+ Variant: () => Variant,
48
+ __Client: () => import_smithy_client.Client
49
+ });
50
+ module.exports = __toCommonJS(index_exports);
51
+
52
+ // src/GeoMapsClient.ts
53
+ var import_middleware_host_header = require("@aws-sdk/middleware-host-header");
54
+ var import_middleware_logger = require("@aws-sdk/middleware-logger");
55
+ var import_middleware_recursion_detection = require("@aws-sdk/middleware-recursion-detection");
56
+ var import_middleware_user_agent = require("@aws-sdk/middleware-user-agent");
57
+ var import_config_resolver = require("@smithy/config-resolver");
58
+ var import_core = require("@smithy/core");
59
+ var import_middleware_content_length = require("@smithy/middleware-content-length");
60
+ var import_middleware_endpoint = require("@smithy/middleware-endpoint");
61
+ var import_middleware_retry = require("@smithy/middleware-retry");
62
+
63
+ var import_httpAuthSchemeProvider = require("./auth/httpAuthSchemeProvider");
64
+
65
+ // src/endpoint/EndpointParameters.ts
66
+ var resolveClientEndpointParameters = /* @__PURE__ */ __name((options) => {
67
+ return Object.assign(options, {
68
+ useDualstackEndpoint: options.useDualstackEndpoint ?? false,
69
+ useFipsEndpoint: options.useFipsEndpoint ?? false,
70
+ defaultSigningName: "geo-maps"
71
+ });
72
+ }, "resolveClientEndpointParameters");
73
+ var commonParams = {
74
+ UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
75
+ Endpoint: { type: "builtInParams", name: "endpoint" },
76
+ Region: { type: "builtInParams", name: "region" },
77
+ UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }
78
+ };
79
+
80
+ // src/GeoMapsClient.ts
81
+ var import_runtimeConfig = require("././runtimeConfig");
82
+
83
+ // src/runtimeExtensions.ts
84
+ var import_region_config_resolver = require("@aws-sdk/region-config-resolver");
85
+ var import_protocol_http = require("@smithy/protocol-http");
86
+ var import_smithy_client = require("@smithy/smithy-client");
87
+
88
+ // src/auth/httpAuthExtensionConfiguration.ts
89
+ var getHttpAuthExtensionConfiguration = /* @__PURE__ */ __name((runtimeConfig) => {
90
+ const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;
91
+ let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;
92
+ let _credentials = runtimeConfig.credentials;
93
+ return {
94
+ setHttpAuthScheme(httpAuthScheme) {
95
+ const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);
96
+ if (index === -1) {
97
+ _httpAuthSchemes.push(httpAuthScheme);
98
+ } else {
99
+ _httpAuthSchemes.splice(index, 1, httpAuthScheme);
100
+ }
101
+ },
102
+ httpAuthSchemes() {
103
+ return _httpAuthSchemes;
104
+ },
105
+ setHttpAuthSchemeProvider(httpAuthSchemeProvider) {
106
+ _httpAuthSchemeProvider = httpAuthSchemeProvider;
107
+ },
108
+ httpAuthSchemeProvider() {
109
+ return _httpAuthSchemeProvider;
110
+ },
111
+ setCredentials(credentials) {
112
+ _credentials = credentials;
113
+ },
114
+ credentials() {
115
+ return _credentials;
116
+ }
117
+ };
118
+ }, "getHttpAuthExtensionConfiguration");
119
+ var resolveHttpAuthRuntimeConfig = /* @__PURE__ */ __name((config) => {
120
+ return {
121
+ httpAuthSchemes: config.httpAuthSchemes(),
122
+ httpAuthSchemeProvider: config.httpAuthSchemeProvider(),
123
+ credentials: config.credentials()
124
+ };
125
+ }, "resolveHttpAuthRuntimeConfig");
126
+
127
+ // src/runtimeExtensions.ts
128
+ var resolveRuntimeExtensions = /* @__PURE__ */ __name((runtimeConfig, extensions) => {
129
+ const extensionConfiguration = Object.assign(
130
+ (0, import_region_config_resolver.getAwsRegionExtensionConfiguration)(runtimeConfig),
131
+ (0, import_smithy_client.getDefaultExtensionConfiguration)(runtimeConfig),
132
+ (0, import_protocol_http.getHttpHandlerExtensionConfiguration)(runtimeConfig),
133
+ getHttpAuthExtensionConfiguration(runtimeConfig)
134
+ );
135
+ extensions.forEach((extension) => extension.configure(extensionConfiguration));
136
+ return Object.assign(
137
+ runtimeConfig,
138
+ (0, import_region_config_resolver.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),
139
+ (0, import_smithy_client.resolveDefaultRuntimeConfig)(extensionConfiguration),
140
+ (0, import_protocol_http.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),
141
+ resolveHttpAuthRuntimeConfig(extensionConfiguration)
142
+ );
143
+ }, "resolveRuntimeExtensions");
144
+
145
+ // src/GeoMapsClient.ts
146
+ var GeoMapsClient = class extends import_smithy_client.Client {
147
+ static {
148
+ __name(this, "GeoMapsClient");
149
+ }
150
+ /**
151
+ * The resolved configuration of GeoMapsClient class. This is resolved and normalized from the {@link GeoMapsClientConfig | constructor configuration interface}.
152
+ */
153
+ config;
154
+ constructor(...[configuration]) {
155
+ const _config_0 = (0, import_runtimeConfig.getRuntimeConfig)(configuration || {});
156
+ super(_config_0);
157
+ this.initConfig = _config_0;
158
+ const _config_1 = resolveClientEndpointParameters(_config_0);
159
+ const _config_2 = (0, import_middleware_user_agent.resolveUserAgentConfig)(_config_1);
160
+ const _config_3 = (0, import_middleware_retry.resolveRetryConfig)(_config_2);
161
+ const _config_4 = (0, import_config_resolver.resolveRegionConfig)(_config_3);
162
+ const _config_5 = (0, import_middleware_host_header.resolveHostHeaderConfig)(_config_4);
163
+ const _config_6 = (0, import_middleware_endpoint.resolveEndpointConfig)(_config_5);
164
+ const _config_7 = (0, import_httpAuthSchemeProvider.resolveHttpAuthSchemeConfig)(_config_6);
165
+ const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
166
+ this.config = _config_8;
167
+ this.middlewareStack.use((0, import_middleware_user_agent.getUserAgentPlugin)(this.config));
168
+ this.middlewareStack.use((0, import_middleware_retry.getRetryPlugin)(this.config));
169
+ this.middlewareStack.use((0, import_middleware_content_length.getContentLengthPlugin)(this.config));
170
+ this.middlewareStack.use((0, import_middleware_host_header.getHostHeaderPlugin)(this.config));
171
+ this.middlewareStack.use((0, import_middleware_logger.getLoggerPlugin)(this.config));
172
+ this.middlewareStack.use((0, import_middleware_recursion_detection.getRecursionDetectionPlugin)(this.config));
173
+ this.middlewareStack.use(
174
+ (0, import_core.getHttpAuthSchemeEndpointRuleSetPlugin)(this.config, {
175
+ httpAuthSchemeParametersProvider: import_httpAuthSchemeProvider.defaultGeoMapsHttpAuthSchemeParametersProvider,
176
+ identityProviderConfigProvider: /* @__PURE__ */ __name(async (config) => new import_core.DefaultIdentityProviderConfig({
177
+ "aws.auth#sigv4": config.credentials
178
+ }), "identityProviderConfigProvider")
179
+ })
180
+ );
181
+ this.middlewareStack.use((0, import_core.getHttpSigningPlugin)(this.config));
182
+ }
183
+ /**
184
+ * Destroy underlying resources, like sockets. It's usually not necessary to do this.
185
+ * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
186
+ * Otherwise, sockets might stay open for quite a long time before the server terminates them.
187
+ */
188
+ destroy() {
189
+ super.destroy();
190
+ }
191
+ };
192
+
193
+ // src/GeoMaps.ts
194
+
195
+
196
+ // src/commands/GetGlyphsCommand.ts
197
+
198
+ var import_middleware_serde = require("@smithy/middleware-serde");
199
+
200
+
201
+ // src/protocols/Aws_restJson1.ts
202
+ var import_core2 = require("@aws-sdk/core");
203
+
204
+
205
+
206
+ // src/models/GeoMapsServiceException.ts
207
+
208
+ var GeoMapsServiceException = class _GeoMapsServiceException extends import_smithy_client.ServiceException {
209
+ static {
210
+ __name(this, "GeoMapsServiceException");
211
+ }
212
+ /**
213
+ * @internal
214
+ */
215
+ constructor(options) {
216
+ super(options);
217
+ Object.setPrototypeOf(this, _GeoMapsServiceException.prototype);
218
+ }
219
+ };
220
+
221
+ // src/models/models_0.ts
222
+
223
+ var AccessDeniedException = class _AccessDeniedException extends GeoMapsServiceException {
224
+ static {
225
+ __name(this, "AccessDeniedException");
226
+ }
227
+ name = "AccessDeniedException";
228
+ $fault = "client";
229
+ Message;
230
+ /**
231
+ * @internal
232
+ */
233
+ constructor(opts) {
234
+ super({
235
+ name: "AccessDeniedException",
236
+ $fault: "client",
237
+ ...opts
238
+ });
239
+ Object.setPrototypeOf(this, _AccessDeniedException.prototype);
240
+ this.Message = opts.Message;
241
+ }
242
+ };
243
+ var ColorScheme = {
244
+ DARK: "Dark",
245
+ LIGHT: "Light"
246
+ };
247
+ var MapStyle = {
248
+ HYBRID: "Hybrid",
249
+ MONOCHROME: "Monochrome",
250
+ SATELLITE: "Satellite",
251
+ STANDARD: "Standard"
252
+ };
253
+ var Variant = {
254
+ DEFAULT: "Default"
255
+ };
256
+ var LabelSize = {
257
+ LARGE: "Large",
258
+ SMALL: "Small"
259
+ };
260
+ var MapFeatureMode = {
261
+ DISABLED: "Disabled",
262
+ ENABLED: "Enabled"
263
+ };
264
+ var ScaleBarUnit = {
265
+ KILOMETERS: "Kilometers",
266
+ KILOMETERS_MILES: "KilometersMiles",
267
+ MILES: "Miles",
268
+ MILES_KILOMETERS: "MilesKilometers"
269
+ };
270
+ var StaticMapStyle = {
271
+ SATELLITE: "Satellite",
272
+ STANDARD: "Standard"
273
+ };
274
+ var InternalServerException = class _InternalServerException extends GeoMapsServiceException {
275
+ static {
276
+ __name(this, "InternalServerException");
277
+ }
278
+ name = "InternalServerException";
279
+ $fault = "server";
280
+ $retryable = {};
281
+ Message;
282
+ /**
283
+ * @internal
284
+ */
285
+ constructor(opts) {
286
+ super({
287
+ name: "InternalServerException",
288
+ $fault: "server",
289
+ ...opts
290
+ });
291
+ Object.setPrototypeOf(this, _InternalServerException.prototype);
292
+ this.Message = opts.Message;
293
+ }
294
+ };
295
+ var ThrottlingException = class _ThrottlingException extends GeoMapsServiceException {
296
+ static {
297
+ __name(this, "ThrottlingException");
298
+ }
299
+ name = "ThrottlingException";
300
+ $fault = "client";
301
+ $retryable = {};
302
+ Message;
303
+ /**
304
+ * @internal
305
+ */
306
+ constructor(opts) {
307
+ super({
308
+ name: "ThrottlingException",
309
+ $fault: "client",
310
+ ...opts
311
+ });
312
+ Object.setPrototypeOf(this, _ThrottlingException.prototype);
313
+ this.Message = opts.Message;
314
+ }
315
+ };
316
+ var ValidationExceptionReason = {
317
+ /**
318
+ * The input cannot be parsed. For example a required JSON document, ARN identifier,
319
+ * date value, or numeric field cannot be parsed.
320
+ *
321
+ */
322
+ CANNOT_PARSE: "CannotParse",
323
+ /**
324
+ * The input is present and parsable, but it is otherwise invalid. For example, a
325
+ * required numeric argument is outside the allowed range.
326
+ *
327
+ */
328
+ FIELD_VALIDATION_FAILED: "FieldValidationFailed",
329
+ /**
330
+ * The required input is missing.
331
+ */
332
+ MISSING: "Missing",
333
+ /**
334
+ * The input is invalid but no more specific reason is applicable.
335
+ */
336
+ OTHER: "Other",
337
+ /**
338
+ * No such field is supported.
339
+ */
340
+ UNKNOWN_FIELD: "UnknownField",
341
+ /**
342
+ * No such operation is supported.
343
+ */
344
+ UNKNOWN_OPERATION: "UnknownOperation"
345
+ };
346
+ var ValidationException = class _ValidationException extends GeoMapsServiceException {
347
+ static {
348
+ __name(this, "ValidationException");
349
+ }
350
+ name = "ValidationException";
351
+ $fault = "client";
352
+ Message;
353
+ /**
354
+ * <p>The field where the invalid entry was detected.</p>
355
+ * @public
356
+ */
357
+ Reason;
358
+ /**
359
+ * <p>A message with the reason for the validation exception error.</p>
360
+ * @public
361
+ */
362
+ FieldList;
363
+ /**
364
+ * @internal
365
+ */
366
+ constructor(opts) {
367
+ super({
368
+ name: "ValidationException",
369
+ $fault: "client",
370
+ ...opts
371
+ });
372
+ Object.setPrototypeOf(this, _ValidationException.prototype);
373
+ this.Message = opts.Message;
374
+ this.Reason = opts.Reason;
375
+ this.FieldList = opts.FieldList;
376
+ }
377
+ };
378
+ var ResourceNotFoundException = class _ResourceNotFoundException extends GeoMapsServiceException {
379
+ static {
380
+ __name(this, "ResourceNotFoundException");
381
+ }
382
+ name = "ResourceNotFoundException";
383
+ $fault = "client";
384
+ Message;
385
+ /**
386
+ * @internal
387
+ */
388
+ constructor(opts) {
389
+ super({
390
+ name: "ResourceNotFoundException",
391
+ $fault: "client",
392
+ ...opts
393
+ });
394
+ Object.setPrototypeOf(this, _ResourceNotFoundException.prototype);
395
+ this.Message = opts.Message;
396
+ }
397
+ };
398
+ var GetStaticMapRequestFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
399
+ ...obj,
400
+ ...obj.BoundingBox && { BoundingBox: import_smithy_client.SENSITIVE_STRING },
401
+ ...obj.BoundedPositions && { BoundedPositions: import_smithy_client.SENSITIVE_STRING },
402
+ ...obj.Center && { Center: import_smithy_client.SENSITIVE_STRING },
403
+ ...obj.CompactOverlay && { CompactOverlay: import_smithy_client.SENSITIVE_STRING },
404
+ ...obj.GeoJsonOverlay && { GeoJsonOverlay: import_smithy_client.SENSITIVE_STRING },
405
+ ...obj.Height && { Height: import_smithy_client.SENSITIVE_STRING },
406
+ ...obj.Key && { Key: import_smithy_client.SENSITIVE_STRING },
407
+ ...obj.Padding && { Padding: import_smithy_client.SENSITIVE_STRING },
408
+ ...obj.PoliticalView && { PoliticalView: import_smithy_client.SENSITIVE_STRING },
409
+ ...obj.Radius && { Radius: import_smithy_client.SENSITIVE_STRING },
410
+ ...obj.Width && { Width: import_smithy_client.SENSITIVE_STRING },
411
+ ...obj.Zoom && { Zoom: import_smithy_client.SENSITIVE_STRING }
412
+ }), "GetStaticMapRequestFilterSensitiveLog");
413
+ var GetStyleDescriptorRequestFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
414
+ ...obj,
415
+ ...obj.PoliticalView && { PoliticalView: import_smithy_client.SENSITIVE_STRING },
416
+ ...obj.Key && { Key: import_smithy_client.SENSITIVE_STRING }
417
+ }), "GetStyleDescriptorRequestFilterSensitiveLog");
418
+ var GetTileRequestFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
419
+ ...obj,
420
+ ...obj.Z && { Z: import_smithy_client.SENSITIVE_STRING },
421
+ ...obj.X && { X: import_smithy_client.SENSITIVE_STRING },
422
+ ...obj.Y && { Y: import_smithy_client.SENSITIVE_STRING },
423
+ ...obj.Key && { Key: import_smithy_client.SENSITIVE_STRING }
424
+ }), "GetTileRequestFilterSensitiveLog");
425
+
426
+ // src/protocols/Aws_restJson1.ts
427
+ var se_GetGlyphsCommand = /* @__PURE__ */ __name(async (input, context) => {
428
+ const b = (0, import_core.requestBuilder)(input, context);
429
+ const headers = {};
430
+ b.bp("/glyphs/{FontStack}/{FontUnicodeRange}");
431
+ b.p("FontStack", () => input.FontStack, "{FontStack}", false);
432
+ b.p("FontUnicodeRange", () => input.FontUnicodeRange, "{FontUnicodeRange}", false);
433
+ let body;
434
+ b.m("GET").h(headers).b(body);
435
+ return b.build();
436
+ }, "se_GetGlyphsCommand");
437
+ var se_GetSpritesCommand = /* @__PURE__ */ __name(async (input, context) => {
438
+ const b = (0, import_core.requestBuilder)(input, context);
439
+ const headers = {};
440
+ b.bp("/styles/{Style}/{ColorScheme}/{Variant}/sprites/{FileName}");
441
+ b.p("FileName", () => input.FileName, "{FileName}", false);
442
+ b.p("Style", () => input.Style, "{Style}", false);
443
+ b.p("ColorScheme", () => input.ColorScheme, "{ColorScheme}", false);
444
+ b.p("Variant", () => input.Variant, "{Variant}", false);
445
+ let body;
446
+ b.m("GET").h(headers).b(body);
447
+ return b.build();
448
+ }, "se_GetSpritesCommand");
449
+ var se_GetStaticMapCommand = /* @__PURE__ */ __name(async (input, context) => {
450
+ const b = (0, import_core.requestBuilder)(input, context);
451
+ const headers = {};
452
+ b.bp("/static/{FileName}");
453
+ b.p("FileName", () => input.FileName, "{FileName}", false);
454
+ const query = (0, import_smithy_client.map)({
455
+ [_bb]: [, input[_BB]],
456
+ [_bp]: [, input[_BP]],
457
+ [_c]: [, input[_C]],
458
+ [_cs]: [, input[_CS]],
459
+ [_co]: [, input[_CO]],
460
+ [_cl]: [() => input.CropLabels !== void 0, () => input[_CL].toString()],
461
+ [_go]: [, input[_GJO]],
462
+ [_h]: [(0, import_smithy_client.expectNonNull)(input.Height, `Height`) != null, () => input[_H].toString()],
463
+ [_k]: [, input[_K]],
464
+ [_ls]: [, input[_LS]],
465
+ [_l]: [, input[_L]],
466
+ [_p]: [() => input.Padding !== void 0, () => input[_P].toString()],
467
+ [_pv]: [, input[_PV]],
468
+ [_po]: [, input[_POI]],
469
+ [_r]: [() => input.Radius !== void 0, () => input[_R].toString()],
470
+ [_su]: [, input[_SBU]],
471
+ [_s]: [, input[_S]],
472
+ [_w]: [(0, import_smithy_client.expectNonNull)(input.Width, `Width`) != null, () => input[_W].toString()],
473
+ [_z]: [() => input.Zoom !== void 0, () => input[_Z] % 1 == 0 ? input[_Z] + ".0" : input[_Z].toString()]
474
+ });
475
+ let body;
476
+ b.m("GET").h(headers).q(query).b(body);
477
+ return b.build();
478
+ }, "se_GetStaticMapCommand");
479
+ var se_GetStyleDescriptorCommand = /* @__PURE__ */ __name(async (input, context) => {
480
+ const b = (0, import_core.requestBuilder)(input, context);
481
+ const headers = {};
482
+ b.bp("/styles/{Style}/descriptor");
483
+ b.p("Style", () => input.Style, "{Style}", false);
484
+ const query = (0, import_smithy_client.map)({
485
+ [_cs]: [, input[_CS]],
486
+ [_pv]: [, input[_PV]],
487
+ [_k]: [, input[_K]]
488
+ });
489
+ let body;
490
+ b.m("GET").h(headers).q(query).b(body);
491
+ return b.build();
492
+ }, "se_GetStyleDescriptorCommand");
493
+ var se_GetTileCommand = /* @__PURE__ */ __name(async (input, context) => {
494
+ const b = (0, import_core.requestBuilder)(input, context);
495
+ const headers = {};
496
+ b.bp("/tiles/{Tileset}/{Z}/{X}/{Y}");
497
+ b.p("Tileset", () => input.Tileset, "{Tileset}", false);
498
+ b.p("Z", () => input.Z, "{Z}", false);
499
+ b.p("X", () => input.X, "{X}", false);
500
+ b.p("Y", () => input.Y, "{Y}", false);
501
+ const query = (0, import_smithy_client.map)({
502
+ [_k]: [, input[_K]]
503
+ });
504
+ let body;
505
+ b.m("GET").h(headers).q(query).b(body);
506
+ return b.build();
507
+ }, "se_GetTileCommand");
508
+ var de_GetGlyphsCommand = /* @__PURE__ */ __name(async (output, context) => {
509
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
510
+ return de_CommandError(output, context);
511
+ }
512
+ const contents = (0, import_smithy_client.map)({
513
+ $metadata: deserializeMetadata(output),
514
+ [_CT]: [, output.headers[_ct]],
515
+ [_CC]: [, output.headers[_cc]],
516
+ [_ET]: [, output.headers[_e]]
517
+ });
518
+ const data = await (0, import_smithy_client.collectBody)(output.body, context);
519
+ contents.Blob = data;
520
+ return contents;
521
+ }, "de_GetGlyphsCommand");
522
+ var de_GetSpritesCommand = /* @__PURE__ */ __name(async (output, context) => {
523
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
524
+ return de_CommandError(output, context);
525
+ }
526
+ const contents = (0, import_smithy_client.map)({
527
+ $metadata: deserializeMetadata(output),
528
+ [_CT]: [, output.headers[_ct]],
529
+ [_CC]: [, output.headers[_cc]],
530
+ [_ET]: [, output.headers[_e]]
531
+ });
532
+ const data = await (0, import_smithy_client.collectBody)(output.body, context);
533
+ contents.Blob = data;
534
+ return contents;
535
+ }, "de_GetSpritesCommand");
536
+ var de_GetStaticMapCommand = /* @__PURE__ */ __name(async (output, context) => {
537
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
538
+ return de_CommandError(output, context);
539
+ }
540
+ const contents = (0, import_smithy_client.map)({
541
+ $metadata: deserializeMetadata(output),
542
+ [_CT]: [, output.headers[_ct]],
543
+ [_CC]: [, output.headers[_cc]],
544
+ [_ET]: [, output.headers[_e]],
545
+ [_PB]: [, output.headers[_xagpb]]
546
+ });
547
+ const data = await (0, import_smithy_client.collectBody)(output.body, context);
548
+ contents.Blob = data;
549
+ return contents;
550
+ }, "de_GetStaticMapCommand");
551
+ var de_GetStyleDescriptorCommand = /* @__PURE__ */ __name(async (output, context) => {
552
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
553
+ return de_CommandError(output, context);
554
+ }
555
+ const contents = (0, import_smithy_client.map)({
556
+ $metadata: deserializeMetadata(output),
557
+ [_CT]: [, output.headers[_ct]],
558
+ [_CC]: [, output.headers[_cc]],
559
+ [_ET]: [, output.headers[_e]]
560
+ });
561
+ const data = await (0, import_smithy_client.collectBody)(output.body, context);
562
+ contents.Blob = data;
563
+ return contents;
564
+ }, "de_GetStyleDescriptorCommand");
565
+ var de_GetTileCommand = /* @__PURE__ */ __name(async (output, context) => {
566
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
567
+ return de_CommandError(output, context);
568
+ }
569
+ const contents = (0, import_smithy_client.map)({
570
+ $metadata: deserializeMetadata(output),
571
+ [_CT]: [, output.headers[_ct]],
572
+ [_CC]: [, output.headers[_cc]],
573
+ [_ET]: [, output.headers[_e]],
574
+ [_PB]: [, output.headers[_xagpb]]
575
+ });
576
+ const data = await (0, import_smithy_client.collectBody)(output.body, context);
577
+ contents.Blob = data;
578
+ return contents;
579
+ }, "de_GetTileCommand");
580
+ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
581
+ const parsedOutput = {
582
+ ...output,
583
+ body: await (0, import_core2.parseJsonErrorBody)(output.body, context)
584
+ };
585
+ const errorCode = (0, import_core2.loadRestJsonErrorCode)(output, parsedOutput.body);
586
+ switch (errorCode) {
587
+ case "AccessDeniedException":
588
+ case "com.amazonaws.geomaps#AccessDeniedException":
589
+ throw await de_AccessDeniedExceptionRes(parsedOutput, context);
590
+ case "InternalServerException":
591
+ case "com.amazonaws.geomaps#InternalServerException":
592
+ throw await de_InternalServerExceptionRes(parsedOutput, context);
593
+ case "ThrottlingException":
594
+ case "com.amazonaws.geomaps#ThrottlingException":
595
+ throw await de_ThrottlingExceptionRes(parsedOutput, context);
596
+ case "ValidationException":
597
+ case "com.amazonaws.geomaps#ValidationException":
598
+ throw await de_ValidationExceptionRes(parsedOutput, context);
599
+ case "ResourceNotFoundException":
600
+ case "com.amazonaws.geomaps#ResourceNotFoundException":
601
+ throw await de_ResourceNotFoundExceptionRes(parsedOutput, context);
602
+ default:
603
+ const parsedBody = parsedOutput.body;
604
+ return throwDefaultError({
605
+ output,
606
+ parsedBody,
607
+ errorCode
608
+ });
609
+ }
610
+ }, "de_CommandError");
611
+ var throwDefaultError = (0, import_smithy_client.withBaseException)(GeoMapsServiceException);
612
+ var de_AccessDeniedExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
613
+ const contents = (0, import_smithy_client.map)({});
614
+ const data = parsedOutput.body;
615
+ const doc = (0, import_smithy_client.take)(data, {
616
+ Message: [, import_smithy_client.expectString, `message`]
617
+ });
618
+ Object.assign(contents, doc);
619
+ const exception = new AccessDeniedException({
620
+ $metadata: deserializeMetadata(parsedOutput),
621
+ ...contents
622
+ });
623
+ return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
624
+ }, "de_AccessDeniedExceptionRes");
625
+ var de_InternalServerExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
626
+ const contents = (0, import_smithy_client.map)({});
627
+ const data = parsedOutput.body;
628
+ const doc = (0, import_smithy_client.take)(data, {
629
+ Message: [, import_smithy_client.expectString, `message`]
630
+ });
631
+ Object.assign(contents, doc);
632
+ const exception = new InternalServerException({
633
+ $metadata: deserializeMetadata(parsedOutput),
634
+ ...contents
635
+ });
636
+ return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
637
+ }, "de_InternalServerExceptionRes");
638
+ var de_ResourceNotFoundExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
639
+ const contents = (0, import_smithy_client.map)({});
640
+ const data = parsedOutput.body;
641
+ const doc = (0, import_smithy_client.take)(data, {
642
+ Message: [, import_smithy_client.expectString, `message`]
643
+ });
644
+ Object.assign(contents, doc);
645
+ const exception = new ResourceNotFoundException({
646
+ $metadata: deserializeMetadata(parsedOutput),
647
+ ...contents
648
+ });
649
+ return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
650
+ }, "de_ResourceNotFoundExceptionRes");
651
+ var de_ThrottlingExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
652
+ const contents = (0, import_smithy_client.map)({});
653
+ const data = parsedOutput.body;
654
+ const doc = (0, import_smithy_client.take)(data, {
655
+ Message: [, import_smithy_client.expectString, `message`]
656
+ });
657
+ Object.assign(contents, doc);
658
+ const exception = new ThrottlingException({
659
+ $metadata: deserializeMetadata(parsedOutput),
660
+ ...contents
661
+ });
662
+ return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
663
+ }, "de_ThrottlingExceptionRes");
664
+ var de_ValidationExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, context) => {
665
+ const contents = (0, import_smithy_client.map)({});
666
+ const data = parsedOutput.body;
667
+ const doc = (0, import_smithy_client.take)(data, {
668
+ FieldList: [, (_) => de_ValidationExceptionFieldList(_, context), `fieldList`],
669
+ Message: [, import_smithy_client.expectString, `message`],
670
+ Reason: [, import_smithy_client.expectString, `reason`]
671
+ });
672
+ Object.assign(contents, doc);
673
+ const exception = new ValidationException({
674
+ $metadata: deserializeMetadata(parsedOutput),
675
+ ...contents
676
+ });
677
+ return (0, import_smithy_client.decorateServiceException)(exception, parsedOutput.body);
678
+ }, "de_ValidationExceptionRes");
679
+ var de_ValidationExceptionField = /* @__PURE__ */ __name((output, context) => {
680
+ return (0, import_smithy_client.take)(output, {
681
+ Message: [, import_smithy_client.expectString, `message`],
682
+ Name: [, import_smithy_client.expectString, `name`]
683
+ });
684
+ }, "de_ValidationExceptionField");
685
+ var de_ValidationExceptionFieldList = /* @__PURE__ */ __name((output, context) => {
686
+ const retVal = (output || []).filter((e) => e != null).map((entry) => {
687
+ return de_ValidationExceptionField(entry, context);
688
+ });
689
+ return retVal;
690
+ }, "de_ValidationExceptionFieldList");
691
+ var deserializeMetadata = /* @__PURE__ */ __name((output) => ({
692
+ httpStatusCode: output.statusCode,
693
+ requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
694
+ extendedRequestId: output.headers["x-amz-id-2"],
695
+ cfId: output.headers["x-amz-cf-id"]
696
+ }), "deserializeMetadata");
697
+ var _BB = "BoundingBox";
698
+ var _BP = "BoundedPositions";
699
+ var _C = "Center";
700
+ var _CC = "CacheControl";
701
+ var _CL = "CropLabels";
702
+ var _CO = "CompactOverlay";
703
+ var _CS = "ColorScheme";
704
+ var _CT = "ContentType";
705
+ var _ET = "ETag";
706
+ var _GJO = "GeoJsonOverlay";
707
+ var _H = "Height";
708
+ var _K = "Key";
709
+ var _L = "Language";
710
+ var _LS = "LabelSize";
711
+ var _P = "Padding";
712
+ var _PB = "PricingBucket";
713
+ var _POI = "PointsOfInterests";
714
+ var _PV = "PoliticalView";
715
+ var _R = "Radius";
716
+ var _S = "Style";
717
+ var _SBU = "ScaleBarUnit";
718
+ var _W = "Width";
719
+ var _Z = "Zoom";
720
+ var _bb = "bounding-box";
721
+ var _bp = "bounded-positions";
722
+ var _c = "center";
723
+ var _cc = "cache-control";
724
+ var _cl = "crop-labels";
725
+ var _co = "compact-overlay";
726
+ var _cs = "color-scheme";
727
+ var _ct = "content-type";
728
+ var _e = "etag";
729
+ var _go = "geojson-overlay";
730
+ var _h = "height";
731
+ var _k = "key";
732
+ var _l = "lang";
733
+ var _ls = "label-size";
734
+ var _p = "padding";
735
+ var _po = "pois";
736
+ var _pv = "political-view";
737
+ var _r = "radius";
738
+ var _s = "style";
739
+ var _su = "scale-unit";
740
+ var _w = "width";
741
+ var _xagpb = "x-amz-geo-pricing-bucket";
742
+ var _z = "zoom";
743
+
744
+ // src/commands/GetGlyphsCommand.ts
745
+ var GetGlyphsCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
746
+ return [
747
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
748
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
749
+ ];
750
+ }).s("MapsService", "GetGlyphs", {}).n("GeoMapsClient", "GetGlyphsCommand").f(void 0, void 0).ser(se_GetGlyphsCommand).de(de_GetGlyphsCommand).build() {
751
+ static {
752
+ __name(this, "GetGlyphsCommand");
753
+ }
754
+ };
755
+
756
+ // src/commands/GetSpritesCommand.ts
757
+
758
+
759
+
760
+ var GetSpritesCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
761
+ return [
762
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
763
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
764
+ ];
765
+ }).s("MapsService", "GetSprites", {}).n("GeoMapsClient", "GetSpritesCommand").f(void 0, void 0).ser(se_GetSpritesCommand).de(de_GetSpritesCommand).build() {
766
+ static {
767
+ __name(this, "GetSpritesCommand");
768
+ }
769
+ };
770
+
771
+ // src/commands/GetStaticMapCommand.ts
772
+
773
+
774
+
775
+ var GetStaticMapCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
776
+ return [
777
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
778
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
779
+ ];
780
+ }).s("MapsService", "GetStaticMap", {}).n("GeoMapsClient", "GetStaticMapCommand").f(GetStaticMapRequestFilterSensitiveLog, void 0).ser(se_GetStaticMapCommand).de(de_GetStaticMapCommand).build() {
781
+ static {
782
+ __name(this, "GetStaticMapCommand");
783
+ }
784
+ };
785
+
786
+ // src/commands/GetStyleDescriptorCommand.ts
787
+
788
+
789
+
790
+ var GetStyleDescriptorCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
791
+ return [
792
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
793
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
794
+ ];
795
+ }).s("MapsService", "GetStyleDescriptor", {}).n("GeoMapsClient", "GetStyleDescriptorCommand").f(GetStyleDescriptorRequestFilterSensitiveLog, void 0).ser(se_GetStyleDescriptorCommand).de(de_GetStyleDescriptorCommand).build() {
796
+ static {
797
+ __name(this, "GetStyleDescriptorCommand");
798
+ }
799
+ };
800
+
801
+ // src/commands/GetTileCommand.ts
802
+
803
+
804
+
805
+ var GetTileCommand = class extends import_smithy_client.Command.classBuilder().ep(commonParams).m(function(Command, cs, config, o) {
806
+ return [
807
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
808
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
809
+ ];
810
+ }).s("MapsService", "GetTile", {}).n("GeoMapsClient", "GetTileCommand").f(GetTileRequestFilterSensitiveLog, void 0).ser(se_GetTileCommand).de(de_GetTileCommand).build() {
811
+ static {
812
+ __name(this, "GetTileCommand");
813
+ }
814
+ };
815
+
816
+ // src/GeoMaps.ts
817
+ var commands = {
818
+ GetGlyphsCommand,
819
+ GetSpritesCommand,
820
+ GetStaticMapCommand,
821
+ GetStyleDescriptorCommand,
822
+ GetTileCommand
823
+ };
824
+ var GeoMaps = class extends GeoMapsClient {
825
+ static {
826
+ __name(this, "GeoMaps");
827
+ }
828
+ };
829
+ (0, import_smithy_client.createAggregatedClient)(commands, GeoMaps);
830
+ // Annotate the CommonJS export names for ESM import in node:
831
+
832
+ 0 && (module.exports = {
833
+ GeoMapsServiceException,
834
+ __Client,
835
+ GeoMapsClient,
836
+ GeoMaps,
837
+ $Command,
838
+ GetGlyphsCommand,
839
+ GetSpritesCommand,
840
+ GetStaticMapCommand,
841
+ GetStyleDescriptorCommand,
842
+ GetTileCommand,
843
+ AccessDeniedException,
844
+ ColorScheme,
845
+ MapStyle,
846
+ Variant,
847
+ LabelSize,
848
+ MapFeatureMode,
849
+ ScaleBarUnit,
850
+ StaticMapStyle,
851
+ InternalServerException,
852
+ ThrottlingException,
853
+ ValidationExceptionReason,
854
+ ValidationException,
855
+ ResourceNotFoundException,
856
+ GetStaticMapRequestFilterSensitiveLog,
857
+ GetStyleDescriptorRequestFilterSensitiveLog,
858
+ GetTileRequestFilterSensitiveLog
859
+ });
860
+