UNPKG

@flatfile/javascript

Version:

Flatfile embedded with vanilla javascript.

1 lines 1.14 MB
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).FlatFileJavaScript={})}(this,(function(e){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function o(e){if(e.__esModule)return e;var t=e.default;if("function"==typeof t){var r=function e(){return this instanceof e?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach((function(t){var o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,o.get?o:{enumerable:!0,get:function(){return e[t]}})})),r}var n={},i={},a=class{static get(e){return this.safeEnvLookup(e)}static set(e,t){return this._overrides.set(e,t)}static alias(e,t){return this._aliases.set(e,t)}static attachConfigRegistry(e){this._registry=e}static attachConfigFactory(e){this._factory=e}static reset(){this._overrides=new Map,this._registry=void 0,this._factory=void 0}static safeEnvLookup(e){let t=[];this._overrides.get(e)&&t.push(this._overrides.get(e)),"object"==typeof this._registry&&t.push(this._registry[e]),"function"==typeof this._factory&&t.push(this._factory(e)),"object"==typeof process&&"object"==typeof process.env&&t.push(process.env[e]),t.push(...this.checkForBrowserVariables(e));const r=t.find((e=>void 0!==e));if(void 0!==r)return r;const o=this._aliases.get(e);return o?this.safeEnvLookup(o):void 0}static checkForBrowserVariables(e){let t=[];if("object"==typeof window){const r=window[`CROSSENV_${e}`];if(void 0!==r&&t.push(r),"object"==typeof sessionStorage){const r=sessionStorage.getItem(`CROSSENV_${e}`);null!==r&&t.push(r)}}return t}};a._overrides=new Map,a._aliases=new Map;var s=o(Object.freeze({__proto__:null,CrossEnvConfig:a})),l={exports:{}};!function(e){var r,o;r=t,o=function(){return function(){return function(e){var t=[];if(0===e.length)return"";if("string"!=typeof e[0])throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var r=e.shift();e[0]=r+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var o=0;o<e.length;o++){var n=e[o];if("string"!=typeof n)throw new TypeError("Url must be a string. Received "+n);""!==n&&(o>0&&(n=n.replace(/^[\/]+/,"")),n=o<e.length-1?n.replace(/[\/]+$/,""):n.replace(/[\/]+$/,"/"),t.push(n))}var i=t.join("/"),a=(i=i.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return a.shift()+(a.length>0?"?":"")+a.join("&")}("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},e.exports?e.exports=o():r.urljoin=o()}(l);var u=l.exports,c={},d={},f={};Object.defineProperty(f,"__esModule",{value:!0}),f.FlatfileEnvironment=void 0,f.FlatfileEnvironment={Production:"https://api.x.flatfile.com/v1"};var p,b={},_={},v={},y="object"==typeof self?self.FormData:window.FormData,h=Error,g=EvalError,m=RangeError,O=ReferenceError,w=SyntaxError,j=TypeError,P=URIError,M="undefined"!=typeof Symbol&&Symbol,E=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var o=Object.getOwnPropertySymbols(e);if(1!==o.length||o[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var n=Object.getOwnPropertyDescriptor(e,t);if(42!==n.value||!0!==n.enumerable)return!1}return!0},S={__proto__:null,foo:{}},z=Object,F=Object.prototype.toString,k=Math.max,R=function(e,t){for(var r=[],o=0;o<e.length;o+=1)r[o]=e[o];for(var n=0;n<t.length;n+=1)r[n+e.length]=t[n];return r},D=function(e){var t=this;if("function"!=typeof t||"[object Function]"!==F.apply(t))throw new TypeError("Function.prototype.bind called on incompatible "+t);for(var r,o=function(e,t){for(var r=[],o=t,n=0;o<e.length;o+=1,n+=1)r[n]=e[o];return r}(arguments,1),n=k(0,t.length-o.length),i=[],a=0;a<n;a++)i[a]="$"+a;if(r=Function("binder","return function ("+function(e,t){for(var r="",o=0;o<e.length;o+=1)r+=e[o],o+1<e.length&&(r+=t);return r}(i,",")+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof r){var n=t.apply(this,R(o,arguments));return Object(n)===n?n:this}return t.apply(e,R(o,arguments))})),t.prototype){var s=function(){};s.prototype=t.prototype,r.prototype=new s,s.prototype=null}return r},U=Function.prototype.bind||D,T=Function.prototype.call,x=Object.prototype.hasOwnProperty,C=U.call(T,x),I=h,A=g,V=m,B=O,N=w,X=j,K=P,L=Function,H=function(e){try{return L('"use strict"; return ('+e+").constructor;")()}catch(e){}},J=Object.getOwnPropertyDescriptor;if(J)try{J({},"")}catch(e){J=null}var $=function(){throw new X},q=J?function(){try{return $}catch(e){try{return J(arguments,"callee").get}catch(e){return $}}}():$,G="function"==typeof M&&"function"==typeof Symbol&&"symbol"==typeof M("foo")&&"symbol"==typeof Symbol("bar")&&E(),W={__proto__:S}.foo===S.foo&&!(S instanceof z),Z=Object.getPrototypeOf||(W?function(e){return e.__proto__}:null),Y={},Q="undefined"!=typeof Uint8Array&&Z?Z(Uint8Array):p,ee={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?p:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?p:ArrayBuffer,"%ArrayIteratorPrototype%":G&&Z?Z([][Symbol.iterator]()):p,"%AsyncFromSyncIteratorPrototype%":p,"%AsyncFunction%":Y,"%AsyncGenerator%":Y,"%AsyncGeneratorFunction%":Y,"%AsyncIteratorPrototype%":Y,"%Atomics%":"undefined"==typeof Atomics?p:Atomics,"%BigInt%":"undefined"==typeof BigInt?p:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?p:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?p:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?p:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":I,"%eval%":eval,"%EvalError%":A,"%Float32Array%":"undefined"==typeof Float32Array?p:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?p:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?p:FinalizationRegistry,"%Function%":L,"%GeneratorFunction%":Y,"%Int8Array%":"undefined"==typeof Int8Array?p:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?p:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?p:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":G&&Z?Z(Z([][Symbol.iterator]())):p,"%JSON%":"object"==typeof JSON?JSON:p,"%Map%":"undefined"==typeof Map?p:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&G&&Z?Z((new Map)[Symbol.iterator]()):p,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?p:Promise,"%Proxy%":"undefined"==typeof Proxy?p:Proxy,"%RangeError%":V,"%ReferenceError%":B,"%Reflect%":"undefined"==typeof Reflect?p:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?p:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&G&&Z?Z((new Set)[Symbol.iterator]()):p,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?p:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":G&&Z?Z(""[Symbol.iterator]()):p,"%Symbol%":G?Symbol:p,"%SyntaxError%":N,"%ThrowTypeError%":q,"%TypedArray%":Q,"%TypeError%":X,"%Uint8Array%":"undefined"==typeof Uint8Array?p:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?p:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?p:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?p:Uint32Array,"%URIError%":K,"%WeakMap%":"undefined"==typeof WeakMap?p:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?p:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?p:WeakSet};if(Z)try{null.error}catch(e){var te=Z(Z(e));ee["%Error.prototype%"]=te}var re,oe,ne=function e(t){var r;if("%AsyncFunction%"===t)r=H("async function () {}");else if("%GeneratorFunction%"===t)r=H("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=H("async function* () {}");else if("%AsyncGenerator%"===t){var o=e("%AsyncGeneratorFunction%");o&&(r=o.prototype)}else if("%AsyncIteratorPrototype%"===t){var n=e("%AsyncGenerator%");n&&Z&&(r=Z(n.prototype))}return ee[t]=r,r},ie={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ae=U,se=C,le=ae.call(Function.call,Array.prototype.concat),ue=ae.call(Function.apply,Array.prototype.splice),ce=ae.call(Function.call,String.prototype.replace),de=ae.call(Function.call,String.prototype.slice),fe=ae.call(Function.call,RegExp.prototype.exec),pe=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,be=/\\(\\)?/g,_e=function(e,t){var r,o=e;if(se(ie,o)&&(o="%"+(r=ie[o])[0]+"%"),se(ee,o)){var n=ee[o];if(n===Y&&(n=ne(o)),void 0===n&&!t)throw new X("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:o,value:n}}throw new N("intrinsic "+e+" does not exist!")},ve=function(e,t){if("string"!=typeof e||0===e.length)throw new X("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new X('"allowMissing" argument must be a boolean');if(null===fe(/^%?[^%]*%?$/,e))throw new N("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=function(e){var t=de(e,0,1),r=de(e,-1);if("%"===t&&"%"!==r)throw new N("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new N("invalid intrinsic syntax, expected opening `%`");var o=[];return ce(e,pe,(function(e,t,r,n){o[o.length]=r?ce(n,be,"$1"):t||e})),o}(e),o=r.length>0?r[0]:"",n=_e("%"+o+"%",t),i=n.name,a=n.value,s=!1,l=n.alias;l&&(o=l[0],ue(r,le([0,1],l)));for(var u=1,c=!0;u<r.length;u+=1){var d=r[u],f=de(d,0,1),p=de(d,-1);if(('"'===f||"'"===f||"`"===f||'"'===p||"'"===p||"`"===p)&&f!==p)throw new N("property names with quotes must have matching quotes");if("constructor"!==d&&c||(s=!0),se(ee,i="%"+(o+="."+d)+"%"))a=ee[i];else if(null!=a){if(!(d in a)){if(!t)throw new X("base intrinsic for "+e+" exists, but the property is not available.");return}if(J&&u+1>=r.length){var b=J(a,d);a=(c=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:a[d]}else c=se(a,d),a=a[d];c&&!s&&(ee[i]=a)}}return a},ye={exports:{}};function he(){if(oe)return re;oe=1;var e=ve("%Object.defineProperty%",!0)||!1;if(e)try{e({},"a",{value:1})}catch(t){e=!1}return re=e}var ge=ve("%Object.getOwnPropertyDescriptor%",!0);if(ge)try{ge([],"length")}catch(e){ge=null}var me=ge,Oe=he(),we=w,je=j,Pe=me,Me=he(),Ee=function(){return!!Me};Ee.hasArrayLengthDefineBug=function(){if(!Me)return null;try{return 1!==Me([],"length",{value:1}).length}catch(e){return!0}};var Se=ve,ze=function(e,t,r){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new je("`obj` must be an object or a function`");if("string"!=typeof t&&"symbol"!=typeof t)throw new je("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new je("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new je("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new je("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new je("`loose`, if provided, must be a boolean");var o=arguments.length>3?arguments[3]:null,n=arguments.length>4?arguments[4]:null,i=arguments.length>5?arguments[5]:null,a=arguments.length>6&&arguments[6],s=!!Pe&&Pe(e,t);if(Oe)Oe(e,t,{configurable:null===i&&s?s.configurable:!i,enumerable:null===o&&s?s.enumerable:!o,value:r,writable:null===n&&s?s.writable:!n});else{if(!a&&(o||n||i))throw new we("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");e[t]=r}},Fe=Ee(),ke=me,Re=j,De=Se("%Math.floor%"),Ue=function(e,t){if("function"!=typeof e)throw new Re("`fn` is not a function");if("number"!=typeof t||t<0||t>4294967295||De(t)!==t)throw new Re("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],o=!0,n=!0;if("length"in e&&ke){var i=ke(e,"length");i&&!i.configurable&&(o=!1),i&&!i.writable&&(n=!1)}return(o||n||!r)&&(Fe?ze(e,"length",t,!0,!0):ze(e,"length",t)),e};!function(e){var t=U,r=ve,o=Ue,n=j,i=r("%Function.prototype.apply%"),a=r("%Function.prototype.call%"),s=r("%Reflect.apply%",!0)||t.call(a,i),l=he(),u=r("%Math.max%");e.exports=function(e){if("function"!=typeof e)throw new n("a function is required");var r=s(t,a,arguments);return o(r,1+u(0,e.length-(arguments.length-1)),!0)};var c=function(){return s(t,i,arguments)};l?l(e.exports,"apply",{value:c}):e.exports.apply=c}(ye);var Te=ve,xe=ye.exports,Ce=xe(Te("String.prototype.indexOf")),Ie=o(Object.freeze({__proto__:null,default:{}})),Ae="function"==typeof Map&&Map.prototype,Ve=Object.getOwnPropertyDescriptor&&Ae?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Be=Ae&&Ve&&"function"==typeof Ve.get?Ve.get:null,Ne=Ae&&Map.prototype.forEach,Xe="function"==typeof Set&&Set.prototype,Ke=Object.getOwnPropertyDescriptor&&Xe?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Le=Xe&&Ke&&"function"==typeof Ke.get?Ke.get:null,He=Xe&&Set.prototype.forEach,Je="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,$e="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,qe="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,Ge=Boolean.prototype.valueOf,We=Object.prototype.toString,Ze=Function.prototype.toString,Ye=String.prototype.match,Qe=String.prototype.slice,et=String.prototype.replace,tt=String.prototype.toUpperCase,rt=String.prototype.toLowerCase,ot=RegExp.prototype.test,nt=Array.prototype.concat,it=Array.prototype.join,at=Array.prototype.slice,st=Math.floor,lt="function"==typeof BigInt?BigInt.prototype.valueOf:null,ut=Object.getOwnPropertySymbols,ct="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,dt="function"==typeof Symbol&&"object"==typeof Symbol.iterator,ft="function"==typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===dt||"symbol")?Symbol.toStringTag:null,pt=Object.prototype.propertyIsEnumerable,bt=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function _t(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||ot.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var o=e<0?-st(-e):st(e);if(o!==e){var n=String(o),i=Qe.call(t,n.length+1);return et.call(n,r,"$&_")+"."+et.call(et.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return et.call(t,r,"$&_")}var vt=Ie,yt=vt.custom,ht=Mt(yt)?yt:null,gt={__proto__:null,double:'"',single:"'"},mt={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};function Ot(e,t,r){var o=r.quoteStyle||t,n=gt[o];return n+e+n}function wt(e){return et.call(String(e),/"/g,"&quot;")}function jt(e){return!("[object Array]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}function Pt(e){return!("[object RegExp]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}function Mt(e){if(dt)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!ct)return!1;try{return ct.call(e),!0}catch(e){}return!1}var Et=Object.prototype.hasOwnProperty||function(e){return e in this};function St(e,t){return Et.call(e,t)}function zt(e){return We.call(e)}function Ft(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,o=e.length;r<o;r++)if(e[r]===t)return r;return-1}function kt(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,o="... "+r+" more character"+(r>1?"s":"");return kt(Qe.call(e,0,t.maxStringLength),t)+o}var n=mt[t.quoteStyle||"single"];return n.lastIndex=0,Ot(et.call(et.call(e,n,"\\$1"),/[\x00-\x1f]/g,Rt),"single",t)}function Rt(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+tt.call(t.toString(16))}function Dt(e){return"Object("+e+")"}function Ut(e){return e+" { ? }"}function Tt(e,t,r,o){return e+" ("+t+") {"+(o?xt(r,o):it.call(r,", "))+"}"}function xt(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+it.call(e,","+r)+"\n"+t.prev}function Ct(e,t){var r=jt(e),o=[];if(r){o.length=e.length;for(var n=0;n<e.length;n++)o[n]=St(e,n)?t(e[n],e):""}var i,a="function"==typeof ut?ut(e):[];if(dt){i={};for(var s=0;s<a.length;s++)i["$"+a[s]]=a[s]}for(var l in e)St(e,l)&&(r&&String(Number(l))===l&&l<e.length||dt&&i["$"+l]instanceof Symbol||(ot.call(/[^\w$]/,l)?o.push(t(l,e)+": "+t(e[l],e)):o.push(l+": "+t(e[l],e))));if("function"==typeof ut)for(var u=0;u<a.length;u++)pt.call(e,a[u])&&o.push("["+t(a[u])+"]: "+t(e[a[u]],e));return o}var It,At,Vt,Bt,Nt=ve,Xt=function(e,t){var r=Te(e,!!t);return"function"==typeof r&&Ce(e,".prototype.")>-1?xe(r):r},Kt=function e(r,o,n,i){var a=o||{};if(St(a,"quoteStyle")&&!St(gt,a.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(St(a,"maxStringLength")&&("number"==typeof a.maxStringLength?a.maxStringLength<0&&a.maxStringLength!==1/0:null!==a.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var s=!St(a,"customInspect")||a.customInspect;if("boolean"!=typeof s&&"symbol"!==s)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(St(a,"indent")&&null!==a.indent&&"\t"!==a.indent&&!(parseInt(a.indent,10)===a.indent&&a.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(St(a,"numericSeparator")&&"boolean"!=typeof a.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var l=a.numericSeparator;if(void 0===r)return"undefined";if(null===r)return"null";if("boolean"==typeof r)return r?"true":"false";if("string"==typeof r)return kt(r,a);if("number"==typeof r){if(0===r)return 1/0/r>0?"0":"-0";var u=String(r);return l?_t(r,u):u}if("bigint"==typeof r){var c=String(r)+"n";return l?_t(r,c):c}var d=void 0===a.depth?5:a.depth;if(void 0===n&&(n=0),n>=d&&d>0&&"object"==typeof r)return jt(r)?"[Array]":"[Object]";var f=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=it.call(Array(e.indent+1)," ")}return{base:r,prev:it.call(Array(t+1),r)}}(a,n);if(void 0===i)i=[];else if(Ft(i,r)>=0)return"[Circular]";function p(t,r,o){if(r&&(i=at.call(i)).push(r),o){var s={depth:a.depth};return St(a,"quoteStyle")&&(s.quoteStyle=a.quoteStyle),e(t,s,n+1,i)}return e(t,a,n+1,i)}if("function"==typeof r&&!Pt(r)){var b=function(e){if(e.name)return e.name;var t=Ye.call(Ze.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(r),_=Ct(r,p);return"[Function"+(b?": "+b:" (anonymous)")+"]"+(_.length>0?" { "+it.call(_,", ")+" }":"")}if(Mt(r)){var v=dt?et.call(String(r),/^(Symbol\(.*\))_[^)]*$/,"$1"):ct.call(r);return"object"!=typeof r||dt?v:Dt(v)}if(function(e){if(!e||"object"!=typeof e)return!1;if("undefined"!=typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"==typeof e.nodeName&&"function"==typeof e.getAttribute}(r)){for(var y="<"+rt.call(String(r.nodeName)),h=r.attributes||[],g=0;g<h.length;g++)y+=" "+h[g].name+"="+Ot(wt(h[g].value),"double",a);return y+=">",r.childNodes&&r.childNodes.length&&(y+="..."),y+="</"+rt.call(String(r.nodeName))+">"}if(jt(r)){if(0===r.length)return"[]";var m=Ct(r,p);return f&&!function(e){for(var t=0;t<e.length;t++)if(Ft(e[t],"\n")>=0)return!1;return!0}(m)?"["+xt(m,f)+"]":"[ "+it.call(m,", ")+" ]"}if(function(e){return!("[object Error]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}(r)){var O=Ct(r,p);return"cause"in Error.prototype||!("cause"in r)||pt.call(r,"cause")?0===O.length?"["+String(r)+"]":"{ ["+String(r)+"] "+it.call(O,", ")+" }":"{ ["+String(r)+"] "+it.call(nt.call("[cause]: "+p(r.cause),O),", ")+" }"}if("object"==typeof r&&s){if(ht&&"function"==typeof r[ht]&&vt)return vt(r,{depth:d-n});if("symbol"!==s&&"function"==typeof r.inspect)return r.inspect()}if(function(e){if(!Be||!e||"object"!=typeof e)return!1;try{Be.call(e);try{Le.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(r)){var w=[];return Ne&&Ne.call(r,(function(e,t){w.push(p(t,r,!0)+" => "+p(e,r))})),Tt("Map",Be.call(r),w,f)}if(function(e){if(!Le||!e||"object"!=typeof e)return!1;try{Le.call(e);try{Be.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(r)){var j=[];return He&&He.call(r,(function(e){j.push(p(e,r))})),Tt("Set",Le.call(r),j,f)}if(function(e){if(!Je||!e||"object"!=typeof e)return!1;try{Je.call(e,Je);try{$e.call(e,$e)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(r))return Ut("WeakMap");if(function(e){if(!$e||!e||"object"!=typeof e)return!1;try{$e.call(e,$e);try{Je.call(e,Je)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(r))return Ut("WeakSet");if(function(e){if(!qe||!e||"object"!=typeof e)return!1;try{return qe.call(e),!0}catch(e){}return!1}(r))return Ut("WeakRef");if(function(e){return!("[object Number]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}(r))return Dt(p(Number(r)));if(function(e){if(!e||"object"!=typeof e||!lt)return!1;try{return lt.call(e),!0}catch(e){}return!1}(r))return Dt(p(lt.call(r)));if(function(e){return!("[object Boolean]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}(r))return Dt(Ge.call(r));if(function(e){return!("[object String]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}(r))return Dt(p(String(r)));if("undefined"!=typeof window&&r===window)return"{ [object Window] }";if("undefined"!=typeof globalThis&&r===globalThis||void 0!==t&&r===t)return"{ [object globalThis] }";if(!function(e){return!("[object Date]"!==zt(e)||ft&&"object"==typeof e&&ft in e)}(r)&&!Pt(r)){var P=Ct(r,p),M=bt?bt(r)===Object.prototype:r instanceof Object||r.constructor===Object,E=r instanceof Object?"":"null prototype",S=!M&&ft&&Object(r)===r&&ft in r?Qe.call(zt(r),8,-1):E?"Object":"",z=(M||"function"!=typeof r.constructor?"":r.constructor.name?r.constructor.name+" ":"")+(S||E?"["+it.call(nt.call([],S||[],E||[]),": ")+"] ":"");return 0===P.length?z+"{}":f?z+"{"+xt(P,f)+"}":z+"{ "+it.call(P,", ")+" }"}return String(r)},Lt=j,Ht=Nt("%WeakMap%",!0),Jt=Nt("%Map%",!0),$t=Xt("WeakMap.prototype.get",!0),qt=Xt("WeakMap.prototype.set",!0),Gt=Xt("WeakMap.prototype.has",!0),Wt=Xt("Map.prototype.get",!0),Zt=Xt("Map.prototype.set",!0),Yt=Xt("Map.prototype.has",!0),Qt=function(e,t){for(var r,o=e;null!==(r=o.next);o=r)if(r.key===t)return o.next=r.next,r.next=e.next,e.next=r,r},er=String.prototype.replace,tr=/%20/g,rr="RFC3986",or={default:rr,formatters:{RFC1738:function(e){return er.call(e,tr,"+")},RFC3986:function(e){return String(e)}},RFC1738:"RFC1738",RFC3986:rr},nr=or,ir=Object.prototype.hasOwnProperty,ar=Array.isArray,sr=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),lr=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},o=0;o<e.length;++o)void 0!==e[o]&&(r[o]=e[o]);return r},ur={arrayToObject:lr,assign:function(e,t){return Object.keys(t).reduce((function(e,r){return e[r]=t[r],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],r=[],o=0;o<t.length;++o)for(var n=t[o],i=n.obj[n.prop],a=Object.keys(i),s=0;s<a.length;++s){var l=a[s],u=i[l];"object"==typeof u&&null!==u&&-1===r.indexOf(u)&&(t.push({obj:i,prop:l}),r.push(u))}return function(e){for(;e.length>1;){var t=e.pop(),r=t.obj[t.prop];if(ar(r)){for(var o=[],n=0;n<r.length;++n)void 0!==r[n]&&o.push(r[n]);t.obj[t.prop]=o}}}(t),e},decode:function(e,t,r){var o=e.replace(/\+/g," ");if("iso-8859-1"===r)return o.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(o)}catch(e){return o}},encode:function(e,t,r,o,n){if(0===e.length)return e;var i=e;if("symbol"==typeof e?i=Symbol.prototype.toString.call(e):"string"!=typeof e&&(i=String(e)),"iso-8859-1"===r)return escape(i).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var a="",s=0;s<i.length;++s){var l=i.charCodeAt(s);45===l||46===l||95===l||126===l||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||n===nr.RFC1738&&(40===l||41===l)?a+=i.charAt(s):l<128?a+=sr[l]:l<2048?a+=sr[192|l>>6]+sr[128|63&l]:l<55296||l>=57344?a+=sr[224|l>>12]+sr[128|l>>6&63]+sr[128|63&l]:(s+=1,l=65536+((1023&l)<<10|1023&i.charCodeAt(s)),a+=sr[240|l>>18]+sr[128|l>>12&63]+sr[128|l>>6&63]+sr[128|63&l])}return a},isBuffer:function(e){return!(!e||"object"!=typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(ar(e)){for(var r=[],o=0;o<e.length;o+=1)r.push(t(e[o]));return r}return t(e)},merge:function e(t,r,o){if(!r)return t;if("object"!=typeof r){if(ar(t))t.push(r);else{if(!t||"object"!=typeof t)return[t,r];(o&&(o.plainObjects||o.allowPrototypes)||!ir.call(Object.prototype,r))&&(t[r]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(r);var n=t;return ar(t)&&!ar(r)&&(n=lr(t,o)),ar(t)&&ar(r)?(r.forEach((function(r,n){if(ir.call(t,n)){var i=t[n];i&&"object"==typeof i&&r&&"object"==typeof r?t[n]=e(i,r,o):t.push(r)}else t[n]=r})),t):Object.keys(r).reduce((function(t,n){var i=r[n];return ir.call(t,n)?t[n]=e(t[n],i,o):t[n]=i,t}),n)}},cr=function(){var e,t,r,o={assert:function(e){if(!o.has(e))throw new Lt("Side channel does not contain "+Kt(e))},get:function(o){if(Ht&&o&&("object"==typeof o||"function"==typeof o)){if(e)return $t(e,o)}else if(Jt){if(t)return Wt(t,o)}else if(r)return function(e,t){var r=Qt(e,t);return r&&r.value}(r,o)},has:function(o){if(Ht&&o&&("object"==typeof o||"function"==typeof o)){if(e)return Gt(e,o)}else if(Jt){if(t)return Yt(t,o)}else if(r)return function(e,t){return!!Qt(e,t)}(r,o);return!1},set:function(o,n){Ht&&o&&("object"==typeof o||"function"==typeof o)?(e||(e=new Ht),qt(e,o,n)):Jt?(t||(t=new Jt),Zt(t,o,n)):(r||(r={key:{},next:null}),function(e,t,r){var o=Qt(e,t);o?o.value=r:e.next={key:t,next:e.next,value:r}}(r,o,n))}};return o},dr=ur,fr=or,pr=Object.prototype.hasOwnProperty,br={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},_r=Array.isArray,vr=Array.prototype.push,yr=function(e,t){vr.apply(e,_r(t)?t:[t])},hr=Date.prototype.toISOString,gr=fr.default,mr={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:dr.encode,encodeValuesOnly:!1,format:gr,formatter:fr.formatters[gr],indices:!1,serializeDate:function(e){return hr.call(e)},skipNulls:!1,strictNullHandling:!1},Or={},wr=function e(t,r,o,n,i,a,s,l,u,c,d,f,p,b,_,v){for(var y=t,h=v,g=0,m=!1;void 0!==(h=h.get(Or))&&!m;){var O=h.get(t);if(g+=1,void 0!==O){if(O===g)throw new RangeError("Cyclic object value");m=!0}void 0===h.get(Or)&&(g=0)}if("function"==typeof l?y=l(r,y):y instanceof Date?y=d(y):"comma"===o&&_r(y)&&(y=dr.maybeMap(y,(function(e){return e instanceof Date?d(e):e}))),null===y){if(i)return s&&!b?s(r,mr.encoder,_,"key",f):r;y=""}if(function(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||"symbol"==typeof e||"bigint"==typeof e}(y)||dr.isBuffer(y))return s?[p(b?r:s(r,mr.encoder,_,"key",f))+"="+p(s(y,mr.encoder,_,"value",f))]:[p(r)+"="+p(String(y))];var w,j=[];if(void 0===y)return j;if("comma"===o&&_r(y))b&&s&&(y=dr.maybeMap(y,s)),w=[{value:y.length>0?y.join(",")||null:void 0}];else if(_r(l))w=l;else{var P=Object.keys(y);w=u?P.sort(u):P}for(var M=n&&_r(y)&&1===y.length?r+"[]":r,E=0;E<w.length;++E){var S=w[E],z="object"==typeof S&&void 0!==S.value?S.value:y[S];if(!a||null!==z){var F=_r(y)?"function"==typeof o?o(M,S):M:M+(c?"."+S:"["+S+"]");v.set(t,g);var k=cr();k.set(Or,v),yr(j,e(z,F,o,n,i,a,"comma"===o&&b&&_r(y)?null:s,l,u,c,d,f,p,b,_,k))}}return j},jr=ur,Pr=Object.prototype.hasOwnProperty,Mr=Array.isArray,Er={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:jr.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},Sr=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},zr=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},Fr=function(e,t,r,o){if(e){var n=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,i=/(\[[^[\]]*])/g,a=r.depth>0&&/(\[[^[\]]*])/.exec(n),s=a?n.slice(0,a.index):n,l=[];if(s){if(!r.plainObjects&&Pr.call(Object.prototype,s)&&!r.allowPrototypes)return;l.push(s)}for(var u=0;r.depth>0&&null!==(a=i.exec(n))&&u<r.depth;){if(u+=1,!r.plainObjects&&Pr.call(Object.prototype,a[1].slice(1,-1))&&!r.allowPrototypes)return;l.push(a[1])}return a&&l.push("["+n.slice(a.index)+"]"),function(e,t,r,o){for(var n=o?t:zr(t,r),i=e.length-1;i>=0;--i){var a,s=e[i];if("[]"===s&&r.parseArrays)a=[].concat(n);else{a=r.plainObjects?Object.create(null):{};var l="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,u=parseInt(l,10);r.parseArrays||""!==l?!isNaN(u)&&s!==l&&String(u)===l&&u>=0&&r.parseArrays&&u<=r.arrayLimit?(a=[])[u]=n:"__proto__"!==l&&(a[l]=n):a={0:n}}n=a}return n}(l,t,r,o)}},kr=function(e,t){var r,o=e,n=function(e){if(!e)return mr;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||mr.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=fr.default;if(void 0!==e.format){if(!pr.call(fr.formatters,e.format))throw new TypeError("Unknown format option provided.");r=e.format}var o=fr.formatters[r],n=mr.filter;return("function"==typeof e.filter||_r(e.filter))&&(n=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:mr.addQueryPrefix,allowDots:void 0===e.allowDots?mr.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:mr.charsetSentinel,delimiter:void 0===e.delimiter?mr.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:mr.encode,encoder:"function"==typeof e.encoder?e.encoder:mr.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:mr.encodeValuesOnly,filter:n,format:r,formatter:o,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:mr.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:mr.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:mr.strictNullHandling}}(t);"function"==typeof n.filter?o=(0,n.filter)("",o):_r(n.filter)&&(r=n.filter);var i,a=[];if("object"!=typeof o||null===o)return"";i=t&&t.arrayFormat in br?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var s=br[i];if(t&&"commaRoundTrip"in t&&"boolean"!=typeof t.commaRoundTrip)throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var l="comma"===s&&t&&t.commaRoundTrip;r||(r=Object.keys(o)),n.sort&&r.sort(n.sort);for(var u=cr(),c=0;c<r.length;++c){var d=r[c];n.skipNulls&&null===o[d]||yr(a,wr(o[d],d,s,l,n.strictNullHandling,n.skipNulls,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,u))}var f=a.join(n.delimiter),p=!0===n.addQueryPrefix?"?":"";return n.charsetSentinel&&("iso-8859-1"===n.charset?p+="utf8=%26%2310003%3B&":p+="utf8=%E2%9C%93&"),f.length>0?p+f:""},Rr=function(e,t){var r=function(e){if(!e)return Er;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?Er.charset:e.charset;return{allowDots:void 0===e.allowDots?Er.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:Er.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:Er.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:Er.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:Er.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:Er.comma,decoder:"function"==typeof e.decoder?e.decoder:Er.decoder,delimiter:"string"==typeof e.delimiter||jr.isRegExp(e.delimiter)?e.delimiter:Er.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:Er.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:Er.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:Er.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:Er.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:Er.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var o="string"==typeof e?function(e,t){var r,o={__proto__:null},n=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,i=t.parameterLimit===1/0?void 0:t.parameterLimit,a=n.split(t.delimiter,i),s=-1,l=t.charset;if(t.charsetSentinel)for(r=0;r<a.length;++r)0===a[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===a[r]?l="utf-8":"utf8=%26%2310003%3B"===a[r]&&(l="iso-8859-1"),s=r,r=a.length);for(r=0;r<a.length;++r)if(r!==s){var u,c,d=a[r],f=d.indexOf("]="),p=-1===f?d.indexOf("="):f+1;-1===p?(u=t.decoder(d,Er.decoder,l,"key"),c=t.strictNullHandling?null:""):(u=t.decoder(d.slice(0,p),Er.decoder,l,"key"),c=jr.maybeMap(zr(d.slice(p+1),t),(function(e){return t.decoder(e,Er.decoder,l,"value")}))),c&&t.interpretNumericEntities&&"iso-8859-1"===l&&(c=Sr(c)),d.indexOf("[]=")>-1&&(c=Mr(c)?[c]:c),Pr.call(o,u)?o[u]=jr.combine(o[u],c):o[u]=c}return o}(e,r):e,n=r.plainObjects?Object.create(null):{},i=Object.keys(o),a=0;a<i.length;++a){var s=i[a],l=Fr(s,o[s],r,"string"==typeof e);n=jr.merge(n,l,r)}return!0===r.allowSparse?n:jr.compact(n)},Dr={formats:or,parse:Rr,stringify:kr},Ur={},Tr={};Object.defineProperty(Tr,"__esModule",{value:!0}),Tr.RUNTIME=void 0;const xr="undefined"!=typeof window&&void 0!==window.document,Cr="object"==typeof self&&"function"==typeof(null===self||void 0===self?void 0:self.importScripts)&&("DedicatedWorkerGlobalScope"===(null===(It=self.constructor)||void 0===It?void 0:It.name)||"ServiceWorkerGlobalScope"===(null===(At=self.constructor)||void 0===At?void 0:At.name)||"SharedWorkerGlobalScope"===(null===(Vt=self.constructor)||void 0===Vt?void 0:Vt.name)),Ir="undefined"!=typeof Deno&&void 0!==Deno.version&&void 0!==Deno.version.deno,Ar="undefined"!=typeof Bun&&void 0!==Bun.version,Vr="undefined"!=typeof process&&Boolean(process.version)&&Boolean(null===(Bt=process.versions)||void 0===Bt?void 0:Bt.node)&&!Ir&&!Ar,Br="undefined"!=typeof navigator&&"ReactNative"===(null===navigator||void 0===navigator?void 0:navigator.product);Tr.RUNTIME=function(){if(xr)return{type:"browser",version:window.navigator.userAgent};if(Cr)return{type:"web-worker"};if(Ir)return{type:"deno",version:Deno.version.deno};if(Ar)return{type:"bun",version:Bun.version};if(Vr)return{type:"node",version:process.versions.node};if(Br)return{type:"react-native"};return{type:"unknown"}}(),function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.RUNTIME=void 0;var t=Tr;Object.defineProperty(e,"RUNTIME",{enumerable:!0,get:function(){return t.RUNTIME}})}(Ur);var Nr,Xr={exports:{}};function Kr(){return Nr||(Nr=1,function(e,r){var o=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==t)return t;throw new Error("unable to locate global object")}();e.exports=r=o.fetch,o.fetch&&(r.default=o.fetch.bind(o)),r.Headers=o.Headers,r.Request=o.Request,r.Response=o.Response}(Xr,Xr.exports)),Xr.exports}var Lr=t&&t.__awaiter||function(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{l(o.next(e))}catch(e){i(e)}}function s(e){try{l(o.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((o=o.apply(e,t||[])).next())}))},Hr=t&&t.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(v,"__esModule",{value:!0}),v.fetcher=void 0;const Jr=Hr(y),$r=Hr(Dr),qr=Ur;v.fetcher=function(e){var t,r;return Lr(this,void 0,void 0,(function*(){const o={};if(void 0!==e.body&&null!=e.contentType&&(o["Content-Type"]=e.contentType),null!=e.headers)for(const[t,r]of Object.entries(e.headers))null!=r&&(o[t]=r);const n=Object.keys(null!==(t=e.queryParameters)&&void 0!==t?t:{}).length>0?`${e.url}?${$r.default.stringify(e.queryParameters,{arrayFormat:"repeat"})}`:e.url;let i;i=e.body instanceof Jr.default||e.body instanceof Uint8Array?e.body:JSON.stringify(e.body);const a="node"===qr.RUNTIME.type?Kr().default:"function"==typeof fetch?fetch:Kr().default,s=()=>Lr(this,void 0,void 0,(function*(){const t=new AbortController;let r;null!=e.timeoutMs&&(r=setTimeout((()=>t.abort()),e.timeoutMs));const s=yield a(n,{method:e.method,headers:o,body:i,signal:t.signal,credentials:e.withCredentials?"include":void 0});return null!=r&&clearTimeout(r),s}));try{let t,o=yield s();for(let t=0;t<(null!==(r=e.maxRetries)&&void 0!==r?r:2)&&(408===o.status||409===o.status||429===o.status||o.status>=500);++t){const e=Math.min(1*Math.pow(t,2),60);yield new Promise((t=>setTimeout(t,e))),o=yield s()}if(null!=o.body&&"blob"===e.responseType)t=yield o.blob();else if(null!=o.body&&"streaming"===e.responseType)t=o.body;else{const e=yield o.text();if(e.length>0)try{t=JSON.parse(e)}catch(t){return{ok:!1,error:{reason:"non-json",statusCode:o.status,rawBody:e}}}}return o.status>=200&&o.status<400?{ok:!0,body:t,headers:o.headers}:{ok:!1,error:{reason:"status-code",statusCode:o.status,body:t}}}catch(e){return e instanceof Error&&"AbortError"===e.name?{ok:!1,error:{reason:"timeout"}}:e instanceof Error?{ok:!1,error:{reason:"unknown",errorMessage:e.message}}:{ok:!1,error:{reason:"unknown",errorMessage:JSON.stringify(e)}}}}))};var Gr={};Object.defineProperty(Gr,"__esModule",{value:!0}),Gr.getHeader=void 0,Gr.getHeader=function(e,t){for(const[r,o]of Object.entries(e))if(r.toLowerCase()===t.toLowerCase())return o};var Wr={},Zr=t&&t.__awaiter||function(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{l(o.next(e))}catch(e){i(e)}}function s(e){try{l(o.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((o=o.apply(e,t||[])).next())}))};Object.defineProperty(Wr,"__esModule",{value:!0}),Wr.Supplier=void 0,Wr.Supplier={get:e=>Zr(void 0,void 0,void 0,(function*(){return"function"==typeof e?e():e}))},function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Supplier=e.getHeader=e.fetcher=void 0;var t=v;Object.defineProperty(e,"fetcher",{enumerable:!0,get:function(){return t.fetcher}});var r=Gr;Object.defineProperty(e,"getHeader",{enumerable:!0,get:function(){return r.getHeader}});var o=Wr;Object.defineProperty(e,"Supplier",{enumerable:!0,get:function(){return o.Supplier}})}(_);var Yr={},Qr={},eo={exports:{}};!function(e,t){"undefined"!=typeof self?self:"undefined"!=typeof window&&window,e.exports=function(){var e="3.7.2",t=e,r="function"==typeof atob,o="function"==typeof btoa,n="function"==typeof Buffer,i="function"==typeof TextDecoder?new TextDecoder:void 0,a="function"==typeof TextEncoder?new TextEncoder:void 0,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",l=Array.prototype.slice.call(s),u=function(e){var t={};return e.forEach((function(e,r){return t[e]=r})),t}(l),c=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,d=String.fromCharCode.bind(String),f="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):function(e,t){return void 0===t&&(t=function(e){return e}),new Uint8Array(Array.prototype.slice.call(e,0).map(t))},p=function(e){return e.replace(/=/g,"").replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"}))},b=function(e){return e.replace(/[^A-Za-z0-9\+\/]/g,"")},_=function(e){for(var t,r,o,n,i="",a=e.length%3,s=0;s<e.length;){if((r=e.charCodeAt(s++))>255||(o=e.charCodeAt(s++))>255||(n=e.charCodeAt(s++))>255)throw new TypeError("invalid character found");i+=l[(t=r<<16|o<<8|n)>>18&63]+l[t>>12&63]+l[t>>6&63]+l[63&t]}return a?i.slice(0,a-3)+"===".substring(a):i},v=o?function(e){return btoa(e)}:n?function(e){return Buffer.from(e,"binary").toString("base64")}:_,y=n?function(e){return Buffer.from(e).toString("base64")}:function(e){for(var t=4096,r=[],o=0,n=e.length;o<n;o+=t)r.push(d.apply(null,e.subarray(o,o+t)));return v(r.join(""))},h=function(e,t){return void 0===t&&(t=!1),t?p(y(e)):y(e)},g=function(e){if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?d(192|t>>>6)+d(128|63&t):d(224|t>>>12&15)+d(128|t>>>6&63)+d(128|63&t);var t=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return d(240|t>>>18&7)+d(128|t>>>12&63)+d(128|t>>>6&63)+d(128|63&t)},m=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,O=function(e){return e.replace(m,g)},w=n?function(e){return Buffer.from(e,"utf8").toString("base64")}:a?function(e){return y(a.encode(e))}:function(e){return v(O(e))},j=function(e,t){return void 0===t&&(t=!1),t?p(w(e)):w(e)},P=function(e){return j(e,!0)},M=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,E=function(e){switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return d(55296+(t>>>10))+d(56320+(1023&t));case 3:return d((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return d((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},S=function(e){return e.replace(M,E)},z=function(e){if(e=e.replace(/\s+/g,""),!c.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(3&e.length));for(var t,r,o,n="",i=0;i<e.length;)t=u[e.charAt(i++)]<<18|u[e.charAt(i++)]<<12|(r=u[e.charAt(i++)])<<6|(o=u[e.charAt(i++)]),n+=64===r?d(t>>16&255):64===o?d(t>>16&255,t>>8&255):d(t>>16&255,t>>8&255,255&t);return n},F=r?function(e){return atob(b(e))}:n?function(e){return Buffer.from(e,"base64").toString("binary")}:z,k=n?function(e){return f(Buffer.from(e,"base64"))}:function(e){return f(F(e),(function(e){return e.charCodeAt(0)}))},R=function(e){return k(U(e))},D=n?function(e){return Buffer.from(e,"base64").toString("utf8")}:i?function(e){return i.decode(k(e))}:function(e){return S(F(e))},U=function(e){return b(e.replace(/[-_]/g,(function(e){return"-"==e?"+":"/"})))},T=function(e){return D(U(e))},x=function(e){return{value:e,enumerable:!1,writable:!0,configurable:!0}},C=function(){var e=function(e,t){return Object.defineProperty(String.prototype,e,x(t))};e("fromBase64",(function(){return T(this)})),e("toBase64",(function(e){return j(this,e)})),e("toBase64URI",(function(){return j(this,!0)})),e("toBase64URL",(function(){return j(this,!0)})),e("toUint8Array",(function(){return R(this)}))},I=function(){var e=function(e,t){return Object.defineProperty(Uint8Array.prototype,e,x(t))};e("toBase64",(function(e){return h(this,e)})),e("toBase64URI",(function(){return h(this,!0)})),e("toBase64URL",(function(){return h(this,!0)}))},A=function(){C(),I()},V={version:e,VERSION:t,atob:F,atobPolyfill:z,btoa:v,btoaPolyfill:_,fromBase64:T,toBase64:j,encode:j,encodeURI:P,encodeURL:P,utob:O,btou:S,decode:T,isValid:function(e){if("string"!=typeof e)return!1;var t=e.replace(/\s+/g,"").replace(/={0,2}$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(t)||!/[^\s0-9a-zA-Z\-_]/.test(t)},fromUint8Array:h,toUint8Array:R,extendString:C,extendUint8Array:I,extendBuiltins:A,Base64:{}};return Object.keys(V).forEach((function(e){return V.Base64[e]=V[e]})),V}()}(eo);var to=eo.exports;Object.defineProperty(Qr,"__esModule",{value:!0}),Qr.BasicAuth=void 0;const ro=to,oo=/^Basic /i;Qr.BasicAuth={toAuthorizationHeader:e=>{if(null==e)return;return`Basic ${ro.Base64.encode(`${e.username}:${e.password}`)}`},fromAuthorizationHeader:e=>{const t=e.replace(oo,""),r=ro.Base64.decode(t),[o,n]=r.split(":",2);if(null==o||null==n)throw new Error("Invalid basic auth");return{username:o,password:n}}};var no={};Object.defineProperty(no,"__esModule",{value:!0}),no.BearerToken=void 0;const io=/^Bearer /i;no.BearerToken={toAuthorizationHeader:e=>{if(null!=e)return`Bearer ${e}`},fromAuthorizationHeader:e=>e.replace(io,"").trim()},function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BearerToken=e.BasicAuth=void 0;var t=Qr;Object.defineProperty(e,"BasicAuth",{enumerable:!0,get:function(){return t.BasicAuth}});var r=no;Object.defineProperty(e,"BearerToken",{enumerable:!0,get:function(){return r.BearerToken}})}(Yr);var ao={},so={},lo={},uo={},co={};Object.defineProperty(co,"__esModule",{value:!0}),co.SchemaType=void 0,co.SchemaType={DATE:"date",ENUM:"enum",LIST:"list",STRING_LITERAL:"stringLiteral",BOOLEAN_LITERAL:"booleanLiteral",OBJECT:"object",ANY:"any",BOOLEAN:"boolean",NUMBER:"number",STRING:"string",UNKNOWN:"unknown",RECORD:"record",SET:"set",UNION:"union",UNDISCRIMINATED_UNION:"undiscriminatedUnion",OPTIONAL:"optional"};var fo={};Object.defineProperty(fo,"__esModule",{value:!0}),fo.getErrorMessageForIncorrectType=void 0,fo.getErrorMessageForIncorrectType=function(e,t){return`Expected ${t}. Received ${function(e){if(Array.isArray(e))return"list";if(null===e)return"null";switch(typeof e){case"string":return`"${e}"`;case"number":case"boolean":case"undefined":return`${e}`}return typeof e}(e)}.`};var po={},bo=t&&t.__awaiter||function(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{l(o.next(e))}catch(e){i(e)}}function s(e){try{l(o.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,s)}l((o=o.apply(e,t||[])).next())}))};function _o(e){return(t,r)=>bo(this,void 0,void 0,(function*(){const o=yield e(t,r),{skipValidation:n=!1}=null!=r?r:{};return!o.ok&&n?(console.warn(["Failed to validate.",...o.errors.map((e=>" - "+(e.path.length>0?`${e.path.join(".")}: ${e.message}`:e.message)))].join("\n")),{ok:!0,value:t}):o}))}Object.defineProperty(po,"__esModule",{value:!0}),po.maybeSkipValidation=void 0,po.maybeSkipValidation=function(e){return Object.assign(Object.assign({},e),{json:_o(e.json),parse:_o(e.parse)})};var vo={},yo={},ho={},go={};Object.defineProperty(go,"__esModule",{value:!0}),go.stringifyValidationError=void 0,go.stringifyValidationError=function(e){return 0===e.path.length?e.message:`${e.path.join(" -> ")}: ${e.message}`},Object.defineProperty(ho,"__esModule",{value:!0}),ho.JsonError=void 0;const mo=go;class Oo extends Error{constructor(e){super(e.map(mo.stringifyValidationError).join("; ")),this.e