@junando/core 0.11.0 → 0.11.1

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 (44) hide show
  1. package/dist/index.d.ts +729 -1928
  2. package/dist/index.d.ts.map +1 -0
  3. package/dist/index.js +1866 -10363
  4. package/dist/index.js.map +1 -0
  5. package/dist/rolldown-runtime-D7D4PA-g.js +13 -0
  6. package/dist/shared/metrics/index.d.ts +29 -0
  7. package/dist/shared/metrics/index.d.ts.map +1 -0
  8. package/dist/shared/metrics/index.js +131 -0
  9. package/dist/shared/metrics/index.js.map +1 -0
  10. package/package.json +11 -11
  11. package/dist/chunk-3OJNTHWB.js +0 -225
  12. package/dist/chunk-5LNMHOUT.js +0 -229
  13. package/dist/chunk-72FU6SG6.js +0 -236
  14. package/dist/chunk-7SYJ764U.js +0 -579
  15. package/dist/chunk-AZU6S4RC.js +0 -11
  16. package/dist/chunk-BGPI5BQ5.js +0 -27
  17. package/dist/chunk-DKQSWD3S.js +0 -46
  18. package/dist/chunk-H4ND7Z4R.js +0 -504
  19. package/dist/chunk-HVICRLMN.js +0 -742
  20. package/dist/chunk-ID7PWYSN.js +0 -12
  21. package/dist/chunk-KU245W3C.js +0 -16
  22. package/dist/chunk-L67CO4EG.js +0 -1038
  23. package/dist/chunk-MLKGABMK.js +0 -9
  24. package/dist/chunk-MQ4JUE6V.js +0 -447
  25. package/dist/chunk-N5AJP37P.js +0 -385
  26. package/dist/chunk-SIDCDO4Q.js +0 -1315
  27. package/dist/chunk-TDZF3WAT.js +0 -3824
  28. package/dist/chunk-VMBT3R2K.js +0 -0
  29. package/dist/chunk-WWHXKECU.js +0 -100
  30. package/dist/chunk-ZKH7AMP3.js +0 -42
  31. package/dist/chunk-ZOU3QHNL.js +0 -28
  32. package/dist/dist-es-CBFEDVZZ.js +0 -493
  33. package/dist/dist-es-ROXOWRKX.js +0 -22
  34. package/dist/dist-es-S3QCFNII.js +0 -327
  35. package/dist/dist-es-SQCUDQ4Y.js +0 -90
  36. package/dist/dist-es-UWOSB3KA.js +0 -72
  37. package/dist/dist-es-VXERFT35.js +0 -172
  38. package/dist/dist-es-Y44CAW7E.js +0 -385
  39. package/dist/event-streams-2IMLK3TK.js +0 -252
  40. package/dist/event-streams-NLZW3NHF.js +0 -1376
  41. package/dist/loadSso-T6VCDGCZ.js +0 -558
  42. package/dist/signin-BC6ZNJCV.js +0 -653
  43. package/dist/sso-oidc-PTS5E3NX.js +0 -793
  44. package/dist/sts-JSJ57UXB.js +0 -6108
@@ -1,579 +0,0 @@
1
- import {
2
- FromStringShapeDeserializer,
3
- extendedEncodeURIComponent,
4
- splitHeader
5
- } from "./chunk-N5AJP37P.js";
6
- import {
7
- JsonCodec,
8
- dateToUtcString,
9
- loadRestJsonErrorCode
10
- } from "./chunk-HVICRLMN.js";
11
- import {
12
- HttpProtocol,
13
- LazyJsonString,
14
- NormalizedSchema,
15
- ProtocolLib,
16
- SerdeContext,
17
- collectBody,
18
- determineTimestampFormat,
19
- translateTraits,
20
- v4
21
- } from "./chunk-TDZF3WAT.js";
22
- import {
23
- sdkStreamMixin
24
- } from "./chunk-3OJNTHWB.js";
25
- import {
26
- toBase64
27
- } from "./chunk-H4ND7Z4R.js";
28
- import {
29
- fromUtf8,
30
- toUtf8
31
- } from "./chunk-ZKH7AMP3.js";
32
- import {
33
- HttpRequest
34
- } from "./chunk-5LNMHOUT.js";
35
-
36
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/serde/quote-header.js
37
- function quoteHeader(part) {
38
- if (part.includes(",") || part.includes('"')) {
39
- part = `"${part.replace(/"/g, '\\"')}"`;
40
- }
41
- return part;
42
- }
43
-
44
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/serde/split-every.js
45
- function splitEvery(value, delimiter, numDelimiters) {
46
- if (numDelimiters <= 0 || !Number.isInteger(numDelimiters)) {
47
- throw new Error("Invalid number of delimiters (" + numDelimiters + ") for splitEvery.");
48
- }
49
- const segments = value.split(delimiter);
50
- if (numDelimiters === 1) {
51
- return segments;
52
- }
53
- const compoundSegments = [];
54
- let currentSegment = "";
55
- for (let i = 0; i < segments.length; i++) {
56
- if (currentSegment === "") {
57
- currentSegment = segments[i];
58
- } else {
59
- currentSegment += delimiter + segments[i];
60
- }
61
- if ((i + 1) % numDelimiters === 0) {
62
- compoundSegments.push(currentSegment);
63
- currentSegment = "";
64
- }
65
- }
66
- if (currentSegment !== "") {
67
- compoundSegments.push(currentSegment);
68
- }
69
- return compoundSegments;
70
- }
71
-
72
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js
73
- var HttpBindingProtocol = class extends HttpProtocol {
74
- async serializeRequest(operationSchema, _input, context) {
75
- const input = _input && typeof _input === "object" ? _input : {};
76
- const serializer = this.serializer;
77
- const query = {};
78
- const headers = {};
79
- const endpoint = await context.endpoint();
80
- const ns = NormalizedSchema.of(operationSchema?.input);
81
- const payloadMemberNames = [];
82
- const payloadMemberSchemas = [];
83
- let hasNonHttpBindingMember = false;
84
- let payload;
85
- const request = new HttpRequest({
86
- protocol: "",
87
- hostname: "",
88
- port: void 0,
89
- path: "",
90
- fragment: void 0,
91
- query,
92
- headers,
93
- body: void 0
94
- });
95
- if (endpoint) {
96
- this.updateServiceEndpoint(request, endpoint);
97
- this.setHostPrefix(request, operationSchema, input);
98
- const opTraits = translateTraits(operationSchema.traits);
99
- if (opTraits.http) {
100
- request.method = opTraits.http[0];
101
- const [path, search] = opTraits.http[1].split("?");
102
- if (request.path == "/") {
103
- request.path = path;
104
- } else {
105
- request.path += path;
106
- }
107
- const traitSearchParams = new URLSearchParams(search ?? "");
108
- for (const [key, value] of traitSearchParams) {
109
- query[key] = value;
110
- }
111
- }
112
- }
113
- for (const [memberName, memberNs] of ns.structIterator()) {
114
- const memberTraits = memberNs.getMergedTraits() ?? {};
115
- const inputMemberValue = input[memberName];
116
- if (inputMemberValue == null && !memberNs.isIdempotencyToken()) {
117
- if (memberTraits.httpLabel) {
118
- if (request.path.includes(`{${memberName}+}`) || request.path.includes(`{${memberName}}`)) {
119
- throw new Error(`No value provided for input HTTP label: ${memberName}.`);
120
- }
121
- }
122
- continue;
123
- }
124
- if (memberTraits.httpPayload) {
125
- const isStreaming = memberNs.isStreaming();
126
- if (isStreaming) {
127
- const isEventStream = memberNs.isStructSchema();
128
- if (isEventStream) {
129
- if (input[memberName]) {
130
- payload = await this.serializeEventStream({
131
- eventStream: input[memberName],
132
- requestSchema: ns
133
- });
134
- }
135
- } else {
136
- payload = inputMemberValue;
137
- }
138
- } else {
139
- serializer.write(memberNs, inputMemberValue);
140
- payload = serializer.flush();
141
- }
142
- } else if (memberTraits.httpLabel) {
143
- serializer.write(memberNs, inputMemberValue);
144
- const replacement = serializer.flush();
145
- if (request.path.includes(`{${memberName}+}`)) {
146
- request.path = request.path.replace(`{${memberName}+}`, replacement.split("/").map(extendedEncodeURIComponent).join("/"));
147
- } else if (request.path.includes(`{${memberName}}`)) {
148
- request.path = request.path.replace(`{${memberName}}`, extendedEncodeURIComponent(replacement));
149
- }
150
- } else if (memberTraits.httpHeader) {
151
- serializer.write(memberNs, inputMemberValue);
152
- headers[memberTraits.httpHeader.toLowerCase()] = String(serializer.flush());
153
- } else if (typeof memberTraits.httpPrefixHeaders === "string") {
154
- for (const key in inputMemberValue) {
155
- const val = inputMemberValue[key];
156
- const amalgam = memberTraits.httpPrefixHeaders + key;
157
- serializer.write([memberNs.getValueSchema(), { httpHeader: amalgam }], val);
158
- headers[amalgam.toLowerCase()] = serializer.flush();
159
- }
160
- } else if (memberTraits.httpQuery || memberTraits.httpQueryParams) {
161
- this.serializeQuery(memberNs, inputMemberValue, query);
162
- } else {
163
- hasNonHttpBindingMember = true;
164
- payloadMemberNames.push(memberName);
165
- payloadMemberSchemas.push(memberNs);
166
- }
167
- }
168
- if (hasNonHttpBindingMember && input) {
169
- const [namespace, name] = (ns.getName(true) ?? "#Unknown").split("#");
170
- const requiredMembers = ns.getSchema()[6];
171
- const payloadSchema = [
172
- 3,
173
- namespace,
174
- name,
175
- ns.getMergedTraits(),
176
- payloadMemberNames,
177
- payloadMemberSchemas,
178
- void 0
179
- ];
180
- if (requiredMembers) {
181
- payloadSchema[6] = requiredMembers;
182
- } else {
183
- payloadSchema.pop();
184
- }
185
- serializer.write(payloadSchema, input);
186
- payload = serializer.flush();
187
- }
188
- request.headers = headers;
189
- request.query = query;
190
- request.body = payload;
191
- return request;
192
- }
193
- serializeQuery(ns, data, query) {
194
- const serializer = this.serializer;
195
- const traits = ns.getMergedTraits();
196
- if (traits.httpQueryParams) {
197
- for (const key in data) {
198
- if (!(key in query)) {
199
- const val = data[key];
200
- const valueSchema = ns.getValueSchema();
201
- Object.assign(valueSchema.getMergedTraits(), {
202
- ...traits,
203
- httpQuery: key,
204
- httpQueryParams: void 0
205
- });
206
- this.serializeQuery(valueSchema, val, query);
207
- }
208
- }
209
- return;
210
- }
211
- if (ns.isListSchema()) {
212
- const sparse = !!ns.getMergedTraits().sparse;
213
- const buffer = [];
214
- for (const item of data) {
215
- serializer.write([ns.getValueSchema(), traits], item);
216
- const serializable = serializer.flush();
217
- if (sparse || serializable !== void 0) {
218
- buffer.push(serializable);
219
- }
220
- }
221
- query[traits.httpQuery] = buffer;
222
- } else {
223
- serializer.write([ns, traits], data);
224
- query[traits.httpQuery] = serializer.flush();
225
- }
226
- }
227
- async deserializeResponse(operationSchema, context, response) {
228
- const deserializer = this.deserializer;
229
- const ns = NormalizedSchema.of(operationSchema.output);
230
- const dataObject = {};
231
- if (response.statusCode >= 300) {
232
- const bytes = await collectBody(response.body, context);
233
- if (bytes.byteLength > 0) {
234
- Object.assign(dataObject, await deserializer.read(15, bytes));
235
- }
236
- await this.handleError(operationSchema, context, response, dataObject, this.deserializeMetadata(response));
237
- throw new Error("@smithy/core/protocols - HTTP Protocol error handler failed to throw.");
238
- }
239
- for (const header in response.headers) {
240
- const value = response.headers[header];
241
- delete response.headers[header];
242
- response.headers[header.toLowerCase()] = value;
243
- }
244
- const nonHttpBindingMembers = await this.deserializeHttpMessage(ns, context, response, dataObject);
245
- if (nonHttpBindingMembers.length) {
246
- const bytes = await collectBody(response.body, context);
247
- if (bytes.byteLength > 0) {
248
- const dataFromBody = await deserializer.read(ns, bytes);
249
- for (const member of nonHttpBindingMembers) {
250
- if (dataFromBody[member] != null) {
251
- dataObject[member] = dataFromBody[member];
252
- }
253
- }
254
- }
255
- } else if (nonHttpBindingMembers.discardResponseBody) {
256
- await collectBody(response.body, context);
257
- }
258
- dataObject.$metadata = this.deserializeMetadata(response);
259
- return dataObject;
260
- }
261
- async deserializeHttpMessage(schema, context, response, arg4, arg5) {
262
- let dataObject;
263
- if (arg4 instanceof Set) {
264
- dataObject = arg5;
265
- } else {
266
- dataObject = arg4;
267
- }
268
- let discardResponseBody = true;
269
- const deserializer = this.deserializer;
270
- const ns = NormalizedSchema.of(schema);
271
- const nonHttpBindingMembers = [];
272
- for (const [memberName, memberSchema] of ns.structIterator()) {
273
- const memberTraits = memberSchema.getMemberTraits();
274
- if (memberTraits.httpPayload) {
275
- discardResponseBody = false;
276
- const isStreaming = memberSchema.isStreaming();
277
- if (isStreaming) {
278
- const isEventStream = memberSchema.isStructSchema();
279
- if (isEventStream) {
280
- dataObject[memberName] = await this.deserializeEventStream({
281
- response,
282
- responseSchema: ns
283
- });
284
- } else {
285
- dataObject[memberName] = sdkStreamMixin(response.body);
286
- }
287
- } else if (response.body) {
288
- const bytes = await collectBody(response.body, context);
289
- if (bytes.byteLength > 0) {
290
- dataObject[memberName] = await deserializer.read(memberSchema, bytes);
291
- }
292
- }
293
- } else if (memberTraits.httpHeader) {
294
- const key = String(memberTraits.httpHeader).toLowerCase();
295
- const value = response.headers[key];
296
- if (null != value) {
297
- if (memberSchema.isListSchema()) {
298
- const headerListValueSchema = memberSchema.getValueSchema();
299
- headerListValueSchema.getMergedTraits().httpHeader = key;
300
- let sections;
301
- if (headerListValueSchema.isTimestampSchema() && headerListValueSchema.getSchema() === 4) {
302
- sections = splitEvery(value, ",", 2);
303
- } else {
304
- sections = splitHeader(value);
305
- }
306
- const list = [];
307
- for (const section of sections) {
308
- list.push(await deserializer.read(headerListValueSchema, section.trim()));
309
- }
310
- dataObject[memberName] = list;
311
- } else {
312
- dataObject[memberName] = await deserializer.read(memberSchema, value);
313
- }
314
- }
315
- } else if (memberTraits.httpPrefixHeaders !== void 0) {
316
- dataObject[memberName] = {};
317
- for (const header in response.headers) {
318
- if (header.startsWith(memberTraits.httpPrefixHeaders)) {
319
- const value = response.headers[header];
320
- const valueSchema = memberSchema.getValueSchema();
321
- valueSchema.getMergedTraits().httpHeader = header;
322
- dataObject[memberName][header.slice(memberTraits.httpPrefixHeaders.length)] = await deserializer.read(valueSchema, value);
323
- }
324
- }
325
- } else if (memberTraits.httpResponseCode) {
326
- dataObject[memberName] = response.statusCode;
327
- } else {
328
- nonHttpBindingMembers.push(memberName);
329
- }
330
- }
331
- nonHttpBindingMembers.discardResponseBody = discardResponseBody;
332
- return nonHttpBindingMembers;
333
- }
334
- };
335
-
336
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/protocols/serde/HttpInterceptingShapeDeserializer.js
337
- var HttpInterceptingShapeDeserializer = class extends SerdeContext {
338
- codecDeserializer;
339
- stringDeserializer;
340
- constructor(codecDeserializer, codecSettings) {
341
- super();
342
- this.codecDeserializer = codecDeserializer;
343
- this.stringDeserializer = new FromStringShapeDeserializer(codecSettings);
344
- }
345
- setSerdeContext(serdeContext) {
346
- this.stringDeserializer.setSerdeContext(serdeContext);
347
- this.codecDeserializer.setSerdeContext(serdeContext);
348
- this.serdeContext = serdeContext;
349
- }
350
- read(schema, data) {
351
- const ns = NormalizedSchema.of(schema);
352
- const traits = ns.getMergedTraits();
353
- const toString = this.serdeContext?.utf8Encoder ?? toUtf8;
354
- if (traits.httpHeader || traits.httpResponseCode) {
355
- return this.stringDeserializer.read(ns, toString(data));
356
- }
357
- if (traits.httpPayload) {
358
- if (ns.isBlobSchema()) {
359
- const toBytes = this.serdeContext?.utf8Decoder ?? fromUtf8;
360
- if (typeof data === "string") {
361
- return toBytes(data);
362
- }
363
- return data;
364
- } else if (ns.isStringSchema()) {
365
- if ("byteLength" in data) {
366
- return toString(data);
367
- }
368
- return data;
369
- }
370
- }
371
- return this.codecDeserializer.read(ns, data);
372
- }
373
- };
374
-
375
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/protocols/serde/ToStringShapeSerializer.js
376
- var ToStringShapeSerializer = class extends SerdeContext {
377
- settings;
378
- stringBuffer = "";
379
- constructor(settings) {
380
- super();
381
- this.settings = settings;
382
- }
383
- write(schema, value) {
384
- const ns = NormalizedSchema.of(schema);
385
- switch (typeof value) {
386
- case "object":
387
- if (value === null) {
388
- this.stringBuffer = "null";
389
- return;
390
- }
391
- if (ns.isTimestampSchema()) {
392
- if (!(value instanceof Date)) {
393
- throw new Error(`@smithy/core/protocols - received non-Date value ${value} when schema expected Date in ${ns.getName(true)}`);
394
- }
395
- const format = determineTimestampFormat(ns, this.settings);
396
- switch (format) {
397
- case 5:
398
- this.stringBuffer = value.toISOString().replace(".000Z", "Z");
399
- break;
400
- case 6:
401
- this.stringBuffer = dateToUtcString(value);
402
- break;
403
- case 7:
404
- this.stringBuffer = String(value.getTime() / 1e3);
405
- break;
406
- default:
407
- console.warn("Missing timestamp format, using epoch seconds", value);
408
- this.stringBuffer = String(value.getTime() / 1e3);
409
- }
410
- return;
411
- }
412
- if (ns.isBlobSchema() && "byteLength" in value) {
413
- this.stringBuffer = (this.serdeContext?.base64Encoder ?? toBase64)(value);
414
- return;
415
- }
416
- if (ns.isListSchema() && Array.isArray(value)) {
417
- let buffer = "";
418
- for (const item of value) {
419
- this.write([ns.getValueSchema(), ns.getMergedTraits()], item);
420
- const headerItem = this.flush();
421
- const serialized = ns.getValueSchema().isTimestampSchema() ? headerItem : quoteHeader(headerItem);
422
- if (buffer !== "") {
423
- buffer += ", ";
424
- }
425
- buffer += serialized;
426
- }
427
- this.stringBuffer = buffer;
428
- return;
429
- }
430
- this.stringBuffer = JSON.stringify(value, null, 2);
431
- break;
432
- case "string":
433
- const mediaType = ns.getMergedTraits().mediaType;
434
- let intermediateValue = value;
435
- if (mediaType) {
436
- const isJson = mediaType === "application/json" || mediaType.endsWith("+json");
437
- if (isJson) {
438
- intermediateValue = LazyJsonString.from(intermediateValue);
439
- }
440
- if (ns.getMergedTraits().httpHeader) {
441
- this.stringBuffer = (this.serdeContext?.base64Encoder ?? toBase64)(intermediateValue.toString());
442
- return;
443
- }
444
- }
445
- this.stringBuffer = value;
446
- break;
447
- default:
448
- if (ns.isIdempotencyToken()) {
449
- this.stringBuffer = v4();
450
- } else {
451
- this.stringBuffer = String(value);
452
- }
453
- }
454
- }
455
- flush() {
456
- const buffer = this.stringBuffer;
457
- this.stringBuffer = "";
458
- return buffer;
459
- }
460
- };
461
-
462
- // ../../node_modules/.pnpm/@smithy+core@3.23.17/node_modules/@smithy/core/dist-es/submodules/protocols/serde/HttpInterceptingShapeSerializer.js
463
- var HttpInterceptingShapeSerializer = class {
464
- codecSerializer;
465
- stringSerializer;
466
- buffer;
467
- constructor(codecSerializer, codecSettings, stringSerializer = new ToStringShapeSerializer(codecSettings)) {
468
- this.codecSerializer = codecSerializer;
469
- this.stringSerializer = stringSerializer;
470
- }
471
- setSerdeContext(serdeContext) {
472
- this.codecSerializer.setSerdeContext(serdeContext);
473
- this.stringSerializer.setSerdeContext(serdeContext);
474
- }
475
- write(schema, value) {
476
- const ns = NormalizedSchema.of(schema);
477
- const traits = ns.getMergedTraits();
478
- if (traits.httpHeader || traits.httpLabel || traits.httpQuery) {
479
- this.stringSerializer.write(ns, value);
480
- this.buffer = this.stringSerializer.flush();
481
- return;
482
- }
483
- return this.codecSerializer.write(ns, value);
484
- }
485
- flush() {
486
- if (this.buffer !== void 0) {
487
- const buffer = this.buffer;
488
- this.buffer = void 0;
489
- return buffer;
490
- }
491
- return this.codecSerializer.flush();
492
- }
493
- };
494
-
495
- // ../../node_modules/.pnpm/@aws-sdk+core@3.974.8/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js
496
- var AwsRestJsonProtocol = class extends HttpBindingProtocol {
497
- serializer;
498
- deserializer;
499
- codec;
500
- mixin = new ProtocolLib();
501
- constructor({ defaultNamespace, errorTypeRegistries }) {
502
- super({
503
- defaultNamespace,
504
- errorTypeRegistries
505
- });
506
- const settings = {
507
- timestampFormat: {
508
- useTrait: true,
509
- default: 7
510
- },
511
- httpBindings: true,
512
- jsonName: true
513
- };
514
- this.codec = new JsonCodec(settings);
515
- this.serializer = new HttpInterceptingShapeSerializer(this.codec.createSerializer(), settings);
516
- this.deserializer = new HttpInterceptingShapeDeserializer(this.codec.createDeserializer(), settings);
517
- }
518
- getShapeId() {
519
- return "aws.protocols#restJson1";
520
- }
521
- getPayloadCodec() {
522
- return this.codec;
523
- }
524
- setSerdeContext(serdeContext) {
525
- this.codec.setSerdeContext(serdeContext);
526
- super.setSerdeContext(serdeContext);
527
- }
528
- async serializeRequest(operationSchema, input, context) {
529
- const request = await super.serializeRequest(operationSchema, input, context);
530
- const inputSchema = NormalizedSchema.of(operationSchema.input);
531
- if (!request.headers["content-type"]) {
532
- const contentType = this.mixin.resolveRestContentType(this.getDefaultContentType(), inputSchema);
533
- if (contentType) {
534
- request.headers["content-type"] = contentType;
535
- }
536
- }
537
- if (request.body == null && request.headers["content-type"] === this.getDefaultContentType()) {
538
- request.body = "{}";
539
- }
540
- return request;
541
- }
542
- async deserializeResponse(operationSchema, context, response) {
543
- const output = await super.deserializeResponse(operationSchema, context, response);
544
- const outputSchema = NormalizedSchema.of(operationSchema.output);
545
- for (const [name, member] of outputSchema.structIterator()) {
546
- if (member.getMemberTraits().httpPayload && !(name in output)) {
547
- output[name] = null;
548
- }
549
- }
550
- return output;
551
- }
552
- async handleError(operationSchema, context, response, dataObject, metadata) {
553
- const errorIdentifier = loadRestJsonErrorCode(response, dataObject) ?? "Unknown";
554
- this.mixin.compose(this.compositeErrorRegistry, errorIdentifier, this.options.defaultNamespace);
555
- const { errorSchema, errorMetadata } = await this.mixin.getErrorSchemaOrThrowBaseException(errorIdentifier, this.options.defaultNamespace, response, dataObject, metadata);
556
- const ns = NormalizedSchema.of(errorSchema);
557
- const message = dataObject.message ?? dataObject.Message ?? "UnknownError";
558
- const ErrorCtor = this.compositeErrorRegistry.getErrorCtor(errorSchema) ?? Error;
559
- const exception = new ErrorCtor(message);
560
- await this.deserializeHttpMessage(errorSchema, context, response, dataObject);
561
- const output = {};
562
- const errorDeserializer = this.codec.createDeserializer();
563
- for (const [name, member] of ns.structIterator()) {
564
- const target = member.getMergedTraits().jsonName ?? name;
565
- output[name] = errorDeserializer.readObject(member, dataObject[target]);
566
- }
567
- throw this.mixin.decorateServiceException(Object.assign(exception, errorMetadata, {
568
- $fault: ns.getMergedTraits().error,
569
- message
570
- }, output), dataObject);
571
- }
572
- getDefaultContentType() {
573
- return "application/json";
574
- }
575
- };
576
-
577
- export {
578
- AwsRestJsonProtocol
579
- };
@@ -1,11 +0,0 @@
1
- // ../../node_modules/.pnpm/@smithy+types@4.14.1/node_modules/@smithy/types/dist-es/profile.js
2
- var IniSectionType;
3
- (function(IniSectionType2) {
4
- IniSectionType2["PROFILE"] = "profile";
5
- IniSectionType2["SSO_SESSION"] = "sso-session";
6
- IniSectionType2["SERVICES"] = "services";
7
- })(IniSectionType || (IniSectionType = {}));
8
-
9
- export {
10
- IniSectionType
11
- };
@@ -1,27 +0,0 @@
1
- // ../../node_modules/.pnpm/@smithy+property-provider@4.2.14/node_modules/@smithy/property-provider/dist-es/ProviderError.js
2
- var ProviderError = class _ProviderError extends Error {
3
- name = "ProviderError";
4
- tryNextLink;
5
- constructor(message, options = true) {
6
- let logger;
7
- let tryNextLink = true;
8
- if (typeof options === "boolean") {
9
- logger = void 0;
10
- tryNextLink = options;
11
- } else if (options != null && typeof options === "object") {
12
- logger = options.logger;
13
- tryNextLink = options.tryNextLink ?? true;
14
- }
15
- super(message);
16
- this.tryNextLink = tryNextLink;
17
- Object.setPrototypeOf(this, _ProviderError.prototype);
18
- logger?.debug?.(`@smithy/property-provider ${tryNextLink ? "->" : "(!)"} ${message}`);
19
- }
20
- static from(error, options = true) {
21
- return Object.assign(new this(error.message, options), error);
22
- }
23
- };
24
-
25
- export {
26
- ProviderError
27
- };
@@ -1,46 +0,0 @@
1
- import {
2
- CredentialsProviderError
3
- } from "./chunk-KU245W3C.js";
4
- import {
5
- setCredentialFeature
6
- } from "./chunk-ID7PWYSN.js";
7
-
8
- // ../../node_modules/.pnpm/@aws-sdk+credential-provider-env@3.972.34/node_modules/@aws-sdk/credential-provider-env/dist-es/fromEnv.js
9
- var ENV_KEY = "AWS_ACCESS_KEY_ID";
10
- var ENV_SECRET = "AWS_SECRET_ACCESS_KEY";
11
- var ENV_SESSION = "AWS_SESSION_TOKEN";
12
- var ENV_EXPIRATION = "AWS_CREDENTIAL_EXPIRATION";
13
- var ENV_CREDENTIAL_SCOPE = "AWS_CREDENTIAL_SCOPE";
14
- var ENV_ACCOUNT_ID = "AWS_ACCOUNT_ID";
15
- var fromEnv = (init) => async () => {
16
- init?.logger?.debug("@aws-sdk/credential-provider-env - fromEnv");
17
- const accessKeyId = process.env[ENV_KEY];
18
- const secretAccessKey = process.env[ENV_SECRET];
19
- const sessionToken = process.env[ENV_SESSION];
20
- const expiry = process.env[ENV_EXPIRATION];
21
- const credentialScope = process.env[ENV_CREDENTIAL_SCOPE];
22
- const accountId = process.env[ENV_ACCOUNT_ID];
23
- if (accessKeyId && secretAccessKey) {
24
- const credentials = {
25
- accessKeyId,
26
- secretAccessKey,
27
- ...sessionToken && { sessionToken },
28
- ...expiry && { expiration: new Date(expiry) },
29
- ...credentialScope && { credentialScope },
30
- ...accountId && { accountId }
31
- };
32
- setCredentialFeature(credentials, "CREDENTIALS_ENV_VARS", "g");
33
- return credentials;
34
- }
35
- throw new CredentialsProviderError("Unable to find environment variable credentials.", { logger: init?.logger });
36
- };
37
-
38
- export {
39
- ENV_KEY,
40
- ENV_SECRET,
41
- ENV_SESSION,
42
- ENV_EXPIRATION,
43
- ENV_CREDENTIAL_SCOPE,
44
- ENV_ACCOUNT_ID,
45
- fromEnv
46
- };