1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8660],{48660:(e,t,r)=>{let a;r.d(t,{K:()=>ax});var n,i,s,o,l,d,u={};r.r(u),r.d(u,{hasBrowserEnv:()=>eX,hasStandardBrowserEnv:()=>e0,hasStandardBrowserWebWorkerEnv:()=>e1,navigator:()=>eY,origin:()=>e4});class c extends Error{constructor(e,t){super(e),this.name="ParseError",this.type=t.type,this.field=t.field,this.value=t.value,this.line=t.line}}function h(e){}function p(e,t,r){return 100===r&&97===e.charCodeAt(t+1)&&116===e.charCodeAt(t+2)&&97===e.charCodeAt(t+3)&&58===e.charCodeAt(t+4)}function f(e,t,r){return 101===r&&118===e.charCodeAt(t+1)&&101===e.charCodeAt(t+2)&&110===e.charCodeAt(t+3)&&116===e.charCodeAt(t+4)&&58===e.charCodeAt(t+5)}class m extends Event{constructor(e,t){var r,a;super(e),this.code=null!=(r=null==t?void 0:t.code)?r:void 0,this.message=null!=(a=null==t?void 0:t.message)?a:void 0}[Symbol.for("nodejs.util.inspect.custom")](e,t,r){return r(y(this),t)}[Symbol.for("Deno.customInspect")](e,t){return e(y(this),t)}}function y(e){return{type:e.type,message:e.message,code:e.code,defaultPrevented:e.defaultPrevented,cancelable:e.cancelable,timeStamp:e.timeStamp}}var g,v,_,b,w,k,x,E,O,R,S,T,A,C,N,j,P,L,Z,I,U,$,F,D=e=>{throw TypeError(e)},M=(e,t,r)=>t.has(e)||D("Cannot "+r),q=(e,t,r)=>(M(e,t,"read from private field"),r?r.call(e):t.get(e)),B=(e,t,r)=>t.has(e)?D("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),z=(e,t,r,a)=>(M(e,t,"write to private field"),t.set(e,r),r),W=(e,t,r)=>(M(e,t,"access private method"),r);class V extends EventTarget{constructor(e,t){var r,a;super(),B(this,C),this.CONNECTING=0,this.OPEN=1,this.CLOSED=2,B(this,g),B(this,v),B(this,_),B(this,b),B(this,w),B(this,k),B(this,x),B(this,E,null),B(this,O),B(this,R),B(this,S,null),B(this,T,null),B(this,A,null),B(this,j,async e=>{var t;q(this,R).reset();let{body:r,redirected:a,status:n,headers:i}=e;if(204===n){W(this,C,U).call(this,"Server sent HTTP 204, not reconnecting",204),this.close();return}if(a?z(this,_,new URL(e.url)):z(this,_,void 0),200!==n)return void W(this,C,U).call(this,`Non-200 status code (${n})`,n);if(!(i.get("content-type")||"").startsWith("text/event-stream"))return void W(this,C,U).call(this,'Invalid content type, expected "text/event-stream"',n);if(q(this,g)===this.CLOSED)return;z(this,g,this.OPEN);let s=new Event("open");if(null==(t=q(this,A))||t.call(this,s),this.dispatchEvent(s),"object"!=typeof r||!r||!("getReader"in r)){W(this,C,U).call(this,"Invalid response body, expected a web ReadableStream",n),this.close();return}let o=new TextDecoder,l=r.getReader(),d=!0;do{let{done:e,value:t}=await l.read();t&&q(this,R).feed(o.decode(t,{stream:!e})),e&&(d=!1,q(this,R).reset(),W(this,C,$).call(this))}while(d)}),B(this,P,e=>{z(this,O,void 0),"AbortError"!==e.name&&"aborted"!==e.type&&W(this,C,$).call(this,function e(t){return t instanceof Error?"errors"in t&&Array.isArray(t.errors)?t.errors.map(e).join(", "):"cause"in t&&t.cause instanceof Error?`${t}: ${e(t.cause)}`:t.message:`${t}`}(e))}),B(this,Z,e=>{"string"==typeof e.id&&z(this,E,e.id);let t=new MessageEvent(e.event||"message",{data:e.data,origin:q(this,_)?q(this,_).origin:q(this,v).origin,lastEventId:e.id||""});q(this,T)&&(!e.event||"message"===e.event)&&q(this,T).call(this,t),this.dispatchEvent(t)}),B(this,I,e=>{z(this,k,e)}),B(this,F,()=>{z(this,x,void 0),q(this,g)===this.CONNECTING&&W(this,C,N).call(this)});try{if(e instanceof URL)z(this,v,e);else if("string"==typeof e)z(this,v,new URL(e,function(){let e="document"in globalThis?globalThis.document:void 0;return e&&"object"==typeof e&&"baseURI"in e&&"string"==typeof e.baseURI?e.baseURI:void 0}()));else throw Error("Invalid URL")}catch{throw function(e){let t=globalThis.DOMException;return"function"==typeof t?new t(e,"SyntaxError"):SyntaxError(e)}("An invalid or illegal string was specified")}z(this,R,function(e){if("function"==typeof e)throw TypeError("`callbacks` must be an object, got a function instead. Did you mean `{onEvent: fn}`?");let{onEvent:t=h,onError:r=h,onRetry:a=h,onComment:n}=e,i=[],s=!0,o,l="",d=0,u;function m(e){let r=0;if(-1===e.indexOf("\r")){let a=e.indexOf(` 2`,r);for(;-1!==a;){if(r===a){d>0&&t({id:o,event:u,data:l}),o=void 0,l="",d=0,u=void 0,r=a+1,a=e.indexOf(` 3`,r);continue}let n=e.charCodeAt(r);if(p(e,r,n)){let n=32===e.charCodeAt(r+5)?r+6:r+5,i=e.slice(n,a);if(0===d&&10===e.charCodeAt(a+1)){t({id:o,event:u,data:i}),o=void 0,l="",u=void 0,r=a+2,a=e.indexOf(` 4`,r);continue}l=0===d?i:`${l} 5${i}`,d++}else f(e,r,n)?u=e.slice(32===e.charCodeAt(r+6)?r+7:r+6,a)||void 0:y(e,r,a);r=a+1,a=e.indexOf(` 6`,r)}return e.slice(r)}for(;r<e.length;){let t=e.indexOf("\r",r),a=e.indexOf(` 7`,r),n=-1;
7if(-1!==t&&-1!==a?n=t<a?t:a:-1!==t?n=t===e.length-1?-1:t:-1!==a&&(n=a),-1===n)break;y(e,r,n),r=n+1,13===e.charCodeAt(r-1)&&10===e.charCodeAt(r)&&r++}return e.slice(r)}function y(e,r,a){if(r===a)return void(d>0&&t({id:o,event:u,data:l}),o=void 0,l="",d=0,u=void 0);let i=e.charCodeAt(r);if(p(e,r,i)){let t=32===e.charCodeAt(r+5)?r+6:r+5,n=e.slice(t,a);l=0===d?n:`${l} 8${n}`,d++;return}if(f(e,r,i)){u=e.slice(32===e.charCodeAt(r+6)?r+7:r+6,a)||void 0;return}if(105===i&&100===e.charCodeAt(r+1)&&58===e.charCodeAt(r+2)){let t=e.slice(32===e.charCodeAt(r+3)?r+4:r+3,a);o=t.includes("\0")?void 0:t;return}if(58===i){n&&n(e.slice(r,a).slice(32===e.charCodeAt(r+1)?2:1));return}let s=e.slice(r,a),c=s.indexOf(":");if(-1===c)return void g(s,"",s);let h=s.slice(0,c),m=32===s.charCodeAt(c+1)?2:1;g(h,s.slice(c+m),s)}function g(e,t,n){switch(e){case"event":u=t||void 0;break;case"data":l=0===d?t:`${l} 9${t}`,d++;break;case"id":o=t.includes("\0")?void 0:t;break;case"retry":/^\d+$/.test(t)?a(parseInt(t,10)):r(new c(`Invalid \`retry\` value: "${t}"`,{type:"invalid-retry",value:t,line:n}));break;default:r(new c(`Unknown field "${e.length>20?`${e.slice(0,20)}\u2026`:e}"`,{type:"unknown-field",field:e,value:t,line:n}))}}return{feed:function(e){if(s&&(s=!1,239===e.charCodeAt(0)&&187===e.charCodeAt(1)&&191===e.charCodeAt(2)&&(e=e.slice(3))),0===i.length){let t=m(e);""!==t&&i.push(t);return}if(-1===e.indexOf(` 10`)&&-1===e.indexOf("\r"))return void i.push(e);i.push(e);let t=i.join("");i.length=0;let r=m(t);""!==r&&i.push(r)},reset:function(e={}){if(e.consume&&i.length>0){let e=i.join("");y(e,0,e.length)}s=!0,o=void 0,l="",d=0,u=void 0,i.length=0}}}({onEvent:q(this,Z),onRetry:q(this,I)})),z(this,g,this.CONNECTING),z(this,k,3e3),z(this,w,null!=(r=null==t?void 0:t.fetch)?r:globalThis.fetch),z(this,b,null!=(a=null==t?void 0:t.withCredentials)&&a),W(this,C,N).call(this)}get readyState(){return q(this,g)}get url(){return q(this,v).href}get withCredentials(){return q(this,b)}get onerror(){return q(this,S)}set onerror(e){z(this,S,e)}get onmessage(){return q(this,T)}set onmessage(e){z(this,T,e)}get onopen(){return q(this,A)}set onopen(e){z(this,A,e)}addEventListener(e,t,r){super.addEventListener(e,t,r)}removeEventListener(e,t,r){super.removeEventListener(e,t,r)}close(){q(this,x)&&clearTimeout(q(this,x)),q(this,g)!==this.CLOSED&&(q(this,O)&&q(this,O).abort(),z(this,g,this.CLOSED),z(this,O,void 0))}}function K(e){let t={};for(let r of Object.keys(e)){let a=r.replaceAll(/[A-Z]/g,e=>`_${e.toLowerCase()}`),n=e[r];t[a]=n}return t}function H(e,t){return function(){return e.apply(t,arguments)}}g=new WeakMap,v=new WeakMap,_=new WeakMap,b=new WeakMap,w=new WeakMap,k=new WeakMap,x=new WeakMap,E=new WeakMap,O=new WeakMap,R=new WeakMap,S=new WeakMap,T=new WeakMap,A=new WeakMap,C=new WeakSet,N=function(){z(this,g,this.CONNECTING),z(this,O,new AbortController),q(this,w)(q(this,v),W(this,C,L).call(this)).then(q(this,j)).catch(q(this,P))},j=new WeakMap,P=new WeakMap,L=function(){var e;let t={mode:"cors",redirect:"follow",headers:{Accept:"text/event-stream",...q(this,E)?{"Last-Event-ID":q(this,E)}:void 0},cache:"no-store",signal:null==(e=q(this,O))?void 0:e.signal};return"window"in globalThis&&(t.credentials=this.withCredentials?"include":"same-origin"),t},Z=new WeakMap,I=new WeakMap,U=function(e,t){var r;q(this,g)!==this.CLOSED&&z(this,g,this.CLOSED);let a=new m("error",{code:t,message:e});null==(r=q(this,S))||r.call(this,a),this.dispatchEvent(a)},$=function(e,t){var r;if(q(this,g)===this.CLOSED)return;z(this,g,this.CONNECTING);let a=new m("error",{code:t,message:e});null==(r=q(this,S))||r.call(this,a),this.dispatchEvent(a),z(this,x,setTimeout(q(this,F),q(this,k)))},F=new WeakMap,V.CONNECTING=0,V.OPEN=1,V.CLOSED=2;var Q=r(87358);let{toString:J}=Object.prototype,{getPrototypeOf:G}=Object,{iterator:X,toStringTag:Y}=Symbol,ee=(e=>t=>{let r=J.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),et=e=>(e=e.toLowerCase(),t=>ee(t)===e),er=e=>t=>typeof t===e,{isArray:ea}=Array,en=er("undefined");function ei(e){return null!==e&&!en(e)&&null!==e.constructor&&!en(e.constructor)&&el(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}let es=et("ArrayBuffer"),eo=er("string"),el=er("function"),ed=er("number"),eu=e=>null!==e&&"object"==typeof e,ec=e=>{if("object"!==ee(e))return!1;let t=G(e);return(null===t||t===Object.prototype||null===Object.getPrototypeOf(t))&&!(Y in e)&&!(X
10in e)},eh=et("Date"),ep=et("File"),ef=et("Blob"),em=et("FileList"),ey=et("URLSearchParams"),[eg,ev,e_,eb]=["ReadableStream","Request","Response","Headers"].map(et);function ew(e,t,{allOwnKeys:r=!1}={}){let a,n;if(null!=e)if("object"!=typeof e&&(e=[e]),ea(e))for(a=0,n=e.length;a<n;a++)t.call(null,e[a],a,e);else{let n;if(ei(e))return;let i=r?Object.getOwnPropertyNames(e):Object.keys(e),s=i.length;for(a=0;a<s;a++)n=i[a],t.call(null,e[n],n,e)}}function ek(e,t){let r;if(ei(e))return null;t=t.toLowerCase();let a=Object.keys(e),n=a.length;for(;n-- >0;)if(t===(r=a[n]).toLowerCase())return r;return null}let ex="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,eE=e=>!en(e)&&e!==ex,eO=(e=>t=>e&&t instanceof e)("undefined"!=typeof Uint8Array&&G(Uint8Array)),eR=et("HTMLFormElement"),eS=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),eT=et("RegExp"),eA=(e,t)=>{let r=Object.getOwnPropertyDescriptors(e),a={};ew(r,(r,n)=>{let i;!1!==(i=t(r,n,e))&&(a[n]=i||r)}),Object.defineProperties(e,a)},eC=et("AsyncFunction"),eN=(n="function"==typeof setImmediate,i=el(ex.postMessage),n?setImmediate:i?((e,t)=>(ex.addEventListener("message",({source:r,data:a})=>{r===ex&&a===e&&t.length&&t.shift()()},!1),r=>{t.push(r),ex.postMessage(e,"*")}))(`axios@${Math.random()}`,[]):e=>setTimeout(e)),ej="undefined"!=typeof queueMicrotask?queueMicrotask.bind(ex):void 0!==Q&&Q.nextTick||eN,eP={isArray:ea,isArrayBuffer:es,isBuffer:ei,isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||el(e.append)&&("formdata"===(t=ee(e))||"object"===t&&el(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&es(e.buffer)},isString:eo,isNumber:ed,isBoolean:e=>!0===e||!1===e,isObject:eu,isPlainObject:ec,isEmptyObject:e=>{if(!eu(e)||ei(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(e){return!1}},isReadableStream:eg,isRequest:ev,isResponse:e_,isHeaders:eb,isUndefined:en,isDate:eh,isFile:ep,isBlob:ef,isRegExp:eT,isFunction:el,isStream:e=>eu(e)&&el(e.pipe),isURLSearchParams:ey,isTypedArray:eO,isFileList:em,forEach:ew,merge:function e(){let{caseless:t,skipUndefined:r}=eE(this)&&this||{},a={},n=(n,i)=>{if("__proto__"===i||"constructor"===i||"prototype"===i)return;let s=t&&ek(a,i)||i;ec(a[s])&&ec(n)?a[s]=e(a[s],n):ec(n)?a[s]=e({},n):ea(n)?a[s]=n.slice():r&&en(n)||(a[s]=n)};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&ew(arguments[e],n);return a},extend:(e,t,r,{allOwnKeys:a}={})=>(ew(t,(t,a)=>{r&&el(t)?Object.defineProperty(e,a,{value:H(t,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:a}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,r,a)=>{e.prototype=Object.create(t.prototype,a),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},toFlatObject:(e,t,r,a)=>{let n,i,s,o={};if(t=t||{},null==e)return t;do{for(i=(n=Object.getOwnPropertyNames(e)).length;i-- >0;)s=n[i],(!a||a(s,e,t))&&!o[s]&&(t[s]=e[s],o[s]=!0);e=!1!==r&&G(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},kindOf:ee,kindOfTest:et,endsWith:(e,t,r)=>{e=String(e),(void 0===r||r>e.length)&&(r=e.length),r-=t.length;let a=e.indexOf(t,r);return -1!==a&&a===r},toArray:e=>{if(!e)return null;if(ea(e))return e;let t=e.length;if(!ed(t))return null;let r=Array(t);for(;t-- >0;)r[t]=e[t];return r},forEachEntry:(e,t)=>{let r,a=(e&&e[X]).call(e);for(;(r=a.next())&&!r.done;){let a=r.value;t.call(e,a[0],a[1])}},matchAll:(e,t)=>{let r,a=[];for(;null!==(r=e.exec(t));)a.push(r);return a},isHTMLForm:eR,hasOwnProperty:eS,hasOwnProp:eS,reduceDescriptors:eA,freezeMethods:e=>{eA(e,(t,r)=>{if(el(e)&&-1!==["arguments","caller","callee"].indexOf(r))return!1;if(el(e[r])){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},toObjectSet:(e,t)=>{let r={};
10return(ea(e)?e:String(e).split(t)).forEach(e=>{r[e]=!0}),r},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,r){return t.toUpperCase()+r}),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e*=1)?e:t,findKey:ek,global:ex,isContextDefined:eE,isSpecCompliantForm:function(e){return!!(e&&el(e.append)&&"FormData"===e[Y]&&e[X])},toJSONObject:e=>{let t=Array(10),r=(e,a)=>{if(eu(e)){if(t.indexOf(e)>=0)return;if(ei(e))return e;if(!("toJSON"in e)){t[a]=e;let n=ea(e)?[]:{};return ew(e,(e,t)=>{let i=r(e,a+1);en(i)||(n[t]=i)}),t[a]=void 0,n}}return e};return r(e,0)},isAsyncFn:eC,isThenable:e=>e&&(eu(e)||el(e))&&el(e.then)&&el(e.catch),setImmediate:eN,asap:ej,isIterable:e=>null!=e&&el(e[X])};class eL extends Error{static from(e,t,r,a,n,i){let s=new eL(e.message,t||e.code,r,a,n);return s.cause=e,s.name=e.name,i&&Object.assign(s,i),s}constructor(e,t,r,a,n){super(e),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),a&&(this.request=a),n&&(this.response=n,this.status=n.status)}toJSON(){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:eP.toJSONObject(this.config),code:this.code,status:this.status}}}eL.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",eL.ERR_BAD_OPTION="ERR_BAD_OPTION",eL.ECONNABORTED="ECONNABORTED",eL.ETIMEDOUT="ETIMEDOUT",eL.ERR_NETWORK="ERR_NETWORK",eL.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",eL.ERR_DEPRECATED="ERR_DEPRECATED",eL.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",eL.ERR_BAD_REQUEST="ERR_BAD_REQUEST",eL.ERR_CANCELED="ERR_CANCELED",eL.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",eL.ERR_INVALID_URL="ERR_INVALID_URL";let eZ=eL;var eI=r(81029).Buffer;function eU(e){return eP.isPlainObject(e)||eP.isArray(e)}function e$(e){return eP.endsWith(e,"[]")?e.slice(0,-2):e}function eF(e,t,r){return e?e.concat(t).map(function(e,t){return e=e$(e),!r&&t?"["+e+"]":e}).join(r?".":""):t}let eD=eP.toFlatObject(eP,{},null,function(e){return/^is[A-Z]/.test(e)}),eM=function(e,t,r){if(!eP.isObject(e))throw TypeError("target must be an object");t=t||new FormData;let a=(r=eP.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!eP.isUndefined(t[e])})).metaTokens,n=r.visitor||d,i=r.dots,s=r.indexes,o=(r.Blob||"undefined"!=typeof Blob&&Blob)&&eP.isSpecCompliantForm(t);if(!eP.isFunction(n))throw TypeError("visitor must be a function");function l(e){if(null===e)return"";if(eP.isDate(e))return e.toISOString();if(eP.isBoolean(e))return e.toString();if(!o&&eP.isBlob(e))throw new eZ("Blob is not supported. Use a Buffer instead.");return eP.isArrayBuffer(e)||eP.isTypedArray(e)?o&&"function"==typeof Blob?new Blob([e]):eI.from(e):e}function d(e,r,n){let o=e;if(e&&!n&&"object"==typeof e)if(eP.endsWith(r,"{}"))r=a?r:r.slice(0,-2),e=JSON.stringify(e);else{var d;if(eP.isArray(e)&&(d=e,eP.isArray(d)&&!d.some(eU))||(eP.isFileList(e)||eP.endsWith(r,"[]"))&&(o=eP.toArray(e)))return r=e$(r),o.forEach(function(e,a){eP.isUndefined(e)||null===e||t.append(!0===s?eF([r],a,i):null===s?r:r+"[]",l(e))}),!1}return!!eU(e)||(t.append(eF(n,r,i),l(e)),!1)}let u=[],c=Object.assign(eD,{defaultVisitor:d,convertValue:l,isVisitable:eU});if(!eP.isObject(e))throw TypeError("data must be an object");return!function e(r,a){if(!eP.isUndefined(r)){if(-1!==u.indexOf(r))throw Error("Circular reference detected in "+a.join("."));u.push(r),eP.forEach(r,function(r,i){!0===(!(eP.isUndefined(r)||null===r)&&n.call(t,r,eP.isString(i)?i.trim():i,a,c))&&e(r,a?a.concat(i):[i])}),u.pop()}}(e),t};function eq(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function eB(e,t){this._pairs=[],e&&eM(e,this,t)}let ez=eB.prototype;function eW(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function eV(e,t,r){let a;if(!t)return e;let n=r&&r.encode||eW,i=eP.isFunction(r)?{serialize:r}:r,s=i&&i.serialize;if(a=s?s(t,i):eP.isURLSearchParams(t)?t.toString():new eB(t,i).toString(n)){let t=e.indexOf("#");
10-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+a}return e}ez.append=function(e,t){this._pairs.push([e,t])},ez.toString=function(e){let t=e?function(t){return e.call(this,t,eq)}:eq;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};class eK{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){eP.forEach(this.handlers,function(t){null!==t&&e(t)})}}let eH={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},eQ="undefined"!=typeof URLSearchParams?URLSearchParams:eB,eJ="undefined"!=typeof FormData?FormData:null,eG="undefined"!=typeof Blob?Blob:null,eX="undefined"!=typeof window&&"undefined"!=typeof document,eY="object"==typeof navigator&&navigator||void 0,e0=eX&&(!eY||0>["ReactNative","NativeScript","NS"].indexOf(eY.product)),e1="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,e4=eX&&window.location.href||"http://localhost",e2={...u,isBrowser:!0,classes:{URLSearchParams:eQ,FormData:eJ,Blob:eG},protocols:["http","https","file","blob","url","data"]},e9=function(e){if(eP.isFormData(e)&&eP.isFunction(e.entries)){let t={};return eP.forEachEntry(e,(e,r)=>{!function e(t,r,a,n){let i=t[n++];if("__proto__"===i)return!0;let s=Number.isFinite(+i),o=n>=t.length;return(i=!i&&eP.isArray(a)?a.length:i,o)?eP.hasOwnProp(a,i)?a[i]=[a[i],r]:a[i]=r:(a[i]&&eP.isObject(a[i])||(a[i]=[]),e(t,r,a[i],n)&&eP.isArray(a[i])&&(a[i]=function(e){let t,r,a={},n=Object.keys(e),i=n.length;for(t=0;t<i;t++)a[r=n[t]]=e[r];return a}(a[i]))),!s}(eP.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0]),r,t,0)}),t}return null},e5={transitional:eH,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){let r,a=t.getContentType()||"",n=a.indexOf("application/json")>-1,i=eP.isObject(e);if(i&&eP.isHTMLForm(e)&&(e=new FormData(e)),eP.isFormData(e))return n?JSON.stringify(e9(e)):e;if(eP.isArrayBuffer(e)||eP.isBuffer(e)||eP.isStream(e)||eP.isFile(e)||eP.isBlob(e)||eP.isReadableStream(e))return e;if(eP.isArrayBufferView(e))return e.buffer;if(eP.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();if(i){if(a.indexOf("application/x-www-form-urlencoded")>-1){var s,o;return(s=e,o=this.formSerializer,eM(s,new e2.classes.URLSearchParams,{visitor:function(e,t,r,a){return e2.isNode&&eP.isBuffer(e)?(this.append(t,e.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)},...o})).toString()}if((r=eP.isFileList(e))||a.indexOf("multipart/form-data")>-1){let t=this.env&&this.env.FormData;return eM(r?{"files[]":e}:e,t&&new t,this.formSerializer)}}if(i||n){t.setContentType("application/json",!1);var l=e;if(eP.isString(l))try{return(0,JSON.parse)(l),eP.trim(l)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(l)}return e}],transformResponse:[function(e){let t=this.transitional||e5.transitional,r=t&&t.forcedJSONParsing,a="json"===this.responseType;if(eP.isResponse(e)||eP.isReadableStream(e))return e;if(e&&eP.isString(e)&&(r&&!this.responseType||a)){let r=t&&t.silentJSONParsing;try{return JSON.parse(e,this.parseReviver)}catch(e){if(!r&&a){if("SyntaxError"===e.name)throw eZ.from(e,eZ.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:e2.classes.FormData,Blob:e2.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};eP.forEach(["delete","get","head","post","put","patch"],e=>{e5.headers[e]={}});let e3=eP.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"]),e6=Symbol("internals");function e8(e){return e&&String(e).trim().toLowerCase()}function e7(e){return!1===e||null==e?e:eP.isArray(e)?e.map(e7):String(e)}function te(e,t,r,a,n){if(eP.isFunction(a))return a.call(this,t,r);if(n&&(t=r),eP.isString(t)){if(eP.isString(a))return -1!==t.indexOf(a);if(eP.isRegExp(a))return a.test(t)}}class tt{constructor(e){e&&this.set(e)}set(e,t,r){let a=this;function n(e,t,r){let n=e8(t);if(!n)throw Error("header name must be a non-empty string");let i=eP.findKey(a,n);i&&void 0!==a[i]&&!0!==r&&(void 0!==r||!1===a[i])||(a[i||t]=e7(e))}let i=(e,t)=>eP.forEach(e,(e,r)=>n(e,r,t));if(eP.isPlainObject(e)||e instanceof this.constructor)i(e,t);else{let a;if(eP.isString(e)&&(e=e.trim())&&(a=e,!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(a.trim())))i((e=>{let t,r,a,n={};return e&&e.split("\n").forEach(function(e){a=e.indexOf(":"),t=e.substring(0,a).trim().toLowerCase(),r=e.substring(a+1).trim(),!t||n[t]&&e3[t]||("set-cookie"===t?n[t]?n[t].push(r):n[t]=[r]:n[t]=n[t]?n[t]+", "+r:r)}),n})(e),t);else if(eP.isObject(e)&&eP.isIterable(e)){let r={},a,n;for(let t of e){if(!eP.isArray(t))throw TypeError("Object iterator must return a key-value pair");r[n=t[0]]=(a=r[n])?eP.isArray(a)?[...a,t[1]]:[a,t[1]]:t[1]}i(r,t)}else null!=e&&n(t,e,r)}return this}get(e,t){if(e=e8(e)){let r=eP.findKey(this,e);if(r){let e=this[r];if(!t)return e;if(!0===t){let t,r=Object.create(null),a=/([^\s,;
10=]+)\s*(?:=\s*([^,;]+))?/g;for(;t=a.exec(e);)r[t[1]]=t[2];return r}if(eP.isFunction(t))return t.call(this,e,r);if(eP.isRegExp(t))return t.exec(e);throw TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=e8(e)){let r=eP.findKey(this,e);return!!(r&&void 0!==this[r]&&(!t||te(this,this[r],r,t)))}return!1}delete(e,t){let r=this,a=!1;function n(e){if(e=e8(e)){let n=eP.findKey(r,e);n&&(!t||te(r,r[n],n,t))&&(delete r[n],a=!0)}}return eP.isArray(e)?e.forEach(n):n(e),a}clear(e){let t=Object.keys(this),r=t.length,a=!1;for(;r--;){let n=t[r];(!e||te(this,this[n],n,e,!0))&&(delete this[n],a=!0)}return a}normalize(e){let t=this,r={};return eP.forEach(this,(a,n)=>{let i=eP.findKey(r,n);if(i){t[i]=e7(a),delete t[n];return}let s=e?n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r):String(n).trim();s!==n&&delete t[n],t[s]=e7(a),r[s]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let t=Object.create(null);return eP.forEach(this,(r,a)=>{null!=r&&!1!==r&&(t[a]=e&&eP.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let r=new this(e);return t.forEach(e=>r.set(e)),r}static accessor(e){let t=(this[e6]=this[e6]={accessors:{}}).accessors,r=this.prototype;function a(e){let a=e8(e);if(!t[a]){let n=eP.toCamelCase(" "+e);["get","set","has"].forEach(t=>{Object.defineProperty(r,t+n,{value:function(r,a,n){return this[t].call(this,e,r,a,n)},configurable:!0})}),t[a]=!0}}return eP.isArray(e)?e.forEach(a):a(e),this}}function tr(e,t){let r=this||e5,a=t||r,n=tt.from(a.headers),i=a.data;return eP.forEach(e,function(e){i=e.call(r,i,n.normalize(),t?t.status:void 0)}),n.normalize(),i}function ta(e){return!!(e&&e.__CANCEL__)}tt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),eP.reduceDescriptors(tt.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[r]=e}}}),eP.freezeMethods(tt);class tn extends eZ{constructor(e,t,r){super(null==e?"canceled":e,eZ.ERR_CANCELED,t,r),this.name="CanceledError",this.__CANCEL__=!0}}function ti(e,t,r){let a=r.config.validateStatus;!r.status||!a||a(r.status)?e(r):t(new eZ("Request failed with status code "+r.status,[eZ.ERR_BAD_REQUEST,eZ.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}let ts=function(e,t){let r,a=Array(e=e||10),n=Array(e),i=0,s=0;return t=void 0!==t?t:1e3,function(o){let l=Date.now(),d=n[s];r||(r=l),a[i]=o,n[i]=l;let u=s,c=0;for(;u!==i;)c+=a[u++],u%=e;if((i=(i+1)%e)===s&&(s=(s+1)%e),l-r<t)return;let h=d&&l-d;return h?Math.round(1e3*c/h):void 0}},to=function(e,t){let r,a,n=0,i=1e3/t,s=(t,i=Date.now())=>{n=i,r=null,a&&(clearTimeout(a),a=null),e(...t)};return[(...e)=>{let t=Date.now(),o=t-n;o>=i?s(e,t):(r=e,a||(a=setTimeout(()=>{a=null,s(r)},i-o)))},()=>r&&s(r)]},tl=(e,t,r=3)=>{let a=0,n=ts(50,250);return to(r=>{let i=r.loaded,s=r.lengthComputable?r.total:void 0,o=i-a,l=n(o);a=i,e({loaded:i,total:s,progress:s?i/s:void 0,bytes:o,rate:l||void 0,estimated:l&&s&&i<=s?(s-i)/l:void 0,event:r,lengthComputable:null!=s,[t?"download":"upload"]:!0})},r)},td=(e,t)=>{let r=null!=e;return[a=>t[0]({lengthComputable:r,total:e,loaded:a}),t[1]]},tu=e=>(...t)=>eP.asap(()=>e(...t)),tc=e2.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,e2.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(e2.origin),e2.navigator&&/(msie|trident)/i.test(e2.navigator.userAgent)):()=>!0,th=e2.hasStandardBrowserEnv?{write(e,t,r,a,n,i,s){if("undefined"==typeof document)return;let o=[`${e}=${encodeURIComponent(t)}`];eP.isNumber(r)&&o.push(`expires=${new Date(r).toUTCString()}`),eP.isString(a)&&o.push(`path=${a}`),eP.isString(n)&&o.push(`domain=${n}`),!0===i&&o.push("secure"),eP.isString(s)&&o.push(`SameSite=${s}`),document.cookie=o.join("; ")},read(e){if("undefined"==typeof document)return null;let t=document.cookie.match(RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read:()=>null,remove(){}};function tp(e,t,r){let a=!("string"==typeof t&&/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t));return e&&(a||!1==r)?t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e:t}let tf=e=>e instanceof tt?{...e}:e;function tm(e,t){t=t||{};let r={};function a(e,t,r,a){return eP.isPlainObject(e)&&eP.isPlainObject(t)?eP.merge.call({caseless:a},e,t):eP.isPlainObject(t)?eP.merge({},t):eP.isArray(t)?t.slice():t}function n(e,t,r,n){return eP.isUndefined(t)?eP.isUndefined(e)?void 0:a(void 0,e,r,n):a(e,t,r,n)}function i(e,t){if(!eP.isUndefined(t))return a(void 0,t)}function s(e,t){return eP.isUndefined(t)?eP.isUndefined(e)?void 0:a(void 0,e):a(void 0,t)}function o(r,n,i){return i in t?a(r,n):i in e?a(void 0,r):void 0}let l={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:o,headers:(e,t,r)=>n(tf(e),tf(t),r,!0)};return eP.forEach(Object.keys({...e,...t}
10),function(a){if("__proto__"===a||"constructor"===a||"prototype"===a)return;let i=eP.hasOwnProp(l,a)?l[a]:n,s=i(e[a],t[a],a);eP.isUndefined(s)&&i!==o||(r[a]=s)}),r}let ty=e=>{let t=tm({},e),{data:r,withXSRFToken:a,xsrfHeaderName:n,xsrfCookieName:i,headers:s,auth:o}=t;if(t.headers=s=tt.from(s),t.url=eV(tp(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),o&&s.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):""))),eP.isFormData(r)){if(e2.hasStandardBrowserEnv||e2.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(eP.isFunction(r.getHeaders)){let e=r.getHeaders(),t=["content-type","content-length"];Object.entries(e).forEach(([e,r])=>{t.includes(e.toLowerCase())&&s.set(e,r)})}}if(e2.hasStandardBrowserEnv&&(a&&eP.isFunction(a)&&(a=a(t)),a||!1!==a&&tc(t.url))){let e=n&&i&&th.read(i);e&&s.set(n,e)}return t},tg="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise(function(t,r){let a,n,i,s,o,l=ty(e),d=l.data,u=tt.from(l.headers).normalize(),{responseType:c,onUploadProgress:h,onDownloadProgress:p}=l;function f(){s&&s(),o&&o(),l.cancelToken&&l.cancelToken.unsubscribe(a),l.signal&&l.signal.removeEventListener("abort",a)}let m=new XMLHttpRequest;function y(){if(!m)return;let a=tt.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders());ti(function(e){t(e),f()},function(e){r(e),f()},{data:c&&"text"!==c&&"json"!==c?m.response:m.responseText,status:m.status,statusText:m.statusText,headers:a,config:e,request:m}),m=null}m.open(l.method.toUpperCase(),l.url,!0),m.timeout=l.timeout,"onloadend"in m?m.onloadend=y:m.onreadystatechange=function(){m&&4===m.readyState&&(0!==m.status||m.responseURL&&0===m.responseURL.indexOf("file:"))&&setTimeout(y)},m.onabort=function(){m&&(r(new eZ("Request aborted",eZ.ECONNABORTED,e,m)),m=null)},m.onerror=function(t){let a=new eZ(t&&t.message?t.message:"Network Error",eZ.ERR_NETWORK,e,m);a.event=t||null,r(a),m=null},m.ontimeout=function(){let t=l.timeout?"timeout of "+l.timeout+"ms exceeded":"timeout exceeded",a=l.transitional||eH;l.timeoutErrorMessage&&(t=l.timeoutErrorMessage),r(new eZ(t,a.clarifyTimeoutError?eZ.ETIMEDOUT:eZ.ECONNABORTED,e,m)),m=null},void 0===d&&u.setContentType(null),"setRequestHeader"in m&&eP.forEach(u.toJSON(),function(e,t){m.setRequestHeader(t,e)}),eP.isUndefined(l.withCredentials)||(m.withCredentials=!!l.withCredentials),c&&"json"!==c&&(m.responseType=l.responseType),p&&([i,o]=tl(p,!0),m.addEventListener("progress",i)),h&&m.upload&&([n,s]=tl(h),m.upload.addEventListener("progress",n),m.upload.addEventListener("loadend",s)),(l.cancelToken||l.signal)&&(a=t=>{m&&(r(!t||t.type?new tn(null,e,m):t),m.abort(),m=null)},l.cancelToken&&l.cancelToken.subscribe(a),l.signal&&(l.signal.aborted?a():l.signal.addEventListener("abort",a)));let g=function(e){let t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(l.url);if(g&&-1===e2.protocols.indexOf(g))return void r(new eZ("Unsupported protocol "+g+":",eZ.ERR_BAD_REQUEST,e));m.send(d||null)})},tv=function*(e,t){let r,a=e.byteLength;if(!t||a<t)return void(yield e);let n=0;for(;n<a;)r=n+t,yield e.slice(n,r),n=r},t_=async function*(e,t){for await(let r of tb(e))yield*tv(r,t)},tb=async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);let t=e.getReader();try{for(;;){let{done:e,value:r}=await t.read();if(e)break;yield r}}finally{await t.cancel()}},tw=(e,t,r,a)=>{let n,i=t_(e,t),s=0,o=e=>{!n&&(n=!0,a&&a(e))};return new ReadableStream({async pull(e){try{let{done:t,value:a}=await i.next();if(t){o(),e.close();return}let n=a.byteLength;if(r){let e=s+=n;r(e)}e.enqueue(new Uint8Array(a))}catch(e){throw o(e),e}},cancel:e=>(o(e),i.return())},{highWaterMark:2})},{isFunction:tk}=eP,tx=(({Request:e,Response:t})=>({Request:e,Response:t}))(eP.global),{ReadableStream:tE,TextEncoder:tO}=eP.global,tR=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},tS=e=>{let t,{fetch:r,Request:a,Response:n}=e=eP.merge.call({skipUndefined:!0},tx,e),i=r?tk(r):"function"==typeof fetch,s=tk(a),o=tk(n);if(!i)return!1;let l=i&&tk(tE),d=i&&("function"==typeof tO?(t=new tO,e=>t.encode(e)):async e=>new Uint8Array(await new a(e).arrayBuffer())),u=s&&l&&tR(()=>{let e=!1,t=new a(e2.origin,{body:new tE,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),c=o&&l&&tR(()=>eP.isReadableStream(new n("").body)),h={stream:c&&(e=>e.body)};
10i&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{h[e]||(h[e]=(t,r)=>{let a=t&&t[e];if(a)return a.call(t);throw new eZ(`Response type '${e}' is not supported`,eZ.ERR_NOT_SUPPORT,r)})});let p=async e=>{if(null==e)return 0;if(eP.isBlob(e))return e.size;if(eP.isSpecCompliantForm(e)){let t=new a(e2.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return eP.isArrayBufferView(e)||eP.isArrayBuffer(e)?e.byteLength:(eP.isURLSearchParams(e)&&(e+=""),eP.isString(e))?(await d(e)).byteLength:void 0},f=async(e,t)=>{let r=eP.toFiniteNumber(e.getContentLength());return null==r?p(t):r};return async e=>{let t,{url:i,method:o,data:l,signal:d,cancelToken:p,timeout:m,onDownloadProgress:y,onUploadProgress:g,responseType:v,headers:_,withCredentials:b="same-origin",fetchOptions:w}=ty(e),k=r||fetch;v=v?(v+"").toLowerCase():"text";let x=((e,t)=>{let{length:r}=e=e?e.filter(Boolean):[];if(t||r){let r,a=new AbortController,n=function(e){if(!r){r=!0,s();let t=e instanceof Error?e:this.reason;a.abort(t instanceof eZ?t:new tn(t instanceof Error?t.message:t))}},i=t&&setTimeout(()=>{i=null,n(new eZ(`timeout of ${t}ms exceeded`,eZ.ETIMEDOUT))},t),s=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(n):e.removeEventListener("abort",n)}),e=null)};e.forEach(e=>e.addEventListener("abort",n));let{signal:o}=a;return o.unsubscribe=()=>eP.asap(s),o}})([d,p&&p.toAbortSignal()],m),E=null,O=x&&x.unsubscribe&&(()=>{x.unsubscribe()});try{if(g&&u&&"get"!==o&&"head"!==o&&0!==(t=await f(_,l))){let e,r=new a(i,{method:"POST",body:l,duplex:"half"});if(eP.isFormData(l)&&(e=r.headers.get("content-type"))&&_.setContentType(e),r.body){let[e,a]=td(t,tl(tu(g)));l=tw(r.body,65536,e,a)}}eP.isString(b)||(b=b?"include":"omit");let r=s&&"credentials"in a.prototype,d={...w,signal:x,method:o.toUpperCase(),headers:_.normalize().toJSON(),body:l,duplex:"half",credentials:r?b:void 0};E=s&&new a(i,d);let p=await (s?k(E,w):k(i,d)),m=c&&("stream"===v||"response"===v);if(c&&(y||m&&O)){let e={};["status","statusText","headers"].forEach(t=>{e[t]=p[t]});let t=eP.toFiniteNumber(p.headers.get("content-length")),[r,a]=y&&td(t,tl(tu(y),!0))||[];p=new n(tw(p.body,65536,r,()=>{a&&a(),O&&O()}),e)}v=v||"text";let R=await h[eP.findKey(h,v)||"text"](p,e);return!m&&O&&O(),await new Promise((t,r)=>{ti(t,r,{data:R,headers:tt.from(p.headers),status:p.status,statusText:p.statusText,config:e,request:E})})}catch(t){if(O&&O(),t&&"TypeError"===t.name&&/Load failed|fetch/i.test(t.message))throw Object.assign(new eZ("Network Error",eZ.ERR_NETWORK,e,E,t&&t.response),{cause:t.cause||t});throw eZ.from(t,t&&t.code,e,E,t&&t.response)}}},tT=new Map,tA=e=>{let t=e&&e.env||{},{fetch:r,Request:a,Response:n}=t,i=[a,n,r],s=i.length,o,l,d=tT;for(;s--;)o=i[s],void 0===(l=d.get(o))&&d.set(o,l=s?new Map:tS(t)),d=l;return l};tA();let tC={http:null,xhr:tg,fetch:{get:tA}};eP.forEach(tC,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}});let tN=e=>`- ${e}`,tj=e=>eP.isFunction(e)||null===e||!1===e,tP={getAdapter:function(e,t){let r,a,{length:n}=e=eP.isArray(e)?e:[e],i={};for(let s=0;s<n;s++){let n;if(a=r=e[s],!tj(r)&&void 0===(a=tC[(n=String(r)).toLowerCase()]))throw new eZ(`Unknown adapter '${n}'`);
10if(a&&(eP.isFunction(a)||(a=a.get(t))))break;i[n||"#"+s]=a}if(!a){let e=Object.entries(i).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));throw new eZ("There is no suitable adapter to dispatch the request "+(n?e.length>1?"since :\n"+e.map(tN).join("\n"):" "+tN(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return a}};function tL(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new tn(null,e)}function tZ(e){return tL(e),e.headers=tt.from(e.headers),e.data=tr.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),tP.getAdapter(e.adapter||e5.adapter,e)(e).then(function(t){return tL(e),t.data=tr.call(e,e.transformResponse,t),t.headers=tt.from(t.headers),t},function(t){return!ta(t)&&(tL(e),t&&t.response&&(t.response.data=tr.call(e,e.transformResponse,t.response),t.response.headers=tt.from(t.response.headers))),Promise.reject(t)})}let tI="1.13.5",tU={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{tU[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});let t$={};tU.transitional=function(e,t,r){function a(e,t){return"[Axios v"+tI+"] Transitional option '"+e+"'"+t+(r?". "+r:"")}return(r,n,i)=>{if(!1===e)throw new eZ(a(n," has been removed"+(t?" in "+t:"")),eZ.ERR_DEPRECATED);return t&&!t$[n]&&(t$[n]=!0,console.warn(a(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(r,n,i)}},tU.spelling=function(e){return(t,r)=>(console.warn(`${r} is likely a misspelling of ${e}`),!0)};let tF={assertOptions:function(e,t,r){if("object"!=typeof e)throw new eZ("options must be an object",eZ.ERR_BAD_OPTION_VALUE);let a=Object.keys(e),n=a.length;for(;n-- >0;){let i=a[n],s=t[i];if(s){let t=e[i],r=void 0===t||s(t,i,e);if(!0!==r)throw new eZ("option "+i+" must be "+r,eZ.ERR_BAD_OPTION_VALUE);continue}if(!0!==r)throw new eZ("Unknown option "+i,eZ.ERR_BAD_OPTION)}},validators:tU},tD=tF.validators;class tM{constructor(e){this.defaults=e||{},this.interceptors={request:new eK,response:new eK}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=Error();let r=t.stack?t.stack.replace(/^.+\n/,""):"";try{e.stack?r&&!String(e.stack).endsWith(r.replace(/^.+\n.+\n/,""))&&(e.stack+="\n"+r):e.stack=r}catch(e){}}throw e}}_request(e,t){let r,a;"string"==typeof e?(t=t||{}).url=e:t=e||{};let{transitional:n,paramsSerializer:i,headers:s}=t=tm(this.defaults,t);void 0!==n&&tF.assertOptions(n,{silentJSONParsing:tD.transitional(tD.boolean),forcedJSONParsing:tD.transitional(tD.boolean),clarifyTimeoutError:tD.transitional(tD.boolean),legacyInterceptorReqResOrdering:tD.transitional(tD.boolean)},!1),null!=i&&(eP.isFunction(i)?t.paramsSerializer={serialize:i}:tF.assertOptions(i,{encode:tD.function,serialize:tD.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),tF.assertOptions(t,{baseUrl:tD.spelling("baseURL"),withXsrfToken:tD.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let o=s&&eP.merge(s.common,s[t.method]);s&&eP.forEach(["delete","get","head","post","put","patch","common"],e=>{delete s[e]}),t.headers=tt.concat(o,s);let l=[],d=!0;this.interceptors.request.forEach(function(e){if("function"==typeof e.runWhen&&!1===e.runWhen(t))return;d=d&&e.synchronous;let r=t.transitional||eH;r&&r.legacyInterceptorReqResOrdering?l.unshift(e.fulfilled,e.rejected):l.push(e.fulfilled,e.rejected)});let u=[];this.interceptors.response.forEach(function(e){u.push(e.fulfilled,e.rejected)});let c=0;if(!d){let e=[tZ.bind(this),void 0];for(e.unshift(...l),e.push(...u),a=e.length,r=Promise.resolve(t);c<a;)r=r.then(e[c++],e[c++]);return r}a=l.length;let h=t;for(;c<a;){let e=l[c++],t=l[c++];try{h=e(h)}catch(e){t.call(this,e);break}}try{r=tZ.call(this,h)}catch(e){return Promise.reject(e)}for(c=0,a=u.length;c<a;)r=r.then(u[c++],u[c++]);return r}getUri(e){return eV(tp((e=tm(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}}eP.forEach(["delete","get","head","options"],function(e){tM.prototype[e]=function(t,r){return this.request(tm(r||{},{method:e,url:t,data:(r||{}).data}))}}),eP.forEach(["post","put","patch"],function(e){function t(t){return function(r,a,n){return this.request(tm(n||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:r,data:a}))}}tM.prototype[e]=t(),tM.prototype[e+"Form"]=t(!0)});class tq{constructor(e){let t;if("function"!=typeof e)throw TypeError("executor must be a function.");this.promise=new Promise(function(e){t=e});let r=this;this.promise.then(e=>{if(!r._listeners)return;let t=r._listeners.length;for(;t-- >0;)r._listeners[t](e);r._listeners=null}),this.promise.then=e=>{let t,a=new Promise(e=>{r.subscribe(e),t=e}).then(e);return a.cancel=function(){r.unsubscribe(t)},a},e(function(e,a,n){r.reason||(r.reason=new tn(e,a,n),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}
10subscribe(e){if(this.reason)return void e(this.reason);this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new tq(function(t){e=t}),cancel:e}}}let tB={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(tB).forEach(([e,t])=>{tB[t]=e});let tz=function e(t){let r=new tM(t),a=H(tM.prototype.request,r);return eP.extend(a,tM.prototype,r,{allOwnKeys:!0}),eP.extend(a,r,null,{allOwnKeys:!0}),a.create=function(r){return e(tm(t,r))},a}(e5);tz.Axios=tM,tz.CanceledError=tn,tz.CancelToken=tq,tz.isCancel=ta,tz.VERSION=tI,tz.toFormData=eM,tz.AxiosError=eZ,tz.Cancel=tz.CanceledError,tz.all=function(e){return Promise.all(e)},tz.spread=function(e){return function(t){return e.apply(null,t)}},tz.isAxiosError=function(e){return eP.isObject(e)&&!0===e.isAxiosError},tz.mergeConfig=tm,tz.AxiosHeaders=tt,tz.formToJSON=e=>e9(eP.isHTMLForm(e)?new FormData(e):e),tz.getAdapter=tP.getAdapter,tz.HttpStatusCode=tB,tz.default=tz;var tW=/:([a-zA-Z_][a-zA-Z0-9_]*)/g;function tV(e,t,r){return e.find(e=>e.method===t&&e.path===r)}var tK=class extends Error{constructor(e,t,r,a){super(e),this.config=t,this.data=r,this.cause=a}},tH={name:"form-data",request:async(e,t)=>{if("object"!=typeof t.data||Array.isArray(t.data))throw new tK("Zodios: multipart/form-data body must be an object",t);let r=function(e){let t=new FormData;for(let r in e)t.append(r,e[r]);return{data:t}}(t.data);return{...t,data:r.data,headers:{...t.headers,...r.headers}}}},tQ={name:"form-url",request:async(e,t)=>{if("object"!=typeof t.data||Array.isArray(t.data))throw new tK("Zodios: application/x-www-form-urlencoded body must be an object",t);return{...t,data:new URLSearchParams(t.data).toString(),headers:{...t.headers,"Content-Type":"application/x-www-form-urlencoded"}}}};function tJ(e,t){return{request:async(r,a)=>({...a,headers:{...a.headers,[e]:t}})}}function tG(e){return[!0,"response","all"].includes(e)}function tX(e){return[!0,"request","all"].includes(e)}var tY=class{constructor(e,t){this.plugins=[],this.key=`${e}-${t}`}indexOf(e){return this.plugins.findIndex(t=>(null==t?void 0:t.name)===e)}use(e){if(e.name){let t=this.indexOf(e.name);if(-1!==t)return this.plugins[t]=e,{key:this.key,value:t}}return this.plugins.push(e),{key:this.key,value:this.plugins.length-1}}eject(e){if("string"==typeof e){let t=this.indexOf(e);if(-1===t)throw Error(`Plugin with name '${e}' not found`);this.plugins[t]=void 0}else{if(e.key!==this.key)throw Error(`Plugin with key '${e.key}' is not registered for endpoint '${this.key}'`);this.plugins[e.value]=void 0}}async interceptRequest(e,t){let r=t;for(let t of this.plugins)null!=t&&t.request&&(r=await t.request(e,r));return r}async interceptResponse(e,t,r){let a=r;for(let r=this.plugins.length-1;r>=0;r--){let n=this.plugins[r];n&&(a=a.then(null!=n&&n.response?r=>n.response(e,t,r):void 0,null!=n&&n.error?r=>n.error(e,t,r):void 0))}return a}count(){return this.plugins.reduce((e,t)=>
10t?e+1:e,0)}};function t0(e){let t=new Set;for(let r of e){let e=`${r.method} ${r.path}`;if(t.has(e))throw Error(`Zodios: Duplicate path '${e}'`);t.add(e)}let r=new Set;for(let t of e)if(t.alias){if(r.has(t.alias))throw Error(`Zodios: Duplicate alias '${t.alias}'`);r.add(t.alias)}for(let t of e)if(t.parameters&&t.parameters.filter(e=>"Body"===e.type).length>1)throw Error(`Zodios: Multiple body parameters in endpoint '${t.path}'`)}var t1=class{constructor(e,t,r){let a,n;if(this.endpointPlugins=new Map,!e)throw Array.isArray(t)?Error("Zodios: missing base url"):Error("Zodios: missing api description");if("string"==typeof e&&Array.isArray(t))n=e,this.api=t,a=r||{};else if(Array.isArray(e)&&!Array.isArray(t))this.api=e,a=t||{};else throw Error("Zodios: api must be an array");t0(this.api),this.options={validate:!0,transform:!0,sendDefaults:!1,...a},this.options.axiosInstance?this.axiosInstance=this.options.axiosInstance:this.axiosInstance=tz.create({...this.options.axiosConfig}),n&&(this.axiosInstance.defaults.baseURL=n),this.injectAliasEndpoints(),this.initPlugins(),[!0,"all","request","response"].includes(this.options.validate)&&this.use(function({validate:e,transform:t,sendDefaults:r}){return{name:"zod-validation",request:tX(e)?async(e,a)=>{let n=tV(e,a.method,a.url);if(!n)throw Error(`No endpoint found for ${a.method} ${a.url}`);let{parameters:i}=n;if(!i)return a;let s={...a,queries:{...a.queries},headers:{...a.headers},params:{...a.params}},o={Query:e=>{var t;return null==(t=s.queries)?void 0:t[e]},Body:e=>s.data,Header:e=>{var t;return null==(t=s.headers)?void 0:t[e]},Path:e=>{var t;return null==(t=s.params)?void 0:t[e]}},l={Query:(e,t)=>s.queries[e]=t,Body:(e,t)=>s.data=t,Header:(e,t)=>s.headers[e]=t,Path:(e,t)=>s.params[e]=t},d=tX(t);for(let e of i){let{name:t,schema:n,type:i}=e,s=o[i](t);if(r||void 0!==s){let e=await n.safeParseAsync(s);if(!e.success)throw new tK(`Zodios: Invalid ${i} parameter '${t}'`,a,s,e.error);d&&l[i](t,e.data)}}return s}:void 0,response:tG(e)?async(e,r,a)=>{var n,i,s,o;let l=tV(e,r.method,r.url);if(!l)throw Error(`No endpoint found for ${r.method} ${r.url}`);if((null==(i=null==(n=a.headers)?void 0:n["content-type"])?void 0:i.includes("application/json"))||(null==(o=null==(s=a.headers)?void 0:s["content-type"])?void 0:o.includes("application/vnd.api+json"))){let e=await l.response.safeParseAsync(a.data);if(!e.success)throw new tK(`Zodios: Invalid response from endpoint '${l.method} ${l.path}' 11status: ${a.status} ${a.statusText} 12cause: 13${e.error.message} 14received: 15${JSON.stringify(a.data,null,2)}`,r,a.data,e.error);tG(t)&&(a.data=e.data)}return a}:void 0}}(this.options))}initPlugins(){this.endpointPlugins.set("any-any",new tY("any","any")),this.api.forEach(e=>{let t=new tY(e.method,e.path);switch(e.requestFormat){case"binary":t.use(tJ("Content-Type","application/octet-stream"));break;case"form-data":t.use(tH);break;case"form-url":t.use(tQ);break;case"text":t.use(tJ("Content-Type","text/plain"))}this.endpointPlugins.set(`${e.method}-${e.path}`,t)})}getAnyEndpointPlugins(){return this.endpointPlugins.get("any-any")}findAliasEndpointPlugins(e){let t=this.api.find(t=>t.alias===e);if(t)return this.endpointPlugins.get(`${t.method}-${t.path}`)}findEnpointPlugins(e,t){return this.endpointPlugins.get(`${e}-${t}`)}get baseURL(){return this.axiosInstance.defaults.baseURL}get axios(){return this.axiosInstance}use(...e){if("object"==typeof e[0])return this.getAnyEndpointPlugins().use(e[0]);if("string"==typeof e[0]&&"object"==typeof e[1]){let t=this.findAliasEndpointPlugins(e[0]);if(!t)throw Error(`Zodios: no alias '${e[0]}' found to register plugin`);return t.use(e[1])}if("string"==typeof e[0]&&"string"==typeof e[1]&&"object"==typeof e[2]){let t=this.findEnpointPlugins(e[0],e[1]);if(!t)throw Error(`Zodios: no endpoint '${e[0]} ${e[1]}' found to register plugin`);return t.use(e[2])}throw Error("Zodios: invalid plugin registration")}eject(e){var t;if("string"==typeof e)return void this.getAnyEndpointPlugins().eject(e);null==(t=this.endpointPlugins.get(e.key))||t.eject(e)}
15injectAliasEndpoints(){this.api.forEach(e=>{e.alias&&(["post","put","patch","delete"].includes(e.method)?this[e.alias]=(t,r)=>this.request({...r,method:e.method,url:e.path,data:t}):this[e.alias]=t=>this.request({...t,method:e.method,url:e.path}))})}async request(e){var t;let r,a,n=e,i=this.getAnyEndpointPlugins(),s=this.findEnpointPlugins(n.method,n.url);n=await i.interceptRequest(this.api,n),s&&(n=await s.interceptRequest(this.api,n));let o=this.axiosInstance.request({...function(e,t){let r={...e};for(let e of t)delete r[e];return r}(n,["params","queries"]),url:(r=(t=n).url,(a=t.params)&&(r=r.replace(tW,(e,t)=>t in a?`${a[t]}`:e)),r),params:n.queries});return s&&(o=s.interceptResponse(this.api,n,o)),o=i.interceptResponse(this.api,n,o),(await o).data}async get(e,...[t]){return this.request({...t,method:"get",url:e})}async post(e,t,...[r]){return this.request({...r,method:"post",url:e,data:t})}async put(e,t,...[r]){return this.request({...r,method:"put",url:e,data:t})}async patch(e,t,...[r]){return this.request({...r,method:"patch",url:e,data:t})}async delete(e,t,...[r]){return this.request({...r,method:"delete",url:e,data:t})}};!function(e){e.assertEqual=e=>{},e.assertIs=function(e){},e.assertNever=function(e){throw Error()},e.arrayToEnum=e=>{let t={};for(let r of e)t[r]=r;return t},e.getValidEnumValues=t=>{let r=e.objectKeys(t).filter(e=>"number"!=typeof t[t[e]]),a={};for(let e of r)a[e]=t[e];return e.objectValues(a)},e.objectValues=t=>e.objectKeys(t).map(function(e){return t[e]}),e.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{let t=[];for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t},e.find=(e,t)=>{for(let r of e)if(t(r))return r},e.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&Number.isFinite(e)&&Math.floor(e)===e,e.joinValues=function(e,t=" | "){return e.map(e=>"string"==typeof e?`'${e}'`:e).join(t)},e.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t}(s||(s={})),(o||(o={})).mergeShapes=(e,t)=>({...e,...t});let t4=s.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),t2=e=>{switch(typeof e){case"undefined":return t4.undefined;case"string":return t4.string;case"number":return Number.isNaN(e)?t4.nan:t4.number;case"boolean":return t4.boolean;case"function":return t4.function;case"bigint":return t4.bigint;case"symbol":return t4.symbol;case"object":if(Array.isArray(e))return t4.array;if(null===e)return t4.null;if(e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch)return t4.promise;if("undefined"!=typeof Map&&e instanceof Map)return t4.map;if("undefined"!=typeof Set&&e instanceof Set)return t4.set;if("undefined"!=typeof Date&&e instanceof Date)return t4.date;return t4.object;default:return t4.unknown}}
15,t9=s.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class t5 extends Error{get errors(){return this.issues}constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};let t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}format(e){let t=e||function(e){return e.message},r={_errors:[]},a=e=>{for(let n of e.issues)if("invalid_union"===n.code)n.unionErrors.map(a);else if("invalid_return_type"===n.code)a(n.returnTypeError);else if("invalid_arguments"===n.code)a(n.argumentsError);else if(0===n.path.length)r._errors.push(t(n));else{let e=r,a=0;for(;a<n.path.length;){let r=n.path[a];a===n.path.length-1?(e[r]=e[r]||{_errors:[]},e[r]._errors.push(t(n))):e[r]=e[r]||{_errors:[]},e=e[r],a++}}};return a(this),r}static assert(e){if(!(e instanceof t5))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,s.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){let t={},r=[];for(let a of this.issues)if(a.path.length>0){let r=a.path[0];t[r]=t[r]||[],t[r].push(e(a))}else r.push(e(a));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}t5.create=e=>new t5(e);let t3=(e,t)=>{let r;switch(e.code){case t9.invalid_type:r=e.received===t4.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case t9.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,s.jsonStringifyReplacer)}`;break;case t9.unrecognized_keys:r=`Unrecognized key(s) in object: ${s.joinValues(e.keys,", ")}`;break;case t9.invalid_union:r="Invalid input";break;case t9.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${s.joinValues(e.options)}`;break;case t9.invalid_enum_value:r=`Invalid enum value. Expected ${s.joinValues(e.options)}, received '${e.received}'`;break;case t9.invalid_arguments:r="Invalid function arguments";break;case t9.invalid_return_type:r="Invalid function return type";break;case t9.invalid_date:r="Invalid date";break;case t9.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(r=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(r=`${r} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:s.assertNever(e.validation):r="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case t9.too_small:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type||"bigint"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case t9.too_big:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case t9.custom:r="Invalid input";break;
vendor: 7,165 bytes, line 15
15case t9.invalid_intersection_types:r="Intersection results could not be merged";break;case t9.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case t9.not_finite:r="Number must be finite";break;default:r=t.defaultError,s.assertNever(e)}return{message:r}};!function(e){e.errToObj=e=>"string"==typeof e?{message:e}:e||{},e.toString=e=>"string"==typeof e?e:e?.message}(l||(l={}));let t6=e=>{let{data:t,path:r,errorMaps:a,issueData:n}=e,i=[...r,...n.path||[]],s={...n,path:i};if(void 0!==n.message)return{...n,path:i,message:n.message};let o="";for(let e of a.filter(e=>!!e).slice().reverse())o=e(s,{data:t,defaultError:o}).message;return{...n,path:i,message:o}};function t8(e,t){let r=t6({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,t3,void 0].filter(e=>!!e)});e.common.issues.push(r)}class t7{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){let r=[];for(let a of t){if("aborted"===a.status)return re;"dirty"===a.status&&e.dirty(),r.push(a.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let e of t){let t=await e.key,a=await e.value;r.push({key:t,value:a})}return t7.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let a of t){let{key:t,value:n}=a;if("aborted"===t.status||"aborted"===n.status)return re;"dirty"===t.status&&e.dirty(),"dirty"===n.status&&e.dirty(),"__proto__"!==t.value&&(void 0!==n.value||a.alwaysSet)&&(r[t.value]=n.value)}return{status:e.value,value:r}}}let re=Object.freeze({status:"aborted"}),rt=e=>({status:"dirty",value:e}),rr=e=>({status:"valid",value:e}),ra=e=>"undefined"!=typeof Promise&&e instanceof Promise;class rn{constructor(e,t,r,a){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=a}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}let ri=(e,t)=>{if("valid"===t.status)return{success:!0,data:t.value};if(!e.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let t=new t5(e.common.issues);return this._error=t,this._error}}};function rs(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:a,description:n}=e;if(t&&(r||a))throw Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:n}:{errorMap:(t,n)=>{let{message:i}=e;return"invalid_enum_value"===t.code?{message:i??n.defaultError}:void 0===n.data?{message:i??a??n.defaultError}:"invalid_type"!==t.code?{message:n.defaultError}:{message:i??r??n.defaultError}},description:n}}class ro{get description(){return this._def.description}_getType(e){return t2(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:t2(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new t7,ctx:{common:e.parent.common,data:e.data,parsedType:t2(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(ra(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){return Promise.resolve(this._parse(e))}parse(e,t){let r=this.safeParse(e,t);if(r.success)return r.data;throw r.error}safeParse(e,t){let r={common:{issues:[],async:t?.async??!1,contextualErrorMap:t?.errorMap},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:t2(e)},a=this._parseSync({data:e,path:r.path,parent:r});return ri(r,a)}"~validate"(e){let t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:t2(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:t});return"valid"===r.status?{value:r.value}:{issues:t.common.issues}}catch(e){e?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then(e=>"valid"===e.status?{value:e.value}:{issues:t.common.issues})}async parseAsync(e,t){let r=await this.safeParseAsync(e,t);if(r.success)return r.data;throw r.error}async safeParseAsync(e,t){let r={common:{issues:[],contextualErrorMap:t?.errorMap,async:!0},path:t?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:t2(e)},a=this._parse({data:e,path:r.path,parent:r});return ri(r,await (ra(a)?a:Promise.resolve(a)))}refine(e,t){return this._refinement((r,a)=>{let n=e(r),i=()=>a.addIssue({code:t9.custom,..."string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(r):t});return"undefined"!=typeof Promise&&n instanceof Promise?n.then(e=>!!e||(i(),!1)):!!n||(i(),!1)})}refinement(e,t){return this._refinement((r,a)=>!!e(r)||(a.addIssue("function"==typeof t?t(r,a):t),!1))}_refinement(e){return new r0({schema:this,typeName:d.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:e=>this["~validate"](e)}}optional(){return r1.create(this,this._def)}nullable(){return r4.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return rU.create(this)}promise(){return rY.create(this,this._def)}or(e){return rF.create([this,e],this._def)}and(e){return rq.create(this,e,this._def)}transform(e){return new r0({...rs(this._def),schema:this,typeName:d.ZodEffects,effect:{type:"transform",transform:e}})}default(e){return new r2({...rs(this._def),innerType:this,defaultValue:"function"==typeof e?e:()=>e,typeName:d.ZodDefault})}brand(){return new r3({typeName:d.ZodBranded,type:this,...rs(this._def)})}catch(e){return new r9({...rs(this._def),innerType:this,catchValue:"function"==typeof e?e:()=>e,typeName:d.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return r6.create(this,e)}readonly(){return r8.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}let rl=/^c[^\s-]{8,}
vendor: 25,257 bytes, line 15
15$/i,rd=/^[0-9a-z]+$/,ru=/^[0-9A-HJKMNP-TV-Z]{26}$/i,rc=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,rh=/^[a-z0-9_-]{21}$/i,rp=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,rf=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,rm=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,ry=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,rg=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,rv=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,r_=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,rb=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,rw=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,rk="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",rx=RegExp(`^${rk}$`);function rE(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`);let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}class rO extends ro{_parse(e){var t,r,n,i;let o;if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==t4.string){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.string,received:t.parsedType}),re}let l=new t7;for(let d of this._def.checks)if("min"===d.kind)e.data.length<d.value&&(t8(o=this._getOrReturnCtx(e,o),{code:t9.too_small,minimum:d.value,type:"string",inclusive:!0,exact:!1,message:d.message}),l.dirty());else if("max"===d.kind)e.data.length>d.value&&(t8(o=this._getOrReturnCtx(e,o),{code:t9.too_big,maximum:d.value,type:"string",inclusive:!0,exact:!1,message:d.message}),l.dirty());else if("length"===d.kind){let t=e.data.length>d.value,r=e.data.length<d.value;(t||r)&&(o=this._getOrReturnCtx(e,o),t?t8(o,{code:t9.too_big,maximum:d.value,type:"string",inclusive:!0,exact:!0,message:d.message}):r&&t8(o,{code:t9.too_small,minimum:d.value,type:"string",inclusive:!0,exact:!0,message:d.message}),l.dirty())}else if("email"===d.kind)rm.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"email",code:t9.invalid_string,message:d.message}),l.dirty());else if("emoji"===d.kind)a||(a=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),a.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"emoji",code:t9.invalid_string,message:d.message}),l.dirty());else if("uuid"===d.kind)rc.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"uuid",code:t9.invalid_string,message:d.message}),l.dirty());else if("nanoid"===d.kind)rh.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"nanoid",code:t9.invalid_string,message:d.message}),l.dirty());else if("cuid"===d.kind)rl.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"cuid",code:t9.invalid_string,message:d.message}),l.dirty());else if("cuid2"===d.kind)rd.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"cuid2",code:t9.invalid_string,message:d.message}),l.dirty());else if("ulid"===d.kind)ru.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"ulid",code:t9.invalid_string,message:d.message}),l.dirty());else if("url"===d.kind)try{new URL(e.data)}catch{t8(o=this._getOrReturnCtx(e,o),{validation:"url",code:t9.invalid_string,message:d.message}),l.dirty()}else"regex"===d.kind?(d.regex.lastIndex=0,d.regex.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"regex",code:t9.invalid_string,message:d.message}),l.dirty())):"trim"===d.kind?e.data=e.data.trim():"includes"===d.kind?e.data.includes(d.value,d.position)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:{includes:d.value,position:d.position},message:d.message}),l.dirty()):"toLowerCase"===d.kind?e.data=e.data.toLowerCase():"toUpperCase"===d.kind?e.data=e.data.toUpperCase():"startsWith"===d.kind?e.data.startsWith(d.value)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:{startsWith:d.value},message:d.message}),l.dirty()):"endsWith"===d.kind?e.data.endsWith(d.value)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:{endsWith:d.value},message:d.message}),l.dirty()):"datetime"===d.kind?(function(e){let t=`${rk}T${rE(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,RegExp(`^${t}$`)})(d).test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:"datetime",message:d.message}),l.dirty()):"date"===d.kind?rx.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:"date",message:d.message}),l.dirty()):"time"===d.kind?RegExp(`^${rE(d)}$`).test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{code:t9.invalid_string,validation:"time",message:d.message}),l.dirty()):"duration"===d.kind?rf.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"duration",code:t9.invalid_string,message:d.message}),l.dirty()):"ip"===d.kind?(t=e.data,!(("v4"===(r=d.version)||!r)&&ry.test(t)||("v6"===r||!r)&&rv.test(t))&&1&&(t8(o=this._getOrReturnCtx(e,o),{validation:"ip",code:t9.invalid_string,message:d.message}),l.dirty())):"jwt"===d.kind?!function(e,t){if(!rp.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let a=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),n=JSON.parse(atob(a));if("object"!=typeof n||null===n||"typ"in n&&n?.typ!=="JWT"||!n.alg||t&&n.alg!==t)return!1;return!0}catch{return!1}}(e.data,d.alg)&&(t8(o=this._getOrReturnCtx(e,o),{validation:"jwt",code:t9.invalid_string,message:d.message}),l.dirty()):"cidr"===d.kind?(n=e.data,!(("v4"===(i=d.version)||!i)&&rg.test(n)||("v6"===i||!i)&&r_.test(n))&&1&&(t8(o=this._getOrReturnCtx(e,o),{validation:"cidr",code:t9.invalid_string,message:d.message}),l.dirty())):"base64"===d.kind?rb.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"base64",code:t9.invalid_string,message:d.message}),l.dirty()):"base64url"===d.kind?rw.test(e.data)||(t8(o=this._getOrReturnCtx(e,o),{validation:"base64url",code:t9.invalid_string,message:d.message}),l.dirty()):s.assertNever(d);return{status:l.value,value:e.data}}_regex(e,t,r){return this.refinement(t=>e.test(t),{validation:t,code:t9.invalid_string,...l.errToObj(r)})}_addCheck(e){return new rO({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...l.errToObj(e)})}url(e){return this._addCheck({kind:"url",...l.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...l.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...l.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...l.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...l.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...l.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...l.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...l.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...l.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...l.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...l.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...l.errToObj(e)})}datetime(e){return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===e?.precision?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...l.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===e?.precision?null:e?.precision,...l.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...l.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...l.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...l.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...l.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...l.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...l.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...l.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...l.errToObj(t)})}nonempty(e){return this.min(1,l.errToObj(e))}trim(){return new rO({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new rO({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new rO({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>"datetime"===e.kind)}get isDate(){return!!this._def.checks.find(e=>"date"===e.kind)}get isTime(){return!!this._def.checks.find(e=>"time"===e.kind)}get isDuration(){return!!this._def.checks.find(e=>"duration"===e.kind)}get isEmail(){return!!this._def.checks.find(e=>"email"===e.kind)}get isURL(){return!!this._def.checks.find(e=>"url"===e.kind)}get isEmoji(){return!!this._def.checks.find(e=>"emoji"===e.kind)}get isUUID(){return!!this._def.checks.find(e=>"uuid"===e.kind)}get isNANOID(){return!!this._def.checks.find(e=>"nanoid"===e.kind)}get isCUID(){return!!this._def.checks.find(e=>"cuid"===e.kind)}get isCUID2(){return!!this._def.checks.find(e=>"cuid2"===e.kind)}get isULID(){return!!this._def.checks.find(e=>"ulid"===e.kind)}get isIP(){return!!this._def.checks.find(e=>"ip"===e.kind)}get isCIDR(){return!!this._def.checks.find(e=>"cidr"===e.kind)}get isBase64(){return!!this._def.checks.find(e=>"base64"===e.kind)}get isBase64url(){return!!this._def.checks.find(e=>"base64url"===e.kind)}get minLength(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}rO.create=e=>new rO({checks:[],typeName:d.ZodString,coerce:e?.coerce??!1,...rs(e)});class rR extends ro{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){let t;if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==t4.number){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.number,received:t.parsedType}),re}let r=new t7;for(let a of this._def.checks)"int"===a.kind?s.isInteger(e.data)||(t8(t=this._getOrReturnCtx(e,t),{code:t9.invalid_type,expected:"integer",received:"float",message:a.message}),r.dirty()):"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_small,minimum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_big,maximum:a.value,type:"number",inclusive:a.inclusive,exact:!1,message:a.message}),r.dirty()):"multipleOf"===a.kind?0!==function(e,t){let r=(e.toString().split(".")[1]||"").length,a=(t.toString().split(".")[1]||"").length,n=r>a?r:a;return Number.parseInt(e.toFixed(n).replace(".",""))%Number.parseInt(t.toFixed(n).replace(".",""))/10**n}(e.data,a.value)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):"finite"===a.kind?Number.isFinite(e.data)||(t8(t=this._getOrReturnCtx(e,t),{code:t9.not_finite,message:a.message}),r.dirty()):s.assertNever(a);return{status:r.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,l.toString(t))}gt(e,t){return this.setLimit("min",e,!1,l.toString(t))}lte(e,t){return this.setLimit("max",e,!0,l.toString(t))}lt(e,t){return this.setLimit("max",e,!1,l.toString(t))}setLimit(e,t,r,a){return new rR({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:l.toString(a)}]})}_addCheck(e){return new rR({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:l.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:l.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:l.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:l.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:l.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:l.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:l.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:l.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:l.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>"int"===e.kind||"multipleOf"===e.kind&&s.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks)if("finite"===r.kind||"int"===r.kind||"multipleOf"===r.kind)return!0;else"min"===r.kind?(null===t||r.value>t)&&(t=r.value):"max"===r.kind&&(null===e||r.value<e)&&(e=r.value);return Number.isFinite(t)&&Number.isFinite(e)}}rR.create=e=>new rR({checks:[],typeName:d.ZodNumber,coerce:e?.coerce||!1,...rs(e)});class rS extends ro{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){let t;if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==t4.bigint)return this._getInvalidInput(e);let r=new t7;for(let a of this._def.checks)"min"===a.kind?(a.inclusive?e.data<a.value:e.data<=a.value)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_small,type:"bigint",minimum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"max"===a.kind?(a.inclusive?e.data>a.value:e.data>=a.value)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_big,type:"bigint",maximum:a.value,inclusive:a.inclusive,message:a.message}),r.dirty()):"multipleOf"===a.kind?e.data%a.value!==BigInt(0)&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.not_multiple_of,multipleOf:a.value,message:a.message}),r.dirty()):s.assertNever(a);return{status:r.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.bigint,received:t.parsedType}),re}gte(e,t){return this.setLimit("min",e,!0,l.toString(t))}gt(e,t){return this.setLimit("min",e,!1,l.toString(t))}lte(e,t){return this.setLimit("max",e,!0,l.toString(t))}lt(e,t){return this.setLimit("max",e,!1,l.toString(t))}setLimit(e,t,r,a){return new rS({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:l.toString(a)}]})}_addCheck(e){return new rS({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:l.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:l.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:l.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:l.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:l.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}rS.create=e=>new rS({checks:[],typeName:d.ZodBigInt,coerce:e?.coerce??!1,...rs(e)});class rT extends ro{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==t4.boolean){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.boolean,received:t.parsedType}),re}return rr(e.data)}}rT.create=e=>new rT({typeName:d.ZodBoolean,coerce:e?.coerce||!1,...rs(e)});class rA extends ro{_parse(e){let t;if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==t4.date){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.date,received:t.parsedType}),re}if(Number.isNaN(e.data.getTime()))return t8(this._getOrReturnCtx(e),{code:t9.invalid_date}),re;let r=new t7;for(let a of this._def.checks)"min"===a.kind?e.data.getTime()<a.value&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_small,message:a.message,inclusive:!0,exact:!1,minimum:a.value,type:"date"}),r.dirty()):"max"===a.kind?e.data.getTime()>a.value&&(t8(t=this._getOrReturnCtx(e,t),{code:t9.too_big,message:a.message,inclusive:!0,exact:!1,maximum:a.value,type:"date"}),r.dirty()):s.assertNever(a);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new rA({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:l.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:l.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}rA.create=e=>new rA({checks:[],coerce:e?.coerce||!1,typeName:d.ZodDate,...rs(e)});class rC extends ro{_parse(e){if(this._getType(e)!==t4.symbol){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.symbol,received:t.parsedType}),re}return rr(e.data)}}rC.create=e=>new rC({typeName:d.ZodSymbol,...rs(e)});class rN extends ro{_parse(e){if(this._getType(e)!==t4.undefined){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.undefined,received:t.parsedType}),re}return rr(e.data)}}rN.create=e=>new rN({typeName:d.ZodUndefined,...rs(e)});class rj extends ro{_parse(e){if(this._getType(e)!==t4.null){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.null,received:t.parsedType}),re}return rr(e.data)}}rj.create=e=>new rj({typeName:d.ZodNull,...rs(e)});class rP extends ro{constructor(){super(...arguments),this._any=!0}_parse(e){return rr(e.data)}}rP.create=e=>new rP({typeName:d.ZodAny,...rs(e)});class rL extends ro{constructor(){super(...arguments),this._unknown=!0}_parse(e){return rr(e.data)}}rL.create=e=>new rL({typeName:d.ZodUnknown,...rs(e)});class rZ extends ro{_parse(e){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.never,received:t.parsedType}),re}}rZ.create=e=>new rZ({typeName:d.ZodNever,...rs(e)});class rI extends ro{_parse(e){if(this._getType(e)!==t4.undefined){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.void,received:t.parsedType}),re}return rr(e.data)}}rI.create=e=>new rI({typeName:d.ZodVoid,...rs(e)});class rU extends ro{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),a=this._def;if(t.parsedType!==t4.array)return t8(t,{code:t9.invalid_type,expected:t4.array,received:t.parsedType}),re;if(null!==a.exactLength){let e=t.data.length>a.exactLength.value,n=t.data.length<a.exactLength.value;(e||n)&&(t8(t,{code:e?t9.too_big:t9.too_small,minimum:n?a.exactLength.value:void 0,maximum:e?a.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:a.exactLength.message}),r.dirty())}if(null!==a.minLength&&t.data.length<a.minLength.value&&(t8(t,{code:t9.too_small,minimum:a.minLength.value,type:"array",inclusive:!0,exact:!1,message:a.minLength.message}),r.dirty()),null!==a.maxLength&&t.data.length>a.maxLength.value&&(t8(t,{code:t9.too_big,maximum:a.maxLength.value,type:"array",inclusive:!0,exact:!1,message:a.maxLength.message}),r.dirty()),t.common.async)return Promise.all([...t.data].map((e,r)=>a.type._parseAsync(new rn(t,e,t.path,r)))).then(e=>t7.mergeArray(r,e));let n=[...t.data].map((e,r)=>a.type._parseSync(new rn(t,e,t.path,r)));return t7.mergeArray(r,n)}get element(){return this._def.type}min(e,t){return new rU({...this._def,minLength:{value:e,message:l.toString(t)}})}max(e,t){return new rU({...this._def,maxLength:{value:e,message:l.toString(t)}})}length(e,t){return new rU({...this._def,exactLength:{value:e,message:l.toString(t)}})}nonempty(e){return this.min(1,e)}}rU.create=(e,t)=>new rU({type:e,minLength:null,maxLength:null,exactLength:null,typeName:d.ZodArray,...rs(t)});class r$ extends ro{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;let e=this._def.shape(),t=s.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==t4.object){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.object,received:t.parsedType}),re}let{status:t,ctx:r}=this._processInputParams(e),{shape:a,keys:n}=this._getCached(),i=[];if(!(this._def.catchall instanceof rZ&&"strip"===this._def.unknownKeys))for(let e in r.data)n.includes(e)||i.push(e);let s=[];for(let e of n){let t=a[e],n=r.data[e];s.push({key:{status:"valid",value:e},value:t._parse(new rn(r,n,r.path,e)),alwaysSet:e in r.data})}if(this._def.catchall instanceof rZ){let e=this._def.unknownKeys;if("passthrough"===e)for(let e of i)s.push({key:{status:"valid",value:e},value:{status:"valid",value:r.data[e]}});else if("strict"===e)i.length>0&&(t8(r,{code:t9.unrecognized_keys,keys:i}),t.dirty());else if("strip"===e);else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let e=this._def.catchall;for(let t of i){let a=r.data[t];s.push({key:{status:"valid",value:t},value:e._parse(new rn(r,a,r.path,t)),alwaysSet:t in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let e=[];for(let t of s){let r=await t.key,a=await t.value;e.push({key:r,value:a,alwaysSet:t.alwaysSet})}return e}).then(e=>t7.mergeObjectSync(t,e)):t7.mergeObjectSync(t,s)}get shape(){return this._def.shape()}strict(e){return l.errToObj,new r$({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,r)=>{let a=this._def.errorMap?.(t,r).message??r.defaultError;return"unrecognized_keys"===t.code?{message:l.errToObj(e).message??a}:{message:a}}}:{}})}strip(){return new r$({...this._def,unknownKeys:"strip"})}passthrough(){return new r$({...this._def,unknownKeys:"passthrough"})}extend(e){return new r$({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new r$({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:d.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new r$({...this._def,catchall:e})}pick(e){let t={};for(let r of s.objectKeys(e))e[r]&&this.shape[r]&&(t[r]=this.shape[r]);return new r$({...this._def,shape:()=>t})}omit(e){let t={};for(let r of s.objectKeys(this.shape))e[r]||(t[r]=this.shape[r]);return new r$({...this._def,shape:()=>t})}deepPartial(){return function e(t){if(t instanceof r$){let r={};for(let a in t.shape){let n=t.shape[a];r[a]=r1.create(e(n))}return new r$({...t._def,shape:()=>r})}if(t instanceof rU)return new rU({...t._def,type:e(t.element)});if(t instanceof r1)return r1.create(e(t.unwrap()));if(t instanceof r4)return r4.create(e(t.unwrap()));if(t instanceof rB)return rB.create(t.items.map(t=>e(t)));else return t}(this)}partial(e){let t={};for(let r of s.objectKeys(this.shape)){let a=this.shape[r];e&&!e[r]?t[r]=a:t[r]=a.optional()}return new r$({...this._def,shape:()=>t})}required(e){let t={};for(let r of s.objectKeys(this.shape))if(e&&!e[r])t[r]=this.shape[r];else{let e=this.shape[r];for(;e instanceof r1;)e=e._def.innerType;t[r]=e}return new r$({...this._def,shape:()=>t})}keyof(){return rJ(s.objectKeys(this.shape))}}r$.create=(e,t)=>
15new r$({shape:()=>e,unknownKeys:"strip",catchall:rZ.create(),typeName:d.ZodObject,...rs(t)}),r$.strictCreate=(e,t)=>new r$({shape:()=>e,unknownKeys:"strict",catchall:rZ.create(),typeName:d.ZodObject,...rs(t)}),r$.lazycreate=(e,t)=>new r$({shape:e,unknownKeys:"strip",catchall:rZ.create(),typeName:d.ZodObject,...rs(t)});class rF extends ro{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;if(t.common.async)return Promise.all(r.map(async e=>{let r={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:r}),ctx:r}})).then(function(e){for(let t of e)if("valid"===t.result.status)return t.result;for(let r of e)if("dirty"===r.result.status)return t.common.issues.push(...r.ctx.common.issues),r.result;let r=e.map(e=>new t5(e.ctx.common.issues));return t8(t,{code:t9.invalid_union,unionErrors:r}),re});{let e,a=[];for(let n of r){let r={...t,common:{...t.common,issues:[]},parent:null},i=n._parseSync({data:t.data,path:t.path,parent:r});if("valid"===i.status)return i;"dirty"!==i.status||e||(e={result:i,ctx:r}),r.common.issues.length&&a.push(r.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;let n=a.map(e=>new t5(e));return t8(t,{code:t9.invalid_union,unionErrors:n}),re}}get options(){return this._def.options}}rF.create=(e,t)=>new rF({options:e,typeName:d.ZodUnion,...rs(t)});let rD=e=>{if(e instanceof rH)return rD(e.schema);if(e instanceof r0)return rD(e.innerType());if(e instanceof rQ)return[e.value];if(e instanceof rG)return e.options;if(e instanceof rX)return s.objectValues(e.enum);else if(e instanceof r2)return rD(e._def.innerType);else if(e instanceof rN)return[void 0];else if(e instanceof rj)return[null];else if(e instanceof r1)return[void 0,...rD(e.unwrap())];else if(e instanceof r4)return[null,...rD(e.unwrap())];else if(e instanceof r3)return rD(e.unwrap());else if(e instanceof r8)return rD(e.unwrap());else if(e instanceof r9)return rD(e._def.innerType);else return[]};class rM extends ro{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==t4.object)return t8(t,{code:t9.invalid_type,expected:t4.object,received:t.parsedType}),re;let r=this.discriminator,a=t.data[r],n=this.optionsMap.get(a);return n?t.common.async?n._parseAsync({data:t.data,path:t.path,parent:t}):n._parseSync({data:t.data,path:t.path,parent:t}):(t8(t,{code:t9.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),re)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let a=new Map;for(let r of t){let t=rD(r.shape[e]);if(!t.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let n of t){if(a.has(n))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(n)}`);a.set(n,r)}}return new rM({typeName:d.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:a,...rs(r)})}}class rq extends ro{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=(e,a)=>{if("aborted"===e.status||"aborted"===a.status)return re;let n=function e(t,r){let a=t2(t),n=t2(r);if(t===r)return{valid:!0,data:t};if(a===t4.object&&n===t4.object){let a=s.objectKeys(r),n=s.objectKeys(t).filter(e=>-1!==a.indexOf(e)),i={...t,...r};for(let a of n){let n=e(t[a],r[a]);if(!n.valid)return{valid:!1};i[a]=n.data}return{valid:!0,data:i}}if(a===t4.array&&n===t4.array){if(t.length!==r.length)return{valid:!1};let a=[];for(let n=0;n<t.length;n++){let i=e(t[n],r[n]);if(!i.valid)return{valid:!1};a.push(i.data)}return{valid:!0,data:a}}if(a===t4.date&&n===t4.date&&+t==+r)return{valid:!0,data:t};return{valid:!1}}(e.value,a.value);return n.valid?(("dirty"===e.status||"dirty"===a.status)&&t.dirty(),{status:t.value,value:n.data}):(t8(r,{code:t9.invalid_intersection_types}),re)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([e,t])=>a(e,t)):a(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}rq.create=(e,t,r)=>new rq({left:e,right:t,typeName:d.ZodIntersection,...rs(r)});class rB extends ro{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);
15if(r.parsedType!==t4.array)return t8(r,{code:t9.invalid_type,expected:t4.array,received:r.parsedType}),re;if(r.data.length<this._def.items.length)return t8(r,{code:t9.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),re;!this._def.rest&&r.data.length>this._def.items.length&&(t8(r,{code:t9.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());let a=[...r.data].map((e,t)=>{let a=this._def.items[t]||this._def.rest;return a?a._parse(new rn(r,e,r.path,t)):null}).filter(e=>!!e);return r.common.async?Promise.all(a).then(e=>t7.mergeArray(t,e)):t7.mergeArray(t,a)}get items(){return this._def.items}rest(e){return new rB({...this._def,rest:e})}}rB.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new rB({items:e,typeName:d.ZodTuple,rest:null,...rs(t)})};class rz extends ro{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==t4.object)return t8(r,{code:t9.invalid_type,expected:t4.object,received:r.parsedType}),re;let a=[],n=this._def.keyType,i=this._def.valueType;for(let e in r.data)a.push({key:n._parse(new rn(r,e,r.path,e)),value:i._parse(new rn(r,r.data[e],r.path,e)),alwaysSet:e in r.data});return r.common.async?t7.mergeObjectAsync(t,a):t7.mergeObjectSync(t,a)}get element(){return this._def.valueType}static create(e,t,r){return new rz(t instanceof ro?{keyType:e,valueType:t,typeName:d.ZodRecord,...rs(r)}:{keyType:rO.create(),valueType:e,typeName:d.ZodRecord,...rs(t)})}}class rW extends ro{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==t4.map)return t8(r,{code:t9.invalid_type,expected:t4.map,received:r.parsedType}),re;let a=this._def.keyType,n=this._def.valueType,i=[...r.data.entries()].map(([e,t],i)=>({key:a._parse(new rn(r,e,r.path,[i,"key"])),value:n._parse(new rn(r,t,r.path,[i,"value"]))}));if(r.common.async){let e=new Map;return Promise.resolve().then(async()=>{for(let r of i){let a=await r.key,n=await r.value;if("aborted"===a.status||"aborted"===n.status)return re;("dirty"===a.status||"dirty"===n.status)&&t.dirty(),e.set(a.value,n.value)}return{status:t.value,value:e}})}{let e=new Map;for(let r of i){let a=r.key,n=r.value;if("aborted"===a.status||"aborted"===n.status)return re;("dirty"===a.status||"dirty"===n.status)&&t.dirty(),e.set(a.value,n.value)}return{status:t.value,value:e}}}}rW.create=(e,t,r)=>new rW({valueType:t,keyType:e,typeName:d.ZodMap,...rs(r)});class rV extends ro{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==t4.set)return t8(r,{code:t9.invalid_type,expected:t4.set,received:r.parsedType}),re;let a=this._def;null!==a.minSize&&r.data.size<a.minSize.value&&(t8(r,{code:t9.too_small,minimum:a.minSize.value,type:"set",inclusive:!0,exact:!1,message:a.minSize.message}),t.dirty()),null!==a.maxSize&&r.data.size>a.maxSize.value&&(t8(r,{code:t9.too_big,maximum:a.maxSize.value,type:"set",inclusive:!0,exact:!1,message:a.maxSize.message}),t.dirty());let n=this._def.valueType;function i(e){let r=new Set;for(let a of e){if("aborted"===a.status)return re;"dirty"===a.status&&t.dirty(),r.add(a.value)}return{status:t.value,value:r}}let s=[...r.data.values()].map((e,t)=>n._parse(new rn(r,e,r.path,t)));return r.common.async?Promise.all(s).then(e=>i(e)):i(s)}min(e,t){return new rV({...this._def,minSize:{value:e,message:l.toString(t)}})}max(e,t){return new rV({...this._def,maxSize:{value:e,message:l.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}rV.create=(e,t)=>new rV({valueType:e,minSize:null,maxSize:null,typeName:d.ZodSet,...rs(t)});class rK extends ro{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==t4.function)return t8(t,{code:t9.invalid_type,expected:t4.function,received:t.parsedType}),re;function r(e,r){return t6({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,t3,t3].filter(e=>
15!!e),issueData:{code:t9.invalid_arguments,argumentsError:r}})}function a(e,r){return t6({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,t3,t3].filter(e=>!!e),issueData:{code:t9.invalid_return_type,returnTypeError:r}})}let n={errorMap:t.common.contextualErrorMap},i=t.data;if(this._def.returns instanceof rY){let e=this;return rr(async function(...t){let s=new t5([]),o=await e._def.args.parseAsync(t,n).catch(e=>{throw s.addIssue(r(t,e)),s}),l=await Reflect.apply(i,this,o);return await e._def.returns._def.type.parseAsync(l,n).catch(e=>{throw s.addIssue(a(l,e)),s})})}{let e=this;return rr(function(...t){let s=e._def.args.safeParse(t,n);if(!s.success)throw new t5([r(t,s.error)]);let o=Reflect.apply(i,this,s.data),l=e._def.returns.safeParse(o,n);if(!l.success)throw new t5([a(o,l.error)]);return l.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new rK({...this._def,args:rB.create(e).rest(rL.create())})}returns(e){return new rK({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new rK({args:e||rB.create([]).rest(rL.create()),returns:t||rL.create(),typeName:d.ZodFunction,...rs(r)})}}class rH extends ro{get schema(){return this._def.getter()}_parse(e){let{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}rH.create=(e,t)=>new rH({getter:e,typeName:d.ZodLazy,...rs(t)});class rQ extends ro{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return t8(t,{received:t.data,code:t9.invalid_literal,expected:this._def.value}),re}return{status:"valid",value:e.data}}get value(){return this._def.value}}function rJ(e,t){return new rG({values:e,typeName:d.ZodEnum,...rs(t)})}rQ.create=(e,t)=>new rQ({value:e,typeName:d.ZodLiteral,...rs(t)});class rG extends ro{_parse(e){if("string"!=typeof e.data){let t=this._getOrReturnCtx(e),r=this._def.values;return t8(t,{expected:s.joinValues(r),received:t.parsedType,code:t9.invalid_type}),re}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return t8(t,{received:t.data,code:t9.invalid_enum_value,options:r}),re}return rr(e.data)}get options(){return this._def.values}get enum(){let e={};for(let t of this._def.values)e[t]=t;return e}get Values(){let e={};for(let t of this._def.values)e[t]=t;return e}get Enum(){let e={};for(let t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return rG.create(e,{...this._def,...t})}exclude(e,t=this._def){return rG.create(this.options.filter(t=>!e.includes(t)),{...this._def,...t})}}rG.create=rJ;class rX extends ro{_parse(e){let t=s.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==t4.string&&r.parsedType!==t4.number){let e=s.objectValues(t);return t8(r,{expected:s.joinValues(e),received:r.parsedType,code:t9.invalid_type}),re}if(this._cache||(this._cache=new Set(s.getValidEnumValues(this._def.values))),!this._cache.has(e.data)){let e=s.objectValues(t);return t8(r,{received:r.data,code:t9.invalid_enum_value,options:e}),re}return rr(e.data)}get enum(){return this._def.values}}rX.create=(e,t)=>new rX({values:e,typeName:d.ZodNativeEnum,...rs(t)});class rY extends ro{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);return t.parsedType!==t4.promise&&!1===t.common.async?(t8(t,{code:t9.invalid_type,expected:t4.promise,received:t.parsedType}),re):rr((t.parsedType===t4.promise?t.data:Promise.resolve(t.data)).then(e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap})))}}rY.create=(e,t)=>new rY({type:e,typeName:d.ZodPromise,...rs(t)});class r0 extends ro{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===d.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),a=this._def.effect||null,n={addIssue:e=>{t8(r,e),e.fatal?t.abort():t.dirty()},get path(){return r.path}};if(n.addIssue=n.addIssue.bind(n),"preprocess"===a.type){let e=a.transform(r.data,n);if(r.common.async)return Promise.resolve(e).then(async e=>{if("aborted"===t.value)return re;let a=await this._def.schema._parseAsync({data:e,path:r.path,parent:r});return"aborted"===a.status?re:"dirty"===a.status||"dirty"===t.value?rt(a.value):a});{if("aborted"===t.value)return re;let a=this._def.schema._parseSync({data:e,path:r.path,parent:r});return"aborted"===a.status?re:"dirty"===a.status||"dirty"===t.value?rt(a.value):a}}if("refinement"===a.type){let e=e=>{let t=a.refinement(e,n);if(r.common.async)return Promise.resolve(t);if(t instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(r=>"aborted"===r.status?re:("dirty"===r.status&&t.dirty(),e(r.value).then(()=>({status:t.value,value:r.value}))));{let a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===a.status?re:("dirty"===a.status&&t.dirty(),e(a.value),{status:t.value,value:a.value})}}if("transform"===a.type)if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(e=>"valid"!==e.status?re:Promise.resolve(a.transform(e.value,n)).then(e=>({status:t.value,value:e})));else{let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if("valid"!==e.status)return re;let i=a.transform(e.value,n);if(i instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:i}}s.assertNever(a)}}r0.create=(e,t,r)=>new r0({schema:e,typeName:d.ZodEffects,effect:t,...rs(r)}),r0.createWithPreprocess=(e,t,r)=>new r0({schema:t,effect:{type:"preprocess",transform:e},typeName:d.ZodEffects,...rs(r)});class r1 extends ro{_parse(e){return this._getType(e)===t4.undefined?rr(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}r1.create=(e,t)=>
15new r1({innerType:e,typeName:d.ZodOptional,...rs(t)});class r4 extends ro{_parse(e){return this._getType(e)===t4.null?rr(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}r4.create=(e,t)=>new r4({innerType:e,typeName:d.ZodNullable,...rs(t)});class r2 extends ro{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return t.parsedType===t4.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}r2.create=(e,t)=>new r2({innerType:e,typeName:d.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...rs(t)});class r9 extends ro{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},a=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return ra(a)?a.then(e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new t5(r.common.issues)},input:r.data})})):{status:"valid",value:"valid"===a.status?a.value:this._def.catchValue({get error(){return new t5(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}r9.create=(e,t)=>new r9({innerType:e,typeName:d.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...rs(t)});class r5 extends ro{_parse(e){if(this._getType(e)!==t4.nan){let t=this._getOrReturnCtx(e);return t8(t,{code:t9.invalid_type,expected:t4.nan,received:t.parsedType}),re}return{status:"valid",value:e.data}}}r5.create=e=>new r5({typeName:d.ZodNaN,...rs(e)}),Symbol("zod_brand");class r3 extends ro{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return this._def.type._parse({data:r,path:t.path,parent:t})}unwrap(){return this._def.type}}class r6 extends ro{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let e=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?re:"dirty"===e.status?(t.dirty(),rt(e.value)):this._def.out._parseAsync({data:e.value,path:r.path,parent:r})})();{let e=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?re:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:r.path,parent:r})}}static create(e,t){return new r6({in:e,out:t,typeName:d.ZodPipeline})}}class r8 extends ro{_parse(e){let t=this._def.innerType._parse(e),r=e=>("valid"===e.status&&(e.value=Object.freeze(e.value)),e);return ra(t)?t.then(e=>r(e)):r(t)}unwrap(){return this._def.innerType}}r8.create=(e,t)=>new r8({innerType:e,typeName:d.ZodReadonly,...rs(t)}),r$.lazycreate,function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"}(d||(d={}));let r7=rO.create,ae=rR.create;r5.create,rS.create;let at=rT.create;rA.create,rC.create,rN.create,rj.create,rP.create,rL.create,rZ.create;let ar=rI.create,aa=rU.create,an=r$.create;r$.strictCreate,rF.create,rM.create,rq.create,rB.create;let ai=rz.create;rW.create,rV.create,rK.create,rH.create,rQ.create;let as=rG.create;rX.create,rY.create,r0.create,r1.create,r4.create,r0.createWithPreprocess,r6.create;let ao=as(["crypto","fx","equity","metal","rates","crypto_redemption_rate","commodities","crypto_index","crypto_nav"]).nullish(),al=r7(),ad=an({attributes:ai(r7()),id:al}
15).passthrough(),au=r7(),ac=as(["hex","base64"]),ah=an({data:aa(r7()),encoding:ac}).passthrough(),ap=an({conf:r7(),expo:ae().int(),price:r7(),publish_time:ae().int()}).passthrough(),af=an({prev_publish_time:ae().int().nullable(),proof_available_time:ae().int().nullable(),slot:ae().int().gte(0).nullable()}).partial().passthrough(),am=an({ema_price:ap,id:al,metadata:af,price:ap}).passthrough(),ay=an({binary:ah,parsed:aa(am).nullish()}).passthrough(),ag=an({cap:ae().int().gte(0),publisher:r7()}).passthrough(),av=an({publisher_stake_caps:aa(ag)}).passthrough(),a_=an({binary:ah,parsed:aa(av).nullish()}).passthrough(),ab=an({down_slots_ratio:r7(),end_timestamp:ae().int(),id:al,start_timestamp:ae().int(),twap:ap}).passthrough(),aw=an({binary:ah,parsed:aa(ab).nullish()}).passthrough(),ak={PriceFeedMetadata:ad,PriceUpdate:ay,LatestPublisherStakeCapsUpdateDataResponse:a_,TwapsResponse:aw};new t1(function(e){return t0(e),e}([{method:"get",path:"/v2/price_feeds",alias:"price_feeds_metadata",description:`Get the set of price feeds. 16 17This endpoint fetches all price feeds from the Pyth network. It can be filtered by asset type 18and query string.`,requestFormat:"json",parameters:[{name:"query",type:"Query",schema:r7().nullish()},{name:"asset_type",type:"Query",schema:ao}],response:aa(ad)}
18,{method:"get",path:"/v2/updates/price/:publish_time",alias:"timestamp_price_updates",description:`Get the latest price updates by price feed id. 19 20Given a collection of price feed ids, retrieve the latest Pyth price for each price feed.`,requestFormat:"json",parameters:[{name:"publish_time",type:"Path",schema:ae().int()},{name:"ids[]",type:"Query",schema:aa(au)},{name:"encoding",type:"Query",schema:as(["hex","base64"]).optional()},{name:"parsed",type:"Query",schema:at().optional()},{name:"ignore_invalid_price_ids",type:"Query",schema:at().optional()}],response:ay,errors:[{status:404,description:"Price ids not found",schema:ar()}]},{method:"get",path:"/v2/updates/price/latest",alias:"latest_price_updates",description:`Get the latest price updates by price feed id. 21 22Given a collection of price feed ids, retrieve the latest Pyth price for each price feed.`,requestFormat:"json",parameters:[{name:"ids[]",type:"Query",schema:aa(au)},{name:"encoding",type:"Query",schema:as(["hex","base64"]).optional()},{name:"parsed",type:"Query",schema:at().optional()},{name:"ignore_invalid_price_ids",type:"Query",schema:at().optional()}],response:ay,errors:[{status:404,description:"Price ids not found",schema:ar()}]},{method:"get",path:"/v2/updates/price/stream",alias:"price_stream_sse_handler",description:`SSE route handler for streaming price updates. 23 24The connection will automatically close after 24 hours to prevent resource leaks. 25Clients should implement reconnection logic to maintain continuous price updates.`,requestFormat:"json",parameters:[{name:"ids[]",type:"Query",schema:aa(au)},{name:"encoding",type:"Query",schema:as(["hex","base64"]).optional()},{name:"parsed",type:"Query",schema:at().optional()},{name:"allow_unordered",type:"Query",schema:at().optional()},{name:"benchmarks_only",type:"Query",schema:at().optional()},{name:"ignore_invalid_price_ids",type:"Query",schema:at().optional()}],response:ay,errors:[{status:404,description:"Price ids not found",schema:ar()}]},{method:"get",path:"/v2/updates/publisher_stake_caps/latest",alias:"latest_publisher_stake_caps",description:"Get the most recent publisher stake caps update data.",requestFormat:"json",parameters:[{name:"encoding",type:"Query",schema:as(["hex","base64"]).optional()},{name:"parsed",type:"Query",schema:at().optional()}],response:a_},{method:"get",path:"/v2/updates/twap/:window_seconds/latest",alias:"latest_twaps",description:`Get the latest TWAP by price feed id with a custom time window. 26
27Given a collection of price feed ids, retrieve the latest Pyth TWAP price for each price feed.`,requestFormat:"json",parameters:[{name:"window_seconds",type:"Path",schema:ae().int().gte(0)},{name:"ids[]",type:"Query",schema:aa(au)},{name:"encoding",type:"Query",schema:as(["hex","base64"]).optional()},{name:"parsed",type:"Query",schema:at().optional()},{name:"ignore_invalid_price_ids",type:"Query",schema:at().optional()}],response:aw,errors:[{status:404,description:"Price ids not found",schema:ar()}]}]));class ax{baseURL;timeout;httpRetries;headers;constructor(e,t){this.baseURL=e,this.timeout=t?.timeout??5e3,this.httpRetries=t?.httpRetries??3,this.headers=t?.headers??{}}async httpRequest(e,t,r,a=this.httpRetries,n=100+Math.floor(100*Math.random())){try{let a=await fetch(e,{...r,signal:AbortSignal.any([...r?.signal?[r.signal]:[],AbortSignal.timeout(this.timeout)]),headers:{...this.headers,...r?.headers}});if(!a.ok){let e=await a.text();throw Error(`HTTP error! status: ${a.status.toString()}${e?`, body: ${e}`:""}`)}let n=await a.json();return t.parse(n)}catch(i){if(a>0&&!(i instanceof Error&&"AbortError"===i.name))return await new Promise(e=>setTimeout(e,n)),this.httpRequest(e,t,r,a-1,2*n);throw i}}async getPriceFeeds({fetchOptions:e,...t}={}){let r=this.buildURL("price_feeds");if(t){let e=K(t);this.appendUrlSearchParams(r,e)}return await this.httpRequest(r.toString(),ak.PriceFeedMetadata.array(),e)}async getLatestPublisherCaps({fetchOptions:e,...t}={}){let r=this.buildURL("updates/publisher_stake_caps/latest");return t&&this.appendUrlSearchParams(r,t),await this.httpRequest(r.toString(),ak.LatestPublisherStakeCapsUpdateDataResponse,e)}async getLatestPriceUpdates(e,t,r){let a=this.buildURL("updates/price/latest");for(let t of e)a.searchParams.append("ids[]",t);if(t){let e=K(t);this.appendUrlSearchParams(a,e)}return this.httpRequest(a.toString(),ak.PriceUpdate,r)}async getPriceUpdatesAtTimestamp(e,t,r,a){let n=this.buildURL(`updates/price/${e.toString()}`);for(let e of t)n.searchParams.append("ids[]",e);if(r){let e=K(r);this.appendUrlSearchParams(n,e)}return this.httpRequest(n.toString(),ak.PriceUpdate,a)}async getPriceUpdatesStream(e,t){let r=this.buildURL("updates/price/stream");for(let t of e)r.searchParams.append("ids[]",t);if(t){let e=K(t);this.appendUrlSearchParams(r,e)}return new V(r.toString(),{fetch:(e,t)=>fetch(e,{...t,headers:{...t?.headers,...this.headers}})})}async getLatestTwaps(e,t,r,a){let n=this.buildURL(`updates/twap/${t.toString()}/latest`);for(let t of e)n.searchParams.append("ids[]",t);if(r){let e=K(r);this.appendUrlSearchParams(n,e)}return this.httpRequest(n.toString(),ak.TwapsResponse,a)}appendUrlSearchParams(e,t){for(let[r,a]of Object.entries(t))void 0!==a&&e.searchParams.append(r,String(a))}buildURL(e){return new URL(`./v2/${e}`,`${this.baseURL}${this.baseURL.endsWith("/")?"":"/"}`)}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.