@typeform/api-client
Version:
JS SDK for Typeform API
1 lines • 72.4 kB
JavaScript
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).typeformAPI={})}(this,(function(t){"use strict";const e=window;var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)};var n=function(){return(n=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++)for(var o in e=arguments[r])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function o(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(t);o<n.length;o++)e.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(t,n[o])&&(r[n[o]]=t[n[o]])}return r}function i(t,e,r,n){return new(r||(r=Promise))((function(o,i){function s(t){try{u(n.next(t))}catch(t){i(t)}}function a(t){try{u(n.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((n=n.apply(t,e||[])).next())}))}function s(t,e){var r,n,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(a){return function(u){return function(a){if(r)throw new TypeError("Generator is already executing.");for(;i&&(i=0,a[0]&&(s=0)),s;)try{if(r=1,n&&(o=2&a[0]?n.return:a[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;switch(n=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return s.label++,{value:a[1],done:!1};case 5:s.label++,n=a[1],a=[0];continue;case 7:a=s.ops.pop(),s.trys.pop();continue;default:if(!(o=(o=s.trys).length>0&&o[o.length-1])&&(6===a[0]||2===a[0])){s=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){s.label=a[1];break}if(6===a[0]&&s.label<o[1]){s.label=o[1],o=a;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(a);break}o[2]&&s.ops.pop(),s.trys.pop();continue}a=e.call(t,s)}catch(t){a=[6,t],n=0}finally{r=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,u])}}}function a(t,e,r){if(r||2===arguments.length)for(var n,o=0,i=e.length;o<i;o++)!n&&o in e||(n||(n=Array.prototype.slice.call(e,0,o)),n[o]=e[o]);return t.concat(n||Array.prototype.slice.call(e))}"function"==typeof SuppressedError&&SuppressedError;var u=void 0!==e?e:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{};function c(){throw new Error("setTimeout has not been defined")}function f(){throw new Error("clearTimeout has not been defined")}var l=c,h=f;function p(t){if(l===setTimeout)return setTimeout(t,0);if((l===c||!l)&&setTimeout)return l=setTimeout,setTimeout(t,0);try{return l(t,0)}catch(e){try{return l.call(null,t,0)}catch(e){return l.call(this,t,0)}}}"function"==typeof u.setTimeout&&(l=setTimeout),"function"==typeof u.clearTimeout&&(h=clearTimeout);var d,g=[],m=!1,y=-1;function w(){m&&d&&(m=!1,d.length?g=d.concat(g):y=-1,g.length&&b())}function b(){if(!m){var t=p(w);m=!0;for(var e=g.length;e;){for(d=g,g=[];++y<e;)d&&d[y].run();y=-1,e=g.length}d=null,m=!1,function(t){if(h===clearTimeout)return clearTimeout(t);if((h===f||!h)&&clearTimeout)return h=clearTimeout,clearTimeout(t);try{h(t)}catch(e){try{return h.call(null,t)}catch(e){return h.call(this,t)}}}(t)}}function v(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];g.push(new E(t,e)),1!==g.length||m||p(b)}function E(t,e){this.fun=t,this.array=e}E.prototype.run=function(){this.fun.apply(null,this.array)};function R(){}var A=R,T=R,S=R,_=R,O=R,P=R,C=R;var U=u.performance||{},x=U.now||U.mozNow||U.msNow||U.oNow||U.webkitNow||function(){return(new Date).getTime()};var B=new Date;var k={nextTick:v,title:"browser",browser:!0,env:{},argv:[],version:"",versions:{},on:A,addListener:T,once:S,off:_,removeListener:O,removeAllListeners:P,emit:C,binding:function(t){throw new Error("process.binding is not supported")},cwd:function(){return"/"},chdir:function(t){throw new Error("process.chdir is not supported")},umask:function(){return 0},hrtime:function(t){var e=.001*x.call(U),r=Math.floor(e),n=Math.floor(e%1*1e9);return t&&(r-=t[0],(n-=t[1])<0&&(r--,n+=1e9)),[r,n]},platform:"browser",release:{},config:{},uptime:function(){return(new Date-B)/1e3}};function j(t,e){return function(){return t.apply(e,arguments)}}const{toString:L}=Object.prototype,{getPrototypeOf:N}=Object,D=(t=>e=>{const r=L.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),I=t=>(t=t.toLowerCase(),e=>D(e)===t),q=t=>e=>typeof e===t,{isArray:F}=Array,M=q("undefined");const z=I("ArrayBuffer");const Y=q("string"),H=q("function"),J=q("number"),V=t=>null!==t&&"object"==typeof t,W=t=>{if("object"!==D(t))return!1;const e=N(t);return!(null!==e&&e!==Object.prototype&&null!==Object.getPrototypeOf(e)||Symbol.toStringTag in t||Symbol.iterator in t)},K=I("Date"),$=I("File"),G=I("Blob"),X=I("FileList"),Q=I("URLSearchParams"),[Z,tt,et,rt]=["ReadableStream","Request","Response","Headers"].map(I);function nt(t,e,{allOwnKeys:r=!1}={}){if(null==t)return;let n,o;if("object"!=typeof t&&(t=[t]),F(t))for(n=0,o=t.length;n<o;n++)e.call(null,t[n],n,t);else{const o=r?Object.getOwnPropertyNames(t):Object.keys(t),i=o.length;let s;for(n=0;n<i;n++)s=o[n],e.call(null,t[s],s,t)}}function ot(t,e){e=e.toLowerCase();const r=Object.keys(t);let n,o=r.length;for(;o-- >0;)if(e===(n=r[o]).toLowerCase())return n;return null}const it=(()=>"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:u)(),st=t=>!M(t)&&t!==it;const at=(t=>e=>t&&e instanceof t)("undefined"!=typeof Uint8Array&&N(Uint8Array)),ut=I("HTMLFormElement"),ct=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),ft=I("RegExp"),lt=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};nt(r,(r,o)=>{let i;!1!==(i=e(r,o,t))&&(n[o]=i||r)}),Object.defineProperties(t,n)},ht="abcdefghijklmnopqrstuvwxyz",pt={DIGIT:"0123456789",ALPHA:ht,ALPHA_DIGIT:ht+ht.toUpperCase()+"0123456789"};const dt=I("AsyncFunction"),gt=((t,e)=>t?setImmediate:e?((t,e)=>(it.addEventListener("message",({source:r,data:n})=>{r===it&&n===t&&e.length&&e.shift()()},!1),r=>{e.push(r),it.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))("function"==typeof setImmediate,H(it.postMessage)),mt="undefined"!=typeof queueMicrotask?queueMicrotask.bind(it):void 0!==k&&v||gt;var yt={isArray:F,isArrayBuffer:z,isBuffer:function(t){return null!==t&&!M(t)&&null!==t.constructor&&!M(t.constructor)&&H(t.constructor.isBuffer)&&t.constructor.isBuffer(t)},isFormData:t=>{let e;return t&&("function"==typeof FormData&&t instanceof FormData||H(t.append)&&("formdata"===(e=D(t))||"object"===e&&H(t.toString)&&"[object FormData]"===t.toString()))},isArrayBufferView:function(t){let e;return e="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&z(t.buffer)},isString:Y,isNumber:J,isBoolean:t=>!0===t||!1===t,isObject:V,isPlainObject:W,isReadableStream:Z,isRequest:tt,isResponse:et,isHeaders:rt,isUndefined:M,isDate:K,isFile:$,isBlob:G,isRegExp:ft,isFunction:H,isStream:t=>V(t)&&H(t.pipe),isURLSearchParams:Q,isTypedArray:at,isFileList:X,forEach:nt,merge:function t(){const{caseless:e}=st(this)&&this||{},r={},n=(n,o)=>{const i=e&&ot(r,o)||o;W(r[i])&&W(n)?r[i]=t(r[i],n):W(n)?r[i]=t({},n):F(n)?r[i]=n.slice():r[i]=n};for(let t=0,e=arguments.length;t<e;t++)arguments[t]&&nt(arguments[t],n);return r},extend:(t,e,r,{allOwnKeys:n}={})=>(nt(e,(e,n)=>{r&&H(e)?t[n]=j(e,r):t[n]=e},{allOwnKeys:n}),t),trim:t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:t=>(65279===t.charCodeAt(0)&&(t=t.slice(1)),t),inherits:(t,e,r,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),r&&Object.assign(t.prototype,r)},toFlatObject:(t,e,r,n)=>{let o,i,s;const a={};if(e=e||{},null==t)return e;do{for(i=(o=Object.getOwnPropertyNames(t)).length;i-- >0;)s=o[i],n&&!n(s,t,e)||a[s]||(e[s]=t[s],a[s]=!0);t=!1!==r&&N(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},kindOf:D,kindOfTest:I,endsWith:(t,e,r)=>{t=String(t),(void 0===r||r>t.length)&&(r=t.length),r-=e.length;const n=t.indexOf(e,r);return-1!==n&&n===r},toArray:t=>{if(!t)return null;if(F(t))return t;let e=t.length;if(!J(e))return null;const r=new Array(e);for(;e-- >0;)r[e]=t[e];return r},forEachEntry:(t,e)=>{const r=(t&&t[Symbol.iterator]).call(t);let n;for(;(n=r.next())&&!n.done;){const r=n.value;e.call(t,r[0],r[1])}},matchAll:(t,e)=>{let r;const n=[];for(;null!==(r=t.exec(e));)n.push(r);return n},isHTMLForm:ut,hasOwnProperty:ct,hasOwnProp:ct,reduceDescriptors:lt,freezeMethods:t=>{lt(t,(e,r)=>{if(H(t)&&-1!==["arguments","caller","callee"].indexOf(r))return!1;const n=t[r];H(n)&&(e.enumerable=!1,"writable"in e?e.writable=!1:e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")}))})},toObjectSet:(t,e)=>{const r={},n=t=>{t.forEach(t=>{r[t]=!0})};return F(t)?n(t):n(String(t).split(e)),r},toCamelCase:t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(t,e,r){return e.toUpperCase()+r})),noop:()=>{},toFiniteNumber:(t,e)=>null!=t&&Number.isFinite(t=+t)?t:e,findKey:ot,global:it,isContextDefined:st,ALPHABET:pt,generateString:(t=16,e=pt.ALPHA_DIGIT)=>{let r="";const{length:n}=e;for(;t--;)r+=e[Math.random()*n|0];return r},isSpecCompliantForm:function(t){return!!(t&&H(t.append)&&"FormData"===t[Symbol.toStringTag]&&t[Symbol.iterator])},toJSONObject:t=>{const e=new Array(10),r=(t,n)=>{if(V(t)){if(e.indexOf(t)>=0)return;if(!("toJSON"in t)){e[n]=t;const o=F(t)?[]:{};return nt(t,(t,e)=>{const i=r(t,n+1);!M(i)&&(o[e]=i)}),e[n]=void 0,o}}return t};return r(t,0)},isAsyncFn:dt,isThenable:t=>t&&(V(t)||H(t))&&H(t.then)&&H(t.catch),setImmediate:gt,asap:mt},wt=[],bt=[],vt="undefined"!=typeof Uint8Array?Uint8Array:Array,Et=!1;function Rt(){Et=!0;for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e=0,r=t.length;e<r;++e)wt[e]=t[e],bt[t.charCodeAt(e)]=e;bt["-".charCodeAt(0)]=62,bt["_".charCodeAt(0)]=63}function At(t,e,r){for(var n,o,i=[],s=e;s<r;s+=3)n=(t[s]<<16)+(t[s+1]<<8)+t[s+2],i.push(wt[(o=n)>>18&63]+wt[o>>12&63]+wt[o>>6&63]+wt[63&o]);return i.join("")}function Tt(t){var e;Et||Rt();for(var r=t.length,n=r%3,o="",i=[],s=0,a=r-n;s<a;s+=16383)i.push(At(t,s,s+16383>a?a:s+16383));return 1===n?(e=t[r-1],o+=wt[e>>2],o+=wt[e<<4&63],o+="=="):2===n&&(e=(t[r-2]<<8)+t[r-1],o+=wt[e>>10],o+=wt[e>>4&63],o+=wt[e<<2&63],o+="="),i.push(o),i.join("")}function St(t,e,r,n,o){var i,s,a=8*o-n-1,u=(1<<a)-1,c=u>>1,f=-7,l=r?o-1:0,h=r?-1:1,p=t[e+l];for(l+=h,i=p&(1<<-f)-1,p>>=-f,f+=a;f>0;i=256*i+t[e+l],l+=h,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=n;f>0;s=256*s+t[e+l],l+=h,f-=8);if(0===i)i=1-c;else{if(i===u)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,n),i-=c}return(p?-1:1)*s*Math.pow(2,i-n)}function _t(t,e,r,n,o,i){var s,a,u,c=8*i-o-1,f=(1<<c)-1,l=f>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:i-1,d=n?1:-1,g=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=f):(s=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-s))<1&&(s--,u*=2),(e+=s+l>=1?h/u:h*Math.pow(2,1-l))*u>=2&&(s++,u/=2),s+l>=f?(a=0,s=f):s+l>=1?(a=(e*u-1)*Math.pow(2,o),s+=l):(a=e*Math.pow(2,l-1)*Math.pow(2,o),s=0));o>=8;t[r+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,c+=o;c>0;t[r+p]=255&s,p+=d,s/=256,c-=8);t[r+p-d]|=128*g}var Ot={}.toString,Pt=Array.isArray||function(t){return"[object Array]"==Ot.call(t)};function Ct(){return xt.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function Ut(t,e){if(Ct()<e)throw new RangeError("Invalid typed array length");return xt.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e)).__proto__=xt.prototype:(null===t&&(t=new xt(e)),t.length=e),t}function xt(t,e,r){if(!(xt.TYPED_ARRAY_SUPPORT||this instanceof xt))return new xt(t,e,r);if("number"==typeof t){if("string"==typeof e)throw new Error("If encoding is specified then the first argument must be a string");return jt(this,t)}return Bt(this,t,e,r)}function Bt(t,e,r,n){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&e instanceof ArrayBuffer?function(t,e,r,n){if(e.byteLength,r<0||e.byteLength<r)throw new RangeError("'offset' is out of bounds");if(e.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");e=void 0===r&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,r):new Uint8Array(e,r,n);xt.TYPED_ARRAY_SUPPORT?(t=e).__proto__=xt.prototype:t=Lt(t,e);return t}(t,e,r,n):"string"==typeof e?function(t,e,r){"string"==typeof r&&""!==r||(r="utf8");if(!xt.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|It(e,r),o=(t=Ut(t,n)).write(e,r);o!==n&&(t=t.slice(0,o));return t}(t,e,r):function(t,e){if(Dt(e)){var r=0|Nt(e.length);return 0===(t=Ut(t,r)).length?t:(e.copy(t,0,0,r),t)}if(e){if("undefined"!=typeof ArrayBuffer&&e.buffer instanceof ArrayBuffer||"length"in e)return"number"!=typeof e.length||(n=e.length)!=n?Ut(t,0):Lt(t,e);if("Buffer"===e.type&&Pt(e.data))return Lt(t,e.data)}var n;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,e)}function kt(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function jt(t,e){if(kt(e),t=Ut(t,e<0?0:0|Nt(e)),!xt.TYPED_ARRAY_SUPPORT)for(var r=0;r<e;++r)t[r]=0;return t}function Lt(t,e){var r=e.length<0?0:0|Nt(e.length);t=Ut(t,r);for(var n=0;n<r;n+=1)t[n]=255&e[n];return t}function Nt(t){if(t>=Ct())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Ct().toString(16)+" bytes");return 0|t}function Dt(t){return!(null==t||!t._isBuffer)}function It(t,e){if(Dt(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var n=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return le(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return he(t).length;default:if(n)return le(t).length;e=(""+e).toLowerCase(),n=!0}}function qt(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return te(this,e,r);case"utf8":case"utf-8":return Gt(this,e,r);case"ascii":return Qt(this,e,r);case"latin1":case"binary":return Zt(this,e,r);case"base64":return $t(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ee(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function Ft(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function Mt(t,e,r,n,o){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return-1;r=t.length-1}else if(r<0){if(!o)return-1;r=0}if("string"==typeof e&&(e=xt.from(e,n)),Dt(e))return 0===e.length?-1:zt(t,e,r,n,o);if("number"==typeof e)return e&=255,xt.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):zt(t,[e],r,n,o);throw new TypeError("val must be string, number or Buffer")}function zt(t,e,r,n,o){var i,s=1,a=t.length,u=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,a/=2,u/=2,r/=2}function c(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(o){var f=-1;for(i=r;i<a;i++)if(c(t,i)===c(e,-1===f?0:i-f)){if(-1===f&&(f=i),i-f+1===u)return f*s}else-1!==f&&(i-=i-f),f=-1}else for(r+u>a&&(r=a-u),i=r;i>=0;i--){for(var l=!0,h=0;h<u;h++)if(c(t,i+h)!==c(e,h)){l=!1;break}if(l)return i}return-1}function Yt(t,e,r,n){r=Number(r)||0;var o=t.length-r;n?(n=Number(n))>o&&(n=o):n=o;var i=e.length;if(i%2!=0)throw new TypeError("Invalid hex string");n>i/2&&(n=i/2);for(var s=0;s<n;++s){var a=parseInt(e.substr(2*s,2),16);if(isNaN(a))return s;t[r+s]=a}return s}function Ht(t,e,r,n){return pe(le(e,t.length-r),t,r,n)}function Jt(t,e,r,n){return pe(function(t){for(var e=[],r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function Vt(t,e,r,n){return Jt(t,e,r,n)}function Wt(t,e,r,n){return pe(he(e),t,r,n)}function Kt(t,e,r,n){return pe(function(t,e){for(var r,n,o,i=[],s=0;s<t.length&&!((e-=2)<0);++s)r=t.charCodeAt(s),n=r>>8,o=r%256,i.push(o),i.push(n);return i}(e,t.length-r),t,r,n)}function $t(t,e,r){return 0===e&&r===t.length?Tt(t):Tt(t.slice(e,r))}function Gt(t,e,r){r=Math.min(t.length,r);for(var n=[],o=e;o<r;){var i,s,a,u,c=t[o],f=null,l=c>239?4:c>223?3:c>191?2:1;if(o+l<=r)switch(l){case 1:c<128&&(f=c);break;case 2:128==(192&(i=t[o+1]))&&(u=(31&c)<<6|63&i)>127&&(f=u);break;case 3:i=t[o+1],s=t[o+2],128==(192&i)&&128==(192&s)&&(u=(15&c)<<12|(63&i)<<6|63&s)>2047&&(u<55296||u>57343)&&(f=u);break;case 4:i=t[o+1],s=t[o+2],a=t[o+3],128==(192&i)&&128==(192&s)&&128==(192&a)&&(u=(15&c)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&u<1114112&&(f=u)}null===f?(f=65533,l=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|1023&f),n.push(f),o+=l}return function(t){var e=t.length;if(e<=Xt)return String.fromCharCode.apply(String,t);var r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=Xt));return r}(n)}xt.TYPED_ARRAY_SUPPORT=void 0===u.TYPED_ARRAY_SUPPORT||u.TYPED_ARRAY_SUPPORT,xt.poolSize=8192,xt._augment=function(t){return t.__proto__=xt.prototype,t},xt.from=function(t,e,r){return Bt(null,t,e,r)},xt.TYPED_ARRAY_SUPPORT&&(xt.prototype.__proto__=Uint8Array.prototype,xt.__proto__=Uint8Array),xt.alloc=function(t,e,r){return function(t,e,r,n){return kt(e),e<=0?Ut(t,e):void 0!==r?"string"==typeof n?Ut(t,e).fill(r,n):Ut(t,e).fill(r):Ut(t,e)}(null,t,e,r)},xt.allocUnsafe=function(t){return jt(null,t)},xt.allocUnsafeSlow=function(t){return jt(null,t)},xt.isBuffer=function(t){return null!=t&&(!!t._isBuffer||de(t)||function(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&de(t.slice(0,0))}(t))},xt.compare=function(t,e){if(!Dt(t)||!Dt(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,o=0,i=Math.min(r,n);o<i;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:n<r?1:0},xt.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},xt.concat=function(t,e){if(!Pt(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return xt.alloc(0);var r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;var n=xt.allocUnsafe(e),o=0;for(r=0;r<t.length;++r){var i=t[r];if(!Dt(i))throw new TypeError('"list" argument must be an Array of Buffers');i.copy(n,o),o+=i.length}return n},xt.byteLength=It,xt.prototype._isBuffer=!0,xt.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)Ft(this,e,e+1);return this},xt.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)Ft(this,e,e+3),Ft(this,e+1,e+2);return this},xt.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)Ft(this,e,e+7),Ft(this,e+1,e+6),Ft(this,e+2,e+5),Ft(this,e+3,e+4);return this},xt.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?Gt(this,0,t):qt.apply(this,arguments)},xt.prototype.equals=function(t){if(!Dt(t))throw new TypeError("Argument must be a Buffer");return this===t||0===xt.compare(this,t)},xt.prototype.inspect=function(){var t="";return this.length>0&&(t=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(t+=" ... ")),"<Buffer "+t+">"},xt.prototype.compare=function(t,e,r,n,o){if(!Dt(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw new RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return-1;if(e>=r)return 1;if(this===t)return 0;for(var i=(o>>>=0)-(n>>>=0),s=(r>>>=0)-(e>>>=0),a=Math.min(i,s),u=this.slice(n,o),c=t.slice(e,r),f=0;f<a;++f)if(u[f]!==c[f]){i=u[f],s=c[f];break}return i<s?-1:s<i?1:0},xt.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},xt.prototype.indexOf=function(t,e,r){return Mt(this,t,e,r,!0)},xt.prototype.lastIndexOf=function(t,e,r){return Mt(this,t,e,r,!1)},xt.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e|=0,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var o=this.length-e;if((void 0===r||r>o)&&(r=o),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var i=!1;;)switch(n){case"hex":return Yt(this,t,e,r);case"utf8":case"utf-8":return Ht(this,t,e,r);case"ascii":return Jt(this,t,e,r);case"latin1":case"binary":return Vt(this,t,e,r);case"base64":return Wt(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Kt(this,t,e,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},xt.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var Xt=4096;function Qt(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(127&t[o]);return n}function Zt(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(t[o]);return n}function te(t,e,r){var n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);for(var o="",i=e;i<r;++i)o+=fe(t[i]);return o}function ee(t,e,r){for(var n=t.slice(e,r),o="",i=0;i<n.length;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}function re(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function ne(t,e,r,n,o,i){if(!Dt(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>o||e<i)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function oe(t,e,r,n){e<0&&(e=65535+e+1);for(var o=0,i=Math.min(t.length-r,2);o<i;++o)t[r+o]=(e&255<<8*(n?o:1-o))>>>8*(n?o:1-o)}function ie(t,e,r,n){e<0&&(e=4294967295+e+1);for(var o=0,i=Math.min(t.length-r,4);o<i;++o)t[r+o]=e>>>8*(n?o:3-o)&255}function se(t,e,r,n,o,i){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function ae(t,e,r,n,o){return o||se(t,0,r,4),_t(t,e,r,n,23,4),r+4}function ue(t,e,r,n,o){return o||se(t,0,r,8),_t(t,e,r,n,52,8),r+8}xt.prototype.slice=function(t,e){var r,n=this.length;if((t=~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),(e=void 0===e?n:~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),e<t&&(e=t),xt.TYPED_ARRAY_SUPPORT)(r=this.subarray(t,e)).__proto__=xt.prototype;else{var o=e-t;r=new xt(o,void 0);for(var i=0;i<o;++i)r[i]=this[i+t]}return r},xt.prototype.readUIntLE=function(t,e,r){t|=0,e|=0,r||re(t,e,this.length);for(var n=this[t],o=1,i=0;++i<e&&(o*=256);)n+=this[t+i]*o;return n},xt.prototype.readUIntBE=function(t,e,r){t|=0,e|=0,r||re(t,e,this.length);for(var n=this[t+--e],o=1;e>0&&(o*=256);)n+=this[t+--e]*o;return n},xt.prototype.readUInt8=function(t,e){return e||re(t,1,this.length),this[t]},xt.prototype.readUInt16LE=function(t,e){return e||re(t,2,this.length),this[t]|this[t+1]<<8},xt.prototype.readUInt16BE=function(t,e){return e||re(t,2,this.length),this[t]<<8|this[t+1]},xt.prototype.readUInt32LE=function(t,e){return e||re(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},xt.prototype.readUInt32BE=function(t,e){return e||re(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},xt.prototype.readIntLE=function(t,e,r){t|=0,e|=0,r||re(t,e,this.length);for(var n=this[t],o=1,i=0;++i<e&&(o*=256);)n+=this[t+i]*o;return n>=(o*=128)&&(n-=Math.pow(2,8*e)),n},xt.prototype.readIntBE=function(t,e,r){t|=0,e|=0,r||re(t,e,this.length);for(var n=e,o=1,i=this[t+--n];n>0&&(o*=256);)i+=this[t+--n]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*e)),i},xt.prototype.readInt8=function(t,e){return e||re(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},xt.prototype.readInt16LE=function(t,e){e||re(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},xt.prototype.readInt16BE=function(t,e){e||re(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},xt.prototype.readInt32LE=function(t,e){return e||re(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},xt.prototype.readInt32BE=function(t,e){return e||re(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},xt.prototype.readFloatLE=function(t,e){return e||re(t,4,this.length),St(this,t,!0,23,4)},xt.prototype.readFloatBE=function(t,e){return e||re(t,4,this.length),St(this,t,!1,23,4)},xt.prototype.readDoubleLE=function(t,e){return e||re(t,8,this.length),St(this,t,!0,52,8)},xt.prototype.readDoubleBE=function(t,e){return e||re(t,8,this.length),St(this,t,!1,52,8)},xt.prototype.writeUIntLE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||ne(this,t,e,r,Math.pow(2,8*r)-1,0);var o=1,i=0;for(this[e]=255&t;++i<r&&(o*=256);)this[e+i]=t/o&255;return e+r},xt.prototype.writeUIntBE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||ne(this,t,e,r,Math.pow(2,8*r)-1,0);var o=r-1,i=1;for(this[e+o]=255&t;--o>=0&&(i*=256);)this[e+o]=t/i&255;return e+r},xt.prototype.writeUInt8=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,1,255,0),xt.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},xt.prototype.writeUInt16LE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,2,65535,0),xt.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):oe(this,t,e,!0),e+2},xt.prototype.writeUInt16BE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,2,65535,0),xt.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):oe(this,t,e,!1),e+2},xt.prototype.writeUInt32LE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,4,4294967295,0),xt.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):ie(this,t,e,!0),e+4},xt.prototype.writeUInt32BE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,4,4294967295,0),xt.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):ie(this,t,e,!1),e+4},xt.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e|=0,!n){var o=Math.pow(2,8*r-1);ne(this,t,e,r,o-1,-o)}var i=0,s=1,a=0;for(this[e]=255&t;++i<r&&(s*=256);)t<0&&0===a&&0!==this[e+i-1]&&(a=1),this[e+i]=(t/s>>0)-a&255;return e+r},xt.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e|=0,!n){var o=Math.pow(2,8*r-1);ne(this,t,e,r,o-1,-o)}var i=r-1,s=1,a=0;for(this[e+i]=255&t;--i>=0&&(s*=256);)t<0&&0===a&&0!==this[e+i+1]&&(a=1),this[e+i]=(t/s>>0)-a&255;return e+r},xt.prototype.writeInt8=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,1,127,-128),xt.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},xt.prototype.writeInt16LE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,2,32767,-32768),xt.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):oe(this,t,e,!0),e+2},xt.prototype.writeInt16BE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,2,32767,-32768),xt.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):oe(this,t,e,!1),e+2},xt.prototype.writeInt32LE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,4,2147483647,-2147483648),xt.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):ie(this,t,e,!0),e+4},xt.prototype.writeInt32BE=function(t,e,r){return t=+t,e|=0,r||ne(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),xt.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):ie(this,t,e,!1),e+4},xt.prototype.writeFloatLE=function(t,e,r){return ae(this,t,e,!0,r)},xt.prototype.writeFloatBE=function(t,e,r){return ae(this,t,e,!1,r)},xt.prototype.writeDoubleLE=function(t,e,r){return ue(this,t,e,!0,r)},xt.prototype.writeDoubleBE=function(t,e,r){return ue(this,t,e,!1,r)},xt.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var o,i=n-r;if(this===t&&r<e&&e<n)for(o=i-1;o>=0;--o)t[o+e]=this[o+r];else if(i<1e3||!xt.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)t[o+e]=this[o+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+i),e);return i},xt.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===t.length){var o=t.charCodeAt(0);o<256&&(t=o)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!xt.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof t&&(t&=255);if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;var i;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(i=e;i<r;++i)this[i]=t;else{var s=Dt(t)?t:le(new xt(t,n).toString()),a=s.length;for(i=0;i<r-e;++i)this[i+e]=s[i%a]}return this};var ce=/[^+\/0-9A-Za-z-_]/g;function fe(t){return t<16?"0"+t.toString(16):t.toString(16)}function le(t,e){var r;e=e||1/0;for(var n=t.length,o=null,i=[],s=0;s<n;++s){if((r=t.charCodeAt(s))>55295&&r<57344){if(!o){if(r>56319){(e-=3)>-1&&i.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(e-=3)>-1&&i.push(239,191,189),o=r;continue}r=65536+(o-55296<<10|r-56320)}else o&&(e-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((e-=1)<0)break;i.push(r)}else if(r<2048){if((e-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function he(t){return function(t){var e,r,n,o,i,s;Et||Rt();var a=t.length;if(a%4>0)throw new Error("Invalid string. Length must be a multiple of 4");i="="===t[a-2]?2:"="===t[a-1]?1:0,s=new vt(3*a/4-i),n=i>0?a-4:a;var u=0;for(e=0,r=0;e<n;e+=4,r+=3)o=bt[t.charCodeAt(e)]<<18|bt[t.charCodeAt(e+1)]<<12|bt[t.charCodeAt(e+2)]<<6|bt[t.charCodeAt(e+3)],s[u++]=o>>16&255,s[u++]=o>>8&255,s[u++]=255&o;return 2===i?(o=bt[t.charCodeAt(e)]<<2|bt[t.charCodeAt(e+1)]>>4,s[u++]=255&o):1===i&&(o=bt[t.charCodeAt(e)]<<10|bt[t.charCodeAt(e+1)]<<4|bt[t.charCodeAt(e+2)]>>2,s[u++]=o>>8&255,s[u++]=255&o),s}(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(ce,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function pe(t,e,r,n){for(var o=0;o<n&&!(o+r>=e.length||o>=t.length);++o)e[o+r]=t[o];return o}function de(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}function ge(t,e,r,n,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=t,this.name="AxiosError",e&&(this.code=e),r&&(this.config=r),n&&(this.request=n),o&&(this.response=o,this.status=o.status?o.status:null)}yt.inherits(ge,Error,{toJSON:function(){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:yt.toJSONObject(this.config),code:this.code,status:this.status}}});const me=ge.prototype,ye={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{ye[t]={value:t}}),Object.defineProperties(ge,ye),Object.defineProperty(me,"isAxiosError",{value:!0}),ge.from=(t,e,r,n,o,i)=>{const s=Object.create(me);return yt.toFlatObject(t,s,(function(t){return t!==Error.prototype}),t=>"isAxiosError"!==t),ge.call(s,t.message,e,r,n,o),s.cause=t,s.name=t.name,i&&Object.assign(s,i),s};function we(t){return yt.isPlainObject(t)||yt.isArray(t)}function be(t){return yt.endsWith(t,"[]")?t.slice(0,-2):t}function ve(t,e,r){return t?t.concat(e).map((function(t,e){return t=be(t),!r&&e?"["+t+"]":t})).join(r?".":""):e}const Ee=yt.toFlatObject(yt,{},null,(function(t){return/^is[A-Z]/.test(t)}));function Re(t,e,r){if(!yt.isObject(t))throw new TypeError("target must be an object");e=e||new FormData;const n=(r=yt.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(t,e){return!yt.isUndefined(e[t])}))).metaTokens,o=r.visitor||c,i=r.dots,s=r.indexes,a=(r.Blob||"undefined"!=typeof Blob&&Blob)&&yt.isSpecCompliantForm(e);if(!yt.isFunction(o))throw new TypeError("visitor must be a function");function u(t){if(null===t)return"";if(yt.isDate(t))return t.toISOString();if(!a&&yt.isBlob(t))throw new ge("Blob is not supported. Use a Buffer instead.");return yt.isArrayBuffer(t)||yt.isTypedArray(t)?a&&"function"==typeof Blob?new Blob([t]):xt.from(t):t}function c(t,r,o){let a=t;if(t&&!o&&"object"==typeof t)if(yt.endsWith(r,"{}"))r=n?r:r.slice(0,-2),t=JSON.stringify(t);else if(yt.isArray(t)&&function(t){return yt.isArray(t)&&!t.some(we)}(t)||(yt.isFileList(t)||yt.endsWith(r,"[]"))&&(a=yt.toArray(t)))return r=be(r),a.forEach((function(t,n){!yt.isUndefined(t)&&null!==t&&e.append(!0===s?ve([r],n,i):null===s?r:r+"[]",u(t))})),!1;return!!we(t)||(e.append(ve(o,r,i),u(t)),!1)}const f=[],l=Object.assign(Ee,{defaultVisitor:c,convertValue:u,isVisitable:we});if(!yt.isObject(t))throw new TypeError("data must be an object");return function t(r,n){if(!yt.isUndefined(r)){if(-1!==f.indexOf(r))throw Error("Circular reference detected in "+n.join("."));f.push(r),yt.forEach(r,(function(r,i){!0===(!(yt.isUndefined(r)||null===r)&&o.call(e,r,yt.isString(i)?i.trim():i,n,l))&&t(r,n?n.concat(i):[i])})),f.pop()}}(t),e}function Ae(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,(function(t){return e[t]}))}function Te(t,e){this._pairs=[],t&&Re(t,this,e)}const Se=Te.prototype;function _e(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Oe(t,e,r){if(!e)return t;const n=r&&r.encode||_e;yt.isFunction(r)&&(r={serialize:r});const o=r&&r.serialize;let i;if(i=o?o(e,r):yt.isURLSearchParams(e)?e.toString():new Te(e,r).toString(n)){const e=t.indexOf("#");-1!==e&&(t=t.slice(0,e)),t+=(-1===t.indexOf("?")?"?":"&")+i}return t}Se.append=function(t,e){this._pairs.push([t,e])},Se.toString=function(t){const e=t?function(e){return t.call(this,e,Ae)}:Ae;return this._pairs.map((function(t){return e(t[0])+"="+e(t[1])}),"").join("&")};class Pe{constructor(){this.handlers=[]}use(t,e,r){return this.handlers.push({fulfilled:t,rejected:e,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){yt.forEach(this.handlers,(function(e){null!==e&&t(e)}))}}var Ce={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ue={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:Te,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};const xe="undefined"!=typeof window&&"undefined"!=typeof document,Be="object"==typeof navigator&&navigator||void 0,ke=xe&&(!Be||["ReactNative","NativeScript","NS"].indexOf(Be.product)<0),je=(()=>"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts)(),Le=xe&&window.location.href||"http://localhost";var Ne={...Object.freeze({hasBrowserEnv:xe,hasStandardBrowserWebWorkerEnv:je,hasStandardBrowserEnv:ke,navigator:Be,origin:Le}),...Ue};function De(t){function e(t,r,n,o){let i=t[o++];if("__proto__"===i)return!0;const s=Number.isFinite(+i),a=o>=t.length;return i=!i&&yt.isArray(n)?n.length:i,a?(yt.hasOwnProp(n,i)?n[i]=[n[i],r]:n[i]=r,!s):(n[i]&&yt.isObject(n[i])||(n[i]=[]),e(t,r,n[i],o)&&yt.isArray(n[i])&&(n[i]=function(t){const e={},r=Object.keys(t);let n;const o=r.length;let i;for(n=0;n<o;n++)e[i=r[n]]=t[i];return e}(n[i])),!s)}if(yt.isFormData(t)&&yt.isFunction(t.entries)){const r={};return yt.forEachEntry(t,(t,n)=>{e(function(t){return yt.matchAll(/\w+|\[(\w*)]/g,t).map(t=>"[]"===t[0]?"":t[1]||t[0])}(t),n,r,0)}),r}return null}const Ie={transitional:Ce,adapter:["xhr","http","fetch"],transformRequest:[function(t,e){const r=e.getContentType()||"",n=r.indexOf("application/json")>-1,o=yt.isObject(t);if(o&&yt.isHTMLForm(t)&&(t=new FormData(t)),yt.isFormData(t))return n?JSON.stringify(De(t)):t;if(yt.isArrayBuffer(t)||yt.isBuffer(t)||yt.isStream(t)||yt.isFile(t)||yt.isBlob(t)||yt.isReadableStream(t))return t;if(yt.isArrayBufferView(t))return t.buffer;if(yt.isURLSearchParams(t))return e.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return function(t,e){return Re(t,new Ne.classes.URLSearchParams,Object.assign({visitor:function(t,e,r,n){return Ne.isNode&&yt.isBuffer(t)?(this.append(e,t.toString("base64")),!1):n.defaultVisitor.apply(this,arguments)}},e))}(t,this.formSerializer).toString();if((i=yt.isFileList(t))||r.indexOf("multipart/form-data")>-1){const e=this.env&&this.env.FormData;return Re(i?{"files[]":t}:t,e&&new e,this.formSerializer)}}return o||n?(e.setContentType("application/json",!1),function(t,e,r){if(yt.isString(t))try{return(e||JSON.parse)(t),yt.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(r||JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){const e=this.transitional||Ie.transitional,r=e&&e.forcedJSONParsing,n="json"===this.responseType;if(yt.isResponse(t)||yt.isReadableStream(t))return t;if(t&&yt.isString(t)&&(r&&!this.responseType||n)){const r=!(e&&e.silentJSONParsing)&&n;try{return JSON.parse(t)}catch(t){if(r){if("SyntaxError"===t.name)throw ge.from(t,ge.ERR_BAD_RESPONSE,this,null,this.response);throw t}}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Ne.classes.FormData,Blob:Ne.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};yt.forEach(["delete","get","head","post","put","patch"],t=>{Ie.headers[t]={}});const qe=yt.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"]);var Fe=t=>{const e={};let r,n,o;return t&&t.split("\n").forEach((function(t){o=t.indexOf(":"),r=t.substring(0,o).trim().toLowerCase(),n=t.substring(o+1).trim(),!r||e[r]&&qe[r]||("set-cookie"===r?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)})),e};const Me=Symbol("internals");function ze(t){return t&&String(t).trim().toLowerCase()}function Ye(t){return!1===t||null==t?t:yt.isArray(t)?t.map(Ye):String(t)}const He=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Je(t,e,r,n,o){return yt.isFunction(n)?n.call(this,e,r):(o&&(e=r),yt.isString(e)?yt.isString(n)?-1!==e.indexOf(n):yt.isRegExp(n)?n.test(e):void 0:void 0)}class Ve{constructor(t){t&&this.set(t)}set(t,e,r){const n=this;function o(t,e,r){const o=ze(e);if(!o)throw new Error("header name must be a non-empty string");const i=yt.findKey(n,o);(!i||void 0===n[i]||!0===r||void 0===r&&!1!==n[i])&&(n[i||e]=Ye(t))}const i=(t,e)=>yt.forEach(t,(t,r)=>o(t,r,e));if(yt.isPlainObject(t)||t instanceof this.constructor)i(t,e);else if(yt.isString(t)&&(t=t.trim())&&!He(t))i(Fe(t),e);else if(yt.isHeaders(t))for(const[e,n]of t.entries())o(n,e,r);else null!=t&&o(e,t,r);return this}get(t,e){if(t=ze(t)){const r=yt.findKey(this,t);if(r){const t=this[r];if(!e)return t;if(!0===e)return function(t){const e=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(t);)e[n[1]]=n[2];return e}(t);if(yt.isFunction(e))return e.call(this,t,r);if(yt.isRegExp(e))return e.exec(t);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,e){if(t=ze(t)){const r=yt.findKey(this,t);return!(!r||void 0===this[r]||e&&!Je(0,this[r],r,e))}return!1}delete(t,e){const r=this;let n=!1;function o(t){if(t=ze(t)){const o=yt.findKey(r,t);!o||e&&!Je(0,r[o],o,e)||(delete r[o],n=!0)}}return yt.isArray(t)?t.forEach(o):o(t),n}clear(t){const e=Object.keys(this);let r=e.length,n=!1;for(;r--;){const o=e[r];t&&!Je(0,this[o],o,t,!0)||(delete this[o],n=!0)}return n}normalize(t){const e=this,r={};return yt.forEach(this,(n,o)=>{const i=yt.findKey(r,o);if(i)return e[i]=Ye(n),void delete e[o];const s=t?function(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,e,r)=>e.toUpperCase()+r)}(o):String(o).trim();s!==o&&delete e[o],e[s]=Ye(n),r[s]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const e=Object.create(null);return yt.forEach(this,(r,n)=>{null!=r&&!1!==r&&(e[n]=t&&yt.isArray(r)?r.join(", "):r)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,e])=>t+": "+e).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...e){const r=new this(t);return e.forEach(t=>r.set(t)),r}static accessor(t){const e=(this[Me]=this[Me]={accessors:{}}).accessors,r=this.prototype;function n(t){const n=ze(t);e[n]||(!function(t,e){const r=yt.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(t,r,o){return this[n].call(this,e,t,r,o)},configurable:!0})})}(r,t),e[n]=!0)}return yt.isArray(t)?t.forEach(n):n(t),this}}function We(t,e){const r=this||Ie,n=e||r,o=Ve.from(n.headers);let i=n.data;return yt.forEach(t,(function(t){i=t.call(r,i,o.normalize(),e?e.status:void 0)})),o.normalize(),i}function Ke(t){return!(!t||!t.__CANCEL__)}function $e(t,e,r){ge.call(this,null==t?"canceled":t,ge.ERR_CANCELED,e,r),this.name="CanceledError"}function Ge(t,e,r){const n=r.config.validateStatus;r.status&&n&&!n(r.status)?e(new ge("Request failed with status code "+r.status,[ge.ERR_BAD_REQUEST,ge.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r)):t(r)}Ve.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),yt.reduceDescriptors(Ve.prototype,({value:t},e)=>{let r=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(t){this[r]=t}}}),yt.freezeMethods(Ve),yt.inherits($e,ge,{__CANCEL__:!0});const Xe=(t,e,r=3)=>{let n=0;const o=function(t,e){t=t||10;const r=new Array(t),n=new Array(t);let o,i=0,s=0;return e=void 0!==e?e:1e3,function(a){const u=Date.now(),c=n[s];o||(o=u),r[i]=a,n[i]=u;let f=s,l=0;for(;f!==i;)l+=r[f++],f%=t;if((i=(i+1)%t)===s&&(s=(s+1)%t),u-o<e)return;const h=c&&u-c;return h?Math.round(1e3*l/h):void 0}}(50,250);return function(t,e){let r,n,o=0,i=1e3/e;const s=(e,i=Date.now())=>{o=i,r=null,n&&(clearTimeout(n),n=null),t.apply(null,e)};return[(...t)=>{const e=Date.now(),a=e-o;a>=i?s(t,e):(r=t,n||(n=setTimeout(()=>{n=null,s(r)},i-a)))},()=>r&&s(r)]}(r=>{const i=r.loaded,s=r.lengthComputable?r.total:void 0,a=i-n,u=o(a);n=i,t({loaded:i,total:s,progress:s?i/s:void 0,bytes:a,rate:u||void 0,estimated:u&&s&&i<=s?(s-i)/u:void 0,event:r,lengthComputable:null!=s,[e?"download":"upload"]:!0})},r)},Qe=(t,e)=>{const r=null!=t;return[n=>e[0]({lengthComputable:r,total:t,loaded:n}),e[1]]},Ze=t=>(...e)=>yt.asap(()=>t(...e));var tr=Ne.hasStandardBrowserEnv?((t,e)=>r=>(r=new URL(r,Ne.origin),t.protocol===r.protocol&&t.host===r.host&&(e||t.port===r.port)))(new URL(Ne.origin),Ne.navigator&&/(msie|trident)/i.test(Ne.navigator.userAgent)):()=>!0,er=Ne.hasStandardBrowserEnv?{write(t,e,r,n,o,i){const s=[t+"="+encodeURIComponent(e)];yt.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),yt.isString(n)&&s.push("path="+n),yt.isString(o)&&s.push("domain="+o),!0===i&&s.push("secure"),document.cookie=s.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}};function rr(t,e){return t&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)?function(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}(t,e):e}const nr=t=>t instanceof Ve?{...t}:t;function or(t,e){e=e||{};const r={};function n(t,e,r,n){return yt.isPlainObject(t)&&yt.isPlainObject(e)?yt.merge.call({caseless:n},t,e):yt.isPlainObject(e)?yt.merge({},e):yt.isArray(e)?e.slice():e}function o(t,e,r,o){return yt.isUndefined(e)?yt.isUndefined(t)?void 0:n(void 0,t,0,o):n(t,e,0,o)}function i(t,e){if(!yt.isUndefined(e))return n(void 0,e)}function s(t,e){return yt.isUndefined(e)?yt.isUndefined(t)?void 0:n(void 0,t):n(void 0,e)}function a(r,o,i){return i in e?n(r,o):i in t?n(void 0,r):void 0}const u={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:a,headers:(t,e,r)=>o(nr(t),nr(e),0,!0)};return yt.forEach(Object.keys(Object.assign({},t,e)),(function(n){const i=u[n]||o,s=i(t[n],e[n],n);yt.isUndefined(s)&&i!==a||(r[n]=s)})),r}var ir=t=>{const e=or({},t);let r,{data:n,withXSRFToken:o,xsrfHeaderName:i,xsrfCookieName:s,headers:a,auth:u}=e;if(e.headers=a=Ve.from(a),e.url=Oe(rr(e.baseURL,e.url),t.params,t.paramsSerializer),u&&a.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?unescape(encodeURIComponent(u.password)):""))),yt.isFormData(n))if(Ne.hasStandardBrowserEnv||Ne.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(!1!==(r=a.getContentType())){const[t,...e]=r?r.split(";").map(t=>t.trim()).filter(Boolean):[];a.setContentType([t||"multipart/form-data",...e].join("; "))}if(Ne.hasStandardBrowserEnv&&(o&&yt.isFunction(o)&&(o=o(e)),o||!1!==o&&tr(e.url))){const t=i&&s&&er.read(s);t&&a.set(i,t)}return e};var sr="undefined"!=typeof XMLHttpRequest&&function(t){return new Promise((function(e,r){const n=ir(t);let o=n.data;const i=Ve.from(n.headers).normalize();let s,a,u,c,f,{responseType:l,onUploadProgress:h,onDownloadProgress:p}=n;function d(){c&&c(),f&&f(),n.cancelToken&&n.cancelToken.unsubscribe(s),n.signal&&n.signal.removeEventListener("abort",s)}let g=new XMLHttpRequest;function m(){if(!g)return;const n=Ve.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders());Ge((function(t){e(t),d()}),(function(t){r(t),d()}),{data:l&&"text"!==l&&"json"!==l?g.response:g.responseText,status:g.status,statusText:g.statusText,headers:n,config:t,request:g}),g=null}g.open(n.method.toUpperCase(),n.url,!0),g.timeout=n.timeout,"onloadend"in g?g.onloadend=m:g.onreadystatechange=function(){g&&4===g.readyState&&(0!==g.status||g.responseURL&&0===g.responseURL.indexOf("file:"))&&setTimeout(m)},g.onabort=function(){g&&(r(new ge("Request aborted",ge.ECONNABORTED,t,g)),g=null)},g.onerror=function(){r(new ge("Network Error",ge.ERR_NETWORK,t,g)),g=null},g.ontimeout=function(){let e=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const o=n.transitional||Ce;n.timeoutErrorMessage&&(e=n.timeoutErrorMessage),r(new ge(e,o.clarifyTimeoutError?ge.ETIMEDOUT:ge.ECONNABORTED,t,g)),g=null},void 0===o&&i.setContentType(null),"setRequestHeader"in g&&yt.forEach(i.toJSON(),(function(t,e){g.setRequestHeader(e,t)})),yt.isUndefined(n.withCredentials)||(g.withCredentials=!!n.withCredentials),l&&"json"!==l&&(g.responseType=n.responseType),p&&([u,f]=Xe(p,!0),g.addEventListener("progress",u)),h&&g.upload&&([a,c]=Xe(h),g.upload.addEventListener("progress",a),g.upload.addEventListener("loadend",c)),(n.cancelToken||n.signal)&&(s=e=>{g&&(r(!e||e.type?new $e(null,t,g):e),g.abort(),g=null)},n.cancelToken&&n.cancelToken.subscribe(s),n.signal&&(n.signal.aborted?s():n.signal.addEventListener("abort",s)));const y=function(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}(n.url);y&&-1===Ne.protocols.indexOf(y)?r(new ge("Unsupported protocol "+y+":",ge.ERR_BAD_REQUEST,t)):g.send(o||null)}))};const ar=(t,e)=>{const{length:r}=t=t?t.filter(Boolean):[];if(e||r){let r,n=new AbortController;const o=function(t){if(!r){r=!0,s();const e=t instanceof Error?t:this.reason;n.abort(e instanceof ge?e:new $e(e instanceof Error?e.message:e))}};let i=e&&setTimeout(()=>{i=null,o(new ge(`timeout ${e} of ms exceeded`,ge.ETIMEDOUT))},e);const s=()=>{t&&(i&&clearTimeout(i),i=null,t.forEach(t=>{t.unsubscribe?t.unsubscribe(o):t.removeEventListener("abort",o)}),t=null)};t.forEach(t=>t.addEventListener("abort",o));const{signal:a}=n;return a.unsubscribe=()=>yt.asap(s),a}},ur=function*(t,e){let r=t.byteLength;if(!e||r<e)return voi