@t2000/cli 5.22.0 → 5.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,18 +1,18 @@
1
1
  import { createRequire as __createRequire } from 'module'; import { fileURLToPath as __fileURLToPath } from 'url'; import { dirname as __pathDirname } from 'path'; const require = __createRequire(import.meta.url); const __filename = __fileURLToPath(import.meta.url); const __dirname = __pathDirname(__filename);
2
2
  import {
3
3
  SuiGrpcClient
4
- } from "./chunk-5AD7I65O.js";
4
+ } from "./chunk-R6QER65C.js";
5
5
  import {
6
6
  Transaction,
7
7
  coinWithBalance
8
- } from "./chunk-TP3M7BAU.js";
8
+ } from "./chunk-JEIOQF6Q.js";
9
9
  import {
10
10
  SUI_CLOCK_OBJECT_ID,
11
11
  suiBcs
12
- } from "./chunk-X6ON6NN5.js";
12
+ } from "./chunk-5MAY6SK7.js";
13
13
  import {
14
14
  normalizeSuiObjectId
15
- } from "./chunk-I2DCISQP.js";
15
+ } from "./chunk-D3DUYZYR.js";
16
16
  import {
17
17
  __commonJS,
18
18
  __export,
@@ -12834,9 +12834,459 @@ var require_src = __commonJS({
12834
12834
  }
12835
12835
  });
12836
12836
 
12837
- // ../../node_modules/.pnpm/follow-redirects@1.15.11/node_modules/follow-redirects/debug.js
12837
+ // ../../node_modules/.pnpm/agent-base@6.0.2/node_modules/agent-base/dist/src/promisify.js
12838
+ var require_promisify = __commonJS({
12839
+ "../../node_modules/.pnpm/agent-base@6.0.2/node_modules/agent-base/dist/src/promisify.js"(exports) {
12840
+ "use strict";
12841
+ Object.defineProperty(exports, "__esModule", { value: true });
12842
+ function promisify(fn) {
12843
+ return function(req, opts) {
12844
+ return new Promise((resolve, reject) => {
12845
+ fn.call(this, req, opts, (err, rtn) => {
12846
+ if (err) {
12847
+ reject(err);
12848
+ } else {
12849
+ resolve(rtn);
12850
+ }
12851
+ });
12852
+ });
12853
+ };
12854
+ }
12855
+ exports.default = promisify;
12856
+ }
12857
+ });
12858
+
12859
+ // ../../node_modules/.pnpm/agent-base@6.0.2/node_modules/agent-base/dist/src/index.js
12860
+ var require_src2 = __commonJS({
12861
+ "../../node_modules/.pnpm/agent-base@6.0.2/node_modules/agent-base/dist/src/index.js"(exports, module) {
12862
+ "use strict";
12863
+ var __importDefault = exports && exports.__importDefault || function(mod2) {
12864
+ return mod2 && mod2.__esModule ? mod2 : { "default": mod2 };
12865
+ };
12866
+ var events_1 = __require("events");
12867
+ var debug_1 = __importDefault(require_src());
12868
+ var promisify_1 = __importDefault(require_promisify());
12869
+ var debug = debug_1.default("agent-base");
12870
+ function isAgent(v) {
12871
+ return Boolean(v) && typeof v.addRequest === "function";
12872
+ }
12873
+ function isSecureEndpoint() {
12874
+ const { stack } = new Error();
12875
+ if (typeof stack !== "string")
12876
+ return false;
12877
+ return stack.split("\n").some((l2) => l2.indexOf("(https.js:") !== -1 || l2.indexOf("node:https:") !== -1);
12878
+ }
12879
+ function createAgent(callback, opts) {
12880
+ return new createAgent.Agent(callback, opts);
12881
+ }
12882
+ (function(createAgent2) {
12883
+ class Agent extends events_1.EventEmitter {
12884
+ constructor(callback, _opts) {
12885
+ super();
12886
+ let opts = _opts;
12887
+ if (typeof callback === "function") {
12888
+ this.callback = callback;
12889
+ } else if (callback) {
12890
+ opts = callback;
12891
+ }
12892
+ this.timeout = null;
12893
+ if (opts && typeof opts.timeout === "number") {
12894
+ this.timeout = opts.timeout;
12895
+ }
12896
+ this.maxFreeSockets = 1;
12897
+ this.maxSockets = 1;
12898
+ this.maxTotalSockets = Infinity;
12899
+ this.sockets = {};
12900
+ this.freeSockets = {};
12901
+ this.requests = {};
12902
+ this.options = {};
12903
+ }
12904
+ get defaultPort() {
12905
+ if (typeof this.explicitDefaultPort === "number") {
12906
+ return this.explicitDefaultPort;
12907
+ }
12908
+ return isSecureEndpoint() ? 443 : 80;
12909
+ }
12910
+ set defaultPort(v) {
12911
+ this.explicitDefaultPort = v;
12912
+ }
12913
+ get protocol() {
12914
+ if (typeof this.explicitProtocol === "string") {
12915
+ return this.explicitProtocol;
12916
+ }
12917
+ return isSecureEndpoint() ? "https:" : "http:";
12918
+ }
12919
+ set protocol(v) {
12920
+ this.explicitProtocol = v;
12921
+ }
12922
+ callback(req, opts, fn) {
12923
+ throw new Error('"agent-base" has no default implementation, you must subclass and override `callback()`');
12924
+ }
12925
+ /**
12926
+ * Called by node-core's "_http_client.js" module when creating
12927
+ * a new HTTP request with this Agent instance.
12928
+ *
12929
+ * @api public
12930
+ */
12931
+ addRequest(req, _opts) {
12932
+ const opts = Object.assign({}, _opts);
12933
+ if (typeof opts.secureEndpoint !== "boolean") {
12934
+ opts.secureEndpoint = isSecureEndpoint();
12935
+ }
12936
+ if (opts.host == null) {
12937
+ opts.host = "localhost";
12938
+ }
12939
+ if (opts.port == null) {
12940
+ opts.port = opts.secureEndpoint ? 443 : 80;
12941
+ }
12942
+ if (opts.protocol == null) {
12943
+ opts.protocol = opts.secureEndpoint ? "https:" : "http:";
12944
+ }
12945
+ if (opts.host && opts.path) {
12946
+ delete opts.path;
12947
+ }
12948
+ delete opts.agent;
12949
+ delete opts.hostname;
12950
+ delete opts._defaultAgent;
12951
+ delete opts.defaultPort;
12952
+ delete opts.createConnection;
12953
+ req._last = true;
12954
+ req.shouldKeepAlive = false;
12955
+ let timedOut = false;
12956
+ let timeoutId = null;
12957
+ const timeoutMs = opts.timeout || this.timeout;
12958
+ const onerror = (err) => {
12959
+ if (req._hadError)
12960
+ return;
12961
+ req.emit("error", err);
12962
+ req._hadError = true;
12963
+ };
12964
+ const ontimeout = () => {
12965
+ timeoutId = null;
12966
+ timedOut = true;
12967
+ const err = new Error(`A "socket" was not created for HTTP request before ${timeoutMs}ms`);
12968
+ err.code = "ETIMEOUT";
12969
+ onerror(err);
12970
+ };
12971
+ const callbackError = (err) => {
12972
+ if (timedOut)
12973
+ return;
12974
+ if (timeoutId !== null) {
12975
+ clearTimeout(timeoutId);
12976
+ timeoutId = null;
12977
+ }
12978
+ onerror(err);
12979
+ };
12980
+ const onsocket = (socket) => {
12981
+ if (timedOut)
12982
+ return;
12983
+ if (timeoutId != null) {
12984
+ clearTimeout(timeoutId);
12985
+ timeoutId = null;
12986
+ }
12987
+ if (isAgent(socket)) {
12988
+ debug("Callback returned another Agent instance %o", socket.constructor.name);
12989
+ socket.addRequest(req, opts);
12990
+ return;
12991
+ }
12992
+ if (socket) {
12993
+ socket.once("free", () => {
12994
+ this.freeSocket(socket, opts);
12995
+ });
12996
+ req.onSocket(socket);
12997
+ return;
12998
+ }
12999
+ const err = new Error(`no Duplex stream was returned to agent-base for \`${req.method} ${req.path}\``);
13000
+ onerror(err);
13001
+ };
13002
+ if (typeof this.callback !== "function") {
13003
+ onerror(new Error("`callback` is not defined"));
13004
+ return;
13005
+ }
13006
+ if (!this.promisifiedCallback) {
13007
+ if (this.callback.length >= 3) {
13008
+ debug("Converting legacy callback function to promise");
13009
+ this.promisifiedCallback = promisify_1.default(this.callback);
13010
+ } else {
13011
+ this.promisifiedCallback = this.callback;
13012
+ }
13013
+ }
13014
+ if (typeof timeoutMs === "number" && timeoutMs > 0) {
13015
+ timeoutId = setTimeout(ontimeout, timeoutMs);
13016
+ }
13017
+ if ("port" in opts && typeof opts.port !== "number") {
13018
+ opts.port = Number(opts.port);
13019
+ }
13020
+ try {
13021
+ debug("Resolving socket for %o request: %o", opts.protocol, `${req.method} ${req.path}`);
13022
+ Promise.resolve(this.promisifiedCallback(req, opts)).then(onsocket, callbackError);
13023
+ } catch (err) {
13024
+ Promise.reject(err).catch(callbackError);
13025
+ }
13026
+ }
13027
+ freeSocket(socket, opts) {
13028
+ debug("Freeing socket %o %o", socket.constructor.name, opts);
13029
+ socket.destroy();
13030
+ }
13031
+ destroy() {
13032
+ debug("Destroying agent %o", this.constructor.name);
13033
+ }
13034
+ }
13035
+ createAgent2.Agent = Agent;
13036
+ createAgent2.prototype = createAgent2.Agent.prototype;
13037
+ })(createAgent || (createAgent = {}));
13038
+ module.exports = createAgent;
13039
+ }
13040
+ });
13041
+
13042
+ // ../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/parse-proxy-response.js
13043
+ var require_parse_proxy_response = __commonJS({
13044
+ "../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/parse-proxy-response.js"(exports) {
13045
+ "use strict";
13046
+ var __importDefault = exports && exports.__importDefault || function(mod2) {
13047
+ return mod2 && mod2.__esModule ? mod2 : { "default": mod2 };
13048
+ };
13049
+ Object.defineProperty(exports, "__esModule", { value: true });
13050
+ var debug_1 = __importDefault(require_src());
13051
+ var debug = debug_1.default("https-proxy-agent:parse-proxy-response");
13052
+ function parseProxyResponse(socket) {
13053
+ return new Promise((resolve, reject) => {
13054
+ let buffersLength = 0;
13055
+ const buffers = [];
13056
+ function read() {
13057
+ const b = socket.read();
13058
+ if (b)
13059
+ ondata(b);
13060
+ else
13061
+ socket.once("readable", read);
13062
+ }
13063
+ function cleanup() {
13064
+ socket.removeListener("end", onend);
13065
+ socket.removeListener("error", onerror);
13066
+ socket.removeListener("close", onclose);
13067
+ socket.removeListener("readable", read);
13068
+ }
13069
+ function onclose(err) {
13070
+ debug("onclose had error %o", err);
13071
+ }
13072
+ function onend() {
13073
+ debug("onend");
13074
+ }
13075
+ function onerror(err) {
13076
+ cleanup();
13077
+ debug("onerror %o", err);
13078
+ reject(err);
13079
+ }
13080
+ function ondata(b) {
13081
+ buffers.push(b);
13082
+ buffersLength += b.length;
13083
+ const buffered = Buffer.concat(buffers, buffersLength);
13084
+ const endOfHeaders = buffered.indexOf("\r\n\r\n");
13085
+ if (endOfHeaders === -1) {
13086
+ debug("have not received end of HTTP headers yet...");
13087
+ read();
13088
+ return;
13089
+ }
13090
+ const firstLine = buffered.toString("ascii", 0, buffered.indexOf("\r\n"));
13091
+ const statusCode = +firstLine.split(" ")[1];
13092
+ debug("got proxy server response: %o", firstLine);
13093
+ resolve({
13094
+ statusCode,
13095
+ buffered
13096
+ });
13097
+ }
13098
+ socket.on("error", onerror);
13099
+ socket.on("close", onclose);
13100
+ socket.on("end", onend);
13101
+ read();
13102
+ });
13103
+ }
13104
+ exports.default = parseProxyResponse;
13105
+ }
13106
+ });
13107
+
13108
+ // ../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/agent.js
13109
+ var require_agent = __commonJS({
13110
+ "../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/agent.js"(exports) {
13111
+ "use strict";
13112
+ var __awaiter = exports && exports.__awaiter || function(thisArg, _arguments, P3, generator) {
13113
+ function adopt(value) {
13114
+ return value instanceof P3 ? value : new P3(function(resolve) {
13115
+ resolve(value);
13116
+ });
13117
+ }
13118
+ return new (P3 || (P3 = Promise))(function(resolve, reject) {
13119
+ function fulfilled(value) {
13120
+ try {
13121
+ step(generator.next(value));
13122
+ } catch (e) {
13123
+ reject(e);
13124
+ }
13125
+ }
13126
+ function rejected(value) {
13127
+ try {
13128
+ step(generator["throw"](value));
13129
+ } catch (e) {
13130
+ reject(e);
13131
+ }
13132
+ }
13133
+ function step(result) {
13134
+ result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
13135
+ }
13136
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
13137
+ });
13138
+ };
13139
+ var __importDefault = exports && exports.__importDefault || function(mod2) {
13140
+ return mod2 && mod2.__esModule ? mod2 : { "default": mod2 };
13141
+ };
13142
+ Object.defineProperty(exports, "__esModule", { value: true });
13143
+ var net_1 = __importDefault(__require("net"));
13144
+ var tls_1 = __importDefault(__require("tls"));
13145
+ var url_1 = __importDefault(__require("url"));
13146
+ var assert_1 = __importDefault(__require("assert"));
13147
+ var debug_1 = __importDefault(require_src());
13148
+ var agent_base_1 = require_src2();
13149
+ var parse_proxy_response_1 = __importDefault(require_parse_proxy_response());
13150
+ var debug = debug_1.default("https-proxy-agent:agent");
13151
+ var HttpsProxyAgent2 = class extends agent_base_1.Agent {
13152
+ constructor(_opts) {
13153
+ let opts;
13154
+ if (typeof _opts === "string") {
13155
+ opts = url_1.default.parse(_opts);
13156
+ } else {
13157
+ opts = _opts;
13158
+ }
13159
+ if (!opts) {
13160
+ throw new Error("an HTTP(S) proxy server `host` and `port` must be specified!");
13161
+ }
13162
+ debug("creating new HttpsProxyAgent instance: %o", opts);
13163
+ super(opts);
13164
+ const proxy = Object.assign({}, opts);
13165
+ this.secureProxy = opts.secureProxy || isHTTPS(proxy.protocol);
13166
+ proxy.host = proxy.hostname || proxy.host;
13167
+ if (typeof proxy.port === "string") {
13168
+ proxy.port = parseInt(proxy.port, 10);
13169
+ }
13170
+ if (!proxy.port && proxy.host) {
13171
+ proxy.port = this.secureProxy ? 443 : 80;
13172
+ }
13173
+ if (this.secureProxy && !("ALPNProtocols" in proxy)) {
13174
+ proxy.ALPNProtocols = ["http 1.1"];
13175
+ }
13176
+ if (proxy.host && proxy.path) {
13177
+ delete proxy.path;
13178
+ delete proxy.pathname;
13179
+ }
13180
+ this.proxy = proxy;
13181
+ }
13182
+ /**
13183
+ * Called when the node-core HTTP client library is creating a
13184
+ * new HTTP request.
13185
+ *
13186
+ * @api protected
13187
+ */
13188
+ callback(req, opts) {
13189
+ return __awaiter(this, void 0, void 0, function* () {
13190
+ const { proxy, secureProxy } = this;
13191
+ let socket;
13192
+ if (secureProxy) {
13193
+ debug("Creating `tls.Socket`: %o", proxy);
13194
+ socket = tls_1.default.connect(proxy);
13195
+ } else {
13196
+ debug("Creating `net.Socket`: %o", proxy);
13197
+ socket = net_1.default.connect(proxy);
13198
+ }
13199
+ const headers = Object.assign({}, proxy.headers);
13200
+ const hostname = `${opts.host}:${opts.port}`;
13201
+ let payload = `CONNECT ${hostname} HTTP/1.1\r
13202
+ `;
13203
+ if (proxy.auth) {
13204
+ headers["Proxy-Authorization"] = `Basic ${Buffer.from(proxy.auth).toString("base64")}`;
13205
+ }
13206
+ let { host, port, secureEndpoint } = opts;
13207
+ if (!isDefaultPort(port, secureEndpoint)) {
13208
+ host += `:${port}`;
13209
+ }
13210
+ headers.Host = host;
13211
+ headers.Connection = "close";
13212
+ for (const name of Object.keys(headers)) {
13213
+ payload += `${name}: ${headers[name]}\r
13214
+ `;
13215
+ }
13216
+ const proxyResponsePromise = parse_proxy_response_1.default(socket);
13217
+ socket.write(`${payload}\r
13218
+ `);
13219
+ const { statusCode, buffered } = yield proxyResponsePromise;
13220
+ if (statusCode === 200) {
13221
+ req.once("socket", resume);
13222
+ if (opts.secureEndpoint) {
13223
+ debug("Upgrading socket connection to TLS");
13224
+ const servername = opts.servername || opts.host;
13225
+ return tls_1.default.connect(Object.assign(Object.assign({}, omit(opts, "host", "hostname", "path", "port")), {
13226
+ socket,
13227
+ servername
13228
+ }));
13229
+ }
13230
+ return socket;
13231
+ }
13232
+ socket.destroy();
13233
+ const fakeSocket = new net_1.default.Socket({ writable: false });
13234
+ fakeSocket.readable = true;
13235
+ req.once("socket", (s) => {
13236
+ debug("replaying proxy buffer for failed request");
13237
+ assert_1.default(s.listenerCount("data") > 0);
13238
+ s.push(buffered);
13239
+ s.push(null);
13240
+ });
13241
+ return fakeSocket;
13242
+ });
13243
+ }
13244
+ };
13245
+ exports.default = HttpsProxyAgent2;
13246
+ function resume(socket) {
13247
+ socket.resume();
13248
+ }
13249
+ function isDefaultPort(port, secure) {
13250
+ return Boolean(!secure && port === 80 || secure && port === 443);
13251
+ }
13252
+ function isHTTPS(protocol) {
13253
+ return typeof protocol === "string" ? /^https:?$/i.test(protocol) : false;
13254
+ }
13255
+ function omit(obj, ...keys) {
13256
+ const ret = {};
13257
+ let key;
13258
+ for (key in obj) {
13259
+ if (!keys.includes(key)) {
13260
+ ret[key] = obj[key];
13261
+ }
13262
+ }
13263
+ return ret;
13264
+ }
13265
+ }
13266
+ });
13267
+
13268
+ // ../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/index.js
13269
+ var require_dist = __commonJS({
13270
+ "../../node_modules/.pnpm/https-proxy-agent@5.0.1/node_modules/https-proxy-agent/dist/index.js"(exports, module) {
13271
+ "use strict";
13272
+ var __importDefault = exports && exports.__importDefault || function(mod2) {
13273
+ return mod2 && mod2.__esModule ? mod2 : { "default": mod2 };
13274
+ };
13275
+ var agent_1 = __importDefault(require_agent());
13276
+ function createHttpsProxyAgent(opts) {
13277
+ return new agent_1.default(opts);
13278
+ }
13279
+ (function(createHttpsProxyAgent2) {
13280
+ createHttpsProxyAgent2.HttpsProxyAgent = agent_1.default;
13281
+ createHttpsProxyAgent2.prototype = agent_1.default.prototype;
13282
+ })(createHttpsProxyAgent || (createHttpsProxyAgent = {}));
13283
+ module.exports = createHttpsProxyAgent;
13284
+ }
13285
+ });
13286
+
13287
+ // ../../node_modules/.pnpm/follow-redirects@1.16.0/node_modules/follow-redirects/debug.js
12838
13288
  var require_debug = __commonJS({
12839
- "../../node_modules/.pnpm/follow-redirects@1.15.11/node_modules/follow-redirects/debug.js"(exports, module) {
13289
+ "../../node_modules/.pnpm/follow-redirects@1.16.0/node_modules/follow-redirects/debug.js"(exports, module) {
12840
13290
  "use strict";
12841
13291
  var debug;
12842
13292
  module.exports = function() {
@@ -12855,9 +13305,9 @@ var require_debug = __commonJS({
12855
13305
  }
12856
13306
  });
12857
13307
 
12858
- // ../../node_modules/.pnpm/follow-redirects@1.15.11/node_modules/follow-redirects/index.js
13308
+ // ../../node_modules/.pnpm/follow-redirects@1.16.0/node_modules/follow-redirects/index.js
12859
13309
  var require_follow_redirects = __commonJS({
12860
- "../../node_modules/.pnpm/follow-redirects@1.15.11/node_modules/follow-redirects/index.js"(exports, module) {
13310
+ "../../node_modules/.pnpm/follow-redirects@1.16.0/node_modules/follow-redirects/index.js"(exports, module) {
12861
13311
  "use strict";
12862
13312
  var url2 = __require("url");
12863
13313
  var URL2 = url2.URL;
@@ -12880,6 +13330,11 @@ var require_follow_redirects = __commonJS({
12880
13330
  } catch (error) {
12881
13331
  useNativeURL = error.code === "ERR_INVALID_URL";
12882
13332
  }
13333
+ var sensitiveHeaders = [
13334
+ "Authorization",
13335
+ "Proxy-Authorization",
13336
+ "Cookie"
13337
+ ];
12883
13338
  var preservedUrlFields = [
12884
13339
  "auth",
12885
13340
  "host",
@@ -12944,6 +13399,7 @@ var require_follow_redirects = __commonJS({
12944
13399
  self2.emit("error", cause instanceof RedirectionError ? cause : new RedirectionError({ cause }));
12945
13400
  }
12946
13401
  };
13402
+ this._headerFilter = new RegExp("^(?:" + sensitiveHeaders.concat(options.sensitiveHeaders).map(escapeRegex).join("|") + ")$", "i");
12947
13403
  this._performRequest();
12948
13404
  }
12949
13405
  RedirectableRequest.prototype = Object.create(Writable.prototype);
@@ -13081,6 +13537,9 @@ var require_follow_redirects = __commonJS({
13081
13537
  if (!options.headers) {
13082
13538
  options.headers = {};
13083
13539
  }
13540
+ if (!isArray2(options.sensitiveHeaders)) {
13541
+ options.sensitiveHeaders = [];
13542
+ }
13084
13543
  if (options.host) {
13085
13544
  if (!options.hostname) {
13086
13545
  options.hostname = options.host;
@@ -13186,7 +13645,7 @@ var require_follow_redirects = __commonJS({
13186
13645
  this._isRedirect = true;
13187
13646
  spreadUrlObject(redirectUrl, this._options);
13188
13647
  if (redirectUrl.protocol !== currentUrlParts.protocol && redirectUrl.protocol !== "https:" || redirectUrl.host !== currentHost && !isSubdomain(redirectUrl.host, currentHost)) {
13189
- removeMatchingHeaders(/^(?:(?:proxy-)?authorization|cookie)$/i, this._options.headers);
13648
+ removeMatchingHeaders(this._headerFilter, this._options.headers);
13190
13649
  }
13191
13650
  if (isFunction3(beforeRedirect)) {
13192
13651
  var responseDetails = {
@@ -13335,6 +13794,9 @@ var require_follow_redirects = __commonJS({
13335
13794
  var dot = subdomain.length - domain.length - 1;
13336
13795
  return dot > 0 && subdomain[dot] === "." && subdomain.endsWith(domain);
13337
13796
  }
13797
+ function isArray2(value) {
13798
+ return value instanceof Array;
13799
+ }
13338
13800
  function isString2(value) {
13339
13801
  return typeof value === "string" || value instanceof String;
13340
13802
  }
@@ -13347,12 +13809,15 @@ var require_follow_redirects = __commonJS({
13347
13809
  function isURL(value) {
13348
13810
  return URL2 && value instanceof URL2;
13349
13811
  }
13812
+ function escapeRegex(regex) {
13813
+ return regex.replace(/[\]\\/()*+?.$]/g, "\\$&");
13814
+ }
13350
13815
  module.exports = wrap({ http: http3, https: https2 });
13351
13816
  module.exports.wrap = wrap;
13352
13817
  }
13353
13818
  });
13354
13819
 
13355
- // ../../node_modules/.pnpm/@cetusprotocol+aggregator-sdk@1.4.8_axios@1.15.2_typescript@5.9.3/node_modules/@cetusprotocol/aggregator-sdk/dist/index.js
13820
+ // ../../node_modules/.pnpm/@cetusprotocol+aggregator-sdk@1.4.8_axios@1.16.1_typescript@5.9.3/node_modules/@cetusprotocol/aggregator-sdk/dist/index.js
13356
13821
  var import_json_bigint = __toESM(require_json_bigint(), 1);
13357
13822
 
13358
13823
  // ../../node_modules/.pnpm/eventsource-parser@3.0.6/node_modules/eventsource-parser/dist/index.js
@@ -13755,7 +14220,7 @@ function getBaseURL() {
13755
14220
  return doc && typeof doc == "object" && "baseURI" in doc && typeof doc.baseURI == "string" ? doc.baseURI : void 0;
13756
14221
  }
13757
14222
 
13758
- // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.15.2/node_modules/@pythnetwork/hermes-client/dist/esm/utils.mjs
14223
+ // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.16.1/node_modules/@pythnetwork/hermes-client/dist/esm/utils.mjs
13759
14224
  function camelToSnakeCase(str) {
13760
14225
  return str.replaceAll(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`);
13761
14226
  }
@@ -13769,14 +14234,14 @@ function camelToSnakeCaseObject(obj) {
13769
14234
  return result;
13770
14235
  }
13771
14236
 
13772
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/bind.js
14237
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/bind.js
13773
14238
  function bind(fn, thisArg) {
13774
14239
  return function wrap() {
13775
14240
  return fn.apply(thisArg, arguments);
13776
14241
  };
13777
14242
  }
13778
14243
 
13779
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/utils.js
14244
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/utils.js
13780
14245
  var { toString } = Object.prototype;
13781
14246
  var { getPrototypeOf } = Object;
13782
14247
  var { iterator, toStringTag } = Symbol;
@@ -13911,7 +14376,7 @@ var _global = (() => {
13911
14376
  return typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : global;
13912
14377
  })();
13913
14378
  var isContextDefined = (context) => !isUndefined(context) && context !== _global;
13914
- function merge() {
14379
+ function merge(...objs) {
13915
14380
  const { caseless, skipUndefined } = isContextDefined(this) && this || {};
13916
14381
  const result = {};
13917
14382
  const assignValue = (val, key) => {
@@ -13919,8 +14384,9 @@ function merge() {
13919
14384
  return;
13920
14385
  }
13921
14386
  const targetKey = caseless && findKey(result, key) || key;
13922
- if (isPlainObject(result[targetKey]) && isPlainObject(val)) {
13923
- result[targetKey] = merge(result[targetKey], val);
14387
+ const existing = hasOwnProperty(result, targetKey) ? result[targetKey] : void 0;
14388
+ if (isPlainObject(existing) && isPlainObject(val)) {
14389
+ result[targetKey] = merge(existing, val);
13924
14390
  } else if (isPlainObject(val)) {
13925
14391
  result[targetKey] = merge({}, val);
13926
14392
  } else if (isArray(val)) {
@@ -13929,8 +14395,8 @@ function merge() {
13929
14395
  result[targetKey] = val;
13930
14396
  }
13931
14397
  };
13932
- for (let i = 0, l2 = arguments.length; i < l2; i++) {
13933
- arguments[i] && forEach(arguments[i], assignValue);
14398
+ for (let i = 0, l2 = objs.length; i < l2; i++) {
14399
+ objs[i] && forEach(objs[i], assignValue);
13934
14400
  }
13935
14401
  return result;
13936
14402
  }
@@ -13940,6 +14406,9 @@ var extend = (a, b, thisArg, { allOwnKeys } = {}) => {
13940
14406
  (val, key) => {
13941
14407
  if (thisArg && isFunction(val)) {
13942
14408
  Object.defineProperty(a, key, {
14409
+ // Null-proto descriptor so a polluted Object.prototype.get cannot
14410
+ // hijack defineProperty's accessor-vs-data resolution.
14411
+ __proto__: null,
13943
14412
  value: bind(val, thisArg),
13944
14413
  writable: true,
13945
14414
  enumerable: true,
@@ -13947,6 +14416,7 @@ var extend = (a, b, thisArg, { allOwnKeys } = {}) => {
13947
14416
  });
13948
14417
  } else {
13949
14418
  Object.defineProperty(a, key, {
14419
+ __proto__: null,
13950
14420
  value: val,
13951
14421
  writable: true,
13952
14422
  enumerable: true,
@@ -13967,12 +14437,14 @@ var stripBOM = (content) => {
13967
14437
  var inherits = (constructor, superConstructor, props, descriptors) => {
13968
14438
  constructor.prototype = Object.create(superConstructor.prototype, descriptors);
13969
14439
  Object.defineProperty(constructor.prototype, "constructor", {
14440
+ __proto__: null,
13970
14441
  value: constructor,
13971
14442
  writable: true,
13972
14443
  enumerable: false,
13973
14444
  configurable: true
13974
14445
  });
13975
14446
  Object.defineProperty(constructor, "super", {
14447
+ __proto__: null,
13976
14448
  value: superConstructor.prototype
13977
14449
  });
13978
14450
  props && Object.assign(constructor.prototype, props);
@@ -14061,7 +14533,7 @@ var reduceDescriptors = (obj, reducer) => {
14061
14533
  };
14062
14534
  var freezeMethods = (obj) => {
14063
14535
  reduceDescriptors(obj, (descriptor, name) => {
14064
- if (isFunction(obj) && ["arguments", "caller", "callee"].indexOf(name) !== -1) {
14536
+ if (isFunction(obj) && ["arguments", "caller", "callee"].includes(name)) {
14065
14537
  return false;
14066
14538
  }
14067
14539
  const value = obj[name];
@@ -14097,29 +14569,29 @@ function isSpecCompliantForm(thing) {
14097
14569
  return !!(thing && isFunction(thing.append) && thing[toStringTag] === "FormData" && thing[iterator]);
14098
14570
  }
14099
14571
  var toJSONObject = (obj) => {
14100
- const stack = new Array(10);
14101
- const visit = (source, i) => {
14572
+ const visited = /* @__PURE__ */ new WeakSet();
14573
+ const visit = (source) => {
14102
14574
  if (isObject(source)) {
14103
- if (stack.indexOf(source) >= 0) {
14575
+ if (visited.has(source)) {
14104
14576
  return;
14105
14577
  }
14106
14578
  if (isBuffer(source)) {
14107
14579
  return source;
14108
14580
  }
14109
14581
  if (!("toJSON" in source)) {
14110
- stack[i] = source;
14582
+ visited.add(source);
14111
14583
  const target = isArray(source) ? [] : {};
14112
14584
  forEach(source, (value, key) => {
14113
- const reducedValue = visit(value, i + 1);
14585
+ const reducedValue = visit(value);
14114
14586
  !isUndefined(reducedValue) && (target[key] = reducedValue);
14115
14587
  });
14116
- stack[i] = void 0;
14588
+ visited.delete(source);
14117
14589
  return target;
14118
14590
  }
14119
14591
  }
14120
14592
  return source;
14121
14593
  };
14122
- return visit(obj, 0);
14594
+ return visit(obj);
14123
14595
  };
14124
14596
  var isAsyncFn = kindOfTest("AsyncFunction");
14125
14597
  var isThenable = (thing) => thing && (isObject(thing) || isFunction(thing)) && isFunction(thing.then) && isFunction(thing.catch);
@@ -14208,895 +14680,972 @@ var utils_default = {
14208
14680
  isIterable
14209
14681
  };
14210
14682
 
14211
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/AxiosError.js
14212
- var AxiosError = class _AxiosError extends Error {
14213
- static from(error, code, config2, request, response, customProps) {
14214
- const axiosError = new _AxiosError(error.message, code || error.code, config2, request, response);
14215
- axiosError.cause = error;
14216
- axiosError.name = error.name;
14217
- if (error.status != null && axiosError.status == null) {
14218
- axiosError.status = error.status;
14683
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/parseHeaders.js
14684
+ var ignoreDuplicateOf = utils_default.toObjectSet([
14685
+ "age",
14686
+ "authorization",
14687
+ "content-length",
14688
+ "content-type",
14689
+ "etag",
14690
+ "expires",
14691
+ "from",
14692
+ "host",
14693
+ "if-modified-since",
14694
+ "if-unmodified-since",
14695
+ "last-modified",
14696
+ "location",
14697
+ "max-forwards",
14698
+ "proxy-authorization",
14699
+ "referer",
14700
+ "retry-after",
14701
+ "user-agent"
14702
+ ]);
14703
+ var parseHeaders_default = (rawHeaders) => {
14704
+ const parsed = {};
14705
+ let key;
14706
+ let val;
14707
+ let i;
14708
+ rawHeaders && rawHeaders.split("\n").forEach(function parser(line) {
14709
+ i = line.indexOf(":");
14710
+ key = line.substring(0, i).trim().toLowerCase();
14711
+ val = line.substring(i + 1).trim();
14712
+ if (!key || parsed[key] && ignoreDuplicateOf[key]) {
14713
+ return;
14219
14714
  }
14220
- customProps && Object.assign(axiosError, customProps);
14221
- return axiosError;
14715
+ if (key === "set-cookie") {
14716
+ if (parsed[key]) {
14717
+ parsed[key].push(val);
14718
+ } else {
14719
+ parsed[key] = [val];
14720
+ }
14721
+ } else {
14722
+ parsed[key] = parsed[key] ? parsed[key] + ", " + val : val;
14723
+ }
14724
+ });
14725
+ return parsed;
14726
+ };
14727
+
14728
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/sanitizeHeaderValue.js
14729
+ function trimSPorHTAB(str) {
14730
+ let start = 0;
14731
+ let end = str.length;
14732
+ while (start < end) {
14733
+ const code = str.charCodeAt(start);
14734
+ if (code !== 9 && code !== 32) {
14735
+ break;
14736
+ }
14737
+ start += 1;
14222
14738
  }
14223
- /**
14224
- * Create an Error with the specified message, config, error code, request and response.
14225
- *
14226
- * @param {string} message The error message.
14227
- * @param {string} [code] The error code (for example, 'ECONNABORTED').
14228
- * @param {Object} [config] The config.
14229
- * @param {Object} [request] The request.
14230
- * @param {Object} [response] The response.
14231
- *
14232
- * @returns {Error} The created error.
14233
- */
14234
- constructor(message, code, config2, request, response) {
14235
- super(message);
14236
- Object.defineProperty(this, "message", {
14237
- value: message,
14238
- enumerable: true,
14239
- writable: true,
14240
- configurable: true
14241
- });
14242
- this.name = "AxiosError";
14243
- this.isAxiosError = true;
14244
- code && (this.code = code);
14245
- config2 && (this.config = config2);
14246
- request && (this.request = request);
14247
- if (response) {
14248
- this.response = response;
14249
- this.status = response.status;
14739
+ while (end > start) {
14740
+ const code = str.charCodeAt(end - 1);
14741
+ if (code !== 9 && code !== 32) {
14742
+ break;
14250
14743
  }
14744
+ end -= 1;
14251
14745
  }
14252
- toJSON() {
14253
- return {
14254
- // Standard
14255
- message: this.message,
14256
- name: this.name,
14257
- // Microsoft
14258
- description: this.description,
14259
- number: this.number,
14260
- // Mozilla
14261
- fileName: this.fileName,
14262
- lineNumber: this.lineNumber,
14263
- columnNumber: this.columnNumber,
14264
- stack: this.stack,
14265
- // Axios
14266
- config: utils_default.toJSONObject(this.config),
14267
- code: this.code,
14268
- status: this.status
14269
- };
14746
+ return start === 0 && end === str.length ? str : str.slice(start, end);
14747
+ }
14748
+ var INVALID_UNICODE_HEADER_VALUE_CHARS = new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+", "g");
14749
+ var INVALID_BYTE_STRING_HEADER_VALUE_CHARS = new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+", "g");
14750
+ function sanitizeValue(value, invalidChars) {
14751
+ if (utils_default.isArray(value)) {
14752
+ return value.map((item) => sanitizeValue(item, invalidChars));
14270
14753
  }
14271
- };
14272
- AxiosError.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
14273
- AxiosError.ERR_BAD_OPTION = "ERR_BAD_OPTION";
14274
- AxiosError.ECONNABORTED = "ECONNABORTED";
14275
- AxiosError.ETIMEDOUT = "ETIMEDOUT";
14276
- AxiosError.ERR_NETWORK = "ERR_NETWORK";
14277
- AxiosError.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
14278
- AxiosError.ERR_DEPRECATED = "ERR_DEPRECATED";
14279
- AxiosError.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
14280
- AxiosError.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
14281
- AxiosError.ERR_CANCELED = "ERR_CANCELED";
14282
- AxiosError.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
14283
- AxiosError.ERR_INVALID_URL = "ERR_INVALID_URL";
14284
- AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = "ERR_FORM_DATA_DEPTH_EXCEEDED";
14285
- var AxiosError_default = AxiosError;
14286
-
14287
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/node/classes/FormData.js
14288
- var import_form_data = __toESM(require_form_data(), 1);
14289
- var FormData_default = import_form_data.default;
14290
-
14291
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/toFormData.js
14292
- function isVisitable(thing) {
14293
- return utils_default.isPlainObject(thing) || utils_default.isArray(thing);
14754
+ return trimSPorHTAB(String(value).replace(invalidChars, ""));
14294
14755
  }
14295
- function removeBrackets(key) {
14296
- return utils_default.endsWith(key, "[]") ? key.slice(0, -2) : key;
14756
+ var sanitizeHeaderValue = (value) => sanitizeValue(value, INVALID_UNICODE_HEADER_VALUE_CHARS);
14757
+ var sanitizeByteStringHeaderValue = (value) => sanitizeValue(value, INVALID_BYTE_STRING_HEADER_VALUE_CHARS);
14758
+ function toByteStringHeaderObject(headers) {
14759
+ const byteStringHeaders = /* @__PURE__ */ Object.create(null);
14760
+ utils_default.forEach(headers.toJSON(), (value, header) => {
14761
+ byteStringHeaders[header] = sanitizeByteStringHeaderValue(value);
14762
+ });
14763
+ return byteStringHeaders;
14297
14764
  }
14298
- function renderKey(path, key, dots) {
14299
- if (!path) return key;
14300
- return path.concat(key).map(function each(token, i) {
14301
- token = removeBrackets(token);
14302
- return !dots && i ? "[" + token + "]" : token;
14303
- }).join(dots ? "." : "");
14765
+
14766
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/AxiosHeaders.js
14767
+ var $internals = /* @__PURE__ */ Symbol("internals");
14768
+ function normalizeHeader(header) {
14769
+ return header && String(header).trim().toLowerCase();
14304
14770
  }
14305
- function isFlatArray(arr) {
14306
- return utils_default.isArray(arr) && !arr.some(isVisitable);
14771
+ function normalizeValue(value) {
14772
+ if (value === false || value == null) {
14773
+ return value;
14774
+ }
14775
+ return utils_default.isArray(value) ? value.map(normalizeValue) : sanitizeHeaderValue(String(value));
14307
14776
  }
14308
- var predicates = utils_default.toFlatObject(utils_default, {}, null, function filter(prop) {
14309
- return /^is[A-Z]/.test(prop);
14310
- });
14311
- function toFormData(obj, formData, options) {
14312
- if (!utils_default.isObject(obj)) {
14313
- throw new TypeError("target must be an object");
14777
+ function parseTokens(str) {
14778
+ const tokens = /* @__PURE__ */ Object.create(null);
14779
+ const tokensRE = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
14780
+ let match;
14781
+ while (match = tokensRE.exec(str)) {
14782
+ tokens[match[1]] = match[2];
14314
14783
  }
14315
- formData = formData || new (FormData_default || FormData)();
14316
- options = utils_default.toFlatObject(
14317
- options,
14318
- {
14319
- metaTokens: true,
14320
- dots: false,
14321
- indexes: false
14322
- },
14323
- false,
14324
- function defined(option, source) {
14325
- return !utils_default.isUndefined(source[option]);
14326
- }
14327
- );
14328
- const metaTokens = options.metaTokens;
14329
- const visitor = options.visitor || defaultVisitor;
14330
- const dots = options.dots;
14331
- const indexes = options.indexes;
14332
- const _Blob = options.Blob || typeof Blob !== "undefined" && Blob;
14333
- const maxDepth = options.maxDepth === void 0 ? 100 : options.maxDepth;
14334
- const useBlob = _Blob && utils_default.isSpecCompliantForm(formData);
14335
- if (!utils_default.isFunction(visitor)) {
14336
- throw new TypeError("visitor must be a function");
14784
+ return tokens;
14785
+ }
14786
+ var isValidHeaderName = (str) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
14787
+ function matchHeaderValue(context, value, header, filter2, isHeaderNameFilter) {
14788
+ if (utils_default.isFunction(filter2)) {
14789
+ return filter2.call(this, value, header);
14337
14790
  }
14338
- function convertValue(value) {
14339
- if (value === null) return "";
14340
- if (utils_default.isDate(value)) {
14341
- return value.toISOString();
14342
- }
14343
- if (utils_default.isBoolean(value)) {
14344
- return value.toString();
14345
- }
14346
- if (!useBlob && utils_default.isBlob(value)) {
14347
- throw new AxiosError_default("Blob is not supported. Use a Buffer instead.");
14791
+ if (isHeaderNameFilter) {
14792
+ value = header;
14793
+ }
14794
+ if (!utils_default.isString(value)) return;
14795
+ if (utils_default.isString(filter2)) {
14796
+ return value.indexOf(filter2) !== -1;
14797
+ }
14798
+ if (utils_default.isRegExp(filter2)) {
14799
+ return filter2.test(value);
14800
+ }
14801
+ }
14802
+ function formatHeader(header) {
14803
+ return header.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (w2, char, str) => {
14804
+ return char.toUpperCase() + str;
14805
+ });
14806
+ }
14807
+ function buildAccessors(obj, header) {
14808
+ const accessorName = utils_default.toCamelCase(" " + header);
14809
+ ["get", "set", "has"].forEach((methodName) => {
14810
+ Object.defineProperty(obj, methodName + accessorName, {
14811
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
14812
+ // this data descriptor into an accessor descriptor on the way in.
14813
+ __proto__: null,
14814
+ value: function(arg1, arg2, arg3) {
14815
+ return this[methodName].call(this, header, arg1, arg2, arg3);
14816
+ },
14817
+ configurable: true
14818
+ });
14819
+ });
14820
+ }
14821
+ var AxiosHeaders = class {
14822
+ constructor(headers) {
14823
+ headers && this.set(headers);
14824
+ }
14825
+ set(header, valueOrRewrite, rewrite) {
14826
+ const self2 = this;
14827
+ function setHeader(_value, _header, _rewrite) {
14828
+ const lHeader = normalizeHeader(_header);
14829
+ if (!lHeader) {
14830
+ throw new Error("header name must be a non-empty string");
14831
+ }
14832
+ const key = utils_default.findKey(self2, lHeader);
14833
+ if (!key || self2[key] === void 0 || _rewrite === true || _rewrite === void 0 && self2[key] !== false) {
14834
+ self2[key || _header] = normalizeValue(_value);
14835
+ }
14348
14836
  }
14349
- if (utils_default.isArrayBuffer(value) || utils_default.isTypedArray(value)) {
14350
- return useBlob && typeof Blob === "function" ? new Blob([value]) : Buffer.from(value);
14837
+ const setHeaders = (headers, _rewrite) => utils_default.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
14838
+ if (utils_default.isPlainObject(header) || header instanceof this.constructor) {
14839
+ setHeaders(header, valueOrRewrite);
14840
+ } else if (utils_default.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
14841
+ setHeaders(parseHeaders_default(header), valueOrRewrite);
14842
+ } else if (utils_default.isObject(header) && utils_default.isIterable(header)) {
14843
+ let obj = {}, dest, key;
14844
+ for (const entry of header) {
14845
+ if (!utils_default.isArray(entry)) {
14846
+ throw TypeError("Object iterator must return a key-value pair");
14847
+ }
14848
+ obj[key = entry[0]] = (dest = obj[key]) ? utils_default.isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]] : entry[1];
14849
+ }
14850
+ setHeaders(obj, valueOrRewrite);
14851
+ } else {
14852
+ header != null && setHeader(valueOrRewrite, header, rewrite);
14351
14853
  }
14352
- return value;
14854
+ return this;
14353
14855
  }
14354
- function defaultVisitor(value, key, path) {
14355
- let arr = value;
14356
- if (utils_default.isReactNative(formData) && utils_default.isReactNativeBlob(value)) {
14357
- formData.append(renderKey(path, key, dots), convertValue(value));
14358
- return false;
14359
- }
14360
- if (value && !path && typeof value === "object") {
14361
- if (utils_default.endsWith(key, "{}")) {
14362
- key = metaTokens ? key : key.slice(0, -2);
14363
- value = JSON.stringify(value);
14364
- } else if (utils_default.isArray(value) && isFlatArray(value) || (utils_default.isFileList(value) || utils_default.endsWith(key, "[]")) && (arr = utils_default.toArray(value))) {
14365
- key = removeBrackets(key);
14366
- arr.forEach(function each(el, index) {
14367
- !(utils_default.isUndefined(el) || el === null) && formData.append(
14368
- // eslint-disable-next-line no-nested-ternary
14369
- indexes === true ? renderKey([key], index, dots) : indexes === null ? key : key + "[]",
14370
- convertValue(el)
14371
- );
14372
- });
14373
- return false;
14856
+ get(header, parser) {
14857
+ header = normalizeHeader(header);
14858
+ if (header) {
14859
+ const key = utils_default.findKey(this, header);
14860
+ if (key) {
14861
+ const value = this[key];
14862
+ if (!parser) {
14863
+ return value;
14864
+ }
14865
+ if (parser === true) {
14866
+ return parseTokens(value);
14867
+ }
14868
+ if (utils_default.isFunction(parser)) {
14869
+ return parser.call(this, value, key);
14870
+ }
14871
+ if (utils_default.isRegExp(parser)) {
14872
+ return parser.exec(value);
14873
+ }
14874
+ throw new TypeError("parser must be boolean|regexp|function");
14374
14875
  }
14375
14876
  }
14376
- if (isVisitable(value)) {
14377
- return true;
14877
+ }
14878
+ has(header, matcher) {
14879
+ header = normalizeHeader(header);
14880
+ if (header) {
14881
+ const key = utils_default.findKey(this, header);
14882
+ return !!(key && this[key] !== void 0 && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
14378
14883
  }
14379
- formData.append(renderKey(path, key, dots), convertValue(value));
14380
14884
  return false;
14381
14885
  }
14382
- const stack = [];
14383
- const exposedHelpers = Object.assign(predicates, {
14384
- defaultVisitor,
14385
- convertValue,
14386
- isVisitable
14387
- });
14388
- function build(value, path, depth = 0) {
14389
- if (utils_default.isUndefined(value)) return;
14390
- if (depth > maxDepth) {
14391
- throw new AxiosError_default(
14392
- "Object is too deeply nested (" + depth + " levels). Max depth: " + maxDepth,
14393
- AxiosError_default.ERR_FORM_DATA_DEPTH_EXCEEDED
14394
- );
14886
+ delete(header, matcher) {
14887
+ const self2 = this;
14888
+ let deleted = false;
14889
+ function deleteHeader(_header) {
14890
+ _header = normalizeHeader(_header);
14891
+ if (_header) {
14892
+ const key = utils_default.findKey(self2, _header);
14893
+ if (key && (!matcher || matchHeaderValue(self2, self2[key], key, matcher))) {
14894
+ delete self2[key];
14895
+ deleted = true;
14896
+ }
14897
+ }
14395
14898
  }
14396
- if (stack.indexOf(value) !== -1) {
14397
- throw Error("Circular reference detected in " + path.join("."));
14899
+ if (utils_default.isArray(header)) {
14900
+ header.forEach(deleteHeader);
14901
+ } else {
14902
+ deleteHeader(header);
14398
14903
  }
14399
- stack.push(value);
14400
- utils_default.forEach(value, function each(el, key) {
14401
- const result = !(utils_default.isUndefined(el) || el === null) && visitor.call(formData, el, utils_default.isString(key) ? key.trim() : key, path, exposedHelpers);
14402
- if (result === true) {
14403
- build(el, path ? path.concat(key) : [key], depth + 1);
14904
+ return deleted;
14905
+ }
14906
+ clear(matcher) {
14907
+ const keys = Object.keys(this);
14908
+ let i = keys.length;
14909
+ let deleted = false;
14910
+ while (i--) {
14911
+ const key = keys[i];
14912
+ if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
14913
+ delete this[key];
14914
+ deleted = true;
14915
+ }
14916
+ }
14917
+ return deleted;
14918
+ }
14919
+ normalize(format) {
14920
+ const self2 = this;
14921
+ const headers = {};
14922
+ utils_default.forEach(this, (value, header) => {
14923
+ const key = utils_default.findKey(headers, header);
14924
+ if (key) {
14925
+ self2[key] = normalizeValue(value);
14926
+ delete self2[header];
14927
+ return;
14404
14928
  }
14929
+ const normalized = format ? formatHeader(header) : String(header).trim();
14930
+ if (normalized !== header) {
14931
+ delete self2[header];
14932
+ }
14933
+ self2[normalized] = normalizeValue(value);
14934
+ headers[normalized] = true;
14405
14935
  });
14406
- stack.pop();
14936
+ return this;
14407
14937
  }
14408
- if (!utils_default.isObject(obj)) {
14409
- throw new TypeError("data must be an object");
14938
+ concat(...targets) {
14939
+ return this.constructor.concat(this, ...targets);
14410
14940
  }
14411
- build(obj);
14412
- return formData;
14413
- }
14414
- var toFormData_default = toFormData;
14415
-
14416
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/AxiosURLSearchParams.js
14417
- function encode(str) {
14418
- const charMap = {
14419
- "!": "%21",
14420
- "'": "%27",
14421
- "(": "%28",
14422
- ")": "%29",
14423
- "~": "%7E",
14424
- "%20": "+"
14425
- };
14426
- return encodeURIComponent(str).replace(/[!'()~]|%20/g, function replacer(match) {
14427
- return charMap[match];
14428
- });
14429
- }
14430
- function AxiosURLSearchParams(params, options) {
14431
- this._pairs = [];
14432
- params && toFormData_default(params, this, options);
14433
- }
14434
- var prototype = AxiosURLSearchParams.prototype;
14435
- prototype.append = function append(name, value) {
14436
- this._pairs.push([name, value]);
14437
- };
14438
- prototype.toString = function toString2(encoder) {
14439
- const _encode = encoder ? function(value) {
14440
- return encoder.call(this, value, encode);
14441
- } : encode;
14442
- return this._pairs.map(function each(pair) {
14443
- return _encode(pair[0]) + "=" + _encode(pair[1]);
14444
- }, "").join("&");
14445
- };
14446
- var AxiosURLSearchParams_default = AxiosURLSearchParams;
14447
-
14448
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/buildURL.js
14449
- function encode2(val) {
14450
- return encodeURIComponent(val).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
14451
- }
14452
- function buildURL(url2, params, options) {
14453
- if (!params) {
14454
- return url2;
14941
+ toJSON(asStrings) {
14942
+ const obj = /* @__PURE__ */ Object.create(null);
14943
+ utils_default.forEach(this, (value, header) => {
14944
+ value != null && value !== false && (obj[header] = asStrings && utils_default.isArray(value) ? value.join(", ") : value);
14945
+ });
14946
+ return obj;
14455
14947
  }
14456
- const _encode = options && options.encode || encode2;
14457
- const _options = utils_default.isFunction(options) ? {
14458
- serialize: options
14459
- } : options;
14460
- const serializeFn = _options && _options.serialize;
14461
- let serializedParams;
14462
- if (serializeFn) {
14463
- serializedParams = serializeFn(params, _options);
14464
- } else {
14465
- serializedParams = utils_default.isURLSearchParams(params) ? params.toString() : new AxiosURLSearchParams_default(params, _options).toString(_encode);
14948
+ [Symbol.iterator]() {
14949
+ return Object.entries(this.toJSON())[Symbol.iterator]();
14466
14950
  }
14467
- if (serializedParams) {
14468
- const hashmarkIndex = url2.indexOf("#");
14469
- if (hashmarkIndex !== -1) {
14470
- url2 = url2.slice(0, hashmarkIndex);
14951
+ toString() {
14952
+ return Object.entries(this.toJSON()).map(([header, value]) => header + ": " + value).join("\n");
14953
+ }
14954
+ getSetCookie() {
14955
+ return this.get("set-cookie") || [];
14956
+ }
14957
+ get [Symbol.toStringTag]() {
14958
+ return "AxiosHeaders";
14959
+ }
14960
+ static from(thing) {
14961
+ return thing instanceof this ? thing : new this(thing);
14962
+ }
14963
+ static concat(first, ...targets) {
14964
+ const computed = new this(first);
14965
+ targets.forEach((target) => computed.set(target));
14966
+ return computed;
14967
+ }
14968
+ static accessor(header) {
14969
+ const internals = this[$internals] = this[$internals] = {
14970
+ accessors: {}
14971
+ };
14972
+ const accessors = internals.accessors;
14973
+ const prototype2 = this.prototype;
14974
+ function defineAccessor(_header) {
14975
+ const lHeader = normalizeHeader(_header);
14976
+ if (!accessors[lHeader]) {
14977
+ buildAccessors(prototype2, _header);
14978
+ accessors[lHeader] = true;
14979
+ }
14471
14980
  }
14472
- url2 += (url2.indexOf("?") === -1 ? "?" : "&") + serializedParams;
14981
+ utils_default.isArray(header) ? header.forEach(defineAccessor) : defineAccessor(header);
14982
+ return this;
14473
14983
  }
14474
- return url2;
14475
- }
14984
+ };
14985
+ AxiosHeaders.accessor([
14986
+ "Content-Type",
14987
+ "Content-Length",
14988
+ "Accept",
14989
+ "Accept-Encoding",
14990
+ "User-Agent",
14991
+ "Authorization"
14992
+ ]);
14993
+ utils_default.reduceDescriptors(AxiosHeaders.prototype, ({ value }, key) => {
14994
+ let mapped = key[0].toUpperCase() + key.slice(1);
14995
+ return {
14996
+ get: () => value,
14997
+ set(headerValue) {
14998
+ this[mapped] = headerValue;
14999
+ }
15000
+ };
15001
+ });
15002
+ utils_default.freezeMethods(AxiosHeaders);
15003
+ var AxiosHeaders_default = AxiosHeaders;
14476
15004
 
14477
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/InterceptorManager.js
14478
- var InterceptorManager = class {
14479
- constructor() {
14480
- this.handlers = [];
14481
- }
14482
- /**
14483
- * Add a new interceptor to the stack
14484
- *
14485
- * @param {Function} fulfilled The function to handle `then` for a `Promise`
14486
- * @param {Function} rejected The function to handle `reject` for a `Promise`
14487
- * @param {Object} options The options for the interceptor, synchronous and runWhen
14488
- *
14489
- * @return {Number} An ID used to remove interceptor later
14490
- */
14491
- use(fulfilled, rejected, options) {
14492
- this.handlers.push({
14493
- fulfilled,
14494
- rejected,
14495
- synchronous: options ? options.synchronous : false,
14496
- runWhen: options ? options.runWhen : null
14497
- });
14498
- return this.handlers.length - 1;
15005
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/AxiosError.js
15006
+ var REDACTED = "[REDACTED ****]";
15007
+ function hasOwnOrPrototypeToJSON(source) {
15008
+ if (utils_default.hasOwnProp(source, "toJSON")) {
15009
+ return true;
14499
15010
  }
14500
- /**
14501
- * Remove an interceptor from the stack
14502
- *
14503
- * @param {Number} id The ID that was returned by `use`
14504
- *
14505
- * @returns {void}
14506
- */
14507
- eject(id) {
14508
- if (this.handlers[id]) {
14509
- this.handlers[id] = null;
15011
+ let prototype2 = Object.getPrototypeOf(source);
15012
+ while (prototype2 && prototype2 !== Object.prototype) {
15013
+ if (utils_default.hasOwnProp(prototype2, "toJSON")) {
15014
+ return true;
14510
15015
  }
15016
+ prototype2 = Object.getPrototypeOf(prototype2);
14511
15017
  }
14512
- /**
14513
- * Clear all interceptors from the stack
14514
- *
14515
- * @returns {void}
14516
- */
14517
- clear() {
14518
- if (this.handlers) {
14519
- this.handlers = [];
15018
+ return false;
15019
+ }
15020
+ function redactConfig(config2, redactKeys) {
15021
+ const lowerKeys = new Set(redactKeys.map((k) => String(k).toLowerCase()));
15022
+ const seen = [];
15023
+ const visit = (source) => {
15024
+ if (source === null || typeof source !== "object") return source;
15025
+ if (utils_default.isBuffer(source)) return source;
15026
+ if (seen.indexOf(source) !== -1) return void 0;
15027
+ if (source instanceof AxiosHeaders_default) {
15028
+ source = source.toJSON();
15029
+ }
15030
+ seen.push(source);
15031
+ let result;
15032
+ if (utils_default.isArray(source)) {
15033
+ result = [];
15034
+ source.forEach((v, i) => {
15035
+ const reducedValue = visit(v);
15036
+ if (!utils_default.isUndefined(reducedValue)) {
15037
+ result[i] = reducedValue;
15038
+ }
15039
+ });
15040
+ } else {
15041
+ if (!utils_default.isPlainObject(source) && hasOwnOrPrototypeToJSON(source)) {
15042
+ seen.pop();
15043
+ return source;
15044
+ }
15045
+ result = /* @__PURE__ */ Object.create(null);
15046
+ for (const [key, value] of Object.entries(source)) {
15047
+ const reducedValue = lowerKeys.has(key.toLowerCase()) ? REDACTED : visit(value);
15048
+ if (!utils_default.isUndefined(reducedValue)) {
15049
+ result[key] = reducedValue;
15050
+ }
15051
+ }
15052
+ }
15053
+ seen.pop();
15054
+ return result;
15055
+ };
15056
+ return visit(config2);
15057
+ }
15058
+ var AxiosError = class _AxiosError extends Error {
15059
+ static from(error, code, config2, request, response, customProps) {
15060
+ const axiosError = new _AxiosError(error.message, code || error.code, config2, request, response);
15061
+ axiosError.cause = error;
15062
+ axiosError.name = error.name;
15063
+ if (error.status != null && axiosError.status == null) {
15064
+ axiosError.status = error.status;
14520
15065
  }
15066
+ customProps && Object.assign(axiosError, customProps);
15067
+ return axiosError;
14521
15068
  }
14522
15069
  /**
14523
- * Iterate over all the registered interceptors
14524
- *
14525
- * This method is particularly useful for skipping over any
14526
- * interceptors that may have become `null` calling `eject`.
15070
+ * Create an Error with the specified message, config, error code, request and response.
14527
15071
  *
14528
- * @param {Function} fn The function to call for each interceptor
15072
+ * @param {string} message The error message.
15073
+ * @param {string} [code] The error code (for example, 'ECONNABORTED').
15074
+ * @param {Object} [config] The config.
15075
+ * @param {Object} [request] The request.
15076
+ * @param {Object} [response] The response.
14529
15077
  *
14530
- * @returns {void}
15078
+ * @returns {Error} The created error.
14531
15079
  */
14532
- forEach(fn) {
14533
- utils_default.forEach(this.handlers, function forEachHandler(h) {
14534
- if (h !== null) {
14535
- fn(h);
14536
- }
15080
+ constructor(message, code, config2, request, response) {
15081
+ super(message);
15082
+ Object.defineProperty(this, "message", {
15083
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
15084
+ // this data descriptor into an accessor descriptor on the way in.
15085
+ __proto__: null,
15086
+ value: message,
15087
+ enumerable: true,
15088
+ writable: true,
15089
+ configurable: true
14537
15090
  });
15091
+ this.name = "AxiosError";
15092
+ this.isAxiosError = true;
15093
+ code && (this.code = code);
15094
+ config2 && (this.config = config2);
15095
+ request && (this.request = request);
15096
+ if (response) {
15097
+ this.response = response;
15098
+ this.status = response.status;
15099
+ }
15100
+ }
15101
+ toJSON() {
15102
+ const config2 = this.config;
15103
+ const redactKeys = config2 && utils_default.hasOwnProp(config2, "redact") ? config2.redact : void 0;
15104
+ const serializedConfig = utils_default.isArray(redactKeys) && redactKeys.length > 0 ? redactConfig(config2, redactKeys) : utils_default.toJSONObject(config2);
15105
+ return {
15106
+ // Standard
15107
+ message: this.message,
15108
+ name: this.name,
15109
+ // Microsoft
15110
+ description: this.description,
15111
+ number: this.number,
15112
+ // Mozilla
15113
+ fileName: this.fileName,
15114
+ lineNumber: this.lineNumber,
15115
+ columnNumber: this.columnNumber,
15116
+ stack: this.stack,
15117
+ // Axios
15118
+ config: serializedConfig,
15119
+ code: this.code,
15120
+ status: this.status
15121
+ };
14538
15122
  }
14539
15123
  };
14540
- var InterceptorManager_default = InterceptorManager;
14541
-
14542
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/defaults/transitional.js
14543
- var transitional_default = {
14544
- silentJSONParsing: true,
14545
- forcedJSONParsing: true,
14546
- clarifyTimeoutError: false,
14547
- legacyInterceptorReqResOrdering: true
14548
- };
15124
+ AxiosError.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
15125
+ AxiosError.ERR_BAD_OPTION = "ERR_BAD_OPTION";
15126
+ AxiosError.ECONNABORTED = "ECONNABORTED";
15127
+ AxiosError.ETIMEDOUT = "ETIMEDOUT";
15128
+ AxiosError.ECONNREFUSED = "ECONNREFUSED";
15129
+ AxiosError.ERR_NETWORK = "ERR_NETWORK";
15130
+ AxiosError.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
15131
+ AxiosError.ERR_DEPRECATED = "ERR_DEPRECATED";
15132
+ AxiosError.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
15133
+ AxiosError.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
15134
+ AxiosError.ERR_CANCELED = "ERR_CANCELED";
15135
+ AxiosError.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
15136
+ AxiosError.ERR_INVALID_URL = "ERR_INVALID_URL";
15137
+ AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = "ERR_FORM_DATA_DEPTH_EXCEEDED";
15138
+ var AxiosError_default = AxiosError;
14549
15139
 
14550
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/node/index.js
14551
- import crypto2 from "crypto";
15140
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/node/classes/FormData.js
15141
+ var import_form_data = __toESM(require_form_data(), 1);
15142
+ var FormData_default = import_form_data.default;
14552
15143
 
14553
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/node/classes/URLSearchParams.js
14554
- import url from "url";
14555
- var URLSearchParams_default = url.URLSearchParams;
14556
-
14557
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/node/index.js
14558
- var ALPHA = "abcdefghijklmnopqrstuvwxyz";
14559
- var DIGIT = "0123456789";
14560
- var ALPHABET = {
14561
- DIGIT,
14562
- ALPHA,
14563
- ALPHA_DIGIT: ALPHA + ALPHA.toUpperCase() + DIGIT
14564
- };
14565
- var generateString = (size = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
14566
- let str = "";
14567
- const { length } = alphabet;
14568
- const randomValues = new Uint32Array(size);
14569
- crypto2.randomFillSync(randomValues);
14570
- for (let i = 0; i < size; i++) {
14571
- str += alphabet[randomValues[i] % length];
14572
- }
14573
- return str;
14574
- };
14575
- var node_default = {
14576
- isNode: true,
14577
- classes: {
14578
- URLSearchParams: URLSearchParams_default,
14579
- FormData: FormData_default,
14580
- Blob: typeof Blob !== "undefined" && Blob || null
14581
- },
14582
- ALPHABET,
14583
- generateString,
14584
- protocols: ["http", "https", "file", "data"]
14585
- };
14586
-
14587
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/common/utils.js
14588
- var utils_exports = {};
14589
- __export(utils_exports, {
14590
- hasBrowserEnv: () => hasBrowserEnv,
14591
- hasStandardBrowserEnv: () => hasStandardBrowserEnv,
14592
- hasStandardBrowserWebWorkerEnv: () => hasStandardBrowserWebWorkerEnv,
14593
- navigator: () => _navigator,
14594
- origin: () => origin
14595
- });
14596
- var hasBrowserEnv = typeof window !== "undefined" && typeof document !== "undefined";
14597
- var _navigator = typeof navigator === "object" && navigator || void 0;
14598
- var hasStandardBrowserEnv = hasBrowserEnv && (!_navigator || ["ReactNative", "NativeScript", "NS"].indexOf(_navigator.product) < 0);
14599
- var hasStandardBrowserWebWorkerEnv = (() => {
14600
- return typeof WorkerGlobalScope !== "undefined" && // eslint-disable-next-line no-undef
14601
- self instanceof WorkerGlobalScope && typeof self.importScripts === "function";
14602
- })();
14603
- var origin = hasBrowserEnv && window.location.href || "http://localhost";
14604
-
14605
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/platform/index.js
14606
- var platform_default = {
14607
- ...utils_exports,
14608
- ...node_default
14609
- };
14610
-
14611
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/toURLEncodedForm.js
14612
- function toURLEncodedForm(data, options) {
14613
- return toFormData_default(data, new platform_default.classes.URLSearchParams(), {
14614
- visitor: function(value, key, path, helpers) {
14615
- if (platform_default.isNode && utils_default.isBuffer(value)) {
14616
- this.append(key, value.toString("base64"));
14617
- return false;
14618
- }
14619
- return helpers.defaultVisitor.apply(this, arguments);
14620
- },
14621
- ...options
14622
- });
15144
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/toFormData.js
15145
+ function isVisitable(thing) {
15146
+ return utils_default.isPlainObject(thing) || utils_default.isArray(thing);
14623
15147
  }
14624
-
14625
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/formDataToJSON.js
14626
- function parsePropPath(name) {
14627
- return utils_default.matchAll(/\w+|\[(\w*)]/g, name).map((match) => {
14628
- return match[0] === "[]" ? "" : match[1] || match[0];
14629
- });
15148
+ function removeBrackets(key) {
15149
+ return utils_default.endsWith(key, "[]") ? key.slice(0, -2) : key;
14630
15150
  }
14631
- function arrayToObject(arr) {
14632
- const obj = {};
14633
- const keys = Object.keys(arr);
14634
- let i;
14635
- const len = keys.length;
14636
- let key;
14637
- for (i = 0; i < len; i++) {
14638
- key = keys[i];
14639
- obj[key] = arr[key];
14640
- }
14641
- return obj;
15151
+ function renderKey(path, key, dots) {
15152
+ if (!path) return key;
15153
+ return path.concat(key).map(function each(token, i) {
15154
+ token = removeBrackets(token);
15155
+ return !dots && i ? "[" + token + "]" : token;
15156
+ }).join(dots ? "." : "");
14642
15157
  }
14643
- function formDataToJSON(formData) {
14644
- function buildPath(path, value, target, index) {
14645
- let name = path[index++];
14646
- if (name === "__proto__") return true;
14647
- const isNumericKey = Number.isFinite(+name);
14648
- const isLast = index >= path.length;
14649
- name = !name && utils_default.isArray(target) ? target.length : name;
14650
- if (isLast) {
14651
- if (utils_default.hasOwnProp(target, name)) {
14652
- target[name] = utils_default.isArray(target[name]) ? target[name].concat(value) : [target[name], value];
14653
- } else {
14654
- target[name] = value;
14655
- }
14656
- return !isNumericKey;
14657
- }
14658
- if (!target[name] || !utils_default.isObject(target[name])) {
14659
- target[name] = [];
14660
- }
14661
- const result = buildPath(path, value, target[name], index);
14662
- if (result && utils_default.isArray(target[name])) {
14663
- target[name] = arrayToObject(target[name]);
14664
- }
14665
- return !isNumericKey;
14666
- }
14667
- if (utils_default.isFormData(formData) && utils_default.isFunction(formData.entries)) {
14668
- const obj = {};
14669
- utils_default.forEachEntry(formData, (name, value) => {
14670
- buildPath(parsePropPath(name), value, obj, 0);
14671
- });
14672
- return obj;
14673
- }
14674
- return null;
15158
+ function isFlatArray(arr) {
15159
+ return utils_default.isArray(arr) && !arr.some(isVisitable);
14675
15160
  }
14676
- var formDataToJSON_default = formDataToJSON;
14677
-
14678
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/defaults/index.js
14679
- var own = (obj, key) => obj != null && utils_default.hasOwnProp(obj, key) ? obj[key] : void 0;
14680
- function stringifySafely(rawValue, parser, encoder) {
14681
- if (utils_default.isString(rawValue)) {
14682
- try {
14683
- (parser || JSON.parse)(rawValue);
14684
- return utils_default.trim(rawValue);
14685
- } catch (e) {
14686
- if (e.name !== "SyntaxError") {
14687
- throw e;
14688
- }
14689
- }
15161
+ var predicates = utils_default.toFlatObject(utils_default, {}, null, function filter(prop) {
15162
+ return /^is[A-Z]/.test(prop);
15163
+ });
15164
+ function toFormData(obj, formData, options) {
15165
+ if (!utils_default.isObject(obj)) {
15166
+ throw new TypeError("target must be an object");
14690
15167
  }
14691
- return (encoder || JSON.stringify)(rawValue);
14692
- }
14693
- var defaults = {
14694
- transitional: transitional_default,
14695
- adapter: ["xhr", "http", "fetch"],
14696
- transformRequest: [
14697
- function transformRequest(data, headers) {
14698
- const contentType = headers.getContentType() || "";
14699
- const hasJSONContentType = contentType.indexOf("application/json") > -1;
14700
- const isObjectPayload = utils_default.isObject(data);
14701
- if (isObjectPayload && utils_default.isHTMLForm(data)) {
14702
- data = new FormData(data);
14703
- }
14704
- const isFormData2 = utils_default.isFormData(data);
14705
- if (isFormData2) {
14706
- return hasJSONContentType ? JSON.stringify(formDataToJSON_default(data)) : data;
14707
- }
14708
- if (utils_default.isArrayBuffer(data) || utils_default.isBuffer(data) || utils_default.isStream(data) || utils_default.isFile(data) || utils_default.isBlob(data) || utils_default.isReadableStream(data)) {
14709
- return data;
14710
- }
14711
- if (utils_default.isArrayBufferView(data)) {
14712
- return data.buffer;
14713
- }
14714
- if (utils_default.isURLSearchParams(data)) {
14715
- headers.setContentType("application/x-www-form-urlencoded;charset=utf-8", false);
14716
- return data.toString();
14717
- }
14718
- let isFileList2;
14719
- if (isObjectPayload) {
14720
- const formSerializer = own(this, "formSerializer");
14721
- if (contentType.indexOf("application/x-www-form-urlencoded") > -1) {
14722
- return toURLEncodedForm(data, formSerializer).toString();
14723
- }
14724
- if ((isFileList2 = utils_default.isFileList(data)) || contentType.indexOf("multipart/form-data") > -1) {
14725
- const env = own(this, "env");
14726
- const _FormData = env && env.FormData;
14727
- return toFormData_default(
14728
- isFileList2 ? { "files[]": data } : data,
14729
- _FormData && new _FormData(),
14730
- formSerializer
14731
- );
14732
- }
14733
- }
14734
- if (isObjectPayload || hasJSONContentType) {
14735
- headers.setContentType("application/json", false);
14736
- return stringifySafely(data);
14737
- }
14738
- return data;
14739
- }
14740
- ],
14741
- transformResponse: [
14742
- function transformResponse(data) {
14743
- const transitional2 = own(this, "transitional") || defaults.transitional;
14744
- const forcedJSONParsing = transitional2 && transitional2.forcedJSONParsing;
14745
- const responseType = own(this, "responseType");
14746
- const JSONRequested = responseType === "json";
14747
- if (utils_default.isResponse(data) || utils_default.isReadableStream(data)) {
14748
- return data;
14749
- }
14750
- if (data && utils_default.isString(data) && (forcedJSONParsing && !responseType || JSONRequested)) {
14751
- const silentJSONParsing = transitional2 && transitional2.silentJSONParsing;
14752
- const strictJSONParsing = !silentJSONParsing && JSONRequested;
14753
- try {
14754
- return JSON.parse(data, own(this, "parseReviver"));
14755
- } catch (e) {
14756
- if (strictJSONParsing) {
14757
- if (e.name === "SyntaxError") {
14758
- throw AxiosError_default.from(e, AxiosError_default.ERR_BAD_RESPONSE, this, null, own(this, "response"));
14759
- }
14760
- throw e;
14761
- }
14762
- }
14763
- }
14764
- return data;
14765
- }
14766
- ],
14767
- /**
14768
- * A timeout in milliseconds to abort a request. If set to 0 (default) a
14769
- * timeout is not created.
14770
- */
14771
- timeout: 0,
14772
- xsrfCookieName: "XSRF-TOKEN",
14773
- xsrfHeaderName: "X-XSRF-TOKEN",
14774
- maxContentLength: -1,
14775
- maxBodyLength: -1,
14776
- env: {
14777
- FormData: platform_default.classes.FormData,
14778
- Blob: platform_default.classes.Blob
14779
- },
14780
- validateStatus: function validateStatus(status) {
14781
- return status >= 200 && status < 300;
14782
- },
14783
- headers: {
14784
- common: {
14785
- Accept: "application/json, text/plain, */*",
14786
- "Content-Type": void 0
15168
+ formData = formData || new (FormData_default || FormData)();
15169
+ options = utils_default.toFlatObject(
15170
+ options,
15171
+ {
15172
+ metaTokens: true,
15173
+ dots: false,
15174
+ indexes: false
15175
+ },
15176
+ false,
15177
+ function defined(option, source) {
15178
+ return !utils_default.isUndefined(source[option]);
14787
15179
  }
15180
+ );
15181
+ const metaTokens = options.metaTokens;
15182
+ const visitor = options.visitor || defaultVisitor;
15183
+ const dots = options.dots;
15184
+ const indexes = options.indexes;
15185
+ const _Blob = options.Blob || typeof Blob !== "undefined" && Blob;
15186
+ const maxDepth = options.maxDepth === void 0 ? 100 : options.maxDepth;
15187
+ const useBlob = _Blob && utils_default.isSpecCompliantForm(formData);
15188
+ if (!utils_default.isFunction(visitor)) {
15189
+ throw new TypeError("visitor must be a function");
14788
15190
  }
14789
- };
14790
- utils_default.forEach(["delete", "get", "head", "post", "put", "patch"], (method) => {
14791
- defaults.headers[method] = {};
14792
- });
14793
- var defaults_default = defaults;
14794
-
14795
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/parseHeaders.js
14796
- var ignoreDuplicateOf = utils_default.toObjectSet([
14797
- "age",
14798
- "authorization",
14799
- "content-length",
14800
- "content-type",
14801
- "etag",
14802
- "expires",
14803
- "from",
14804
- "host",
14805
- "if-modified-since",
14806
- "if-unmodified-since",
14807
- "last-modified",
14808
- "location",
14809
- "max-forwards",
14810
- "proxy-authorization",
14811
- "referer",
14812
- "retry-after",
14813
- "user-agent"
14814
- ]);
14815
- var parseHeaders_default = (rawHeaders) => {
14816
- const parsed = {};
14817
- let key;
14818
- let val;
14819
- let i;
14820
- rawHeaders && rawHeaders.split("\n").forEach(function parser(line) {
14821
- i = line.indexOf(":");
14822
- key = line.substring(0, i).trim().toLowerCase();
14823
- val = line.substring(i + 1).trim();
14824
- if (!key || parsed[key] && ignoreDuplicateOf[key]) {
14825
- return;
15191
+ function convertValue(value) {
15192
+ if (value === null) return "";
15193
+ if (utils_default.isDate(value)) {
15194
+ return value.toISOString();
14826
15195
  }
14827
- if (key === "set-cookie") {
14828
- if (parsed[key]) {
14829
- parsed[key].push(val);
14830
- } else {
14831
- parsed[key] = [val];
15196
+ if (utils_default.isBoolean(value)) {
15197
+ return value.toString();
15198
+ }
15199
+ if (!useBlob && utils_default.isBlob(value)) {
15200
+ throw new AxiosError_default("Blob is not supported. Use a Buffer instead.");
15201
+ }
15202
+ if (utils_default.isArrayBuffer(value) || utils_default.isTypedArray(value)) {
15203
+ return useBlob && typeof Blob === "function" ? new Blob([value]) : Buffer.from(value);
15204
+ }
15205
+ return value;
15206
+ }
15207
+ function defaultVisitor(value, key, path) {
15208
+ let arr = value;
15209
+ if (utils_default.isReactNative(formData) && utils_default.isReactNativeBlob(value)) {
15210
+ formData.append(renderKey(path, key, dots), convertValue(value));
15211
+ return false;
15212
+ }
15213
+ if (value && !path && typeof value === "object") {
15214
+ if (utils_default.endsWith(key, "{}")) {
15215
+ key = metaTokens ? key : key.slice(0, -2);
15216
+ value = JSON.stringify(value);
15217
+ } else if (utils_default.isArray(value) && isFlatArray(value) || (utils_default.isFileList(value) || utils_default.endsWith(key, "[]")) && (arr = utils_default.toArray(value))) {
15218
+ key = removeBrackets(key);
15219
+ arr.forEach(function each(el, index) {
15220
+ !(utils_default.isUndefined(el) || el === null) && formData.append(
15221
+ // eslint-disable-next-line no-nested-ternary
15222
+ indexes === true ? renderKey([key], index, dots) : indexes === null ? key : key + "[]",
15223
+ convertValue(el)
15224
+ );
15225
+ });
15226
+ return false;
14832
15227
  }
14833
- } else {
14834
- parsed[key] = parsed[key] ? parsed[key] + ", " + val : val;
14835
15228
  }
14836
- });
14837
- return parsed;
14838
- };
14839
-
14840
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/AxiosHeaders.js
14841
- var $internals = /* @__PURE__ */ Symbol("internals");
14842
- var INVALID_HEADER_VALUE_CHARS_RE = /[^\x09\x20-\x7E\x80-\xFF]/g;
14843
- function trimSPorHTAB(str) {
14844
- let start = 0;
14845
- let end = str.length;
14846
- while (start < end) {
14847
- const code = str.charCodeAt(start);
14848
- if (code !== 9 && code !== 32) {
14849
- break;
15229
+ if (isVisitable(value)) {
15230
+ return true;
14850
15231
  }
14851
- start += 1;
15232
+ formData.append(renderKey(path, key, dots), convertValue(value));
15233
+ return false;
14852
15234
  }
14853
- while (end > start) {
14854
- const code = str.charCodeAt(end - 1);
14855
- if (code !== 9 && code !== 32) {
14856
- break;
15235
+ const stack = [];
15236
+ const exposedHelpers = Object.assign(predicates, {
15237
+ defaultVisitor,
15238
+ convertValue,
15239
+ isVisitable
15240
+ });
15241
+ function build(value, path, depth = 0) {
15242
+ if (utils_default.isUndefined(value)) return;
15243
+ if (depth > maxDepth) {
15244
+ throw new AxiosError_default(
15245
+ "Object is too deeply nested (" + depth + " levels). Max depth: " + maxDepth,
15246
+ AxiosError_default.ERR_FORM_DATA_DEPTH_EXCEEDED
15247
+ );
14857
15248
  }
14858
- end -= 1;
15249
+ if (stack.indexOf(value) !== -1) {
15250
+ throw Error("Circular reference detected in " + path.join("."));
15251
+ }
15252
+ stack.push(value);
15253
+ utils_default.forEach(value, function each(el, key) {
15254
+ const result = !(utils_default.isUndefined(el) || el === null) && visitor.call(formData, el, utils_default.isString(key) ? key.trim() : key, path, exposedHelpers);
15255
+ if (result === true) {
15256
+ build(el, path ? path.concat(key) : [key], depth + 1);
15257
+ }
15258
+ });
15259
+ stack.pop();
14859
15260
  }
14860
- return start === 0 && end === str.length ? str : str.slice(start, end);
15261
+ if (!utils_default.isObject(obj)) {
15262
+ throw new TypeError("data must be an object");
15263
+ }
15264
+ build(obj);
15265
+ return formData;
14861
15266
  }
14862
- function normalizeHeader(header) {
14863
- return header && String(header).trim().toLowerCase();
15267
+ var toFormData_default = toFormData;
15268
+
15269
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/AxiosURLSearchParams.js
15270
+ function encode(str) {
15271
+ const charMap = {
15272
+ "!": "%21",
15273
+ "'": "%27",
15274
+ "(": "%28",
15275
+ ")": "%29",
15276
+ "~": "%7E",
15277
+ "%20": "+"
15278
+ };
15279
+ return encodeURIComponent(str).replace(/[!'()~]|%20/g, function replacer(match) {
15280
+ return charMap[match];
15281
+ });
14864
15282
  }
14865
- function sanitizeHeaderValue(str) {
14866
- return trimSPorHTAB(str.replace(INVALID_HEADER_VALUE_CHARS_RE, ""));
15283
+ function AxiosURLSearchParams(params, options) {
15284
+ this._pairs = [];
15285
+ params && toFormData_default(params, this, options);
14867
15286
  }
14868
- function normalizeValue(value) {
14869
- if (value === false || value == null) {
14870
- return value;
14871
- }
14872
- return utils_default.isArray(value) ? value.map(normalizeValue) : sanitizeHeaderValue(String(value));
15287
+ var prototype = AxiosURLSearchParams.prototype;
15288
+ prototype.append = function append(name, value) {
15289
+ this._pairs.push([name, value]);
15290
+ };
15291
+ prototype.toString = function toString2(encoder) {
15292
+ const _encode = encoder ? function(value) {
15293
+ return encoder.call(this, value, encode);
15294
+ } : encode;
15295
+ return this._pairs.map(function each(pair) {
15296
+ return _encode(pair[0]) + "=" + _encode(pair[1]);
15297
+ }, "").join("&");
15298
+ };
15299
+ var AxiosURLSearchParams_default = AxiosURLSearchParams;
15300
+
15301
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/buildURL.js
15302
+ function encode2(val) {
15303
+ return encodeURIComponent(val).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
14873
15304
  }
14874
- function parseTokens(str) {
14875
- const tokens = /* @__PURE__ */ Object.create(null);
14876
- const tokensRE = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
14877
- let match;
14878
- while (match = tokensRE.exec(str)) {
14879
- tokens[match[1]] = match[2];
15305
+ function buildURL(url2, params, options) {
15306
+ if (!params) {
15307
+ return url2;
14880
15308
  }
14881
- return tokens;
15309
+ const _encode = options && options.encode || encode2;
15310
+ const _options = utils_default.isFunction(options) ? {
15311
+ serialize: options
15312
+ } : options;
15313
+ const serializeFn = _options && _options.serialize;
15314
+ let serializedParams;
15315
+ if (serializeFn) {
15316
+ serializedParams = serializeFn(params, _options);
15317
+ } else {
15318
+ serializedParams = utils_default.isURLSearchParams(params) ? params.toString() : new AxiosURLSearchParams_default(params, _options).toString(_encode);
15319
+ }
15320
+ if (serializedParams) {
15321
+ const hashmarkIndex = url2.indexOf("#");
15322
+ if (hashmarkIndex !== -1) {
15323
+ url2 = url2.slice(0, hashmarkIndex);
15324
+ }
15325
+ url2 += (url2.indexOf("?") === -1 ? "?" : "&") + serializedParams;
15326
+ }
15327
+ return url2;
14882
15328
  }
14883
- var isValidHeaderName = (str) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
14884
- function matchHeaderValue(context, value, header, filter2, isHeaderNameFilter) {
14885
- if (utils_default.isFunction(filter2)) {
14886
- return filter2.call(this, value, header);
15329
+
15330
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/InterceptorManager.js
15331
+ var InterceptorManager = class {
15332
+ constructor() {
15333
+ this.handlers = [];
14887
15334
  }
14888
- if (isHeaderNameFilter) {
14889
- value = header;
15335
+ /**
15336
+ * Add a new interceptor to the stack
15337
+ *
15338
+ * @param {Function} fulfilled The function to handle `then` for a `Promise`
15339
+ * @param {Function} rejected The function to handle `reject` for a `Promise`
15340
+ * @param {Object} options The options for the interceptor, synchronous and runWhen
15341
+ *
15342
+ * @return {Number} An ID used to remove interceptor later
15343
+ */
15344
+ use(fulfilled, rejected, options) {
15345
+ this.handlers.push({
15346
+ fulfilled,
15347
+ rejected,
15348
+ synchronous: options ? options.synchronous : false,
15349
+ runWhen: options ? options.runWhen : null
15350
+ });
15351
+ return this.handlers.length - 1;
14890
15352
  }
14891
- if (!utils_default.isString(value)) return;
14892
- if (utils_default.isString(filter2)) {
14893
- return value.indexOf(filter2) !== -1;
15353
+ /**
15354
+ * Remove an interceptor from the stack
15355
+ *
15356
+ * @param {Number} id The ID that was returned by `use`
15357
+ *
15358
+ * @returns {void}
15359
+ */
15360
+ eject(id) {
15361
+ if (this.handlers[id]) {
15362
+ this.handlers[id] = null;
15363
+ }
14894
15364
  }
14895
- if (utils_default.isRegExp(filter2)) {
14896
- return filter2.test(value);
15365
+ /**
15366
+ * Clear all interceptors from the stack
15367
+ *
15368
+ * @returns {void}
15369
+ */
15370
+ clear() {
15371
+ if (this.handlers) {
15372
+ this.handlers = [];
15373
+ }
15374
+ }
15375
+ /**
15376
+ * Iterate over all the registered interceptors
15377
+ *
15378
+ * This method is particularly useful for skipping over any
15379
+ * interceptors that may have become `null` calling `eject`.
15380
+ *
15381
+ * @param {Function} fn The function to call for each interceptor
15382
+ *
15383
+ * @returns {void}
15384
+ */
15385
+ forEach(fn) {
15386
+ utils_default.forEach(this.handlers, function forEachHandler(h) {
15387
+ if (h !== null) {
15388
+ fn(h);
15389
+ }
15390
+ });
15391
+ }
15392
+ };
15393
+ var InterceptorManager_default = InterceptorManager;
15394
+
15395
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/defaults/transitional.js
15396
+ var transitional_default = {
15397
+ silentJSONParsing: true,
15398
+ forcedJSONParsing: true,
15399
+ clarifyTimeoutError: false,
15400
+ legacyInterceptorReqResOrdering: true
15401
+ };
15402
+
15403
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/node/index.js
15404
+ import crypto2 from "crypto";
15405
+
15406
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/node/classes/URLSearchParams.js
15407
+ import url from "url";
15408
+ var URLSearchParams_default = url.URLSearchParams;
15409
+
15410
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/node/index.js
15411
+ var ALPHA = "abcdefghijklmnopqrstuvwxyz";
15412
+ var DIGIT = "0123456789";
15413
+ var ALPHABET = {
15414
+ DIGIT,
15415
+ ALPHA,
15416
+ ALPHA_DIGIT: ALPHA + ALPHA.toUpperCase() + DIGIT
15417
+ };
15418
+ var generateString = (size = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
15419
+ let str = "";
15420
+ const { length } = alphabet;
15421
+ const randomValues = new Uint32Array(size);
15422
+ crypto2.randomFillSync(randomValues);
15423
+ for (let i = 0; i < size; i++) {
15424
+ str += alphabet[randomValues[i] % length];
14897
15425
  }
14898
- }
14899
- function formatHeader(header) {
14900
- return header.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (w2, char, str) => {
14901
- return char.toUpperCase() + str;
15426
+ return str;
15427
+ };
15428
+ var node_default = {
15429
+ isNode: true,
15430
+ classes: {
15431
+ URLSearchParams: URLSearchParams_default,
15432
+ FormData: FormData_default,
15433
+ Blob: typeof Blob !== "undefined" && Blob || null
15434
+ },
15435
+ ALPHABET,
15436
+ generateString,
15437
+ protocols: ["http", "https", "file", "data"]
15438
+ };
15439
+
15440
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/common/utils.js
15441
+ var utils_exports = {};
15442
+ __export(utils_exports, {
15443
+ hasBrowserEnv: () => hasBrowserEnv,
15444
+ hasStandardBrowserEnv: () => hasStandardBrowserEnv,
15445
+ hasStandardBrowserWebWorkerEnv: () => hasStandardBrowserWebWorkerEnv,
15446
+ navigator: () => _navigator,
15447
+ origin: () => origin
15448
+ });
15449
+ var hasBrowserEnv = typeof window !== "undefined" && typeof document !== "undefined";
15450
+ var _navigator = typeof navigator === "object" && navigator || void 0;
15451
+ var hasStandardBrowserEnv = hasBrowserEnv && (!_navigator || ["ReactNative", "NativeScript", "NS"].indexOf(_navigator.product) < 0);
15452
+ var hasStandardBrowserWebWorkerEnv = (() => {
15453
+ return typeof WorkerGlobalScope !== "undefined" && // eslint-disable-next-line no-undef
15454
+ self instanceof WorkerGlobalScope && typeof self.importScripts === "function";
15455
+ })();
15456
+ var origin = hasBrowserEnv && window.location.href || "http://localhost";
15457
+
15458
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/platform/index.js
15459
+ var platform_default = {
15460
+ ...utils_exports,
15461
+ ...node_default
15462
+ };
15463
+
15464
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/toURLEncodedForm.js
15465
+ function toURLEncodedForm(data, options) {
15466
+ return toFormData_default(data, new platform_default.classes.URLSearchParams(), {
15467
+ visitor: function(value, key, path, helpers) {
15468
+ if (platform_default.isNode && utils_default.isBuffer(value)) {
15469
+ this.append(key, value.toString("base64"));
15470
+ return false;
15471
+ }
15472
+ return helpers.defaultVisitor.apply(this, arguments);
15473
+ },
15474
+ ...options
14902
15475
  });
14903
15476
  }
14904
- function buildAccessors(obj, header) {
14905
- const accessorName = utils_default.toCamelCase(" " + header);
14906
- ["get", "set", "has"].forEach((methodName) => {
14907
- Object.defineProperty(obj, methodName + accessorName, {
14908
- value: function(arg1, arg2, arg3) {
14909
- return this[methodName].call(this, header, arg1, arg2, arg3);
14910
- },
14911
- configurable: true
14912
- });
15477
+
15478
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/formDataToJSON.js
15479
+ function parsePropPath(name) {
15480
+ return utils_default.matchAll(/\w+|\[(\w*)]/g, name).map((match) => {
15481
+ return match[0] === "[]" ? "" : match[1] || match[0];
14913
15482
  });
14914
15483
  }
14915
- var AxiosHeaders = class {
14916
- constructor(headers) {
14917
- headers && this.set(headers);
15484
+ function arrayToObject(arr) {
15485
+ const obj = {};
15486
+ const keys = Object.keys(arr);
15487
+ let i;
15488
+ const len = keys.length;
15489
+ let key;
15490
+ for (i = 0; i < len; i++) {
15491
+ key = keys[i];
15492
+ obj[key] = arr[key];
14918
15493
  }
14919
- set(header, valueOrRewrite, rewrite) {
14920
- const self2 = this;
14921
- function setHeader(_value, _header, _rewrite) {
14922
- const lHeader = normalizeHeader(_header);
14923
- if (!lHeader) {
14924
- throw new Error("header name must be a non-empty string");
14925
- }
14926
- const key = utils_default.findKey(self2, lHeader);
14927
- if (!key || self2[key] === void 0 || _rewrite === true || _rewrite === void 0 && self2[key] !== false) {
14928
- self2[key || _header] = normalizeValue(_value);
15494
+ return obj;
15495
+ }
15496
+ function formDataToJSON(formData) {
15497
+ function buildPath(path, value, target, index) {
15498
+ let name = path[index++];
15499
+ if (name === "__proto__") return true;
15500
+ const isNumericKey = Number.isFinite(+name);
15501
+ const isLast = index >= path.length;
15502
+ name = !name && utils_default.isArray(target) ? target.length : name;
15503
+ if (isLast) {
15504
+ if (utils_default.hasOwnProp(target, name)) {
15505
+ target[name] = utils_default.isArray(target[name]) ? target[name].concat(value) : [target[name], value];
15506
+ } else {
15507
+ target[name] = value;
14929
15508
  }
15509
+ return !isNumericKey;
14930
15510
  }
14931
- const setHeaders = (headers, _rewrite) => utils_default.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
14932
- if (utils_default.isPlainObject(header) || header instanceof this.constructor) {
14933
- setHeaders(header, valueOrRewrite);
14934
- } else if (utils_default.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
14935
- setHeaders(parseHeaders_default(header), valueOrRewrite);
14936
- } else if (utils_default.isObject(header) && utils_default.isIterable(header)) {
14937
- let obj = {}, dest, key;
14938
- for (const entry of header) {
14939
- if (!utils_default.isArray(entry)) {
14940
- throw TypeError("Object iterator must return a key-value pair");
14941
- }
14942
- obj[key = entry[0]] = (dest = obj[key]) ? utils_default.isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]] : entry[1];
14943
- }
14944
- setHeaders(obj, valueOrRewrite);
14945
- } else {
14946
- header != null && setHeader(valueOrRewrite, header, rewrite);
15511
+ if (!utils_default.hasOwnProp(target, name) || !utils_default.isObject(target[name])) {
15512
+ target[name] = [];
14947
15513
  }
14948
- return this;
14949
- }
14950
- get(header, parser) {
14951
- header = normalizeHeader(header);
14952
- if (header) {
14953
- const key = utils_default.findKey(this, header);
14954
- if (key) {
14955
- const value = this[key];
14956
- if (!parser) {
14957
- return value;
14958
- }
14959
- if (parser === true) {
14960
- return parseTokens(value);
14961
- }
14962
- if (utils_default.isFunction(parser)) {
14963
- return parser.call(this, value, key);
14964
- }
14965
- if (utils_default.isRegExp(parser)) {
14966
- return parser.exec(value);
14967
- }
14968
- throw new TypeError("parser must be boolean|regexp|function");
14969
- }
15514
+ const result = buildPath(path, value, target[name], index);
15515
+ if (result && utils_default.isArray(target[name])) {
15516
+ target[name] = arrayToObject(target[name]);
14970
15517
  }
15518
+ return !isNumericKey;
14971
15519
  }
14972
- has(header, matcher) {
14973
- header = normalizeHeader(header);
14974
- if (header) {
14975
- const key = utils_default.findKey(this, header);
14976
- return !!(key && this[key] !== void 0 && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
14977
- }
14978
- return false;
15520
+ if (utils_default.isFormData(formData) && utils_default.isFunction(formData.entries)) {
15521
+ const obj = {};
15522
+ utils_default.forEachEntry(formData, (name, value) => {
15523
+ buildPath(parsePropPath(name), value, obj, 0);
15524
+ });
15525
+ return obj;
14979
15526
  }
14980
- delete(header, matcher) {
14981
- const self2 = this;
14982
- let deleted = false;
14983
- function deleteHeader(_header) {
14984
- _header = normalizeHeader(_header);
14985
- if (_header) {
14986
- const key = utils_default.findKey(self2, _header);
14987
- if (key && (!matcher || matchHeaderValue(self2, self2[key], key, matcher))) {
14988
- delete self2[key];
14989
- deleted = true;
14990
- }
15527
+ return null;
15528
+ }
15529
+ var formDataToJSON_default = formDataToJSON;
15530
+
15531
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/defaults/index.js
15532
+ var own = (obj, key) => obj != null && utils_default.hasOwnProp(obj, key) ? obj[key] : void 0;
15533
+ function stringifySafely(rawValue, parser, encoder) {
15534
+ if (utils_default.isString(rawValue)) {
15535
+ try {
15536
+ (parser || JSON.parse)(rawValue);
15537
+ return utils_default.trim(rawValue);
15538
+ } catch (e) {
15539
+ if (e.name !== "SyntaxError") {
15540
+ throw e;
14991
15541
  }
14992
15542
  }
14993
- if (utils_default.isArray(header)) {
14994
- header.forEach(deleteHeader);
14995
- } else {
14996
- deleteHeader(header);
14997
- }
14998
- return deleted;
14999
15543
  }
15000
- clear(matcher) {
15001
- const keys = Object.keys(this);
15002
- let i = keys.length;
15003
- let deleted = false;
15004
- while (i--) {
15005
- const key = keys[i];
15006
- if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
15007
- delete this[key];
15008
- deleted = true;
15544
+ return (encoder || JSON.stringify)(rawValue);
15545
+ }
15546
+ var defaults = {
15547
+ transitional: transitional_default,
15548
+ adapter: ["xhr", "http", "fetch"],
15549
+ transformRequest: [
15550
+ function transformRequest(data, headers) {
15551
+ const contentType = headers.getContentType() || "";
15552
+ const hasJSONContentType = contentType.indexOf("application/json") > -1;
15553
+ const isObjectPayload = utils_default.isObject(data);
15554
+ if (isObjectPayload && utils_default.isHTMLForm(data)) {
15555
+ data = new FormData(data);
15009
15556
  }
15010
- }
15011
- return deleted;
15012
- }
15013
- normalize(format) {
15014
- const self2 = this;
15015
- const headers = {};
15016
- utils_default.forEach(this, (value, header) => {
15017
- const key = utils_default.findKey(headers, header);
15018
- if (key) {
15019
- self2[key] = normalizeValue(value);
15020
- delete self2[header];
15021
- return;
15557
+ const isFormData2 = utils_default.isFormData(data);
15558
+ if (isFormData2) {
15559
+ return hasJSONContentType ? JSON.stringify(formDataToJSON_default(data)) : data;
15560
+ }
15561
+ if (utils_default.isArrayBuffer(data) || utils_default.isBuffer(data) || utils_default.isStream(data) || utils_default.isFile(data) || utils_default.isBlob(data) || utils_default.isReadableStream(data)) {
15562
+ return data;
15563
+ }
15564
+ if (utils_default.isArrayBufferView(data)) {
15565
+ return data.buffer;
15566
+ }
15567
+ if (utils_default.isURLSearchParams(data)) {
15568
+ headers.setContentType("application/x-www-form-urlencoded;charset=utf-8", false);
15569
+ return data.toString();
15570
+ }
15571
+ let isFileList2;
15572
+ if (isObjectPayload) {
15573
+ const formSerializer = own(this, "formSerializer");
15574
+ if (contentType.indexOf("application/x-www-form-urlencoded") > -1) {
15575
+ return toURLEncodedForm(data, formSerializer).toString();
15576
+ }
15577
+ if ((isFileList2 = utils_default.isFileList(data)) || contentType.indexOf("multipart/form-data") > -1) {
15578
+ const env = own(this, "env");
15579
+ const _FormData = env && env.FormData;
15580
+ return toFormData_default(
15581
+ isFileList2 ? { "files[]": data } : data,
15582
+ _FormData && new _FormData(),
15583
+ formSerializer
15584
+ );
15585
+ }
15586
+ }
15587
+ if (isObjectPayload || hasJSONContentType) {
15588
+ headers.setContentType("application/json", false);
15589
+ return stringifySafely(data);
15022
15590
  }
15023
- const normalized = format ? formatHeader(header) : String(header).trim();
15024
- if (normalized !== header) {
15025
- delete self2[header];
15591
+ return data;
15592
+ }
15593
+ ],
15594
+ transformResponse: [
15595
+ function transformResponse(data) {
15596
+ const transitional2 = own(this, "transitional") || defaults.transitional;
15597
+ const forcedJSONParsing = transitional2 && transitional2.forcedJSONParsing;
15598
+ const responseType = own(this, "responseType");
15599
+ const JSONRequested = responseType === "json";
15600
+ if (utils_default.isResponse(data) || utils_default.isReadableStream(data)) {
15601
+ return data;
15026
15602
  }
15027
- self2[normalized] = normalizeValue(value);
15028
- headers[normalized] = true;
15029
- });
15030
- return this;
15031
- }
15032
- concat(...targets) {
15033
- return this.constructor.concat(this, ...targets);
15034
- }
15035
- toJSON(asStrings) {
15036
- const obj = /* @__PURE__ */ Object.create(null);
15037
- utils_default.forEach(this, (value, header) => {
15038
- value != null && value !== false && (obj[header] = asStrings && utils_default.isArray(value) ? value.join(", ") : value);
15039
- });
15040
- return obj;
15041
- }
15042
- [Symbol.iterator]() {
15043
- return Object.entries(this.toJSON())[Symbol.iterator]();
15044
- }
15045
- toString() {
15046
- return Object.entries(this.toJSON()).map(([header, value]) => header + ": " + value).join("\n");
15047
- }
15048
- getSetCookie() {
15049
- return this.get("set-cookie") || [];
15050
- }
15051
- get [Symbol.toStringTag]() {
15052
- return "AxiosHeaders";
15053
- }
15054
- static from(thing) {
15055
- return thing instanceof this ? thing : new this(thing);
15056
- }
15057
- static concat(first, ...targets) {
15058
- const computed = new this(first);
15059
- targets.forEach((target) => computed.set(target));
15060
- return computed;
15061
- }
15062
- static accessor(header) {
15063
- const internals = this[$internals] = this[$internals] = {
15064
- accessors: {}
15065
- };
15066
- const accessors = internals.accessors;
15067
- const prototype2 = this.prototype;
15068
- function defineAccessor(_header) {
15069
- const lHeader = normalizeHeader(_header);
15070
- if (!accessors[lHeader]) {
15071
- buildAccessors(prototype2, _header);
15072
- accessors[lHeader] = true;
15603
+ if (data && utils_default.isString(data) && (forcedJSONParsing && !responseType || JSONRequested)) {
15604
+ const silentJSONParsing = transitional2 && transitional2.silentJSONParsing;
15605
+ const strictJSONParsing = !silentJSONParsing && JSONRequested;
15606
+ try {
15607
+ return JSON.parse(data, own(this, "parseReviver"));
15608
+ } catch (e) {
15609
+ if (strictJSONParsing) {
15610
+ if (e.name === "SyntaxError") {
15611
+ throw AxiosError_default.from(e, AxiosError_default.ERR_BAD_RESPONSE, this, null, own(this, "response"));
15612
+ }
15613
+ throw e;
15614
+ }
15615
+ }
15073
15616
  }
15617
+ return data;
15618
+ }
15619
+ ],
15620
+ /**
15621
+ * A timeout in milliseconds to abort a request. If set to 0 (default) a
15622
+ * timeout is not created.
15623
+ */
15624
+ timeout: 0,
15625
+ xsrfCookieName: "XSRF-TOKEN",
15626
+ xsrfHeaderName: "X-XSRF-TOKEN",
15627
+ maxContentLength: -1,
15628
+ maxBodyLength: -1,
15629
+ env: {
15630
+ FormData: platform_default.classes.FormData,
15631
+ Blob: platform_default.classes.Blob
15632
+ },
15633
+ validateStatus: function validateStatus(status) {
15634
+ return status >= 200 && status < 300;
15635
+ },
15636
+ headers: {
15637
+ common: {
15638
+ Accept: "application/json, text/plain, */*",
15639
+ "Content-Type": void 0
15074
15640
  }
15075
- utils_default.isArray(header) ? header.forEach(defineAccessor) : defineAccessor(header);
15076
- return this;
15077
15641
  }
15078
15642
  };
15079
- AxiosHeaders.accessor([
15080
- "Content-Type",
15081
- "Content-Length",
15082
- "Accept",
15083
- "Accept-Encoding",
15084
- "User-Agent",
15085
- "Authorization"
15086
- ]);
15087
- utils_default.reduceDescriptors(AxiosHeaders.prototype, ({ value }, key) => {
15088
- let mapped = key[0].toUpperCase() + key.slice(1);
15089
- return {
15090
- get: () => value,
15091
- set(headerValue) {
15092
- this[mapped] = headerValue;
15093
- }
15094
- };
15643
+ utils_default.forEach(["delete", "get", "head", "post", "put", "patch", "query"], (method) => {
15644
+ defaults.headers[method] = {};
15095
15645
  });
15096
- utils_default.freezeMethods(AxiosHeaders);
15097
- var AxiosHeaders_default = AxiosHeaders;
15646
+ var defaults_default = defaults;
15098
15647
 
15099
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/transformData.js
15648
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/transformData.js
15100
15649
  function transformData(fns, response) {
15101
15650
  const config2 = this || defaults_default;
15102
15651
  const context = response || config2;
@@ -15109,12 +15658,12 @@ function transformData(fns, response) {
15109
15658
  return data;
15110
15659
  }
15111
15660
 
15112
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/cancel/isCancel.js
15661
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/cancel/isCancel.js
15113
15662
  function isCancel(value) {
15114
15663
  return !!(value && value.__CANCEL__);
15115
15664
  }
15116
15665
 
15117
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/cancel/CanceledError.js
15666
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/cancel/CanceledError.js
15118
15667
  var CanceledError = class extends AxiosError_default {
15119
15668
  /**
15120
15669
  * A `CanceledError` is an object that is thrown when an operation is canceled.
@@ -15133,25 +15682,23 @@ var CanceledError = class extends AxiosError_default {
15133
15682
  };
15134
15683
  var CanceledError_default = CanceledError;
15135
15684
 
15136
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/settle.js
15685
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/settle.js
15137
15686
  function settle(resolve, reject, response) {
15138
15687
  const validateStatus2 = response.config.validateStatus;
15139
15688
  if (!response.status || !validateStatus2 || validateStatus2(response.status)) {
15140
15689
  resolve(response);
15141
15690
  } else {
15142
- reject(
15143
- new AxiosError_default(
15144
- "Request failed with status code " + response.status,
15145
- [AxiosError_default.ERR_BAD_REQUEST, AxiosError_default.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
15146
- response.config,
15147
- response.request,
15148
- response
15149
- )
15150
- );
15691
+ reject(new AxiosError_default(
15692
+ "Request failed with status code " + response.status,
15693
+ response.status >= 400 && response.status < 500 ? AxiosError_default.ERR_BAD_REQUEST : AxiosError_default.ERR_BAD_RESPONSE,
15694
+ response.config,
15695
+ response.request,
15696
+ response
15697
+ ));
15151
15698
  }
15152
15699
  }
15153
15700
 
15154
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/isAbsoluteURL.js
15701
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/isAbsoluteURL.js
15155
15702
  function isAbsoluteURL(url2) {
15156
15703
  if (typeof url2 !== "string") {
15157
15704
  return false;
@@ -15159,12 +15706,12 @@ function isAbsoluteURL(url2) {
15159
15706
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url2);
15160
15707
  }
15161
15708
 
15162
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/combineURLs.js
15709
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/combineURLs.js
15163
15710
  function combineURLs(baseURL, relativeURL) {
15164
15711
  return relativeURL ? baseURL.replace(/\/?\/$/, "") + "/" + relativeURL.replace(/^\/+/, "") : baseURL;
15165
15712
  }
15166
15713
 
15167
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/buildFullPath.js
15714
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/buildFullPath.js
15168
15715
  function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
15169
15716
  let isRelativeUrl = !isAbsoluteURL(requestedURL);
15170
15717
  if (baseURL && (isRelativeUrl || allowAbsoluteUrls === false)) {
@@ -15240,7 +15787,8 @@ function getEnv(key) {
15240
15787
  return process.env[key.toLowerCase()] || process.env[key.toUpperCase()] || "";
15241
15788
  }
15242
15789
 
15243
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/http.js
15790
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/http.js
15791
+ var import_https_proxy_agent = __toESM(require_dist(), 1);
15244
15792
  var import_follow_redirects = __toESM(require_follow_redirects(), 1);
15245
15793
  import http from "http";
15246
15794
  import https from "https";
@@ -15249,17 +15797,17 @@ import util2 from "util";
15249
15797
  import { resolve as resolvePath } from "path";
15250
15798
  import zlib from "zlib";
15251
15799
 
15252
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/env/data.js
15253
- var VERSION = "1.15.2";
15800
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/env/data.js
15801
+ var VERSION = "1.16.1";
15254
15802
 
15255
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/parseProtocol.js
15803
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/parseProtocol.js
15256
15804
  function parseProtocol(url2) {
15257
- const match = /^([-+\w]{1,25})(:?\/\/|:)/.exec(url2);
15805
+ const match = /^([-+\w]{1,25}):(?:\/\/)?/.exec(url2);
15258
15806
  return match && match[1] || "";
15259
15807
  }
15260
15808
 
15261
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/fromDataURI.js
15262
- var DATA_URL_PATTERN = /^(?:([^;]+);)?(?:[^;]+;)?(base64|),([\s\S]*)$/;
15809
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/fromDataURI.js
15810
+ var DATA_URL_PATTERN = /^([^,;]+\/[^,;]+)?((?:;[^,;=]+=[^,;]+)*)(;base64)?,([\s\S]*)$/;
15263
15811
  function fromDataURI(uri, asBlob, options) {
15264
15812
  const _Blob = options && options.Blob || platform_default.classes.Blob;
15265
15813
  const protocol = parseProtocol(uri);
@@ -15272,10 +15820,17 @@ function fromDataURI(uri, asBlob, options) {
15272
15820
  if (!match) {
15273
15821
  throw new AxiosError_default("Invalid URL", AxiosError_default.ERR_INVALID_URL);
15274
15822
  }
15275
- const mime = match[1];
15276
- const isBase64 = match[2];
15277
- const body = match[3];
15278
- const buffer = Buffer.from(decodeURIComponent(body), isBase64 ? "base64" : "utf8");
15823
+ const type = match[1];
15824
+ const params = match[2];
15825
+ const encoding = match[3] ? "base64" : "utf8";
15826
+ const body = match[4];
15827
+ let mime;
15828
+ if (type) {
15829
+ mime = params ? type + params : type;
15830
+ } else if (params) {
15831
+ mime = "text/plain" + params;
15832
+ }
15833
+ const buffer = Buffer.from(decodeURIComponent(body), encoding);
15279
15834
  if (asBlob) {
15280
15835
  if (!_Blob) {
15281
15836
  throw new AxiosError_default("Blob is not supported", AxiosError_default.ERR_NOT_SUPPORT);
@@ -15287,10 +15842,10 @@ function fromDataURI(uri, asBlob, options) {
15287
15842
  throw new AxiosError_default("Unsupported protocol " + protocol, AxiosError_default.ERR_NOT_SUPPORT);
15288
15843
  }
15289
15844
 
15290
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/http.js
15845
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/http.js
15291
15846
  import stream3 from "stream";
15292
15847
 
15293
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/AxiosTransformStream.js
15848
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/AxiosTransformStream.js
15294
15849
  import stream from "stream";
15295
15850
  var kInternals = /* @__PURE__ */ Symbol("internals");
15296
15851
  var AxiosTransformStream = class extends stream.Transform {
@@ -15413,14 +15968,14 @@ var AxiosTransformStream = class extends stream.Transform {
15413
15968
  };
15414
15969
  var AxiosTransformStream_default = AxiosTransformStream;
15415
15970
 
15416
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/http.js
15971
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/http.js
15417
15972
  import { EventEmitter } from "events";
15418
15973
 
15419
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/formDataToStream.js
15974
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/formDataToStream.js
15420
15975
  import util from "util";
15421
15976
  import { Readable } from "stream";
15422
15977
 
15423
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/readBlob.js
15978
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/readBlob.js
15424
15979
  var { asyncIterator } = Symbol;
15425
15980
  var readBlob = async function* (blob) {
15426
15981
  if (blob.stream) {
@@ -15435,7 +15990,7 @@ var readBlob = async function* (blob) {
15435
15990
  };
15436
15991
  var readBlob_default = readBlob;
15437
15992
 
15438
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/formDataToStream.js
15993
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/formDataToStream.js
15439
15994
  var BOUNDARY_ALPHABET = platform_default.ALPHABET.ALPHA_DIGIT + "-_";
15440
15995
  var textEncoder = typeof TextEncoder === "function" ? new TextEncoder() : new util.TextEncoder();
15441
15996
  var CRLF = "\r\n";
@@ -15489,7 +16044,7 @@ var formDataToStream = (form, headersHandler, options) => {
15489
16044
  throw TypeError("FormData instance required");
15490
16045
  }
15491
16046
  if (boundary.length < 1 || boundary.length > 70) {
15492
- throw Error("boundary must be 10-70 characters long");
16047
+ throw Error("boundary must be 1-70 characters long");
15493
16048
  }
15494
16049
  const boundaryBytes = textEncoder.encode("--" + boundary + CRLF);
15495
16050
  const footerBytes = textEncoder.encode("--" + boundary + "--" + CRLF);
@@ -15520,7 +16075,7 @@ var formDataToStream = (form, headersHandler, options) => {
15520
16075
  };
15521
16076
  var formDataToStream_default = formDataToStream;
15522
16077
 
15523
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js
16078
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js
15524
16079
  import stream2 from "stream";
15525
16080
  var ZlibHeaderTransformStream = class extends stream2.Transform {
15526
16081
  __transform(chunk, encoding, callback) {
@@ -15542,7 +16097,7 @@ var ZlibHeaderTransformStream = class extends stream2.Transform {
15542
16097
  };
15543
16098
  var ZlibHeaderTransformStream_default = ZlibHeaderTransformStream;
15544
16099
 
15545
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/callbackify.js
16100
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/callbackify.js
15546
16101
  var callbackify = (fn, reducer) => {
15547
16102
  return utils_default.isAsyncFn(fn) ? function(...args) {
15548
16103
  const cb = args.pop();
@@ -15557,7 +16112,7 @@ var callbackify = (fn, reducer) => {
15557
16112
  };
15558
16113
  var callbackify_default = callbackify;
15559
16114
 
15560
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/shouldBypassProxy.js
16115
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/shouldBypassProxy.js
15561
16116
  var LOOPBACK_HOSTNAMES = /* @__PURE__ */ new Set(["localhost"]);
15562
16117
  var isIPv4Loopback = (host) => {
15563
16118
  const parts = host.split(".");
@@ -15618,6 +16173,20 @@ var parseNoProxyEntry = (entry) => {
15618
16173
  }
15619
16174
  return [entryHost, entryPort];
15620
16175
  };
16176
+ var IPV4_MAPPED_DOTTED_RE = /^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:(\d+\.\d+\.\d+\.\d+)$/i;
16177
+ var IPV4_MAPPED_HEX_RE = /^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i;
16178
+ var unmapIPv4MappedIPv6 = (host) => {
16179
+ if (typeof host !== "string" || host.indexOf(":") === -1) return host;
16180
+ const dotted = host.match(IPV4_MAPPED_DOTTED_RE);
16181
+ if (dotted) return dotted[1];
16182
+ const hex = host.match(IPV4_MAPPED_HEX_RE);
16183
+ if (hex) {
16184
+ const high = parseInt(hex[1], 16);
16185
+ const low = parseInt(hex[2], 16);
16186
+ return `${high >> 8}.${high & 255}.${low >> 8}.${low & 255}`;
16187
+ }
16188
+ return host;
16189
+ };
15621
16190
  var normalizeNoProxyHost = (hostname) => {
15622
16191
  if (!hostname) {
15623
16192
  return hostname;
@@ -15625,7 +16194,7 @@ var normalizeNoProxyHost = (hostname) => {
15625
16194
  if (hostname.charAt(0) === "[" && hostname.charAt(hostname.length - 1) === "]") {
15626
16195
  hostname = hostname.slice(1, -1);
15627
16196
  }
15628
- return hostname.replace(/\.+$/, "");
16197
+ return unmapIPv4MappedIPv6(hostname.replace(/\.+$/, ""));
15629
16198
  };
15630
16199
  function shouldBypassProxy(location) {
15631
16200
  let parsed;
@@ -15665,7 +16234,7 @@ function shouldBypassProxy(location) {
15665
16234
  });
15666
16235
  }
15667
16236
 
15668
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/speedometer.js
16237
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/speedometer.js
15669
16238
  function speedometer(samplesCount, min2) {
15670
16239
  samplesCount = samplesCount || 10;
15671
16240
  const bytes = new Array(samplesCount);
@@ -15701,7 +16270,7 @@ function speedometer(samplesCount, min2) {
15701
16270
  }
15702
16271
  var speedometer_default = speedometer;
15703
16272
 
15704
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/throttle.js
16273
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/throttle.js
15705
16274
  function throttle(fn, freq) {
15706
16275
  let timestamp = 0;
15707
16276
  let threshold = 1e3 / freq;
@@ -15736,11 +16305,14 @@ function throttle(fn, freq) {
15736
16305
  }
15737
16306
  var throttle_default = throttle;
15738
16307
 
15739
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/progressEventReducer.js
16308
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/progressEventReducer.js
15740
16309
  var progressEventReducer = (listener, isDownloadStream, freq = 3) => {
15741
16310
  let bytesNotified = 0;
15742
16311
  const _speedometer = speedometer_default(50, 250);
15743
16312
  return throttle_default((e) => {
16313
+ if (!e || typeof e.loaded !== "number") {
16314
+ return;
16315
+ }
15744
16316
  const rawLoaded = e.loaded;
15745
16317
  const total = e.lengthComputable ? e.total : void 0;
15746
16318
  const loaded = total != null ? Math.min(rawLoaded, total) : rawLoaded;
@@ -15774,7 +16346,7 @@ var progressEventDecorator = (total, throttled) => {
15774
16346
  };
15775
16347
  var asyncDecorator = (fn) => (...args) => utils_default.asap(() => fn(...args));
15776
16348
 
15777
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/estimateDataURLDecodedBytes.js
16349
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/estimateDataURLDecodedBytes.js
15778
16350
  function estimateDataURLDecodedBytes(url2) {
15779
16351
  if (!url2 || typeof url2 !== "string") return 0;
15780
16352
  if (!url2.startsWith("data:")) return 0;
@@ -15819,13 +16391,35 @@ function estimateDataURLDecodedBytes(url2) {
15819
16391
  }
15820
16392
  }
15821
16393
  const groups = Math.floor(effectiveLen / 4);
15822
- const bytes = groups * 3 - (pad || 0);
15823
- return bytes > 0 ? bytes : 0;
16394
+ const bytes2 = groups * 3 - (pad || 0);
16395
+ return bytes2 > 0 ? bytes2 : 0;
16396
+ }
16397
+ if (typeof Buffer !== "undefined" && typeof Buffer.byteLength === "function") {
16398
+ return Buffer.byteLength(body, "utf8");
16399
+ }
16400
+ let bytes = 0;
16401
+ for (let i = 0, len = body.length; i < len; i++) {
16402
+ const c = body.charCodeAt(i);
16403
+ if (c < 128) {
16404
+ bytes += 1;
16405
+ } else if (c < 2048) {
16406
+ bytes += 2;
16407
+ } else if (c >= 55296 && c <= 56319 && i + 1 < len) {
16408
+ const next = body.charCodeAt(i + 1);
16409
+ if (next >= 56320 && next <= 57343) {
16410
+ bytes += 4;
16411
+ i++;
16412
+ } else {
16413
+ bytes += 3;
16414
+ }
16415
+ } else {
16416
+ bytes += 3;
16417
+ }
15824
16418
  }
15825
- return Buffer.byteLength(body, "utf8");
16419
+ return bytes;
15826
16420
  }
15827
16421
 
15828
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/http.js
16422
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/http.js
15829
16423
  var zlibOptions = {
15830
16424
  flush: zlib.constants.Z_SYNC_FLUSH,
15831
16425
  finishFlush: zlib.constants.Z_SYNC_FLUSH
@@ -15837,11 +16431,47 @@ var brotliOptions = {
15837
16431
  var isBrotliSupported = utils_default.isFunction(zlib.createBrotliDecompress);
15838
16432
  var { http: httpFollow, https: httpsFollow } = import_follow_redirects.default;
15839
16433
  var isHttps = /https:?/;
16434
+ var FORM_DATA_CONTENT_HEADERS = ["content-type", "content-length"];
16435
+ function setFormDataHeaders(headers, formHeaders, policy) {
16436
+ if (policy !== "content-only") {
16437
+ headers.set(formHeaders);
16438
+ return;
16439
+ }
16440
+ Object.entries(formHeaders).forEach(([key, val]) => {
16441
+ if (FORM_DATA_CONTENT_HEADERS.includes(key.toLowerCase())) {
16442
+ headers.set(key, val);
16443
+ }
16444
+ });
16445
+ }
15840
16446
  var kAxiosSocketListener = /* @__PURE__ */ Symbol("axios.http.socketListener");
15841
16447
  var kAxiosCurrentReq = /* @__PURE__ */ Symbol("axios.http.currentReq");
16448
+ var kAxiosInstalledTunnel = /* @__PURE__ */ Symbol("axios.http.installedTunnel");
16449
+ var tunnelingAgentCache = /* @__PURE__ */ new Map();
16450
+ var tunnelingAgentCacheUser = /* @__PURE__ */ new WeakMap();
16451
+ function getTunnelingAgent(agentOptions, userHttpsAgent) {
16452
+ const key = agentOptions.protocol + "//" + agentOptions.hostname + ":" + (agentOptions.port || "") + "#" + (agentOptions.auth || "");
16453
+ const cache = userHttpsAgent ? tunnelingAgentCacheUser.get(userHttpsAgent) || tunnelingAgentCacheUser.set(userHttpsAgent, /* @__PURE__ */ new Map()).get(userHttpsAgent) : tunnelingAgentCache;
16454
+ let agent = cache.get(key);
16455
+ if (agent) return agent;
16456
+ const merged = userHttpsAgent && userHttpsAgent.options ? { ...userHttpsAgent.options, ...agentOptions } : agentOptions;
16457
+ agent = new import_https_proxy_agent.default(merged);
16458
+ agent[kAxiosInstalledTunnel] = true;
16459
+ cache.set(key, agent);
16460
+ return agent;
16461
+ }
15842
16462
  var supportedProtocols = platform_default.protocols.map((protocol) => {
15843
16463
  return protocol + ":";
15844
16464
  });
16465
+ var decodeURIComponentSafe = (value) => {
16466
+ if (!utils_default.isString(value)) {
16467
+ return value;
16468
+ }
16469
+ try {
16470
+ return decodeURIComponent(value);
16471
+ } catch (error) {
16472
+ return value;
16473
+ }
16474
+ };
15845
16475
  var flushOnFinish = (stream4, [throttled, flush]) => {
15846
16476
  stream4.on("end", flush).on("error", flush);
15847
16477
  return throttled;
@@ -15919,15 +16549,15 @@ var Http2Sessions = class {
15919
16549
  }
15920
16550
  };
15921
16551
  var http2Sessions = new Http2Sessions();
15922
- function dispatchBeforeRedirect(options, responseDetails) {
16552
+ function dispatchBeforeRedirect(options, responseDetails, requestDetails) {
15923
16553
  if (options.beforeRedirects.proxy) {
15924
16554
  options.beforeRedirects.proxy(options);
15925
16555
  }
15926
16556
  if (options.beforeRedirects.config) {
15927
- options.beforeRedirects.config(options, responseDetails);
16557
+ options.beforeRedirects.config(options, responseDetails, requestDetails);
15928
16558
  }
15929
16559
  }
15930
- function setProxy(options, configProxy, location) {
16560
+ function setProxy(options, configProxy, location, isRedirect, configHttpsAgent) {
15931
16561
  let proxy = configProxy;
15932
16562
  if (!proxy && proxy !== false) {
15933
16563
  const proxyUrl = getProxyForUrl(location);
@@ -15937,32 +16567,90 @@ function setProxy(options, configProxy, location) {
15937
16567
  }
15938
16568
  }
15939
16569
  }
15940
- if (proxy) {
15941
- if (proxy.username) {
15942
- proxy.auth = (proxy.username || "") + ":" + (proxy.password || "");
16570
+ if (isRedirect && options.headers) {
16571
+ for (const name of Object.keys(options.headers)) {
16572
+ if (name.toLowerCase() === "proxy-authorization") {
16573
+ delete options.headers[name];
16574
+ }
15943
16575
  }
15944
- if (proxy.auth) {
15945
- const validProxyAuth = Boolean(proxy.auth.username || proxy.auth.password);
16576
+ }
16577
+ if (isRedirect && options.agent && options.agent[kAxiosInstalledTunnel]) {
16578
+ options.agent = void 0;
16579
+ }
16580
+ if (proxy) {
16581
+ const isProxyURL = proxy instanceof URL;
16582
+ const readProxyField = (key) => isProxyURL || utils_default.hasOwnProp(proxy, key) ? proxy[key] : void 0;
16583
+ const proxyUsername = readProxyField("username");
16584
+ const proxyPassword = readProxyField("password");
16585
+ let proxyAuth = utils_default.hasOwnProp(proxy, "auth") ? proxy.auth : void 0;
16586
+ if (proxyUsername) {
16587
+ proxyAuth = (proxyUsername || "") + ":" + (proxyPassword || "");
16588
+ }
16589
+ if (proxyAuth) {
16590
+ const authIsObject = typeof proxyAuth === "object";
16591
+ const authUsername = authIsObject && utils_default.hasOwnProp(proxyAuth, "username") ? proxyAuth.username : void 0;
16592
+ const authPassword = authIsObject && utils_default.hasOwnProp(proxyAuth, "password") ? proxyAuth.password : void 0;
16593
+ const validProxyAuth = Boolean(authUsername || authPassword);
15946
16594
  if (validProxyAuth) {
15947
- proxy.auth = (proxy.auth.username || "") + ":" + (proxy.auth.password || "");
15948
- } else if (typeof proxy.auth === "object") {
16595
+ proxyAuth = (authUsername || "") + ":" + (authPassword || "");
16596
+ } else if (authIsObject) {
15949
16597
  throw new AxiosError_default("Invalid proxy authorization", AxiosError_default.ERR_BAD_OPTION, { proxy });
15950
16598
  }
15951
- const base64 = Buffer.from(proxy.auth, "utf8").toString("base64");
15952
- options.headers["Proxy-Authorization"] = "Basic " + base64;
15953
16599
  }
15954
- options.headers.host = options.hostname + (options.port ? ":" + options.port : "");
15955
- const proxyHost = proxy.hostname || proxy.host;
15956
- options.hostname = proxyHost;
15957
- options.host = proxyHost;
15958
- options.port = proxy.port;
15959
- options.path = location;
15960
- if (proxy.protocol) {
15961
- options.protocol = proxy.protocol.includes(":") ? proxy.protocol : `${proxy.protocol}:`;
16600
+ const targetIsHttps = isHttps.test(options.protocol);
16601
+ if (targetIsHttps) {
16602
+ if (!(configHttpsAgent instanceof import_https_proxy_agent.default)) {
16603
+ const proxyHost = readProxyField("hostname") || readProxyField("host");
16604
+ const proxyPort = readProxyField("port");
16605
+ const rawProxyProtocol = readProxyField("protocol");
16606
+ const normalizedProtocol = rawProxyProtocol ? rawProxyProtocol.includes(":") ? rawProxyProtocol : `${rawProxyProtocol}:` : "http:";
16607
+ const proxyHostForURL = proxyHost && proxyHost.includes(":") && !proxyHost.startsWith("[") ? `[${proxyHost}]` : proxyHost;
16608
+ const proxyURL = new URL(
16609
+ `${normalizedProtocol}//${proxyHostForURL}${proxyPort ? ":" + proxyPort : ""}`
16610
+ );
16611
+ const agentOptions = {
16612
+ protocol: proxyURL.protocol,
16613
+ hostname: proxyURL.hostname.replace(/^\[|\]$/g, ""),
16614
+ port: proxyURL.port,
16615
+ auth: proxyAuth && typeof proxyAuth === "string" ? proxyAuth : void 0
16616
+ };
16617
+ if (proxyURL.protocol === "https:") {
16618
+ agentOptions.ALPNProtocols = ["http/1.1"];
16619
+ }
16620
+ const tunnelingAgent = getTunnelingAgent(agentOptions, configHttpsAgent);
16621
+ options.agent = tunnelingAgent;
16622
+ if (options.agents) {
16623
+ options.agents.https = tunnelingAgent;
16624
+ }
16625
+ }
16626
+ } else {
16627
+ if (proxyAuth) {
16628
+ const base64 = Buffer.from(proxyAuth, "utf8").toString("base64");
16629
+ options.headers["Proxy-Authorization"] = "Basic " + base64;
16630
+ }
16631
+ let hasUserHostHeader = false;
16632
+ for (const name of Object.keys(options.headers)) {
16633
+ if (name.toLowerCase() === "host") {
16634
+ hasUserHostHeader = true;
16635
+ break;
16636
+ }
16637
+ }
16638
+ if (!hasUserHostHeader) {
16639
+ options.headers.host = options.hostname + (options.port ? ":" + options.port : "");
16640
+ }
16641
+ const proxyHost = readProxyField("hostname") || readProxyField("host");
16642
+ options.hostname = proxyHost;
16643
+ options.host = proxyHost;
16644
+ options.port = readProxyField("port");
16645
+ options.path = location;
16646
+ const proxyProtocol = readProxyField("protocol");
16647
+ if (proxyProtocol) {
16648
+ options.protocol = proxyProtocol.includes(":") ? proxyProtocol : `${proxyProtocol}:`;
16649
+ }
15962
16650
  }
15963
16651
  }
15964
16652
  options.beforeRedirects.proxy = function beforeRedirect(redirectOptions) {
15965
- setProxy(redirectOptions, configProxy, redirectOptions.href);
16653
+ setProxy(redirectOptions, configProxy, redirectOptions.href, true, configHttpsAgent);
15966
16654
  };
15967
16655
  }
15968
16656
  var isHttpAdapterSupported = typeof process !== "undefined" && utils_default.kindOf(process) === "process";
@@ -16038,6 +16726,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16038
16726
  let isDone;
16039
16727
  let rejected = false;
16040
16728
  let req;
16729
+ let connectPhaseTimer;
16041
16730
  httpVersion = +httpVersion;
16042
16731
  if (Number.isNaN(httpVersion)) {
16043
16732
  throw TypeError(`Invalid protocol version: '${config2.httpVersion}' is not a number`);
@@ -16069,8 +16758,28 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16069
16758
  console.warn("emit error", err);
16070
16759
  }
16071
16760
  }
16761
+ function clearConnectPhaseTimer() {
16762
+ if (connectPhaseTimer) {
16763
+ clearTimeout(connectPhaseTimer);
16764
+ connectPhaseTimer = null;
16765
+ }
16766
+ }
16767
+ function createTimeoutError() {
16768
+ let timeoutErrorMessage = config2.timeout ? "timeout of " + config2.timeout + "ms exceeded" : "timeout exceeded";
16769
+ const transitional2 = config2.transitional || transitional_default;
16770
+ if (config2.timeoutErrorMessage) {
16771
+ timeoutErrorMessage = config2.timeoutErrorMessage;
16772
+ }
16773
+ return new AxiosError_default(
16774
+ timeoutErrorMessage,
16775
+ transitional2.clarifyTimeoutError ? AxiosError_default.ETIMEDOUT : AxiosError_default.ECONNABORTED,
16776
+ config2,
16777
+ req
16778
+ );
16779
+ }
16072
16780
  abortEmitter.once("abort", reject);
16073
16781
  const onFinished = () => {
16782
+ clearConnectPhaseTimer();
16074
16783
  if (config2.cancelToken) {
16075
16784
  config2.cancelToken.unsubscribe(abort);
16076
16785
  }
@@ -16087,6 +16796,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16087
16796
  }
16088
16797
  onDone((response, isRejected) => {
16089
16798
  isDone = true;
16799
+ clearConnectPhaseTimer();
16090
16800
  if (isRejected) {
16091
16801
  rejected = true;
16092
16802
  onFinished();
@@ -16175,7 +16885,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16175
16885
  }
16176
16886
  );
16177
16887
  } else if (utils_default.isFormData(data) && utils_default.isFunction(data.getHeaders) && data.getHeaders !== Object.prototype.getHeaders) {
16178
- headers.set(data.getHeaders());
16888
+ setFormDataHeaders(headers, data.getHeaders(), own2("formDataHeaderPolicy"));
16179
16889
  if (!headers.hasContentLength()) {
16180
16890
  try {
16181
16891
  const knownLength = await util2.promisify(data.getLength).call(data);
@@ -16252,8 +16962,8 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16252
16962
  auth = username + ":" + password;
16253
16963
  }
16254
16964
  if (!auth && parsed.username) {
16255
- const urlUsername = parsed.username;
16256
- const urlPassword = parsed.password;
16965
+ const urlUsername = decodeURIComponentSafe(parsed.username);
16966
+ const urlPassword = decodeURIComponentSafe(parsed.password);
16257
16967
  auth = urlUsername + ":" + urlPassword;
16258
16968
  }
16259
16969
  auth && headers.delete("authorization");
@@ -16279,7 +16989,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16279
16989
  const options = Object.assign(/* @__PURE__ */ Object.create(null), {
16280
16990
  path,
16281
16991
  method,
16282
- headers: headers.toJSON(),
16992
+ headers: toByteStringHeaderObject(headers),
16283
16993
  agents: { http: config2.httpAgent, https: config2.httpsAgent },
16284
16994
  auth,
16285
16995
  protocol,
@@ -16291,11 +17001,9 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16291
17001
  !utils_default.isUndefined(lookup) && (options.lookup = lookup);
16292
17002
  if (config2.socketPath) {
16293
17003
  if (typeof config2.socketPath !== "string") {
16294
- return reject(new AxiosError_default(
16295
- "socketPath must be a string",
16296
- AxiosError_default.ERR_BAD_OPTION_VALUE,
16297
- config2
16298
- ));
17004
+ return reject(
17005
+ new AxiosError_default("socketPath must be a string", AxiosError_default.ERR_BAD_OPTION_VALUE, config2)
17006
+ );
16299
17007
  }
16300
17008
  if (config2.allowedSocketPaths != null) {
16301
17009
  const allowed = Array.isArray(config2.allowedSocketPaths) ? config2.allowedSocketPaths : [config2.allowedSocketPaths];
@@ -16304,11 +17012,13 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16304
17012
  (entry) => typeof entry === "string" && resolvePath(entry) === resolvedSocket
16305
17013
  );
16306
17014
  if (!isAllowed) {
16307
- return reject(new AxiosError_default(
16308
- `socketPath "${config2.socketPath}" is not permitted by allowedSocketPaths`,
16309
- AxiosError_default.ERR_BAD_OPTION_VALUE,
16310
- config2
16311
- ));
17015
+ return reject(
17016
+ new AxiosError_default(
17017
+ `socketPath "${config2.socketPath}" is not permitted by allowedSocketPaths`,
17018
+ AxiosError_default.ERR_BAD_OPTION_VALUE,
17019
+ config2
17020
+ )
17021
+ );
16312
17022
  }
16313
17023
  }
16314
17024
  options.socketPath = config2.socketPath;
@@ -16318,12 +17028,17 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16318
17028
  setProxy(
16319
17029
  options,
16320
17030
  config2.proxy,
16321
- protocol + "//" + parsed.hostname + (parsed.port ? ":" + parsed.port : "") + options.path
17031
+ protocol + "//" + parsed.hostname + (parsed.port ? ":" + parsed.port : "") + options.path,
17032
+ false,
17033
+ config2.httpsAgent
16322
17034
  );
16323
17035
  }
16324
17036
  let transport;
17037
+ let isNativeTransport = false;
16325
17038
  const isHttpsRequest = isHttps.test(options.protocol);
16326
- options.agent = isHttpsRequest ? config2.httpsAgent : config2.httpAgent;
17039
+ if (options.agent == null) {
17040
+ options.agent = isHttpsRequest ? config2.httpsAgent : config2.httpAgent;
17041
+ }
16327
17042
  if (isHttp2) {
16328
17043
  transport = http2Transport;
16329
17044
  } else {
@@ -16332,6 +17047,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16332
17047
  transport = configTransport;
16333
17048
  } else if (config2.maxRedirects === 0) {
16334
17049
  transport = isHttpsRequest ? https : http;
17050
+ isNativeTransport = true;
16335
17051
  } else {
16336
17052
  if (config2.maxRedirects) {
16337
17053
  options.maxRedirects = config2.maxRedirects;
@@ -16350,6 +17066,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16350
17066
  }
16351
17067
  options.insecureHTTPParser = Boolean(own2("insecureHTTPParser"));
16352
17068
  req = transport.request(options, function handleResponse(res) {
17069
+ clearConnectPhaseTimer();
16353
17070
  if (req.destroyed) return;
16354
17071
  const streams = [res];
16355
17072
  const responseLength = utils_default.toFiniteNumber(res.headers["content-length"]);
@@ -16456,14 +17173,15 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16456
17173
  "stream has been aborted",
16457
17174
  AxiosError_default.ERR_BAD_RESPONSE,
16458
17175
  config2,
16459
- lastRequest
17176
+ lastRequest,
17177
+ response
16460
17178
  );
16461
17179
  responseStream.destroy(err);
16462
17180
  reject(err);
16463
17181
  });
16464
17182
  responseStream.on("error", function handleStreamError(err) {
16465
- if (req.destroyed) return;
16466
- reject(AxiosError_default.from(err, null, config2, lastRequest));
17183
+ if (rejected) return;
17184
+ reject(AxiosError_default.from(err, null, config2, lastRequest, response));
16467
17185
  });
16468
17186
  responseStream.on("end", function handleStreamEnd() {
16469
17187
  try {
@@ -16498,6 +17216,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16498
17216
  req.on("error", function handleRequestError(err) {
16499
17217
  reject(AxiosError_default.from(err, null, config2, req));
16500
17218
  });
17219
+ const boundSockets = /* @__PURE__ */ new Set();
16501
17220
  req.on("socket", function handleRequestSocket(socket) {
16502
17221
  socket.setKeepAlive(true, 1e3 * 60);
16503
17222
  if (!socket[kAxiosSocketListener]) {
@@ -16510,11 +17229,16 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16510
17229
  socket[kAxiosSocketListener] = true;
16511
17230
  }
16512
17231
  socket[kAxiosCurrentReq] = req;
16513
- req.once("close", function clearCurrentReq() {
17232
+ boundSockets.add(socket);
17233
+ });
17234
+ req.once("close", function clearCurrentReq() {
17235
+ clearConnectPhaseTimer();
17236
+ for (const socket of boundSockets) {
16514
17237
  if (socket[kAxiosCurrentReq] === req) {
16515
17238
  socket[kAxiosCurrentReq] = null;
16516
17239
  }
16517
- });
17240
+ }
17241
+ boundSockets.clear();
16518
17242
  });
16519
17243
  if (config2.timeout) {
16520
17244
  const timeout = parseInt(config2.timeout, 10);
@@ -16529,22 +17253,14 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16529
17253
  );
16530
17254
  return;
16531
17255
  }
16532
- req.setTimeout(timeout, function handleRequestTimeout() {
17256
+ const handleTimeout = function handleTimeout2() {
16533
17257
  if (isDone) return;
16534
- let timeoutErrorMessage = config2.timeout ? "timeout of " + config2.timeout + "ms exceeded" : "timeout exceeded";
16535
- const transitional2 = config2.transitional || transitional_default;
16536
- if (config2.timeoutErrorMessage) {
16537
- timeoutErrorMessage = config2.timeoutErrorMessage;
16538
- }
16539
- abort(
16540
- new AxiosError_default(
16541
- timeoutErrorMessage,
16542
- transitional2.clarifyTimeoutError ? AxiosError_default.ETIMEDOUT : AxiosError_default.ECONNABORTED,
16543
- config2,
16544
- req
16545
- )
16546
- );
16547
- });
17258
+ abort(createTimeoutError());
17259
+ };
17260
+ if (isNativeTransport && timeout > 0) {
17261
+ connectPhaseTimer = setTimeout(handleTimeout, timeout);
17262
+ }
17263
+ req.setTimeout(timeout, handleTimeout);
16548
17264
  } else {
16549
17265
  req.setTimeout(0);
16550
17266
  }
@@ -16601,7 +17317,7 @@ var http_default = isHttpAdapterSupported && function httpAdapter(config2) {
16601
17317
  });
16602
17318
  };
16603
17319
 
16604
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/isURLSameOrigin.js
17320
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/isURLSameOrigin.js
16605
17321
  var isURLSameOrigin_default = platform_default.hasStandardBrowserEnv ? /* @__PURE__ */ ((origin2, isMSIE) => (url2) => {
16606
17322
  url2 = new URL(url2, platform_default.origin);
16607
17323
  return origin2.protocol === url2.protocol && origin2.host === url2.host && (isMSIE || origin2.port === url2.port);
@@ -16610,7 +17326,7 @@ var isURLSameOrigin_default = platform_default.hasStandardBrowserEnv ? /* @__PUR
16610
17326
  platform_default.navigator && /(msie|trident)/i.test(platform_default.navigator.userAgent)
16611
17327
  ) : () => true;
16612
17328
 
16613
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/cookies.js
17329
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/cookies.js
16614
17330
  var cookies_default = platform_default.hasStandardBrowserEnv ? (
16615
17331
  // Standard browser envs support document.cookie
16616
17332
  {
@@ -16636,8 +17352,15 @@ var cookies_default = platform_default.hasStandardBrowserEnv ? (
16636
17352
  },
16637
17353
  read(name) {
16638
17354
  if (typeof document === "undefined") return null;
16639
- const match = document.cookie.match(new RegExp("(?:^|; )" + name + "=([^;]*)"));
16640
- return match ? decodeURIComponent(match[1]) : null;
17355
+ const cookies = document.cookie.split(";");
17356
+ for (let i = 0; i < cookies.length; i++) {
17357
+ const cookie = cookies[i].replace(/^\s+/, "");
17358
+ const eq = cookie.indexOf("=");
17359
+ if (eq !== -1 && cookie.slice(0, eq) === name) {
17360
+ return decodeURIComponent(cookie.slice(eq + 1));
17361
+ }
17362
+ }
17363
+ return null;
16641
17364
  },
16642
17365
  remove(name) {
16643
17366
  this.write(name, "", Date.now() - 864e5, "/");
@@ -16656,12 +17379,15 @@ var cookies_default = platform_default.hasStandardBrowserEnv ? (
16656
17379
  }
16657
17380
  );
16658
17381
 
16659
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/mergeConfig.js
17382
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/mergeConfig.js
16660
17383
  var headersToObject = (thing) => thing instanceof AxiosHeaders_default ? { ...thing } : thing;
16661
17384
  function mergeConfig(config1, config2) {
16662
17385
  config2 = config2 || {};
16663
17386
  const config3 = /* @__PURE__ */ Object.create(null);
16664
17387
  Object.defineProperty(config3, "hasOwnProperty", {
17388
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
17389
+ // this data descriptor into an accessor descriptor on the way in.
17390
+ __proto__: null,
16665
17391
  value: Object.prototype.hasOwnProperty,
16666
17392
  enumerable: false,
16667
17393
  writable: true,
@@ -16746,7 +17472,23 @@ function mergeConfig(config1, config2) {
16746
17472
  return config3;
16747
17473
  }
16748
17474
 
16749
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/resolveConfig.js
17475
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/resolveConfig.js
17476
+ var FORM_DATA_CONTENT_HEADERS2 = ["content-type", "content-length"];
17477
+ function setFormDataHeaders2(headers, formHeaders, policy) {
17478
+ if (policy !== "content-only") {
17479
+ headers.set(formHeaders);
17480
+ return;
17481
+ }
17482
+ Object.entries(formHeaders).forEach(([key, val]) => {
17483
+ if (FORM_DATA_CONTENT_HEADERS2.includes(key.toLowerCase())) {
17484
+ headers.set(key, val);
17485
+ }
17486
+ });
17487
+ }
17488
+ var encodeUTF8 = (str) => encodeURIComponent(str).replace(
17489
+ /%([0-9A-F]{2})/gi,
17490
+ (_, hex) => String.fromCharCode(parseInt(hex, 16))
17491
+ );
16750
17492
  var resolveConfig_default = (config2) => {
16751
17493
  const newConfig = mergeConfig({}, config2);
16752
17494
  const own2 = (key) => utils_default.hasOwnProp(newConfig, key) ? newConfig[key] : void 0;
@@ -16768,22 +17510,14 @@ var resolveConfig_default = (config2) => {
16768
17510
  if (auth) {
16769
17511
  headers.set(
16770
17512
  "Authorization",
16771
- "Basic " + btoa(
16772
- (auth.username || "") + ":" + (auth.password ? unescape(encodeURIComponent(auth.password)) : "")
16773
- )
17513
+ "Basic " + btoa((auth.username || "") + ":" + (auth.password ? encodeUTF8(auth.password) : ""))
16774
17514
  );
16775
17515
  }
16776
17516
  if (utils_default.isFormData(data)) {
16777
17517
  if (platform_default.hasStandardBrowserEnv || platform_default.hasStandardBrowserWebWorkerEnv) {
16778
17518
  headers.setContentType(void 0);
16779
17519
  } else if (utils_default.isFunction(data.getHeaders)) {
16780
- const formHeaders = data.getHeaders();
16781
- const allowedHeaders = ["content-type", "content-length"];
16782
- Object.entries(formHeaders).forEach(([key, val]) => {
16783
- if (allowedHeaders.includes(key.toLowerCase())) {
16784
- headers.set(key, val);
16785
- }
16786
- });
17520
+ setFormDataHeaders2(headers, data.getHeaders(), own2("formDataHeaderPolicy"));
16787
17521
  }
16788
17522
  }
16789
17523
  if (platform_default.hasStandardBrowserEnv) {
@@ -16801,7 +17535,7 @@ var resolveConfig_default = (config2) => {
16801
17535
  return newConfig;
16802
17536
  };
16803
17537
 
16804
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/xhr.js
17538
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/xhr.js
16805
17539
  var isXHRAdapterSupported = typeof XMLHttpRequest !== "undefined";
16806
17540
  var xhr_default = isXHRAdapterSupported && function(config2) {
16807
17541
  return new Promise(function dispatchXhrRequest(resolve, reject) {
@@ -16857,7 +17591,7 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16857
17591
  if (!request || request.readyState !== 4) {
16858
17592
  return;
16859
17593
  }
16860
- if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf("file:") === 0)) {
17594
+ if (request.status === 0 && !(request.responseURL && request.responseURL.startsWith("file:"))) {
16861
17595
  return;
16862
17596
  }
16863
17597
  setTimeout(onloadend);
@@ -16868,6 +17602,7 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16868
17602
  return;
16869
17603
  }
16870
17604
  reject(new AxiosError_default("Request aborted", AxiosError_default.ECONNABORTED, config2, request));
17605
+ done();
16871
17606
  request = null;
16872
17607
  };
16873
17608
  request.onerror = function handleError(event) {
@@ -16875,6 +17610,7 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16875
17610
  const err = new AxiosError_default(msg, AxiosError_default.ERR_NETWORK, config2, request);
16876
17611
  err.event = event || null;
16877
17612
  reject(err);
17613
+ done();
16878
17614
  request = null;
16879
17615
  };
16880
17616
  request.ontimeout = function handleTimeout() {
@@ -16891,11 +17627,12 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16891
17627
  request
16892
17628
  )
16893
17629
  );
17630
+ done();
16894
17631
  request = null;
16895
17632
  };
16896
17633
  requestData === void 0 && requestHeaders.setContentType(null);
16897
17634
  if ("setRequestHeader" in request) {
16898
- utils_default.forEach(requestHeaders.toJSON(), function setRequestHeader(val, key) {
17635
+ utils_default.forEach(toByteStringHeaderObject(requestHeaders), function setRequestHeader(val, key) {
16899
17636
  request.setRequestHeader(key, val);
16900
17637
  });
16901
17638
  }
@@ -16921,6 +17658,7 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16921
17658
  }
16922
17659
  reject(!cancel || cancel.type ? new CanceledError_default(null, config2, request) : cancel);
16923
17660
  request.abort();
17661
+ done();
16924
17662
  request = null;
16925
17663
  };
16926
17664
  _config.cancelToken && _config.cancelToken.subscribe(onCanceled);
@@ -16929,7 +17667,7 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16929
17667
  }
16930
17668
  }
16931
17669
  const protocol = parseProtocol(_config.url);
16932
- if (protocol && platform_default.protocols.indexOf(protocol) === -1) {
17670
+ if (protocol && !platform_default.protocols.includes(protocol)) {
16933
17671
  reject(
16934
17672
  new AxiosError_default(
16935
17673
  "Unsupported protocol " + protocol + ":",
@@ -16943,45 +17681,47 @@ var xhr_default = isXHRAdapterSupported && function(config2) {
16943
17681
  });
16944
17682
  };
16945
17683
 
16946
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/composeSignals.js
17684
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/composeSignals.js
16947
17685
  var composeSignals = (signals, timeout) => {
16948
- const { length } = signals = signals ? signals.filter(Boolean) : [];
16949
- if (timeout || length) {
16950
- let controller = new AbortController();
16951
- let aborted;
16952
- const onabort = function(reason) {
16953
- if (!aborted) {
16954
- aborted = true;
16955
- unsubscribe();
16956
- const err = reason instanceof Error ? reason : this.reason;
16957
- controller.abort(
16958
- err instanceof AxiosError_default ? err : new CanceledError_default(err instanceof Error ? err.message : err)
16959
- );
16960
- }
16961
- };
16962
- let timer = timeout && setTimeout(() => {
16963
- timer = null;
16964
- onabort(new AxiosError_default(`timeout of ${timeout}ms exceeded`, AxiosError_default.ETIMEDOUT));
16965
- }, timeout);
16966
- const unsubscribe = () => {
16967
- if (signals) {
16968
- timer && clearTimeout(timer);
16969
- timer = null;
16970
- signals.forEach((signal2) => {
16971
- signal2.unsubscribe ? signal2.unsubscribe(onabort) : signal2.removeEventListener("abort", onabort);
16972
- });
16973
- signals = null;
16974
- }
16975
- };
16976
- signals.forEach((signal2) => signal2.addEventListener("abort", onabort));
16977
- const { signal } = controller;
16978
- signal.unsubscribe = () => utils_default.asap(unsubscribe);
16979
- return signal;
17686
+ signals = signals ? signals.filter(Boolean) : [];
17687
+ if (!timeout && !signals.length) {
17688
+ return;
16980
17689
  }
17690
+ const controller = new AbortController();
17691
+ let aborted = false;
17692
+ const onabort = function(reason) {
17693
+ if (!aborted) {
17694
+ aborted = true;
17695
+ unsubscribe();
17696
+ const err = reason instanceof Error ? reason : this.reason;
17697
+ controller.abort(
17698
+ err instanceof AxiosError_default ? err : new CanceledError_default(err instanceof Error ? err.message : err)
17699
+ );
17700
+ }
17701
+ };
17702
+ let timer = timeout && setTimeout(() => {
17703
+ timer = null;
17704
+ onabort(new AxiosError_default(`timeout of ${timeout}ms exceeded`, AxiosError_default.ETIMEDOUT));
17705
+ }, timeout);
17706
+ const unsubscribe = () => {
17707
+ if (!signals) {
17708
+ return;
17709
+ }
17710
+ timer && clearTimeout(timer);
17711
+ timer = null;
17712
+ signals.forEach((signal2) => {
17713
+ signal2.unsubscribe ? signal2.unsubscribe(onabort) : signal2.removeEventListener("abort", onabort);
17714
+ });
17715
+ signals = null;
17716
+ };
17717
+ signals.forEach((signal2) => signal2.addEventListener("abort", onabort));
17718
+ const { signal } = controller;
17719
+ signal.unsubscribe = () => utils_default.asap(unsubscribe);
17720
+ return signal;
16981
17721
  };
16982
17722
  var composeSignals_default = composeSignals;
16983
17723
 
16984
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/trackStream.js
17724
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/trackStream.js
16985
17725
  var streamChunk = function* (chunk, chunkSize) {
16986
17726
  let len = chunk.byteLength;
16987
17727
  if (!chunkSize || len < chunkSize) {
@@ -17061,14 +17801,9 @@ var trackStream = (stream4, chunkSize, onProgress, onFinish) => {
17061
17801
  );
17062
17802
  };
17063
17803
 
17064
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/fetch.js
17804
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/fetch.js
17065
17805
  var DEFAULT_CHUNK_SIZE = 64 * 1024;
17066
17806
  var { isFunction: isFunction2 } = utils_default;
17067
- var globalFetchAPI = (({ Request, Response }) => ({
17068
- Request,
17069
- Response
17070
- }))(utils_default.global);
17071
- var { ReadableStream: ReadableStream2, TextEncoder: TextEncoder2 } = utils_default.global;
17072
17807
  var test = (fn, ...args) => {
17073
17808
  try {
17074
17809
  return !!fn(...args);
@@ -17077,11 +17812,16 @@ var test = (fn, ...args) => {
17077
17812
  }
17078
17813
  };
17079
17814
  var factory = (env) => {
17815
+ const globalObject = utils_default.global !== void 0 && utils_default.global !== null ? utils_default.global : globalThis;
17816
+ const { ReadableStream: ReadableStream2, TextEncoder: TextEncoder2 } = globalObject;
17080
17817
  env = utils_default.merge.call(
17081
17818
  {
17082
17819
  skipUndefined: true
17083
17820
  },
17084
- globalFetchAPI,
17821
+ {
17822
+ Request: globalObject.Request,
17823
+ Response: globalObject.Response
17824
+ },
17085
17825
  env
17086
17826
  );
17087
17827
  const { fetch: envFetch, Request, Response } = env;
@@ -17169,8 +17909,12 @@ var factory = (env) => {
17169
17909
  responseType,
17170
17910
  headers,
17171
17911
  withCredentials = "same-origin",
17172
- fetchOptions
17912
+ fetchOptions,
17913
+ maxContentLength,
17914
+ maxBodyLength
17173
17915
  } = resolveConfig_default(config2);
17916
+ const hasMaxContentLength = utils_default.isNumber(maxContentLength) && maxContentLength > -1;
17917
+ const hasMaxBodyLength = utils_default.isNumber(maxBodyLength) && maxBodyLength > -1;
17174
17918
  let _fetch2 = envFetch || fetch;
17175
17919
  responseType = responseType ? (responseType + "").toLowerCase() : "text";
17176
17920
  let composedSignal = composeSignals_default(
@@ -17183,6 +17927,28 @@ var factory = (env) => {
17183
17927
  });
17184
17928
  let requestContentLength;
17185
17929
  try {
17930
+ if (hasMaxContentLength && typeof url2 === "string" && url2.startsWith("data:")) {
17931
+ const estimated = estimateDataURLDecodedBytes(url2);
17932
+ if (estimated > maxContentLength) {
17933
+ throw new AxiosError_default(
17934
+ "maxContentLength size of " + maxContentLength + " exceeded",
17935
+ AxiosError_default.ERR_BAD_RESPONSE,
17936
+ config2,
17937
+ request
17938
+ );
17939
+ }
17940
+ }
17941
+ if (hasMaxBodyLength && method !== "get" && method !== "head") {
17942
+ const outboundLength = await resolveBodyLength(headers, data);
17943
+ if (typeof outboundLength === "number" && isFinite(outboundLength) && outboundLength > maxBodyLength) {
17944
+ throw new AxiosError_default(
17945
+ "Request body larger than maxBodyLength limit",
17946
+ AxiosError_default.ERR_BAD_REQUEST,
17947
+ config2,
17948
+ request
17949
+ );
17950
+ }
17951
+ }
17186
17952
  if (onUploadProgress && supportsRequestStream && method !== "get" && method !== "head" && (requestContentLength = await resolveBodyLength(headers, data)) !== 0) {
17187
17953
  let _request = new Request(url2, {
17188
17954
  method: "POST",
@@ -17211,19 +17977,31 @@ var factory = (env) => {
17211
17977
  headers.delete("content-type");
17212
17978
  }
17213
17979
  }
17980
+ headers.set("User-Agent", "axios/" + VERSION, false);
17214
17981
  const resolvedOptions = {
17215
17982
  ...fetchOptions,
17216
17983
  signal: composedSignal,
17217
17984
  method: method.toUpperCase(),
17218
- headers: headers.normalize().toJSON(),
17985
+ headers: toByteStringHeaderObject(headers.normalize()),
17219
17986
  body: data,
17220
17987
  duplex: "half",
17221
17988
  credentials: isCredentialsSupported ? withCredentials : void 0
17222
17989
  };
17223
17990
  request = isRequestSupported && new Request(url2, resolvedOptions);
17224
17991
  let response = await (isRequestSupported ? _fetch2(request, fetchOptions) : _fetch2(url2, resolvedOptions));
17992
+ if (hasMaxContentLength) {
17993
+ const declaredLength = utils_default.toFiniteNumber(response.headers.get("content-length"));
17994
+ if (declaredLength != null && declaredLength > maxContentLength) {
17995
+ throw new AxiosError_default(
17996
+ "maxContentLength size of " + maxContentLength + " exceeded",
17997
+ AxiosError_default.ERR_BAD_RESPONSE,
17998
+ config2,
17999
+ request
18000
+ );
18001
+ }
18002
+ }
17225
18003
  const isStreamResponse = supportsResponseStream && (responseType === "stream" || responseType === "response");
17226
- if (supportsResponseStream && (onDownloadProgress || isStreamResponse && unsubscribe)) {
18004
+ if (supportsResponseStream && response.body && (onDownloadProgress || hasMaxContentLength || isStreamResponse && unsubscribe)) {
17227
18005
  const options = {};
17228
18006
  ["status", "statusText", "headers"].forEach((prop) => {
17229
18007
  options[prop] = response[prop];
@@ -17233,8 +18011,23 @@ var factory = (env) => {
17233
18011
  responseContentLength,
17234
18012
  progressEventReducer(asyncDecorator(onDownloadProgress), true)
17235
18013
  ) || [];
18014
+ let bytesRead = 0;
18015
+ const onChunkProgress = (loadedBytes) => {
18016
+ if (hasMaxContentLength) {
18017
+ bytesRead = loadedBytes;
18018
+ if (bytesRead > maxContentLength) {
18019
+ throw new AxiosError_default(
18020
+ "maxContentLength size of " + maxContentLength + " exceeded",
18021
+ AxiosError_default.ERR_BAD_RESPONSE,
18022
+ config2,
18023
+ request
18024
+ );
18025
+ }
18026
+ }
18027
+ onProgress && onProgress(loadedBytes);
18028
+ };
17236
18029
  response = new Response(
17237
- trackStream(response.body, DEFAULT_CHUNK_SIZE, onProgress, () => {
18030
+ trackStream(response.body, DEFAULT_CHUNK_SIZE, onChunkProgress, () => {
17238
18031
  flush && flush();
17239
18032
  unsubscribe && unsubscribe();
17240
18033
  }),
@@ -17246,6 +18039,26 @@ var factory = (env) => {
17246
18039
  response,
17247
18040
  config2
17248
18041
  );
18042
+ if (hasMaxContentLength && !supportsResponseStream && !isStreamResponse) {
18043
+ let materializedSize;
18044
+ if (responseData != null) {
18045
+ if (typeof responseData.byteLength === "number") {
18046
+ materializedSize = responseData.byteLength;
18047
+ } else if (typeof responseData.size === "number") {
18048
+ materializedSize = responseData.size;
18049
+ } else if (typeof responseData === "string") {
18050
+ materializedSize = typeof TextEncoder2 === "function" ? new TextEncoder2().encode(responseData).byteLength : responseData.length;
18051
+ }
18052
+ }
18053
+ if (typeof materializedSize === "number" && materializedSize > maxContentLength) {
18054
+ throw new AxiosError_default(
18055
+ "maxContentLength size of " + maxContentLength + " exceeded",
18056
+ AxiosError_default.ERR_BAD_RESPONSE,
18057
+ config2,
18058
+ request
18059
+ );
18060
+ }
18061
+ }
17249
18062
  !isStreamResponse && unsubscribe && unsubscribe();
17250
18063
  return await new Promise((resolve, reject) => {
17251
18064
  settle(resolve, reject, {
@@ -17259,6 +18072,13 @@ var factory = (env) => {
17259
18072
  });
17260
18073
  } catch (err) {
17261
18074
  unsubscribe && unsubscribe();
18075
+ if (composedSignal && composedSignal.aborted && composedSignal.reason instanceof AxiosError_default) {
18076
+ const canceledError = composedSignal.reason;
18077
+ canceledError.config = config2;
18078
+ request && (canceledError.request = request);
18079
+ err !== canceledError && (canceledError.cause = err);
18080
+ throw canceledError;
18081
+ }
17262
18082
  if (err && err.name === "TypeError" && /Load failed|fetch/i.test(err.message)) {
17263
18083
  throw Object.assign(
17264
18084
  new AxiosError_default(
@@ -17293,7 +18113,7 @@ var getFetch = (config2) => {
17293
18113
  };
17294
18114
  var adapter = getFetch();
17295
18115
 
17296
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/adapters/adapters.js
18116
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/adapters/adapters.js
17297
18117
  var knownAdapters = {
17298
18118
  http: http_default,
17299
18119
  xhr: xhr_default,
@@ -17304,10 +18124,10 @@ var knownAdapters = {
17304
18124
  utils_default.forEach(knownAdapters, (fn, value) => {
17305
18125
  if (fn) {
17306
18126
  try {
17307
- Object.defineProperty(fn, "name", { value });
18127
+ Object.defineProperty(fn, "name", { __proto__: null, value });
17308
18128
  } catch (e) {
17309
18129
  }
17310
- Object.defineProperty(fn, "adapterName", { value });
18130
+ Object.defineProperty(fn, "adapterName", { __proto__: null, value });
17311
18131
  }
17312
18132
  });
17313
18133
  var renderReason = (reason) => `- ${reason}`;
@@ -17358,7 +18178,7 @@ var adapters_default = {
17358
18178
  adapters: knownAdapters
17359
18179
  };
17360
18180
 
17361
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/dispatchRequest.js
18181
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/dispatchRequest.js
17362
18182
  function throwIfCancellationRequested(config2) {
17363
18183
  if (config2.cancelToken) {
17364
18184
  config2.cancelToken.throwIfRequested();
@@ -17378,7 +18198,12 @@ function dispatchRequest(config2) {
17378
18198
  return adapter2(config2).then(
17379
18199
  function onAdapterResolution(response) {
17380
18200
  throwIfCancellationRequested(config2);
17381
- response.data = transformData.call(config2, config2.transformResponse, response);
18201
+ config2.response = response;
18202
+ try {
18203
+ response.data = transformData.call(config2, config2.transformResponse, response);
18204
+ } finally {
18205
+ delete config2.response;
18206
+ }
17382
18207
  response.headers = AxiosHeaders_default.from(response.headers);
17383
18208
  return response;
17384
18209
  },
@@ -17386,11 +18211,16 @@ function dispatchRequest(config2) {
17386
18211
  if (!isCancel(reason)) {
17387
18212
  throwIfCancellationRequested(config2);
17388
18213
  if (reason && reason.response) {
17389
- reason.response.data = transformData.call(
17390
- config2,
17391
- config2.transformResponse,
17392
- reason.response
17393
- );
18214
+ config2.response = reason.response;
18215
+ try {
18216
+ reason.response.data = transformData.call(
18217
+ config2,
18218
+ config2.transformResponse,
18219
+ reason.response
18220
+ );
18221
+ } finally {
18222
+ delete config2.response;
18223
+ }
17394
18224
  reason.response.headers = AxiosHeaders_default.from(reason.response.headers);
17395
18225
  }
17396
18226
  }
@@ -17399,7 +18229,7 @@ function dispatchRequest(config2) {
17399
18229
  );
17400
18230
  }
17401
18231
 
17402
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/validator.js
18232
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/validator.js
17403
18233
  var validators = {};
17404
18234
  ["object", "boolean", "number", "function", "string", "symbol"].forEach((type, i) => {
17405
18235
  validators[type] = function validator(thing) {
@@ -17466,7 +18296,7 @@ var validator_default = {
17466
18296
  validators
17467
18297
  };
17468
18298
 
17469
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/core/Axios.js
18299
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/core/Axios.js
17470
18300
  var validators2 = validator_default.validators;
17471
18301
  var Axios = class {
17472
18302
  constructor(instanceConfig) {
@@ -17568,7 +18398,7 @@ var Axios = class {
17568
18398
  );
17569
18399
  config2.method = (config2.method || this.defaults.method || "get").toLowerCase();
17570
18400
  let contextHeaders = headers && utils_default.merge(headers.common, headers[config2.method]);
17571
- headers && utils_default.forEach(["delete", "get", "head", "post", "put", "patch", "common"], (method) => {
18401
+ headers && utils_default.forEach(["delete", "get", "head", "post", "put", "patch", "query", "common"], (method) => {
17572
18402
  delete headers[method];
17573
18403
  });
17574
18404
  config2.headers = AxiosHeaders_default.concat(contextHeaders, headers);
@@ -17646,7 +18476,7 @@ utils_default.forEach(["delete", "get", "head", "options"], function forEachMeth
17646
18476
  );
17647
18477
  };
17648
18478
  });
17649
- utils_default.forEach(["post", "put", "patch"], function forEachMethodWithData(method) {
18479
+ utils_default.forEach(["post", "put", "patch", "query"], function forEachMethodWithData(method) {
17650
18480
  function generateHTTPMethod(isForm) {
17651
18481
  return function httpMethod(url2, data, config2) {
17652
18482
  return this.request(
@@ -17662,11 +18492,13 @@ utils_default.forEach(["post", "put", "patch"], function forEachMethodWithData(m
17662
18492
  };
17663
18493
  }
17664
18494
  Axios.prototype[method] = generateHTTPMethod();
17665
- Axios.prototype[method + "Form"] = generateHTTPMethod(true);
18495
+ if (method !== "query") {
18496
+ Axios.prototype[method + "Form"] = generateHTTPMethod(true);
18497
+ }
17666
18498
  });
17667
18499
  var Axios_default = Axios;
17668
18500
 
17669
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/cancel/CancelToken.js
18501
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/cancel/CancelToken.js
17670
18502
  var CancelToken = class _CancelToken {
17671
18503
  constructor(executor) {
17672
18504
  if (typeof executor !== "function") {
@@ -17764,19 +18596,19 @@ var CancelToken = class _CancelToken {
17764
18596
  };
17765
18597
  var CancelToken_default = CancelToken;
17766
18598
 
17767
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/spread.js
18599
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/spread.js
17768
18600
  function spread(callback) {
17769
18601
  return function wrap(arr) {
17770
18602
  return callback.apply(null, arr);
17771
18603
  };
17772
18604
  }
17773
18605
 
17774
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/isAxiosError.js
18606
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/isAxiosError.js
17775
18607
  function isAxiosError(payload) {
17776
18608
  return utils_default.isObject(payload) && payload.isAxiosError === true;
17777
18609
  }
17778
18610
 
17779
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/helpers/HttpStatusCode.js
18611
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/helpers/HttpStatusCode.js
17780
18612
  var HttpStatusCode = {
17781
18613
  Continue: 100,
17782
18614
  SwitchingProtocols: 101,
@@ -17853,13 +18685,13 @@ Object.entries(HttpStatusCode).forEach(([key, value]) => {
17853
18685
  });
17854
18686
  var HttpStatusCode_default = HttpStatusCode;
17855
18687
 
17856
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/lib/axios.js
18688
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/lib/axios.js
17857
18689
  function createInstance(defaultConfig) {
17858
18690
  const context = new Axios_default(defaultConfig);
17859
18691
  const instance = bind(Axios_default.prototype.request, context);
17860
18692
  utils_default.extend(instance, Axios_default.prototype, context, { allOwnKeys: true });
17861
18693
  utils_default.extend(instance, context, null, { allOwnKeys: true });
17862
- instance.create = function create(instanceConfig) {
18694
+ instance.create = function create2(instanceConfig) {
17863
18695
  return createInstance(mergeConfig(defaultConfig, instanceConfig));
17864
18696
  };
17865
18697
  return instance;
@@ -17886,7 +18718,7 @@ axios.HttpStatusCode = HttpStatusCode_default;
17886
18718
  axios.default = axios;
17887
18719
  var axios_default = axios;
17888
18720
 
17889
- // ../../node_modules/.pnpm/axios@1.15.2/node_modules/axios/index.js
18721
+ // ../../node_modules/.pnpm/axios@1.16.1/node_modules/axios/index.js
17890
18722
  var {
17891
18723
  Axios: Axios2,
17892
18724
  AxiosError: AxiosError2,
@@ -17903,7 +18735,8 @@ var {
17903
18735
  HttpStatusCode: HttpStatusCode2,
17904
18736
  formToJSON,
17905
18737
  getAdapter: getAdapter2,
17906
- mergeConfig: mergeConfig2
18738
+ mergeConfig: mergeConfig2,
18739
+ create
17907
18740
  } = axios_default;
17908
18741
 
17909
18742
  // ../../node_modules/.pnpm/zod@3.25.76/node_modules/zod/v3/external.js
@@ -21947,7 +22780,7 @@ var coerce = {
21947
22780
  };
21948
22781
  var NEVER = INVALID;
21949
22782
 
21950
- // ../../node_modules/.pnpm/@zodios+core@10.9.6_axios@1.15.2_zod@3.25.76/node_modules/@zodios/core/lib/index.mjs
22783
+ // ../../node_modules/.pnpm/@zodios+core@10.9.6_axios@1.16.1_zod@3.25.76/node_modules/@zodios/core/lib/index.mjs
21951
22784
  function D(o, e) {
21952
22785
  let t = { ...o };
21953
22786
  for (let i of e) delete t[i];
@@ -22196,7 +23029,7 @@ var B = class {
22196
23029
  };
22197
23030
  var te = B;
22198
23031
 
22199
- // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.15.2/node_modules/@pythnetwork/hermes-client/dist/esm/zodSchemas.mjs
23032
+ // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.16.1/node_modules/@pythnetwork/hermes-client/dist/esm/zodSchemas.mjs
22200
23033
  var AssetType = external_exports.enum([
22201
23034
  "crypto",
22202
23035
  "fx",
@@ -22465,7 +23298,7 @@ Clients should implement reconnection logic to maintain continuous price updates
22465
23298
  ]);
22466
23299
  var api = new te(endpoints);
22467
23300
 
22468
- // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.15.2/node_modules/@pythnetwork/hermes-client/dist/esm/hermes-client.mjs
23301
+ // ../../node_modules/.pnpm/@pythnetwork+hermes-client@3.1.0_axios@1.16.1/node_modules/@pythnetwork/hermes-client/dist/esm/hermes-client.mjs
22469
23302
  var DEFAULT_TIMEOUT = 5e3;
22470
23303
  var DEFAULT_HTTP_RETRIES = 3;
22471
23304
  var HermesClient = class {
@@ -22666,7 +23499,7 @@ var HermesClient = class {
22666
23499
  }
22667
23500
  };
22668
23501
 
22669
- // ../../node_modules/.pnpm/@cetusprotocol+aggregator-sdk@1.4.8_axios@1.15.2_typescript@5.9.3/node_modules/@cetusprotocol/aggregator-sdk/dist/index.js
23502
+ // ../../node_modules/.pnpm/@cetusprotocol+aggregator-sdk@1.4.8_axios@1.16.1_typescript@5.9.3/node_modules/@cetusprotocol/aggregator-sdk/dist/index.js
22670
23503
  var __create = Object.create;
22671
23504
  var __defProp = Object.defineProperty;
22672
23505
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -32559,4 +33392,4 @@ mime-types/index.js:
32559
33392
  *)
32560
33393
  *)
32561
33394
  */
32562
- //# sourceMappingURL=chunk-MBNGFMZQ.js.map
33395
+ //# sourceMappingURL=chunk-UJGE644R.js.map