UNPKG

axios

Version:

Promise based HTTP client for the browser and node.js

4 lines • 58.9 kB
/*! Axios v1.21.0 Copyright (c) 2026 Matt Zabriskie and contributors */
function e(e,t){return function(){return e.apply(t,arguments)}}const{toString:t}=Object.prototype,{getPrototypeOf:n}=Object,{iterator:r,toStringTag:o}=Symbol,s=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),i=e=>"string"==typeof e&&("__proto__"===e||"constructor"===e||"prototype"===e),a=(e,t,n)=>e===Object.prototype||!n&&null===t,c=(e,t)=>{let r=e;const o=[];for(;null!=r;){if(-1!==o.indexOf(r))return!1;o.push(r);const i=n(r);if(a(r,i,r===e))return!1;if(s(r,t))return!0;r=i}return!1},l=(u=Object.create(null),e=>{const n=t.call(e);return u[n]||(u[n]=n.slice(8,-1).toLowerCase())});var u;const f=e=>(e=e.toLowerCase(),t=>l(t)===e),d=e=>t=>typeof t===e,{isArray:p}=Array,h=d("undefined");function m(e){return null!==e&&!h(e)&&null!==e.constructor&&!h(e.constructor)&&y(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const g=f("ArrayBuffer");const b=d("string"),y=d("function"),w=d("number"),O=e=>null!==e&&"object"==typeof e,E=e=>{if(!O(e))return!1;const t=n(e);return(null===t||t===Object.prototype||null===n(t))&&(a(e,t,!0)||!s(e,o)&&!s(e,r))},R=f("Date"),S=f("File"),_=f("Blob"),v=f("FileList"),A=f("Set");const P="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},T=void 0!==P.FormData?P.FormData:void 0,j=f("URLSearchParams"),[C,N,x,U]=["ReadableStream","Request","Response","Headers"].map(f);function D(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),p(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{if(m(e))return;const o=n?Object.getOwnPropertyNames(e):Object.keys(e),s=o.length;let i;for(r=0;r<s;r++)i=o[r],t.call(null,e[i],i,e)}}const L="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,F=e=>!h(e)&&e!==L;const B=(k="undefined"!=typeof Uint8Array&&n(Uint8Array),e=>k&&e instanceof k);var k;const I=f("HTMLFormElement"),{propertyIsEnumerable:q}=Object.prototype,M=f("RegExp"),z=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};D(n,(n,o)=>{let s;!1!==(s=t(n,o,e))&&(r[o]=s||n)}),Object.defineProperties(e,r)};const $=f("AsyncFunction"),H=(W="function"==typeof setImmediate,J=y(L.postMessage),W?setImmediate:J?(V=`axios@${Math.random()}`,K=[],L.addEventListener("message",({source:e,data:t})=>{e===L&&t===V&&K.length&&K.shift()()},!1),e=>{K.push(e),L.postMessage(V,"*")}):e=>setTimeout(e));var W,J,V,K;const X="undefined"!=typeof queueMicrotask?queueMicrotask.bind(L):"undefined"!=typeof process&&process.nextTick||H,Q=e=>null!=e&&y(e[r]);var Z={isArray:p,isArrayBuffer:g,isBuffer:m,isFormData:e=>{if(!e)return!1;if(T&&e instanceof T)return!0;const t=n(e);if(!t||t===Object.prototype)return!1;if(!y(e.append))return!1;const r=l(e);return"formdata"===r||"object"===r&&y(e.toString)&&"[object FormData]"===e.toString()},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&g(e.buffer),t},isString:b,isNumber:w,isBoolean:e=>!0===e||!1===e,isObject:O,isPlainObject:E,isEmptyObject:e=>{if(!O(e)||m(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(e){return!1}},isReadableStream:C,isRequest:N,isResponse:x,isHeaders:U,isUndefined:h,isDate:R,isFile:S,isReactNativeBlob:e=>!(!e||void 0===e.uri),isReactNative:e=>e&&void 0!==e.getParts,isBlob:_,isRegExp:M,isFunction:y,isStream:e=>O(e)&&y(e.pipe),isURLSearchParams:j,isTypedArray:B,isFileList:v,forEach:D,merge:function e(...t){const{caseless:n,skipUndefined:r}=F(this)&&this||{},o={},i=n?Object.create(null):null,a=(t,n)=>{if("__proto__"===n||"constructor"===n||"prototype"===n)return;let a=n;if(i&&"string"==typeof n){const e=n.toLowerCase(),t=i[e];void 0!==t&&s(o,t)?a=t:i[e]=n}const c=s(o,a)?o[a]:void 0;E(c)&&E(t)?o[a]=e(c,t):E(t)?o[a]=e({},t):p(t)?o[a]=t.slice():r&&h(t)||(o[a]=t)};for(let e=0,n=t.length;e<n;e++){const n=t[e];if(!n||m(n))continue;if(D(n,a),"object"!=typeof n||p(n)||!Object.getOwnPropertySymbols)continue;const r=Object.getOwnPropertySymbols(n);for(let e=0;e<r.length;e++){const t=r[e];q.call(n,t)&&a(n[t],t)}}return o},extend:(t,n,r,{allOwnKeys:o}={})=>(D(n,(n,o)=>{r&&y(n)?Object.defineProperty(t,o,{__proto__:null,value:e(n,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(t,o,{__proto__:null,value:n,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:o}),t),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:(e,t,r,o)=>{let s,i,a;const c={};if(t=t||{},null==e)return t;do{for(s=Object.getOwnPropertyNames(e),i=s.length;i-- >0;)a=s[i],o&&!o(a,e,t)||c[a]||(t[a]=e[a],c[a]=!0);e=!1!==r&&n(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:l,kindOfTest:f,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(p(e))return e;let t=e.length;if(!Number.isSafeInteger(t)||t<0||t>4294967295)return null;const r=new Set,o=new Set;let i=e;for(;null!=i&&r.size<t;){if(o.has(i))return null;o.add(i);const c=n(i);if(a(i,c,i===e))break;Object.getOwnPropertyNames(i).forEach(e=>{const n=+e;Number.isInteger(n)&&n>=0&&n<t&&String(n)===e&&s(i,e)&&r.add(n)}),i=c}if(r.size!==t)return null;const c=new Array(t);for(;t-- >0;)c[t]=e[t];return c},forEachEntry:(e,t)=>{const n=(e&&e[r]).call(e);let o;for(;(o=n.next())&&!o.done;){const n=o.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:I,hasOwnProperty:s,hasOwnProp:s,hasOwnInPrototypeChain:c,getSafeProp:(e,t)=>null!=e&&c(e,t)?e[t]:void 0,toSafeFlatObject:e=>{if(null==e||"object"!=typeof e&&"function"!=typeof e)return e;const t=n(e);if(null===t&&(e=>{if(!Object.isExtensible(e))return!1;const t=Object.getOwnPropertyNames(e);return Object.getOwnPropertySymbols&&t.push(...Object.getOwnPropertySymbols(e)),t.every(t=>{if(i(t))return!1;const n=Object.getOwnPropertyDescriptor(e,t);return!!n&&n.configurable&&!0===n.writable})})(e))return e;const r=Object.create(null),o=Object.create(null),c=[];let l=e;for(;null!=l&&-1===c.indexOf(l);){c.push(l);const u=l===e?t:n(l);if(a(l,u,l===e))break;const f=Object.getOwnPropertyNames(l);Object.getOwnPropertySymbols&&f.push(...Object.getOwnPropertySymbols(l));for(const t of f)i(t)||s(o,t)||(r[t]=e[t],o[t]=!0);l=u}return r},reduceDescriptors:z,freezeMethods:e=>{z(e,(t,n)=>{if(y(e)&&["arguments","caller","callee"].includes(n))return!1;const r=e[n];y(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))})},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach(e=>{n[e]=!0})};return p(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,n){return t.toUpperCase()+n}),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e=+e)?e:t,findKey:function(e,t){if(m(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r,o=n.length;for(;o-- >0;)if(r=n[o],t===r.toLowerCase())return r;return null},global:L,isContextDefined:F,isSpecCompliantForm:function(e){return!!(e&&y(e.append)&&"FormData"===e[o]&&e[r])},toJSONObject:e=>{const t=new WeakSet,n=e=>{if(O(e)){if(t.has(e))return;if(m(e))return e;if(!("toJSON"in e)){let r;if(t.add(e),A(e)){r=[];for(const t of e){const e=n(t);!h(e)&&r.push(e)}}else r=p(e)?[]:{},D(e,(e,t)=>{const o=n(e);!h(o)&&(r[t]=o)});return t.delete(e),r}}return e};return n(e)},isAsyncFn:$,isThenable:e=>e&&(O(e)||y(e))&&y(e.then)&&y(e.catch),setImmediate:H,asap:X,isIterable:Q,isSafeIterable:e=>null!=e&&c(e,r)&&Q(e)};const G=Z.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]);const Y=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),ee=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function te(e,t){return Z.isArray(e)?e.map(e=>te(e,t)):function(e){let t=0,n=e.length;for(;t<n;){const n=e.charCodeAt(t);if(9!==n&&32!==n)break;t+=1}for(;n>t;){const t=e.charCodeAt(n-1);if(9!==t&&32!==t)break;n-=1}return 0===t&&n===e.length?e:e.slice(t,n)}(String(e).replace(t,""))}function ne(e){const t=Object.create(null);return Z.forEach(e.toJSON(),(e,n)=>{t[n]=(e=>te(e,ee))(e)}),t}const re=Symbol("internals");function oe(e){return e&&String(e).trim().toLowerCase()}function se(e){return!1===e||null==e?e:Z.isArray(e)?e.map(se):(e=>te(e,Y))(String(e))}const ie=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;function ae(e){let t=0,n=e.length;for(;t<n;){const n=e.charCodeAt(t);if(9!==n&&32!==n)break;t+=1}for(;n>t;){const t=e.charCodeAt(n-1);if(9!==t&&32!==t)break;n-=1}return 0===t&&n===e.length?e:e.slice(t,n)}const ce=e=>"__proto__"===e?"__Proto__":e;function le(e,t,n,r,o){return Z.isFunction(r)?r.call(e,t,n):(o&&(t=n),Z.isString(t)?Z.isString(r)?-1!==t.indexOf(r):Z.isRegExp(r)?r.test(t):void 0:void 0)}let ue=class{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=oe(t);if(!o)return;const s=Z.findKey(r,o);(!s||void 0===r[s]||!0===n||void 0===n&&!1!==r[s])&&(r[ce(s||t)]=se(e))}const s=(e,t)=>Z.forEach(e,(e,n)=>o(e,n,t));if(Z.isPlainObject(e)||e instanceof this.constructor)s(e,t);else if(Z.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))s((e=>{const t=Object.create(null);let n,r,o;return e&&e.split("\n").forEach(function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim();const s=Z.hasOwnProp(t,n);!n||s&&Z.hasOwnProp(G,n)||("set-cookie"===n?s?t[n].push(r):t[n]=[r]:t[n]=s?t[n]+", "+r:r)}),t})(e),t);else if(Z.isObject(e)&&Z.isSafeIterable(e)){let n,r,o=Object.create(null);for(const t of e){if(!Z.isArray(t))throw new TypeError("Object iterator must return a key-value pair");r=t[0],Z.hasOwnProp(o,r)?(n=o[r],o[r]=Z.isArray(n)?[...n,t[1]]:[n,t[1]]):o[r]=t[1]}s(o,t)}else null!=e&&o(t,e,n);return this}get(e,t){if(e=oe(e)){const n=Z.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}(e);if(Z.isFunction(t))return t.call(this,e,n);if(Z.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=oe(e)){const n=Z.findKey(this,e);return!(!n||void 0===this[n]||t&&!le(this,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=oe(e)){const o=Z.findKey(n,e);!o||t&&!le(n,n[o],o,t)||(delete n[o],r=!0)}}return Z.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!le(this,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n=Object.create(null);return Z.forEach(this,(r,o)=>{const s=Z.findKey(n,o);if(s)return t[s]=se(r),void delete t[o];const i=ce(e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,n)=>t.toUpperCase()+n)}(o):String(o).trim());i!==o&&delete t[o],t[i]=se(r),n[i]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Z.forEach(this,(n,r)=>{null!=n&&!1!==n&&(t[r]=e&&Z.isArray(n)?n.join(", "):n)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}getSetCookie(){const e=this.get("set-cookie");return Z.isArray(e)?e:null==e||!1===e?[]:[e]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static parseParameters(e){return function(e){const t=Object.create(null),n=String(e);let r=0,o=!1,s=!1;function i(e){const o=ae(n.slice(r,e)),s=o.indexOf("=");if(s<1)return;const i=ae(o.slice(0,s));if(!ie.test(i))return;const a=i.toLowerCase();if("__proto__"===a||"constructor"===a||"prototype"===a)return;const c=ae(o.slice(s+1));t[a]=function(e){const t=e.length-1;if(t<1||34!==e.charCodeAt(0)||34!==e.charCodeAt(t))return e;let n="";for(let r=1;r<t;r++){const o=e.charCodeAt(r);if(34===o)return e;if(92===o&&(r+=1,r>=t))return e;n+=e[r]}return n}(c)}for(let e=0;e<n.length;e++){const t=n.charCodeAt(e);o?s?s=!1:92===t?s=!0:34===t&&(o=!1):34===t?o=!0:44!==t&&59!==t||(i(e),r=e+1)}return i(n.length),t}(e)}static concat(e,...t){const n=new this(e);return t.forEach(e=>n.set(e)),n}static accessor(e){const t=(this[re]=this[re]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=oe(e);t[r]||(!function(e,t){const n=Z.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{__proto__:null,value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})})}(n,e),t[r]=!0)}return Z.isArray(e)?e.forEach(r):r(e),this}};ue.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Z.reduceDescriptors(ue.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),Z.freezeMethods(ue);const fe="[REDACTED ****]";function de(e,t){const n=new Set(t.map(e=>String(e).toLowerCase())),r=[],o=e=>{if(null===e||"object"!=typeof e)return e;if(Z.isBuffer(e))return e;if(-1!==r.indexOf(e))return;let t;if(e instanceof ue&&(e=e.toJSON()),r.push(e),Z.isArray(e))t=[],e.forEach((e,n)=>{const r=o(e);Z.isUndefined(r)||(t[n]=r)});else{if(!Z.isPlainObject(e)&&function(e){if(Z.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(Z.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}(e))return r.pop(),e;t=Object.create(null);for(const[r,s]of Object.entries(e)){const e=n.has(r.toLowerCase())?fe:o(s);Z.isUndefined(e)||(t[r]=e)}}return r.pop(),t};return o(e)}function pe(e){try{return String(e)}catch(e){return""}}const he=Symbol("causeStack");let me=class e extends Error{static from(t,n,r,o,s,i){let a=t.message;!a&&Z.isArray(t.errors)&&t.errors.length&&(a=function(e){return e.errors.map(e=>{try{return e&&e.message?pe(e.message):pe(e)}catch(e){return""}}).filter(Boolean).join("; ")||e.name||"AggregateError"}(t));const c=new e(a,n||t.code,r,o,s);return Object.defineProperty(c,"cause",{__proto__:null,value:t,writable:!0,enumerable:!1,configurable:!0}),c.name=t.name,function(e,t){try{const n=t&&t.stack;if("string"!=typeof n||!n)return;const r=e.stack;if("string"!=typeof r||!r)return;const o="\nCaused by: "+n;e.stack=r+o,Object.defineProperty(e,he,{__proto__:null,value:o})}catch(e){}}(c,t),null!=t.status&&null==c.status&&(c.status=t.status),i&&Object.assign(c,i),c}constructor(e,t,n,r,o){super(e),Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o,this.status=o.status)}toJSON(){const e=this.config,t=e&&Z.hasOwnProp(e,"redact")?e.redact:void 0,n=Z.isArray(t)&&t.length>0?de(e,t):Z.toJSONObject(e);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:n,code:this.code,status:this.status}}};me.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",me.ERR_BAD_OPTION="ERR_BAD_OPTION",me.ECONNABORTED="ECONNABORTED",me.ETIMEDOUT="ETIMEDOUT",me.ECONNREFUSED="ECONNREFUSED",me.ERR_NETWORK="ERR_NETWORK",me.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",me.ERR_DEPRECATED="ERR_DEPRECATED",me.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",me.ERR_BAD_REQUEST="ERR_BAD_REQUEST",me.ERR_CANCELED="ERR_CANCELED",me.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",me.ERR_INVALID_URL="ERR_INVALID_URL",me.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";function ge(e){return Z.isPlainObject(e)||Z.isArray(e)}function be(e){return Z.endsWith(e,"[]")?e.slice(0,-2):e}function ye(e,t,n){return e?e.concat(t).map(function(e,t){return e=be(e),!n&&t?"["+e+"]":e}).join(n?".":""):t}const we=Z.toFlatObject(Z,{},null,function(e){return/^is[A-Z]/.test(e)});function Oe(e,t,n){if(!Z.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(e,t)=>{const r=Z.getSafeProp(n,e);return Z.isUndefined(r)?t:r},o=r("metaTokens",!0),s=r("visitor")||h,i=r("dots",!1),a=r("indexes",!1),c=r("Blob")||"undefined"!=typeof Blob&&Blob,l=r("maxDepth",100),u=c&&Z.isSpecCompliantForm(t),f=[];if(!Z.isFunction(s))throw new TypeError("visitor must be a function");function d(e){if(null===e)return"";if(Z.isDate(e))return e.toISOString();if(Z.isBoolean(e))return e.toString();if(!u&&Z.isBlob(e))throw new me("Blob is not supported. Use a Buffer instead.");if(Z.isArrayBuffer(e)||Z.isTypedArray(e)){if(u&&"function"==typeof c)return new c([e]);throw new me("Blob is not supported. Use a Buffer instead.",me.ERR_NOT_SUPPORT)}return e}function p(e){if(e>l)throw new me("Object is too deeply nested ("+e+" levels). Max depth: "+l,me.ERR_FORM_DATA_DEPTH_EXCEEDED)}function h(e,n,r){let s=e;if(Z.isReactNative(t)&&Z.isReactNativeBlob(e))return t.append(ye(r,n,i),d(e)),!1;if(e&&!r&&"object"==typeof e)if(Z.endsWith(n,"{}"))n=o?n:n.slice(0,-2),e=function(e,t){if(l===1/0)return JSON.stringify(e);const n=[];return JSON.stringify(e,function(e,r){if(!Z.isObject(r))return r;for(;n.length&&n[n.length-1]!==this;)n.pop();return n.push(r),p(t+n.length-1),r})}(e,1);else if(Z.isArray(e)&&function(e){return Z.isArray(e)&&!e.some(ge)}(e)||(Z.isFileList(e)||Z.endsWith(n,"[]"))&&(s=Z.toArray(e)))return n=be(n),s.forEach(function(e,r){!Z.isUndefined(e)&&null!==e&&t.append(!0===a?ye([n],r,i):null===a?n:n+"[]",d(e))}),!1;return!!ge(e)||(t.append(ye(r,n,i),d(e)),!1)}const m=Object.assign(we,{defaultVisitor:h,convertValue:d,isVisitable:ge});if(!Z.isObject(e))throw new TypeError("data must be an object");return function e(n,r,o=0){if(!Z.isUndefined(n)){if(p(o),-1!==f.indexOf(n))throw new Error("Circular reference detected in "+r.join("."));f.push(n),Z.forEach(n,function(n,i){!0===(!(Z.isUndefined(n)||null===n)&&s.call(t,n,Z.isString(i)?i.trim():i,r,m))&&e(n,r?r.concat(i):[i],o+1)}),f.pop()}}(e),t}function Ee(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(e){return t[e]})}function Re(e,t){this._pairs=[],e&&Oe(e,this,t)}const Se=Re.prototype;function _e(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function ve(e,t,n){if(!t)return e;e=e||"";const r=Z.isFunction(n)?{serialize:n}:n,o=Z.getSafeProp(r,"encode")||_e,s=Z.getSafeProp(r,"serialize");let i;if(i=s?s(t,r):Z.isURLSearchParams(t)?t.toString():new Re(t,r).toString(o),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}Se.append=function(e,t){this._pairs.push([e,t])},Se.toString=function(e){const t=e?t=>e.call(this,t,Ee):Ee;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};const Ae=Symbol("internals");function Pe(e){return e?e.length:0}function Te(e){if(e)for(;e.length&&null===e[e.length-1];)e.pop()}function je(e,t){const n=e.handlers,r=Pe(n);n!==t.handlersRef?(t.handlersRef=n,t.handlerEntries.clear()):r!==t.handlersLength&&(r?t.handlerEntries.forEach(function(e,r){n[e.index]!==e.handler&&t.handlerEntries.delete(r)}):t.handlerEntries.clear()),t.handlersLength=r}class Ce{constructor(){this.handlers=[],this[Ae]={handlersRef:this.handlers,handlersLength:this.handlers.length,handlerEntries:new Map,iterationDepth:0,nextId:0}}use(e,t,n){const r={fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null},o=this[Ae];null==this.handlers&&(this.handlers=[]),je(this,o);const s=o.nextId++;return this.handlers.push(r),o.handlerEntries.set(s,{handler:r,index:this.handlers.length-1}),o.handlersLength=this.handlers.length,s}eject(e){const t=this[Ae];je(this,t);const n=function(e){return"string"==typeof e&&""!==e&&String(Number(e))===e?Number(e):e}(e),r=t.handlerEntries.get(n);if(r){if(t.handlerEntries.delete(n),this.handlers[r.index]!==r.handler)return;this.handlers[r.index]=null,t.iterationDepth||(Te(this.handlers),t.handlersLength=this.handlers.length)}}clear(){this.handlers&&(this.handlers=[],je(this,this[Ae]))}forEach(e){const t=this[Ae];je(this,t),t.iterationDepth++;try{Z.forEach(this.handlers,function(t){null!==t&&e(t)})}finally{--t.iterationDepth||(je(this,t),Te(this.handlers),t.handlersLength=Pe(this.handlers))}}}var Ne={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0,encodeBasicAuthUsername:!1},xe={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:Re,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};const Ue="undefined"!=typeof window&&"undefined"!=typeof document,De="object"==typeof navigator&&navigator||void 0,Le=Ue&&(!De||["ReactNative","NativeScript","NS"].indexOf(De.product)<0),Fe="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,Be=Ue&&window.location.href||"http://localhost";var ke={...Object.freeze({__proto__:null,hasBrowserEnv:Ue,hasStandardBrowserEnv:Le,hasStandardBrowserWebWorkerEnv:Fe,navigator:De,origin:Be}),...xe};function Ie(e){if(e>100)throw new me("FormData field is too deeply nested ("+e+" levels). Max depth: 100",me.ERR_FORM_DATA_DEPTH_EXCEEDED)}function qe(e){const t={},n=Object.keys(e);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],t[s]=e[s];return t}function Me(e){if(!Z.isArray(e))return e;const t=Object.keys(e);return t.length!==e.length||t.some((e,t)=>e!==String(t))?qe(e):e}function ze(e){function t(e,n,r,o){Ie(o);let s=e[o++];if("__proto__"===s)return!0;const i=Number.isFinite(+s),a=o>=e.length;if(s=!s&&Z.isArray(r)?r.length:s,a)return Z.hasOwnProp(r,s)?(r[s]=Me(r[s]),r[s]=Z.isArray(r[s])?r[s].concat(n):[r[s],n]):r[s]=n,!i;Z.hasOwnProp(r,s)&&Z.isObject(r[s])||(r[s]=[]);return t(e,n,r[s],o)&&Z.isArray(r[s])&&(r[s]=qe(r[s])),!i}if(Z.isFormData(e)&&Z.isFunction(e.entries)){const n={};return Z.forEachEntry(e,(e,r)=>{t(function(e){const t=[],n=/[^.[\]]+|\[([^.[\]]*)]/g;let r;for(;null!==(r=n.exec(e));)Ie(t.length),t.push("[]"===r[0]?"":r[1]||r[0]);return t}(e),r,n,0)}),function(e){const t=[e];for(;t.length;){const e=t.pop();Object.keys(e).forEach(n=>{const r=e[n]=Me(e[n]);(Z.isArray(r)||Z.isPlainObject(r))&&t.push(r)})}return e}(n)}return null}const $e=Object.freeze(["get","delete","head","options","post","put","patch","purge","link","unlink","query"]),He=(e,t)=>null!=e&&Z.hasOwnProp(e,t)?e[t]:void 0;const We={transitional:Ne,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=Z.isObject(e);o&&Z.isHTMLForm(e)&&(e=new FormData(e));if(Z.isFormData(e))return r?JSON.stringify(ze(e)):e;if(Z.isArrayBuffer(e)||Z.isBuffer(e)||Z.isStream(e)||Z.isFile(e)||Z.isBlob(e)||Z.isReadableStream(e))return e;if(Z.isArrayBufferView(e))return e.buffer;if(Z.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let s;if(o){const t=He(this,"formSerializer");if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return Oe(e,new ke.classes.URLSearchParams,{visitor:function(e,t,n,r){return ke.isNode&&Z.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)},...t})}(e,t).toString();if((s=Z.isFileList(e))||n.indexOf("multipart/form-data")>-1){const n=He(this,"env"),r=n&&n.FormData;return Oe(s?{"files[]":e}:e,r&&new r,t)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(Z.isString(e))try{return(t||JSON.parse)(e),Z.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(n||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=He(this,"transitional")||We.transitional,n=t&&t.forcedJSONParsing,r=He(this,"responseType"),o="json"===r;if(Z.isResponse(e)||Z.isReadableStream(e))return e;if(e&&Z.isString(e)&&(n&&!r||o)){const n=!(t&&t.silentJSONParsing)&&o;try{return JSON.parse(e,He(this,"parseReviver"))}catch(e){if(n){if("SyntaxError"===e.name)throw me.from(e,me.ERR_BAD_RESPONSE,this,null,He(this,"response"));throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ke.classes.FormData,Blob:ke.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};function Je(e,t){const n=this||We,r=t||n,o=ue.from(r.headers);let s=r.data;return Z.forEach(e,function(e){s=e.call(n,s,o.normalize(),t?t.status:void 0)}),o.normalize(),s}function Ve(e){return!(!e||!e.__CANCEL__)}Z.forEach($e,e=>{We.headers[e]={}});let Ke=class extends me{constructor(e,t,n){super(null==e?"canceled":e,me.ERR_CANCELED,t,n),this.name="CanceledError",this.__CANCEL__=!0}};function Xe(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new me("Request failed with status code "+n.status,n.status>=400&&n.status<500?me.ERR_BAD_REQUEST:me.ERR_BAD_RESPONSE,n.config,n.request,n)):e(n)}const Qe=/[\t\n\r]/g;function Ze(e){if("string"!=typeof e)return e;let t=0;for(;t<e.length&&e.charCodeAt(t)<=32;)t++;return e.slice(t).replace(Qe,"")}function Ge(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1].toLowerCase()||""}const Ye=e=>{try{return decodeURIComponent(e)}catch(t){return e}};var et=ke.hasStandardBrowserEnv?{write(e,t,n,r,o,s,i){if("undefined"==typeof document)return;const a=[`${e}=${encodeURIComponent(t)}`];Z.isNumber(n)&&a.push(`expires=${new Date(n).toUTCString()}`),Z.isString(r)&&a.push(`path=${r}`),Z.isString(o)&&a.push(`domain=${o}`),!0===s&&a.push("secure"),Z.isString(i)&&a.push(`SameSite=${i}`),document.cookie=a.join("; ")},read(e){if("undefined"==typeof document)return null;const t=document.cookie;if(!t)return null;const n=t.split(";");for(let t=0;t<n.length;t++){const r=n[t].replace(/^\s+/,""),o=r.indexOf("=");if(-1!==o&&r.slice(0,o)===e)return Ye(r.slice(o+1))}return null},async readAsync(e){try{const t="undefined"!=typeof window&&window.cookieStore;if(t&&Z.isFunction(t.get)){const n=await t.get(e);return n?Ye(n.value):null}}catch(e){}return this.read(e)},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read:()=>null,readAsync:async()=>null,remove(){}};const tt=(e,t,n=3)=>{let r=0;const o=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,s=0,i=0;return t=void 0!==t?t:1e3,function(a){const c=Date.now(),l=r[i];o||(o=c),n[s]=a,r[s]=c;let u=i,f=0;for(;u!==s;)f+=n[u++],u%=e;if(s=(s+1)%e,s===i&&(i=(i+1)%e),c-o<t)return;const d=l&&c-l;return d?Math.round(1e3*f/d):void 0}}(50,250);return function(e,t){let n,r,o=0,s=1e3/t;const i=(t,s=Date.now())=>{o=s,n=null,r&&(clearTimeout(r),r=null),e(...t)};return[(...e)=>{const t=Date.now(),a=t-o;a>=s?i(e,t):(n=e,r||(r=setTimeout(()=>{r=null,i(n)},s-a)))},()=>n&&i(n),(...e)=>i(e)]}(n=>{if(!n||!Z.isNumber(n.loaded))return;const s=n.loaded,i=n.lengthComputable?n.total:void 0,a=Math.max(0,null!=i?Math.min(s,i):s),c=Math.max(0,a-r),l=o(c);r=Math.max(r,a);e({loaded:a,total:i,progress:i?a/i:void 0,bytes:c,rate:l||void 0,estimated:l&&i?(i-a)/l:void 0,event:n,lengthComputable:null!=i,[t?"download":"upload"]:!0})},n)},nt=(e,t)=>{const n=null!=e;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},rt=(e,t=Z.asap)=>(...n)=>t(()=>e(...n));var ot=ke.hasStandardBrowserEnv?(e=>t=>(t=new URL(t,document.baseURI||ke.origin),e.protocol===t.protocol&&e.host===t.host&&e.port===t.port))(new URL(ke.origin)):()=>!0;const st=/^https?:(?!\/\/)/i;function it(e){const t=e.replace(/^(https?:\/{0,2})[^/?#]*@/i,`$1${fe}@`),n=t.indexOf("#"),r=(-1===n?t:t.slice(0,n)).replace(/([?&][^=&#]*=)[^&#]*/g,`$1${fe}`);return-1===n?r:`${r}#${o=t.slice(n+1),o?o.replace(/(^|&)([^=&]*=)?[^&]+/g,(e,t,n="")=>`${t}${n}${fe}`):o}`;var o}function at(e,t){if("string"==typeof e){const n=Ze(e);if(st.test(n))throw new me(`Invalid URL ${JSON.stringify(it(n))}: missing "//" after protocol`,me.ERR_INVALID_URL,t)}}function ct(e,t,n,r){at(t,r);let o=!("string"==typeof(s=t)&&/^([a-z][a-z\d+\-.]*:)?\/\//i.test(s));var s;return e&&(o||!1===n)?(at(e,r),function(e,t){if(!t)return e;let n=e.length;for(;n>0&&47===e.charCodeAt(n-1);)n--;return e.slice(0,n)+"/"+t.replace(/^\/+/,"")}(e,t)):t}const lt=e=>e instanceof ue?{...e}:e,ut=e=>Object.getOwnPropertySymbols&&Object.getOwnPropertyDescriptor?Object.keys(e).concat(Object.getOwnPropertySymbols(e).filter(t=>{const n=Object.getOwnPropertyDescriptor(e,t);return n&&n.enumerable})):Object.keys(e);function ft(e,t,n,r){return Z.isPlainObject(e)&&Z.isPlainObject(t)?Z.merge.call({caseless:r},e,t):Z.isPlainObject(t)?Z.merge({},t):Z.isArray(t)?t.slice():t}function dt(e,t,n,r){return Z.isUndefined(t)?Z.isUndefined(e)?void 0:ft(void 0,e,0,r):ft(e,t,0,r)}function pt(e,t){if(!Z.isUndefined(t))return ft(void 0,t)}function ht(e,t){return Z.isUndefined(t)?Z.isUndefined(e)?void 0:ft(void 0,e):ft(void 0,t)}function mt(e,t,n,r,o){return Z.hasOwnProp(o,n)?ft(e,t):Z.hasOwnProp(r,n)?ft(void 0,e):void 0}const gt=Object.freeze({__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0}),bt={url:pt,method:pt,data:pt,baseURL:ht,transformRequest:ht,transformResponse:ht,params:function(e,t){const n=[],r=new WeakMap,o={};function s(e,t){if(!Z.isPlainObject(t))return Z.isArray(t)?t.slice():t;const s=Z.isPlainObject(e)?e:o;let i=r.get(t);if(i||(i=new WeakMap,r.set(t,i)),i.has(s))return i.get(s);const a={};return i.set(s,a),n.push({base:s,source:t,result:a}),a}const i=Z.isUndefined(t)?s(void 0,e):s(e,t);for(;n.length;){const{base:e,source:t,result:r}=n.pop(),o=new Set(ut(e)),i=new Set(ut(t));new Set([...o,...i]).forEach(n=>{if("__proto__"===n||"constructor"===n||"prototype"===n)return;const a=i.has(n),c=a?t[n]:void 0,l=a&&!Z.isPlainObject(c)||!o.has(n)?void 0:e[n];r[n]=a?s(l,c):s(void 0,l)})}return function(e){const t=[{value:e}],n=new WeakSet,r=new WeakSet;for(;t.length;){const{value:e,done:o}=t.pop();if(!Z.isPlainObject(e)&&!Z.isArray(e))continue;if(o){n.delete(e);continue}if(n.has(e))throw new me("Circular reference detected in params",me.ERR_BAD_OPTION_VALUE);if(r.has(e))continue;r.add(e),n.add(e),t.push({value:e,done:!0});const s=Object.keys(e);Object.getOwnPropertySymbols&&Object.getOwnPropertyDescriptor&&Object.getOwnPropertySymbols(e).forEach(t=>{const n=Object.getOwnPropertyDescriptor(e,t);n&&n.enumerable&&s.push(t)}),s.forEach(n=>{if("__proto__"===n||"constructor"===n||"prototype"===n){const r=Object.getOwnPropertyDescriptor(e,n);r&&Z.hasOwnProp(r,"value")&&t.push({value:r.value})}else t.push({value:e[n]})})}}(i),i},paramsSerializer:ht,timeout:ht,timeoutErrorMessage:ht,withCredentials:ht,withXSRFToken:ht,adapter:ht,responseType:ht,xsrfCookieName:ht,xsrfHeaderName:ht,onUploadProgress:ht,onDownloadProgress:ht,decompress:ht,maxContentLength:ht,maxBodyLength:ht,beforeRedirect:ht,transport:ht,httpAgent:ht,httpsAgent:ht,cancelToken:ht,socketPath:ht,allowedSocketPaths:ht,responseEncoding:ht,validateStatus:mt,headers:function(e,t,n){return dt(lt(e),lt(t),0,!0)}};function yt(e,t){e=e||{},t=t||{};const n=Object.create(null);Object.defineProperty(n,"hasOwnProperty",gt);const r=ut({...e,...t});for(let o=0,s=r.length;o<s;o++){const s=r[o];if("__proto__"===s||"constructor"===s||"prototype"===s)continue;const i=Z.hasOwnProp(bt,s)?bt[s]:dt,a=Z.hasOwnProp(e,s)?e[s]:void 0,c=Z.hasOwnProp(t,s)?t[s]:void 0,l=i===mt?i(a,c,s,e,t):i(a,c,s);Z.isUndefined(l)&&i!==mt||(n[s]=l)}return Z.hasOwnProp(t,"validateStatus")&&Z.isUndefined(t.validateStatus)&&!1===function(e,t,n){const r=Z.hasOwnProp(t,"transitional")?t.transitional:void 0;if(!Z.isUndefined(r)){if(!Z.isPlainObject(r))return;if(Z.hasOwnProp(r,n))return r[n]}const o=Z.hasOwnProp(e,"transitional")?e.transitional:void 0;if(Z.isPlainObject(o)&&Z.hasOwnProp(o,n))return o[n]}(e,t,"validateStatusUndefinedResolves")&&(Z.hasOwnProp(e,"validateStatus")?n.validateStatus=ft(void 0,e.validateStatus):delete n.validateStatus),n}const wt=["content-type","content-length"];const Ot=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(e,t)=>String.fromCharCode(parseInt(t,16))),Et=e=>et.read(e);function Rt(e,t=Et){const n=yt({},e),r=e=>Z.hasOwnProp(n,e)?n[e]:void 0,o=r("data");let s=r("withXSRFToken");const i=r("xsrfHeaderName"),a=r("xsrfCookieName");let c=r("headers");const l=r("auth"),u=r("baseURL"),f=r("allowAbsoluteUrls"),d=r("url");if(n.headers=c=ue.from(c),n.url=ve(ct(u,d,f,n),r("params"),r("paramsSerializer")),l){const t=Z.getSafeProp(l,"username")||"",n=Z.getSafeProp(l,"password")||"",o=r("transitional"),s=o&&Z.hasOwnProp(o,"encodeBasicAuthUsername")&&!0===o.encodeBasicAuthUsername;try{c.set("Authorization","Basic "+btoa((s?Ot(t):t)+":"+(n?Ot(n):"")))}catch(t){throw me.from(t,me.ERR_BAD_OPTION_VALUE,e)}}if(Z.isFormData(o)){const e=Z.getSafeProp(o,"getHeaders");ke.hasStandardBrowserEnv||ke.hasStandardBrowserWebWorkerEnv||Z.isReactNative(o)?c.setContentType(void 0):Z.isFunction(e)&&function(e,t,n){"content-only"===n?Object.entries(t||{}).forEach(([t,n])=>{wt.includes(t.toLowerCase())&&e.set(t,n)}):e.set(t)}(c,e.call(o),r("formDataHeaderPolicy"))}if(ke.hasStandardBrowserEnv){Z.isFunction(s)&&(s=s(n));if(!0===s||null==s&&ot(n.url)){const e=i&&a&&t(a);e&&c.set(i,e)}}return n}var St="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise(function(t,n){let r,o;try{const e=ke.hasStandardBrowserEnv&&"undefined"!=typeof window&&window.cookieStore;r=e&&Z.isFunction(e.get)}catch(e){}const s=Rt(e,r?e=>(o=e,null):void 0);let i=s.data;const a=ue.from(s.headers).normalize();let c,l,u,f,d,p,h,{responseType:m,onUploadProgress:g,onDownloadProgress:b}=s;function y(){clearTimeout(l);try{d&&d()}catch(e){setTimeout(()=>{throw e})}try{p&&p()}catch(e){setTimeout(()=>{throw e})}w&&(f&&w.removeEventListener("progress",f),w.upload&&(u&&w.upload.removeEventListener("progress",u),d&&w.upload.removeEventListener("loadend",d))),s.cancelToken&&s.cancelToken.unsubscribe(c),s.signal&&s.signal.removeEventListener("abort",c)}let w=new XMLHttpRequest;function O(r){if(!w)return;if(!(0!==w.status||"file"===(Ge(Ze(s.url))||Ge(ke.origin))||w.responseURL&&w.responseURL.startsWith("file:")))return n(new me("Request aborted",me.ECONNABORTED,e,w)),y(),void(w=null);try{r?h&&h(r):p&&p()}catch(e){setTimeout(()=>{throw e})}if(!w)return;const o=ue.from("getAllResponseHeaders"in w&&w.getAllResponseHeaders());Xe(function(e){t(e),y()},function(e){n(e),y()},{data:m&&"text"!==m&&"json"!==m?w.response:w.responseText,status:w.status,statusText:w.statusText,headers:o,config:e,request:w}),w=null}if(w.open(s.method.toUpperCase(),s.url,!0),w.timeout=s.timeout,"onloadend"in w?w.onloadend=O:w.onreadystatechange=function(){w&&4===w.readyState&&(0!==w.status||w.responseURL&&w.responseURL.startsWith("file:"))&&setTimeout(O)},w.onabort=function(){w&&(n(new me("Request aborted",me.ECONNABORTED,e,w)),y(),w=null)},w.onerror=function(t){const r=t&&t.message?t.message:"Network Error",o=new me(r,me.ERR_NETWORK,e,w);o.event=t||null,n(o),y(),w=null},w.ontimeout=function(){if(!w)return;let t=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const r=s.transitional||Ne;s.timeoutErrorMessage&&(t=s.timeoutErrorMessage),n(new me(t,r.clarifyTimeoutError?me.ETIMEDOUT:me.ECONNABORTED,e,w)),y(),w=null},void 0===i&&a.setContentType(null),Z.isUndefined(s.withCredentials)||(w.withCredentials=!!s.withCredentials),m&&"json"!==m&&(w.responseType=s.responseType),b&&([f,p,h]=tt(b,!0),w.addEventListener("progress",f)),g&&w.upload&&([u,d]=tt(g),w.upload.addEventListener("progress",u),w.upload.addEventListener("loadend",d)),s.cancelToken||s.signal){if(c=t=>{if(!w)return;n(!t||t.type?new Ke(null,e,w):t);const r=w;y(),w=null,r.abort()},s.cancelToken&&s.cancelToken.subscribe(c),!w)return;s.signal&&(s.signal.aborted?c():s.signal.addEventListener("abort",c))}if(!w)return;const E=Ge(s.url);if(E&&!ke.protocols.includes(E))return n(new me("Unsupported protocol "+E+":",me.ERR_BAD_REQUEST,e)),void y();const R=()=>{w&&("setRequestHeader"in w&&Z.forEach(ne(a),function(e,t){w.setRequestHeader(t,e)}),w.send(i||null))};if(o){const t="undefined"!=typeof performance&&Z.isFunction(performance.now)?()=>performance.now():Date.now,r=w.timeout>0?t()+Number(w.timeout):void 0,i=()=>{if(!w)return;const e=w;e.ontimeout(),e.abort()};if(void 0!==r){const e=()=>{const n=r-t();n>0?l=setTimeout(e,Math.min(n,2147483647)):i()};e()}et.readAsync(o).then(e=>{if(w)if(void 0!==r&&t()>=r)i();else{if(e){const t=Z.hasOwnProp(s,"xsrfHeaderName")&&s.xsrfHeaderName;a.set(t,e)}R()}}).catch(t=>{w&&(n(me.from(t,null,e,w)),y(),w=null)})}else R()})};const _t=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;const n=new AbortController;let r=!1;const o=function(e){if(!r){r=!0,i();const t=e instanceof Error?e:this.reason;n.abort(t instanceof me?t:new Ke(t instanceof Error?t.message:t))}};let s=t&&setTimeout(()=>{s=null,o(new me(`timeout of ${t}ms exceeded`,me.ETIMEDOUT))},t);const i=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(e=>{const t=Z.getSafeProp(e,"unsubscribe");Z.isFunction(t)?t.call(e,o):e.removeEventListener("abort",o)}),e=null)};e.forEach(e=>{r||(e.aborted?o.call(e):e.addEventListener("abort",o,{once:!0}))});const{signal:a}=n;return a.unsubscribe=()=>Z.asap(i),a},vt=function*(e,t){let n=e.byteLength;if(n<t)return void(yield e);let r,o=0;for(;o<n;)r=o+t,yield e.slice(o,r),o=r},At=async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);const t=e.getReader();try{for(;;){const{done:e,value:n}=await t.read();if(e)break;yield n}}finally{await t.cancel()}},Pt=(e,t,n,r)=>{const o=async function*(e,t){for await(const n of At(e))yield*vt(n,t)}(e,t);let s,i=0,a=e=>{s||(s=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await o.next();if(t)return a(),void e.close();let s=r.byteLength;if(n){let e=i+=s;n(e)}e.enqueue(new Uint8Array(r))}catch(e){throw a(e),e}},cancel:e=>(a(e),o.return())},{highWaterMark:2})},Tt="\r\n",jt=e=>String(e).replace(/\r\n|\r|\n/g,Tt),Ct=e=>String(e).replace(/[\r\n"]/g,e=>"\r"===e?"%0D":"\n"===e?"%0A":"%22"),Nt=(e,t)=>{let n=0;for(let r=0;r<e.length;r++){const o=e.charCodeAt(r);!t||13!==o&&10!==o?o<128?n++:o<2048?n+=2:o>=55296&&o<=56319&&e.charCodeAt(r+1)>=56320&&e.charCodeAt(r+1)<=57343?(n+=4,r++):n+=3:(13===o&&10===e.charCodeAt(r+1)&&r++,n+=2)}return n};class xt extends TypeError{constructor(e,t){super(e),this.name="FormDataError",this.reason=t}}function Ut(e,t,n,r,o){if(!Z.isFunction(t))throw new me("Blob is not supported",me.ERR_NOT_SUPPORT);if(void 0===o)if(Z.isFunction(ke.generateString))o="axios-"+ke.generateString(36,"0123456789abcdef");else{const e=Z.global.crypto;if(!e||!Z.isFunction(e.getRandomValues))throw new me("Random byte generation is not supported",me.ERR_NOT_SUPPORT);const t=new Uint8Array(18);e.getRandomValues(t),o="axios-"+Array.from(t,e=>("0"+e.toString(16)).slice(-2)).join("")}try{return function(e,t,n,r,o){if(!Z.isFunction(t))throw new xt("Blob is not supported","blob");if(!Z.isString(o)||!/^[A-Za-z0-9'()+_,./:=? -]{1,70}$/.test(o)||/ $/.test(o))throw new xt("Invalid multipart boundary","boundary");const s="--"+o+"--"+Tt;let i=s.length;const a=[],c=e=>{if(i+e>n)throw r()};c(0);for(const[t,n]of e){const e=Z.isString(n),r=e?Nt(n,!0):n.size;if(!Number.isFinite(r)||r<0)throw new xt("Unsupported FormData part size","part");c(r+Nt(t,!0)+(!e&&n.name?Nt(n.name,!1):0)+(!e&&n.type?Nt(n.type,!1):0));let s="--"+o+'\r\nContent-Disposition: form-data; name="'+Ct(jt(t))+'"';e||(s+='; filename="'+Ct(Z.isString(n.name)?n.name:"blob")+'"\r\nContent-Type: '+String(n.type||"application/octet-stream").replace(/[\r\n]/g,"")),s+=Tt+Tt;const l=Nt(s,!1)+r+2;c(l),i+=l,a.push({header:s,value:n,isString:e})}const l=[];for(const e of a)l.push(e.header,e.isString?jt(e.value):e.value,Tt);return l.push(s),new t(l,{type:"multipart/form-data; boundary="+o})}(e,t,n,r,o)}catch(e){if(e instanceof xt){const t="boundary"===e.reason?me.ERR_BAD_OPTION_VALUE:me.ERR_BAD_REQUEST;throw new me(e.message,t)}throw e}}const Dt=e=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,Lt=(e,t,n)=>t+2<n&&Dt(e.charCodeAt(t+1))&&Dt(e.charCodeAt(t+2)),Ft=e=>e<=57?e-48:(223&e)-55,Bt=e=>e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||43===e||47===e||45===e||95===e,kt=e=>9===e||10===e||12===e||13===e||32===e,It=e=>{const t=e.length;let n=0,r=0,o=!1;for(let s=0;s<t;s++){let i=e.charCodeAt(s);37===i&&Lt(e,s,t)&&(i=16*Ft(e.charCodeAt(s+1))+Ft(e.charCodeAt(s+2)),s+=2),kt(i)||(61!==i?!Bt(i)||r>0?o=!0:n++:r++)}return o||r>2||r>0&&(n+r)%4!=0||n%4==1?(e=>{const t=e.length;let n=0;return t>0&&61===e.charCodeAt(t-1)&&(n++,t>1&&61===e.charCodeAt(t-2)&&n++),Math.floor(3*(t-n)/4)})(e):(e=>{const t=e%4;return 3*Math.floor(e/4)+(2===t?1:3===t?2:0)})(n)};function qt(e){const t="string"==typeof e?e.indexOf("#"):-1;return((e,t,n)=>{if(!e||"string"!=typeof e)return 0;if(!/^data:/i.test(e))return 0;const r=e.indexOf(",");if(r<0)return 0;const o=e.slice(5,r),s=e.slice(r+1);if(n.test(o))return t(s);let i=0;for(let e=0,t=s.length;e<t;e++){const n=s.charCodeAt(e);if(37===n&&Lt(s,e,t))i+=1,e+=2;else if(n<128)i+=1;else if(n<2048)i+=2;else if(n>=55296&&n<=56319&&e+1<t){const t=s.charCodeAt(e+1);t>=56320&&t<=57343?(i+=4,e++):i+=3}else i+=3}return i})(-1===t?e:e.slice(0,t),It,/; *base64[\t\n\f\r ]*$/i)}const Mt="1.21.0",zt={cache:"default",redirect:"follow",referrer:"about:client",referrerPolicy:"",mode:"cors",integrity:"",keepalive:!1,priority:"auto",window:null},{isFunction:$t}=Z,Ht=e=>{if(!Z.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},Wt=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},Jt=e=>{const t=void 0!==Z.global&&null!==Z.global?Z.global:globalThis,{ReadableStream:n,TextEncoder:r}=t;e=Z.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response,Blob:t.Blob},e);const o=Z.hasOwnProp(e,"fetch")?e.fetch:void 0,{Request:s,Response:i,Blob:a}=e,c=o?$t(o):"function"==typeof fetch,l=$t(s),u=$t(i);if(!c)return!1;const f=c&&$t(n),d=c&&("function"==typeof r?(p=new r,e=>p.encode(e)):async e=>new Uint8Array(await new s(e).arrayBuffer()));var p;const h=l&&f&&Wt(()=>{let e=!1;const t=new s(ke.origin,{body:new n,method:"POST",get duplex(){return e=!0,"half"}}),r=t.headers.has("Content-Type");return null!=t.body&&t.body.cancel(),e&&!r}),m=u&&f&&Wt(()=>Z.isReadableStream(new i("").body)),g=Object.assign(Object.create(null),zt);l&&!Wt(()=>new s(ke.origin,g))&&(delete g.cache,Wt(()=>new s(ke.origin,g))||(g.cache=zt.cache));const b={stream:m&&(e=>e.body)};c&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!b[e]&&(b[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new me(`Response type '${e}' is not supported`,me.ERR_NOT_SUPPORT,n)})});const y=async e=>null==e?0:Z.isBlob(e)?e.size:Z.isArrayBufferView(e)||Z.isArrayBuffer(e)?e.byteLength:(Z.isURLSearchParams(e)&&(e+=""),Z.isString(e)?(await d(e)).byteLength:void 0);return async e=>{let{url:t,method:n,data:c,signal:u,cancelToken:d,timeout:p,onDownloadProgress:w,onUploadProgress:O,responseType:E,headers:R,withCredentials:S="same-origin",fetchOptions:_,maxContentLength:v,maxBodyLength:A,maxRedirects:P}=Rt(e);const T=Z.isNumber(v)&&v>-1,j=Z.isNumber(A)&&A>-1,C=t=>Z.hasOwnProp(e,t)?e[t]:void 0;let N=o||fetch;E=E?(E+"").toLowerCase():"text";let x=_t([u,d&&d.toAbortSignal()],p),U=null;const D=x&&x.unsubscribe&&(()=>{x.unsubscribe()});let L,F=null,B=null;const k=()=>new me("Request body larger than maxBodyLength limit",me.ERR_BAD_REQUEST,e,U);try{let o;const u=C("auth");if(u){const e=Z.getSafeProp(u,"username")||"";o={username:e,password:Z.getSafeProp(u,"password")||""}}let d;if((e=>{const t=e.indexOf("://");let n=e;return-1!==t&&(n=n.slice(t+3)),n.includes("@")||n.includes(":")})(t)){if(d=new URL(t,ke.origin),!o&&(d.username||d.password)){const e=Ht(d.username);o={username:e,password:Ht(d.password)}}(d.username||d.password)&&(d.username="",d.password="",t=d.href)}if(o&&(R.delete("authorization"),R.set("Authorization","Basic "+btoa((I=(o.username||"")+":"+(o.password||""),encodeURIComponent(I).replace(/%([0-9A-F]{2})/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))))),T&&d&&"data:"===d.protocol){if(qt(d.href)>v)throw new me("maxContentLength size of "+v+" exceeded",me.ERR_BAD_RESPONSE,e,U)}const p=Z.isSpecCompliantForm(c)&&ue.from(C("headers")).getContentType();let q;if(Z.isString(p)&&/^multipart\/form-data(?:\s*;|$)/i.test(p.trim())){const e=ue.parseParameters(p);Z.hasOwnProp(e,"boundary")&&(q=e.boundary)}if(Z.isSpecCompliantForm(c)&&"get"!==n&&"head"!==n&&(j||O&&h||void 0!==q)&&(c=Ut(c,a,j?A:1/0,k,q),R.setContentType(void 0===q?c.type:p),L=c.size),j&&"get"!==n&&"head"!==n){const e=await y(c);if("number"==typeof e&&isFinite(e)&&(L=e,e>A))throw k()}const M=j&&(Z.isReadableStream(c)||Z.isStream(c)),z=(e,t,n)=>Pt(e,65536,e=>{if(j&&e>A)throw F=k();t&&t(e)},n);if(h&&"get"!==n&&"head"!==n&&(O||M)){if(L=null==L?await(async(e,t)=>{const n=Z.toFiniteNumber(e.getContentLength());return null==n?y(t):n})(R,c):L,0!==L||M){let e,n=new s(t,{method:"POST",body:c,duplex:"half"});if(Z.isFormData(c)&&(e=n.headers.get("content-type"))&&R.setContentType(e),n.body){const[e,t]=O&&nt(L,tt(rt(O)))||[];c=z(n.body,e,t)}}}else if(M&&!l&&f&&"get"!==n&&"head"!==n)c=z(c);else if(M&&l&&!h&&"get"!==n&&"head"!==n)throw new me("Stream request bodies are not supported by the current fetch implementation",me.ERR_NOT_SUPPORT,e,U);Z.isString(S)||(S=S?"include":"omit");const $=l&&"credentials"in s.prototype;if(Z.isFormData(c)){const e=R.getContentType();e&&/^multipart\/form-data/i.test(e)&&!/boundary=/i.test(e)&&R.delete("content-type")}R.set("User-Agent","axios/"+Mt,!1);const H=null==_?_:Object.assign(Object.create(null),_);H&&(delete H.body,delete H.headers,delete H.method,delete H.signal,delete H.duplex,delete H.credentials);const W=Object.assign(Object.create(null),H,{signal:x,method:n.toUpperCase(),headers:ne(R.normalize()),body:c,duplex:"half",credentials:$?S:void 0});l&&(Z.forEach(g,(e,t)=>{void 0===W[t]&&(W[t]=e)}),void 0===W.signal&&(W.signal=null),void 0===W.body&&(W.body=null)),0===P&&(W.redirect="manual",H&&(H.redirect="manual")),U=l&&new s(t,W);let J=await(l?N(U,H):N(t,W));const V=ue.from(J.headers);if(T){const t=Z.toFiniteNumber(V.getContentLength());if(null!=t&&t>v)throw new me("maxContentLength size of "+v+" exceeded",me.ERR_BAD_RESPONSE,e,U)}const K=m&&("stream"===E||"response"===E);if(m&&J.body&&(w||T||K&&D)){const t={};["status","statusText","headers"].forEach(e=>{t[e]=J[e]});const n=Z.toFiniteNumber(V.getContentLength()),[r,o]=w&&nt(n,tt(rt(w),!0))||[];let s=0;const a=t=>{if(T&&(s=t,s>v))throw B=new me("maxContentLength size of "+v+" exceeded",me.ERR_BAD_RESPONSE,e,U);r&&r(t)};J=new i(Pt(J.body,65536,a,()=>{o&&o(),D&&D()}),t)}E=E||"text";let X=await b[Z.findKey(b,E)||"text"](J,e);if(T&&!m&&!K){let t;if(null!=X&&("number"==typeof X.byteLength?t=X.byteLength:"number"==typeof X.size?t=X.size:"string"==typeof X&&(t="function"==typeof r?(new r).encode(X).byteLength:X.length)),"number"==typeof t&&t>v)throw new me("maxContentLength size of "+v+" exceeded",me.ERR_BAD_RESPONSE,e,U)}return!K&&D&&D(),await new Promise((t,n)=>{Xe(t,n,{data:X,headers:ue.from(J.headers),status:J.status,statusText:J.statusText,config:e,request:U})})}catch(t){if(D&&D(),x&&x.aborted&&x.reason instanceof me){const n=x.reason;throw n.config=e,U&&(n.request=U),t!==n&&Object.defineProperty(n,"cause",{__proto__:null,value:t,writable:!0,enumerable:!1,configurable:!0}),n}if(F)throw U&&!F.request&&(F.request=U),F;if(B)throw B;if(t instanceof me)throw U&&!t.request&&(t.request=U),t;if(t&&"TypeError"===t.name&&/Load failed|fetch/i.test(t.message)){const n=new me("Network Error",me.ERR_NETWORK,e,U,t&&t.response);throw Object.defineProperty(n,"cause",{__proto__:null,value:t.cause||t,writable:!0,enumerable:!1,configurable:!0}),n}throw me.from(t,t&&t.code,e,U,t&&t.response)}var I}},Vt=new Map,Kt=e=>{const t=Object.create(null),n=e&&Z.hasOwnProp(e,"env")&&e.env;["fetch","Request","Response","Blob"].forEach(e=>{n&&Z.hasOwnProp(n,e)&&(t[e]=n[e])});const{fetch:r,Request:o,Response:s,Blob:i}=t,a=[o,s,r,i];let c,l,u=a.length,f=Vt;for(;u--;)c=a[u],l=f.get(c),void 0===l&&f.set(c,l=u?new Map:Jt(t)),f=l;return l};Kt();const Xt={http:null,xhr:St,fetch:{get:Kt}};Z.forEach(Xt,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(e){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const Qt=e=>`- ${e}`,Zt=e=>Z.isFunction(e)||null===e||!1===e;var Gt={getAdapter:function(e,t){e=Z.isArray(e)?e:[e];const{length:n}=e;let r,o;const s={};for(let i=0;i<n;i++){let n;if(r=e[i],o=r,!Zt(r)&&(o=Xt[(n=String(r)).toLowerCase()],void 0===o))throw new me(`Unknown adapter '${n}'`);if(o&&(Z.isFunction(o)||(o=o.get(t))))break;s[n||"#"+i]=o}if(!o){const e=Object.entries(s).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));let t=n?e.length>1?"since :\n"+e.map(Qt).join("\n"):" "+Qt(e[0]):"as no adapter specified";throw new me("There is no suitable adapter to dispatch the request "+t,me.ERR_NOT_SUPPORT)}return o},adapters:Xt};function Yt(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ke(null,e)}function en(e){return Math.max(0,Date.now()-e)}function tn(e){const t=Z.toSafeFlatObject(e);Yt(t),t.headers=ue.from(Z.getSafeProp(t,"headers")),t.data=Je.call(t,t.transformRequest),-1!==["post","put","patch"].indexOf(t.method)&&t.headers.setContentType("application/x-www-form-urlencoded",!1);const n=Gt.getAdapter(t.adapter||We.adapter,t),r=Date.now();return n(t).then(function(e){Yt(t),e.duration=en(r),t.response=e;try{e.data=Je.call(t,t.transformResponse,e)}finally{delete t.response}return e.headers=ue.from(e.headers),e},function(e){if(!Ve(e)&&(Yt(t),e&&e.response)){e.response.duration=en(r),t.response=e.response;try{e.response.data=Je.call(t,t.transformResponse,e.response)}finally{delete t.response}e.response.headers=ue.from(e.response.headers)}return Promise.reject(e)})}const nn={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{nn[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const rn={};nn.transitional=function(e,t,n){function r(e,t){return"[Axios v"+Mt+"] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,s)=>{if(!1===e)throw new me(r(o," has been removed"+(t?" in "+t:"")),me.ERR_DEPRECATED);return t&&!rn[o]&&(rn[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,s)}},nn.spelling=function(e){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};var on={assertOptions:function(e,t,n){if("object"!=typeof e||null===e)throw new me("options must be an object",me.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const s=r[o],i=Object.prototype.hasOwnProperty.call(t,s)?t[s]:void 0;if(i){const t=e[s],n=void 0===t||i(t,s,e);if(!0!==n)throw new me("option "+s+" must be "+n,me.ERR_BAD_OPTION_VALUE);continue}if(!0!==n)throw new me("Unknown option "+s,me.ERR_BAD_OPTION)}},validators:nn};const sn=on.validators,an=e=>{if(null==e||Z.isPlainObject(e)||e instanceof ue)return!0;try{return Z.isObject(e)&&"AxiosHeaders"===Z.getSafeProp(e,Symbol.toStringTag)&&["toJSON","set","get","has","delete","clear","normalize","concat","toString",Symbol.iterator].every(t=>Z.isFunction(Z.getSafeProp(e,t)))}catch(e){return!1}};let cn=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Ce,response:new Ce}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error)try{let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=new Error;const n=t.stack;let r="";if("string"==typeof n){const e=n.indexOf("\n");r=-1===e?"":n.slice(e+1)}if(e.stack){if(r){const t=r.indexOf("\n"),n=-1===t?-1:r.indexOf("\n",t+1),o=-1===n?r:r.slice(n+1),s=String(e.stack),i=function(e,t){const n=Z.hasOwnProp(e,he)&&e[he];return n&&t.endsWith(n)?t.length-n.length:-1}(e,s),a=-1===i?s:s.slice(0,i),c=-1===i?"":s.slice(i);a.endsWith(o)||(e.stack=a+"\n"+r+c)}}else e.stack=r}catch(e){}throw e}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=yt(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&on.assertOptions(n,{silentJSONParsing:sn.transitional(sn.boolean),forcedJSONParsing:sn.transitional(sn.boolean),clarifyTimeoutError:sn.transitional(sn.boolean),legacyInterceptorReqResOrdering:sn.transitional(sn.boolean),advertiseZstdAcceptEncoding:sn.transitional(sn.boolean),validateStatusUndefinedResolves:sn.transitional(sn.boolean),encodeBasicAuthUsername:sn.transitional(sn.boolean)},!1),null!=r&&(Z.isFunction(r)?t.paramsSerializer={serialize:r}:on.assertOptions(r,{encode:sn.function,serialize:sn.function},!0)),void 0!==t.allowAbsoluteUrls||(Z.hasOwnProp(this.defaults,"allowAbsoluteUrls")&&void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),on.assertOptions(t,{baseUrl:sn.spelling("baseURL"),withXsrfToken:sn.spelling("withXSRFToken")},!0),t.method=(Z.getSafeProp(t,"method")||Z.getSafeProp(this.defaults,"method")||"get").toLowerCase();const s=Z.getSafeProp(o,"common"),i=Z.getSafeProp(o,t.method),a=o&&Z.merge(an(s)?s:void 0,an(i)?i:void 0);o&&Z.forEach($e.concat("common"),e=>{an(Z.getSafeProp(o,e))&&delete o[e]}),t.headers=ue.concat(a,o);const c=[];let l=!0;this.interceptors.request.forEach(function(e){if("function"==typeof e.runWhen&&!1===e.runWhen(t))return;l=l&&e.synchronous;const n=t.transitional||Ne;n&&n.legacyInterceptorReqResOrdering?c.unshift(e.fulfilled,e.rejected):c.push(e.fulfilled,e.rejected)});const u=[];let f;this.interceptors.response.forEach(function(e){u.push(e.fulfilled,e.rejected)});let d,p=0;if(!l){const e=[tn.bind(this),void 0];for(e.unshift(...c),e.push(...u),d=e.length,f=Promise.resolve(t);p<d;)f=f.then(e[p++],e[p++]);return f}d=c.length;let h=t;for(;p<d;){const e=c[p++],t=c[p++];try{h=e?e(h):h}catch(e){if(!t){f=Promise.reject(e);break}try{const n=t.call(this,e);Z.isThenable(n)&&(f=Promise.resolve(n).then(()=>tn.call(this,h)))}catch(e){f=Promise.reject(e)}break}}if(!f)try{f=tn.call(this,h)}catch(e){f=Promise.reject(e)}for(p=0,d=u.length;p<d;)f=f.then(u[p++],u[p++]);return f}getUri(e){return ve(ct((e=yt(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls,e),e.params,e.paramsSerializer)}};Z.forEach(["delete","get","head","options"],function(e){cn.prototype[e]=async function(t,n){return this.request(yt(n||{},{method:e,url:t,data:n&&Z.hasOwnProp(n,"data")?n.data:void 0}))}}),Z.forEach(["post","put","patch","query"],function(e){function t(t){return async function(n,r,o){return this.request(yt(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}cn.prototype[e]=t(),"query"!==e&&(cn.prototype[e+"Form"]=t(!0))});const ln={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,ContentTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,UnprocessableContent:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerReturnsAnUnknownError:520,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(ln).forEach(([e,t])=>{void 0===ln[t]&&(ln[t]=e)});const un=function t(n){const r=new cn(n),o=e(cn.prototype.request,r);return Z.extend(o,cn.prototype,r,{allOwnKeys:!0}),Z.extend(o,r,null,{allOwnKeys:!0}),o.create=function(e){return t(yt(n,e))},o}(We);un.Axios=cn,un.CanceledError=Ke,un.CancelToken=class e{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(e){t=e});const n=this;this.promise.then(e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null}),this.promise.then=e=>{let t;const r=new Promise(e=>{n.subscribe(e),t=e}).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e(function(e,r,o){n.reason||(n.reason=new Ke(e,r,o),t(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let t;return{token:new e(function(e){t=e}),cancel:t}}},un.isCancel=Ve,un.VERSION=Mt,un.toFormData=Oe,un.AxiosError=me,un.Cancel=un.CanceledError,un.all=function(e){return Promise.all(e)},un.spread=function(e){return function(t){return e.apply(null,t)}},un.isAxiosError=function(e){return Z.isObject(e)&&!0===e.isAxiosError},un.mergeConfig=yt,un.AxiosHeaders=ue,un.formToJSON=e=>ze(Z.isHTMLForm(e)?new FormData(e):e),un.getAdapter=Gt.getAdapter,un.HttpStatusCode=ln,un.default=un;const{Axios:fn,AxiosError:dn,CanceledError:pn,isCancel:hn,CancelToken:mn,VERSION:gn,all:bn,Cancel:yn,isAxiosError:wn,spread:On,toFormData:En,AxiosHeaders:Rn,HttpStatusCode:Sn,formToJSON:_n,getAdapter:vn,mergeConfig:An,create:Pn}=un;export{fn as Axios,dn as AxiosError,Rn as AxiosHeaders,yn as Cancel,mn as CancelToken,pn as CanceledError,Sn as HttpStatusCode,gn as VERSION,bn as all,Pn as create,un as default,_n as formToJSON,vn as getAdapter,wn as isAxiosError,hn as isCancel,An as mergeConfig,On as spread,En as toFormData};
//# sourceMappingURL=axios.min.js.map