@jerome-benoit/sap-ai-provider-v2 4.9.1 → 5.0.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 (32) hide show
  1. package/README.md +64 -51
  2. package/dist/{chunk-5ZKQJNHO.js → chunk-BIBSYTMU.js} +479 -215
  3. package/dist/chunk-BIBSYTMU.js.map +1 -0
  4. package/dist/{chunk-5JVF4555.js → chunk-FY2HO62O.js} +3 -3
  5. package/dist/{chunk-VHZSAQBJ.js → chunk-Q5JV4I6D.js} +2 -2
  6. package/dist/{chunk-4JIMBRMV.js → chunk-QDUZRLMI.js} +154 -20
  7. package/dist/chunk-QDUZRLMI.js.map +1 -0
  8. package/dist/{chunk-RJFB6VFO.js → chunk-TXZZURBA.js} +2 -2
  9. package/dist/{chunk-5EDF6MHL.js → chunk-WNR7DC4V.js} +5 -4
  10. package/dist/chunk-WNR7DC4V.js.map +1 -0
  11. package/dist/{foundation-models-embedding-model-strategy-VKBRG7RT.js → foundation-models-embedding-model-strategy-JJBN3TQI.js} +4 -4
  12. package/dist/{foundation-models-language-model-strategy-FBGKZSTU.js → foundation-models-language-model-strategy-6ELKE34K.js} +5 -5
  13. package/dist/index.cjs +702 -341
  14. package/dist/index.cjs.map +1 -1
  15. package/dist/index.d.cts +1634 -8
  16. package/dist/index.d.ts +1634 -8
  17. package/dist/index.js +13 -14
  18. package/dist/index.js.map +1 -1
  19. package/dist/{orchestration-embedding-model-strategy-DVPO2TP3.js → orchestration-embedding-model-strategy-QI72OB3E.js} +5 -5
  20. package/dist/{orchestration-language-model-strategy-KEJWB4E2.js → orchestration-language-model-strategy-X4FZNLSA.js} +38 -75
  21. package/dist/orchestration-language-model-strategy-X4FZNLSA.js.map +1 -0
  22. package/package.json +30 -22
  23. package/dist/chunk-4JIMBRMV.js.map +0 -1
  24. package/dist/chunk-5EDF6MHL.js.map +0 -1
  25. package/dist/chunk-5ZKQJNHO.js.map +0 -1
  26. package/dist/orchestration-language-model-strategy-KEJWB4E2.js.map +0 -1
  27. /package/dist/{chunk-5JVF4555.js.map → chunk-FY2HO62O.js.map} +0 -0
  28. /package/dist/{chunk-VHZSAQBJ.js.map → chunk-Q5JV4I6D.js.map} +0 -0
  29. /package/dist/{chunk-RJFB6VFO.js.map → chunk-TXZZURBA.js.map} +0 -0
  30. /package/dist/{foundation-models-embedding-model-strategy-VKBRG7RT.js.map → foundation-models-embedding-model-strategy-JJBN3TQI.js.map} +0 -0
  31. /package/dist/{foundation-models-language-model-strategy-FBGKZSTU.js.map → foundation-models-language-model-strategy-6ELKE34K.js.map} +0 -0
  32. /package/dist/{orchestration-embedding-model-strategy-DVPO2TP3.js.map → orchestration-embedding-model-strategy-QI72OB3E.js.map} +0 -0
@@ -23880,121 +23880,6 @@ var require_browser = __commonJS({
23880
23880
  }
23881
23881
  });
23882
23882
 
23883
- // node_modules/has-flag/index.js
23884
- var require_has_flag2 = __commonJS({
23885
- "node_modules/has-flag/index.js"(exports, module) {
23886
- "use strict";
23887
- module.exports = (flag, argv = process.argv) => {
23888
- const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
23889
- const position = argv.indexOf(prefix + flag);
23890
- const terminatorPosition = argv.indexOf("--");
23891
- return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
23892
- };
23893
- }
23894
- });
23895
-
23896
- // node_modules/supports-color/index.js
23897
- var require_supports_color = __commonJS({
23898
- "node_modules/supports-color/index.js"(exports, module) {
23899
- "use strict";
23900
- var os = __require("os");
23901
- var tty = __require("tty");
23902
- var hasFlag = require_has_flag2();
23903
- var { env } = process;
23904
- var forceColor;
23905
- if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) {
23906
- forceColor = 0;
23907
- } else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) {
23908
- forceColor = 1;
23909
- }
23910
- if ("FORCE_COLOR" in env) {
23911
- if (env.FORCE_COLOR === "true") {
23912
- forceColor = 1;
23913
- } else if (env.FORCE_COLOR === "false") {
23914
- forceColor = 0;
23915
- } else {
23916
- forceColor = env.FORCE_COLOR.length === 0 ? 1 : Math.min(parseInt(env.FORCE_COLOR, 10), 3);
23917
- }
23918
- }
23919
- function translateLevel(level) {
23920
- if (level === 0) {
23921
- return false;
23922
- }
23923
- return {
23924
- level,
23925
- hasBasic: true,
23926
- has256: level >= 2,
23927
- has16m: level >= 3
23928
- };
23929
- }
23930
- function supportsColor(haveStream, streamIsTTY) {
23931
- if (forceColor === 0) {
23932
- return 0;
23933
- }
23934
- if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) {
23935
- return 3;
23936
- }
23937
- if (hasFlag("color=256")) {
23938
- return 2;
23939
- }
23940
- if (haveStream && !streamIsTTY && forceColor === void 0) {
23941
- return 0;
23942
- }
23943
- const min = forceColor || 0;
23944
- if (env.TERM === "dumb") {
23945
- return min;
23946
- }
23947
- if (process.platform === "win32") {
23948
- const osRelease = os.release().split(".");
23949
- if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
23950
- return Number(osRelease[2]) >= 14931 ? 3 : 2;
23951
- }
23952
- return 1;
23953
- }
23954
- if ("CI" in env) {
23955
- if (["TRAVIS", "CIRCLECI", "APPVEYOR", "GITLAB_CI", "GITHUB_ACTIONS", "BUILDKITE"].some((sign) => sign in env) || env.CI_NAME === "codeship") {
23956
- return 1;
23957
- }
23958
- return min;
23959
- }
23960
- if ("TEAMCITY_VERSION" in env) {
23961
- return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
23962
- }
23963
- if (env.COLORTERM === "truecolor") {
23964
- return 3;
23965
- }
23966
- if ("TERM_PROGRAM" in env) {
23967
- const version2 = parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
23968
- switch (env.TERM_PROGRAM) {
23969
- case "iTerm.app":
23970
- return version2 >= 3 ? 3 : 2;
23971
- case "Apple_Terminal":
23972
- return 2;
23973
- }
23974
- }
23975
- if (/-256(color)?$/i.test(env.TERM)) {
23976
- return 2;
23977
- }
23978
- if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {
23979
- return 1;
23980
- }
23981
- if ("COLORTERM" in env) {
23982
- return 1;
23983
- }
23984
- return min;
23985
- }
23986
- function getSupportLevel(stream) {
23987
- const level = supportsColor(stream, stream && stream.isTTY);
23988
- return translateLevel(level);
23989
- }
23990
- module.exports = {
23991
- supportsColor: getSupportLevel,
23992
- stdout: translateLevel(supportsColor(true, tty.isatty(1))),
23993
- stderr: translateLevel(supportsColor(true, tty.isatty(2)))
23994
- };
23995
- }
23996
- });
23997
-
23998
23883
  // node_modules/debug/src/node.js
23999
23884
  var require_node3 = __commonJS({
24000
23885
  "node_modules/debug/src/node.js"(exports, module) {
@@ -24014,7 +23899,7 @@ var require_node3 = __commonJS({
24014
23899
  );
24015
23900
  exports.colors = [6, 2, 3, 4, 5, 1];
24016
23901
  try {
24017
- const supportsColor = require_supports_color();
23902
+ const supportsColor = __require("supports-color");
24018
23903
  if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
24019
23904
  exports.colors = [
24020
23905
  20,
@@ -25200,22 +25085,82 @@ var require_axios = __commonJS({
25200
25085
  var hasOwnProperty = (({
25201
25086
  hasOwnProperty: hasOwnProperty2
25202
25087
  }) => (obj, prop) => hasOwnProperty2.call(obj, prop))(Object.prototype);
25088
+ var isUnsafeObjectKey = (prop) => typeof prop === "string" && (prop === "__proto__" || prop === "constructor" || prop === "prototype");
25089
+ var isPrototypeBoundary = (obj, prototype2, source) => obj === Object.prototype || !source && prototype2 === null;
25090
+ var isSafeAndFullyMutable = (obj) => {
25091
+ if (!Object.isExtensible(obj)) {
25092
+ return false;
25093
+ }
25094
+ const props = Object.getOwnPropertyNames(obj);
25095
+ if (Object.getOwnPropertySymbols) {
25096
+ props.push(...Object.getOwnPropertySymbols(obj));
25097
+ }
25098
+ return props.every((prop) => {
25099
+ if (isUnsafeObjectKey(prop)) {
25100
+ return false;
25101
+ }
25102
+ const descriptor = Object.getOwnPropertyDescriptor(obj, prop);
25103
+ return !!descriptor && descriptor.configurable && descriptor.writable === true;
25104
+ });
25105
+ };
25203
25106
  var hasOwnInPrototypeChain = (thing, prop) => {
25204
25107
  let obj = thing;
25205
25108
  const seen = [];
25206
- while (obj != null && obj !== Object.prototype) {
25109
+ while (obj != null) {
25207
25110
  if (seen.indexOf(obj) !== -1) {
25208
25111
  return false;
25209
25112
  }
25210
25113
  seen.push(obj);
25114
+ const prototype2 = getPrototypeOf(obj);
25115
+ if (isPrototypeBoundary(obj, prototype2, obj === thing)) {
25116
+ return false;
25117
+ }
25211
25118
  if (hasOwnProperty(obj, prop)) {
25212
25119
  return true;
25213
25120
  }
25214
- obj = getPrototypeOf(obj);
25121
+ obj = prototype2;
25215
25122
  }
25216
25123
  return false;
25217
25124
  };
25218
25125
  var getSafeProp = (obj, prop) => obj != null && hasOwnInPrototypeChain(obj, prop) ? obj[prop] : void 0;
25126
+ var toSafeFlatObject = (thing) => {
25127
+ if (thing == null || typeof thing !== "object" && typeof thing !== "function") {
25128
+ return thing;
25129
+ }
25130
+ const sourcePrototype = getPrototypeOf(thing);
25131
+ if (sourcePrototype === null && isSafeAndFullyMutable(thing)) {
25132
+ return thing;
25133
+ }
25134
+ const result = /* @__PURE__ */ Object.create(null);
25135
+ const merged = /* @__PURE__ */ Object.create(null);
25136
+ const seen = [];
25137
+ let current = thing;
25138
+ while (current != null) {
25139
+ if (seen.indexOf(current) !== -1) {
25140
+ break;
25141
+ }
25142
+ seen.push(current);
25143
+ const prototype2 = current === thing ? sourcePrototype : getPrototypeOf(current);
25144
+ if (isPrototypeBoundary(current, prototype2, current === thing)) {
25145
+ break;
25146
+ }
25147
+ const props = Object.getOwnPropertyNames(current);
25148
+ if (Object.getOwnPropertySymbols) {
25149
+ props.push(...Object.getOwnPropertySymbols(current));
25150
+ }
25151
+ for (const prop of props) {
25152
+ if (isUnsafeObjectKey(prop)) {
25153
+ continue;
25154
+ }
25155
+ if (!hasOwnProperty(merged, prop)) {
25156
+ result[prop] = thing[prop];
25157
+ merged[prop] = true;
25158
+ }
25159
+ }
25160
+ current = prototype2;
25161
+ }
25162
+ return result;
25163
+ };
25219
25164
  var kindOf = /* @__PURE__ */ ((cache) => (thing) => {
25220
25165
  const str = toString2.call(thing);
25221
25166
  return cache[str] || (cache[str] = str.slice(8, -1).toLowerCase());
@@ -25252,9 +25197,9 @@ var require_axios = __commonJS({
25252
25197
  return false;
25253
25198
  }
25254
25199
  const prototype2 = getPrototypeOf(val);
25255
- return (prototype2 === null || prototype2 === Object.prototype || getPrototypeOf(prototype2) === null) && // Treat any genuine (non-Object.prototype-polluted) Symbol.toStringTag or
25256
- // Symbol.iterator as evidence the value is a tagged/iterable type rather
25257
- // than a plain object, while ignoring keys injected onto Object.prototype.
25200
+ return (prototype2 === null || prototype2 === Object.prototype || getPrototypeOf(prototype2) === null) && // Treat safe own/inherited Symbol.toStringTag or Symbol.iterator members as
25201
+ // evidence the value is tagged/iterable, while ignoring members reachable
25202
+ // only through shared or terminal prototype boundaries.
25258
25203
  !hasOwnInPrototypeChain(val, toStringTag) && !hasOwnInPrototypeChain(val, iterator);
25259
25204
  };
25260
25205
  var isEmptyObject = (val) => {
@@ -25666,6 +25611,7 @@ var require_axios = __commonJS({
25666
25611
  // an alias to avoid ESLint no-prototype-builtins detection
25667
25612
  hasOwnInPrototypeChain,
25668
25613
  getSafeProp,
25614
+ toSafeFlatObject,
25669
25615
  reduceDescriptors,
25670
25616
  freezeMethods,
25671
25617
  toObjectSet,
@@ -25746,7 +25692,7 @@ var require_axios = __commonJS({
25746
25692
  });
25747
25693
  return byteStringHeaders;
25748
25694
  }
25749
- var $internals = /* @__PURE__ */ Symbol("internals");
25695
+ var $internals$1 = /* @__PURE__ */ Symbol("internals");
25750
25696
  function normalizeHeader(header) {
25751
25697
  return header && String(header).trim().toLowerCase();
25752
25698
  }
@@ -26042,7 +25988,7 @@ var require_axios = __commonJS({
26042
25988
  return computed;
26043
25989
  }
26044
25990
  static accessor(header) {
26045
- const internals = this[$internals] = this[$internals] = {
25991
+ const internals = this[$internals$1] = this[$internals$1] = {
26046
25992
  accessors: {}
26047
25993
  };
26048
25994
  const accessors = internals.accessors;
@@ -26263,19 +26209,16 @@ var require_axios = __commonJS({
26263
26209
  throw new TypeError("target must be an object");
26264
26210
  }
26265
26211
  formData = formData || new (FormData$1 || FormData)();
26266
- options = utils$1.toFlatObject(options, {
26267
- metaTokens: true,
26268
- dots: false,
26269
- indexes: false
26270
- }, false, function defined(option, source) {
26271
- return !utils$1.isUndefined(source[option]);
26272
- });
26273
- const metaTokens = options.metaTokens;
26274
- const visitor = options.visitor || defaultVisitor;
26275
- const dots = options.dots;
26276
- const indexes = options.indexes;
26277
- const _Blob = options.Blob || typeof Blob !== "undefined" && Blob;
26278
- const maxDepth = options.maxDepth === void 0 ? DEFAULT_FORM_DATA_MAX_DEPTH : options.maxDepth;
26212
+ const option = (name, fallback) => {
26213
+ const value = utils$1.getSafeProp(options, name);
26214
+ return utils$1.isUndefined(value) ? fallback : value;
26215
+ };
26216
+ const metaTokens = option("metaTokens", true);
26217
+ const visitor = option("visitor") || defaultVisitor;
26218
+ const dots = option("dots", false);
26219
+ const indexes = option("indexes", false);
26220
+ const _Blob = option("Blob") || typeof Blob !== "undefined" && Blob;
26221
+ const maxDepth = option("maxDepth", DEFAULT_FORM_DATA_MAX_DEPTH);
26279
26222
  const useBlob = _Blob && utils$1.isSpecCompliantForm(formData);
26280
26223
  const stack = [];
26281
26224
  if (!utils$1.isFunction(visitor)) {
@@ -26434,9 +26377,47 @@ var require_axios = __commonJS({
26434
26377
  }
26435
26378
  return url2;
26436
26379
  }
26380
+ var $internals = /* @__PURE__ */ Symbol("internals");
26381
+ function countHandlers(handlers) {
26382
+ return handlers ? handlers.length : 0;
26383
+ }
26384
+ function trimHandlers(handlers) {
26385
+ if (!handlers) {
26386
+ return;
26387
+ }
26388
+ while (handlers.length && handlers[handlers.length - 1] === null) {
26389
+ handlers.pop();
26390
+ }
26391
+ }
26392
+ function syncHandlerEntries(manager, internals) {
26393
+ const handlers = manager.handlers;
26394
+ const length = countHandlers(handlers);
26395
+ if (handlers !== internals.handlersRef) {
26396
+ internals.handlersRef = handlers;
26397
+ internals.handlerEntries.clear();
26398
+ } else if (length !== internals.handlersLength) {
26399
+ if (!length) {
26400
+ internals.handlerEntries.clear();
26401
+ } else {
26402
+ internals.handlerEntries.forEach(function removeStaleEntry(entry, id) {
26403
+ if (handlers[entry.index] !== entry.handler) {
26404
+ internals.handlerEntries.delete(id);
26405
+ }
26406
+ });
26407
+ }
26408
+ }
26409
+ internals.handlersLength = length;
26410
+ }
26437
26411
  var InterceptorManager = class {
26438
26412
  constructor() {
26439
26413
  this.handlers = [];
26414
+ this[$internals] = {
26415
+ handlersRef: this.handlers,
26416
+ handlersLength: this.handlers.length,
26417
+ handlerEntries: /* @__PURE__ */ new Map(),
26418
+ iterationDepth: 0,
26419
+ nextId: 0
26420
+ };
26440
26421
  }
26441
26422
  /**
26442
26423
  * Add a new interceptor to the stack
@@ -26448,13 +26429,25 @@ var require_axios = __commonJS({
26448
26429
  * @return {Number} An ID used to remove interceptor later
26449
26430
  */
26450
26431
  use(fulfilled, rejected, options) {
26451
- this.handlers.push({
26432
+ const handler = {
26452
26433
  fulfilled,
26453
26434
  rejected,
26454
26435
  synchronous: options ? options.synchronous : false,
26455
26436
  runWhen: options ? options.runWhen : null
26437
+ };
26438
+ const internals = this[$internals];
26439
+ if (this.handlers == null) {
26440
+ this.handlers = [];
26441
+ }
26442
+ syncHandlerEntries(this, internals);
26443
+ const id = internals.nextId++;
26444
+ this.handlers.push(handler);
26445
+ internals.handlerEntries.set(id, {
26446
+ handler,
26447
+ index: this.handlers.length - 1
26456
26448
  });
26457
- return this.handlers.length - 1;
26449
+ internals.handlersLength = this.handlers.length;
26450
+ return id;
26458
26451
  }
26459
26452
  /**
26460
26453
  * Remove an interceptor from the stack
@@ -26464,8 +26457,19 @@ var require_axios = __commonJS({
26464
26457
  * @returns {void}
26465
26458
  */
26466
26459
  eject(id) {
26467
- if (this.handlers[id]) {
26468
- this.handlers[id] = null;
26460
+ const internals = this[$internals];
26461
+ syncHandlerEntries(this, internals);
26462
+ const entry = internals.handlerEntries.get(id);
26463
+ if (entry) {
26464
+ internals.handlerEntries.delete(id);
26465
+ if (this.handlers[entry.index] !== entry.handler) {
26466
+ return;
26467
+ }
26468
+ this.handlers[entry.index] = null;
26469
+ if (!internals.iterationDepth) {
26470
+ trimHandlers(this.handlers);
26471
+ internals.handlersLength = this.handlers.length;
26472
+ }
26469
26473
  }
26470
26474
  }
26471
26475
  /**
@@ -26476,6 +26480,7 @@ var require_axios = __commonJS({
26476
26480
  clear() {
26477
26481
  if (this.handlers) {
26478
26482
  this.handlers = [];
26483
+ syncHandlerEntries(this, this[$internals]);
26479
26484
  }
26480
26485
  }
26481
26486
  /**
@@ -26489,11 +26494,22 @@ var require_axios = __commonJS({
26489
26494
  * @returns {void}
26490
26495
  */
26491
26496
  forEach(fn) {
26492
- utils$1.forEach(this.handlers, function forEachHandler(h) {
26493
- if (h !== null) {
26494
- fn(h);
26497
+ const internals = this[$internals];
26498
+ syncHandlerEntries(this, internals);
26499
+ internals.iterationDepth++;
26500
+ try {
26501
+ utils$1.forEach(this.handlers, function forEachHandler(h) {
26502
+ if (h !== null) {
26503
+ fn(h);
26504
+ }
26505
+ });
26506
+ } finally {
26507
+ if (!--internals.iterationDepth) {
26508
+ syncHandlerEntries(this, internals);
26509
+ trimHandlers(this.handlers);
26510
+ internals.handlersLength = countHandlers(this.handlers);
26495
26511
  }
26496
- });
26512
+ }
26497
26513
  }
26498
26514
  };
26499
26515
  var transitionalDefaults = {
@@ -26629,6 +26645,7 @@ var require_axios = __commonJS({
26629
26645
  }
26630
26646
  return null;
26631
26647
  }
26648
+ var methodList = Object.freeze(["get", "delete", "head", "options", "post", "put", "patch", "purge", "link", "unlink", "query"]);
26632
26649
  var own = (obj, key) => obj != null && utils$1.hasOwnProp(obj, key) ? obj[key] : void 0;
26633
26650
  function stringifySafely(rawValue, parser, encoder) {
26634
26651
  if (utils$1.isString(rawValue)) {
@@ -26734,7 +26751,7 @@ var require_axios = __commonJS({
26734
26751
  }
26735
26752
  }
26736
26753
  };
26737
- utils$1.forEach(["delete", "get", "head", "post", "put", "patch", "query"], (method) => {
26754
+ utils$1.forEach(methodList, (method) => {
26738
26755
  defaults.headers[method] = {};
26739
26756
  });
26740
26757
  function transformData(fns, response) {
@@ -26791,18 +26808,18 @@ var require_axios = __commonJS({
26791
26808
  }
26792
26809
  return baseURL.slice(0, end) + "/" + relativeURL.replace(/^\/+/, "");
26793
26810
  }
26794
- var malformedHttpProtocol = /^https?:(?!\/\/)/i;
26795
- var httpProtocolControlCharacters = /[\t\n\r]/g;
26796
- function stripLeadingC0ControlOrSpace(url2) {
26797
- let i = 0;
26798
- while (i < url2.length && url2.charCodeAt(i) <= 32) {
26799
- i++;
26800
- }
26801
- return url2.slice(i);
26802
- }
26811
+ var urlParserControlCharacters = /[\t\n\r]/g;
26803
26812
  function normalizeURLForProtocolCheck(url2) {
26804
- return stripLeadingC0ControlOrSpace(url2).replace(httpProtocolControlCharacters, "");
26813
+ if (typeof url2 !== "string") {
26814
+ return url2;
26815
+ }
26816
+ let start = 0;
26817
+ while (start < url2.length && url2.charCodeAt(start) <= 32) {
26818
+ start++;
26819
+ }
26820
+ return url2.slice(start).replace(urlParserControlCharacters, "");
26805
26821
  }
26822
+ var malformedHttpProtocol = /^https?:(?!\/\/)/i;
26806
26823
  function redactFragment(fragment) {
26807
26824
  if (!fragment) {
26808
26825
  return fragment;
@@ -26903,12 +26920,12 @@ var require_axios = __commonJS({
26903
26920
  function getEnv(key) {
26904
26921
  return process.env[key.toLowerCase()] || process.env[key.toUpperCase()] || "";
26905
26922
  }
26906
- var VERSION2 = "1.19.0";
26923
+ var VERSION2 = "1.20.0";
26907
26924
  function parseProtocol(url2) {
26908
26925
  const match2 = /^([-+\w]{1,25}):(?:\/\/)?/.exec(url2);
26909
26926
  return match2 && match2[1] || "";
26910
26927
  }
26911
- var DATA_URL_PATTERN = /^([^,;]+\/[^,;]+)?((?:;[^,;=]+=[^,;]+)*)(;base64)?,([\s\S]*)$/;
26928
+ var DATA_URL_PATTERN = /^([^,;/]+\/[^,;/]+)?((?:;[^,;=]+=[^,;]+)*)(;base64)?,([\s\S]*)$/;
26912
26929
  function fromDataURI(uri, asBlob, options) {
26913
26930
  const _Blob = options && options.Blob || platform.classes.Blob;
26914
26931
  const protocol = parseProtocol(uri);
@@ -27185,7 +27202,7 @@ var require_axios = __commonJS({
27185
27202
  this.sessions = /* @__PURE__ */ Object.create(null);
27186
27203
  }
27187
27204
  getSession(authority, options) {
27188
- options = Object.assign({
27205
+ options = Object.assign(/* @__PURE__ */ Object.create(null), {
27189
27206
  sessionTimeout: 1e3
27190
27207
  }, options);
27191
27208
  let authoritySessions = this.sessions[authority];
@@ -27250,6 +27267,7 @@ var require_axios = __commonJS({
27250
27267
  };
27251
27268
  }
27252
27269
  session.once("close", removeSession);
27270
+ session.once("error", removeSession);
27253
27271
  let entry = [session, options];
27254
27272
  authoritySessions ? authoritySessions.push(entry) : authoritySessions = this.sessions[authority] = [entry];
27255
27273
  return session;
@@ -27268,6 +27286,13 @@ var require_axios = __commonJS({
27268
27286
  } : fn;
27269
27287
  };
27270
27288
  var LOOPBACK_HOSTNAMES = /* @__PURE__ */ new Set(["localhost", "0.0.0.0"]);
27289
+ var trimTrailingDots = (value) => {
27290
+ let end = value.length;
27291
+ while (end && value.charCodeAt(end - 1) === 46) {
27292
+ end--;
27293
+ }
27294
+ return end === value.length ? value : value.slice(0, end);
27295
+ };
27271
27296
  var isIPv4Loopback = (host) => {
27272
27297
  const parts = host.split(".");
27273
27298
  if (parts.length !== 4) return false;
@@ -27300,7 +27325,7 @@ var require_axios = __commonJS({
27300
27325
  if (h.charAt(0) === "[" && h.charAt(h.length - 1) === "]") {
27301
27326
  h = h.slice(1, -1);
27302
27327
  }
27303
- h = h.replace(/\.+$/, "");
27328
+ h = trimTrailingDots(h);
27304
27329
  if (!/^[0-9.xXa-fA-F]+$/.test(h)) return host;
27305
27330
  const parts = h.split(".");
27306
27331
  if (parts.some((p) => p === "")) return host;
@@ -27412,6 +27437,40 @@ var require_axios = __commonJS({
27412
27437
  }
27413
27438
  return host;
27414
27439
  };
27440
+ var IPV4_OCTET_RE = /^(?:0|[1-9]\d{0,2})$/;
27441
+ var ipv4ToBytes = (host) => {
27442
+ const parts = host.split(".");
27443
+ return parts.length === 4 && parts.every((part) => IPV4_OCTET_RE.test(part) && Number(part) <= 255) ? parts.map(Number) : null;
27444
+ };
27445
+ var IPV6_GROUP_RE = /^[0-9a-f]{1,4}$/i;
27446
+ var ipv6ToBytes = (host) => {
27447
+ const halves = host.split("::");
27448
+ if (halves.length > 2) {
27449
+ return null;
27450
+ }
27451
+ const groups = halves[0] ? halves[0].split(":") : [];
27452
+ if (halves.length === 2) {
27453
+ const rear = halves[1] ? halves[1].split(":") : [];
27454
+ const missing = 8 - groups.length - rear.length;
27455
+ if (missing < 1) {
27456
+ return null;
27457
+ }
27458
+ groups.push(...new Array(missing).fill("0"), ...rear);
27459
+ }
27460
+ if (groups.length !== 8 || groups.some((group) => !IPV6_GROUP_RE.test(group))) {
27461
+ return null;
27462
+ }
27463
+ return groups.flatMap((group) => {
27464
+ const value = Number.parseInt(group, 16);
27465
+ return [value >> 8 & 255, value & 255];
27466
+ });
27467
+ };
27468
+ var ipToBytes = (host) => {
27469
+ if (typeof host !== "string" || !host) {
27470
+ return null;
27471
+ }
27472
+ return host.indexOf(":") !== -1 ? ipv6ToBytes(host) : ipv4ToBytes(host);
27473
+ };
27415
27474
  var normalizeNoProxyHost = (hostname) => {
27416
27475
  if (!hostname) {
27417
27476
  return hostname;
@@ -27419,13 +27478,99 @@ var require_axios = __commonJS({
27419
27478
  if (hostname.charAt(0) === "[" && hostname.charAt(hostname.length - 1) === "]") {
27420
27479
  hostname = hostname.slice(1, -1);
27421
27480
  }
27422
- const trimmed = hostname.replace(/\.+$/, "");
27481
+ const trimmed = trimTrailingDots(hostname);
27423
27482
  const ipv4 = normalizeIPAddress(trimmed);
27424
27483
  if (ipv4 !== trimmed) {
27425
27484
  return ipv4;
27426
27485
  }
27427
27486
  return unmapIPv4MappedIPv6(trimmed);
27428
27487
  };
27488
+ var normalizeCidrBase = (input) => {
27489
+ let base2 = input;
27490
+ const startsBracket = base2.charAt(0) === "[";
27491
+ const endsBracket = base2.charAt(base2.length - 1) === "]";
27492
+ const hasBracket = base2.includes("[") || base2.includes("]");
27493
+ if (startsBracket || endsBracket) {
27494
+ if (!startsBracket || !endsBracket) {
27495
+ return null;
27496
+ }
27497
+ base2 = base2.slice(1, -1);
27498
+ if (base2.indexOf(":") === -1 || base2.includes("[") || base2.includes("]")) {
27499
+ return null;
27500
+ }
27501
+ } else if (hasBracket) {
27502
+ return null;
27503
+ }
27504
+ if (!base2 || base2.charAt(base2.length - 1) === ".") {
27505
+ return null;
27506
+ }
27507
+ const wasIPv6 = base2.indexOf(":") !== -1;
27508
+ if (wasIPv6) {
27509
+ try {
27510
+ base2 = new URL(`http://[${base2}]/`).hostname.slice(1, -1);
27511
+ } catch (_err) {
27512
+ return null;
27513
+ }
27514
+ } else {
27515
+ base2 = normalizeIPAddress(base2);
27516
+ if (!ipv4ToBytes(base2)) {
27517
+ return null;
27518
+ }
27519
+ }
27520
+ return {
27521
+ normalized: unmapIPv4MappedIPv6(base2),
27522
+ wasIPv6
27523
+ };
27524
+ };
27525
+ var CIDR_ENTRY_RE = /^(.+)\/(0|[1-9]\d{0,2})$/;
27526
+ var parseCidrEntry = (entry) => {
27527
+ if (entry.indexOf("/") === -1) {
27528
+ return void 0;
27529
+ }
27530
+ const match2 = CIDR_ENTRY_RE.exec(entry);
27531
+ if (!match2) {
27532
+ return null;
27533
+ }
27534
+ let prefix = Number(match2[2]);
27535
+ const parsedBase = normalizeCidrBase(match2[1]);
27536
+ if (!parsedBase) {
27537
+ return null;
27538
+ }
27539
+ const {
27540
+ normalized,
27541
+ wasIPv6
27542
+ } = parsedBase;
27543
+ if (wasIPv6 && normalized.indexOf(":") === -1) {
27544
+ if (prefix < 96) {
27545
+ return null;
27546
+ }
27547
+ prefix -= 96;
27548
+ }
27549
+ const bytes = ipToBytes(normalized);
27550
+ if (!bytes || prefix > bytes.length * 8) {
27551
+ return null;
27552
+ }
27553
+ return {
27554
+ bytes,
27555
+ prefix
27556
+ };
27557
+ };
27558
+ var isInSubnet = (addressBytes, networkBytes, prefix) => {
27559
+ const fullBytes = prefix >> 3;
27560
+ for (let i = 0; i < fullBytes; i++) {
27561
+ if (addressBytes[i] !== networkBytes[i]) {
27562
+ return false;
27563
+ }
27564
+ }
27565
+ const remainingBits = prefix & 7;
27566
+ if (remainingBits) {
27567
+ const mask = 255 << 8 - remainingBits & 255;
27568
+ if ((addressBytes[fullBytes] & mask) !== (networkBytes[fullBytes] & mask)) {
27569
+ return false;
27570
+ }
27571
+ }
27572
+ return true;
27573
+ };
27429
27574
  function shouldBypassProxy(location) {
27430
27575
  let parsed;
27431
27576
  try {
@@ -27442,6 +27587,7 @@ var require_axios = __commonJS({
27442
27587
  }
27443
27588
  const port = Number.parseInt(parsed.port, 10) || DEFAULT_PORTS[parsed.protocol.split(":", 1)[0]] || 0;
27444
27589
  const hostname = normalizeNoProxyHost(parsed.hostname.toLowerCase());
27590
+ const hostnameBytes = ipToBytes(hostname);
27445
27591
  return noProxy.split(/[\s,]+/).some((entry) => {
27446
27592
  if (!entry) {
27447
27593
  return false;
@@ -27449,6 +27595,10 @@ var require_axios = __commonJS({
27449
27595
  if (entry === "*") {
27450
27596
  return true;
27451
27597
  }
27598
+ const cidr = parseCidrEntry(entry);
27599
+ if (cidr !== void 0) {
27600
+ return cidr !== null && !!hostnameBytes && hostnameBytes.length === cidr.bytes.length && isInSubnet(hostnameBytes, cidr.bytes, cidr.prefix);
27601
+ }
27452
27602
  let [entryHost, entryPort] = parseNoProxyEntry(entry);
27453
27603
  entryHost = normalizeNoProxyHost(entryHost);
27454
27604
  if (!entryHost) {
@@ -27529,13 +27679,14 @@ var require_axios = __commonJS({
27529
27679
  }
27530
27680
  };
27531
27681
  const flush = () => lastArgs && invoke(lastArgs);
27532
- return [throttled, flush];
27682
+ const flushWith = (...args) => invoke(args);
27683
+ return [throttled, flush, flushWith];
27533
27684
  }
27534
27685
  var progressEventReducer = (listener, isDownloadStream, freq = 3) => {
27535
27686
  let bytesNotified = 0;
27536
27687
  const _speedometer = speedometer(50, 250);
27537
27688
  return throttle((e) => {
27538
- if (!e || typeof e.loaded !== "number") {
27689
+ if (!e || !utils$1.isNumber(e.loaded)) {
27539
27690
  return;
27540
27691
  }
27541
27692
  const rawLoaded = e.loaded;
@@ -27689,6 +27840,12 @@ var require_axios = __commonJS({
27689
27840
  var isHttps = /https:?/;
27690
27841
  var kAxiosSocketListener = /* @__PURE__ */ Symbol("axios.http.socketListener");
27691
27842
  var kAxiosCurrentReq = /* @__PURE__ */ Symbol("axios.http.currentReq");
27843
+ function handleSocketError(err) {
27844
+ const current = this[kAxiosCurrentReq];
27845
+ if (current && !current.destroyed) {
27846
+ current.destroy(err);
27847
+ }
27848
+ }
27692
27849
  var kAxiosInstalledTunnel = /* @__PURE__ */ Symbol("axios.http.installedTunnel");
27693
27850
  var tunnelingAgentCache = /* @__PURE__ */ new Map();
27694
27851
  var tunnelingAgentCacheUser = /* @__PURE__ */ new WeakMap();
@@ -27797,10 +27954,10 @@ var require_axios = __commonJS({
27797
27954
  return false;
27798
27955
  }
27799
27956
  }
27800
- function setProxy(options, configProxy, location, isRedirect, configHttpsAgent, configHttpAgent) {
27957
+ function setProxy(options, configProxy, location, isRedirect, configHttpsAgent, configHttpAgent, allowEnvProxy = true) {
27801
27958
  let proxy = configProxy;
27802
27959
  const proxyEnvAgent = getProxyEnvAgent(options, configHttpAgent, configHttpsAgent);
27803
- if (!proxy && proxy !== false && !isNodeEnvProxyEnabled(proxyEnvAgent)) {
27960
+ if (!proxy && proxy !== false && allowEnvProxy && !isNodeEnvProxyEnabled(proxyEnvAgent)) {
27804
27961
  const proxyUrl = getProxyForUrl(location);
27805
27962
  if (proxyUrl) {
27806
27963
  if (!shouldBypassProxy(location)) {
@@ -27891,8 +28048,9 @@ var require_axios = __commonJS({
27891
28048
  }
27892
28049
  }
27893
28050
  options.beforeRedirects.proxy = function beforeRedirect(redirectOptions) {
27894
- setProxy(redirectOptions, configProxy, redirectOptions.href, true, configHttpsAgent, configHttpAgent);
28051
+ setProxy(redirectOptions, configProxy, redirectOptions.href, true, configHttpsAgent, configHttpAgent, allowEnvProxy);
27895
28052
  };
28053
+ return Boolean(proxy || configProxy !== false && allowEnvProxy && isNodeEnvProxyEnabled(proxyEnvAgent));
27896
28054
  }
27897
28055
  var isHttpAdapterSupported = typeof process !== "undefined" && utils$1.kindOf(process) === "process";
27898
28056
  var wrapAsync = (asyncExecutor) => {
@@ -27920,7 +28078,7 @@ var require_axios = __commonJS({
27920
28078
  family
27921
28079
  }) => {
27922
28080
  if (!utils$1.isString(address)) {
27923
- throw TypeError("address must be a string");
28081
+ throw new AxiosError("address must be a string", AxiosError.ERR_BAD_OPTION_VALUE);
27924
28082
  }
27925
28083
  return {
27926
28084
  address,
@@ -27931,6 +28089,30 @@ var require_axios = __commonJS({
27931
28089
  address,
27932
28090
  family
27933
28091
  });
28092
+ var normalizedLookupCache = /* @__PURE__ */ new WeakMap();
28093
+ var normalizeLookup = (lookup) => {
28094
+ let normalized = normalizedLookupCache.get(lookup);
28095
+ if (normalized) {
28096
+ return normalized;
28097
+ }
28098
+ const callbackLookup = callbackify(lookup, (value) => utils$1.isArray(value) ? value : [value]);
28099
+ normalized = (hostname, opt, cb) => {
28100
+ callbackLookup(hostname, opt, (err, arg0, arg1) => {
28101
+ if (err) {
28102
+ return cb(err);
28103
+ }
28104
+ let addresses;
28105
+ try {
28106
+ addresses = utils$1.isArray(arg0) ? arg0.map((addr) => buildAddressEntry(addr)) : [buildAddressEntry(arg0, arg1)];
28107
+ } catch (error) {
28108
+ return cb(error);
28109
+ }
28110
+ opt.all ? cb(err, addresses) : cb(err, addresses[0].address, addresses[0].family);
28111
+ });
28112
+ };
28113
+ normalizedLookupCache.set(lookup, normalized);
28114
+ return normalized;
28115
+ };
27934
28116
  var http2Transport = {
27935
28117
  request(options, cb) {
27936
28118
  const authority = options.protocol + "//" + options.hostname + ":" + (options.port || (options.protocol === "https:" ? 443 : 80));
@@ -27975,6 +28157,7 @@ var require_axios = __commonJS({
27975
28157
  let family = own2("family");
27976
28158
  let httpVersion = own2("httpVersion");
27977
28159
  if (httpVersion === void 0) httpVersion = 1;
28160
+ const rawHttpVersion = httpVersion;
27978
28161
  let http2Options = own2("http2Options");
27979
28162
  const httpAgent = own2("httpAgent");
27980
28163
  const httpsAgent = own2("httpsAgent");
@@ -27991,25 +28174,20 @@ var require_axios = __commonJS({
27991
28174
  let rejected = false;
27992
28175
  let req;
27993
28176
  let connectPhaseTimer;
27994
- httpVersion = +httpVersion;
28177
+ try {
28178
+ httpVersion = +httpVersion;
28179
+ } catch (err) {
28180
+ throw new AxiosError("Invalid protocol version: value is not a number", AxiosError.ERR_BAD_OPTION_VALUE, config);
28181
+ }
27995
28182
  if (Number.isNaN(httpVersion)) {
27996
- throw TypeError(`Invalid protocol version: '${config.httpVersion}' is not a number`);
28183
+ throw new AxiosError(`Invalid protocol version: '${rawHttpVersion}' is not a number`, AxiosError.ERR_BAD_OPTION_VALUE, config);
27997
28184
  }
27998
28185
  if (httpVersion !== 1 && httpVersion !== 2) {
27999
- throw TypeError(`Unsupported protocol version '${httpVersion}'`);
28186
+ throw new AxiosError(`Unsupported protocol version '${httpVersion}'`, AxiosError.ERR_BAD_OPTION_VALUE, config);
28000
28187
  }
28001
28188
  const isHttp2 = httpVersion === 2;
28002
28189
  if (lookup) {
28003
- const _lookup = callbackify(lookup, (value) => utils$1.isArray(value) ? value : [value]);
28004
- lookup = (hostname, opt, cb) => {
28005
- _lookup(hostname, opt, (err, arg0, arg1) => {
28006
- if (err) {
28007
- return cb(err);
28008
- }
28009
- const addresses = utils$1.isArray(arg0) ? arg0.map((addr) => buildAddressEntry(addr)) : [buildAddressEntry(arg0, arg1)];
28010
- opt.all ? cb(err, addresses) : cb(err, addresses[0].address, addresses[0].family);
28011
- });
28012
- };
28190
+ lookup = normalizeLookup(lookup);
28013
28191
  }
28014
28192
  const abortEmitter = new events.EventEmitter();
28015
28193
  function abort(reason) {
@@ -28202,6 +28380,11 @@ var require_axios = __commonJS({
28202
28380
  }));
28203
28381
  }
28204
28382
  headers.set("Accept-Encoding", utils$1.hasOwnProp(transitional, "advertiseZstdAcceptEncoding") && transitional.advertiseZstdAcceptEncoding === true ? ACCEPT_ENCODING_WITH_ZSTD : ACCEPT_ENCODING, false);
28383
+ if (isHttp2 && lookup) {
28384
+ http2Options = Object.assign(/* @__PURE__ */ Object.create(null), http2Options, {
28385
+ lookup
28386
+ });
28387
+ }
28205
28388
  const options = Object.assign(/* @__PURE__ */ Object.create(null), {
28206
28389
  path: path$1,
28207
28390
  method,
@@ -28215,9 +28398,11 @@ var require_axios = __commonJS({
28215
28398
  family,
28216
28399
  beforeRedirect: dispatchBeforeRedirect,
28217
28400
  beforeRedirects: /* @__PURE__ */ Object.create(null),
28218
- http2Options
28401
+ http2Options,
28402
+ createConnection: void 0
28219
28403
  });
28220
28404
  !utils$1.isUndefined(lookup) && (options.lookup = lookup);
28405
+ let proxyApplied = false;
28221
28406
  if (socketPath) {
28222
28407
  if (typeof socketPath !== "string") {
28223
28408
  return reject(new AxiosError("socketPath must be a string", AxiosError.ERR_BAD_OPTION_VALUE, config));
@@ -28235,7 +28420,18 @@ var require_axios = __commonJS({
28235
28420
  } else {
28236
28421
  options.hostname = parsed.hostname.startsWith("[") ? parsed.hostname.slice(1, -1) : parsed.hostname;
28237
28422
  options.port = parsed.port;
28238
- setProxy(options, configProxy, protocol + "//" + parsed.hostname + (parsed.port ? ":" + parsed.port : "") + options.path, false, httpsAgent, httpAgent);
28423
+ proxyApplied = setProxy(
28424
+ options,
28425
+ configProxy,
28426
+ protocol + "//" + parsed.hostname + (parsed.port ? ":" + parsed.port : "") + options.path,
28427
+ false,
28428
+ httpsAgent,
28429
+ httpAgent,
28430
+ // The HTTP/2 transport connects independently of HTTP/1 agents, so it
28431
+ // cannot apply either axios-resolved or agent-local environment proxies.
28432
+ // Explicit proxy config is still processed and rejected below.
28433
+ !isHttp2
28434
+ );
28239
28435
  }
28240
28436
  let transport;
28241
28437
  let isNativeTransport = false;
@@ -28245,6 +28441,9 @@ var require_axios = __commonJS({
28245
28441
  options.agent = isHttpsRequest ? httpsAgent : httpAgent;
28246
28442
  }
28247
28443
  if (isHttp2) {
28444
+ if (proxyApplied) {
28445
+ return reject(new AxiosError("HTTP/2 requests with a proxy are not supported", AxiosError.ERR_NOT_SUPPORT, config));
28446
+ }
28248
28447
  transport = http2Transport;
28249
28448
  } else {
28250
28449
  const configTransport = own2("transport");
@@ -28442,12 +28641,7 @@ var require_axios = __commonJS({
28442
28641
  socket.setKeepAlive(true, 1e3 * 60);
28443
28642
  }
28444
28643
  if (!socket[kAxiosSocketListener]) {
28445
- socket.on("error", function handleSocketError(err) {
28446
- const current = socket[kAxiosCurrentReq];
28447
- if (current && !current.destroyed) {
28448
- current.destroy(err);
28449
- }
28450
- });
28644
+ socket.on("error", handleSocketError);
28451
28645
  socket[kAxiosSocketListener] = true;
28452
28646
  }
28453
28647
  socket[kAxiosCurrentReq] = req;
@@ -28663,7 +28857,7 @@ var require_axios = __commonJS({
28663
28857
  transformResponse: defaultToConfig2,
28664
28858
  paramsSerializer: defaultToConfig2,
28665
28859
  timeout: defaultToConfig2,
28666
- timeoutMessage: defaultToConfig2,
28860
+ timeoutErrorMessage: defaultToConfig2,
28667
28861
  withCredentials: defaultToConfig2,
28668
28862
  withXSRFToken: defaultToConfig2,
28669
28863
  adapter: defaultToConfig2,
@@ -28731,10 +28925,11 @@ var require_axios = __commonJS({
28731
28925
  }
28732
28926
  }
28733
28927
  if (utils$1.isFormData(data)) {
28928
+ const getHeaders = utils$1.getSafeProp(data, "getHeaders");
28734
28929
  if (platform.hasStandardBrowserEnv || platform.hasStandardBrowserWebWorkerEnv || utils$1.isReactNative(data)) {
28735
28930
  headers.setContentType(void 0);
28736
- } else if (utils$1.isFunction(data.getHeaders)) {
28737
- setFormDataHeaders(headers, data.getHeaders(), own2("formDataHeaderPolicy"));
28931
+ } else if (utils$1.isFunction(getHeaders)) {
28932
+ setFormDataHeaders(headers, getHeaders.call(data), own2("formDataHeaderPolicy"));
28738
28933
  }
28739
28934
  }
28740
28935
  if (platform.hasStandardBrowserEnv) {
@@ -28764,7 +28959,7 @@ var require_axios = __commonJS({
28764
28959
  } = _config;
28765
28960
  let onCanceled;
28766
28961
  let uploadThrottled, downloadThrottled;
28767
- let flushUpload, flushDownload;
28962
+ let flushUpload, flushDownload, flushDownloadWithEvent;
28768
28963
  function done() {
28769
28964
  flushUpload && flushUpload();
28770
28965
  flushDownload && flushDownload();
@@ -28774,7 +28969,27 @@ var require_axios = __commonJS({
28774
28969
  let request = new XMLHttpRequest();
28775
28970
  request.open(_config.method.toUpperCase(), _config.url, true);
28776
28971
  request.timeout = _config.timeout;
28777
- function onloadend() {
28972
+ function onloadend(event) {
28973
+ if (!request) {
28974
+ return;
28975
+ }
28976
+ if (request.status === 0 && (parseProtocol(normalizeURLForProtocolCheck(_config.url)) || parseProtocol(platform.origin)) !== "file" && !(request.responseURL && request.responseURL.startsWith("file:"))) {
28977
+ reject(new AxiosError("Request aborted", AxiosError.ECONNABORTED, config, request));
28978
+ done();
28979
+ request = null;
28980
+ return;
28981
+ }
28982
+ try {
28983
+ if (event) {
28984
+ flushDownloadWithEvent && flushDownloadWithEvent(event);
28985
+ } else {
28986
+ flushDownload && flushDownload();
28987
+ }
28988
+ } catch (err) {
28989
+ setTimeout(() => {
28990
+ throw err;
28991
+ });
28992
+ }
28778
28993
  if (!request) {
28779
28994
  return;
28780
28995
  }
@@ -28849,7 +29064,7 @@ var require_axios = __commonJS({
28849
29064
  request.responseType = _config.responseType;
28850
29065
  }
28851
29066
  if (onDownloadProgress) {
28852
- [downloadThrottled, flushDownload] = progressEventReducer(onDownloadProgress, true);
29067
+ [downloadThrottled, flushDownload, flushDownloadWithEvent] = progressEventReducer(onDownloadProgress, true);
28853
29068
  request.addEventListener("progress", downloadThrottled);
28854
29069
  }
28855
29070
  if (onUploadProgress && request.upload) {
@@ -29011,6 +29226,17 @@ var require_axios = __commonJS({
29011
29226
  });
29012
29227
  };
29013
29228
  var DEFAULT_CHUNK_SIZE = 64 * 1024;
29229
+ var DEFAULT_REQUEST_OPTIONS = {
29230
+ cache: "default",
29231
+ redirect: "follow",
29232
+ referrer: "about:client",
29233
+ referrerPolicy: "",
29234
+ mode: "cors",
29235
+ integrity: "",
29236
+ keepalive: false,
29237
+ priority: "auto",
29238
+ window: null
29239
+ };
29014
29240
  var {
29015
29241
  isFunction
29016
29242
  } = utils$1;
@@ -29139,7 +29365,8 @@ var require_axios = __commonJS({
29139
29365
  withCredentials = "same-origin",
29140
29366
  fetchOptions,
29141
29367
  maxContentLength,
29142
- maxBodyLength
29368
+ maxBodyLength,
29369
+ maxRedirects
29143
29370
  } = resolveConfig(config);
29144
29371
  const hasMaxContentLength = utils$1.isNumber(maxContentLength) && maxContentLength > -1;
29145
29372
  const hasMaxBodyLength = utils$1.isNumber(maxBodyLength) && maxBodyLength > -1;
@@ -29240,17 +29467,44 @@ var require_axios = __commonJS({
29240
29467
  }
29241
29468
  }
29242
29469
  headers.set("User-Agent", "axios/" + VERSION2, false);
29243
- const resolvedOptions = {
29244
- ...fetchOptions,
29470
+ const safeFetchOptions = fetchOptions == null ? fetchOptions : Object.assign(/* @__PURE__ */ Object.create(null), fetchOptions);
29471
+ if (safeFetchOptions) {
29472
+ delete safeFetchOptions.body;
29473
+ delete safeFetchOptions.headers;
29474
+ delete safeFetchOptions.method;
29475
+ delete safeFetchOptions.signal;
29476
+ delete safeFetchOptions.duplex;
29477
+ delete safeFetchOptions.credentials;
29478
+ }
29479
+ const resolvedOptions = Object.assign(/* @__PURE__ */ Object.create(null), safeFetchOptions, {
29245
29480
  signal: composedSignal,
29246
29481
  method: method.toUpperCase(),
29247
29482
  headers: toByteStringHeaderObject(headers.normalize()),
29248
29483
  body: data,
29249
29484
  duplex: "half",
29250
29485
  credentials: isCredentialsSupported ? withCredentials : void 0
29251
- };
29486
+ });
29487
+ if (isRequestSupported) {
29488
+ utils$1.forEach(DEFAULT_REQUEST_OPTIONS, (value, key) => {
29489
+ if (resolvedOptions[key] === void 0) {
29490
+ resolvedOptions[key] = value;
29491
+ }
29492
+ });
29493
+ if (resolvedOptions.signal === void 0) {
29494
+ resolvedOptions.signal = null;
29495
+ }
29496
+ if (resolvedOptions.body === void 0) {
29497
+ resolvedOptions.body = null;
29498
+ }
29499
+ }
29500
+ if (maxRedirects === 0) {
29501
+ resolvedOptions.redirect = "manual";
29502
+ if (safeFetchOptions) {
29503
+ safeFetchOptions.redirect = "manual";
29504
+ }
29505
+ }
29252
29506
  request = isRequestSupported && new Request(url2, resolvedOptions);
29253
- let response = await (isRequestSupported ? _fetch(request, fetchOptions) : _fetch(url2, resolvedOptions));
29507
+ let response = await (isRequestSupported ? _fetch(request, safeFetchOptions) : _fetch(url2, resolvedOptions));
29254
29508
  const responseHeaders = AxiosHeaders.from(response.headers);
29255
29509
  if (hasMaxContentLength) {
29256
29510
  const declaredLength = utils$1.toFiniteNumber(responseHeaders.getContentLength());
@@ -29442,9 +29696,10 @@ var require_axios = __commonJS({
29442
29696
  throw new CanceledError(null, config);
29443
29697
  }
29444
29698
  }
29445
- function dispatchRequest(config) {
29699
+ function dispatchRequest(_config) {
29700
+ const config = utils$1.toSafeFlatObject(_config);
29446
29701
  throwIfCancellationRequested(config);
29447
- config.headers = AxiosHeaders.from(config.headers);
29702
+ config.headers = AxiosHeaders.from(utils$1.getSafeProp(config, "headers"));
29448
29703
  config.data = transformData.call(config, config.transformRequest);
29449
29704
  if (["post", "put", "patch"].indexOf(config.method) !== -1) {
29450
29705
  config.headers.setContentType("application/x-www-form-urlencoded", false);
@@ -29552,16 +29807,15 @@ var require_axios = __commonJS({
29552
29807
  return await this._request(configOrUrl, config);
29553
29808
  } catch (err) {
29554
29809
  if (err instanceof Error) {
29555
- let dummy = {};
29556
- Error.captureStackTrace ? Error.captureStackTrace(dummy) : dummy = new Error();
29557
- const stack = (() => {
29558
- if (!dummy.stack) {
29559
- return "";
29560
- }
29561
- const firstNewlineIndex = dummy.stack.indexOf("\n");
29562
- return firstNewlineIndex === -1 ? "" : dummy.stack.slice(firstNewlineIndex + 1);
29563
- })();
29564
29810
  try {
29811
+ let dummy = {};
29812
+ Error.captureStackTrace ? Error.captureStackTrace(dummy) : dummy = new Error();
29813
+ const dummyStack = dummy.stack;
29814
+ let stack = "";
29815
+ if (typeof dummyStack === "string") {
29816
+ const firstNewlineIndex = dummyStack.indexOf("\n");
29817
+ stack = firstNewlineIndex === -1 ? "" : dummyStack.slice(firstNewlineIndex + 1);
29818
+ }
29565
29819
  if (!err.stack) {
29566
29820
  err.stack = stack;
29567
29821
  } else if (stack) {
@@ -29623,9 +29877,9 @@ var require_axios = __commonJS({
29623
29877
  baseUrl: validators.spelling("baseURL"),
29624
29878
  withXsrfToken: validators.spelling("withXSRFToken")
29625
29879
  }, true);
29626
- config.method = (config.method || this.defaults.method || "get").toLowerCase();
29880
+ config.method = (utils$1.getSafeProp(config, "method") || utils$1.getSafeProp(this.defaults, "method") || "get").toLowerCase();
29627
29881
  let contextHeaders = headers && utils$1.merge(headers.common, headers[config.method]);
29628
- headers && utils$1.forEach(["delete", "get", "head", "post", "put", "patch", "query", "common"], (method) => {
29882
+ headers && utils$1.forEach(methodList.concat("common"), (method) => {
29629
29883
  delete headers[method];
29630
29884
  });
29631
29885
  config.headers = AxiosHeaders.concat(contextHeaders, headers);
@@ -29872,14 +30126,22 @@ var require_axios = __commonJS({
29872
30126
  Gone: 410,
29873
30127
  LengthRequired: 411,
29874
30128
  PreconditionFailed: 412,
30129
+ /**
30130
+ * @deprecated Use `ContentTooLarge` instead.
30131
+ */
29875
30132
  PayloadTooLarge: 413,
30133
+ ContentTooLarge: 413,
29876
30134
  UriTooLong: 414,
29877
30135
  UnsupportedMediaType: 415,
29878
30136
  RangeNotSatisfiable: 416,
29879
30137
  ExpectationFailed: 417,
29880
30138
  ImATeapot: 418,
29881
30139
  MisdirectedRequest: 421,
30140
+ /**
30141
+ * @deprecated Use `UnprocessableContent` instead.
30142
+ */
29882
30143
  UnprocessableEntity: 422,
30144
+ UnprocessableContent: 422,
29883
30145
  Locked: 423,
29884
30146
  FailedDependency: 424,
29885
30147
  TooEarly: 425,
@@ -29908,7 +30170,9 @@ var require_axios = __commonJS({
29908
30170
  InvalidSslCertificate: 526
29909
30171
  };
29910
30172
  Object.entries(HttpStatusCode).forEach(([key, value]) => {
29911
- HttpStatusCode[value] = key;
30173
+ if (HttpStatusCode[value] === void 0) {
30174
+ HttpStatusCode[value] = key;
30175
+ }
29912
30176
  });
29913
30177
  function createInstance(defaultConfig) {
29914
30178
  const context = new Axios(defaultConfig);
@@ -30764,7 +31028,7 @@ function tryExtractSAPErrorFromMessage(message) {
30764
31028
  }
30765
31029
 
30766
31030
  // src/version.ts
30767
- var VERSION = true ? "4.9.1" : "0.0.0-test";
31031
+ var VERSION = true ? "5.0.0" : "0.0.0-test";
30768
31032
 
30769
31033
  export {
30770
31034
  __toESM,
@@ -30816,6 +31080,6 @@ mime-types/index.js:
30816
31080
  *)
30817
31081
 
30818
31082
  axios/dist/node/axios.cjs:
30819
- (*! Axios v1.19.0 Copyright (c) 2026 Matt Zabriskie and contributors *)
31083
+ (*! Axios v1.20.0 Copyright (c) 2026 Matt Zabriskie and contributors *)
30820
31084
  */
30821
- //# sourceMappingURL=chunk-5ZKQJNHO.js.map
31085
+ //# sourceMappingURL=chunk-BIBSYTMU.js.map