figura-cli 0.26.0 → 0.26.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +186 -185
- package/dist/mcp.js +43 -42
- package/package.json +1 -1
package/dist/mcp.js
CHANGED
|
@@ -1,71 +1,72 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{createRequire as _T}from"node:module";var dT=Object.create;var{getPrototypeOf:mT,defineProperty:Zc,getOwnPropertyNames:fT}=Object;var hT=Object.prototype.hasOwnProperty;function gT(e){return this[e]}var xT,vT,jo=(e,t,r)=>{var n=e!=null&&typeof e==="object";if(n){var o=t?xT??=new WeakMap:vT??=new WeakMap,i=o.get(e);if(i)return i}r=e!=null?dT(mT(e)):{};let s=t||!e||!e.__esModule?Zc(r,"default",{value:e,enumerable:!0}):r;if(e&&typeof e==="object"||typeof e==="function"){for(let a of fT(e))if(!hT.call(s,a))Zc(s,a,{get:gT.bind(e,a),enumerable:!0})}if(n)o.set(e,s);return s};var _=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var yT=(e)=>e;function bT(e,t){this[e]=yT.bind(null,t)}var No=(e,t)=>{for(var r in t)Zc(e,r,{get:t[r],enumerable:!0,configurable:!0,set:bT.bind(t,r)})};var bs=(e,t)=>()=>(e&&(t=e(e=0)),t);var ge=_T(import.meta.url);var Bf=_(function(XZ,Zf){var Ff=ge("stream").Stream,SE=ge("util");Zf.exports=Mt;function Mt(){this.source=null,this.dataSize=0,this.maxDataSize=1048576,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}SE.inherits(Mt,Ff);Mt.create=function(e,t){var r=new this;t=t||{};for(var n in t)r[n]=t[n];r.source=e;var o=e.emit;if(e.emit=function(){return r._handleEmit(arguments),o.apply(e,arguments)},e.on("error",function(){}),r.pauseStream)e.pause();return r};Object.defineProperty(Mt.prototype,"readable",{configurable:!0,enumerable:!0,get:function(){return this.source.readable}});Mt.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};Mt.prototype.resume=function(){if(!this._released)this.release();this.source.resume()};Mt.prototype.pause=function(){this.source.pause()};Mt.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};Mt.prototype.pipe=function(){var e=Ff.prototype.pipe.apply(this,arguments);return this.resume(),e};Mt.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data")this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded();this._bufferedEvents.push(e)};Mt.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded)return;if(this.dataSize<=this.maxDataSize)return;this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",Error(e))}});var Jf=_(function(QZ,Gf){var $E=ge("util"),Vf=ge("stream").Stream,Hf=Bf();Gf.exports=Ie;function Ie(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2097152,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}$E.inherits(Ie,Vf);Ie.create=function(e){var t=new this;e=e||{};for(var r in e)t[r]=e[r];return t};Ie.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};Ie.prototype.append=function(e){var t=Ie.isStreamLike(e);if(t){if(!(e instanceof Hf)){var r=Hf.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=r}if(this._handleErrors(e),this.pauseStreams)e.pause()}return this._streams.push(e),this};Ie.prototype.pipe=function(e,t){return Vf.prototype.pipe.call(this,e,t),this.resume(),e};Ie.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop){this._pendingNext=!0;return}this._insideLoop=!0;try{do this._pendingNext=!1,this._realGetNext();while(this._pendingNext)}finally{this._insideLoop=!1}};Ie.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e>"u"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(r){var n=Ie.isStreamLike(r);if(n)r.on("data",this._checkDataSize.bind(this)),this._handleErrors(r);this._pipeNext(r)}.bind(this))};Ie.prototype._pipeNext=function(e){this._currentStream=e;var t=Ie.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this)),e.pipe(this,{end:!1});return}var r=e;this.write(r),this._getNext()};Ie.prototype._handleErrors=function(e){var t=this;e.on("error",function(r){t._emitError(r)})};Ie.prototype.write=function(e){this.emit("data",e)};Ie.prototype.pause=function(){if(!this.pauseStreams)return;if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};Ie.prototype.resume=function(){if(!this._released)this._released=!0,this.writable=!0,this._getNext();if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};Ie.prototype.end=function(){this._reset(),this.emit("end")};Ie.prototype.destroy=function(){this._reset(),this.emit("close")};Ie.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};Ie.prototype._checkDataSize=function(){if(this._updateDataSize(),this.dataSize<=this.maxDataSize)return;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(Error(e))};Ie.prototype._updateDataSize=function(){this.dataSize=0;var e=this;if(this._streams.forEach(function(t){if(!t.dataSize)return;e.dataSize+=t.dataSize}),this._currentStream&&this._currentStream.dataSize)this.dataSize+=this._currentStream.dataSize};Ie.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var Wf=_(function(e9,TE){TE.exports={"application/1d-interleaved-parityfec":{source:"iana"},"application/3gpdash-qoe-report+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/3gpp-ims+xml":{source:"iana",compressible:!0},"application/3gpphal+json":{source:"iana",compressible:!0},"application/3gpphalforms+json":{source:"iana",compressible:!0},"application/a2l":{source:"iana"},"application/ace+cbor":{source:"iana"},"application/activemessage":{source:"iana"},"application/activity+json":{source:"iana",compressible:!0},"application/alto-costmap+json":{source:"iana",compressible:!0},"application/alto-costmapfilter+json":{source:"iana",compressible:!0},"application/alto-directory+json":{source:"iana",compressible:!0},"application/alto-endpointcost+json":{source:"iana",compressible:!0},"application/alto-endpointcostparams+json":{source:"iana",compressible:!0},"application/alto-endpointprop+json":{source:"iana",compressible:!0},"application/alto-endpointpropparams+json":{source:"iana",compressible:!0},"application/alto-error+json":{source:"iana",compressible:!0},"application/alto-networkmap+json":{source:"iana",compressible:!0},"application/alto-networkmapfilter+json":{source:"iana",compressible:!0},"application/alto-updatestreamcontrol+json":{source:"iana",compressible:!0},"application/alto-updatestreamparams+json":{source:"iana",compressible:!0},"application/aml":{source:"iana"},"application/andrew-inset":{source:"iana",extensions:["ez"]},"application/applefile":{source:"iana"},"application/applixware":{source:"apache",extensions:["aw"]},"application/at+jwt":{source:"iana"},"application/atf":{source:"iana"},"application/atfx":{source:"iana"},"application/atom+xml":{source:"iana",compressible:!0,extensions:["atom"]},"application/atomcat+xml":{source:"iana",compressible:!0,extensions:["atomcat"]},"application/atomdeleted+xml":{source:"iana",compressible:!0,extensions:["atomdeleted"]},"application/atomicmail":{source:"iana"},"application/atomsvc+xml":{source:"iana",compressible:!0,extensions:["atomsvc"]},"application/atsc-dwd+xml":{source:"iana",compressible:!0,extensions:["dwd"]},"application/atsc-dynamic-event-message":{source:"iana"},"application/atsc-held+xml":{source:"iana",compressible:!0,extensions:["held"]},"application/atsc-rdt+json":{source:"iana",compressible:!0},"application/atsc-rsat+xml":{source:"iana",compressible:!0,extensions:["rsat"]},"application/atxml":{source:"iana"},"application/auth-policy+xml":{source:"iana",compressible:!0},"application/bacnet-xdd+zip":{source:"iana",compressible:!1},"application/batch-smtp":{source:"iana"},"application/bdoc":{compressible:!1,extensions:["bdoc"]},"application/beep+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/calendar+json":{source:"iana",compressible:!0},"application/calendar+xml":{source:"iana",compressible:!0,extensions:["xcs"]},"application/call-completion":{source:"iana"},"application/cals-1840":{source:"iana"},"application/captive+json":{source:"iana",compressible:!0},"application/cbor":{source:"iana"},"application/cbor-seq":{source:"iana"},"application/cccex":{source:"iana"},"application/ccmp+xml":{source:"iana",compressible:!0},"application/ccxml+xml":{source:"iana",compressible:!0,extensions:["ccxml"]},"application/cdfx+xml":{source:"iana",compressible:!0,extensions:["cdfx"]},"application/cdmi-capability":{source:"iana",extensions:["cdmia"]},"application/cdmi-container":{source:"iana",extensions:["cdmic"]},"application/cdmi-domain":{source:"iana",extensions:["cdmid"]},"application/cdmi-object":{source:"iana",extensions:["cdmio"]},"application/cdmi-queue":{source:"iana",extensions:["cdmiq"]},"application/cdni":{source:"iana"},"application/cea":{source:"iana"},"application/cea-2018+xml":{source:"iana",compressible:!0},"application/cellml+xml":{source:"iana",compressible:!0},"application/cfw":{source:"iana"},"application/city+json":{source:"iana",compressible:!0},"application/clr":{source:"iana"},"application/clue+xml":{source:"iana",compressible:!0},"application/clue_info+xml":{source:"iana",compressible:!0},"application/cms":{source:"iana"},"application/cnrp+xml":{source:"iana",compressible:!0},"application/coap-group+json":{source:"iana",compressible:!0},"application/coap-payload":{source:"iana"},"application/commonground":{source:"iana"},"application/conference-info+xml":{source:"iana",compressible:!0},"application/cose":{source:"iana"},"application/cose-key":{source:"iana"},"application/cose-key-set":{source:"iana"},"application/cpl+xml":{source:"iana",compressible:!0,extensions:["cpl"]},"application/csrattrs":{source:"iana"},"application/csta+xml":{source:"iana",compressible:!0},"application/cstadata+xml":{source:"iana",compressible:!0},"application/csvm+json":{source:"iana",compressible:!0},"application/cu-seeme":{source:"apache",extensions:["cu"]},"application/cwt":{source:"iana"},"application/cybercash":{source:"iana"},"application/dart":{compressible:!0},"application/dash+xml":{source:"iana",compressible:!0,extensions:["mpd"]},"application/dash-patch+xml":{source:"iana",compressible:!0,extensions:["mpp"]},"application/dashdelta":{source:"iana"},"application/davmount+xml":{source:"iana",compressible:!0,extensions:["davmount"]},"application/dca-rft":{source:"iana"},"application/dcd":{source:"iana"},"application/dec-dx":{source:"iana"},"application/dialog-info+xml":{source:"iana",compressible:!0},"application/dicom":{source:"iana"},"application/dicom+json":{source:"iana",compressible:!0},"application/dicom+xml":{source:"iana",compressible:!0},"application/dii":{source:"iana"},"application/dit":{source:"iana"},"application/dns":{source:"iana"},"application/dns+json":{source:"iana",compressible:!0},"application/dns-message":{source:"iana"},"application/docbook+xml":{source:"apache",compressible:!0,extensions:["dbk"]},"application/dots+cbor":{source:"iana"},"application/dskpp+xml":{source:"iana",compressible:!0},"application/dssc+der":{source:"iana",extensions:["dssc"]},"application/dssc+xml":{source:"iana",compressible:!0,extensions:["xdssc"]},"application/dvcs":{source:"iana"},"application/ecmascript":{source:"iana",compressible:!0,extensions:["es","ecma"]},"application/edi-consent":{source:"iana"},"application/edi-x12":{source:"iana",compressible:!1},"application/edifact":{source:"iana",compressible:!1},"application/efi":{source:"iana"},"application/elm+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/elm+xml":{source:"iana",compressible:!0},"application/emergencycalldata.cap+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/emergencycalldata.comment+xml":{source:"iana",compressible:!0},"application/emergencycalldata.control+xml":{source:"iana",compressible:!0},"application/emergencycalldata.deviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.ecall.msd":{source:"iana"},"application/emergencycalldata.providerinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.serviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.subscriberinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.veds+xml":{source:"iana",compressible:!0},"application/emma+xml":{source:"iana",compressible:!0,extensions:["emma"]},"application/emotionml+xml":{source:"iana",compressible:!0,extensions:["emotionml"]},"application/encaprtp":{source:"iana"},"application/epp+xml":{source:"iana",compressible:!0},"application/epub+zip":{source:"iana",compressible:!1,extensions:["epub"]},"application/eshop":{source:"iana"},"application/exi":{source:"iana",extensions:["exi"]},"application/expect-ct-report+json":{source:"iana",compressible:!0},"application/express":{source:"iana",extensions:["exp"]},"application/fastinfoset":{source:"iana"},"application/fastsoap":{source:"iana"},"application/fdt+xml":{source:"iana",compressible:!0,extensions:["fdt"]},"application/fhir+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/fhir+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/fido.trusted-apps+json":{compressible:!0},"application/fits":{source:"iana"},"application/flexfec":{source:"iana"},"application/font-sfnt":{source:"iana"},"application/font-tdpfr":{source:"iana",extensions:["pfr"]},"application/font-woff":{source:"iana",compressible:!1},"application/framework-attributes+xml":{source:"iana",compressible:!0},"application/geo+json":{source:"iana",compressible:!0,extensions:["geojson"]},"application/geo+json-seq":{source:"iana"},"application/geopackage+sqlite3":{source:"iana"},"application/geoxacml+xml":{source:"iana",compressible:!0},"application/gltf-buffer":{source:"iana"},"application/gml+xml":{source:"iana",compressible:!0,extensions:["gml"]},"application/gpx+xml":{source:"apache",compressible:!0,extensions:["gpx"]},"application/gxf":{source:"apache",extensions:["gxf"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/h224":{source:"iana"},"application/held+xml":{source:"iana",compressible:!0},"application/hjson":{extensions:["hjson"]},"application/http":{source:"iana"},"application/hyperstudio":{source:"iana",extensions:["stk"]},"application/ibe-key-request+xml":{source:"iana",compressible:!0},"application/ibe-pkg-reply+xml":{source:"iana",compressible:!0},"application/ibe-pp-data":{source:"iana"},"application/iges":{source:"iana"},"application/im-iscomposing+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/index":{source:"iana"},"application/index.cmd":{source:"iana"},"application/index.obj":{source:"iana"},"application/index.response":{source:"iana"},"application/index.vnd":{source:"iana"},"application/inkml+xml":{source:"iana",compressible:!0,extensions:["ink","inkml"]},"application/iotp":{source:"iana"},"application/ipfix":{source:"iana",extensions:["ipfix"]},"application/ipp":{source:"iana"},"application/isup":{source:"iana"},"application/its+xml":{source:"iana",compressible:!0,extensions:["its"]},"application/java-archive":{source:"apache",compressible:!1,extensions:["jar","war","ear"]},"application/java-serialized-object":{source:"apache",compressible:!1,extensions:["ser"]},"application/java-vm":{source:"apache",compressible:!1,extensions:["class"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/jf2feed+json":{source:"iana",compressible:!0},"application/jose":{source:"iana"},"application/jose+json":{source:"iana",compressible:!0},"application/jrd+json":{source:"iana",compressible:!0},"application/jscalendar+json":{source:"iana",compressible:!0},"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/json-patch+json":{source:"iana",compressible:!0},"application/json-seq":{source:"iana"},"application/json5":{extensions:["json5"]},"application/jsonml+json":{source:"apache",compressible:!0,extensions:["jsonml"]},"application/jwk+json":{source:"iana",compressible:!0},"application/jwk-set+json":{source:"iana",compressible:!0},"application/jwt":{source:"iana"},"application/kpml-request+xml":{source:"iana",compressible:!0},"application/kpml-response+xml":{source:"iana",compressible:!0},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/lgr+xml":{source:"iana",compressible:!0,extensions:["lgr"]},"application/link-format":{source:"iana"},"application/load-control+xml":{source:"iana",compressible:!0},"application/lost+xml":{source:"iana",compressible:!0,extensions:["lostxml"]},"application/lostsync+xml":{source:"iana",compressible:!0},"application/lpf+zip":{source:"iana",compressible:!1},"application/lxf":{source:"iana"},"application/mac-binhex40":{source:"iana",extensions:["hqx"]},"application/mac-compactpro":{source:"apache",extensions:["cpt"]},"application/macwriteii":{source:"iana"},"application/mads+xml":{source:"iana",compressible:!0,extensions:["mads"]},"application/manifest+json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/marc":{source:"iana",extensions:["mrc"]},"application/marcxml+xml":{source:"iana",compressible:!0,extensions:["mrcx"]},"application/mathematica":{source:"iana",extensions:["ma","nb","mb"]},"application/mathml+xml":{source:"iana",compressible:!0,extensions:["mathml"]},"application/mathml-content+xml":{source:"iana",compressible:!0},"application/mathml-presentation+xml":{source:"iana",compressible:!0},"application/mbms-associated-procedure-description+xml":{source:"iana",compressible:!0},"application/mbms-deregister+xml":{source:"iana",compressible:!0},"application/mbms-envelope+xml":{source:"iana",compressible:!0},"application/mbms-msk+xml":{source:"iana",compressible:!0},"application/mbms-msk-response+xml":{source:"iana",compressible:!0},"application/mbms-protection-description+xml":{source:"iana",compressible:!0},"application/mbms-reception-report+xml":{source:"iana",compressible:!0},"application/mbms-register+xml":{source:"iana",compressible:!0},"application/mbms-register-response+xml":{source:"iana",compressible:!0},"application/mbms-schedule+xml":{source:"iana",compressible:!0},"application/mbms-user-service-description+xml":{source:"iana",compressible:!0},"application/mbox":{source:"iana",extensions:["mbox"]},"application/media-policy-dataset+xml":{source:"iana",compressible:!0,extensions:["mpf"]},"application/media_control+xml":{source:"iana",compressible:!0},"application/mediaservercontrol+xml":{source:"iana",compressible:!0,extensions:["mscml"]},"application/merge-patch+json":{source:"iana",compressible:!0},"application/metalink+xml":{source:"apache",compressible:!0,extensions:["metalink"]},"application/metalink4+xml":{source:"iana",compressible:!0,extensions:["meta4"]},"application/mets+xml":{source:"iana",compressible:!0,extensions:["mets"]},"application/mf4":{source:"iana"},"application/mikey":{source:"iana"},"application/mipc":{source:"iana"},"application/missing-blocks+cbor-seq":{source:"iana"},"application/mmt-aei+xml":{source:"iana",compressible:!0,extensions:["maei"]},"application/mmt-usd+xml":{source:"iana",compressible:!0,extensions:["musd"]},"application/mods+xml":{source:"iana",compressible:!0,extensions:["mods"]},"application/moss-keys":{source:"iana"},"application/moss-signature":{source:"iana"},"application/mosskey-data":{source:"iana"},"application/mosskey-request":{source:"iana"},"application/mp21":{source:"iana",extensions:["m21","mp21"]},"application/mp4":{source:"iana",extensions:["mp4s","m4p"]},"application/mpeg4-generic":{source:"iana"},"application/mpeg4-iod":{source:"iana"},"application/mpeg4-iod-xmt":{source:"iana"},"application/mrb-consumer+xml":{source:"iana",compressible:!0},"application/mrb-publish+xml":{source:"iana",compressible:!0},"application/msc-ivr+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msc-mixer+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msword":{source:"iana",compressible:!1,extensions:["doc","dot"]},"application/mud+json":{source:"iana",compressible:!0},"application/multipart-core":{source:"iana"},"application/mxf":{source:"iana",extensions:["mxf"]},"application/n-quads":{source:"iana",extensions:["nq"]},"application/n-triples":{source:"iana",extensions:["nt"]},"application/nasdata":{source:"iana"},"application/news-checkgroups":{source:"iana",charset:"US-ASCII"},"application/news-groupinfo":{source:"iana",charset:"US-ASCII"},"application/news-transmission":{source:"iana"},"application/nlsml+xml":{source:"iana",compressible:!0},"application/node":{source:"iana",extensions:["cjs"]},"application/nss":{source:"iana"},"application/oauth-authz-req+jwt":{source:"iana"},"application/oblivious-dns-message":{source:"iana"},"application/ocsp-request":{source:"iana"},"application/ocsp-response":{source:"iana"},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{source:"iana",extensions:["oda"]},"application/odm+xml":{source:"iana",compressible:!0},"application/odx":{source:"iana"},"application/oebps-package+xml":{source:"iana",compressible:!0,extensions:["opf"]},"application/ogg":{source:"iana",compressible:!1,extensions:["ogx"]},"application/omdoc+xml":{source:"apache",compressible:!0,extensions:["omdoc"]},"application/onenote":{source:"apache",extensions:["onetoc","onetoc2","onetmp","onepkg"]},"application/opc-nodeset+xml":{source:"iana",compressible:!0},"application/oscore":{source:"iana"},"application/oxps":{source:"iana",extensions:["oxps"]},"application/p21":{source:"iana"},"application/p21+zip":{source:"iana",compressible:!1},"application/p2p-overlay+xml":{source:"iana",compressible:!0,extensions:["relo"]},"application/parityfec":{source:"iana"},"application/passport":{source:"iana"},"application/patch-ops-error+xml":{source:"iana",compressible:!0,extensions:["xer"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/pdx":{source:"iana"},"application/pem-certificate-chain":{source:"iana"},"application/pgp-encrypted":{source:"iana",compressible:!1,extensions:["pgp"]},"application/pgp-keys":{source:"iana",extensions:["asc"]},"application/pgp-signature":{source:"iana",extensions:["asc","sig"]},"application/pics-rules":{source:"apache",extensions:["prf"]},"application/pidf+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pidf-diff+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pkcs10":{source:"iana",extensions:["p10"]},"application/pkcs12":{source:"iana"},"application/pkcs7-mime":{source:"iana",extensions:["p7m","p7c"]},"application/pkcs7-signature":{source:"iana",extensions:["p7s"]},"application/pkcs8":{source:"iana",extensions:["p8"]},"application/pkcs8-encrypted":{source:"iana"},"application/pkix-attr-cert":{source:"iana",extensions:["ac"]},"application/pkix-cert":{source:"iana",extensions:["cer"]},"application/pkix-crl":{source:"iana",extensions:["crl"]},"application/pkix-pkipath":{source:"iana",extensions:["pkipath"]},"application/pkixcmp":{source:"iana",extensions:["pki"]},"application/pls+xml":{source:"iana",compressible:!0,extensions:["pls"]},"application/poc-settings+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/postscript":{source:"iana",compressible:!0,extensions:["ai","eps","ps"]},"application/ppsp-tracker+json":{source:"iana",compressible:!0},"application/problem+json":{source:"iana",compressible:!0},"application/problem+xml":{source:"iana",compressible:!0},"application/provenance+xml":{source:"iana",compressible:!0,extensions:["provx"]},"application/prs.alvestrand.titrax-sheet":{source:"iana"},"application/prs.cww":{source:"iana",extensions:["cww"]},"application/prs.cyn":{source:"iana",charset:"7-BIT"},"application/prs.hpub+zip":{source:"iana",compressible:!1},"application/prs.nprend":{source:"iana"},"application/prs.plucker":{source:"iana"},"application/prs.rdf-xml-crypt":{source:"iana"},"application/prs.xsf+xml":{source:"iana",compressible:!0},"application/pskc+xml":{source:"iana",compressible:!0,extensions:["pskcxml"]},"application/pvd+json":{source:"iana",compressible:!0},"application/qsig":{source:"iana"},"application/raml+yaml":{compressible:!0,extensions:["raml"]},"application/raptorfec":{source:"iana"},"application/rdap+json":{source:"iana",compressible:!0},"application/rdf+xml":{source:"iana",compressible:!0,extensions:["rdf","owl"]},"application/reginfo+xml":{source:"iana",compressible:!0,extensions:["rif"]},"application/relax-ng-compact-syntax":{source:"iana",extensions:["rnc"]},"application/remote-printing":{source:"iana"},"application/reputon+json":{source:"iana",compressible:!0},"application/resource-lists+xml":{source:"iana",compressible:!0,extensions:["rl"]},"application/resource-lists-diff+xml":{source:"iana",compressible:!0,extensions:["rld"]},"application/rfc+xml":{source:"iana",compressible:!0},"application/riscos":{source:"iana"},"application/rlmi+xml":{source:"iana",compressible:!0},"application/rls-services+xml":{source:"iana",compressible:!0,extensions:["rs"]},"application/route-apd+xml":{source:"iana",compressible:!0,extensions:["rapd"]},"application/route-s-tsid+xml":{source:"iana",compressible:!0,extensions:["sls"]},"application/route-usd+xml":{source:"iana",compressible:!0,extensions:["rusd"]},"application/rpki-ghostbusters":{source:"iana",extensions:["gbr"]},"application/rpki-manifest":{source:"iana",extensions:["mft"]},"application/rpki-publication":{source:"iana"},"application/rpki-roa":{source:"iana",extensions:["roa"]},"application/rpki-updown":{source:"iana"},"application/rsd+xml":{source:"apache",compressible:!0,extensions:["rsd"]},"application/rss+xml":{source:"apache",compressible:!0,extensions:["rss"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/rtploopback":{source:"iana"},"application/rtx":{source:"iana"},"application/samlassertion+xml":{source:"iana",compressible:!0},"application/samlmetadata+xml":{source:"iana",compressible:!0},"application/sarif+json":{source:"iana",compressible:!0},"application/sarif-external-properties+json":{source:"iana",compressible:!0},"application/sbe":{source:"iana"},"application/sbml+xml":{source:"iana",compressible:!0,extensions:["sbml"]},"application/scaip+xml":{source:"iana",compressible:!0},"application/scim+json":{source:"iana",compressible:!0},"application/scvp-cv-request":{source:"iana",extensions:["scq"]},"application/scvp-cv-response":{source:"iana",extensions:["scs"]},"application/scvp-vp-request":{source:"iana",extensions:["spq"]},"application/scvp-vp-response":{source:"iana",extensions:["spp"]},"application/sdp":{source:"iana",extensions:["sdp"]},"application/secevent+jwt":{source:"iana"},"application/senml+cbor":{source:"iana"},"application/senml+json":{source:"iana",compressible:!0},"application/senml+xml":{source:"iana",compressible:!0,extensions:["senmlx"]},"application/senml-etch+cbor":{source:"iana"},"application/senml-etch+json":{source:"iana",compressible:!0},"application/senml-exi":{source:"iana"},"application/sensml+cbor":{source:"iana"},"application/sensml+json":{source:"iana",compressible:!0},"application/sensml+xml":{source:"iana",compressible:!0,extensions:["sensmlx"]},"application/sensml-exi":{source:"iana"},"application/sep+xml":{source:"iana",compressible:!0},"application/sep-exi":{source:"iana"},"application/session-info":{source:"iana"},"application/set-payment":{source:"iana"},"application/set-payment-initiation":{source:"iana",extensions:["setpay"]},"application/set-registration":{source:"iana"},"application/set-registration-initiation":{source:"iana",extensions:["setreg"]},"application/sgml":{source:"iana"},"application/sgml-open-catalog":{source:"iana"},"application/shf+xml":{source:"iana",compressible:!0,extensions:["shf"]},"application/sieve":{source:"iana",extensions:["siv","sieve"]},"application/simple-filter+xml":{source:"iana",compressible:!0},"application/simple-message-summary":{source:"iana"},"application/simplesymbolcontainer":{source:"iana"},"application/sipc":{source:"iana"},"application/slate":{source:"iana"},"application/smil":{source:"iana"},"application/smil+xml":{source:"iana",compressible:!0,extensions:["smi","smil"]},"application/smpte336m":{source:"iana"},"application/soap+fastinfoset":{source:"iana"},"application/soap+xml":{source:"iana",compressible:!0},"application/sparql-query":{source:"iana",extensions:["rq"]},"application/sparql-results+xml":{source:"iana",compressible:!0,extensions:["srx"]},"application/spdx+json":{source:"iana",compressible:!0},"application/spirits-event+xml":{source:"iana",compressible:!0},"application/sql":{source:"iana"},"application/srgs":{source:"iana",extensions:["gram"]},"application/srgs+xml":{source:"iana",compressible:!0,extensions:["grxml"]},"application/sru+xml":{source:"iana",compressible:!0,extensions:["sru"]},"application/ssdl+xml":{source:"apache",compressible:!0,extensions:["ssdl"]},"application/ssml+xml":{source:"iana",compressible:!0,extensions:["ssml"]},"application/stix+json":{source:"iana",compressible:!0},"application/swid+xml":{source:"iana",compressible:!0,extensions:["swidtag"]},"application/tamp-apex-update":{source:"iana"},"application/tamp-apex-update-confirm":{source:"iana"},"application/tamp-community-update":{source:"iana"},"application/tamp-community-update-confirm":{source:"iana"},"application/tamp-error":{source:"iana"},"application/tamp-sequence-adjust":{source:"iana"},"application/tamp-sequence-adjust-confirm":{source:"iana"},"application/tamp-status-query":{source:"iana"},"application/tamp-status-response":{source:"iana"},"application/tamp-update":{source:"iana"},"application/tamp-update-confirm":{source:"iana"},"application/tar":{compressible:!0},"application/taxii+json":{source:"iana",compressible:!0},"application/td+json":{source:"iana",compressible:!0},"application/tei+xml":{source:"iana",compressible:!0,extensions:["tei","teicorpus"]},"application/tetra_isi":{source:"iana"},"application/thraud+xml":{source:"iana",compressible:!0,extensions:["tfi"]},"application/timestamp-query":{source:"iana"},"application/timestamp-reply":{source:"iana"},"application/timestamped-data":{source:"iana",extensions:["tsd"]},"application/tlsrpt+gzip":{source:"iana"},"application/tlsrpt+json":{source:"iana",compressible:!0},"application/tnauthlist":{source:"iana"},"application/token-introspection+jwt":{source:"iana"},"application/toml":{compressible:!0,extensions:["toml"]},"application/trickle-ice-sdpfrag":{source:"iana"},"application/trig":{source:"iana",extensions:["trig"]},"application/ttml+xml":{source:"iana",compressible:!0,extensions:["ttml"]},"application/tve-trigger":{source:"iana"},"application/tzif":{source:"iana"},"application/tzif-leap":{source:"iana"},"application/ubjson":{compressible:!1,extensions:["ubj"]},"application/ulpfec":{source:"iana"},"application/urc-grpsheet+xml":{source:"iana",compressible:!0},"application/urc-ressheet+xml":{source:"iana",compressible:!0,extensions:["rsheet"]},"application/urc-targetdesc+xml":{source:"iana",compressible:!0,extensions:["td"]},"application/urc-uisocketdesc+xml":{source:"iana",compressible:!0},"application/vcard+json":{source:"iana",compressible:!0},"application/vcard+xml":{source:"iana",compressible:!0},"application/vemmi":{source:"iana"},"application/vividence.scriptfile":{source:"apache"},"application/vnd.1000minds.decision-model+xml":{source:"iana",compressible:!0,extensions:["1km"]},"application/vnd.3gpp-prose+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-prose-pc3ch+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-v2x-local-service-information":{source:"iana"},"application/vnd.3gpp.5gnas":{source:"iana"},"application/vnd.3gpp.access-transfer-events+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.bsf+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gmop+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gtpc":{source:"iana"},"application/vnd.3gpp.interworking-data":{source:"iana"},"application/vnd.3gpp.lpp":{source:"iana"},"application/vnd.3gpp.mc-signalling-ear":{source:"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-payload":{source:"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-signalling":{source:"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-floor-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-signed+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-init-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-transmission-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mid-call+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ngap":{source:"iana"},"application/vnd.3gpp.pfcp":{source:"iana"},"application/vnd.3gpp.pic-bw-large":{source:"iana",extensions:["plb"]},"application/vnd.3gpp.pic-bw-small":{source:"iana",extensions:["psb"]},"application/vnd.3gpp.pic-bw-var":{source:"iana",extensions:["pvb"]},"application/vnd.3gpp.s1ap":{source:"iana"},"application/vnd.3gpp.sms":{source:"iana"},"application/vnd.3gpp.sms+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-ext+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.state-and-event-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ussd+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.bcmcsinfo+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.sms":{source:"iana"},"application/vnd.3gpp2.tcap":{source:"iana",extensions:["tcap"]},"application/vnd.3lightssoftware.imagescal":{source:"iana"},"application/vnd.3m.post-it-notes":{source:"iana",extensions:["pwn"]},"application/vnd.accpac.simply.aso":{source:"iana",extensions:["aso"]},"application/vnd.accpac.simply.imp":{source:"iana",extensions:["imp"]},"application/vnd.acucobol":{source:"iana",extensions:["acu"]},"application/vnd.acucorp":{source:"iana",extensions:["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{source:"apache",compressible:!1,extensions:["air"]},"application/vnd.adobe.flash.movie":{source:"iana"},"application/vnd.adobe.formscentral.fcdt":{source:"iana",extensions:["fcdt"]},"application/vnd.adobe.fxp":{source:"iana",extensions:["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{source:"iana"},"application/vnd.adobe.xdp+xml":{source:"iana",compressible:!0,extensions:["xdp"]},"application/vnd.adobe.xfdf":{source:"iana",extensions:["xfdf"]},"application/vnd.aether.imp":{source:"iana"},"application/vnd.afpc.afplinedata":{source:"iana"},"application/vnd.afpc.afplinedata-pagedef":{source:"iana"},"application/vnd.afpc.cmoca-cmresource":{source:"iana"},"application/vnd.afpc.foca-charset":{source:"iana"},"application/vnd.afpc.foca-codedfont":{source:"iana"},"application/vnd.afpc.foca-codepage":{source:"iana"},"application/vnd.afpc.modca":{source:"iana"},"application/vnd.afpc.modca-cmtable":{source:"iana"},"application/vnd.afpc.modca-formdef":{source:"iana"},"application/vnd.afpc.modca-mediummap":{source:"iana"},"application/vnd.afpc.modca-objectcontainer":{source:"iana"},"application/vnd.afpc.modca-overlay":{source:"iana"},"application/vnd.afpc.modca-pagesegment":{source:"iana"},"application/vnd.age":{source:"iana",extensions:["age"]},"application/vnd.ah-barcode":{source:"iana"},"application/vnd.ahead.space":{source:"iana",extensions:["ahead"]},"application/vnd.airzip.filesecure.azf":{source:"iana",extensions:["azf"]},"application/vnd.airzip.filesecure.azs":{source:"iana",extensions:["azs"]},"application/vnd.amadeus+json":{source:"iana",compressible:!0},"application/vnd.amazon.ebook":{source:"apache",extensions:["azw"]},"application/vnd.amazon.mobi8-ebook":{source:"iana"},"application/vnd.americandynamics.acc":{source:"iana",extensions:["acc"]},"application/vnd.amiga.ami":{source:"iana",extensions:["ami"]},"application/vnd.amundsen.maze+xml":{source:"iana",compressible:!0},"application/vnd.android.ota":{source:"iana"},"application/vnd.android.package-archive":{source:"apache",compressible:!1,extensions:["apk"]},"application/vnd.anki":{source:"iana"},"application/vnd.anser-web-certificate-issue-initiation":{source:"iana",extensions:["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{source:"apache",extensions:["fti"]},"application/vnd.antix.game-component":{source:"iana",extensions:["atx"]},"application/vnd.apache.arrow.file":{source:"iana"},"application/vnd.apache.arrow.stream":{source:"iana"},"application/vnd.apache.thrift.binary":{source:"iana"},"application/vnd.apache.thrift.compact":{source:"iana"},"application/vnd.apache.thrift.json":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/vnd.aplextor.warrp+json":{source:"iana",compressible:!0},"application/vnd.apothekende.reservation+json":{source:"iana",compressible:!0},"application/vnd.apple.installer+xml":{source:"iana",compressible:!0,extensions:["mpkg"]},"application/vnd.apple.keynote":{source:"iana",extensions:["key"]},"application/vnd.apple.mpegurl":{source:"iana",extensions:["m3u8"]},"application/vnd.apple.numbers":{source:"iana",extensions:["numbers"]},"application/vnd.apple.pages":{source:"iana",extensions:["pages"]},"application/vnd.apple.pkpass":{compressible:!1,extensions:["pkpass"]},"application/vnd.arastra.swi":{source:"iana"},"application/vnd.aristanetworks.swi":{source:"iana",extensions:["swi"]},"application/vnd.artisan+json":{source:"iana",compressible:!0},"application/vnd.artsquare":{source:"iana"},"application/vnd.astraea-software.iota":{source:"iana",extensions:["iota"]},"application/vnd.audiograph":{source:"iana",extensions:["aep"]},"application/vnd.autopackage":{source:"iana"},"application/vnd.avalon+json":{source:"iana",compressible:!0},"application/vnd.avistar+xml":{source:"iana",compressible:!0},"application/vnd.balsamiq.bmml+xml":{source:"iana",compressible:!0,extensions:["bmml"]},"application/vnd.balsamiq.bmpr":{source:"iana"},"application/vnd.banana-accounting":{source:"iana"},"application/vnd.bbf.usp.error":{source:"iana"},"application/vnd.bbf.usp.msg":{source:"iana"},"application/vnd.bbf.usp.msg+json":{source:"iana",compressible:!0},"application/vnd.bekitzur-stech+json":{source:"iana",compressible:!0},"application/vnd.bint.med-content":{source:"iana"},"application/vnd.biopax.rdf+xml":{source:"iana",compressible:!0},"application/vnd.blink-idb-value-wrapper":{source:"iana"},"application/vnd.blueice.multipass":{source:"iana",extensions:["mpm"]},"application/vnd.bluetooth.ep.oob":{source:"iana"},"application/vnd.bluetooth.le.oob":{source:"iana"},"application/vnd.bmi":{source:"iana",extensions:["bmi"]},"application/vnd.bpf":{source:"iana"},"application/vnd.bpf3":{source:"iana"},"application/vnd.businessobjects":{source:"iana",extensions:["rep"]},"application/vnd.byu.uapi+json":{source:"iana",compressible:!0},"application/vnd.cab-jscript":{source:"iana"},"application/vnd.canon-cpdl":{source:"iana"},"application/vnd.canon-lips":{source:"iana"},"application/vnd.capasystems-pg+json":{source:"iana",compressible:!0},"application/vnd.cendio.thinlinc.clientconf":{source:"iana"},"application/vnd.century-systems.tcp_stream":{source:"iana"},"application/vnd.chemdraw+xml":{source:"iana",compressible:!0,extensions:["cdxml"]},"application/vnd.chess-pgn":{source:"iana"},"application/vnd.chipnuts.karaoke-mmd":{source:"iana",extensions:["mmd"]},"application/vnd.ciedi":{source:"iana"},"application/vnd.cinderella":{source:"iana",extensions:["cdy"]},"application/vnd.cirpack.isdn-ext":{source:"iana"},"application/vnd.citationstyles.style+xml":{source:"iana",compressible:!0,extensions:["csl"]},"application/vnd.claymore":{source:"iana",extensions:["cla"]},"application/vnd.cloanto.rp9":{source:"iana",extensions:["rp9"]},"application/vnd.clonk.c4group":{source:"iana",extensions:["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{source:"iana",extensions:["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{source:"iana",extensions:["c11amz"]},"application/vnd.coffeescript":{source:"iana"},"application/vnd.collabio.xodocuments.document":{source:"iana"},"application/vnd.collabio.xodocuments.document-template":{source:"iana"},"application/vnd.collabio.xodocuments.presentation":{source:"iana"},"application/vnd.collabio.xodocuments.presentation-template":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{source:"iana"},"application/vnd.collection+json":{source:"iana",compressible:!0},"application/vnd.collection.doc+json":{source:"iana",compressible:!0},"application/vnd.collection.next+json":{source:"iana",compressible:!0},"application/vnd.comicbook+zip":{source:"iana",compressible:!1},"application/vnd.comicbook-rar":{source:"iana"},"application/vnd.commerce-battelle":{source:"iana"},"application/vnd.commonspace":{source:"iana",extensions:["csp"]},"application/vnd.contact.cmsg":{source:"iana",extensions:["cdbcmsg"]},"application/vnd.coreos.ignition+json":{source:"iana",compressible:!0},"application/vnd.cosmocaller":{source:"iana",extensions:["cmc"]},"application/vnd.crick.clicker":{source:"iana",extensions:["clkx"]},"application/vnd.crick.clicker.keyboard":{source:"iana",extensions:["clkk"]},"application/vnd.crick.clicker.palette":{source:"iana",extensions:["clkp"]},"application/vnd.crick.clicker.template":{source:"iana",extensions:["clkt"]},"application/vnd.crick.clicker.wordbank":{source:"iana",extensions:["clkw"]},"application/vnd.criticaltools.wbs+xml":{source:"iana",compressible:!0,extensions:["wbs"]},"application/vnd.cryptii.pipe+json":{source:"iana",compressible:!0},"application/vnd.crypto-shade-file":{source:"iana"},"application/vnd.cryptomator.encrypted":{source:"iana"},"application/vnd.cryptomator.vault":{source:"iana"},"application/vnd.ctc-posml":{source:"iana",extensions:["pml"]},"application/vnd.ctct.ws+xml":{source:"iana",compressible:!0},"application/vnd.cups-pdf":{source:"iana"},"application/vnd.cups-postscript":{source:"iana"},"application/vnd.cups-ppd":{source:"iana",extensions:["ppd"]},"application/vnd.cups-raster":{source:"iana"},"application/vnd.cups-raw":{source:"iana"},"application/vnd.curl":{source:"iana"},"application/vnd.curl.car":{source:"apache",extensions:["car"]},"application/vnd.curl.pcurl":{source:"apache",extensions:["pcurl"]},"application/vnd.cyan.dean.root+xml":{source:"iana",compressible:!0},"application/vnd.cybank":{source:"iana"},"application/vnd.cyclonedx+json":{source:"iana",compressible:!0},"application/vnd.cyclonedx+xml":{source:"iana",compressible:!0},"application/vnd.d2l.coursepackage1p0+zip":{source:"iana",compressible:!1},"application/vnd.d3m-dataset":{source:"iana"},"application/vnd.d3m-problem":{source:"iana"},"application/vnd.dart":{source:"iana",compressible:!0,extensions:["dart"]},"application/vnd.data-vision.rdz":{source:"iana",extensions:["rdz"]},"application/vnd.datapackage+json":{source:"iana",compressible:!0},"application/vnd.dataresource+json":{source:"iana",compressible:!0},"application/vnd.dbf":{source:"iana",extensions:["dbf"]},"application/vnd.debian.binary-package":{source:"iana"},"application/vnd.dece.data":{source:"iana",extensions:["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{source:"iana",compressible:!0,extensions:["uvt","uvvt"]},"application/vnd.dece.unspecified":{source:"iana",extensions:["uvx","uvvx"]},"application/vnd.dece.zip":{source:"iana",extensions:["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{source:"iana",extensions:["fe_launch"]},"application/vnd.desmume.movie":{source:"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{source:"iana"},"application/vnd.dm.delegation+xml":{source:"iana",compressible:!0},"application/vnd.dna":{source:"iana",extensions:["dna"]},"application/vnd.document+json":{source:"iana",compressible:!0},"application/vnd.dolby.mlp":{source:"apache",extensions:["mlp"]},"application/vnd.dolby.mobile.1":{source:"iana"},"application/vnd.dolby.mobile.2":{source:"iana"},"application/vnd.doremir.scorecloud-binary-document":{source:"iana"},"application/vnd.dpgraph":{source:"iana",extensions:["dpg"]},"application/vnd.dreamfactory":{source:"iana",extensions:["dfac"]},"application/vnd.drive+json":{source:"iana",compressible:!0},"application/vnd.ds-keypoint":{source:"apache",extensions:["kpxx"]},"application/vnd.dtg.local":{source:"iana"},"application/vnd.dtg.local.flash":{source:"iana"},"application/vnd.dtg.local.html":{source:"iana"},"application/vnd.dvb.ait":{source:"iana",extensions:["ait"]},"application/vnd.dvb.dvbisl+xml":{source:"iana",compressible:!0},"application/vnd.dvb.dvbj":{source:"iana"},"application/vnd.dvb.esgcontainer":{source:"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess2":{source:"iana"},"application/vnd.dvb.ipdcesgpdd":{source:"iana"},"application/vnd.dvb.ipdcroaming":{source:"iana"},"application/vnd.dvb.iptv.alfec-base":{source:"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{source:"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-container+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-generic+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-msglist+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-request+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-response+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-init+xml":{source:"iana",compressible:!0},"application/vnd.dvb.pfr":{source:"iana"},"application/vnd.dvb.service":{source:"iana",extensions:["svc"]},"application/vnd.dxr":{source:"iana"},"application/vnd.dynageo":{source:"iana",extensions:["geo"]},"application/vnd.dzr":{source:"iana"},"application/vnd.easykaraoke.cdgdownload":{source:"iana"},"application/vnd.ecdis-update":{source:"iana"},"application/vnd.ecip.rlp":{source:"iana"},"application/vnd.eclipse.ditto+json":{source:"iana",compressible:!0},"application/vnd.ecowin.chart":{source:"iana",extensions:["mag"]},"application/vnd.ecowin.filerequest":{source:"iana"},"application/vnd.ecowin.fileupdate":{source:"iana"},"application/vnd.ecowin.series":{source:"iana"},"application/vnd.ecowin.seriesrequest":{source:"iana"},"application/vnd.ecowin.seriesupdate":{source:"iana"},"application/vnd.efi.img":{source:"iana"},"application/vnd.efi.iso":{source:"iana"},"application/vnd.emclient.accessrequest+xml":{source:"iana",compressible:!0},"application/vnd.enliven":{source:"iana",extensions:["nml"]},"application/vnd.enphase.envoy":{source:"iana"},"application/vnd.eprints.data+xml":{source:"iana",compressible:!0},"application/vnd.epson.esf":{source:"iana",extensions:["esf"]},"application/vnd.epson.msf":{source:"iana",extensions:["msf"]},"application/vnd.epson.quickanime":{source:"iana",extensions:["qam"]},"application/vnd.epson.salt":{source:"iana",extensions:["slt"]},"application/vnd.epson.ssf":{source:"iana",extensions:["ssf"]},"application/vnd.ericsson.quickcall":{source:"iana"},"application/vnd.espass-espass+zip":{source:"iana",compressible:!1},"application/vnd.eszigno3+xml":{source:"iana",compressible:!0,extensions:["es3","et3"]},"application/vnd.etsi.aoc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.asic-e+zip":{source:"iana",compressible:!1},"application/vnd.etsi.asic-s+zip":{source:"iana",compressible:!1},"application/vnd.etsi.cug+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvcommand+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-bc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-cod+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-npvr+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvservice+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsync+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvueprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mcid+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mheg5":{source:"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{source:"iana",compressible:!0},"application/vnd.etsi.pstn+xml":{source:"iana",compressible:!0},"application/vnd.etsi.sci+xml":{source:"iana",compressible:!0},"application/vnd.etsi.simservs+xml":{source:"iana",compressible:!0},"application/vnd.etsi.timestamp-token":{source:"iana"},"application/vnd.etsi.tsl+xml":{source:"iana",compressible:!0},"application/vnd.etsi.tsl.der":{source:"iana"},"application/vnd.eu.kasparian.car+json":{source:"iana",compressible:!0},"application/vnd.eudora.data":{source:"iana"},"application/vnd.evolv.ecig.profile":{source:"iana"},"application/vnd.evolv.ecig.settings":{source:"iana"},"application/vnd.evolv.ecig.theme":{source:"iana"},"application/vnd.exstream-empower+zip":{source:"iana",compressible:!1},"application/vnd.exstream-package":{source:"iana"},"application/vnd.ezpix-album":{source:"iana",extensions:["ez2"]},"application/vnd.ezpix-package":{source:"iana",extensions:["ez3"]},"application/vnd.f-secure.mobile":{source:"iana"},"application/vnd.familysearch.gedcom+zip":{source:"iana",compressible:!1},"application/vnd.fastcopy-disk-image":{source:"iana"},"application/vnd.fdf":{source:"iana",extensions:["fdf"]},"application/vnd.fdsn.mseed":{source:"iana",extensions:["mseed"]},"application/vnd.fdsn.seed":{source:"iana",extensions:["seed","dataless"]},"application/vnd.ffsns":{source:"iana"},"application/vnd.ficlab.flb+zip":{source:"iana",compressible:!1},"application/vnd.filmit.zfc":{source:"iana"},"application/vnd.fints":{source:"iana"},"application/vnd.firemonkeys.cloudcell":{source:"iana"},"application/vnd.flographit":{source:"iana",extensions:["gph"]},"application/vnd.fluxtime.clip":{source:"iana",extensions:["ftc"]},"application/vnd.font-fontforge-sfd":{source:"iana"},"application/vnd.framemaker":{source:"iana",extensions:["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{source:"iana",extensions:["fnc"]},"application/vnd.frogans.ltf":{source:"iana",extensions:["ltf"]},"application/vnd.fsc.weblaunch":{source:"iana",extensions:["fsc"]},"application/vnd.fujifilm.fb.docuworks":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.binder":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.container":{source:"iana"},"application/vnd.fujifilm.fb.jfi+xml":{source:"iana",compressible:!0},"application/vnd.fujitsu.oasys":{source:"iana",extensions:["oas"]},"application/vnd.fujitsu.oasys2":{source:"iana",extensions:["oa2"]},"application/vnd.fujitsu.oasys3":{source:"iana",extensions:["oa3"]},"application/vnd.fujitsu.oasysgp":{source:"iana",extensions:["fg5"]},"application/vnd.fujitsu.oasysprs":{source:"iana",extensions:["bh2"]},"application/vnd.fujixerox.art-ex":{source:"iana"},"application/vnd.fujixerox.art4":{source:"iana"},"application/vnd.fujixerox.ddd":{source:"iana",extensions:["ddd"]},"application/vnd.fujixerox.docuworks":{source:"iana",extensions:["xdw"]},"application/vnd.fujixerox.docuworks.binder":{source:"iana",extensions:["xbd"]},"application/vnd.fujixerox.docuworks.container":{source:"iana"},"application/vnd.fujixerox.hbpl":{source:"iana"},"application/vnd.fut-misnet":{source:"iana"},"application/vnd.futoin+cbor":{source:"iana"},"application/vnd.futoin+json":{source:"iana",compressible:!0},"application/vnd.fuzzysheet":{source:"iana",extensions:["fzs"]},"application/vnd.genomatix.tuxedo":{source:"iana",extensions:["txd"]},"application/vnd.gentics.grd+json":{source:"iana",compressible:!0},"application/vnd.geo+json":{source:"iana",compressible:!0},"application/vnd.geocube+xml":{source:"iana",compressible:!0},"application/vnd.geogebra.file":{source:"iana",extensions:["ggb"]},"application/vnd.geogebra.slides":{source:"iana"},"application/vnd.geogebra.tool":{source:"iana",extensions:["ggt"]},"application/vnd.geometry-explorer":{source:"iana",extensions:["gex","gre"]},"application/vnd.geonext":{source:"iana",extensions:["gxt"]},"application/vnd.geoplan":{source:"iana",extensions:["g2w"]},"application/vnd.geospace":{source:"iana",extensions:["g3w"]},"application/vnd.gerber":{source:"iana"},"application/vnd.globalplatform.card-content-mgt":{source:"iana"},"application/vnd.globalplatform.card-content-mgt-response":{source:"iana"},"application/vnd.gmx":{source:"iana",extensions:["gmx"]},"application/vnd.google-apps.document":{compressible:!1,extensions:["gdoc"]},"application/vnd.google-apps.presentation":{compressible:!1,extensions:["gslides"]},"application/vnd.google-apps.spreadsheet":{compressible:!1,extensions:["gsheet"]},"application/vnd.google-earth.kml+xml":{source:"iana",compressible:!0,extensions:["kml"]},"application/vnd.google-earth.kmz":{source:"iana",compressible:!1,extensions:["kmz"]},"application/vnd.gov.sk.e-form+xml":{source:"iana",compressible:!0},"application/vnd.gov.sk.e-form+zip":{source:"iana",compressible:!1},"application/vnd.gov.sk.xmldatacontainer+xml":{source:"iana",compressible:!0},"application/vnd.grafeq":{source:"iana",extensions:["gqf","gqs"]},"application/vnd.gridmp":{source:"iana"},"application/vnd.groove-account":{source:"iana",extensions:["gac"]},"application/vnd.groove-help":{source:"iana",extensions:["ghf"]},"application/vnd.groove-identity-message":{source:"iana",extensions:["gim"]},"application/vnd.groove-injector":{source:"iana",extensions:["grv"]},"application/vnd.groove-tool-message":{source:"iana",extensions:["gtm"]},"application/vnd.groove-tool-template":{source:"iana",extensions:["tpl"]},"application/vnd.groove-vcard":{source:"iana",extensions:["vcg"]},"application/vnd.hal+json":{source:"iana",compressible:!0},"application/vnd.hal+xml":{source:"iana",compressible:!0,extensions:["hal"]},"application/vnd.handheld-entertainment+xml":{source:"iana",compressible:!0,extensions:["zmm"]},"application/vnd.hbci":{source:"iana",extensions:["hbci"]},"application/vnd.hc+json":{source:"iana",compressible:!0},"application/vnd.hcl-bireports":{source:"iana"},"application/vnd.hdt":{source:"iana"},"application/vnd.heroku+json":{source:"iana",compressible:!0},"application/vnd.hhe.lesson-player":{source:"iana",extensions:["les"]},"application/vnd.hl7cda+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hl7v2+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hp-hpgl":{source:"iana",extensions:["hpgl"]},"application/vnd.hp-hpid":{source:"iana",extensions:["hpid"]},"application/vnd.hp-hps":{source:"iana",extensions:["hps"]},"application/vnd.hp-jlyt":{source:"iana",extensions:["jlt"]},"application/vnd.hp-pcl":{source:"iana",extensions:["pcl"]},"application/vnd.hp-pclxl":{source:"iana",extensions:["pclxl"]},"application/vnd.httphone":{source:"iana"},"application/vnd.hydrostatix.sof-data":{source:"iana",extensions:["sfd-hdstx"]},"application/vnd.hyper+json":{source:"iana",compressible:!0},"application/vnd.hyper-item+json":{source:"iana",compressible:!0},"application/vnd.hyperdrive+json":{source:"iana",compressible:!0},"application/vnd.hzn-3d-crossword":{source:"iana"},"application/vnd.ibm.afplinedata":{source:"iana"},"application/vnd.ibm.electronic-media":{source:"iana"},"application/vnd.ibm.minipay":{source:"iana",extensions:["mpy"]},"application/vnd.ibm.modcap":{source:"iana",extensions:["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{source:"iana",extensions:["irm"]},"application/vnd.ibm.secure-container":{source:"iana",extensions:["sc"]},"application/vnd.iccprofile":{source:"iana",extensions:["icc","icm"]},"application/vnd.ieee.1905":{source:"iana"},"application/vnd.igloader":{source:"iana",extensions:["igl"]},"application/vnd.imagemeter.folder+zip":{source:"iana",compressible:!1},"application/vnd.imagemeter.image+zip":{source:"iana",compressible:!1},"application/vnd.immervision-ivp":{source:"iana",extensions:["ivp"]},"application/vnd.immervision-ivu":{source:"iana",extensions:["ivu"]},"application/vnd.ims.imsccv1p1":{source:"iana"},"application/vnd.ims.imsccv1p2":{source:"iana"},"application/vnd.ims.imsccv1p3":{source:"iana"},"application/vnd.ims.lis.v2.result+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy.id+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings.simple+json":{source:"iana",compressible:!0},"application/vnd.informedcontrol.rms+xml":{source:"iana",compressible:!0},"application/vnd.informix-visionary":{source:"iana"},"application/vnd.infotech.project":{source:"iana"},"application/vnd.infotech.project+xml":{source:"iana",compressible:!0},"application/vnd.innopath.wamp.notification":{source:"iana"},"application/vnd.insors.igm":{source:"iana",extensions:["igm"]},"application/vnd.intercon.formnet":{source:"iana",extensions:["xpw","xpx"]},"application/vnd.intergeo":{source:"iana",extensions:["i2g"]},"application/vnd.intertrust.digibox":{source:"iana"},"application/vnd.intertrust.nncp":{source:"iana"},"application/vnd.intu.qbo":{source:"iana",extensions:["qbo"]},"application/vnd.intu.qfx":{source:"iana",extensions:["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.conceptitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.knowledgeitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsmessage+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.packageitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.planningitem+xml":{source:"iana",compressible:!0},"application/vnd.ipunplugged.rcprofile":{source:"iana",extensions:["rcprofile"]},"application/vnd.irepository.package+xml":{source:"iana",compressible:!0,extensions:["irp"]},"application/vnd.is-xpr":{source:"iana",extensions:["xpr"]},"application/vnd.isac.fcs":{source:"iana",extensions:["fcs"]},"application/vnd.iso11783-10+zip":{source:"iana",compressible:!1},"application/vnd.jam":{source:"iana",extensions:["jam"]},"application/vnd.japannet-directory-service":{source:"iana"},"application/vnd.japannet-jpnstore-wakeup":{source:"iana"},"application/vnd.japannet-payment-wakeup":{source:"iana"},"application/vnd.japannet-registration":{source:"iana"},"application/vnd.japannet-registration-wakeup":{source:"iana"},"application/vnd.japannet-setstore-wakeup":{source:"iana"},"application/vnd.japannet-verification":{source:"iana"},"application/vnd.japannet-verification-wakeup":{source:"iana"},"application/vnd.jcp.javame.midlet-rms":{source:"iana",extensions:["rms"]},"application/vnd.jisp":{source:"iana",extensions:["jisp"]},"application/vnd.joost.joda-archive":{source:"iana",extensions:["joda"]},"application/vnd.jsk.isdn-ngn":{source:"iana"},"application/vnd.kahootz":{source:"iana",extensions:["ktz","ktr"]},"application/vnd.kde.karbon":{source:"iana",extensions:["karbon"]},"application/vnd.kde.kchart":{source:"iana",extensions:["chrt"]},"application/vnd.kde.kformula":{source:"iana",extensions:["kfo"]},"application/vnd.kde.kivio":{source:"iana",extensions:["flw"]},"application/vnd.kde.kontour":{source:"iana",extensions:["kon"]},"application/vnd.kde.kpresenter":{source:"iana",extensions:["kpr","kpt"]},"application/vnd.kde.kspread":{source:"iana",extensions:["ksp"]},"application/vnd.kde.kword":{source:"iana",extensions:["kwd","kwt"]},"application/vnd.kenameaapp":{source:"iana",extensions:["htke"]},"application/vnd.kidspiration":{source:"iana",extensions:["kia"]},"application/vnd.kinar":{source:"iana",extensions:["kne","knp"]},"application/vnd.koan":{source:"iana",extensions:["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{source:"iana",extensions:["sse"]},"application/vnd.las":{source:"iana"},"application/vnd.las.las+json":{source:"iana",compressible:!0},"application/vnd.las.las+xml":{source:"iana",compressible:!0,extensions:["lasxml"]},"application/vnd.laszip":{source:"iana"},"application/vnd.leap+json":{source:"iana",compressible:!0},"application/vnd.liberty-request+xml":{source:"iana",compressible:!0},"application/vnd.llamagraphics.life-balance.desktop":{source:"iana",extensions:["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{source:"iana",compressible:!0,extensions:["lbe"]},"application/vnd.logipipe.circuit+zip":{source:"iana",compressible:!1},"application/vnd.loom":{source:"iana"},"application/vnd.lotus-1-2-3":{source:"iana",extensions:["123"]},"application/vnd.lotus-approach":{source:"iana",extensions:["apr"]},"application/vnd.lotus-freelance":{source:"iana",extensions:["pre"]},"application/vnd.lotus-notes":{source:"iana",extensions:["nsf"]},"application/vnd.lotus-organizer":{source:"iana",extensions:["org"]},"application/vnd.lotus-screencam":{source:"iana",extensions:["scm"]},"application/vnd.lotus-wordpro":{source:"iana",extensions:["lwp"]},"application/vnd.macports.portpkg":{source:"iana",extensions:["portpkg"]},"application/vnd.mapbox-vector-tile":{source:"iana",extensions:["mvt"]},"application/vnd.marlin.drm.actiontoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.conftoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.license+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.mdcf":{source:"iana"},"application/vnd.mason+json":{source:"iana",compressible:!0},"application/vnd.maxar.archive.3tz+zip":{source:"iana",compressible:!1},"application/vnd.maxmind.maxmind-db":{source:"iana"},"application/vnd.mcd":{source:"iana",extensions:["mcd"]},"application/vnd.medcalcdata":{source:"iana",extensions:["mc1"]},"application/vnd.mediastation.cdkey":{source:"iana",extensions:["cdkey"]},"application/vnd.meridian-slingshot":{source:"iana"},"application/vnd.mfer":{source:"iana",extensions:["mwf"]},"application/vnd.mfmp":{source:"iana",extensions:["mfm"]},"application/vnd.micro+json":{source:"iana",compressible:!0},"application/vnd.micrografx.flo":{source:"iana",extensions:["flo"]},"application/vnd.micrografx.igx":{source:"iana",extensions:["igx"]},"application/vnd.microsoft.portable-executable":{source:"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{source:"iana"},"application/vnd.miele+json":{source:"iana",compressible:!0},"application/vnd.mif":{source:"iana",extensions:["mif"]},"application/vnd.minisoft-hp3000-save":{source:"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{source:"iana"},"application/vnd.mobius.daf":{source:"iana",extensions:["daf"]},"application/vnd.mobius.dis":{source:"iana",extensions:["dis"]},"application/vnd.mobius.mbk":{source:"iana",extensions:["mbk"]},"application/vnd.mobius.mqy":{source:"iana",extensions:["mqy"]},"application/vnd.mobius.msl":{source:"iana",extensions:["msl"]},"application/vnd.mobius.plc":{source:"iana",extensions:["plc"]},"application/vnd.mobius.txf":{source:"iana",extensions:["txf"]},"application/vnd.mophun.application":{source:"iana",extensions:["mpn"]},"application/vnd.mophun.certificate":{source:"iana",extensions:["mpc"]},"application/vnd.motorola.flexsuite":{source:"iana"},"application/vnd.motorola.flexsuite.adsi":{source:"iana"},"application/vnd.motorola.flexsuite.fis":{source:"iana"},"application/vnd.motorola.flexsuite.gotap":{source:"iana"},"application/vnd.motorola.flexsuite.kmr":{source:"iana"},"application/vnd.motorola.flexsuite.ttc":{source:"iana"},"application/vnd.motorola.flexsuite.wem":{source:"iana"},"application/vnd.motorola.iprm":{source:"iana"},"application/vnd.mozilla.xul+xml":{source:"iana",compressible:!0,extensions:["xul"]},"application/vnd.ms-3mfdocument":{source:"iana"},"application/vnd.ms-artgalry":{source:"iana",extensions:["cil"]},"application/vnd.ms-asf":{source:"iana"},"application/vnd.ms-cab-compressed":{source:"iana",extensions:["cab"]},"application/vnd.ms-color.iccprofile":{source:"apache"},"application/vnd.ms-excel":{source:"iana",compressible:!1,extensions:["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{source:"iana",extensions:["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{source:"iana",extensions:["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{source:"iana",extensions:["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{source:"iana",extensions:["xltm"]},"application/vnd.ms-fontobject":{source:"iana",compressible:!0,extensions:["eot"]},"application/vnd.ms-htmlhelp":{source:"iana",extensions:["chm"]},"application/vnd.ms-ims":{source:"iana",extensions:["ims"]},"application/vnd.ms-lrm":{source:"iana",extensions:["lrm"]},"application/vnd.ms-office.activex+xml":{source:"iana",compressible:!0},"application/vnd.ms-officetheme":{source:"iana",extensions:["thmx"]},"application/vnd.ms-opentype":{source:"apache",compressible:!0},"application/vnd.ms-outlook":{compressible:!1,extensions:["msg"]},"application/vnd.ms-package.obfuscated-opentype":{source:"apache"},"application/vnd.ms-pki.seccat":{source:"apache",extensions:["cat"]},"application/vnd.ms-pki.stl":{source:"apache",extensions:["stl"]},"application/vnd.ms-playready.initiator+xml":{source:"iana",compressible:!0},"application/vnd.ms-powerpoint":{source:"iana",compressible:!1,extensions:["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{source:"iana",extensions:["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{source:"iana",extensions:["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{source:"iana",extensions:["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{source:"iana",extensions:["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{source:"iana",extensions:["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{source:"iana",compressible:!0},"application/vnd.ms-printing.printticket+xml":{source:"apache",compressible:!0},"application/vnd.ms-printschematicket+xml":{source:"iana",compressible:!0},"application/vnd.ms-project":{source:"iana",extensions:["mpp","mpt"]},"application/vnd.ms-tnef":{source:"iana"},"application/vnd.ms-windows.devicepairing":{source:"iana"},"application/vnd.ms-windows.nwprinting.oob":{source:"iana"},"application/vnd.ms-windows.printerpairing":{source:"iana"},"application/vnd.ms-windows.wsd.oob":{source:"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.lic-resp":{source:"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.meter-resp":{source:"iana"},"application/vnd.ms-word.document.macroenabled.12":{source:"iana",extensions:["docm"]},"application/vnd.ms-word.template.macroenabled.12":{source:"iana",extensions:["dotm"]},"application/vnd.ms-works":{source:"iana",extensions:["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{source:"iana",extensions:["wpl"]},"application/vnd.ms-xpsdocument":{source:"iana",compressible:!1,extensions:["xps"]},"application/vnd.msa-disk-image":{source:"iana"},"application/vnd.mseq":{source:"iana",extensions:["mseq"]},"application/vnd.msign":{source:"iana"},"application/vnd.multiad.creator":{source:"iana"},"application/vnd.multiad.creator.cif":{source:"iana"},"application/vnd.music-niff":{source:"iana"},"application/vnd.musician":{source:"iana",extensions:["mus"]},"application/vnd.muvee.style":{source:"iana",extensions:["msty"]},"application/vnd.mynfc":{source:"iana",extensions:["taglet"]},"application/vnd.nacamar.ybrid+json":{source:"iana",compressible:!0},"application/vnd.ncd.control":{source:"iana"},"application/vnd.ncd.reference":{source:"iana"},"application/vnd.nearst.inv+json":{source:"iana",compressible:!0},"application/vnd.nebumind.line":{source:"iana"},"application/vnd.nervana":{source:"iana"},"application/vnd.netfpx":{source:"iana"},"application/vnd.neurolanguage.nlu":{source:"iana",extensions:["nlu"]},"application/vnd.nimn":{source:"iana"},"application/vnd.nintendo.nitro.rom":{source:"iana"},"application/vnd.nintendo.snes.rom":{source:"iana"},"application/vnd.nitf":{source:"iana",extensions:["ntf","nitf"]},"application/vnd.noblenet-directory":{source:"iana",extensions:["nnd"]},"application/vnd.noblenet-sealer":{source:"iana",extensions:["nns"]},"application/vnd.noblenet-web":{source:"iana",extensions:["nnw"]},"application/vnd.nokia.catalogs":{source:"iana"},"application/vnd.nokia.conml+wbxml":{source:"iana"},"application/vnd.nokia.conml+xml":{source:"iana",compressible:!0},"application/vnd.nokia.iptv.config+xml":{source:"iana",compressible:!0},"application/vnd.nokia.isds-radio-presets":{source:"iana"},"application/vnd.nokia.landmark+wbxml":{source:"iana"},"application/vnd.nokia.landmark+xml":{source:"iana",compressible:!0},"application/vnd.nokia.landmarkcollection+xml":{source:"iana",compressible:!0},"application/vnd.nokia.n-gage.ac+xml":{source:"iana",compressible:!0,extensions:["ac"]},"application/vnd.nokia.n-gage.data":{source:"iana",extensions:["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{source:"iana",extensions:["n-gage"]},"application/vnd.nokia.ncd":{source:"iana"},"application/vnd.nokia.pcd+wbxml":{source:"iana"},"application/vnd.nokia.pcd+xml":{source:"iana",compressible:!0},"application/vnd.nokia.radio-preset":{source:"iana",extensions:["rpst"]},"application/vnd.nokia.radio-presets":{source:"iana",extensions:["rpss"]},"application/vnd.novadigm.edm":{source:"iana",extensions:["edm"]},"application/vnd.novadigm.edx":{source:"iana",extensions:["edx"]},"application/vnd.novadigm.ext":{source:"iana",extensions:["ext"]},"application/vnd.ntt-local.content-share":{source:"iana"},"application/vnd.ntt-local.file-transfer":{source:"iana"},"application/vnd.ntt-local.ogw_remote-access":{source:"iana"},"application/vnd.ntt-local.sip-ta_remote":{source:"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{source:"iana"},"application/vnd.oasis.opendocument.chart":{source:"iana",extensions:["odc"]},"application/vnd.oasis.opendocument.chart-template":{source:"iana",extensions:["otc"]},"application/vnd.oasis.opendocument.database":{source:"iana",extensions:["odb"]},"application/vnd.oasis.opendocument.formula":{source:"iana",extensions:["odf"]},"application/vnd.oasis.opendocument.formula-template":{source:"iana",extensions:["odft"]},"application/vnd.oasis.opendocument.graphics":{source:"iana",compressible:!1,extensions:["odg"]},"application/vnd.oasis.opendocument.graphics-template":{source:"iana",extensions:["otg"]},"application/vnd.oasis.opendocument.image":{source:"iana",extensions:["odi"]},"application/vnd.oasis.opendocument.image-template":{source:"iana",extensions:["oti"]},"application/vnd.oasis.opendocument.presentation":{source:"iana",compressible:!1,extensions:["odp"]},"application/vnd.oasis.opendocument.presentation-template":{source:"iana",extensions:["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{source:"iana",compressible:!1,extensions:["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{source:"iana",extensions:["ots"]},"application/vnd.oasis.opendocument.text":{source:"iana",compressible:!1,extensions:["odt"]},"application/vnd.oasis.opendocument.text-master":{source:"iana",extensions:["odm"]},"application/vnd.oasis.opendocument.text-template":{source:"iana",extensions:["ott"]},"application/vnd.oasis.opendocument.text-web":{source:"iana",extensions:["oth"]},"application/vnd.obn":{source:"iana"},"application/vnd.ocf+cbor":{source:"iana"},"application/vnd.oci.image.manifest.v1+json":{source:"iana",compressible:!0},"application/vnd.oftn.l10n+json":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessdownload+xml":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessstreaming+xml":{source:"iana",compressible:!0},"application/vnd.oipf.cspg-hexbinary":{source:"iana"},"application/vnd.oipf.dae.svg+xml":{source:"iana",compressible:!0},"application/vnd.oipf.dae.xhtml+xml":{source:"iana",compressible:!0},"application/vnd.oipf.mippvcontrolmessage+xml":{source:"iana",compressible:!0},"application/vnd.oipf.pae.gem":{source:"iana"},"application/vnd.oipf.spdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.oipf.spdlist+xml":{source:"iana",compressible:!0},"application/vnd.oipf.ueprofile+xml":{source:"iana",compressible:!0},"application/vnd.oipf.userprofile+xml":{source:"iana",compressible:!0},"application/vnd.olpc-sugar":{source:"iana",extensions:["xo"]},"application/vnd.oma-scws-config":{source:"iana"},"application/vnd.oma-scws-http-request":{source:"iana"},"application/vnd.oma-scws-http-response":{source:"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.drm-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.imd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.ltkm":{source:"iana"},"application/vnd.oma.bcast.notification+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.provisioningtrigger":{source:"iana"},"application/vnd.oma.bcast.sgboot":{source:"iana"},"application/vnd.oma.bcast.sgdd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sgdu":{source:"iana"},"application/vnd.oma.bcast.simple-symbol-container":{source:"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sprov+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.stkm":{source:"iana"},"application/vnd.oma.cab-address-book+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-feature-handler+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-pcc+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-subs-invite+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-user-prefs+xml":{source:"iana",compressible:!0},"application/vnd.oma.dcd":{source:"iana"},"application/vnd.oma.dcdc":{source:"iana"},"application/vnd.oma.dd2+xml":{source:"iana",compressible:!0,extensions:["dd2"]},"application/vnd.oma.drm.risd+xml":{source:"iana",compressible:!0},"application/vnd.oma.group-usage-list+xml":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+cbor":{source:"iana"},"application/vnd.oma.lwm2m+json":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+tlv":{source:"iana"},"application/vnd.oma.pal+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.detailed-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.final-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.groups+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.invocation-descriptor+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.optimized-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.push":{source:"iana"},"application/vnd.oma.scidm.messages+xml":{source:"iana",compressible:!0},"application/vnd.oma.xcap-directory+xml":{source:"iana",compressible:!0},"application/vnd.omads-email+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-file+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-folder+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omaloc-supl-init":{source:"iana"},"application/vnd.onepager":{source:"iana"},"application/vnd.onepagertamp":{source:"iana"},"application/vnd.onepagertamx":{source:"iana"},"application/vnd.onepagertat":{source:"iana"},"application/vnd.onepagertatp":{source:"iana"},"application/vnd.onepagertatx":{source:"iana"},"application/vnd.openblox.game+xml":{source:"iana",compressible:!0,extensions:["obgx"]},"application/vnd.openblox.game-binary":{source:"iana"},"application/vnd.openeye.oeb":{source:"iana"},"application/vnd.openofficeorg.extension":{source:"apache",extensions:["oxt"]},"application/vnd.openstreetmap.data+xml":{source:"iana",compressible:!0,extensions:["osm"]},"application/vnd.opentimestamps.ots":{source:"iana"},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawing+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",compressible:!1,extensions:["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slide":{source:"iana",extensions:["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{source:"iana",extensions:["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.template":{source:"iana",extensions:["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",compressible:!1,extensions:["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{source:"iana",extensions:["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.theme+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.vmldrawing":{source:"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",compressible:!1,extensions:["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{source:"iana",extensions:["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.core-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.relationships+xml":{source:"iana",compressible:!0},"application/vnd.oracle.resource+json":{source:"iana",compressible:!0},"application/vnd.orange.indata":{source:"iana"},"application/vnd.osa.netdeploy":{source:"iana"},"application/vnd.osgeo.mapguide.package":{source:"iana",extensions:["mgp"]},"application/vnd.osgi.bundle":{source:"iana"},"application/vnd.osgi.dp":{source:"iana",extensions:["dp"]},"application/vnd.osgi.subsystem":{source:"iana",extensions:["esa"]},"application/vnd.otps.ct-kip+xml":{source:"iana",compressible:!0},"application/vnd.oxli.countgraph":{source:"iana"},"application/vnd.pagerduty+json":{source:"iana",compressible:!0},"application/vnd.palm":{source:"iana",extensions:["pdb","pqa","oprc"]},"application/vnd.panoply":{source:"iana"},"application/vnd.paos.xml":{source:"iana"},"application/vnd.patentdive":{source:"iana"},"application/vnd.patientecommsdoc":{source:"iana"},"application/vnd.pawaafile":{source:"iana",extensions:["paw"]},"application/vnd.pcos":{source:"iana"},"application/vnd.pg.format":{source:"iana",extensions:["str"]},"application/vnd.pg.osasli":{source:"iana",extensions:["ei6"]},"application/vnd.piaccess.application-licence":{source:"iana"},"application/vnd.picsel":{source:"iana",extensions:["efif"]},"application/vnd.pmi.widget":{source:"iana",extensions:["wg"]},"application/vnd.poc.group-advertisement+xml":{source:"iana",compressible:!0},"application/vnd.pocketlearn":{source:"iana",extensions:["plf"]},"application/vnd.powerbuilder6":{source:"iana",extensions:["pbd"]},"application/vnd.powerbuilder6-s":{source:"iana"},"application/vnd.powerbuilder7":{source:"iana"},"application/vnd.powerbuilder7-s":{source:"iana"},"application/vnd.powerbuilder75":{source:"iana"},"application/vnd.powerbuilder75-s":{source:"iana"},"application/vnd.preminet":{source:"iana"},"application/vnd.previewsystems.box":{source:"iana",extensions:["box"]},"application/vnd.proteus.magazine":{source:"iana",extensions:["mgz"]},"application/vnd.psfs":{source:"iana"},"application/vnd.publishare-delta-tree":{source:"iana",extensions:["qps"]},"application/vnd.pvi.ptid1":{source:"iana",extensions:["ptid"]},"application/vnd.pwg-multiplexed":{source:"iana"},"application/vnd.pwg-xhtml-print+xml":{source:"iana",compressible:!0},"application/vnd.qualcomm.brew-app-res":{source:"iana"},"application/vnd.quarantainenet":{source:"iana"},"application/vnd.quark.quarkxpress":{source:"iana",extensions:["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{source:"iana"},"application/vnd.radisys.moml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conn+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-stream+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-base+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-detect+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-group+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-speech+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-transform+xml":{source:"iana",compressible:!0},"application/vnd.rainstor.data":{source:"iana"},"application/vnd.rapid":{source:"iana"},"application/vnd.rar":{source:"iana",extensions:["rar"]},"application/vnd.realvnc.bed":{source:"iana",extensions:["bed"]},"application/vnd.recordare.musicxml":{source:"iana",extensions:["mxl"]},"application/vnd.recordare.musicxml+xml":{source:"iana",compressible:!0,extensions:["musicxml"]},"application/vnd.renlearn.rlprint":{source:"iana"},"application/vnd.resilient.logic":{source:"iana"},"application/vnd.restful+json":{source:"iana",compressible:!0},"application/vnd.rig.cryptonote":{source:"iana",extensions:["cryptonote"]},"application/vnd.rim.cod":{source:"apache",extensions:["cod"]},"application/vnd.rn-realmedia":{source:"apache",extensions:["rm"]},"application/vnd.rn-realmedia-vbr":{source:"apache",extensions:["rmvb"]},"application/vnd.route66.link66+xml":{source:"iana",compressible:!0,extensions:["link66"]},"application/vnd.rs-274x":{source:"iana"},"application/vnd.ruckus.download":{source:"iana"},"application/vnd.s3sms":{source:"iana"},"application/vnd.sailingtracker.track":{source:"iana",extensions:["st"]},"application/vnd.sar":{source:"iana"},"application/vnd.sbm.cid":{source:"iana"},"application/vnd.sbm.mid2":{source:"iana"},"application/vnd.scribus":{source:"iana"},"application/vnd.sealed.3df":{source:"iana"},"application/vnd.sealed.csf":{source:"iana"},"application/vnd.sealed.doc":{source:"iana"},"application/vnd.sealed.eml":{source:"iana"},"application/vnd.sealed.mht":{source:"iana"},"application/vnd.sealed.net":{source:"iana"},"application/vnd.sealed.ppt":{source:"iana"},"application/vnd.sealed.tiff":{source:"iana"},"application/vnd.sealed.xls":{source:"iana"},"application/vnd.sealedmedia.softseal.html":{source:"iana"},"application/vnd.sealedmedia.softseal.pdf":{source:"iana"},"application/vnd.seemail":{source:"iana",extensions:["see"]},"application/vnd.seis+json":{source:"iana",compressible:!0},"application/vnd.sema":{source:"iana",extensions:["sema"]},"application/vnd.semd":{source:"iana",extensions:["semd"]},"application/vnd.semf":{source:"iana",extensions:["semf"]},"application/vnd.shade-save-file":{source:"iana"},"application/vnd.shana.informed.formdata":{source:"iana",extensions:["ifm"]},"application/vnd.shana.informed.formtemplate":{source:"iana",extensions:["itp"]},"application/vnd.shana.informed.interchange":{source:"iana",extensions:["iif"]},"application/vnd.shana.informed.package":{source:"iana",extensions:["ipk"]},"application/vnd.shootproof+json":{source:"iana",compressible:!0},"application/vnd.shopkick+json":{source:"iana",compressible:!0},"application/vnd.shp":{source:"iana"},"application/vnd.shx":{source:"iana"},"application/vnd.sigrok.session":{source:"iana"},"application/vnd.simtech-mindmapper":{source:"iana",extensions:["twd","twds"]},"application/vnd.siren+json":{source:"iana",compressible:!0},"application/vnd.smaf":{source:"iana",extensions:["mmf"]},"application/vnd.smart.notebook":{source:"iana"},"application/vnd.smart.teacher":{source:"iana",extensions:["teacher"]},"application/vnd.snesdev-page-table":{source:"iana"},"application/vnd.software602.filler.form+xml":{source:"iana",compressible:!0,extensions:["fo"]},"application/vnd.software602.filler.form-xml-zip":{source:"iana"},"application/vnd.solent.sdkm+xml":{source:"iana",compressible:!0,extensions:["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{source:"iana",extensions:["dxp"]},"application/vnd.spotfire.sfs":{source:"iana",extensions:["sfs"]},"application/vnd.sqlite3":{source:"iana"},"application/vnd.sss-cod":{source:"iana"},"application/vnd.sss-dtf":{source:"iana"},"application/vnd.sss-ntf":{source:"iana"},"application/vnd.stardivision.calc":{source:"apache",extensions:["sdc"]},"application/vnd.stardivision.draw":{source:"apache",extensions:["sda"]},"application/vnd.stardivision.impress":{source:"apache",extensions:["sdd"]},"application/vnd.stardivision.math":{source:"apache",extensions:["smf"]},"application/vnd.stardivision.writer":{source:"apache",extensions:["sdw","vor"]},"application/vnd.stardivision.writer-global":{source:"apache",extensions:["sgl"]},"application/vnd.stepmania.package":{source:"iana",extensions:["smzip"]},"application/vnd.stepmania.stepchart":{source:"iana",extensions:["sm"]},"application/vnd.street-stream":{source:"iana"},"application/vnd.sun.wadl+xml":{source:"iana",compressible:!0,extensions:["wadl"]},"application/vnd.sun.xml.calc":{source:"apache",extensions:["sxc"]},"application/vnd.sun.xml.calc.template":{source:"apache",extensions:["stc"]},"application/vnd.sun.xml.draw":{source:"apache",extensions:["sxd"]},"application/vnd.sun.xml.draw.template":{source:"apache",extensions:["std"]},"application/vnd.sun.xml.impress":{source:"apache",extensions:["sxi"]},"application/vnd.sun.xml.impress.template":{source:"apache",extensions:["sti"]},"application/vnd.sun.xml.math":{source:"apache",extensions:["sxm"]},"application/vnd.sun.xml.writer":{source:"apache",extensions:["sxw"]},"application/vnd.sun.xml.writer.global":{source:"apache",extensions:["sxg"]},"application/vnd.sun.xml.writer.template":{source:"apache",extensions:["stw"]},"application/vnd.sus-calendar":{source:"iana",extensions:["sus","susp"]},"application/vnd.svd":{source:"iana",extensions:["svd"]},"application/vnd.swiftview-ics":{source:"iana"},"application/vnd.sycle+xml":{source:"iana",compressible:!0},"application/vnd.syft+json":{source:"iana",compressible:!0},"application/vnd.symbian.install":{source:"apache",extensions:["sis","sisx"]},"application/vnd.syncml+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xsm"]},"application/vnd.syncml.dm+wbxml":{source:"iana",charset:"UTF-8",extensions:["bdm"]},"application/vnd.syncml.dm+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xdm"]},"application/vnd.syncml.dm.notification":{source:"iana"},"application/vnd.syncml.dmddf+wbxml":{source:"iana"},"application/vnd.syncml.dmddf+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["ddf"]},"application/vnd.syncml.dmtnds+wbxml":{source:"iana"},"application/vnd.syncml.dmtnds+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.syncml.ds.notification":{source:"iana"},"application/vnd.tableschema+json":{source:"iana",compressible:!0},"application/vnd.tao.intent-module-archive":{source:"iana",extensions:["tao"]},"application/vnd.tcpdump.pcap":{source:"iana",extensions:["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{source:"iana",compressible:!0},"application/vnd.tmd.mediaflex.api+xml":{source:"iana",compressible:!0},"application/vnd.tml":{source:"iana"},"application/vnd.tmobile-livetv":{source:"iana",extensions:["tmo"]},"application/vnd.tri.onesource":{source:"iana"},"application/vnd.trid.tpt":{source:"iana",extensions:["tpt"]},"application/vnd.triscape.mxs":{source:"iana",extensions:["mxs"]},"application/vnd.trueapp":{source:"iana",extensions:["tra"]},"application/vnd.truedoc":{source:"iana"},"application/vnd.ubisoft.webplayer":{source:"iana"},"application/vnd.ufdl":{source:"iana",extensions:["ufd","ufdl"]},"application/vnd.uiq.theme":{source:"iana",extensions:["utz"]},"application/vnd.umajin":{source:"iana",extensions:["umj"]},"application/vnd.unity":{source:"iana",extensions:["unityweb"]},"application/vnd.uoml+xml":{source:"iana",compressible:!0,extensions:["uoml"]},"application/vnd.uplanet.alert":{source:"iana"},"application/vnd.uplanet.alert-wbxml":{source:"iana"},"application/vnd.uplanet.bearer-choice":{source:"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{source:"iana"},"application/vnd.uplanet.cacheop":{source:"iana"},"application/vnd.uplanet.cacheop-wbxml":{source:"iana"},"application/vnd.uplanet.channel":{source:"iana"},"application/vnd.uplanet.channel-wbxml":{source:"iana"},"application/vnd.uplanet.list":{source:"iana"},"application/vnd.uplanet.list-wbxml":{source:"iana"},"application/vnd.uplanet.listcmd":{source:"iana"},"application/vnd.uplanet.listcmd-wbxml":{source:"iana"},"application/vnd.uplanet.signal":{source:"iana"},"application/vnd.uri-map":{source:"iana"},"application/vnd.valve.source.material":{source:"iana"},"application/vnd.vcx":{source:"iana",extensions:["vcx"]},"application/vnd.vd-study":{source:"iana"},"application/vnd.vectorworks":{source:"iana"},"application/vnd.vel+json":{source:"iana",compressible:!0},"application/vnd.verimatrix.vcas":{source:"iana"},"application/vnd.veritone.aion+json":{source:"iana",compressible:!0},"application/vnd.veryant.thin":{source:"iana"},"application/vnd.ves.encrypted":{source:"iana"},"application/vnd.vidsoft.vidconference":{source:"iana"},"application/vnd.visio":{source:"iana",extensions:["vsd","vst","vss","vsw"]},"application/vnd.visionary":{source:"iana",extensions:["vis"]},"application/vnd.vividence.scriptfile":{source:"iana"},"application/vnd.vsf":{source:"iana",extensions:["vsf"]},"application/vnd.wap.sic":{source:"iana"},"application/vnd.wap.slc":{source:"iana"},"application/vnd.wap.wbxml":{source:"iana",charset:"UTF-8",extensions:["wbxml"]},"application/vnd.wap.wmlc":{source:"iana",extensions:["wmlc"]},"application/vnd.wap.wmlscriptc":{source:"iana",extensions:["wmlsc"]},"application/vnd.webturbo":{source:"iana",extensions:["wtb"]},"application/vnd.wfa.dpp":{source:"iana"},"application/vnd.wfa.p2p":{source:"iana"},"application/vnd.wfa.wsc":{source:"iana"},"application/vnd.windows.devicepairing":{source:"iana"},"application/vnd.wmc":{source:"iana"},"application/vnd.wmf.bootstrap":{source:"iana"},"application/vnd.wolfram.mathematica":{source:"iana"},"application/vnd.wolfram.mathematica.package":{source:"iana"},"application/vnd.wolfram.player":{source:"iana",extensions:["nbp"]},"application/vnd.wordperfect":{source:"iana",extensions:["wpd"]},"application/vnd.wqd":{source:"iana",extensions:["wqd"]},"application/vnd.wrq-hp3000-labelled":{source:"iana"},"application/vnd.wt.stf":{source:"iana",extensions:["stf"]},"application/vnd.wv.csp+wbxml":{source:"iana"},"application/vnd.wv.csp+xml":{source:"iana",compressible:!0},"application/vnd.wv.ssp+xml":{source:"iana",compressible:!0},"application/vnd.xacml+json":{source:"iana",compressible:!0},"application/vnd.xara":{source:"iana",extensions:["xar"]},"application/vnd.xfdl":{source:"iana",extensions:["xfdl"]},"application/vnd.xfdl.webform":{source:"iana"},"application/vnd.xmi+xml":{source:"iana",compressible:!0},"application/vnd.xmpie.cpkg":{source:"iana"},"application/vnd.xmpie.dpkg":{source:"iana"},"application/vnd.xmpie.plan":{source:"iana"},"application/vnd.xmpie.ppkg":{source:"iana"},"application/vnd.xmpie.xlim":{source:"iana"},"application/vnd.yamaha.hv-dic":{source:"iana",extensions:["hvd"]},"application/vnd.yamaha.hv-script":{source:"iana",extensions:["hvs"]},"application/vnd.yamaha.hv-voice":{source:"iana",extensions:["hvp"]},"application/vnd.yamaha.openscoreformat":{source:"iana",extensions:["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{source:"iana",compressible:!0,extensions:["osfpvg"]},"application/vnd.yamaha.remote-setup":{source:"iana"},"application/vnd.yamaha.smaf-audio":{source:"iana",extensions:["saf"]},"application/vnd.yamaha.smaf-phrase":{source:"iana",extensions:["spf"]},"application/vnd.yamaha.through-ngn":{source:"iana"},"application/vnd.yamaha.tunnel-udpencap":{source:"iana"},"application/vnd.yaoweme":{source:"iana"},"application/vnd.yellowriver-custom-menu":{source:"iana",extensions:["cmp"]},"application/vnd.youtube.yt":{source:"iana"},"application/vnd.zul":{source:"iana",extensions:["zir","zirz"]},"application/vnd.zzazz.deck+xml":{source:"iana",compressible:!0,extensions:["zaz"]},"application/voicexml+xml":{source:"iana",compressible:!0,extensions:["vxml"]},"application/voucher-cms+json":{source:"iana",compressible:!0},"application/vq-rtcpxr":{source:"iana"},"application/wasm":{source:"iana",compressible:!0,extensions:["wasm"]},"application/watcherinfo+xml":{source:"iana",compressible:!0,extensions:["wif"]},"application/webpush-options+json":{source:"iana",compressible:!0},"application/whoispp-query":{source:"iana"},"application/whoispp-response":{source:"iana"},"application/widget":{source:"iana",extensions:["wgt"]},"application/winhlp":{source:"apache",extensions:["hlp"]},"application/wita":{source:"iana"},"application/wordperfect5.1":{source:"iana"},"application/wsdl+xml":{source:"iana",compressible:!0,extensions:["wsdl"]},"application/wspolicy+xml":{source:"iana",compressible:!0,extensions:["wspolicy"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/x-abiword":{source:"apache",extensions:["abw"]},"application/x-ace-compressed":{source:"apache",extensions:["ace"]},"application/x-amf":{source:"apache"},"application/x-apple-diskimage":{source:"apache",extensions:["dmg"]},"application/x-arj":{compressible:!1,extensions:["arj"]},"application/x-authorware-bin":{source:"apache",extensions:["aab","x32","u32","vox"]},"application/x-authorware-map":{source:"apache",extensions:["aam"]},"application/x-authorware-seg":{source:"apache",extensions:["aas"]},"application/x-bcpio":{source:"apache",extensions:["bcpio"]},"application/x-bdoc":{compressible:!1,extensions:["bdoc"]},"application/x-bittorrent":{source:"apache",extensions:["torrent"]},"application/x-blorb":{source:"apache",extensions:["blb","blorb"]},"application/x-bzip":{source:"apache",compressible:!1,extensions:["bz"]},"application/x-bzip2":{source:"apache",compressible:!1,extensions:["bz2","boz"]},"application/x-cbr":{source:"apache",extensions:["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{source:"apache",extensions:["vcd"]},"application/x-cfs-compressed":{source:"apache",extensions:["cfs"]},"application/x-chat":{source:"apache",extensions:["chat"]},"application/x-chess-pgn":{source:"apache",extensions:["pgn"]},"application/x-chrome-extension":{extensions:["crx"]},"application/x-cocoa":{source:"nginx",extensions:["cco"]},"application/x-compress":{source:"apache"},"application/x-conference":{source:"apache",extensions:["nsc"]},"application/x-cpio":{source:"apache",extensions:["cpio"]},"application/x-csh":{source:"apache",extensions:["csh"]},"application/x-deb":{compressible:!1},"application/x-debian-package":{source:"apache",extensions:["deb","udeb"]},"application/x-dgc-compressed":{source:"apache",extensions:["dgc"]},"application/x-director":{source:"apache",extensions:["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{source:"apache",extensions:["wad"]},"application/x-dtbncx+xml":{source:"apache",compressible:!0,extensions:["ncx"]},"application/x-dtbook+xml":{source:"apache",compressible:!0,extensions:["dtb"]},"application/x-dtbresource+xml":{source:"apache",compressible:!0,extensions:["res"]},"application/x-dvi":{source:"apache",compressible:!1,extensions:["dvi"]},"application/x-envoy":{source:"apache",extensions:["evy"]},"application/x-eva":{source:"apache",extensions:["eva"]},"application/x-font-bdf":{source:"apache",extensions:["bdf"]},"application/x-font-dos":{source:"apache"},"application/x-font-framemaker":{source:"apache"},"application/x-font-ghostscript":{source:"apache",extensions:["gsf"]},"application/x-font-libgrx":{source:"apache"},"application/x-font-linux-psf":{source:"apache",extensions:["psf"]},"application/x-font-pcf":{source:"apache",extensions:["pcf"]},"application/x-font-snf":{source:"apache",extensions:["snf"]},"application/x-font-speedo":{source:"apache"},"application/x-font-sunos-news":{source:"apache"},"application/x-font-type1":{source:"apache",extensions:["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{source:"apache"},"application/x-freearc":{source:"apache",extensions:["arc"]},"application/x-futuresplash":{source:"apache",extensions:["spl"]},"application/x-gca-compressed":{source:"apache",extensions:["gca"]},"application/x-glulx":{source:"apache",extensions:["ulx"]},"application/x-gnumeric":{source:"apache",extensions:["gnumeric"]},"application/x-gramps-xml":{source:"apache",extensions:["gramps"]},"application/x-gtar":{source:"apache",extensions:["gtar"]},"application/x-gzip":{source:"apache"},"application/x-hdf":{source:"apache",extensions:["hdf"]},"application/x-httpd-php":{compressible:!0,extensions:["php"]},"application/x-install-instructions":{source:"apache",extensions:["install"]},"application/x-iso9660-image":{source:"apache",extensions:["iso"]},"application/x-iwork-keynote-sffkey":{extensions:["key"]},"application/x-iwork-numbers-sffnumbers":{extensions:["numbers"]},"application/x-iwork-pages-sffpages":{extensions:["pages"]},"application/x-java-archive-diff":{source:"nginx",extensions:["jardiff"]},"application/x-java-jnlp-file":{source:"apache",compressible:!1,extensions:["jnlp"]},"application/x-javascript":{compressible:!0},"application/x-keepass2":{extensions:["kdbx"]},"application/x-latex":{source:"apache",compressible:!1,extensions:["latex"]},"application/x-lua-bytecode":{extensions:["luac"]},"application/x-lzh-compressed":{source:"apache",extensions:["lzh","lha"]},"application/x-makeself":{source:"nginx",extensions:["run"]},"application/x-mie":{source:"apache",extensions:["mie"]},"application/x-mobipocket-ebook":{source:"apache",extensions:["prc","mobi"]},"application/x-mpegurl":{compressible:!1},"application/x-ms-application":{source:"apache",extensions:["application"]},"application/x-ms-shortcut":{source:"apache",extensions:["lnk"]},"application/x-ms-wmd":{source:"apache",extensions:["wmd"]},"application/x-ms-wmz":{source:"apache",extensions:["wmz"]},"application/x-ms-xbap":{source:"apache",extensions:["xbap"]},"application/x-msaccess":{source:"apache",extensions:["mdb"]},"application/x-msbinder":{source:"apache",extensions:["obd"]},"application/x-mscardfile":{source:"apache",extensions:["crd"]},"application/x-msclip":{source:"apache",extensions:["clp"]},"application/x-msdos-program":{extensions:["exe"]},"application/x-msdownload":{source:"apache",extensions:["exe","dll","com","bat","msi"]},"application/x-msmediaview":{source:"apache",extensions:["mvb","m13","m14"]},"application/x-msmetafile":{source:"apache",extensions:["wmf","wmz","emf","emz"]},"application/x-msmoney":{source:"apache",extensions:["mny"]},"application/x-mspublisher":{source:"apache",extensions:["pub"]},"application/x-msschedule":{source:"apache",extensions:["scd"]},"application/x-msterminal":{source:"apache",extensions:["trm"]},"application/x-mswrite":{source:"apache",extensions:["wri"]},"application/x-netcdf":{source:"apache",extensions:["nc","cdf"]},"application/x-ns-proxy-autoconfig":{compressible:!0,extensions:["pac"]},"application/x-nzb":{source:"apache",extensions:["nzb"]},"application/x-perl":{source:"nginx",extensions:["pl","pm"]},"application/x-pilot":{source:"nginx",extensions:["prc","pdb"]},"application/x-pkcs12":{source:"apache",compressible:!1,extensions:["p12","pfx"]},"application/x-pkcs7-certificates":{source:"apache",extensions:["p7b","spc"]},"application/x-pkcs7-certreqresp":{source:"apache",extensions:["p7r"]},"application/x-pki-message":{source:"iana"},"application/x-rar-compressed":{source:"apache",compressible:!1,extensions:["rar"]},"application/x-redhat-package-manager":{source:"nginx",extensions:["rpm"]},"application/x-research-info-systems":{source:"apache",extensions:["ris"]},"application/x-sea":{source:"nginx",extensions:["sea"]},"application/x-sh":{source:"apache",compressible:!0,extensions:["sh"]},"application/x-shar":{source:"apache",extensions:["shar"]},"application/x-shockwave-flash":{source:"apache",compressible:!1,extensions:["swf"]},"application/x-silverlight-app":{source:"apache",extensions:["xap"]},"application/x-sql":{source:"apache",extensions:["sql"]},"application/x-stuffit":{source:"apache",compressible:!1,extensions:["sit"]},"application/x-stuffitx":{source:"apache",extensions:["sitx"]},"application/x-subrip":{source:"apache",extensions:["srt"]},"application/x-sv4cpio":{source:"apache",extensions:["sv4cpio"]},"application/x-sv4crc":{source:"apache",extensions:["sv4crc"]},"application/x-t3vm-image":{source:"apache",extensions:["t3"]},"application/x-tads":{source:"apache",extensions:["gam"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-tcl":{source:"apache",extensions:["tcl","tk"]},"application/x-tex":{source:"apache",extensions:["tex"]},"application/x-tex-tfm":{source:"apache",extensions:["tfm"]},"application/x-texinfo":{source:"apache",extensions:["texinfo","texi"]},"application/x-tgif":{source:"apache",extensions:["obj"]},"application/x-ustar":{source:"apache",extensions:["ustar"]},"application/x-virtualbox-hdd":{compressible:!0,extensions:["hdd"]},"application/x-virtualbox-ova":{compressible:!0,extensions:["ova"]},"application/x-virtualbox-ovf":{compressible:!0,extensions:["ovf"]},"application/x-virtualbox-vbox":{compressible:!0,extensions:["vbox"]},"application/x-virtualbox-vbox-extpack":{compressible:!1,extensions:["vbox-extpack"]},"application/x-virtualbox-vdi":{compressible:!0,extensions:["vdi"]},"application/x-virtualbox-vhd":{compressible:!0,extensions:["vhd"]},"application/x-virtualbox-vmdk":{compressible:!0,extensions:["vmdk"]},"application/x-wais-source":{source:"apache",extensions:["src"]},"application/x-web-app-manifest+json":{compressible:!0,extensions:["webapp"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"application/x-x509-ca-cert":{source:"iana",extensions:["der","crt","pem"]},"application/x-x509-ca-ra-cert":{source:"iana"},"application/x-x509-next-ca-cert":{source:"iana"},"application/x-xfig":{source:"apache",extensions:["fig"]},"application/x-xliff+xml":{source:"apache",compressible:!0,extensions:["xlf"]},"application/x-xpinstall":{source:"apache",compressible:!1,extensions:["xpi"]},"application/x-xz":{source:"apache",extensions:["xz"]},"application/x-zmachine":{source:"apache",extensions:["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{source:"iana"},"application/xacml+xml":{source:"iana",compressible:!0},"application/xaml+xml":{source:"apache",compressible:!0,extensions:["xaml"]},"application/xcap-att+xml":{source:"iana",compressible:!0,extensions:["xav"]},"application/xcap-caps+xml":{source:"iana",compressible:!0,extensions:["xca"]},"application/xcap-diff+xml":{source:"iana",compressible:!0,extensions:["xdf"]},"application/xcap-el+xml":{source:"iana",compressible:!0,extensions:["xel"]},"application/xcap-error+xml":{source:"iana",compressible:!0},"application/xcap-ns+xml":{source:"iana",compressible:!0,extensions:["xns"]},"application/xcon-conference-info+xml":{source:"iana",compressible:!0},"application/xcon-conference-info-diff+xml":{source:"iana",compressible:!0},"application/xenc+xml":{source:"iana",compressible:!0,extensions:["xenc"]},"application/xhtml+xml":{source:"iana",compressible:!0,extensions:["xhtml","xht"]},"application/xhtml-voice+xml":{source:"apache",compressible:!0},"application/xliff+xml":{source:"iana",compressible:!0,extensions:["xlf"]},"application/xml":{source:"iana",compressible:!0,extensions:["xml","xsl","xsd","rng"]},"application/xml-dtd":{source:"iana",compressible:!0,extensions:["dtd"]},"application/xml-external-parsed-entity":{source:"iana"},"application/xml-patch+xml":{source:"iana",compressible:!0},"application/xmpp+xml":{source:"iana",compressible:!0},"application/xop+xml":{source:"iana",compressible:!0,extensions:["xop"]},"application/xproc+xml":{source:"apache",compressible:!0,extensions:["xpl"]},"application/xslt+xml":{source:"iana",compressible:!0,extensions:["xsl","xslt"]},"application/xspf+xml":{source:"apache",compressible:!0,extensions:["xspf"]},"application/xv+xml":{source:"iana",compressible:!0,extensions:["mxml","xhvml","xvml","xvm"]},"application/yang":{source:"iana",extensions:["yang"]},"application/yang-data+json":{source:"iana",compressible:!0},"application/yang-data+xml":{source:"iana",compressible:!0},"application/yang-patch+json":{source:"iana",compressible:!0},"application/yang-patch+xml":{source:"iana",compressible:!0},"application/yin+xml":{source:"iana",compressible:!0,extensions:["yin"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/zlib":{source:"iana"},"application/zstd":{source:"iana"},"audio/1d-interleaved-parityfec":{source:"iana"},"audio/32kadpcm":{source:"iana"},"audio/3gpp":{source:"iana",compressible:!1,extensions:["3gpp"]},"audio/3gpp2":{source:"iana"},"audio/aac":{source:"iana"},"audio/ac3":{source:"iana"},"audio/adpcm":{source:"apache",extensions:["adp"]},"audio/amr":{source:"iana",extensions:["amr"]},"audio/amr-wb":{source:"iana"},"audio/amr-wb+":{source:"iana"},"audio/aptx":{source:"iana"},"audio/asc":{source:"iana"},"audio/atrac-advanced-lossless":{source:"iana"},"audio/atrac-x":{source:"iana"},"audio/atrac3":{source:"iana"},"audio/basic":{source:"iana",compressible:!1,extensions:["au","snd"]},"audio/bv16":{source:"iana"},"audio/bv32":{source:"iana"},"audio/clearmode":{source:"iana"},"audio/cn":{source:"iana"},"audio/dat12":{source:"iana"},"audio/dls":{source:"iana"},"audio/dsr-es201108":{source:"iana"},"audio/dsr-es202050":{source:"iana"},"audio/dsr-es202211":{source:"iana"},"audio/dsr-es202212":{source:"iana"},"audio/dv":{source:"iana"},"audio/dvi4":{source:"iana"},"audio/eac3":{source:"iana"},"audio/encaprtp":{source:"iana"},"audio/evrc":{source:"iana"},"audio/evrc-qcp":{source:"iana"},"audio/evrc0":{source:"iana"},"audio/evrc1":{source:"iana"},"audio/evrcb":{source:"iana"},"audio/evrcb0":{source:"iana"},"audio/evrcb1":{source:"iana"},"audio/evrcnw":{source:"iana"},"audio/evrcnw0":{source:"iana"},"audio/evrcnw1":{source:"iana"},"audio/evrcwb":{source:"iana"},"audio/evrcwb0":{source:"iana"},"audio/evrcwb1":{source:"iana"},"audio/evs":{source:"iana"},"audio/flexfec":{source:"iana"},"audio/fwdred":{source:"iana"},"audio/g711-0":{source:"iana"},"audio/g719":{source:"iana"},"audio/g722":{source:"iana"},"audio/g7221":{source:"iana"},"audio/g723":{source:"iana"},"audio/g726-16":{source:"iana"},"audio/g726-24":{source:"iana"},"audio/g726-32":{source:"iana"},"audio/g726-40":{source:"iana"},"audio/g728":{source:"iana"},"audio/g729":{source:"iana"},"audio/g7291":{source:"iana"},"audio/g729d":{source:"iana"},"audio/g729e":{source:"iana"},"audio/gsm":{source:"iana"},"audio/gsm-efr":{source:"iana"},"audio/gsm-hr-08":{source:"iana"},"audio/ilbc":{source:"iana"},"audio/ip-mr_v2.5":{source:"iana"},"audio/isac":{source:"apache"},"audio/l16":{source:"iana"},"audio/l20":{source:"iana"},"audio/l24":{source:"iana",compressible:!1},"audio/l8":{source:"iana"},"audio/lpc":{source:"iana"},"audio/melp":{source:"iana"},"audio/melp1200":{source:"iana"},"audio/melp2400":{source:"iana"},"audio/melp600":{source:"iana"},"audio/mhas":{source:"iana"},"audio/midi":{source:"apache",extensions:["mid","midi","kar","rmi"]},"audio/mobile-xmf":{source:"iana",extensions:["mxmf"]},"audio/mp3":{compressible:!1,extensions:["mp3"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a","mp4a"]},"audio/mp4a-latm":{source:"iana"},"audio/mpa":{source:"iana"},"audio/mpa-robust":{source:"iana"},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{source:"iana"},"audio/musepack":{source:"apache"},"audio/ogg":{source:"iana",compressible:!1,extensions:["oga","ogg","spx","opus"]},"audio/opus":{source:"iana"},"audio/parityfec":{source:"iana"},"audio/pcma":{source:"iana"},"audio/pcma-wb":{source:"iana"},"audio/pcmu":{source:"iana"},"audio/pcmu-wb":{source:"iana"},"audio/prs.sid":{source:"iana"},"audio/qcelp":{source:"iana"},"audio/raptorfec":{source:"iana"},"audio/red":{source:"iana"},"audio/rtp-enc-aescm128":{source:"iana"},"audio/rtp-midi":{source:"iana"},"audio/rtploopback":{source:"iana"},"audio/rtx":{source:"iana"},"audio/s3m":{source:"apache",extensions:["s3m"]},"audio/scip":{source:"iana"},"audio/silk":{source:"apache",extensions:["sil"]},"audio/smv":{source:"iana"},"audio/smv-qcp":{source:"iana"},"audio/smv0":{source:"iana"},"audio/sofa":{source:"iana"},"audio/sp-midi":{source:"iana"},"audio/speex":{source:"iana"},"audio/t140c":{source:"iana"},"audio/t38":{source:"iana"},"audio/telephone-event":{source:"iana"},"audio/tetra_acelp":{source:"iana"},"audio/tetra_acelp_bb":{source:"iana"},"audio/tone":{source:"iana"},"audio/tsvcis":{source:"iana"},"audio/uemclip":{source:"iana"},"audio/ulpfec":{source:"iana"},"audio/usac":{source:"iana"},"audio/vdvi":{source:"iana"},"audio/vmr-wb":{source:"iana"},"audio/vnd.3gpp.iufp":{source:"iana"},"audio/vnd.4sb":{source:"iana"},"audio/vnd.audiokoz":{source:"iana"},"audio/vnd.celp":{source:"iana"},"audio/vnd.cisco.nse":{source:"iana"},"audio/vnd.cmles.radio-events":{source:"iana"},"audio/vnd.cns.anp1":{source:"iana"},"audio/vnd.cns.inf1":{source:"iana"},"audio/vnd.dece.audio":{source:"iana",extensions:["uva","uvva"]},"audio/vnd.digital-winds":{source:"iana",extensions:["eol"]},"audio/vnd.dlna.adts":{source:"iana"},"audio/vnd.dolby.heaac.1":{source:"iana"},"audio/vnd.dolby.heaac.2":{source:"iana"},"audio/vnd.dolby.mlp":{source:"iana"},"audio/vnd.dolby.mps":{source:"iana"},"audio/vnd.dolby.pl2":{source:"iana"},"audio/vnd.dolby.pl2x":{source:"iana"},"audio/vnd.dolby.pl2z":{source:"iana"},"audio/vnd.dolby.pulse.1":{source:"iana"},"audio/vnd.dra":{source:"iana",extensions:["dra"]},"audio/vnd.dts":{source:"iana",extensions:["dts"]},"audio/vnd.dts.hd":{source:"iana",extensions:["dtshd"]},"audio/vnd.dts.uhd":{source:"iana"},"audio/vnd.dvb.file":{source:"iana"},"audio/vnd.everad.plj":{source:"iana"},"audio/vnd.hns.audio":{source:"iana"},"audio/vnd.lucent.voice":{source:"iana",extensions:["lvp"]},"audio/vnd.ms-playready.media.pya":{source:"iana",extensions:["pya"]},"audio/vnd.nokia.mobile-xmf":{source:"iana"},"audio/vnd.nortel.vbk":{source:"iana"},"audio/vnd.nuera.ecelp4800":{source:"iana",extensions:["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{source:"iana",extensions:["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{source:"iana",extensions:["ecelp9600"]},"audio/vnd.octel.sbc":{source:"iana"},"audio/vnd.presonus.multitrack":{source:"iana"},"audio/vnd.qcelp":{source:"iana"},"audio/vnd.rhetorex.32kadpcm":{source:"iana"},"audio/vnd.rip":{source:"iana",extensions:["rip"]},"audio/vnd.rn-realaudio":{compressible:!1},"audio/vnd.sealedmedia.softseal.mpeg":{source:"iana"},"audio/vnd.vmx.cvsd":{source:"iana"},"audio/vnd.wave":{compressible:!1},"audio/vorbis":{source:"iana",compressible:!1},"audio/vorbis-config":{source:"iana"},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/wave":{compressible:!1,extensions:["wav"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/x-aac":{source:"apache",compressible:!1,extensions:["aac"]},"audio/x-aiff":{source:"apache",extensions:["aif","aiff","aifc"]},"audio/x-caf":{source:"apache",compressible:!1,extensions:["caf"]},"audio/x-flac":{source:"apache",extensions:["flac"]},"audio/x-m4a":{source:"nginx",extensions:["m4a"]},"audio/x-matroska":{source:"apache",extensions:["mka"]},"audio/x-mpegurl":{source:"apache",extensions:["m3u"]},"audio/x-ms-wax":{source:"apache",extensions:["wax"]},"audio/x-ms-wma":{source:"apache",extensions:["wma"]},"audio/x-pn-realaudio":{source:"apache",extensions:["ram","ra"]},"audio/x-pn-realaudio-plugin":{source:"apache",extensions:["rmp"]},"audio/x-realaudio":{source:"nginx",extensions:["ra"]},"audio/x-tta":{source:"apache"},"audio/x-wav":{source:"apache",extensions:["wav"]},"audio/xm":{source:"apache",extensions:["xm"]},"chemical/x-cdx":{source:"apache",extensions:["cdx"]},"chemical/x-cif":{source:"apache",extensions:["cif"]},"chemical/x-cmdf":{source:"apache",extensions:["cmdf"]},"chemical/x-cml":{source:"apache",extensions:["cml"]},"chemical/x-csml":{source:"apache",extensions:["csml"]},"chemical/x-pdb":{source:"apache"},"chemical/x-xyz":{source:"apache",extensions:["xyz"]},"font/collection":{source:"iana",extensions:["ttc"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"font/sfnt":{source:"iana"},"font/ttf":{source:"iana",compressible:!0,extensions:["ttf"]},"font/woff":{source:"iana",extensions:["woff"]},"font/woff2":{source:"iana",extensions:["woff2"]},"image/aces":{source:"iana",extensions:["exr"]},"image/apng":{compressible:!1,extensions:["apng"]},"image/avci":{source:"iana",extensions:["avci"]},"image/avcs":{source:"iana",extensions:["avcs"]},"image/avif":{source:"iana",compressible:!1,extensions:["avif"]},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/cgm":{source:"iana",extensions:["cgm"]},"image/dicom-rle":{source:"iana",extensions:["drle"]},"image/emf":{source:"iana",extensions:["emf"]},"image/fits":{source:"iana",extensions:["fits"]},"image/g3fax":{source:"iana",extensions:["g3"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/heic":{source:"iana",extensions:["heic"]},"image/heic-sequence":{source:"iana",extensions:["heics"]},"image/heif":{source:"iana",extensions:["heif"]},"image/heif-sequence":{source:"iana",extensions:["heifs"]},"image/hej2k":{source:"iana",extensions:["hej2"]},"image/hsj2":{source:"iana",extensions:["hsj2"]},"image/ief":{source:"iana",extensions:["ief"]},"image/jls":{source:"iana",extensions:["jls"]},"image/jp2":{source:"iana",compressible:!1,extensions:["jp2","jpg2"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/jph":{source:"iana",extensions:["jph"]},"image/jphc":{source:"iana",extensions:["jhc"]},"image/jpm":{source:"iana",compressible:!1,extensions:["jpm"]},"image/jpx":{source:"iana",compressible:!1,extensions:["jpx","jpf"]},"image/jxr":{source:"iana",extensions:["jxr"]},"image/jxra":{source:"iana",extensions:["jxra"]},"image/jxrs":{source:"iana",extensions:["jxrs"]},"image/jxs":{source:"iana",extensions:["jxs"]},"image/jxsc":{source:"iana",extensions:["jxsc"]},"image/jxsi":{source:"iana",extensions:["jxsi"]},"image/jxss":{source:"iana",extensions:["jxss"]},"image/ktx":{source:"iana",extensions:["ktx"]},"image/ktx2":{source:"iana",extensions:["ktx2"]},"image/naplps":{source:"iana"},"image/pjpeg":{compressible:!1},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/prs.btif":{source:"iana",extensions:["btif"]},"image/prs.pti":{source:"iana",extensions:["pti"]},"image/pwg-raster":{source:"iana"},"image/sgi":{source:"apache",extensions:["sgi"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/t38":{source:"iana",extensions:["t38"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tif","tiff"]},"image/tiff-fx":{source:"iana",extensions:["tfx"]},"image/vnd.adobe.photoshop":{source:"iana",compressible:!0,extensions:["psd"]},"image/vnd.airzip.accelerator.azv":{source:"iana",extensions:["azv"]},"image/vnd.cns.inf2":{source:"iana"},"image/vnd.dece.graphic":{source:"iana",extensions:["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{source:"iana",extensions:["djvu","djv"]},"image/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"image/vnd.dwg":{source:"iana",extensions:["dwg"]},"image/vnd.dxf":{source:"iana",extensions:["dxf"]},"image/vnd.fastbidsheet":{source:"iana",extensions:["fbs"]},"image/vnd.fpx":{source:"iana",extensions:["fpx"]},"image/vnd.fst":{source:"iana",extensions:["fst"]},"image/vnd.fujixerox.edmics-mmr":{source:"iana",extensions:["mmr"]},"image/vnd.fujixerox.edmics-rlc":{source:"iana",extensions:["rlc"]},"image/vnd.globalgraphics.pgb":{source:"iana"},"image/vnd.microsoft.icon":{source:"iana",compressible:!0,extensions:["ico"]},"image/vnd.mix":{source:"iana"},"image/vnd.mozilla.apng":{source:"iana"},"image/vnd.ms-dds":{compressible:!0,extensions:["dds"]},"image/vnd.ms-modi":{source:"iana",extensions:["mdi"]},"image/vnd.ms-photo":{source:"apache",extensions:["wdp"]},"image/vnd.net-fpx":{source:"iana",extensions:["npx"]},"image/vnd.pco.b16":{source:"iana",extensions:["b16"]},"image/vnd.radiance":{source:"iana"},"image/vnd.sealed.png":{source:"iana"},"image/vnd.sealedmedia.softseal.gif":{source:"iana"},"image/vnd.sealedmedia.softseal.jpg":{source:"iana"},"image/vnd.svf":{source:"iana"},"image/vnd.tencent.tap":{source:"iana",extensions:["tap"]},"image/vnd.valve.source.texture":{source:"iana",extensions:["vtf"]},"image/vnd.wap.wbmp":{source:"iana",extensions:["wbmp"]},"image/vnd.xiff":{source:"iana",extensions:["xif"]},"image/vnd.zbrush.pcx":{source:"iana",extensions:["pcx"]},"image/webp":{source:"apache",extensions:["webp"]},"image/wmf":{source:"iana",extensions:["wmf"]},"image/x-3ds":{source:"apache",extensions:["3ds"]},"image/x-cmu-raster":{source:"apache",extensions:["ras"]},"image/x-cmx":{source:"apache",extensions:["cmx"]},"image/x-freehand":{source:"apache",extensions:["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/x-jng":{source:"nginx",extensions:["jng"]},"image/x-mrsid-image":{source:"apache",extensions:["sid"]},"image/x-ms-bmp":{source:"nginx",compressible:!0,extensions:["bmp"]},"image/x-pcx":{source:"apache",extensions:["pcx"]},"image/x-pict":{source:"apache",extensions:["pic","pct"]},"image/x-portable-anymap":{source:"apache",extensions:["pnm"]},"image/x-portable-bitmap":{source:"apache",extensions:["pbm"]},"image/x-portable-graymap":{source:"apache",extensions:["pgm"]},"image/x-portable-pixmap":{source:"apache",extensions:["ppm"]},"image/x-rgb":{source:"apache",extensions:["rgb"]},"image/x-tga":{source:"apache",extensions:["tga"]},"image/x-xbitmap":{source:"apache",extensions:["xbm"]},"image/x-xcf":{compressible:!1},"image/x-xpixmap":{source:"apache",extensions:["xpm"]},"image/x-xwindowdump":{source:"apache",extensions:["xwd"]},"message/cpim":{source:"iana"},"message/delivery-status":{source:"iana"},"message/disposition-notification":{source:"iana",extensions:["disposition-notification"]},"message/external-body":{source:"iana"},"message/feedback-report":{source:"iana"},"message/global":{source:"iana",extensions:["u8msg"]},"message/global-delivery-status":{source:"iana",extensions:["u8dsn"]},"message/global-disposition-notification":{source:"iana",extensions:["u8mdn"]},"message/global-headers":{source:"iana",extensions:["u8hdr"]},"message/http":{source:"iana",compressible:!1},"message/imdn+xml":{source:"iana",compressible:!0},"message/news":{source:"iana"},"message/partial":{source:"iana",compressible:!1},"message/rfc822":{source:"iana",compressible:!0,extensions:["eml","mime"]},"message/s-http":{source:"iana"},"message/sip":{source:"iana"},"message/sipfrag":{source:"iana"},"message/tracking-status":{source:"iana"},"message/vnd.si.simp":{source:"iana"},"message/vnd.wfa.wsc":{source:"iana",extensions:["wsc"]},"model/3mf":{source:"iana",extensions:["3mf"]},"model/e57":{source:"iana"},"model/gltf+json":{source:"iana",compressible:!0,extensions:["gltf"]},"model/gltf-binary":{source:"iana",compressible:!0,extensions:["glb"]},"model/iges":{source:"iana",compressible:!1,extensions:["igs","iges"]},"model/mesh":{source:"iana",compressible:!1,extensions:["msh","mesh","silo"]},"model/mtl":{source:"iana",extensions:["mtl"]},"model/obj":{source:"iana",extensions:["obj"]},"model/step":{source:"iana"},"model/step+xml":{source:"iana",compressible:!0,extensions:["stpx"]},"model/step+zip":{source:"iana",compressible:!1,extensions:["stpz"]},"model/step-xml+zip":{source:"iana",compressible:!1,extensions:["stpxz"]},"model/stl":{source:"iana",extensions:["stl"]},"model/vnd.collada+xml":{source:"iana",compressible:!0,extensions:["dae"]},"model/vnd.dwf":{source:"iana",extensions:["dwf"]},"model/vnd.flatland.3dml":{source:"iana"},"model/vnd.gdl":{source:"iana",extensions:["gdl"]},"model/vnd.gs-gdl":{source:"apache"},"model/vnd.gs.gdl":{source:"iana"},"model/vnd.gtw":{source:"iana",extensions:["gtw"]},"model/vnd.moml+xml":{source:"iana",compressible:!0},"model/vnd.mts":{source:"iana",extensions:["mts"]},"model/vnd.opengex":{source:"iana",extensions:["ogex"]},"model/vnd.parasolid.transmit.binary":{source:"iana",extensions:["x_b"]},"model/vnd.parasolid.transmit.text":{source:"iana",extensions:["x_t"]},"model/vnd.pytha.pyox":{source:"iana"},"model/vnd.rosette.annotated-data-model":{source:"iana"},"model/vnd.sap.vds":{source:"iana",extensions:["vds"]},"model/vnd.usdz+zip":{source:"iana",compressible:!1,extensions:["usdz"]},"model/vnd.valve.source.compiled-map":{source:"iana",extensions:["bsp"]},"model/vnd.vtu":{source:"iana",extensions:["vtu"]},"model/vrml":{source:"iana",compressible:!1,extensions:["wrl","vrml"]},"model/x3d+binary":{source:"apache",compressible:!1,extensions:["x3db","x3dbz"]},"model/x3d+fastinfoset":{source:"iana",extensions:["x3db"]},"model/x3d+vrml":{source:"apache",compressible:!1,extensions:["x3dv","x3dvz"]},"model/x3d+xml":{source:"iana",compressible:!0,extensions:["x3d","x3dz"]},"model/x3d-vrml":{source:"iana",extensions:["x3dv"]},"multipart/alternative":{source:"iana",compressible:!1},"multipart/appledouble":{source:"iana"},"multipart/byteranges":{source:"iana"},"multipart/digest":{source:"iana"},"multipart/encrypted":{source:"iana",compressible:!1},"multipart/form-data":{source:"iana",compressible:!1},"multipart/header-set":{source:"iana"},"multipart/mixed":{source:"iana"},"multipart/multilingual":{source:"iana"},"multipart/parallel":{source:"iana"},"multipart/related":{source:"iana",compressible:!1},"multipart/report":{source:"iana"},"multipart/signed":{source:"iana",compressible:!1},"multipart/vnd.bint.med-plus":{source:"iana"},"multipart/voice-message":{source:"iana"},"multipart/x-mixed-replace":{source:"iana"},"text/1d-interleaved-parityfec":{source:"iana"},"text/cache-manifest":{source:"iana",compressible:!0,extensions:["appcache","manifest"]},"text/calendar":{source:"iana",extensions:["ics","ifb"]},"text/calender":{compressible:!0},"text/cmd":{compressible:!0},"text/coffeescript":{extensions:["coffee","litcoffee"]},"text/cql":{source:"iana"},"text/cql-expression":{source:"iana"},"text/cql-identifier":{source:"iana"},"text/css":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["css"]},"text/csv":{source:"iana",compressible:!0,extensions:["csv"]},"text/csv-schema":{source:"iana"},"text/directory":{source:"iana"},"text/dns":{source:"iana"},"text/ecmascript":{source:"iana"},"text/encaprtp":{source:"iana"},"text/enriched":{source:"iana"},"text/fhirpath":{source:"iana"},"text/flexfec":{source:"iana"},"text/fwdred":{source:"iana"},"text/gff3":{source:"iana"},"text/grammar-ref-list":{source:"iana"},"text/html":{source:"iana",compressible:!0,extensions:["html","htm","shtml"]},"text/jade":{extensions:["jade"]},"text/javascript":{source:"iana",compressible:!0},"text/jcr-cnd":{source:"iana"},"text/jsx":{compressible:!0,extensions:["jsx"]},"text/less":{compressible:!0,extensions:["less"]},"text/markdown":{source:"iana",compressible:!0,extensions:["markdown","md"]},"text/mathml":{source:"nginx",extensions:["mml"]},"text/mdx":{compressible:!0,extensions:["mdx"]},"text/mizar":{source:"iana"},"text/n3":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["n3"]},"text/parameters":{source:"iana",charset:"UTF-8"},"text/parityfec":{source:"iana"},"text/plain":{source:"iana",compressible:!0,extensions:["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{source:"iana",charset:"UTF-8"},"text/prs.fallenstein.rst":{source:"iana"},"text/prs.lines.tag":{source:"iana",extensions:["dsc"]},"text/prs.prop.logic":{source:"iana"},"text/raptorfec":{source:"iana"},"text/red":{source:"iana"},"text/rfc822-headers":{source:"iana"},"text/richtext":{source:"iana",compressible:!0,extensions:["rtx"]},"text/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"text/rtp-enc-aescm128":{source:"iana"},"text/rtploopback":{source:"iana"},"text/rtx":{source:"iana"},"text/sgml":{source:"iana",extensions:["sgml","sgm"]},"text/shaclc":{source:"iana"},"text/shex":{source:"iana",extensions:["shex"]},"text/slim":{extensions:["slim","slm"]},"text/spdx":{source:"iana",extensions:["spdx"]},"text/strings":{source:"iana"},"text/stylus":{extensions:["stylus","styl"]},"text/t140":{source:"iana"},"text/tab-separated-values":{source:"iana",compressible:!0,extensions:["tsv"]},"text/troff":{source:"iana",extensions:["t","tr","roff","man","me","ms"]},"text/turtle":{source:"iana",charset:"UTF-8",extensions:["ttl"]},"text/ulpfec":{source:"iana"},"text/uri-list":{source:"iana",compressible:!0,extensions:["uri","uris","urls"]},"text/vcard":{source:"iana",compressible:!0,extensions:["vcard"]},"text/vnd.a":{source:"iana"},"text/vnd.abc":{source:"iana"},"text/vnd.ascii-art":{source:"iana"},"text/vnd.curl":{source:"iana",extensions:["curl"]},"text/vnd.curl.dcurl":{source:"apache",extensions:["dcurl"]},"text/vnd.curl.mcurl":{source:"apache",extensions:["mcurl"]},"text/vnd.curl.scurl":{source:"apache",extensions:["scurl"]},"text/vnd.debian.copyright":{source:"iana",charset:"UTF-8"},"text/vnd.dmclientscript":{source:"iana"},"text/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"text/vnd.esmertec.theme-descriptor":{source:"iana",charset:"UTF-8"},"text/vnd.familysearch.gedcom":{source:"iana",extensions:["ged"]},"text/vnd.ficlab.flt":{source:"iana"},"text/vnd.fly":{source:"iana",extensions:["fly"]},"text/vnd.fmi.flexstor":{source:"iana",extensions:["flx"]},"text/vnd.gml":{source:"iana"},"text/vnd.graphviz":{source:"iana",extensions:["gv"]},"text/vnd.hans":{source:"iana"},"text/vnd.hgl":{source:"iana"},"text/vnd.in3d.3dml":{source:"iana",extensions:["3dml"]},"text/vnd.in3d.spot":{source:"iana",extensions:["spot"]},"text/vnd.iptc.newsml":{source:"iana"},"text/vnd.iptc.nitf":{source:"iana"},"text/vnd.latex-z":{source:"iana"},"text/vnd.motorola.reflex":{source:"iana"},"text/vnd.ms-mediapackage":{source:"iana"},"text/vnd.net2phone.commcenter.command":{source:"iana"},"text/vnd.radisys.msml-basic-layout":{source:"iana"},"text/vnd.senx.warpscript":{source:"iana"},"text/vnd.si.uricatalogue":{source:"iana"},"text/vnd.sosi":{source:"iana"},"text/vnd.sun.j2me.app-descriptor":{source:"iana",charset:"UTF-8",extensions:["jad"]},"text/vnd.trolltech.linguist":{source:"iana",charset:"UTF-8"},"text/vnd.wap.si":{source:"iana"},"text/vnd.wap.sl":{source:"iana"},"text/vnd.wap.wml":{source:"iana",extensions:["wml"]},"text/vnd.wap.wmlscript":{source:"iana",extensions:["wmls"]},"text/vtt":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["vtt"]},"text/x-asm":{source:"apache",extensions:["s","asm"]},"text/x-c":{source:"apache",extensions:["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{source:"nginx",extensions:["htc"]},"text/x-fortran":{source:"apache",extensions:["f","for","f77","f90"]},"text/x-gwt-rpc":{compressible:!0},"text/x-handlebars-template":{extensions:["hbs"]},"text/x-java-source":{source:"apache",extensions:["java"]},"text/x-jquery-tmpl":{compressible:!0},"text/x-lua":{extensions:["lua"]},"text/x-markdown":{compressible:!0,extensions:["mkd"]},"text/x-nfo":{source:"apache",extensions:["nfo"]},"text/x-opml":{source:"apache",extensions:["opml"]},"text/x-org":{compressible:!0,extensions:["org"]},"text/x-pascal":{source:"apache",extensions:["p","pas"]},"text/x-processing":{compressible:!0,extensions:["pde"]},"text/x-sass":{extensions:["sass"]},"text/x-scss":{extensions:["scss"]},"text/x-setext":{source:"apache",extensions:["etx"]},"text/x-sfv":{source:"apache",extensions:["sfv"]},"text/x-suse-ymp":{compressible:!0,extensions:["ymp"]},"text/x-uuencode":{source:"apache",extensions:["uu"]},"text/x-vcalendar":{source:"apache",extensions:["vcs"]},"text/x-vcard":{source:"apache",extensions:["vcf"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/xml-external-parsed-entity":{source:"iana"},"text/yaml":{compressible:!0,extensions:["yaml","yml"]},"video/1d-interleaved-parityfec":{source:"iana"},"video/3gpp":{source:"iana",extensions:["3gp","3gpp"]},"video/3gpp-tt":{source:"iana"},"video/3gpp2":{source:"iana",extensions:["3g2"]},"video/av1":{source:"iana"},"video/bmpeg":{source:"iana"},"video/bt656":{source:"iana"},"video/celb":{source:"iana"},"video/dv":{source:"iana"},"video/encaprtp":{source:"iana"},"video/ffv1":{source:"iana"},"video/flexfec":{source:"iana"},"video/h261":{source:"iana",extensions:["h261"]},"video/h263":{source:"iana",extensions:["h263"]},"video/h263-1998":{source:"iana"},"video/h263-2000":{source:"iana"},"video/h264":{source:"iana",extensions:["h264"]},"video/h264-rcdo":{source:"iana"},"video/h264-svc":{source:"iana"},"video/h265":{source:"iana"},"video/iso.segment":{source:"iana",extensions:["m4s"]},"video/jpeg":{source:"iana",extensions:["jpgv"]},"video/jpeg2000":{source:"iana"},"video/jpm":{source:"apache",extensions:["jpm","jpgm"]},"video/jxsv":{source:"iana"},"video/mj2":{source:"iana",extensions:["mj2","mjp2"]},"video/mp1s":{source:"iana"},"video/mp2p":{source:"iana"},"video/mp2t":{source:"iana",extensions:["ts"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","mp4v","mpg4"]},"video/mp4v-es":{source:"iana"},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{source:"iana"},"video/mpv":{source:"iana"},"video/nv":{source:"iana"},"video/ogg":{source:"iana",compressible:!1,extensions:["ogv"]},"video/parityfec":{source:"iana"},"video/pointer":{source:"iana"},"video/quicktime":{source:"iana",compressible:!1,extensions:["qt","mov"]},"video/raptorfec":{source:"iana"},"video/raw":{source:"iana"},"video/rtp-enc-aescm128":{source:"iana"},"video/rtploopback":{source:"iana"},"video/rtx":{source:"iana"},"video/scip":{source:"iana"},"video/smpte291":{source:"iana"},"video/smpte292m":{source:"iana"},"video/ulpfec":{source:"iana"},"video/vc1":{source:"iana"},"video/vc2":{source:"iana"},"video/vnd.cctv":{source:"iana"},"video/vnd.dece.hd":{source:"iana",extensions:["uvh","uvvh"]},"video/vnd.dece.mobile":{source:"iana",extensions:["uvm","uvvm"]},"video/vnd.dece.mp4":{source:"iana"},"video/vnd.dece.pd":{source:"iana",extensions:["uvp","uvvp"]},"video/vnd.dece.sd":{source:"iana",extensions:["uvs","uvvs"]},"video/vnd.dece.video":{source:"iana",extensions:["uvv","uvvv"]},"video/vnd.directv.mpeg":{source:"iana"},"video/vnd.directv.mpeg-tts":{source:"iana"},"video/vnd.dlna.mpeg-tts":{source:"iana"},"video/vnd.dvb.file":{source:"iana",extensions:["dvb"]},"video/vnd.fvt":{source:"iana",extensions:["fvt"]},"video/vnd.hns.video":{source:"iana"},"video/vnd.iptvforum.1dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.1dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.2dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.2dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.ttsavc":{source:"iana"},"video/vnd.iptvforum.ttsmpeg2":{source:"iana"},"video/vnd.motorola.video":{source:"iana"},"video/vnd.motorola.videop":{source:"iana"},"video/vnd.mpegurl":{source:"iana",extensions:["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{source:"iana",extensions:["pyv"]},"video/vnd.nokia.interleaved-multimedia":{source:"iana"},"video/vnd.nokia.mp4vr":{source:"iana"},"video/vnd.nokia.videovoip":{source:"iana"},"video/vnd.objectvideo":{source:"iana"},"video/vnd.radgamettools.bink":{source:"iana"},"video/vnd.radgamettools.smacker":{source:"iana"},"video/vnd.sealed.mpeg1":{source:"iana"},"video/vnd.sealed.mpeg4":{source:"iana"},"video/vnd.sealed.swf":{source:"iana"},"video/vnd.sealedmedia.softseal.mov":{source:"iana"},"video/vnd.uvvu.mp4":{source:"iana",extensions:["uvu","uvvu"]},"video/vnd.vivo":{source:"iana",extensions:["viv"]},"video/vnd.youtube.yt":{source:"iana"},"video/vp8":{source:"iana"},"video/vp9":{source:"iana"},"video/webm":{source:"apache",compressible:!1,extensions:["webm"]},"video/x-f4v":{source:"apache",extensions:["f4v"]},"video/x-fli":{source:"apache",extensions:["fli"]},"video/x-flv":{source:"apache",compressible:!1,extensions:["flv"]},"video/x-m4v":{source:"apache",extensions:["m4v"]},"video/x-matroska":{source:"apache",compressible:!1,extensions:["mkv","mk3d","mks"]},"video/x-mng":{source:"apache",extensions:["mng"]},"video/x-ms-asf":{source:"apache",extensions:["asf","asx"]},"video/x-ms-vob":{source:"apache",extensions:["vob"]},"video/x-ms-wm":{source:"apache",extensions:["wm"]},"video/x-ms-wmv":{source:"apache",compressible:!1,extensions:["wmv"]},"video/x-ms-wmx":{source:"apache",extensions:["wmx"]},"video/x-ms-wvx":{source:"apache",extensions:["wvx"]},"video/x-msvideo":{source:"apache",extensions:["avi"]},"video/x-sgi-movie":{source:"apache",extensions:["movie"]},"video/x-smv":{source:"apache",extensions:["smv"]},"x-conference/x-cooltalk":{source:"apache",extensions:["ice"]},"x-shader/x-fragment":{compressible:!0},"x-shader/x-vertex":{compressible:!0}}});var eh=_(function(CE){/*!
|
|
2
|
+
import{createRequire as n1}from"node:module";var J$=Object.create;var{getPrototypeOf:W$,defineProperty:Mc,getOwnPropertyNames:K$}=Object;var vf=Object.prototype.hasOwnProperty;function Y$(e){return this[e]}var X$,Q$,So=(e,t,r)=>{var n=e!=null&&typeof e==="object";if(n){var o=t?X$??=new WeakMap:Q$??=new WeakMap,i=o.get(e);if(i)return i}r=e!=null?J$(W$(e)):{};let s=t||!e||!e.__esModule||!vf.call(e,"default")?Mc(r,"default",{value:e,enumerable:!0}):r;if(e&&typeof e==="object"||typeof e==="function"){for(let a of K$(e))if(!vf.call(s,a))Mc(s,a,{get:Y$.bind(e,a),enumerable:!0})}if(n)o.set(e,s);return s};var b=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var e1=(e)=>e;function t1(e,t){this[e]=e1.bind(null,t)}var r1=(e,t)=>{for(var r in t)Mc(e,r,{get:t[r],enumerable:!0,configurable:!0,set:t1.bind(t,r)})};var us=(e,t,r)=>()=>{if(e)try{t=e(e=0)}catch(n){r=[n]}if(r)throw r[0];return t};var ge=n1(import.meta.url);var If=b(function(Z4,Cf){var Af=ge("stream").Stream,sT=ge("util");Cf.exports=Zt;function Zt(){this.source=null,this.dataSize=0,this.maxDataSize=1048576,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}sT.inherits(Zt,Af);Zt.create=function(e,t){var r=new this;t=t||{};for(var n in t)r[n]=t[n];r.source=e;var o=e.emit;if(e.emit=function(){return r._handleEmit(arguments),o.apply(e,arguments)},e.on("error",function(){}),r.pauseStream)e.pause();return r};Object.defineProperty(Zt.prototype,"readable",{configurable:!0,enumerable:!0,get:function(){return this.source.readable}});Zt.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};Zt.prototype.resume=function(){if(!this._released)this.release();this.source.resume()};Zt.prototype.pause=function(){this.source.pause()};Zt.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};Zt.prototype.pipe=function(){var e=Af.prototype.pipe.apply(this,arguments);return this.resume(),e};Zt.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}if(e[0]==="data")this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded();this._bufferedEvents.push(e)};Zt.prototype._checkIfMaxDataSizeExceeded=function(){if(this._maxDataSizeExceeded)return;if(this.dataSize<=this.maxDataSize)return;this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",Error(e))}});var Mf=b(function(B4,Df){var aT=ge("util"),Nf=ge("stream").Stream,jf=If();Df.exports=Ce;function Ce(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2097152,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}aT.inherits(Ce,Nf);Ce.create=function(e){var t=new this;e=e||{};for(var r in e)t[r]=e[r];return t};Ce.isStreamLike=function(e){return typeof e!=="function"&&typeof e!=="string"&&typeof e!=="boolean"&&typeof e!=="number"&&!Buffer.isBuffer(e)};Ce.prototype.append=function(e){var t=Ce.isStreamLike(e);if(t){if(!(e instanceof jf)){var r=jf.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=r}if(this._handleErrors(e),this.pauseStreams)e.pause()}return this._streams.push(e),this};Ce.prototype.pipe=function(e,t){return Nf.prototype.pipe.call(this,e,t),this.resume(),e};Ce.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop){this._pendingNext=!0;return}this._insideLoop=!0;try{do this._pendingNext=!1,this._realGetNext();while(this._pendingNext)}finally{this._insideLoop=!1}};Ce.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e>"u"){this.end();return}if(typeof e!=="function"){this._pipeNext(e);return}var t=e;t(function(r){var n=Ce.isStreamLike(r);if(n)r.on("data",this._checkDataSize.bind(this)),this._handleErrors(r);this._pipeNext(r)}.bind(this))};Ce.prototype._pipeNext=function(e){this._currentStream=e;var t=Ce.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this)),e.pipe(this,{end:!1});return}var r=e;this.write(r),this._getNext()};Ce.prototype._handleErrors=function(e){var t=this;e.on("error",function(r){t._emitError(r)})};Ce.prototype.write=function(e){this.emit("data",e)};Ce.prototype.pause=function(){if(!this.pauseStreams)return;if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function")this._currentStream.pause();this.emit("pause")};Ce.prototype.resume=function(){if(!this._released)this._released=!0,this.writable=!0,this._getNext();if(this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function")this._currentStream.resume();this.emit("resume")};Ce.prototype.end=function(){this._reset(),this.emit("end")};Ce.prototype.destroy=function(){this._reset(),this.emit("close")};Ce.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};Ce.prototype._checkDataSize=function(){if(this._updateDataSize(),this.dataSize<=this.maxDataSize)return;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(Error(e))};Ce.prototype._updateDataSize=function(){this.dataSize=0;var e=this;if(this._streams.forEach(function(t){if(!t.dataSize)return;e.dataSize+=t.dataSize}),this._currentStream&&this._currentStream.dataSize)this.dataSize+=this._currentStream.dataSize};Ce.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var Lf=b(function(H4,cT){cT.exports={"application/1d-interleaved-parityfec":{source:"iana"},"application/3gpdash-qoe-report+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/3gpp-ims+xml":{source:"iana",compressible:!0},"application/3gpphal+json":{source:"iana",compressible:!0},"application/3gpphalforms+json":{source:"iana",compressible:!0},"application/a2l":{source:"iana"},"application/ace+cbor":{source:"iana"},"application/activemessage":{source:"iana"},"application/activity+json":{source:"iana",compressible:!0},"application/alto-costmap+json":{source:"iana",compressible:!0},"application/alto-costmapfilter+json":{source:"iana",compressible:!0},"application/alto-directory+json":{source:"iana",compressible:!0},"application/alto-endpointcost+json":{source:"iana",compressible:!0},"application/alto-endpointcostparams+json":{source:"iana",compressible:!0},"application/alto-endpointprop+json":{source:"iana",compressible:!0},"application/alto-endpointpropparams+json":{source:"iana",compressible:!0},"application/alto-error+json":{source:"iana",compressible:!0},"application/alto-networkmap+json":{source:"iana",compressible:!0},"application/alto-networkmapfilter+json":{source:"iana",compressible:!0},"application/alto-updatestreamcontrol+json":{source:"iana",compressible:!0},"application/alto-updatestreamparams+json":{source:"iana",compressible:!0},"application/aml":{source:"iana"},"application/andrew-inset":{source:"iana",extensions:["ez"]},"application/applefile":{source:"iana"},"application/applixware":{source:"apache",extensions:["aw"]},"application/at+jwt":{source:"iana"},"application/atf":{source:"iana"},"application/atfx":{source:"iana"},"application/atom+xml":{source:"iana",compressible:!0,extensions:["atom"]},"application/atomcat+xml":{source:"iana",compressible:!0,extensions:["atomcat"]},"application/atomdeleted+xml":{source:"iana",compressible:!0,extensions:["atomdeleted"]},"application/atomicmail":{source:"iana"},"application/atomsvc+xml":{source:"iana",compressible:!0,extensions:["atomsvc"]},"application/atsc-dwd+xml":{source:"iana",compressible:!0,extensions:["dwd"]},"application/atsc-dynamic-event-message":{source:"iana"},"application/atsc-held+xml":{source:"iana",compressible:!0,extensions:["held"]},"application/atsc-rdt+json":{source:"iana",compressible:!0},"application/atsc-rsat+xml":{source:"iana",compressible:!0,extensions:["rsat"]},"application/atxml":{source:"iana"},"application/auth-policy+xml":{source:"iana",compressible:!0},"application/bacnet-xdd+zip":{source:"iana",compressible:!1},"application/batch-smtp":{source:"iana"},"application/bdoc":{compressible:!1,extensions:["bdoc"]},"application/beep+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/calendar+json":{source:"iana",compressible:!0},"application/calendar+xml":{source:"iana",compressible:!0,extensions:["xcs"]},"application/call-completion":{source:"iana"},"application/cals-1840":{source:"iana"},"application/captive+json":{source:"iana",compressible:!0},"application/cbor":{source:"iana"},"application/cbor-seq":{source:"iana"},"application/cccex":{source:"iana"},"application/ccmp+xml":{source:"iana",compressible:!0},"application/ccxml+xml":{source:"iana",compressible:!0,extensions:["ccxml"]},"application/cdfx+xml":{source:"iana",compressible:!0,extensions:["cdfx"]},"application/cdmi-capability":{source:"iana",extensions:["cdmia"]},"application/cdmi-container":{source:"iana",extensions:["cdmic"]},"application/cdmi-domain":{source:"iana",extensions:["cdmid"]},"application/cdmi-object":{source:"iana",extensions:["cdmio"]},"application/cdmi-queue":{source:"iana",extensions:["cdmiq"]},"application/cdni":{source:"iana"},"application/cea":{source:"iana"},"application/cea-2018+xml":{source:"iana",compressible:!0},"application/cellml+xml":{source:"iana",compressible:!0},"application/cfw":{source:"iana"},"application/city+json":{source:"iana",compressible:!0},"application/clr":{source:"iana"},"application/clue+xml":{source:"iana",compressible:!0},"application/clue_info+xml":{source:"iana",compressible:!0},"application/cms":{source:"iana"},"application/cnrp+xml":{source:"iana",compressible:!0},"application/coap-group+json":{source:"iana",compressible:!0},"application/coap-payload":{source:"iana"},"application/commonground":{source:"iana"},"application/conference-info+xml":{source:"iana",compressible:!0},"application/cose":{source:"iana"},"application/cose-key":{source:"iana"},"application/cose-key-set":{source:"iana"},"application/cpl+xml":{source:"iana",compressible:!0,extensions:["cpl"]},"application/csrattrs":{source:"iana"},"application/csta+xml":{source:"iana",compressible:!0},"application/cstadata+xml":{source:"iana",compressible:!0},"application/csvm+json":{source:"iana",compressible:!0},"application/cu-seeme":{source:"apache",extensions:["cu"]},"application/cwt":{source:"iana"},"application/cybercash":{source:"iana"},"application/dart":{compressible:!0},"application/dash+xml":{source:"iana",compressible:!0,extensions:["mpd"]},"application/dash-patch+xml":{source:"iana",compressible:!0,extensions:["mpp"]},"application/dashdelta":{source:"iana"},"application/davmount+xml":{source:"iana",compressible:!0,extensions:["davmount"]},"application/dca-rft":{source:"iana"},"application/dcd":{source:"iana"},"application/dec-dx":{source:"iana"},"application/dialog-info+xml":{source:"iana",compressible:!0},"application/dicom":{source:"iana"},"application/dicom+json":{source:"iana",compressible:!0},"application/dicom+xml":{source:"iana",compressible:!0},"application/dii":{source:"iana"},"application/dit":{source:"iana"},"application/dns":{source:"iana"},"application/dns+json":{source:"iana",compressible:!0},"application/dns-message":{source:"iana"},"application/docbook+xml":{source:"apache",compressible:!0,extensions:["dbk"]},"application/dots+cbor":{source:"iana"},"application/dskpp+xml":{source:"iana",compressible:!0},"application/dssc+der":{source:"iana",extensions:["dssc"]},"application/dssc+xml":{source:"iana",compressible:!0,extensions:["xdssc"]},"application/dvcs":{source:"iana"},"application/ecmascript":{source:"iana",compressible:!0,extensions:["es","ecma"]},"application/edi-consent":{source:"iana"},"application/edi-x12":{source:"iana",compressible:!1},"application/edifact":{source:"iana",compressible:!1},"application/efi":{source:"iana"},"application/elm+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/elm+xml":{source:"iana",compressible:!0},"application/emergencycalldata.cap+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/emergencycalldata.comment+xml":{source:"iana",compressible:!0},"application/emergencycalldata.control+xml":{source:"iana",compressible:!0},"application/emergencycalldata.deviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.ecall.msd":{source:"iana"},"application/emergencycalldata.providerinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.serviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.subscriberinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.veds+xml":{source:"iana",compressible:!0},"application/emma+xml":{source:"iana",compressible:!0,extensions:["emma"]},"application/emotionml+xml":{source:"iana",compressible:!0,extensions:["emotionml"]},"application/encaprtp":{source:"iana"},"application/epp+xml":{source:"iana",compressible:!0},"application/epub+zip":{source:"iana",compressible:!1,extensions:["epub"]},"application/eshop":{source:"iana"},"application/exi":{source:"iana",extensions:["exi"]},"application/expect-ct-report+json":{source:"iana",compressible:!0},"application/express":{source:"iana",extensions:["exp"]},"application/fastinfoset":{source:"iana"},"application/fastsoap":{source:"iana"},"application/fdt+xml":{source:"iana",compressible:!0,extensions:["fdt"]},"application/fhir+json":{source:"iana",charset:"UTF-8",compressible:!0},"application/fhir+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/fido.trusted-apps+json":{compressible:!0},"application/fits":{source:"iana"},"application/flexfec":{source:"iana"},"application/font-sfnt":{source:"iana"},"application/font-tdpfr":{source:"iana",extensions:["pfr"]},"application/font-woff":{source:"iana",compressible:!1},"application/framework-attributes+xml":{source:"iana",compressible:!0},"application/geo+json":{source:"iana",compressible:!0,extensions:["geojson"]},"application/geo+json-seq":{source:"iana"},"application/geopackage+sqlite3":{source:"iana"},"application/geoxacml+xml":{source:"iana",compressible:!0},"application/gltf-buffer":{source:"iana"},"application/gml+xml":{source:"iana",compressible:!0,extensions:["gml"]},"application/gpx+xml":{source:"apache",compressible:!0,extensions:["gpx"]},"application/gxf":{source:"apache",extensions:["gxf"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/h224":{source:"iana"},"application/held+xml":{source:"iana",compressible:!0},"application/hjson":{extensions:["hjson"]},"application/http":{source:"iana"},"application/hyperstudio":{source:"iana",extensions:["stk"]},"application/ibe-key-request+xml":{source:"iana",compressible:!0},"application/ibe-pkg-reply+xml":{source:"iana",compressible:!0},"application/ibe-pp-data":{source:"iana"},"application/iges":{source:"iana"},"application/im-iscomposing+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/index":{source:"iana"},"application/index.cmd":{source:"iana"},"application/index.obj":{source:"iana"},"application/index.response":{source:"iana"},"application/index.vnd":{source:"iana"},"application/inkml+xml":{source:"iana",compressible:!0,extensions:["ink","inkml"]},"application/iotp":{source:"iana"},"application/ipfix":{source:"iana",extensions:["ipfix"]},"application/ipp":{source:"iana"},"application/isup":{source:"iana"},"application/its+xml":{source:"iana",compressible:!0,extensions:["its"]},"application/java-archive":{source:"apache",compressible:!1,extensions:["jar","war","ear"]},"application/java-serialized-object":{source:"apache",compressible:!1,extensions:["ser"]},"application/java-vm":{source:"apache",compressible:!1,extensions:["class"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/jf2feed+json":{source:"iana",compressible:!0},"application/jose":{source:"iana"},"application/jose+json":{source:"iana",compressible:!0},"application/jrd+json":{source:"iana",compressible:!0},"application/jscalendar+json":{source:"iana",compressible:!0},"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/json-patch+json":{source:"iana",compressible:!0},"application/json-seq":{source:"iana"},"application/json5":{extensions:["json5"]},"application/jsonml+json":{source:"apache",compressible:!0,extensions:["jsonml"]},"application/jwk+json":{source:"iana",compressible:!0},"application/jwk-set+json":{source:"iana",compressible:!0},"application/jwt":{source:"iana"},"application/kpml-request+xml":{source:"iana",compressible:!0},"application/kpml-response+xml":{source:"iana",compressible:!0},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/lgr+xml":{source:"iana",compressible:!0,extensions:["lgr"]},"application/link-format":{source:"iana"},"application/load-control+xml":{source:"iana",compressible:!0},"application/lost+xml":{source:"iana",compressible:!0,extensions:["lostxml"]},"application/lostsync+xml":{source:"iana",compressible:!0},"application/lpf+zip":{source:"iana",compressible:!1},"application/lxf":{source:"iana"},"application/mac-binhex40":{source:"iana",extensions:["hqx"]},"application/mac-compactpro":{source:"apache",extensions:["cpt"]},"application/macwriteii":{source:"iana"},"application/mads+xml":{source:"iana",compressible:!0,extensions:["mads"]},"application/manifest+json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/marc":{source:"iana",extensions:["mrc"]},"application/marcxml+xml":{source:"iana",compressible:!0,extensions:["mrcx"]},"application/mathematica":{source:"iana",extensions:["ma","nb","mb"]},"application/mathml+xml":{source:"iana",compressible:!0,extensions:["mathml"]},"application/mathml-content+xml":{source:"iana",compressible:!0},"application/mathml-presentation+xml":{source:"iana",compressible:!0},"application/mbms-associated-procedure-description+xml":{source:"iana",compressible:!0},"application/mbms-deregister+xml":{source:"iana",compressible:!0},"application/mbms-envelope+xml":{source:"iana",compressible:!0},"application/mbms-msk+xml":{source:"iana",compressible:!0},"application/mbms-msk-response+xml":{source:"iana",compressible:!0},"application/mbms-protection-description+xml":{source:"iana",compressible:!0},"application/mbms-reception-report+xml":{source:"iana",compressible:!0},"application/mbms-register+xml":{source:"iana",compressible:!0},"application/mbms-register-response+xml":{source:"iana",compressible:!0},"application/mbms-schedule+xml":{source:"iana",compressible:!0},"application/mbms-user-service-description+xml":{source:"iana",compressible:!0},"application/mbox":{source:"iana",extensions:["mbox"]},"application/media-policy-dataset+xml":{source:"iana",compressible:!0,extensions:["mpf"]},"application/media_control+xml":{source:"iana",compressible:!0},"application/mediaservercontrol+xml":{source:"iana",compressible:!0,extensions:["mscml"]},"application/merge-patch+json":{source:"iana",compressible:!0},"application/metalink+xml":{source:"apache",compressible:!0,extensions:["metalink"]},"application/metalink4+xml":{source:"iana",compressible:!0,extensions:["meta4"]},"application/mets+xml":{source:"iana",compressible:!0,extensions:["mets"]},"application/mf4":{source:"iana"},"application/mikey":{source:"iana"},"application/mipc":{source:"iana"},"application/missing-blocks+cbor-seq":{source:"iana"},"application/mmt-aei+xml":{source:"iana",compressible:!0,extensions:["maei"]},"application/mmt-usd+xml":{source:"iana",compressible:!0,extensions:["musd"]},"application/mods+xml":{source:"iana",compressible:!0,extensions:["mods"]},"application/moss-keys":{source:"iana"},"application/moss-signature":{source:"iana"},"application/mosskey-data":{source:"iana"},"application/mosskey-request":{source:"iana"},"application/mp21":{source:"iana",extensions:["m21","mp21"]},"application/mp4":{source:"iana",extensions:["mp4s","m4p"]},"application/mpeg4-generic":{source:"iana"},"application/mpeg4-iod":{source:"iana"},"application/mpeg4-iod-xmt":{source:"iana"},"application/mrb-consumer+xml":{source:"iana",compressible:!0},"application/mrb-publish+xml":{source:"iana",compressible:!0},"application/msc-ivr+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msc-mixer+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/msword":{source:"iana",compressible:!1,extensions:["doc","dot"]},"application/mud+json":{source:"iana",compressible:!0},"application/multipart-core":{source:"iana"},"application/mxf":{source:"iana",extensions:["mxf"]},"application/n-quads":{source:"iana",extensions:["nq"]},"application/n-triples":{source:"iana",extensions:["nt"]},"application/nasdata":{source:"iana"},"application/news-checkgroups":{source:"iana",charset:"US-ASCII"},"application/news-groupinfo":{source:"iana",charset:"US-ASCII"},"application/news-transmission":{source:"iana"},"application/nlsml+xml":{source:"iana",compressible:!0},"application/node":{source:"iana",extensions:["cjs"]},"application/nss":{source:"iana"},"application/oauth-authz-req+jwt":{source:"iana"},"application/oblivious-dns-message":{source:"iana"},"application/ocsp-request":{source:"iana"},"application/ocsp-response":{source:"iana"},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{source:"iana",extensions:["oda"]},"application/odm+xml":{source:"iana",compressible:!0},"application/odx":{source:"iana"},"application/oebps-package+xml":{source:"iana",compressible:!0,extensions:["opf"]},"application/ogg":{source:"iana",compressible:!1,extensions:["ogx"]},"application/omdoc+xml":{source:"apache",compressible:!0,extensions:["omdoc"]},"application/onenote":{source:"apache",extensions:["onetoc","onetoc2","onetmp","onepkg"]},"application/opc-nodeset+xml":{source:"iana",compressible:!0},"application/oscore":{source:"iana"},"application/oxps":{source:"iana",extensions:["oxps"]},"application/p21":{source:"iana"},"application/p21+zip":{source:"iana",compressible:!1},"application/p2p-overlay+xml":{source:"iana",compressible:!0,extensions:["relo"]},"application/parityfec":{source:"iana"},"application/passport":{source:"iana"},"application/patch-ops-error+xml":{source:"iana",compressible:!0,extensions:["xer"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/pdx":{source:"iana"},"application/pem-certificate-chain":{source:"iana"},"application/pgp-encrypted":{source:"iana",compressible:!1,extensions:["pgp"]},"application/pgp-keys":{source:"iana",extensions:["asc"]},"application/pgp-signature":{source:"iana",extensions:["asc","sig"]},"application/pics-rules":{source:"apache",extensions:["prf"]},"application/pidf+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pidf-diff+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/pkcs10":{source:"iana",extensions:["p10"]},"application/pkcs12":{source:"iana"},"application/pkcs7-mime":{source:"iana",extensions:["p7m","p7c"]},"application/pkcs7-signature":{source:"iana",extensions:["p7s"]},"application/pkcs8":{source:"iana",extensions:["p8"]},"application/pkcs8-encrypted":{source:"iana"},"application/pkix-attr-cert":{source:"iana",extensions:["ac"]},"application/pkix-cert":{source:"iana",extensions:["cer"]},"application/pkix-crl":{source:"iana",extensions:["crl"]},"application/pkix-pkipath":{source:"iana",extensions:["pkipath"]},"application/pkixcmp":{source:"iana",extensions:["pki"]},"application/pls+xml":{source:"iana",compressible:!0,extensions:["pls"]},"application/poc-settings+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/postscript":{source:"iana",compressible:!0,extensions:["ai","eps","ps"]},"application/ppsp-tracker+json":{source:"iana",compressible:!0},"application/problem+json":{source:"iana",compressible:!0},"application/problem+xml":{source:"iana",compressible:!0},"application/provenance+xml":{source:"iana",compressible:!0,extensions:["provx"]},"application/prs.alvestrand.titrax-sheet":{source:"iana"},"application/prs.cww":{source:"iana",extensions:["cww"]},"application/prs.cyn":{source:"iana",charset:"7-BIT"},"application/prs.hpub+zip":{source:"iana",compressible:!1},"application/prs.nprend":{source:"iana"},"application/prs.plucker":{source:"iana"},"application/prs.rdf-xml-crypt":{source:"iana"},"application/prs.xsf+xml":{source:"iana",compressible:!0},"application/pskc+xml":{source:"iana",compressible:!0,extensions:["pskcxml"]},"application/pvd+json":{source:"iana",compressible:!0},"application/qsig":{source:"iana"},"application/raml+yaml":{compressible:!0,extensions:["raml"]},"application/raptorfec":{source:"iana"},"application/rdap+json":{source:"iana",compressible:!0},"application/rdf+xml":{source:"iana",compressible:!0,extensions:["rdf","owl"]},"application/reginfo+xml":{source:"iana",compressible:!0,extensions:["rif"]},"application/relax-ng-compact-syntax":{source:"iana",extensions:["rnc"]},"application/remote-printing":{source:"iana"},"application/reputon+json":{source:"iana",compressible:!0},"application/resource-lists+xml":{source:"iana",compressible:!0,extensions:["rl"]},"application/resource-lists-diff+xml":{source:"iana",compressible:!0,extensions:["rld"]},"application/rfc+xml":{source:"iana",compressible:!0},"application/riscos":{source:"iana"},"application/rlmi+xml":{source:"iana",compressible:!0},"application/rls-services+xml":{source:"iana",compressible:!0,extensions:["rs"]},"application/route-apd+xml":{source:"iana",compressible:!0,extensions:["rapd"]},"application/route-s-tsid+xml":{source:"iana",compressible:!0,extensions:["sls"]},"application/route-usd+xml":{source:"iana",compressible:!0,extensions:["rusd"]},"application/rpki-ghostbusters":{source:"iana",extensions:["gbr"]},"application/rpki-manifest":{source:"iana",extensions:["mft"]},"application/rpki-publication":{source:"iana"},"application/rpki-roa":{source:"iana",extensions:["roa"]},"application/rpki-updown":{source:"iana"},"application/rsd+xml":{source:"apache",compressible:!0,extensions:["rsd"]},"application/rss+xml":{source:"apache",compressible:!0,extensions:["rss"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/rtploopback":{source:"iana"},"application/rtx":{source:"iana"},"application/samlassertion+xml":{source:"iana",compressible:!0},"application/samlmetadata+xml":{source:"iana",compressible:!0},"application/sarif+json":{source:"iana",compressible:!0},"application/sarif-external-properties+json":{source:"iana",compressible:!0},"application/sbe":{source:"iana"},"application/sbml+xml":{source:"iana",compressible:!0,extensions:["sbml"]},"application/scaip+xml":{source:"iana",compressible:!0},"application/scim+json":{source:"iana",compressible:!0},"application/scvp-cv-request":{source:"iana",extensions:["scq"]},"application/scvp-cv-response":{source:"iana",extensions:["scs"]},"application/scvp-vp-request":{source:"iana",extensions:["spq"]},"application/scvp-vp-response":{source:"iana",extensions:["spp"]},"application/sdp":{source:"iana",extensions:["sdp"]},"application/secevent+jwt":{source:"iana"},"application/senml+cbor":{source:"iana"},"application/senml+json":{source:"iana",compressible:!0},"application/senml+xml":{source:"iana",compressible:!0,extensions:["senmlx"]},"application/senml-etch+cbor":{source:"iana"},"application/senml-etch+json":{source:"iana",compressible:!0},"application/senml-exi":{source:"iana"},"application/sensml+cbor":{source:"iana"},"application/sensml+json":{source:"iana",compressible:!0},"application/sensml+xml":{source:"iana",compressible:!0,extensions:["sensmlx"]},"application/sensml-exi":{source:"iana"},"application/sep+xml":{source:"iana",compressible:!0},"application/sep-exi":{source:"iana"},"application/session-info":{source:"iana"},"application/set-payment":{source:"iana"},"application/set-payment-initiation":{source:"iana",extensions:["setpay"]},"application/set-registration":{source:"iana"},"application/set-registration-initiation":{source:"iana",extensions:["setreg"]},"application/sgml":{source:"iana"},"application/sgml-open-catalog":{source:"iana"},"application/shf+xml":{source:"iana",compressible:!0,extensions:["shf"]},"application/sieve":{source:"iana",extensions:["siv","sieve"]},"application/simple-filter+xml":{source:"iana",compressible:!0},"application/simple-message-summary":{source:"iana"},"application/simplesymbolcontainer":{source:"iana"},"application/sipc":{source:"iana"},"application/slate":{source:"iana"},"application/smil":{source:"iana"},"application/smil+xml":{source:"iana",compressible:!0,extensions:["smi","smil"]},"application/smpte336m":{source:"iana"},"application/soap+fastinfoset":{source:"iana"},"application/soap+xml":{source:"iana",compressible:!0},"application/sparql-query":{source:"iana",extensions:["rq"]},"application/sparql-results+xml":{source:"iana",compressible:!0,extensions:["srx"]},"application/spdx+json":{source:"iana",compressible:!0},"application/spirits-event+xml":{source:"iana",compressible:!0},"application/sql":{source:"iana"},"application/srgs":{source:"iana",extensions:["gram"]},"application/srgs+xml":{source:"iana",compressible:!0,extensions:["grxml"]},"application/sru+xml":{source:"iana",compressible:!0,extensions:["sru"]},"application/ssdl+xml":{source:"apache",compressible:!0,extensions:["ssdl"]},"application/ssml+xml":{source:"iana",compressible:!0,extensions:["ssml"]},"application/stix+json":{source:"iana",compressible:!0},"application/swid+xml":{source:"iana",compressible:!0,extensions:["swidtag"]},"application/tamp-apex-update":{source:"iana"},"application/tamp-apex-update-confirm":{source:"iana"},"application/tamp-community-update":{source:"iana"},"application/tamp-community-update-confirm":{source:"iana"},"application/tamp-error":{source:"iana"},"application/tamp-sequence-adjust":{source:"iana"},"application/tamp-sequence-adjust-confirm":{source:"iana"},"application/tamp-status-query":{source:"iana"},"application/tamp-status-response":{source:"iana"},"application/tamp-update":{source:"iana"},"application/tamp-update-confirm":{source:"iana"},"application/tar":{compressible:!0},"application/taxii+json":{source:"iana",compressible:!0},"application/td+json":{source:"iana",compressible:!0},"application/tei+xml":{source:"iana",compressible:!0,extensions:["tei","teicorpus"]},"application/tetra_isi":{source:"iana"},"application/thraud+xml":{source:"iana",compressible:!0,extensions:["tfi"]},"application/timestamp-query":{source:"iana"},"application/timestamp-reply":{source:"iana"},"application/timestamped-data":{source:"iana",extensions:["tsd"]},"application/tlsrpt+gzip":{source:"iana"},"application/tlsrpt+json":{source:"iana",compressible:!0},"application/tnauthlist":{source:"iana"},"application/token-introspection+jwt":{source:"iana"},"application/toml":{compressible:!0,extensions:["toml"]},"application/trickle-ice-sdpfrag":{source:"iana"},"application/trig":{source:"iana",extensions:["trig"]},"application/ttml+xml":{source:"iana",compressible:!0,extensions:["ttml"]},"application/tve-trigger":{source:"iana"},"application/tzif":{source:"iana"},"application/tzif-leap":{source:"iana"},"application/ubjson":{compressible:!1,extensions:["ubj"]},"application/ulpfec":{source:"iana"},"application/urc-grpsheet+xml":{source:"iana",compressible:!0},"application/urc-ressheet+xml":{source:"iana",compressible:!0,extensions:["rsheet"]},"application/urc-targetdesc+xml":{source:"iana",compressible:!0,extensions:["td"]},"application/urc-uisocketdesc+xml":{source:"iana",compressible:!0},"application/vcard+json":{source:"iana",compressible:!0},"application/vcard+xml":{source:"iana",compressible:!0},"application/vemmi":{source:"iana"},"application/vividence.scriptfile":{source:"apache"},"application/vnd.1000minds.decision-model+xml":{source:"iana",compressible:!0,extensions:["1km"]},"application/vnd.3gpp-prose+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-prose-pc3ch+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-v2x-local-service-information":{source:"iana"},"application/vnd.3gpp.5gnas":{source:"iana"},"application/vnd.3gpp.access-transfer-events+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.bsf+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gmop+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gtpc":{source:"iana"},"application/vnd.3gpp.interworking-data":{source:"iana"},"application/vnd.3gpp.lpp":{source:"iana"},"application/vnd.3gpp.mc-signalling-ear":{source:"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-payload":{source:"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-signalling":{source:"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-floor-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-signed+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-init-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-transmission-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mid-call+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ngap":{source:"iana"},"application/vnd.3gpp.pfcp":{source:"iana"},"application/vnd.3gpp.pic-bw-large":{source:"iana",extensions:["plb"]},"application/vnd.3gpp.pic-bw-small":{source:"iana",extensions:["psb"]},"application/vnd.3gpp.pic-bw-var":{source:"iana",extensions:["pvb"]},"application/vnd.3gpp.s1ap":{source:"iana"},"application/vnd.3gpp.sms":{source:"iana"},"application/vnd.3gpp.sms+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-ext+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.state-and-event-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ussd+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.bcmcsinfo+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.sms":{source:"iana"},"application/vnd.3gpp2.tcap":{source:"iana",extensions:["tcap"]},"application/vnd.3lightssoftware.imagescal":{source:"iana"},"application/vnd.3m.post-it-notes":{source:"iana",extensions:["pwn"]},"application/vnd.accpac.simply.aso":{source:"iana",extensions:["aso"]},"application/vnd.accpac.simply.imp":{source:"iana",extensions:["imp"]},"application/vnd.acucobol":{source:"iana",extensions:["acu"]},"application/vnd.acucorp":{source:"iana",extensions:["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{source:"apache",compressible:!1,extensions:["air"]},"application/vnd.adobe.flash.movie":{source:"iana"},"application/vnd.adobe.formscentral.fcdt":{source:"iana",extensions:["fcdt"]},"application/vnd.adobe.fxp":{source:"iana",extensions:["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{source:"iana"},"application/vnd.adobe.xdp+xml":{source:"iana",compressible:!0,extensions:["xdp"]},"application/vnd.adobe.xfdf":{source:"iana",extensions:["xfdf"]},"application/vnd.aether.imp":{source:"iana"},"application/vnd.afpc.afplinedata":{source:"iana"},"application/vnd.afpc.afplinedata-pagedef":{source:"iana"},"application/vnd.afpc.cmoca-cmresource":{source:"iana"},"application/vnd.afpc.foca-charset":{source:"iana"},"application/vnd.afpc.foca-codedfont":{source:"iana"},"application/vnd.afpc.foca-codepage":{source:"iana"},"application/vnd.afpc.modca":{source:"iana"},"application/vnd.afpc.modca-cmtable":{source:"iana"},"application/vnd.afpc.modca-formdef":{source:"iana"},"application/vnd.afpc.modca-mediummap":{source:"iana"},"application/vnd.afpc.modca-objectcontainer":{source:"iana"},"application/vnd.afpc.modca-overlay":{source:"iana"},"application/vnd.afpc.modca-pagesegment":{source:"iana"},"application/vnd.age":{source:"iana",extensions:["age"]},"application/vnd.ah-barcode":{source:"iana"},"application/vnd.ahead.space":{source:"iana",extensions:["ahead"]},"application/vnd.airzip.filesecure.azf":{source:"iana",extensions:["azf"]},"application/vnd.airzip.filesecure.azs":{source:"iana",extensions:["azs"]},"application/vnd.amadeus+json":{source:"iana",compressible:!0},"application/vnd.amazon.ebook":{source:"apache",extensions:["azw"]},"application/vnd.amazon.mobi8-ebook":{source:"iana"},"application/vnd.americandynamics.acc":{source:"iana",extensions:["acc"]},"application/vnd.amiga.ami":{source:"iana",extensions:["ami"]},"application/vnd.amundsen.maze+xml":{source:"iana",compressible:!0},"application/vnd.android.ota":{source:"iana"},"application/vnd.android.package-archive":{source:"apache",compressible:!1,extensions:["apk"]},"application/vnd.anki":{source:"iana"},"application/vnd.anser-web-certificate-issue-initiation":{source:"iana",extensions:["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{source:"apache",extensions:["fti"]},"application/vnd.antix.game-component":{source:"iana",extensions:["atx"]},"application/vnd.apache.arrow.file":{source:"iana"},"application/vnd.apache.arrow.stream":{source:"iana"},"application/vnd.apache.thrift.binary":{source:"iana"},"application/vnd.apache.thrift.compact":{source:"iana"},"application/vnd.apache.thrift.json":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/vnd.aplextor.warrp+json":{source:"iana",compressible:!0},"application/vnd.apothekende.reservation+json":{source:"iana",compressible:!0},"application/vnd.apple.installer+xml":{source:"iana",compressible:!0,extensions:["mpkg"]},"application/vnd.apple.keynote":{source:"iana",extensions:["key"]},"application/vnd.apple.mpegurl":{source:"iana",extensions:["m3u8"]},"application/vnd.apple.numbers":{source:"iana",extensions:["numbers"]},"application/vnd.apple.pages":{source:"iana",extensions:["pages"]},"application/vnd.apple.pkpass":{compressible:!1,extensions:["pkpass"]},"application/vnd.arastra.swi":{source:"iana"},"application/vnd.aristanetworks.swi":{source:"iana",extensions:["swi"]},"application/vnd.artisan+json":{source:"iana",compressible:!0},"application/vnd.artsquare":{source:"iana"},"application/vnd.astraea-software.iota":{source:"iana",extensions:["iota"]},"application/vnd.audiograph":{source:"iana",extensions:["aep"]},"application/vnd.autopackage":{source:"iana"},"application/vnd.avalon+json":{source:"iana",compressible:!0},"application/vnd.avistar+xml":{source:"iana",compressible:!0},"application/vnd.balsamiq.bmml+xml":{source:"iana",compressible:!0,extensions:["bmml"]},"application/vnd.balsamiq.bmpr":{source:"iana"},"application/vnd.banana-accounting":{source:"iana"},"application/vnd.bbf.usp.error":{source:"iana"},"application/vnd.bbf.usp.msg":{source:"iana"},"application/vnd.bbf.usp.msg+json":{source:"iana",compressible:!0},"application/vnd.bekitzur-stech+json":{source:"iana",compressible:!0},"application/vnd.bint.med-content":{source:"iana"},"application/vnd.biopax.rdf+xml":{source:"iana",compressible:!0},"application/vnd.blink-idb-value-wrapper":{source:"iana"},"application/vnd.blueice.multipass":{source:"iana",extensions:["mpm"]},"application/vnd.bluetooth.ep.oob":{source:"iana"},"application/vnd.bluetooth.le.oob":{source:"iana"},"application/vnd.bmi":{source:"iana",extensions:["bmi"]},"application/vnd.bpf":{source:"iana"},"application/vnd.bpf3":{source:"iana"},"application/vnd.businessobjects":{source:"iana",extensions:["rep"]},"application/vnd.byu.uapi+json":{source:"iana",compressible:!0},"application/vnd.cab-jscript":{source:"iana"},"application/vnd.canon-cpdl":{source:"iana"},"application/vnd.canon-lips":{source:"iana"},"application/vnd.capasystems-pg+json":{source:"iana",compressible:!0},"application/vnd.cendio.thinlinc.clientconf":{source:"iana"},"application/vnd.century-systems.tcp_stream":{source:"iana"},"application/vnd.chemdraw+xml":{source:"iana",compressible:!0,extensions:["cdxml"]},"application/vnd.chess-pgn":{source:"iana"},"application/vnd.chipnuts.karaoke-mmd":{source:"iana",extensions:["mmd"]},"application/vnd.ciedi":{source:"iana"},"application/vnd.cinderella":{source:"iana",extensions:["cdy"]},"application/vnd.cirpack.isdn-ext":{source:"iana"},"application/vnd.citationstyles.style+xml":{source:"iana",compressible:!0,extensions:["csl"]},"application/vnd.claymore":{source:"iana",extensions:["cla"]},"application/vnd.cloanto.rp9":{source:"iana",extensions:["rp9"]},"application/vnd.clonk.c4group":{source:"iana",extensions:["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{source:"iana",extensions:["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{source:"iana",extensions:["c11amz"]},"application/vnd.coffeescript":{source:"iana"},"application/vnd.collabio.xodocuments.document":{source:"iana"},"application/vnd.collabio.xodocuments.document-template":{source:"iana"},"application/vnd.collabio.xodocuments.presentation":{source:"iana"},"application/vnd.collabio.xodocuments.presentation-template":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{source:"iana"},"application/vnd.collection+json":{source:"iana",compressible:!0},"application/vnd.collection.doc+json":{source:"iana",compressible:!0},"application/vnd.collection.next+json":{source:"iana",compressible:!0},"application/vnd.comicbook+zip":{source:"iana",compressible:!1},"application/vnd.comicbook-rar":{source:"iana"},"application/vnd.commerce-battelle":{source:"iana"},"application/vnd.commonspace":{source:"iana",extensions:["csp"]},"application/vnd.contact.cmsg":{source:"iana",extensions:["cdbcmsg"]},"application/vnd.coreos.ignition+json":{source:"iana",compressible:!0},"application/vnd.cosmocaller":{source:"iana",extensions:["cmc"]},"application/vnd.crick.clicker":{source:"iana",extensions:["clkx"]},"application/vnd.crick.clicker.keyboard":{source:"iana",extensions:["clkk"]},"application/vnd.crick.clicker.palette":{source:"iana",extensions:["clkp"]},"application/vnd.crick.clicker.template":{source:"iana",extensions:["clkt"]},"application/vnd.crick.clicker.wordbank":{source:"iana",extensions:["clkw"]},"application/vnd.criticaltools.wbs+xml":{source:"iana",compressible:!0,extensions:["wbs"]},"application/vnd.cryptii.pipe+json":{source:"iana",compressible:!0},"application/vnd.crypto-shade-file":{source:"iana"},"application/vnd.cryptomator.encrypted":{source:"iana"},"application/vnd.cryptomator.vault":{source:"iana"},"application/vnd.ctc-posml":{source:"iana",extensions:["pml"]},"application/vnd.ctct.ws+xml":{source:"iana",compressible:!0},"application/vnd.cups-pdf":{source:"iana"},"application/vnd.cups-postscript":{source:"iana"},"application/vnd.cups-ppd":{source:"iana",extensions:["ppd"]},"application/vnd.cups-raster":{source:"iana"},"application/vnd.cups-raw":{source:"iana"},"application/vnd.curl":{source:"iana"},"application/vnd.curl.car":{source:"apache",extensions:["car"]},"application/vnd.curl.pcurl":{source:"apache",extensions:["pcurl"]},"application/vnd.cyan.dean.root+xml":{source:"iana",compressible:!0},"application/vnd.cybank":{source:"iana"},"application/vnd.cyclonedx+json":{source:"iana",compressible:!0},"application/vnd.cyclonedx+xml":{source:"iana",compressible:!0},"application/vnd.d2l.coursepackage1p0+zip":{source:"iana",compressible:!1},"application/vnd.d3m-dataset":{source:"iana"},"application/vnd.d3m-problem":{source:"iana"},"application/vnd.dart":{source:"iana",compressible:!0,extensions:["dart"]},"application/vnd.data-vision.rdz":{source:"iana",extensions:["rdz"]},"application/vnd.datapackage+json":{source:"iana",compressible:!0},"application/vnd.dataresource+json":{source:"iana",compressible:!0},"application/vnd.dbf":{source:"iana",extensions:["dbf"]},"application/vnd.debian.binary-package":{source:"iana"},"application/vnd.dece.data":{source:"iana",extensions:["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{source:"iana",compressible:!0,extensions:["uvt","uvvt"]},"application/vnd.dece.unspecified":{source:"iana",extensions:["uvx","uvvx"]},"application/vnd.dece.zip":{source:"iana",extensions:["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{source:"iana",extensions:["fe_launch"]},"application/vnd.desmume.movie":{source:"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{source:"iana"},"application/vnd.dm.delegation+xml":{source:"iana",compressible:!0},"application/vnd.dna":{source:"iana",extensions:["dna"]},"application/vnd.document+json":{source:"iana",compressible:!0},"application/vnd.dolby.mlp":{source:"apache",extensions:["mlp"]},"application/vnd.dolby.mobile.1":{source:"iana"},"application/vnd.dolby.mobile.2":{source:"iana"},"application/vnd.doremir.scorecloud-binary-document":{source:"iana"},"application/vnd.dpgraph":{source:"iana",extensions:["dpg"]},"application/vnd.dreamfactory":{source:"iana",extensions:["dfac"]},"application/vnd.drive+json":{source:"iana",compressible:!0},"application/vnd.ds-keypoint":{source:"apache",extensions:["kpxx"]},"application/vnd.dtg.local":{source:"iana"},"application/vnd.dtg.local.flash":{source:"iana"},"application/vnd.dtg.local.html":{source:"iana"},"application/vnd.dvb.ait":{source:"iana",extensions:["ait"]},"application/vnd.dvb.dvbisl+xml":{source:"iana",compressible:!0},"application/vnd.dvb.dvbj":{source:"iana"},"application/vnd.dvb.esgcontainer":{source:"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess2":{source:"iana"},"application/vnd.dvb.ipdcesgpdd":{source:"iana"},"application/vnd.dvb.ipdcroaming":{source:"iana"},"application/vnd.dvb.iptv.alfec-base":{source:"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{source:"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-container+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-generic+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-msglist+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-request+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-response+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-init+xml":{source:"iana",compressible:!0},"application/vnd.dvb.pfr":{source:"iana"},"application/vnd.dvb.service":{source:"iana",extensions:["svc"]},"application/vnd.dxr":{source:"iana"},"application/vnd.dynageo":{source:"iana",extensions:["geo"]},"application/vnd.dzr":{source:"iana"},"application/vnd.easykaraoke.cdgdownload":{source:"iana"},"application/vnd.ecdis-update":{source:"iana"},"application/vnd.ecip.rlp":{source:"iana"},"application/vnd.eclipse.ditto+json":{source:"iana",compressible:!0},"application/vnd.ecowin.chart":{source:"iana",extensions:["mag"]},"application/vnd.ecowin.filerequest":{source:"iana"},"application/vnd.ecowin.fileupdate":{source:"iana"},"application/vnd.ecowin.series":{source:"iana"},"application/vnd.ecowin.seriesrequest":{source:"iana"},"application/vnd.ecowin.seriesupdate":{source:"iana"},"application/vnd.efi.img":{source:"iana"},"application/vnd.efi.iso":{source:"iana"},"application/vnd.emclient.accessrequest+xml":{source:"iana",compressible:!0},"application/vnd.enliven":{source:"iana",extensions:["nml"]},"application/vnd.enphase.envoy":{source:"iana"},"application/vnd.eprints.data+xml":{source:"iana",compressible:!0},"application/vnd.epson.esf":{source:"iana",extensions:["esf"]},"application/vnd.epson.msf":{source:"iana",extensions:["msf"]},"application/vnd.epson.quickanime":{source:"iana",extensions:["qam"]},"application/vnd.epson.salt":{source:"iana",extensions:["slt"]},"application/vnd.epson.ssf":{source:"iana",extensions:["ssf"]},"application/vnd.ericsson.quickcall":{source:"iana"},"application/vnd.espass-espass+zip":{source:"iana",compressible:!1},"application/vnd.eszigno3+xml":{source:"iana",compressible:!0,extensions:["es3","et3"]},"application/vnd.etsi.aoc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.asic-e+zip":{source:"iana",compressible:!1},"application/vnd.etsi.asic-s+zip":{source:"iana",compressible:!1},"application/vnd.etsi.cug+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvcommand+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-bc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-cod+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-npvr+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvservice+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsync+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvueprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mcid+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mheg5":{source:"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{source:"iana",compressible:!0},"application/vnd.etsi.pstn+xml":{source:"iana",compressible:!0},"application/vnd.etsi.sci+xml":{source:"iana",compressible:!0},"application/vnd.etsi.simservs+xml":{source:"iana",compressible:!0},"application/vnd.etsi.timestamp-token":{source:"iana"},"application/vnd.etsi.tsl+xml":{source:"iana",compressible:!0},"application/vnd.etsi.tsl.der":{source:"iana"},"application/vnd.eu.kasparian.car+json":{source:"iana",compressible:!0},"application/vnd.eudora.data":{source:"iana"},"application/vnd.evolv.ecig.profile":{source:"iana"},"application/vnd.evolv.ecig.settings":{source:"iana"},"application/vnd.evolv.ecig.theme":{source:"iana"},"application/vnd.exstream-empower+zip":{source:"iana",compressible:!1},"application/vnd.exstream-package":{source:"iana"},"application/vnd.ezpix-album":{source:"iana",extensions:["ez2"]},"application/vnd.ezpix-package":{source:"iana",extensions:["ez3"]},"application/vnd.f-secure.mobile":{source:"iana"},"application/vnd.familysearch.gedcom+zip":{source:"iana",compressible:!1},"application/vnd.fastcopy-disk-image":{source:"iana"},"application/vnd.fdf":{source:"iana",extensions:["fdf"]},"application/vnd.fdsn.mseed":{source:"iana",extensions:["mseed"]},"application/vnd.fdsn.seed":{source:"iana",extensions:["seed","dataless"]},"application/vnd.ffsns":{source:"iana"},"application/vnd.ficlab.flb+zip":{source:"iana",compressible:!1},"application/vnd.filmit.zfc":{source:"iana"},"application/vnd.fints":{source:"iana"},"application/vnd.firemonkeys.cloudcell":{source:"iana"},"application/vnd.flographit":{source:"iana",extensions:["gph"]},"application/vnd.fluxtime.clip":{source:"iana",extensions:["ftc"]},"application/vnd.font-fontforge-sfd":{source:"iana"},"application/vnd.framemaker":{source:"iana",extensions:["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{source:"iana",extensions:["fnc"]},"application/vnd.frogans.ltf":{source:"iana",extensions:["ltf"]},"application/vnd.fsc.weblaunch":{source:"iana",extensions:["fsc"]},"application/vnd.fujifilm.fb.docuworks":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.binder":{source:"iana"},"application/vnd.fujifilm.fb.docuworks.container":{source:"iana"},"application/vnd.fujifilm.fb.jfi+xml":{source:"iana",compressible:!0},"application/vnd.fujitsu.oasys":{source:"iana",extensions:["oas"]},"application/vnd.fujitsu.oasys2":{source:"iana",extensions:["oa2"]},"application/vnd.fujitsu.oasys3":{source:"iana",extensions:["oa3"]},"application/vnd.fujitsu.oasysgp":{source:"iana",extensions:["fg5"]},"application/vnd.fujitsu.oasysprs":{source:"iana",extensions:["bh2"]},"application/vnd.fujixerox.art-ex":{source:"iana"},"application/vnd.fujixerox.art4":{source:"iana"},"application/vnd.fujixerox.ddd":{source:"iana",extensions:["ddd"]},"application/vnd.fujixerox.docuworks":{source:"iana",extensions:["xdw"]},"application/vnd.fujixerox.docuworks.binder":{source:"iana",extensions:["xbd"]},"application/vnd.fujixerox.docuworks.container":{source:"iana"},"application/vnd.fujixerox.hbpl":{source:"iana"},"application/vnd.fut-misnet":{source:"iana"},"application/vnd.futoin+cbor":{source:"iana"},"application/vnd.futoin+json":{source:"iana",compressible:!0},"application/vnd.fuzzysheet":{source:"iana",extensions:["fzs"]},"application/vnd.genomatix.tuxedo":{source:"iana",extensions:["txd"]},"application/vnd.gentics.grd+json":{source:"iana",compressible:!0},"application/vnd.geo+json":{source:"iana",compressible:!0},"application/vnd.geocube+xml":{source:"iana",compressible:!0},"application/vnd.geogebra.file":{source:"iana",extensions:["ggb"]},"application/vnd.geogebra.slides":{source:"iana"},"application/vnd.geogebra.tool":{source:"iana",extensions:["ggt"]},"application/vnd.geometry-explorer":{source:"iana",extensions:["gex","gre"]},"application/vnd.geonext":{source:"iana",extensions:["gxt"]},"application/vnd.geoplan":{source:"iana",extensions:["g2w"]},"application/vnd.geospace":{source:"iana",extensions:["g3w"]},"application/vnd.gerber":{source:"iana"},"application/vnd.globalplatform.card-content-mgt":{source:"iana"},"application/vnd.globalplatform.card-content-mgt-response":{source:"iana"},"application/vnd.gmx":{source:"iana",extensions:["gmx"]},"application/vnd.google-apps.document":{compressible:!1,extensions:["gdoc"]},"application/vnd.google-apps.presentation":{compressible:!1,extensions:["gslides"]},"application/vnd.google-apps.spreadsheet":{compressible:!1,extensions:["gsheet"]},"application/vnd.google-earth.kml+xml":{source:"iana",compressible:!0,extensions:["kml"]},"application/vnd.google-earth.kmz":{source:"iana",compressible:!1,extensions:["kmz"]},"application/vnd.gov.sk.e-form+xml":{source:"iana",compressible:!0},"application/vnd.gov.sk.e-form+zip":{source:"iana",compressible:!1},"application/vnd.gov.sk.xmldatacontainer+xml":{source:"iana",compressible:!0},"application/vnd.grafeq":{source:"iana",extensions:["gqf","gqs"]},"application/vnd.gridmp":{source:"iana"},"application/vnd.groove-account":{source:"iana",extensions:["gac"]},"application/vnd.groove-help":{source:"iana",extensions:["ghf"]},"application/vnd.groove-identity-message":{source:"iana",extensions:["gim"]},"application/vnd.groove-injector":{source:"iana",extensions:["grv"]},"application/vnd.groove-tool-message":{source:"iana",extensions:["gtm"]},"application/vnd.groove-tool-template":{source:"iana",extensions:["tpl"]},"application/vnd.groove-vcard":{source:"iana",extensions:["vcg"]},"application/vnd.hal+json":{source:"iana",compressible:!0},"application/vnd.hal+xml":{source:"iana",compressible:!0,extensions:["hal"]},"application/vnd.handheld-entertainment+xml":{source:"iana",compressible:!0,extensions:["zmm"]},"application/vnd.hbci":{source:"iana",extensions:["hbci"]},"application/vnd.hc+json":{source:"iana",compressible:!0},"application/vnd.hcl-bireports":{source:"iana"},"application/vnd.hdt":{source:"iana"},"application/vnd.heroku+json":{source:"iana",compressible:!0},"application/vnd.hhe.lesson-player":{source:"iana",extensions:["les"]},"application/vnd.hl7cda+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hl7v2+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.hp-hpgl":{source:"iana",extensions:["hpgl"]},"application/vnd.hp-hpid":{source:"iana",extensions:["hpid"]},"application/vnd.hp-hps":{source:"iana",extensions:["hps"]},"application/vnd.hp-jlyt":{source:"iana",extensions:["jlt"]},"application/vnd.hp-pcl":{source:"iana",extensions:["pcl"]},"application/vnd.hp-pclxl":{source:"iana",extensions:["pclxl"]},"application/vnd.httphone":{source:"iana"},"application/vnd.hydrostatix.sof-data":{source:"iana",extensions:["sfd-hdstx"]},"application/vnd.hyper+json":{source:"iana",compressible:!0},"application/vnd.hyper-item+json":{source:"iana",compressible:!0},"application/vnd.hyperdrive+json":{source:"iana",compressible:!0},"application/vnd.hzn-3d-crossword":{source:"iana"},"application/vnd.ibm.afplinedata":{source:"iana"},"application/vnd.ibm.electronic-media":{source:"iana"},"application/vnd.ibm.minipay":{source:"iana",extensions:["mpy"]},"application/vnd.ibm.modcap":{source:"iana",extensions:["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{source:"iana",extensions:["irm"]},"application/vnd.ibm.secure-container":{source:"iana",extensions:["sc"]},"application/vnd.iccprofile":{source:"iana",extensions:["icc","icm"]},"application/vnd.ieee.1905":{source:"iana"},"application/vnd.igloader":{source:"iana",extensions:["igl"]},"application/vnd.imagemeter.folder+zip":{source:"iana",compressible:!1},"application/vnd.imagemeter.image+zip":{source:"iana",compressible:!1},"application/vnd.immervision-ivp":{source:"iana",extensions:["ivp"]},"application/vnd.immervision-ivu":{source:"iana",extensions:["ivu"]},"application/vnd.ims.imsccv1p1":{source:"iana"},"application/vnd.ims.imsccv1p2":{source:"iana"},"application/vnd.ims.imsccv1p3":{source:"iana"},"application/vnd.ims.lis.v2.result+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy.id+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings.simple+json":{source:"iana",compressible:!0},"application/vnd.informedcontrol.rms+xml":{source:"iana",compressible:!0},"application/vnd.informix-visionary":{source:"iana"},"application/vnd.infotech.project":{source:"iana"},"application/vnd.infotech.project+xml":{source:"iana",compressible:!0},"application/vnd.innopath.wamp.notification":{source:"iana"},"application/vnd.insors.igm":{source:"iana",extensions:["igm"]},"application/vnd.intercon.formnet":{source:"iana",extensions:["xpw","xpx"]},"application/vnd.intergeo":{source:"iana",extensions:["i2g"]},"application/vnd.intertrust.digibox":{source:"iana"},"application/vnd.intertrust.nncp":{source:"iana"},"application/vnd.intu.qbo":{source:"iana",extensions:["qbo"]},"application/vnd.intu.qfx":{source:"iana",extensions:["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.conceptitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.knowledgeitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsmessage+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.packageitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.planningitem+xml":{source:"iana",compressible:!0},"application/vnd.ipunplugged.rcprofile":{source:"iana",extensions:["rcprofile"]},"application/vnd.irepository.package+xml":{source:"iana",compressible:!0,extensions:["irp"]},"application/vnd.is-xpr":{source:"iana",extensions:["xpr"]},"application/vnd.isac.fcs":{source:"iana",extensions:["fcs"]},"application/vnd.iso11783-10+zip":{source:"iana",compressible:!1},"application/vnd.jam":{source:"iana",extensions:["jam"]},"application/vnd.japannet-directory-service":{source:"iana"},"application/vnd.japannet-jpnstore-wakeup":{source:"iana"},"application/vnd.japannet-payment-wakeup":{source:"iana"},"application/vnd.japannet-registration":{source:"iana"},"application/vnd.japannet-registration-wakeup":{source:"iana"},"application/vnd.japannet-setstore-wakeup":{source:"iana"},"application/vnd.japannet-verification":{source:"iana"},"application/vnd.japannet-verification-wakeup":{source:"iana"},"application/vnd.jcp.javame.midlet-rms":{source:"iana",extensions:["rms"]},"application/vnd.jisp":{source:"iana",extensions:["jisp"]},"application/vnd.joost.joda-archive":{source:"iana",extensions:["joda"]},"application/vnd.jsk.isdn-ngn":{source:"iana"},"application/vnd.kahootz":{source:"iana",extensions:["ktz","ktr"]},"application/vnd.kde.karbon":{source:"iana",extensions:["karbon"]},"application/vnd.kde.kchart":{source:"iana",extensions:["chrt"]},"application/vnd.kde.kformula":{source:"iana",extensions:["kfo"]},"application/vnd.kde.kivio":{source:"iana",extensions:["flw"]},"application/vnd.kde.kontour":{source:"iana",extensions:["kon"]},"application/vnd.kde.kpresenter":{source:"iana",extensions:["kpr","kpt"]},"application/vnd.kde.kspread":{source:"iana",extensions:["ksp"]},"application/vnd.kde.kword":{source:"iana",extensions:["kwd","kwt"]},"application/vnd.kenameaapp":{source:"iana",extensions:["htke"]},"application/vnd.kidspiration":{source:"iana",extensions:["kia"]},"application/vnd.kinar":{source:"iana",extensions:["kne","knp"]},"application/vnd.koan":{source:"iana",extensions:["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{source:"iana",extensions:["sse"]},"application/vnd.las":{source:"iana"},"application/vnd.las.las+json":{source:"iana",compressible:!0},"application/vnd.las.las+xml":{source:"iana",compressible:!0,extensions:["lasxml"]},"application/vnd.laszip":{source:"iana"},"application/vnd.leap+json":{source:"iana",compressible:!0},"application/vnd.liberty-request+xml":{source:"iana",compressible:!0},"application/vnd.llamagraphics.life-balance.desktop":{source:"iana",extensions:["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{source:"iana",compressible:!0,extensions:["lbe"]},"application/vnd.logipipe.circuit+zip":{source:"iana",compressible:!1},"application/vnd.loom":{source:"iana"},"application/vnd.lotus-1-2-3":{source:"iana",extensions:["123"]},"application/vnd.lotus-approach":{source:"iana",extensions:["apr"]},"application/vnd.lotus-freelance":{source:"iana",extensions:["pre"]},"application/vnd.lotus-notes":{source:"iana",extensions:["nsf"]},"application/vnd.lotus-organizer":{source:"iana",extensions:["org"]},"application/vnd.lotus-screencam":{source:"iana",extensions:["scm"]},"application/vnd.lotus-wordpro":{source:"iana",extensions:["lwp"]},"application/vnd.macports.portpkg":{source:"iana",extensions:["portpkg"]},"application/vnd.mapbox-vector-tile":{source:"iana",extensions:["mvt"]},"application/vnd.marlin.drm.actiontoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.conftoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.license+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.mdcf":{source:"iana"},"application/vnd.mason+json":{source:"iana",compressible:!0},"application/vnd.maxar.archive.3tz+zip":{source:"iana",compressible:!1},"application/vnd.maxmind.maxmind-db":{source:"iana"},"application/vnd.mcd":{source:"iana",extensions:["mcd"]},"application/vnd.medcalcdata":{source:"iana",extensions:["mc1"]},"application/vnd.mediastation.cdkey":{source:"iana",extensions:["cdkey"]},"application/vnd.meridian-slingshot":{source:"iana"},"application/vnd.mfer":{source:"iana",extensions:["mwf"]},"application/vnd.mfmp":{source:"iana",extensions:["mfm"]},"application/vnd.micro+json":{source:"iana",compressible:!0},"application/vnd.micrografx.flo":{source:"iana",extensions:["flo"]},"application/vnd.micrografx.igx":{source:"iana",extensions:["igx"]},"application/vnd.microsoft.portable-executable":{source:"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{source:"iana"},"application/vnd.miele+json":{source:"iana",compressible:!0},"application/vnd.mif":{source:"iana",extensions:["mif"]},"application/vnd.minisoft-hp3000-save":{source:"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{source:"iana"},"application/vnd.mobius.daf":{source:"iana",extensions:["daf"]},"application/vnd.mobius.dis":{source:"iana",extensions:["dis"]},"application/vnd.mobius.mbk":{source:"iana",extensions:["mbk"]},"application/vnd.mobius.mqy":{source:"iana",extensions:["mqy"]},"application/vnd.mobius.msl":{source:"iana",extensions:["msl"]},"application/vnd.mobius.plc":{source:"iana",extensions:["plc"]},"application/vnd.mobius.txf":{source:"iana",extensions:["txf"]},"application/vnd.mophun.application":{source:"iana",extensions:["mpn"]},"application/vnd.mophun.certificate":{source:"iana",extensions:["mpc"]},"application/vnd.motorola.flexsuite":{source:"iana"},"application/vnd.motorola.flexsuite.adsi":{source:"iana"},"application/vnd.motorola.flexsuite.fis":{source:"iana"},"application/vnd.motorola.flexsuite.gotap":{source:"iana"},"application/vnd.motorola.flexsuite.kmr":{source:"iana"},"application/vnd.motorola.flexsuite.ttc":{source:"iana"},"application/vnd.motorola.flexsuite.wem":{source:"iana"},"application/vnd.motorola.iprm":{source:"iana"},"application/vnd.mozilla.xul+xml":{source:"iana",compressible:!0,extensions:["xul"]},"application/vnd.ms-3mfdocument":{source:"iana"},"application/vnd.ms-artgalry":{source:"iana",extensions:["cil"]},"application/vnd.ms-asf":{source:"iana"},"application/vnd.ms-cab-compressed":{source:"iana",extensions:["cab"]},"application/vnd.ms-color.iccprofile":{source:"apache"},"application/vnd.ms-excel":{source:"iana",compressible:!1,extensions:["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{source:"iana",extensions:["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{source:"iana",extensions:["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{source:"iana",extensions:["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{source:"iana",extensions:["xltm"]},"application/vnd.ms-fontobject":{source:"iana",compressible:!0,extensions:["eot"]},"application/vnd.ms-htmlhelp":{source:"iana",extensions:["chm"]},"application/vnd.ms-ims":{source:"iana",extensions:["ims"]},"application/vnd.ms-lrm":{source:"iana",extensions:["lrm"]},"application/vnd.ms-office.activex+xml":{source:"iana",compressible:!0},"application/vnd.ms-officetheme":{source:"iana",extensions:["thmx"]},"application/vnd.ms-opentype":{source:"apache",compressible:!0},"application/vnd.ms-outlook":{compressible:!1,extensions:["msg"]},"application/vnd.ms-package.obfuscated-opentype":{source:"apache"},"application/vnd.ms-pki.seccat":{source:"apache",extensions:["cat"]},"application/vnd.ms-pki.stl":{source:"apache",extensions:["stl"]},"application/vnd.ms-playready.initiator+xml":{source:"iana",compressible:!0},"application/vnd.ms-powerpoint":{source:"iana",compressible:!1,extensions:["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{source:"iana",extensions:["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{source:"iana",extensions:["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{source:"iana",extensions:["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{source:"iana",extensions:["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{source:"iana",extensions:["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{source:"iana",compressible:!0},"application/vnd.ms-printing.printticket+xml":{source:"apache",compressible:!0},"application/vnd.ms-printschematicket+xml":{source:"iana",compressible:!0},"application/vnd.ms-project":{source:"iana",extensions:["mpp","mpt"]},"application/vnd.ms-tnef":{source:"iana"},"application/vnd.ms-windows.devicepairing":{source:"iana"},"application/vnd.ms-windows.nwprinting.oob":{source:"iana"},"application/vnd.ms-windows.printerpairing":{source:"iana"},"application/vnd.ms-windows.wsd.oob":{source:"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.lic-resp":{source:"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.meter-resp":{source:"iana"},"application/vnd.ms-word.document.macroenabled.12":{source:"iana",extensions:["docm"]},"application/vnd.ms-word.template.macroenabled.12":{source:"iana",extensions:["dotm"]},"application/vnd.ms-works":{source:"iana",extensions:["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{source:"iana",extensions:["wpl"]},"application/vnd.ms-xpsdocument":{source:"iana",compressible:!1,extensions:["xps"]},"application/vnd.msa-disk-image":{source:"iana"},"application/vnd.mseq":{source:"iana",extensions:["mseq"]},"application/vnd.msign":{source:"iana"},"application/vnd.multiad.creator":{source:"iana"},"application/vnd.multiad.creator.cif":{source:"iana"},"application/vnd.music-niff":{source:"iana"},"application/vnd.musician":{source:"iana",extensions:["mus"]},"application/vnd.muvee.style":{source:"iana",extensions:["msty"]},"application/vnd.mynfc":{source:"iana",extensions:["taglet"]},"application/vnd.nacamar.ybrid+json":{source:"iana",compressible:!0},"application/vnd.ncd.control":{source:"iana"},"application/vnd.ncd.reference":{source:"iana"},"application/vnd.nearst.inv+json":{source:"iana",compressible:!0},"application/vnd.nebumind.line":{source:"iana"},"application/vnd.nervana":{source:"iana"},"application/vnd.netfpx":{source:"iana"},"application/vnd.neurolanguage.nlu":{source:"iana",extensions:["nlu"]},"application/vnd.nimn":{source:"iana"},"application/vnd.nintendo.nitro.rom":{source:"iana"},"application/vnd.nintendo.snes.rom":{source:"iana"},"application/vnd.nitf":{source:"iana",extensions:["ntf","nitf"]},"application/vnd.noblenet-directory":{source:"iana",extensions:["nnd"]},"application/vnd.noblenet-sealer":{source:"iana",extensions:["nns"]},"application/vnd.noblenet-web":{source:"iana",extensions:["nnw"]},"application/vnd.nokia.catalogs":{source:"iana"},"application/vnd.nokia.conml+wbxml":{source:"iana"},"application/vnd.nokia.conml+xml":{source:"iana",compressible:!0},"application/vnd.nokia.iptv.config+xml":{source:"iana",compressible:!0},"application/vnd.nokia.isds-radio-presets":{source:"iana"},"application/vnd.nokia.landmark+wbxml":{source:"iana"},"application/vnd.nokia.landmark+xml":{source:"iana",compressible:!0},"application/vnd.nokia.landmarkcollection+xml":{source:"iana",compressible:!0},"application/vnd.nokia.n-gage.ac+xml":{source:"iana",compressible:!0,extensions:["ac"]},"application/vnd.nokia.n-gage.data":{source:"iana",extensions:["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{source:"iana",extensions:["n-gage"]},"application/vnd.nokia.ncd":{source:"iana"},"application/vnd.nokia.pcd+wbxml":{source:"iana"},"application/vnd.nokia.pcd+xml":{source:"iana",compressible:!0},"application/vnd.nokia.radio-preset":{source:"iana",extensions:["rpst"]},"application/vnd.nokia.radio-presets":{source:"iana",extensions:["rpss"]},"application/vnd.novadigm.edm":{source:"iana",extensions:["edm"]},"application/vnd.novadigm.edx":{source:"iana",extensions:["edx"]},"application/vnd.novadigm.ext":{source:"iana",extensions:["ext"]},"application/vnd.ntt-local.content-share":{source:"iana"},"application/vnd.ntt-local.file-transfer":{source:"iana"},"application/vnd.ntt-local.ogw_remote-access":{source:"iana"},"application/vnd.ntt-local.sip-ta_remote":{source:"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{source:"iana"},"application/vnd.oasis.opendocument.chart":{source:"iana",extensions:["odc"]},"application/vnd.oasis.opendocument.chart-template":{source:"iana",extensions:["otc"]},"application/vnd.oasis.opendocument.database":{source:"iana",extensions:["odb"]},"application/vnd.oasis.opendocument.formula":{source:"iana",extensions:["odf"]},"application/vnd.oasis.opendocument.formula-template":{source:"iana",extensions:["odft"]},"application/vnd.oasis.opendocument.graphics":{source:"iana",compressible:!1,extensions:["odg"]},"application/vnd.oasis.opendocument.graphics-template":{source:"iana",extensions:["otg"]},"application/vnd.oasis.opendocument.image":{source:"iana",extensions:["odi"]},"application/vnd.oasis.opendocument.image-template":{source:"iana",extensions:["oti"]},"application/vnd.oasis.opendocument.presentation":{source:"iana",compressible:!1,extensions:["odp"]},"application/vnd.oasis.opendocument.presentation-template":{source:"iana",extensions:["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{source:"iana",compressible:!1,extensions:["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{source:"iana",extensions:["ots"]},"application/vnd.oasis.opendocument.text":{source:"iana",compressible:!1,extensions:["odt"]},"application/vnd.oasis.opendocument.text-master":{source:"iana",extensions:["odm"]},"application/vnd.oasis.opendocument.text-template":{source:"iana",extensions:["ott"]},"application/vnd.oasis.opendocument.text-web":{source:"iana",extensions:["oth"]},"application/vnd.obn":{source:"iana"},"application/vnd.ocf+cbor":{source:"iana"},"application/vnd.oci.image.manifest.v1+json":{source:"iana",compressible:!0},"application/vnd.oftn.l10n+json":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessdownload+xml":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessstreaming+xml":{source:"iana",compressible:!0},"application/vnd.oipf.cspg-hexbinary":{source:"iana"},"application/vnd.oipf.dae.svg+xml":{source:"iana",compressible:!0},"application/vnd.oipf.dae.xhtml+xml":{source:"iana",compressible:!0},"application/vnd.oipf.mippvcontrolmessage+xml":{source:"iana",compressible:!0},"application/vnd.oipf.pae.gem":{source:"iana"},"application/vnd.oipf.spdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.oipf.spdlist+xml":{source:"iana",compressible:!0},"application/vnd.oipf.ueprofile+xml":{source:"iana",compressible:!0},"application/vnd.oipf.userprofile+xml":{source:"iana",compressible:!0},"application/vnd.olpc-sugar":{source:"iana",extensions:["xo"]},"application/vnd.oma-scws-config":{source:"iana"},"application/vnd.oma-scws-http-request":{source:"iana"},"application/vnd.oma-scws-http-response":{source:"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.drm-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.imd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.ltkm":{source:"iana"},"application/vnd.oma.bcast.notification+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.provisioningtrigger":{source:"iana"},"application/vnd.oma.bcast.sgboot":{source:"iana"},"application/vnd.oma.bcast.sgdd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sgdu":{source:"iana"},"application/vnd.oma.bcast.simple-symbol-container":{source:"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sprov+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.stkm":{source:"iana"},"application/vnd.oma.cab-address-book+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-feature-handler+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-pcc+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-subs-invite+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-user-prefs+xml":{source:"iana",compressible:!0},"application/vnd.oma.dcd":{source:"iana"},"application/vnd.oma.dcdc":{source:"iana"},"application/vnd.oma.dd2+xml":{source:"iana",compressible:!0,extensions:["dd2"]},"application/vnd.oma.drm.risd+xml":{source:"iana",compressible:!0},"application/vnd.oma.group-usage-list+xml":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+cbor":{source:"iana"},"application/vnd.oma.lwm2m+json":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+tlv":{source:"iana"},"application/vnd.oma.pal+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.detailed-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.final-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.groups+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.invocation-descriptor+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.optimized-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.push":{source:"iana"},"application/vnd.oma.scidm.messages+xml":{source:"iana",compressible:!0},"application/vnd.oma.xcap-directory+xml":{source:"iana",compressible:!0},"application/vnd.omads-email+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-file+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omads-folder+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.omaloc-supl-init":{source:"iana"},"application/vnd.onepager":{source:"iana"},"application/vnd.onepagertamp":{source:"iana"},"application/vnd.onepagertamx":{source:"iana"},"application/vnd.onepagertat":{source:"iana"},"application/vnd.onepagertatp":{source:"iana"},"application/vnd.onepagertatx":{source:"iana"},"application/vnd.openblox.game+xml":{source:"iana",compressible:!0,extensions:["obgx"]},"application/vnd.openblox.game-binary":{source:"iana"},"application/vnd.openeye.oeb":{source:"iana"},"application/vnd.openofficeorg.extension":{source:"apache",extensions:["oxt"]},"application/vnd.openstreetmap.data+xml":{source:"iana",compressible:!0,extensions:["osm"]},"application/vnd.opentimestamps.ots":{source:"iana"},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawing+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",compressible:!1,extensions:["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slide":{source:"iana",extensions:["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{source:"iana",extensions:["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.template":{source:"iana",extensions:["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",compressible:!1,extensions:["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{source:"iana",extensions:["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.theme+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.vmldrawing":{source:"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",compressible:!1,extensions:["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{source:"iana",extensions:["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.core-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.relationships+xml":{source:"iana",compressible:!0},"application/vnd.oracle.resource+json":{source:"iana",compressible:!0},"application/vnd.orange.indata":{source:"iana"},"application/vnd.osa.netdeploy":{source:"iana"},"application/vnd.osgeo.mapguide.package":{source:"iana",extensions:["mgp"]},"application/vnd.osgi.bundle":{source:"iana"},"application/vnd.osgi.dp":{source:"iana",extensions:["dp"]},"application/vnd.osgi.subsystem":{source:"iana",extensions:["esa"]},"application/vnd.otps.ct-kip+xml":{source:"iana",compressible:!0},"application/vnd.oxli.countgraph":{source:"iana"},"application/vnd.pagerduty+json":{source:"iana",compressible:!0},"application/vnd.palm":{source:"iana",extensions:["pdb","pqa","oprc"]},"application/vnd.panoply":{source:"iana"},"application/vnd.paos.xml":{source:"iana"},"application/vnd.patentdive":{source:"iana"},"application/vnd.patientecommsdoc":{source:"iana"},"application/vnd.pawaafile":{source:"iana",extensions:["paw"]},"application/vnd.pcos":{source:"iana"},"application/vnd.pg.format":{source:"iana",extensions:["str"]},"application/vnd.pg.osasli":{source:"iana",extensions:["ei6"]},"application/vnd.piaccess.application-licence":{source:"iana"},"application/vnd.picsel":{source:"iana",extensions:["efif"]},"application/vnd.pmi.widget":{source:"iana",extensions:["wg"]},"application/vnd.poc.group-advertisement+xml":{source:"iana",compressible:!0},"application/vnd.pocketlearn":{source:"iana",extensions:["plf"]},"application/vnd.powerbuilder6":{source:"iana",extensions:["pbd"]},"application/vnd.powerbuilder6-s":{source:"iana"},"application/vnd.powerbuilder7":{source:"iana"},"application/vnd.powerbuilder7-s":{source:"iana"},"application/vnd.powerbuilder75":{source:"iana"},"application/vnd.powerbuilder75-s":{source:"iana"},"application/vnd.preminet":{source:"iana"},"application/vnd.previewsystems.box":{source:"iana",extensions:["box"]},"application/vnd.proteus.magazine":{source:"iana",extensions:["mgz"]},"application/vnd.psfs":{source:"iana"},"application/vnd.publishare-delta-tree":{source:"iana",extensions:["qps"]},"application/vnd.pvi.ptid1":{source:"iana",extensions:["ptid"]},"application/vnd.pwg-multiplexed":{source:"iana"},"application/vnd.pwg-xhtml-print+xml":{source:"iana",compressible:!0},"application/vnd.qualcomm.brew-app-res":{source:"iana"},"application/vnd.quarantainenet":{source:"iana"},"application/vnd.quark.quarkxpress":{source:"iana",extensions:["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{source:"iana"},"application/vnd.radisys.moml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conn+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-stream+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-base+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-detect+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-group+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-speech+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-transform+xml":{source:"iana",compressible:!0},"application/vnd.rainstor.data":{source:"iana"},"application/vnd.rapid":{source:"iana"},"application/vnd.rar":{source:"iana",extensions:["rar"]},"application/vnd.realvnc.bed":{source:"iana",extensions:["bed"]},"application/vnd.recordare.musicxml":{source:"iana",extensions:["mxl"]},"application/vnd.recordare.musicxml+xml":{source:"iana",compressible:!0,extensions:["musicxml"]},"application/vnd.renlearn.rlprint":{source:"iana"},"application/vnd.resilient.logic":{source:"iana"},"application/vnd.restful+json":{source:"iana",compressible:!0},"application/vnd.rig.cryptonote":{source:"iana",extensions:["cryptonote"]},"application/vnd.rim.cod":{source:"apache",extensions:["cod"]},"application/vnd.rn-realmedia":{source:"apache",extensions:["rm"]},"application/vnd.rn-realmedia-vbr":{source:"apache",extensions:["rmvb"]},"application/vnd.route66.link66+xml":{source:"iana",compressible:!0,extensions:["link66"]},"application/vnd.rs-274x":{source:"iana"},"application/vnd.ruckus.download":{source:"iana"},"application/vnd.s3sms":{source:"iana"},"application/vnd.sailingtracker.track":{source:"iana",extensions:["st"]},"application/vnd.sar":{source:"iana"},"application/vnd.sbm.cid":{source:"iana"},"application/vnd.sbm.mid2":{source:"iana"},"application/vnd.scribus":{source:"iana"},"application/vnd.sealed.3df":{source:"iana"},"application/vnd.sealed.csf":{source:"iana"},"application/vnd.sealed.doc":{source:"iana"},"application/vnd.sealed.eml":{source:"iana"},"application/vnd.sealed.mht":{source:"iana"},"application/vnd.sealed.net":{source:"iana"},"application/vnd.sealed.ppt":{source:"iana"},"application/vnd.sealed.tiff":{source:"iana"},"application/vnd.sealed.xls":{source:"iana"},"application/vnd.sealedmedia.softseal.html":{source:"iana"},"application/vnd.sealedmedia.softseal.pdf":{source:"iana"},"application/vnd.seemail":{source:"iana",extensions:["see"]},"application/vnd.seis+json":{source:"iana",compressible:!0},"application/vnd.sema":{source:"iana",extensions:["sema"]},"application/vnd.semd":{source:"iana",extensions:["semd"]},"application/vnd.semf":{source:"iana",extensions:["semf"]},"application/vnd.shade-save-file":{source:"iana"},"application/vnd.shana.informed.formdata":{source:"iana",extensions:["ifm"]},"application/vnd.shana.informed.formtemplate":{source:"iana",extensions:["itp"]},"application/vnd.shana.informed.interchange":{source:"iana",extensions:["iif"]},"application/vnd.shana.informed.package":{source:"iana",extensions:["ipk"]},"application/vnd.shootproof+json":{source:"iana",compressible:!0},"application/vnd.shopkick+json":{source:"iana",compressible:!0},"application/vnd.shp":{source:"iana"},"application/vnd.shx":{source:"iana"},"application/vnd.sigrok.session":{source:"iana"},"application/vnd.simtech-mindmapper":{source:"iana",extensions:["twd","twds"]},"application/vnd.siren+json":{source:"iana",compressible:!0},"application/vnd.smaf":{source:"iana",extensions:["mmf"]},"application/vnd.smart.notebook":{source:"iana"},"application/vnd.smart.teacher":{source:"iana",extensions:["teacher"]},"application/vnd.snesdev-page-table":{source:"iana"},"application/vnd.software602.filler.form+xml":{source:"iana",compressible:!0,extensions:["fo"]},"application/vnd.software602.filler.form-xml-zip":{source:"iana"},"application/vnd.solent.sdkm+xml":{source:"iana",compressible:!0,extensions:["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{source:"iana",extensions:["dxp"]},"application/vnd.spotfire.sfs":{source:"iana",extensions:["sfs"]},"application/vnd.sqlite3":{source:"iana"},"application/vnd.sss-cod":{source:"iana"},"application/vnd.sss-dtf":{source:"iana"},"application/vnd.sss-ntf":{source:"iana"},"application/vnd.stardivision.calc":{source:"apache",extensions:["sdc"]},"application/vnd.stardivision.draw":{source:"apache",extensions:["sda"]},"application/vnd.stardivision.impress":{source:"apache",extensions:["sdd"]},"application/vnd.stardivision.math":{source:"apache",extensions:["smf"]},"application/vnd.stardivision.writer":{source:"apache",extensions:["sdw","vor"]},"application/vnd.stardivision.writer-global":{source:"apache",extensions:["sgl"]},"application/vnd.stepmania.package":{source:"iana",extensions:["smzip"]},"application/vnd.stepmania.stepchart":{source:"iana",extensions:["sm"]},"application/vnd.street-stream":{source:"iana"},"application/vnd.sun.wadl+xml":{source:"iana",compressible:!0,extensions:["wadl"]},"application/vnd.sun.xml.calc":{source:"apache",extensions:["sxc"]},"application/vnd.sun.xml.calc.template":{source:"apache",extensions:["stc"]},"application/vnd.sun.xml.draw":{source:"apache",extensions:["sxd"]},"application/vnd.sun.xml.draw.template":{source:"apache",extensions:["std"]},"application/vnd.sun.xml.impress":{source:"apache",extensions:["sxi"]},"application/vnd.sun.xml.impress.template":{source:"apache",extensions:["sti"]},"application/vnd.sun.xml.math":{source:"apache",extensions:["sxm"]},"application/vnd.sun.xml.writer":{source:"apache",extensions:["sxw"]},"application/vnd.sun.xml.writer.global":{source:"apache",extensions:["sxg"]},"application/vnd.sun.xml.writer.template":{source:"apache",extensions:["stw"]},"application/vnd.sus-calendar":{source:"iana",extensions:["sus","susp"]},"application/vnd.svd":{source:"iana",extensions:["svd"]},"application/vnd.swiftview-ics":{source:"iana"},"application/vnd.sycle+xml":{source:"iana",compressible:!0},"application/vnd.syft+json":{source:"iana",compressible:!0},"application/vnd.symbian.install":{source:"apache",extensions:["sis","sisx"]},"application/vnd.syncml+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xsm"]},"application/vnd.syncml.dm+wbxml":{source:"iana",charset:"UTF-8",extensions:["bdm"]},"application/vnd.syncml.dm+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["xdm"]},"application/vnd.syncml.dm.notification":{source:"iana"},"application/vnd.syncml.dmddf+wbxml":{source:"iana"},"application/vnd.syncml.dmddf+xml":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["ddf"]},"application/vnd.syncml.dmtnds+wbxml":{source:"iana"},"application/vnd.syncml.dmtnds+xml":{source:"iana",charset:"UTF-8",compressible:!0},"application/vnd.syncml.ds.notification":{source:"iana"},"application/vnd.tableschema+json":{source:"iana",compressible:!0},"application/vnd.tao.intent-module-archive":{source:"iana",extensions:["tao"]},"application/vnd.tcpdump.pcap":{source:"iana",extensions:["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{source:"iana",compressible:!0},"application/vnd.tmd.mediaflex.api+xml":{source:"iana",compressible:!0},"application/vnd.tml":{source:"iana"},"application/vnd.tmobile-livetv":{source:"iana",extensions:["tmo"]},"application/vnd.tri.onesource":{source:"iana"},"application/vnd.trid.tpt":{source:"iana",extensions:["tpt"]},"application/vnd.triscape.mxs":{source:"iana",extensions:["mxs"]},"application/vnd.trueapp":{source:"iana",extensions:["tra"]},"application/vnd.truedoc":{source:"iana"},"application/vnd.ubisoft.webplayer":{source:"iana"},"application/vnd.ufdl":{source:"iana",extensions:["ufd","ufdl"]},"application/vnd.uiq.theme":{source:"iana",extensions:["utz"]},"application/vnd.umajin":{source:"iana",extensions:["umj"]},"application/vnd.unity":{source:"iana",extensions:["unityweb"]},"application/vnd.uoml+xml":{source:"iana",compressible:!0,extensions:["uoml"]},"application/vnd.uplanet.alert":{source:"iana"},"application/vnd.uplanet.alert-wbxml":{source:"iana"},"application/vnd.uplanet.bearer-choice":{source:"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{source:"iana"},"application/vnd.uplanet.cacheop":{source:"iana"},"application/vnd.uplanet.cacheop-wbxml":{source:"iana"},"application/vnd.uplanet.channel":{source:"iana"},"application/vnd.uplanet.channel-wbxml":{source:"iana"},"application/vnd.uplanet.list":{source:"iana"},"application/vnd.uplanet.list-wbxml":{source:"iana"},"application/vnd.uplanet.listcmd":{source:"iana"},"application/vnd.uplanet.listcmd-wbxml":{source:"iana"},"application/vnd.uplanet.signal":{source:"iana"},"application/vnd.uri-map":{source:"iana"},"application/vnd.valve.source.material":{source:"iana"},"application/vnd.vcx":{source:"iana",extensions:["vcx"]},"application/vnd.vd-study":{source:"iana"},"application/vnd.vectorworks":{source:"iana"},"application/vnd.vel+json":{source:"iana",compressible:!0},"application/vnd.verimatrix.vcas":{source:"iana"},"application/vnd.veritone.aion+json":{source:"iana",compressible:!0},"application/vnd.veryant.thin":{source:"iana"},"application/vnd.ves.encrypted":{source:"iana"},"application/vnd.vidsoft.vidconference":{source:"iana"},"application/vnd.visio":{source:"iana",extensions:["vsd","vst","vss","vsw"]},"application/vnd.visionary":{source:"iana",extensions:["vis"]},"application/vnd.vividence.scriptfile":{source:"iana"},"application/vnd.vsf":{source:"iana",extensions:["vsf"]},"application/vnd.wap.sic":{source:"iana"},"application/vnd.wap.slc":{source:"iana"},"application/vnd.wap.wbxml":{source:"iana",charset:"UTF-8",extensions:["wbxml"]},"application/vnd.wap.wmlc":{source:"iana",extensions:["wmlc"]},"application/vnd.wap.wmlscriptc":{source:"iana",extensions:["wmlsc"]},"application/vnd.webturbo":{source:"iana",extensions:["wtb"]},"application/vnd.wfa.dpp":{source:"iana"},"application/vnd.wfa.p2p":{source:"iana"},"application/vnd.wfa.wsc":{source:"iana"},"application/vnd.windows.devicepairing":{source:"iana"},"application/vnd.wmc":{source:"iana"},"application/vnd.wmf.bootstrap":{source:"iana"},"application/vnd.wolfram.mathematica":{source:"iana"},"application/vnd.wolfram.mathematica.package":{source:"iana"},"application/vnd.wolfram.player":{source:"iana",extensions:["nbp"]},"application/vnd.wordperfect":{source:"iana",extensions:["wpd"]},"application/vnd.wqd":{source:"iana",extensions:["wqd"]},"application/vnd.wrq-hp3000-labelled":{source:"iana"},"application/vnd.wt.stf":{source:"iana",extensions:["stf"]},"application/vnd.wv.csp+wbxml":{source:"iana"},"application/vnd.wv.csp+xml":{source:"iana",compressible:!0},"application/vnd.wv.ssp+xml":{source:"iana",compressible:!0},"application/vnd.xacml+json":{source:"iana",compressible:!0},"application/vnd.xara":{source:"iana",extensions:["xar"]},"application/vnd.xfdl":{source:"iana",extensions:["xfdl"]},"application/vnd.xfdl.webform":{source:"iana"},"application/vnd.xmi+xml":{source:"iana",compressible:!0},"application/vnd.xmpie.cpkg":{source:"iana"},"application/vnd.xmpie.dpkg":{source:"iana"},"application/vnd.xmpie.plan":{source:"iana"},"application/vnd.xmpie.ppkg":{source:"iana"},"application/vnd.xmpie.xlim":{source:"iana"},"application/vnd.yamaha.hv-dic":{source:"iana",extensions:["hvd"]},"application/vnd.yamaha.hv-script":{source:"iana",extensions:["hvs"]},"application/vnd.yamaha.hv-voice":{source:"iana",extensions:["hvp"]},"application/vnd.yamaha.openscoreformat":{source:"iana",extensions:["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{source:"iana",compressible:!0,extensions:["osfpvg"]},"application/vnd.yamaha.remote-setup":{source:"iana"},"application/vnd.yamaha.smaf-audio":{source:"iana",extensions:["saf"]},"application/vnd.yamaha.smaf-phrase":{source:"iana",extensions:["spf"]},"application/vnd.yamaha.through-ngn":{source:"iana"},"application/vnd.yamaha.tunnel-udpencap":{source:"iana"},"application/vnd.yaoweme":{source:"iana"},"application/vnd.yellowriver-custom-menu":{source:"iana",extensions:["cmp"]},"application/vnd.youtube.yt":{source:"iana"},"application/vnd.zul":{source:"iana",extensions:["zir","zirz"]},"application/vnd.zzazz.deck+xml":{source:"iana",compressible:!0,extensions:["zaz"]},"application/voicexml+xml":{source:"iana",compressible:!0,extensions:["vxml"]},"application/voucher-cms+json":{source:"iana",compressible:!0},"application/vq-rtcpxr":{source:"iana"},"application/wasm":{source:"iana",compressible:!0,extensions:["wasm"]},"application/watcherinfo+xml":{source:"iana",compressible:!0,extensions:["wif"]},"application/webpush-options+json":{source:"iana",compressible:!0},"application/whoispp-query":{source:"iana"},"application/whoispp-response":{source:"iana"},"application/widget":{source:"iana",extensions:["wgt"]},"application/winhlp":{source:"apache",extensions:["hlp"]},"application/wita":{source:"iana"},"application/wordperfect5.1":{source:"iana"},"application/wsdl+xml":{source:"iana",compressible:!0,extensions:["wsdl"]},"application/wspolicy+xml":{source:"iana",compressible:!0,extensions:["wspolicy"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/x-abiword":{source:"apache",extensions:["abw"]},"application/x-ace-compressed":{source:"apache",extensions:["ace"]},"application/x-amf":{source:"apache"},"application/x-apple-diskimage":{source:"apache",extensions:["dmg"]},"application/x-arj":{compressible:!1,extensions:["arj"]},"application/x-authorware-bin":{source:"apache",extensions:["aab","x32","u32","vox"]},"application/x-authorware-map":{source:"apache",extensions:["aam"]},"application/x-authorware-seg":{source:"apache",extensions:["aas"]},"application/x-bcpio":{source:"apache",extensions:["bcpio"]},"application/x-bdoc":{compressible:!1,extensions:["bdoc"]},"application/x-bittorrent":{source:"apache",extensions:["torrent"]},"application/x-blorb":{source:"apache",extensions:["blb","blorb"]},"application/x-bzip":{source:"apache",compressible:!1,extensions:["bz"]},"application/x-bzip2":{source:"apache",compressible:!1,extensions:["bz2","boz"]},"application/x-cbr":{source:"apache",extensions:["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{source:"apache",extensions:["vcd"]},"application/x-cfs-compressed":{source:"apache",extensions:["cfs"]},"application/x-chat":{source:"apache",extensions:["chat"]},"application/x-chess-pgn":{source:"apache",extensions:["pgn"]},"application/x-chrome-extension":{extensions:["crx"]},"application/x-cocoa":{source:"nginx",extensions:["cco"]},"application/x-compress":{source:"apache"},"application/x-conference":{source:"apache",extensions:["nsc"]},"application/x-cpio":{source:"apache",extensions:["cpio"]},"application/x-csh":{source:"apache",extensions:["csh"]},"application/x-deb":{compressible:!1},"application/x-debian-package":{source:"apache",extensions:["deb","udeb"]},"application/x-dgc-compressed":{source:"apache",extensions:["dgc"]},"application/x-director":{source:"apache",extensions:["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{source:"apache",extensions:["wad"]},"application/x-dtbncx+xml":{source:"apache",compressible:!0,extensions:["ncx"]},"application/x-dtbook+xml":{source:"apache",compressible:!0,extensions:["dtb"]},"application/x-dtbresource+xml":{source:"apache",compressible:!0,extensions:["res"]},"application/x-dvi":{source:"apache",compressible:!1,extensions:["dvi"]},"application/x-envoy":{source:"apache",extensions:["evy"]},"application/x-eva":{source:"apache",extensions:["eva"]},"application/x-font-bdf":{source:"apache",extensions:["bdf"]},"application/x-font-dos":{source:"apache"},"application/x-font-framemaker":{source:"apache"},"application/x-font-ghostscript":{source:"apache",extensions:["gsf"]},"application/x-font-libgrx":{source:"apache"},"application/x-font-linux-psf":{source:"apache",extensions:["psf"]},"application/x-font-pcf":{source:"apache",extensions:["pcf"]},"application/x-font-snf":{source:"apache",extensions:["snf"]},"application/x-font-speedo":{source:"apache"},"application/x-font-sunos-news":{source:"apache"},"application/x-font-type1":{source:"apache",extensions:["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{source:"apache"},"application/x-freearc":{source:"apache",extensions:["arc"]},"application/x-futuresplash":{source:"apache",extensions:["spl"]},"application/x-gca-compressed":{source:"apache",extensions:["gca"]},"application/x-glulx":{source:"apache",extensions:["ulx"]},"application/x-gnumeric":{source:"apache",extensions:["gnumeric"]},"application/x-gramps-xml":{source:"apache",extensions:["gramps"]},"application/x-gtar":{source:"apache",extensions:["gtar"]},"application/x-gzip":{source:"apache"},"application/x-hdf":{source:"apache",extensions:["hdf"]},"application/x-httpd-php":{compressible:!0,extensions:["php"]},"application/x-install-instructions":{source:"apache",extensions:["install"]},"application/x-iso9660-image":{source:"apache",extensions:["iso"]},"application/x-iwork-keynote-sffkey":{extensions:["key"]},"application/x-iwork-numbers-sffnumbers":{extensions:["numbers"]},"application/x-iwork-pages-sffpages":{extensions:["pages"]},"application/x-java-archive-diff":{source:"nginx",extensions:["jardiff"]},"application/x-java-jnlp-file":{source:"apache",compressible:!1,extensions:["jnlp"]},"application/x-javascript":{compressible:!0},"application/x-keepass2":{extensions:["kdbx"]},"application/x-latex":{source:"apache",compressible:!1,extensions:["latex"]},"application/x-lua-bytecode":{extensions:["luac"]},"application/x-lzh-compressed":{source:"apache",extensions:["lzh","lha"]},"application/x-makeself":{source:"nginx",extensions:["run"]},"application/x-mie":{source:"apache",extensions:["mie"]},"application/x-mobipocket-ebook":{source:"apache",extensions:["prc","mobi"]},"application/x-mpegurl":{compressible:!1},"application/x-ms-application":{source:"apache",extensions:["application"]},"application/x-ms-shortcut":{source:"apache",extensions:["lnk"]},"application/x-ms-wmd":{source:"apache",extensions:["wmd"]},"application/x-ms-wmz":{source:"apache",extensions:["wmz"]},"application/x-ms-xbap":{source:"apache",extensions:["xbap"]},"application/x-msaccess":{source:"apache",extensions:["mdb"]},"application/x-msbinder":{source:"apache",extensions:["obd"]},"application/x-mscardfile":{source:"apache",extensions:["crd"]},"application/x-msclip":{source:"apache",extensions:["clp"]},"application/x-msdos-program":{extensions:["exe"]},"application/x-msdownload":{source:"apache",extensions:["exe","dll","com","bat","msi"]},"application/x-msmediaview":{source:"apache",extensions:["mvb","m13","m14"]},"application/x-msmetafile":{source:"apache",extensions:["wmf","wmz","emf","emz"]},"application/x-msmoney":{source:"apache",extensions:["mny"]},"application/x-mspublisher":{source:"apache",extensions:["pub"]},"application/x-msschedule":{source:"apache",extensions:["scd"]},"application/x-msterminal":{source:"apache",extensions:["trm"]},"application/x-mswrite":{source:"apache",extensions:["wri"]},"application/x-netcdf":{source:"apache",extensions:["nc","cdf"]},"application/x-ns-proxy-autoconfig":{compressible:!0,extensions:["pac"]},"application/x-nzb":{source:"apache",extensions:["nzb"]},"application/x-perl":{source:"nginx",extensions:["pl","pm"]},"application/x-pilot":{source:"nginx",extensions:["prc","pdb"]},"application/x-pkcs12":{source:"apache",compressible:!1,extensions:["p12","pfx"]},"application/x-pkcs7-certificates":{source:"apache",extensions:["p7b","spc"]},"application/x-pkcs7-certreqresp":{source:"apache",extensions:["p7r"]},"application/x-pki-message":{source:"iana"},"application/x-rar-compressed":{source:"apache",compressible:!1,extensions:["rar"]},"application/x-redhat-package-manager":{source:"nginx",extensions:["rpm"]},"application/x-research-info-systems":{source:"apache",extensions:["ris"]},"application/x-sea":{source:"nginx",extensions:["sea"]},"application/x-sh":{source:"apache",compressible:!0,extensions:["sh"]},"application/x-shar":{source:"apache",extensions:["shar"]},"application/x-shockwave-flash":{source:"apache",compressible:!1,extensions:["swf"]},"application/x-silverlight-app":{source:"apache",extensions:["xap"]},"application/x-sql":{source:"apache",extensions:["sql"]},"application/x-stuffit":{source:"apache",compressible:!1,extensions:["sit"]},"application/x-stuffitx":{source:"apache",extensions:["sitx"]},"application/x-subrip":{source:"apache",extensions:["srt"]},"application/x-sv4cpio":{source:"apache",extensions:["sv4cpio"]},"application/x-sv4crc":{source:"apache",extensions:["sv4crc"]},"application/x-t3vm-image":{source:"apache",extensions:["t3"]},"application/x-tads":{source:"apache",extensions:["gam"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-tcl":{source:"apache",extensions:["tcl","tk"]},"application/x-tex":{source:"apache",extensions:["tex"]},"application/x-tex-tfm":{source:"apache",extensions:["tfm"]},"application/x-texinfo":{source:"apache",extensions:["texinfo","texi"]},"application/x-tgif":{source:"apache",extensions:["obj"]},"application/x-ustar":{source:"apache",extensions:["ustar"]},"application/x-virtualbox-hdd":{compressible:!0,extensions:["hdd"]},"application/x-virtualbox-ova":{compressible:!0,extensions:["ova"]},"application/x-virtualbox-ovf":{compressible:!0,extensions:["ovf"]},"application/x-virtualbox-vbox":{compressible:!0,extensions:["vbox"]},"application/x-virtualbox-vbox-extpack":{compressible:!1,extensions:["vbox-extpack"]},"application/x-virtualbox-vdi":{compressible:!0,extensions:["vdi"]},"application/x-virtualbox-vhd":{compressible:!0,extensions:["vhd"]},"application/x-virtualbox-vmdk":{compressible:!0,extensions:["vmdk"]},"application/x-wais-source":{source:"apache",extensions:["src"]},"application/x-web-app-manifest+json":{compressible:!0,extensions:["webapp"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"application/x-x509-ca-cert":{source:"iana",extensions:["der","crt","pem"]},"application/x-x509-ca-ra-cert":{source:"iana"},"application/x-x509-next-ca-cert":{source:"iana"},"application/x-xfig":{source:"apache",extensions:["fig"]},"application/x-xliff+xml":{source:"apache",compressible:!0,extensions:["xlf"]},"application/x-xpinstall":{source:"apache",compressible:!1,extensions:["xpi"]},"application/x-xz":{source:"apache",extensions:["xz"]},"application/x-zmachine":{source:"apache",extensions:["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{source:"iana"},"application/xacml+xml":{source:"iana",compressible:!0},"application/xaml+xml":{source:"apache",compressible:!0,extensions:["xaml"]},"application/xcap-att+xml":{source:"iana",compressible:!0,extensions:["xav"]},"application/xcap-caps+xml":{source:"iana",compressible:!0,extensions:["xca"]},"application/xcap-diff+xml":{source:"iana",compressible:!0,extensions:["xdf"]},"application/xcap-el+xml":{source:"iana",compressible:!0,extensions:["xel"]},"application/xcap-error+xml":{source:"iana",compressible:!0},"application/xcap-ns+xml":{source:"iana",compressible:!0,extensions:["xns"]},"application/xcon-conference-info+xml":{source:"iana",compressible:!0},"application/xcon-conference-info-diff+xml":{source:"iana",compressible:!0},"application/xenc+xml":{source:"iana",compressible:!0,extensions:["xenc"]},"application/xhtml+xml":{source:"iana",compressible:!0,extensions:["xhtml","xht"]},"application/xhtml-voice+xml":{source:"apache",compressible:!0},"application/xliff+xml":{source:"iana",compressible:!0,extensions:["xlf"]},"application/xml":{source:"iana",compressible:!0,extensions:["xml","xsl","xsd","rng"]},"application/xml-dtd":{source:"iana",compressible:!0,extensions:["dtd"]},"application/xml-external-parsed-entity":{source:"iana"},"application/xml-patch+xml":{source:"iana",compressible:!0},"application/xmpp+xml":{source:"iana",compressible:!0},"application/xop+xml":{source:"iana",compressible:!0,extensions:["xop"]},"application/xproc+xml":{source:"apache",compressible:!0,extensions:["xpl"]},"application/xslt+xml":{source:"iana",compressible:!0,extensions:["xsl","xslt"]},"application/xspf+xml":{source:"apache",compressible:!0,extensions:["xspf"]},"application/xv+xml":{source:"iana",compressible:!0,extensions:["mxml","xhvml","xvml","xvm"]},"application/yang":{source:"iana",extensions:["yang"]},"application/yang-data+json":{source:"iana",compressible:!0},"application/yang-data+xml":{source:"iana",compressible:!0},"application/yang-patch+json":{source:"iana",compressible:!0},"application/yang-patch+xml":{source:"iana",compressible:!0},"application/yin+xml":{source:"iana",compressible:!0,extensions:["yin"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/zlib":{source:"iana"},"application/zstd":{source:"iana"},"audio/1d-interleaved-parityfec":{source:"iana"},"audio/32kadpcm":{source:"iana"},"audio/3gpp":{source:"iana",compressible:!1,extensions:["3gpp"]},"audio/3gpp2":{source:"iana"},"audio/aac":{source:"iana"},"audio/ac3":{source:"iana"},"audio/adpcm":{source:"apache",extensions:["adp"]},"audio/amr":{source:"iana",extensions:["amr"]},"audio/amr-wb":{source:"iana"},"audio/amr-wb+":{source:"iana"},"audio/aptx":{source:"iana"},"audio/asc":{source:"iana"},"audio/atrac-advanced-lossless":{source:"iana"},"audio/atrac-x":{source:"iana"},"audio/atrac3":{source:"iana"},"audio/basic":{source:"iana",compressible:!1,extensions:["au","snd"]},"audio/bv16":{source:"iana"},"audio/bv32":{source:"iana"},"audio/clearmode":{source:"iana"},"audio/cn":{source:"iana"},"audio/dat12":{source:"iana"},"audio/dls":{source:"iana"},"audio/dsr-es201108":{source:"iana"},"audio/dsr-es202050":{source:"iana"},"audio/dsr-es202211":{source:"iana"},"audio/dsr-es202212":{source:"iana"},"audio/dv":{source:"iana"},"audio/dvi4":{source:"iana"},"audio/eac3":{source:"iana"},"audio/encaprtp":{source:"iana"},"audio/evrc":{source:"iana"},"audio/evrc-qcp":{source:"iana"},"audio/evrc0":{source:"iana"},"audio/evrc1":{source:"iana"},"audio/evrcb":{source:"iana"},"audio/evrcb0":{source:"iana"},"audio/evrcb1":{source:"iana"},"audio/evrcnw":{source:"iana"},"audio/evrcnw0":{source:"iana"},"audio/evrcnw1":{source:"iana"},"audio/evrcwb":{source:"iana"},"audio/evrcwb0":{source:"iana"},"audio/evrcwb1":{source:"iana"},"audio/evs":{source:"iana"},"audio/flexfec":{source:"iana"},"audio/fwdred":{source:"iana"},"audio/g711-0":{source:"iana"},"audio/g719":{source:"iana"},"audio/g722":{source:"iana"},"audio/g7221":{source:"iana"},"audio/g723":{source:"iana"},"audio/g726-16":{source:"iana"},"audio/g726-24":{source:"iana"},"audio/g726-32":{source:"iana"},"audio/g726-40":{source:"iana"},"audio/g728":{source:"iana"},"audio/g729":{source:"iana"},"audio/g7291":{source:"iana"},"audio/g729d":{source:"iana"},"audio/g729e":{source:"iana"},"audio/gsm":{source:"iana"},"audio/gsm-efr":{source:"iana"},"audio/gsm-hr-08":{source:"iana"},"audio/ilbc":{source:"iana"},"audio/ip-mr_v2.5":{source:"iana"},"audio/isac":{source:"apache"},"audio/l16":{source:"iana"},"audio/l20":{source:"iana"},"audio/l24":{source:"iana",compressible:!1},"audio/l8":{source:"iana"},"audio/lpc":{source:"iana"},"audio/melp":{source:"iana"},"audio/melp1200":{source:"iana"},"audio/melp2400":{source:"iana"},"audio/melp600":{source:"iana"},"audio/mhas":{source:"iana"},"audio/midi":{source:"apache",extensions:["mid","midi","kar","rmi"]},"audio/mobile-xmf":{source:"iana",extensions:["mxmf"]},"audio/mp3":{compressible:!1,extensions:["mp3"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a","mp4a"]},"audio/mp4a-latm":{source:"iana"},"audio/mpa":{source:"iana"},"audio/mpa-robust":{source:"iana"},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{source:"iana"},"audio/musepack":{source:"apache"},"audio/ogg":{source:"iana",compressible:!1,extensions:["oga","ogg","spx","opus"]},"audio/opus":{source:"iana"},"audio/parityfec":{source:"iana"},"audio/pcma":{source:"iana"},"audio/pcma-wb":{source:"iana"},"audio/pcmu":{source:"iana"},"audio/pcmu-wb":{source:"iana"},"audio/prs.sid":{source:"iana"},"audio/qcelp":{source:"iana"},"audio/raptorfec":{source:"iana"},"audio/red":{source:"iana"},"audio/rtp-enc-aescm128":{source:"iana"},"audio/rtp-midi":{source:"iana"},"audio/rtploopback":{source:"iana"},"audio/rtx":{source:"iana"},"audio/s3m":{source:"apache",extensions:["s3m"]},"audio/scip":{source:"iana"},"audio/silk":{source:"apache",extensions:["sil"]},"audio/smv":{source:"iana"},"audio/smv-qcp":{source:"iana"},"audio/smv0":{source:"iana"},"audio/sofa":{source:"iana"},"audio/sp-midi":{source:"iana"},"audio/speex":{source:"iana"},"audio/t140c":{source:"iana"},"audio/t38":{source:"iana"},"audio/telephone-event":{source:"iana"},"audio/tetra_acelp":{source:"iana"},"audio/tetra_acelp_bb":{source:"iana"},"audio/tone":{source:"iana"},"audio/tsvcis":{source:"iana"},"audio/uemclip":{source:"iana"},"audio/ulpfec":{source:"iana"},"audio/usac":{source:"iana"},"audio/vdvi":{source:"iana"},"audio/vmr-wb":{source:"iana"},"audio/vnd.3gpp.iufp":{source:"iana"},"audio/vnd.4sb":{source:"iana"},"audio/vnd.audiokoz":{source:"iana"},"audio/vnd.celp":{source:"iana"},"audio/vnd.cisco.nse":{source:"iana"},"audio/vnd.cmles.radio-events":{source:"iana"},"audio/vnd.cns.anp1":{source:"iana"},"audio/vnd.cns.inf1":{source:"iana"},"audio/vnd.dece.audio":{source:"iana",extensions:["uva","uvva"]},"audio/vnd.digital-winds":{source:"iana",extensions:["eol"]},"audio/vnd.dlna.adts":{source:"iana"},"audio/vnd.dolby.heaac.1":{source:"iana"},"audio/vnd.dolby.heaac.2":{source:"iana"},"audio/vnd.dolby.mlp":{source:"iana"},"audio/vnd.dolby.mps":{source:"iana"},"audio/vnd.dolby.pl2":{source:"iana"},"audio/vnd.dolby.pl2x":{source:"iana"},"audio/vnd.dolby.pl2z":{source:"iana"},"audio/vnd.dolby.pulse.1":{source:"iana"},"audio/vnd.dra":{source:"iana",extensions:["dra"]},"audio/vnd.dts":{source:"iana",extensions:["dts"]},"audio/vnd.dts.hd":{source:"iana",extensions:["dtshd"]},"audio/vnd.dts.uhd":{source:"iana"},"audio/vnd.dvb.file":{source:"iana"},"audio/vnd.everad.plj":{source:"iana"},"audio/vnd.hns.audio":{source:"iana"},"audio/vnd.lucent.voice":{source:"iana",extensions:["lvp"]},"audio/vnd.ms-playready.media.pya":{source:"iana",extensions:["pya"]},"audio/vnd.nokia.mobile-xmf":{source:"iana"},"audio/vnd.nortel.vbk":{source:"iana"},"audio/vnd.nuera.ecelp4800":{source:"iana",extensions:["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{source:"iana",extensions:["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{source:"iana",extensions:["ecelp9600"]},"audio/vnd.octel.sbc":{source:"iana"},"audio/vnd.presonus.multitrack":{source:"iana"},"audio/vnd.qcelp":{source:"iana"},"audio/vnd.rhetorex.32kadpcm":{source:"iana"},"audio/vnd.rip":{source:"iana",extensions:["rip"]},"audio/vnd.rn-realaudio":{compressible:!1},"audio/vnd.sealedmedia.softseal.mpeg":{source:"iana"},"audio/vnd.vmx.cvsd":{source:"iana"},"audio/vnd.wave":{compressible:!1},"audio/vorbis":{source:"iana",compressible:!1},"audio/vorbis-config":{source:"iana"},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/wave":{compressible:!1,extensions:["wav"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/x-aac":{source:"apache",compressible:!1,extensions:["aac"]},"audio/x-aiff":{source:"apache",extensions:["aif","aiff","aifc"]},"audio/x-caf":{source:"apache",compressible:!1,extensions:["caf"]},"audio/x-flac":{source:"apache",extensions:["flac"]},"audio/x-m4a":{source:"nginx",extensions:["m4a"]},"audio/x-matroska":{source:"apache",extensions:["mka"]},"audio/x-mpegurl":{source:"apache",extensions:["m3u"]},"audio/x-ms-wax":{source:"apache",extensions:["wax"]},"audio/x-ms-wma":{source:"apache",extensions:["wma"]},"audio/x-pn-realaudio":{source:"apache",extensions:["ram","ra"]},"audio/x-pn-realaudio-plugin":{source:"apache",extensions:["rmp"]},"audio/x-realaudio":{source:"nginx",extensions:["ra"]},"audio/x-tta":{source:"apache"},"audio/x-wav":{source:"apache",extensions:["wav"]},"audio/xm":{source:"apache",extensions:["xm"]},"chemical/x-cdx":{source:"apache",extensions:["cdx"]},"chemical/x-cif":{source:"apache",extensions:["cif"]},"chemical/x-cmdf":{source:"apache",extensions:["cmdf"]},"chemical/x-cml":{source:"apache",extensions:["cml"]},"chemical/x-csml":{source:"apache",extensions:["csml"]},"chemical/x-pdb":{source:"apache"},"chemical/x-xyz":{source:"apache",extensions:["xyz"]},"font/collection":{source:"iana",extensions:["ttc"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"font/sfnt":{source:"iana"},"font/ttf":{source:"iana",compressible:!0,extensions:["ttf"]},"font/woff":{source:"iana",extensions:["woff"]},"font/woff2":{source:"iana",extensions:["woff2"]},"image/aces":{source:"iana",extensions:["exr"]},"image/apng":{compressible:!1,extensions:["apng"]},"image/avci":{source:"iana",extensions:["avci"]},"image/avcs":{source:"iana",extensions:["avcs"]},"image/avif":{source:"iana",compressible:!1,extensions:["avif"]},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/cgm":{source:"iana",extensions:["cgm"]},"image/dicom-rle":{source:"iana",extensions:["drle"]},"image/emf":{source:"iana",extensions:["emf"]},"image/fits":{source:"iana",extensions:["fits"]},"image/g3fax":{source:"iana",extensions:["g3"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/heic":{source:"iana",extensions:["heic"]},"image/heic-sequence":{source:"iana",extensions:["heics"]},"image/heif":{source:"iana",extensions:["heif"]},"image/heif-sequence":{source:"iana",extensions:["heifs"]},"image/hej2k":{source:"iana",extensions:["hej2"]},"image/hsj2":{source:"iana",extensions:["hsj2"]},"image/ief":{source:"iana",extensions:["ief"]},"image/jls":{source:"iana",extensions:["jls"]},"image/jp2":{source:"iana",compressible:!1,extensions:["jp2","jpg2"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/jph":{source:"iana",extensions:["jph"]},"image/jphc":{source:"iana",extensions:["jhc"]},"image/jpm":{source:"iana",compressible:!1,extensions:["jpm"]},"image/jpx":{source:"iana",compressible:!1,extensions:["jpx","jpf"]},"image/jxr":{source:"iana",extensions:["jxr"]},"image/jxra":{source:"iana",extensions:["jxra"]},"image/jxrs":{source:"iana",extensions:["jxrs"]},"image/jxs":{source:"iana",extensions:["jxs"]},"image/jxsc":{source:"iana",extensions:["jxsc"]},"image/jxsi":{source:"iana",extensions:["jxsi"]},"image/jxss":{source:"iana",extensions:["jxss"]},"image/ktx":{source:"iana",extensions:["ktx"]},"image/ktx2":{source:"iana",extensions:["ktx2"]},"image/naplps":{source:"iana"},"image/pjpeg":{compressible:!1},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/prs.btif":{source:"iana",extensions:["btif"]},"image/prs.pti":{source:"iana",extensions:["pti"]},"image/pwg-raster":{source:"iana"},"image/sgi":{source:"apache",extensions:["sgi"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/t38":{source:"iana",extensions:["t38"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tif","tiff"]},"image/tiff-fx":{source:"iana",extensions:["tfx"]},"image/vnd.adobe.photoshop":{source:"iana",compressible:!0,extensions:["psd"]},"image/vnd.airzip.accelerator.azv":{source:"iana",extensions:["azv"]},"image/vnd.cns.inf2":{source:"iana"},"image/vnd.dece.graphic":{source:"iana",extensions:["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{source:"iana",extensions:["djvu","djv"]},"image/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"image/vnd.dwg":{source:"iana",extensions:["dwg"]},"image/vnd.dxf":{source:"iana",extensions:["dxf"]},"image/vnd.fastbidsheet":{source:"iana",extensions:["fbs"]},"image/vnd.fpx":{source:"iana",extensions:["fpx"]},"image/vnd.fst":{source:"iana",extensions:["fst"]},"image/vnd.fujixerox.edmics-mmr":{source:"iana",extensions:["mmr"]},"image/vnd.fujixerox.edmics-rlc":{source:"iana",extensions:["rlc"]},"image/vnd.globalgraphics.pgb":{source:"iana"},"image/vnd.microsoft.icon":{source:"iana",compressible:!0,extensions:["ico"]},"image/vnd.mix":{source:"iana"},"image/vnd.mozilla.apng":{source:"iana"},"image/vnd.ms-dds":{compressible:!0,extensions:["dds"]},"image/vnd.ms-modi":{source:"iana",extensions:["mdi"]},"image/vnd.ms-photo":{source:"apache",extensions:["wdp"]},"image/vnd.net-fpx":{source:"iana",extensions:["npx"]},"image/vnd.pco.b16":{source:"iana",extensions:["b16"]},"image/vnd.radiance":{source:"iana"},"image/vnd.sealed.png":{source:"iana"},"image/vnd.sealedmedia.softseal.gif":{source:"iana"},"image/vnd.sealedmedia.softseal.jpg":{source:"iana"},"image/vnd.svf":{source:"iana"},"image/vnd.tencent.tap":{source:"iana",extensions:["tap"]},"image/vnd.valve.source.texture":{source:"iana",extensions:["vtf"]},"image/vnd.wap.wbmp":{source:"iana",extensions:["wbmp"]},"image/vnd.xiff":{source:"iana",extensions:["xif"]},"image/vnd.zbrush.pcx":{source:"iana",extensions:["pcx"]},"image/webp":{source:"apache",extensions:["webp"]},"image/wmf":{source:"iana",extensions:["wmf"]},"image/x-3ds":{source:"apache",extensions:["3ds"]},"image/x-cmu-raster":{source:"apache",extensions:["ras"]},"image/x-cmx":{source:"apache",extensions:["cmx"]},"image/x-freehand":{source:"apache",extensions:["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/x-jng":{source:"nginx",extensions:["jng"]},"image/x-mrsid-image":{source:"apache",extensions:["sid"]},"image/x-ms-bmp":{source:"nginx",compressible:!0,extensions:["bmp"]},"image/x-pcx":{source:"apache",extensions:["pcx"]},"image/x-pict":{source:"apache",extensions:["pic","pct"]},"image/x-portable-anymap":{source:"apache",extensions:["pnm"]},"image/x-portable-bitmap":{source:"apache",extensions:["pbm"]},"image/x-portable-graymap":{source:"apache",extensions:["pgm"]},"image/x-portable-pixmap":{source:"apache",extensions:["ppm"]},"image/x-rgb":{source:"apache",extensions:["rgb"]},"image/x-tga":{source:"apache",extensions:["tga"]},"image/x-xbitmap":{source:"apache",extensions:["xbm"]},"image/x-xcf":{compressible:!1},"image/x-xpixmap":{source:"apache",extensions:["xpm"]},"image/x-xwindowdump":{source:"apache",extensions:["xwd"]},"message/cpim":{source:"iana"},"message/delivery-status":{source:"iana"},"message/disposition-notification":{source:"iana",extensions:["disposition-notification"]},"message/external-body":{source:"iana"},"message/feedback-report":{source:"iana"},"message/global":{source:"iana",extensions:["u8msg"]},"message/global-delivery-status":{source:"iana",extensions:["u8dsn"]},"message/global-disposition-notification":{source:"iana",extensions:["u8mdn"]},"message/global-headers":{source:"iana",extensions:["u8hdr"]},"message/http":{source:"iana",compressible:!1},"message/imdn+xml":{source:"iana",compressible:!0},"message/news":{source:"iana"},"message/partial":{source:"iana",compressible:!1},"message/rfc822":{source:"iana",compressible:!0,extensions:["eml","mime"]},"message/s-http":{source:"iana"},"message/sip":{source:"iana"},"message/sipfrag":{source:"iana"},"message/tracking-status":{source:"iana"},"message/vnd.si.simp":{source:"iana"},"message/vnd.wfa.wsc":{source:"iana",extensions:["wsc"]},"model/3mf":{source:"iana",extensions:["3mf"]},"model/e57":{source:"iana"},"model/gltf+json":{source:"iana",compressible:!0,extensions:["gltf"]},"model/gltf-binary":{source:"iana",compressible:!0,extensions:["glb"]},"model/iges":{source:"iana",compressible:!1,extensions:["igs","iges"]},"model/mesh":{source:"iana",compressible:!1,extensions:["msh","mesh","silo"]},"model/mtl":{source:"iana",extensions:["mtl"]},"model/obj":{source:"iana",extensions:["obj"]},"model/step":{source:"iana"},"model/step+xml":{source:"iana",compressible:!0,extensions:["stpx"]},"model/step+zip":{source:"iana",compressible:!1,extensions:["stpz"]},"model/step-xml+zip":{source:"iana",compressible:!1,extensions:["stpxz"]},"model/stl":{source:"iana",extensions:["stl"]},"model/vnd.collada+xml":{source:"iana",compressible:!0,extensions:["dae"]},"model/vnd.dwf":{source:"iana",extensions:["dwf"]},"model/vnd.flatland.3dml":{source:"iana"},"model/vnd.gdl":{source:"iana",extensions:["gdl"]},"model/vnd.gs-gdl":{source:"apache"},"model/vnd.gs.gdl":{source:"iana"},"model/vnd.gtw":{source:"iana",extensions:["gtw"]},"model/vnd.moml+xml":{source:"iana",compressible:!0},"model/vnd.mts":{source:"iana",extensions:["mts"]},"model/vnd.opengex":{source:"iana",extensions:["ogex"]},"model/vnd.parasolid.transmit.binary":{source:"iana",extensions:["x_b"]},"model/vnd.parasolid.transmit.text":{source:"iana",extensions:["x_t"]},"model/vnd.pytha.pyox":{source:"iana"},"model/vnd.rosette.annotated-data-model":{source:"iana"},"model/vnd.sap.vds":{source:"iana",extensions:["vds"]},"model/vnd.usdz+zip":{source:"iana",compressible:!1,extensions:["usdz"]},"model/vnd.valve.source.compiled-map":{source:"iana",extensions:["bsp"]},"model/vnd.vtu":{source:"iana",extensions:["vtu"]},"model/vrml":{source:"iana",compressible:!1,extensions:["wrl","vrml"]},"model/x3d+binary":{source:"apache",compressible:!1,extensions:["x3db","x3dbz"]},"model/x3d+fastinfoset":{source:"iana",extensions:["x3db"]},"model/x3d+vrml":{source:"apache",compressible:!1,extensions:["x3dv","x3dvz"]},"model/x3d+xml":{source:"iana",compressible:!0,extensions:["x3d","x3dz"]},"model/x3d-vrml":{source:"iana",extensions:["x3dv"]},"multipart/alternative":{source:"iana",compressible:!1},"multipart/appledouble":{source:"iana"},"multipart/byteranges":{source:"iana"},"multipart/digest":{source:"iana"},"multipart/encrypted":{source:"iana",compressible:!1},"multipart/form-data":{source:"iana",compressible:!1},"multipart/header-set":{source:"iana"},"multipart/mixed":{source:"iana"},"multipart/multilingual":{source:"iana"},"multipart/parallel":{source:"iana"},"multipart/related":{source:"iana",compressible:!1},"multipart/report":{source:"iana"},"multipart/signed":{source:"iana",compressible:!1},"multipart/vnd.bint.med-plus":{source:"iana"},"multipart/voice-message":{source:"iana"},"multipart/x-mixed-replace":{source:"iana"},"text/1d-interleaved-parityfec":{source:"iana"},"text/cache-manifest":{source:"iana",compressible:!0,extensions:["appcache","manifest"]},"text/calendar":{source:"iana",extensions:["ics","ifb"]},"text/calender":{compressible:!0},"text/cmd":{compressible:!0},"text/coffeescript":{extensions:["coffee","litcoffee"]},"text/cql":{source:"iana"},"text/cql-expression":{source:"iana"},"text/cql-identifier":{source:"iana"},"text/css":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["css"]},"text/csv":{source:"iana",compressible:!0,extensions:["csv"]},"text/csv-schema":{source:"iana"},"text/directory":{source:"iana"},"text/dns":{source:"iana"},"text/ecmascript":{source:"iana"},"text/encaprtp":{source:"iana"},"text/enriched":{source:"iana"},"text/fhirpath":{source:"iana"},"text/flexfec":{source:"iana"},"text/fwdred":{source:"iana"},"text/gff3":{source:"iana"},"text/grammar-ref-list":{source:"iana"},"text/html":{source:"iana",compressible:!0,extensions:["html","htm","shtml"]},"text/jade":{extensions:["jade"]},"text/javascript":{source:"iana",compressible:!0},"text/jcr-cnd":{source:"iana"},"text/jsx":{compressible:!0,extensions:["jsx"]},"text/less":{compressible:!0,extensions:["less"]},"text/markdown":{source:"iana",compressible:!0,extensions:["markdown","md"]},"text/mathml":{source:"nginx",extensions:["mml"]},"text/mdx":{compressible:!0,extensions:["mdx"]},"text/mizar":{source:"iana"},"text/n3":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["n3"]},"text/parameters":{source:"iana",charset:"UTF-8"},"text/parityfec":{source:"iana"},"text/plain":{source:"iana",compressible:!0,extensions:["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{source:"iana",charset:"UTF-8"},"text/prs.fallenstein.rst":{source:"iana"},"text/prs.lines.tag":{source:"iana",extensions:["dsc"]},"text/prs.prop.logic":{source:"iana"},"text/raptorfec":{source:"iana"},"text/red":{source:"iana"},"text/rfc822-headers":{source:"iana"},"text/richtext":{source:"iana",compressible:!0,extensions:["rtx"]},"text/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"text/rtp-enc-aescm128":{source:"iana"},"text/rtploopback":{source:"iana"},"text/rtx":{source:"iana"},"text/sgml":{source:"iana",extensions:["sgml","sgm"]},"text/shaclc":{source:"iana"},"text/shex":{source:"iana",extensions:["shex"]},"text/slim":{extensions:["slim","slm"]},"text/spdx":{source:"iana",extensions:["spdx"]},"text/strings":{source:"iana"},"text/stylus":{extensions:["stylus","styl"]},"text/t140":{source:"iana"},"text/tab-separated-values":{source:"iana",compressible:!0,extensions:["tsv"]},"text/troff":{source:"iana",extensions:["t","tr","roff","man","me","ms"]},"text/turtle":{source:"iana",charset:"UTF-8",extensions:["ttl"]},"text/ulpfec":{source:"iana"},"text/uri-list":{source:"iana",compressible:!0,extensions:["uri","uris","urls"]},"text/vcard":{source:"iana",compressible:!0,extensions:["vcard"]},"text/vnd.a":{source:"iana"},"text/vnd.abc":{source:"iana"},"text/vnd.ascii-art":{source:"iana"},"text/vnd.curl":{source:"iana",extensions:["curl"]},"text/vnd.curl.dcurl":{source:"apache",extensions:["dcurl"]},"text/vnd.curl.mcurl":{source:"apache",extensions:["mcurl"]},"text/vnd.curl.scurl":{source:"apache",extensions:["scurl"]},"text/vnd.debian.copyright":{source:"iana",charset:"UTF-8"},"text/vnd.dmclientscript":{source:"iana"},"text/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"text/vnd.esmertec.theme-descriptor":{source:"iana",charset:"UTF-8"},"text/vnd.familysearch.gedcom":{source:"iana",extensions:["ged"]},"text/vnd.ficlab.flt":{source:"iana"},"text/vnd.fly":{source:"iana",extensions:["fly"]},"text/vnd.fmi.flexstor":{source:"iana",extensions:["flx"]},"text/vnd.gml":{source:"iana"},"text/vnd.graphviz":{source:"iana",extensions:["gv"]},"text/vnd.hans":{source:"iana"},"text/vnd.hgl":{source:"iana"},"text/vnd.in3d.3dml":{source:"iana",extensions:["3dml"]},"text/vnd.in3d.spot":{source:"iana",extensions:["spot"]},"text/vnd.iptc.newsml":{source:"iana"},"text/vnd.iptc.nitf":{source:"iana"},"text/vnd.latex-z":{source:"iana"},"text/vnd.motorola.reflex":{source:"iana"},"text/vnd.ms-mediapackage":{source:"iana"},"text/vnd.net2phone.commcenter.command":{source:"iana"},"text/vnd.radisys.msml-basic-layout":{source:"iana"},"text/vnd.senx.warpscript":{source:"iana"},"text/vnd.si.uricatalogue":{source:"iana"},"text/vnd.sosi":{source:"iana"},"text/vnd.sun.j2me.app-descriptor":{source:"iana",charset:"UTF-8",extensions:["jad"]},"text/vnd.trolltech.linguist":{source:"iana",charset:"UTF-8"},"text/vnd.wap.si":{source:"iana"},"text/vnd.wap.sl":{source:"iana"},"text/vnd.wap.wml":{source:"iana",extensions:["wml"]},"text/vnd.wap.wmlscript":{source:"iana",extensions:["wmls"]},"text/vtt":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["vtt"]},"text/x-asm":{source:"apache",extensions:["s","asm"]},"text/x-c":{source:"apache",extensions:["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{source:"nginx",extensions:["htc"]},"text/x-fortran":{source:"apache",extensions:["f","for","f77","f90"]},"text/x-gwt-rpc":{compressible:!0},"text/x-handlebars-template":{extensions:["hbs"]},"text/x-java-source":{source:"apache",extensions:["java"]},"text/x-jquery-tmpl":{compressible:!0},"text/x-lua":{extensions:["lua"]},"text/x-markdown":{compressible:!0,extensions:["mkd"]},"text/x-nfo":{source:"apache",extensions:["nfo"]},"text/x-opml":{source:"apache",extensions:["opml"]},"text/x-org":{compressible:!0,extensions:["org"]},"text/x-pascal":{source:"apache",extensions:["p","pas"]},"text/x-processing":{compressible:!0,extensions:["pde"]},"text/x-sass":{extensions:["sass"]},"text/x-scss":{extensions:["scss"]},"text/x-setext":{source:"apache",extensions:["etx"]},"text/x-sfv":{source:"apache",extensions:["sfv"]},"text/x-suse-ymp":{compressible:!0,extensions:["ymp"]},"text/x-uuencode":{source:"apache",extensions:["uu"]},"text/x-vcalendar":{source:"apache",extensions:["vcs"]},"text/x-vcard":{source:"apache",extensions:["vcf"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/xml-external-parsed-entity":{source:"iana"},"text/yaml":{compressible:!0,extensions:["yaml","yml"]},"video/1d-interleaved-parityfec":{source:"iana"},"video/3gpp":{source:"iana",extensions:["3gp","3gpp"]},"video/3gpp-tt":{source:"iana"},"video/3gpp2":{source:"iana",extensions:["3g2"]},"video/av1":{source:"iana"},"video/bmpeg":{source:"iana"},"video/bt656":{source:"iana"},"video/celb":{source:"iana"},"video/dv":{source:"iana"},"video/encaprtp":{source:"iana"},"video/ffv1":{source:"iana"},"video/flexfec":{source:"iana"},"video/h261":{source:"iana",extensions:["h261"]},"video/h263":{source:"iana",extensions:["h263"]},"video/h263-1998":{source:"iana"},"video/h263-2000":{source:"iana"},"video/h264":{source:"iana",extensions:["h264"]},"video/h264-rcdo":{source:"iana"},"video/h264-svc":{source:"iana"},"video/h265":{source:"iana"},"video/iso.segment":{source:"iana",extensions:["m4s"]},"video/jpeg":{source:"iana",extensions:["jpgv"]},"video/jpeg2000":{source:"iana"},"video/jpm":{source:"apache",extensions:["jpm","jpgm"]},"video/jxsv":{source:"iana"},"video/mj2":{source:"iana",extensions:["mj2","mjp2"]},"video/mp1s":{source:"iana"},"video/mp2p":{source:"iana"},"video/mp2t":{source:"iana",extensions:["ts"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","mp4v","mpg4"]},"video/mp4v-es":{source:"iana"},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{source:"iana"},"video/mpv":{source:"iana"},"video/nv":{source:"iana"},"video/ogg":{source:"iana",compressible:!1,extensions:["ogv"]},"video/parityfec":{source:"iana"},"video/pointer":{source:"iana"},"video/quicktime":{source:"iana",compressible:!1,extensions:["qt","mov"]},"video/raptorfec":{source:"iana"},"video/raw":{source:"iana"},"video/rtp-enc-aescm128":{source:"iana"},"video/rtploopback":{source:"iana"},"video/rtx":{source:"iana"},"video/scip":{source:"iana"},"video/smpte291":{source:"iana"},"video/smpte292m":{source:"iana"},"video/ulpfec":{source:"iana"},"video/vc1":{source:"iana"},"video/vc2":{source:"iana"},"video/vnd.cctv":{source:"iana"},"video/vnd.dece.hd":{source:"iana",extensions:["uvh","uvvh"]},"video/vnd.dece.mobile":{source:"iana",extensions:["uvm","uvvm"]},"video/vnd.dece.mp4":{source:"iana"},"video/vnd.dece.pd":{source:"iana",extensions:["uvp","uvvp"]},"video/vnd.dece.sd":{source:"iana",extensions:["uvs","uvvs"]},"video/vnd.dece.video":{source:"iana",extensions:["uvv","uvvv"]},"video/vnd.directv.mpeg":{source:"iana"},"video/vnd.directv.mpeg-tts":{source:"iana"},"video/vnd.dlna.mpeg-tts":{source:"iana"},"video/vnd.dvb.file":{source:"iana",extensions:["dvb"]},"video/vnd.fvt":{source:"iana",extensions:["fvt"]},"video/vnd.hns.video":{source:"iana"},"video/vnd.iptvforum.1dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.1dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.2dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.2dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.ttsavc":{source:"iana"},"video/vnd.iptvforum.ttsmpeg2":{source:"iana"},"video/vnd.motorola.video":{source:"iana"},"video/vnd.motorola.videop":{source:"iana"},"video/vnd.mpegurl":{source:"iana",extensions:["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{source:"iana",extensions:["pyv"]},"video/vnd.nokia.interleaved-multimedia":{source:"iana"},"video/vnd.nokia.mp4vr":{source:"iana"},"video/vnd.nokia.videovoip":{source:"iana"},"video/vnd.objectvideo":{source:"iana"},"video/vnd.radgamettools.bink":{source:"iana"},"video/vnd.radgamettools.smacker":{source:"iana"},"video/vnd.sealed.mpeg1":{source:"iana"},"video/vnd.sealed.mpeg4":{source:"iana"},"video/vnd.sealed.swf":{source:"iana"},"video/vnd.sealedmedia.softseal.mov":{source:"iana"},"video/vnd.uvvu.mp4":{source:"iana",extensions:["uvu","uvvu"]},"video/vnd.vivo":{source:"iana",extensions:["viv"]},"video/vnd.youtube.yt":{source:"iana"},"video/vp8":{source:"iana"},"video/vp9":{source:"iana"},"video/webm":{source:"apache",compressible:!1,extensions:["webm"]},"video/x-f4v":{source:"apache",extensions:["f4v"]},"video/x-fli":{source:"apache",extensions:["fli"]},"video/x-flv":{source:"apache",compressible:!1,extensions:["flv"]},"video/x-m4v":{source:"apache",extensions:["m4v"]},"video/x-matroska":{source:"apache",compressible:!1,extensions:["mkv","mk3d","mks"]},"video/x-mng":{source:"apache",extensions:["mng"]},"video/x-ms-asf":{source:"apache",extensions:["asf","asx"]},"video/x-ms-vob":{source:"apache",extensions:["vob"]},"video/x-ms-wm":{source:"apache",extensions:["wm"]},"video/x-ms-wmv":{source:"apache",compressible:!1,extensions:["wmv"]},"video/x-ms-wmx":{source:"apache",extensions:["wmx"]},"video/x-ms-wvx":{source:"apache",extensions:["wvx"]},"video/x-msvideo":{source:"apache",extensions:["avi"]},"video/x-sgi-movie":{source:"apache",extensions:["movie"]},"video/x-smv":{source:"apache",extensions:["smv"]},"x-conference/x-cooltalk":{source:"apache",extensions:["ice"]},"x-shader/x-fragment":{compressible:!0},"x-shader/x-vertex":{compressible:!0}}});var Bf=b(function(hT){/*!
|
|
3
3
|
* mime-types
|
|
4
4
|
* Copyright(c) 2014 Jonathan Ong
|
|
5
5
|
* Copyright(c) 2015 Douglas Christopher Wilson
|
|
6
6
|
* MIT Licensed
|
|
7
|
-
*/var $s=Wf(),EE=ge("path").extname,Kf=/^\s*([^;\s]*)(?:;|\s|$)/,RE=/^text\//i;CE.charset=Yf;CE.charsets={lookup:Yf};CE.contentType=PE;CE.extension=zE;CE.extensions=Object.create(null);CE.lookup=OE;CE.types=Object.create(null);AE(CE.extensions,CE.types);function Yf(e){if(!e||typeof e!=="string")return!1;var t=Kf.exec(e),r=t&&$s[t[1].toLowerCase()];if(r&&r.charset)return r.charset;if(t&&RE.test(t[1]))return"UTF-8";return!1}function PE(e){if(!e||typeof e!=="string")return!1;var t=e.indexOf("/")===-1?CE.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var r=CE.charset(t);if(r)t+="; charset="+r.toLowerCase()}return t}function zE(e){if(!e||typeof e!=="string")return!1;var t=Kf.exec(e),r=t&&CE.extensions[t[1].toLowerCase()];if(!r||!r.length)return!1;return r[0]}function OE(e){if(!e||typeof e!=="string")return!1;var t=EE("x."+e).toLowerCase().substr(1);if(!t)return!1;return CE.types[t]||!1}function AE(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys($s).forEach(function(o){var i=$s[o],s=i.extensions;if(!s||!s.length)return;e[o]=s;for(var a=0;a<s.length;a++){var c=s[a];if(t[c]){var u=r.indexOf($s[t[c]].source),l=r.indexOf(i.source);if(t[c]!=="application/octet-stream"&&(u>l||u===l&&t[c].substr(0,12)==="application/"))continue}t[c]=o}})}});var rh=_(function(r9,th){th.exports=DE;function DE(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t)t(e);else setTimeout(e,0)}});var Kc=_(function(n9,oh){var nh=rh();oh.exports=LE;function LE(e){var t=!1;return nh(function(){t=!0}),function(n,o){if(t)e(n,o);else nh(function(){e(n,o)})}}});var Yc=_(function(o9,ih){ih.exports=ME;function ME(e){Object.keys(e.jobs).forEach(qE.bind(e)),e.jobs={}}function qE(e){if(typeof this.jobs[e]=="function")this.jobs[e]()}});var Xc=_(function(i9,ah){var sh=Kc(),UE=Yc();ah.exports=FE;function FE(e,t,r,n){var o=r.keyedList?r.keyedList[r.index]:r.index;r.jobs[o]=ZE(t,o,e[o],function(i,s){if(!(o in r.jobs))return;if(delete r.jobs[o],i)UE(r);else r.results[o]=s;n(i,r.results)})}function ZE(e,t,r,n){var o;if(e.length==2)o=e(r,sh(n));else o=e(r,t,sh(n));return o}});var Qc=_(function(s9,ch){ch.exports=BE;function BE(e,t){var r=!Array.isArray(e),n={index:0,keyedList:r||t?Object.keys(e):null,jobs:{},results:r?{}:[],size:r?Object.keys(e).length:e.length};if(t)n.keyedList.sort(r?t:function(o,i){return t(e[o],e[i])});return n}});var eu=_(function(a9,uh){var HE=Yc(),VE=Kc();uh.exports=GE;function GE(e){if(!Object.keys(this.jobs).length)return;this.index=this.size,HE(this),VE(e)(null,this.results)}});var ph=_(function(c9,lh){var JE=Xc(),WE=Qc(),KE=eu();lh.exports=YE;function YE(e,t,r){var n=WE(e);while(n.index<(n.keyedList||e).length)JE(e,t,n,function(o,i){if(o){r(o,i);return}if(Object.keys(n.jobs).length===0){r(null,n.results);return}}),n.index++;return KE.bind(n,r)}});var tu=_(function(u9,Ts){var dh=Xc(),XE=Qc(),QE=eu();Ts.exports=eR;Ts.exports.ascending=mh;Ts.exports.descending=tR;function eR(e,t,r,n){var o=XE(e,r);return dh(e,t,o,function i(s,a){if(s){n(s,a);return}if(o.index++,o.index<(o.keyedList||e).length){dh(e,t,o,i);return}n(null,o.results)}),QE.bind(o,n)}function mh(e,t){return e<t?-1:e>t?1:0}function tR(e,t){return-1*mh(e,t)}});var hh=_(function(l9,fh){var rR=tu();fh.exports=nR;function nR(e,t,r){return rR(e,t,null,r)}});var xh=_(function(p9,gh){gh.exports={parallel:ph(),serial:hh(),serialOrdered:tu()}});var ru=_(function(d9,vh){vh.exports=Object});var bh=_(function(m9,yh){yh.exports=Error});var wh=_(function(f9,_h){_h.exports=EvalError});var Sh=_(function(h9,kh){kh.exports=RangeError});var Th=_(function(g9,$h){$h.exports=ReferenceError});var Rh=_(function(x9,Eh){Eh.exports=SyntaxError});var Es=_(function(v9,Ph){Ph.exports=TypeError});var Oh=_(function(y9,zh){zh.exports=URIError});var Ch=_(function(b9,Ah){Ah.exports=Math.abs});var jh=_(function(_9,Ih){Ih.exports=Math.floor});var Dh=_(function(w9,Nh){Nh.exports=Math.max});var Mh=_(function(k9,Lh){Lh.exports=Math.min});var Uh=_(function(S9,qh){qh.exports=Math.pow});var Zh=_(function($9,Fh){Fh.exports=Math.round});var Hh=_(function(T9,Bh){Bh.exports=Number.isNaN||function(t){return t!==t}});var Gh=_(function(E9,Vh){var oR=Hh();Vh.exports=function(t){if(oR(t)||t===0)return t;return t<0?-1:1}});var Wh=_(function(R9,Jh){Jh.exports=Object.getOwnPropertyDescriptor});var nu=_(function(P9,Kh){var Rs=Wh();if(Rs)try{Rs([],"length")}catch(e){Rs=null}Kh.exports=Rs});var Xh=_(function(z9,Yh){var Ps=Object.defineProperty||!1;if(Ps)try{Ps({},"a",{value:1})}catch(e){Ps=!1}Yh.exports=Ps});var ou=_(function(O9,Qh){Qh.exports=function(){if(typeof Symbol!=="function"||typeof Object.getOwnPropertySymbols!=="function")return!1;if(typeof Symbol.iterator==="symbol")return!0;var t={},r=Symbol("test"),n=Object(r);if(typeof r==="string")return!1;if(Object.prototype.toString.call(r)!=="[object Symbol]")return!1;if(Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;t[r]=o;for(var i in t)return!1;if(typeof Object.keys==="function"&&Object.keys(t).length!==0)return!1;if(typeof Object.getOwnPropertyNames==="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var s=Object.getOwnPropertySymbols(t);if(s.length!==1||s[0]!==r)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor==="function"){var a=Object.getOwnPropertyDescriptor(t,r);if(a.value!==o||a.enumerable!==!0)return!1}return!0}});var rg=_(function(A9,tg){var eg=typeof Symbol<"u"&&Symbol,iR=ou();tg.exports=function(){if(typeof eg!=="function")return!1;if(typeof Symbol!=="function")return!1;if(typeof eg("foo")!=="symbol")return!1;if(typeof Symbol("bar")!=="symbol")return!1;return iR()}});var iu=_(function(C9,ng){ng.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var su=_(function(I9,og){var sR=ru();og.exports=sR.getPrototypeOf||null});var ag=_(function(j9,sg){var aR="Function.prototype.bind called on incompatible ",cR=Object.prototype.toString,uR=Math.max,lR="[object Function]",ig=function(t,r){var n=[];for(var o=0;o<t.length;o+=1)n[o]=t[o];for(var i=0;i<r.length;i+=1)n[i+t.length]=r[i];return n},pR=function(t,r){var n=[];for(var o=r||0,i=0;o<t.length;o+=1,i+=1)n[i]=t[o];return n},dR=function(e,t){var r="";for(var n=0;n<e.length;n+=1)if(r+=e[n],n+1<e.length)r+=t;return r};sg.exports=function(t){var r=this;if(typeof r!=="function"||cR.apply(r)!==lR)throw TypeError(aR+r);var n=pR(arguments,1),o,i=function(){if(this instanceof o){var l=r.apply(this,ig(n,arguments));if(Object(l)===l)return l;return this}return r.apply(t,ig(n,arguments))},s=uR(0,r.length-n.length),a=[];for(var c=0;c<s;c++)a[c]="$"+c;if(o=Function("binder","return function ("+dR(a,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var u=function(){};u.prototype=r.prototype,o.prototype=new u,u.prototype=null}return o}});var Zo=_(function(N9,cg){var mR=ag();cg.exports=Function.prototype.bind||mR});var zs=_(function(D9,ug){ug.exports=Function.prototype.call});var au=_(function(L9,lg){lg.exports=Function.prototype.apply});var dg=_(function(M9,pg){pg.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var fg=_(function(q9,mg){var fR=Zo(),hR=au(),gR=zs(),xR=dg();mg.exports=xR||fR.call(gR,hR)});var gg=_(function(U9,hg){var vR=Zo(),yR=Es(),bR=zs(),_R=fg();hg.exports=function(t){if(t.length<1||typeof t[0]!=="function")throw new yR("a function is required");return _R(vR,bR,t)}});var wg=_(function(F9,_g){var wR=gg(),xg=nu(),yg;try{yg=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!=="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var cu=!!yg&&xg&&xg(Object.prototype,"__proto__"),bg=Object,vg=bg.getPrototypeOf;_g.exports=cu&&typeof cu.get==="function"?wR([cu.get]):typeof vg==="function"?function(t){return vg(t==null?t:bg(t))}:!1});var Eg=_(function(Z9,Tg){var kg=iu(),Sg=su(),$g=wg();Tg.exports=kg?function(t){return kg(t)}:Sg?function(t){if(!t||typeof t!=="object"&&typeof t!=="function")throw TypeError("getProto: not an object");return Sg(t)}:$g?function(t){return $g(t)}:null});var Os=_(function(B9,Rg){var kR=Function.prototype.call,SR=Object.prototype.hasOwnProperty,$R=Zo();Rg.exports=$R.call(kR,SR)});var Ig=_(function(H9,Cg){var Q,TR=ru(),ER=bh(),RR=wh(),PR=Sh(),zR=Th(),Ln=Rh(),Dn=Es(),OR=Oh(),AR=Ch(),CR=jh(),IR=Dh(),jR=Mh(),NR=Uh(),DR=Zh(),LR=Gh(),Og=Function,uu=function(e){try{return Og('"use strict"; return ('+e+").constructor;")()}catch(t){}},Bo=nu(),MR=Xh(),lu=function(){throw new Dn},qR=Bo?function(){try{return arguments.callee,lu}catch(e){try{return Bo(arguments,"callee").get}catch(t){return lu}}}():lu,jn=rg()(),He=Eg(),UR=su(),FR=iu(),Ag=au(),Ho=zs(),Nn={},ZR=typeof Uint8Array>"u"||!He?Q:He(Uint8Array),en={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?Q:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Q:ArrayBuffer,"%ArrayIteratorPrototype%":jn&&He?He([][Symbol.iterator]()):Q,"%AsyncFromSyncIteratorPrototype%":Q,"%AsyncFunction%":Nn,"%AsyncGenerator%":Nn,"%AsyncGeneratorFunction%":Nn,"%AsyncIteratorPrototype%":Nn,"%Atomics%":typeof Atomics>"u"?Q:Atomics,"%BigInt%":typeof BigInt>"u"?Q:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?Q:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?Q:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Q:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":ER,"%eval%":eval,"%EvalError%":RR,"%Float16Array%":typeof Float16Array>"u"?Q:Float16Array,"%Float32Array%":typeof Float32Array>"u"?Q:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Q:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Q:FinalizationRegistry,"%Function%":Og,"%GeneratorFunction%":Nn,"%Int8Array%":typeof Int8Array>"u"?Q:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Q:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Q:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":jn&&He?He(He([][Symbol.iterator]())):Q,"%JSON%":typeof JSON==="object"?JSON:Q,"%Map%":typeof Map>"u"?Q:Map,"%MapIteratorPrototype%":typeof Map>"u"||!jn||!He?Q:He(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":TR,"%Object.getOwnPropertyDescriptor%":Bo,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Q:Promise,"%Proxy%":typeof Proxy>"u"?Q:Proxy,"%RangeError%":PR,"%ReferenceError%":zR,"%Reflect%":typeof Reflect>"u"?Q:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Q:Set,"%SetIteratorPrototype%":typeof Set>"u"||!jn||!He?Q:He(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Q:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":jn&&He?He(""[Symbol.iterator]()):Q,"%Symbol%":jn?Symbol:Q,"%SyntaxError%":Ln,"%ThrowTypeError%":qR,"%TypedArray%":ZR,"%TypeError%":Dn,"%Uint8Array%":typeof Uint8Array>"u"?Q:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Q:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Q:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Q:Uint32Array,"%URIError%":OR,"%WeakMap%":typeof WeakMap>"u"?Q:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Q:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Q:WeakSet,"%Function.prototype.call%":Ho,"%Function.prototype.apply%":Ag,"%Object.defineProperty%":MR,"%Object.getPrototypeOf%":UR,"%Math.abs%":AR,"%Math.floor%":CR,"%Math.max%":IR,"%Math.min%":jR,"%Math.pow%":NR,"%Math.round%":DR,"%Math.sign%":LR,"%Reflect.getPrototypeOf%":FR};if(He)try{null.error}catch(e){pu=He(He(e)),en["%Error.prototype%"]=pu}var pu,BR=function e(t){var r;if(t==="%AsyncFunction%")r=uu("async function () {}");else if(t==="%GeneratorFunction%")r=uu("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=uu("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");if(n)r=n.prototype}else if(t==="%AsyncIteratorPrototype%"){var o=e("%AsyncGenerator%");if(o&&He)r=He(o.prototype)}return en[t]=r,r},Pg={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Vo=Zo(),As=Os(),HR=Vo.call(Ho,Array.prototype.concat),VR=Vo.call(Ag,Array.prototype.splice),zg=Vo.call(Ho,String.prototype.replace),Cs=Vo.call(Ho,String.prototype.slice),GR=Vo.call(Ho,RegExp.prototype.exec),JR=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,WR=/\\(\\)?/g,KR=function(t){var r=Cs(t,0,1),n=Cs(t,-1);if(r==="%"&&n!=="%")throw new Ln("invalid intrinsic syntax, expected closing `%`");else if(n==="%"&&r!=="%")throw new Ln("invalid intrinsic syntax, expected opening `%`");var o=[];return zg(t,JR,function(i,s,a,c){o[o.length]=a?zg(c,WR,"$1"):s||i}),o},YR=function(t,r){var n=t,o;if(As(Pg,n))o=Pg[n],n="%"+o[0]+"%";if(As(en,n)){var i=en[n];if(i===Nn)i=BR(n);if(typeof i>"u"&&!r)throw new Dn("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new Ln("intrinsic "+t+" does not exist!")};Cg.exports=function(t,r){if(typeof t!=="string"||t.length===0)throw new Dn("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!=="boolean")throw new Dn('"allowMissing" argument must be a boolean');if(GR(/^%?[^%]*%?$/,t)===null)throw new Ln("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=KR(t),o=n.length>0?n[0]:"",i=YR("%"+o+"%",r),s=i.name,a=i.value,c=!1,u=i.alias;if(u)o=u[0],VR(n,HR([0,1],u));for(var l=1,p=!0;l<n.length;l+=1){var m=n[l],d=Cs(m,0,1),h=Cs(m,-1);if((d==='"'||d==="'"||d==="`"||(h==='"'||h==="'"||h==="`"))&&d!==h)throw new Ln("property names with quotes must have matching quotes");if(m==="constructor"||!p)c=!0;if(o+="."+m,s="%"+o+"%",As(en,s))a=en[s];else if(a!=null){if(!(m in a)){if(!r)throw new Dn("base intrinsic for "+t+" exists, but the property is not available.");return}if(Bo&&l+1>=n.length){var x=Bo(a,m);if(p=!!x,p&&"get"in x&&!("originalValue"in x.get))a=x.get;else a=a[m]}else p=As(a,m),a=a[m];if(p&&!c)en[s]=a}}return a}});var Ng=_(function(V9,jg){var XR=ou();jg.exports=function(){return XR()&&!!Symbol.toStringTag}});var Mg=_(function(G9,Lg){var QR=Ig(),Dg=QR("%Object.defineProperty%",!0),eP=Ng()(),tP=Os(),rP=Es(),Is=eP?Symbol.toStringTag:null;Lg.exports=function(t,r){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,o=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!=="boolean"||typeof o<"u"&&typeof o!=="boolean")throw new rP("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");if(Is&&(n||!tP(t,Is)))if(Dg)Dg(t,Is,{configurable:!o,enumerable:!1,value:r,writable:!1});else t[Is]=r}});var Ug=_(function(J9,qg){qg.exports=function(e,t){return Object.keys(t).forEach(function(r){e[r]=e[r]||t[r]}),e}});var Bg=_(function(W9,Zg){var hu=Jf(),nP=ge("util"),du=ge("path"),oP=ge("http"),iP=ge("https"),sP=ge("url").parse,aP=ge("fs"),cP=ge("stream").Stream,uP=ge("crypto"),mu=eh(),lP=xh(),pP=Mg(),kr=Os(),fu=Ug();function Fg(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}function se(e){if(!(this instanceof se))return new se(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],hu.call(this),e=e||{};for(var t in e)this[t]=e[t]}nP.inherits(se,hu);se.LINE_BREAK=`\r
|
|
8
|
-
`;se.DEFAULT_CONTENT_TYPE="application/octet-stream";se.prototype.append=function(e,t,r){if(r=r||{},typeof r==="string")r={filename:r};var n=hu.prototype.append.bind(this);if(typeof t==="number"||t==null)t=String(t);if(Array.isArray(t)){this._error(Error("Arrays are not supported."));return}var o=this._multiPartHeader(e,t,r),i=this._multiPartFooter();n(o),n(t),n(i),this._trackLength(o,t,r)};se.prototype._trackLength=function(e,t,r){var n=0;if(r.knownLength!=null)n+=Number(r.knownLength);else if(Buffer.isBuffer(t))n=t.length;else if(typeof t==="string")n=Buffer.byteLength(t);if(this._valueLength+=n,this._overheadLength+=Buffer.byteLength(e)+se.LINE_BREAK.length,!t||!t.path&&!(t.readable&&kr(t,"httpVersion"))&&!(t instanceof cP))return;if(!r.knownLength)this._valuesToMeasure.push(t)};se.prototype._lengthRetriever=function(e,t){if(kr(e,"fd"))if(e.end!=null&&e.end!=1/0&&e.start!=null)t(null,e.end+1-(e.start?e.start:0));else aP.stat(e.path,function(r,n){if(r){t(r);return}var o=n.size-(e.start?e.start:0);t(null,o)});else if(kr(e,"httpVersion"))t(null,Number(e.headers["content-length"]));else if(kr(e,"httpModule"))e.on("response",function(r){e.pause(),t(null,Number(r.headers["content-length"]))}),e.resume();else t("Unknown stream")};se.prototype._multiPartHeader=function(e,t,r){if(typeof r.header==="string")return r.header;var n=this._getContentDisposition(t,r),o=this._getContentType(t,r),i="",s={"Content-Disposition":["form-data",'name="'+Fg(e)+'"'].concat(n||[]),"Content-Type":[].concat(o||[])};if(typeof r.header==="object")fu(s,r.header);var a;for(var c in s)if(kr(s,c)){if(a=s[c],a==null)continue;if(!Array.isArray(a))a=[a];if(a.length)i+=c+": "+a.join("; ")+se.LINE_BREAK}return"--"+this.getBoundary()+se.LINE_BREAK+i+se.LINE_BREAK};se.prototype._getContentDisposition=function(e,t){var r;if(typeof t.filepath==="string")r=du.normalize(t.filepath).replace(/\\/g,"/");else if(t.filename||e&&(e.name||e.path))r=du.basename(t.filename||e&&(e.name||e.path));else if(e&&e.readable&&kr(e,"httpVersion"))r=du.basename(e.client._httpMessage.path||"");if(r)return'filename="'+Fg(r)+'"'};se.prototype._getContentType=function(e,t){var r=t.contentType;if(!r&&e&&e.name)r=mu.lookup(e.name);if(!r&&e&&e.path)r=mu.lookup(e.path);if(!r&&e&&e.readable&&kr(e,"httpVersion"))r=e.headers["content-type"];if(!r&&(t.filepath||t.filename))r=mu.lookup(t.filepath||t.filename);if(!r&&e&&typeof e==="object")r=se.DEFAULT_CONTENT_TYPE;return r};se.prototype._multiPartFooter=function(){return function(e){var t=se.LINE_BREAK,r=this._streams.length===0;if(r)t+=this._lastBoundary();e(t)}.bind(this)};se.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+se.LINE_BREAK};se.prototype.getHeaders=function(e){var t,r={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)if(kr(e,t))r[t.toLowerCase()]=e[t];return r};se.prototype.setBoundary=function(e){if(typeof e!=="string")throw TypeError("FormData boundary must be a string");this._boundary=e};se.prototype.getBoundary=function(){if(!this._boundary)this._generateBoundary();return this._boundary};se.prototype.getBuffer=function(){var e=new Buffer.alloc(0),t=this.getBoundary();for(var r=0,n=this._streams.length;r<n;r++)if(typeof this._streams[r]!=="function"){if(Buffer.isBuffer(this._streams[r]))e=Buffer.concat([e,this._streams[r]]);else e=Buffer.concat([e,Buffer.from(this._streams[r])]);if(typeof this._streams[r]!=="string"||this._streams[r].substring(2,t.length+2)!==t)e=Buffer.concat([e,Buffer.from(se.LINE_BREAK)])}return Buffer.concat([e,Buffer.from(this._lastBoundary())])};se.prototype._generateBoundary=function(){this._boundary="--------------------------"+uP.randomBytes(12).toString("hex")};se.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;if(this._streams.length)e+=this._lastBoundary().length;if(!this.hasKnownLength())this._error(Error("Cannot calculate proper length in synchronous way."));return e};se.prototype.hasKnownLength=function(){var e=!0;if(this._valuesToMeasure.length)e=!1;return e};se.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;if(this._streams.length)t+=this._lastBoundary().length;if(!this._valuesToMeasure.length){process.nextTick(e.bind(this,null,t));return}lP.parallel(this._valuesToMeasure,this._lengthRetriever,function(r,n){if(r){e(r);return}n.forEach(function(o){t+=o}),e(null,t)})};se.prototype.submit=function(e,t){var r,n,o={method:"post"};if(typeof e==="string")e=sP(e),n=fu({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},o);else if(n=fu(e,o),!n.port)n.port=n.protocol==="https:"?443:80;if(n.headers=this.getHeaders(e.headers),n.protocol==="https:")r=iP.request(n);else r=oP.request(n);return this.getLength(function(i,s){if(i&&i!=="Unknown stream"){this._error(i);return}if(s)r.setHeader("Content-Length",s);if(this.pipe(r),t){var a,c=function(u,l){return r.removeListener("error",c),r.removeListener("response",a),t.call(this,u,l)};a=c.bind(this,null),r.on("error",c),r.on("response",a)}}.bind(this)),r};se.prototype._error=function(e){if(!this.error)this.error=e,this.pause(),this.emit("error",e)};se.prototype.toString=function(){return"[object FormData]"};pP(se.prototype,"FormData");Zg.exports=se});var cx=_(function(W3,ax){var Un=1000,Fn=Un*60,Zn=Fn*60,nn=Zn*24,CP=nn*7,IP=nn*365.25;ax.exports=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return jP(e);else if(r==="number"&&isFinite(e))return t.long?DP(e):NP(e);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function jP(e){if(e=String(e),e.length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*IP;case"weeks":case"week":case"w":return r*CP;case"days":case"day":case"d":return r*nn;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Zn;case"minutes":case"minute":case"mins":case"min":case"m":return r*Fn;case"seconds":case"second":case"secs":case"sec":case"s":return r*Un;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}function NP(e){var t=Math.abs(e);if(t>=nn)return Math.round(e/nn)+"d";if(t>=Zn)return Math.round(e/Zn)+"h";if(t>=Fn)return Math.round(e/Fn)+"m";if(t>=Un)return Math.round(e/Un)+"s";return e+"ms"}function DP(e){var t=Math.abs(e);if(t>=nn)return Ds(e,t,nn,"day");if(t>=Zn)return Ds(e,t,Zn,"hour");if(t>=Fn)return Ds(e,t,Fn,"minute");if(t>=Un)return Ds(e,t,Un,"second");return e+" ms"}function Ds(e,t,r,n){var o=t>=r*1.5;return Math.round(e/r)+" "+n+(o?"s":"")}});var Pu=_(function(K3,ux){function LP(e){r.debug=r,r.default=r,r.coerce=c,r.disable=s,r.enable=o,r.enabled=a,r.humanize=cx(),r.destroy=u,Object.keys(e).forEach((l)=>{r[l]=e[l]}),r.names=[],r.skips=[],r.formatters={};function t(l){let p=0;for(let m=0;m<l.length;m++)p=(p<<5)-p+l.charCodeAt(m),p|=0;return r.colors[Math.abs(p)%r.colors.length]}r.selectColor=t;function r(l){let p,m=null,d,h;function x(...y){if(!x.enabled)return;let g=x,b=Number(new Date),k=b-(p||b);if(g.diff=k,g.prev=p,g.curr=b,p=b,y[0]=r.coerce(y[0]),typeof y[0]!=="string")y.unshift("%O");let z=0;y[0]=y[0].replace(/%([a-zA-Z%])/g,(H,me)=>{if(H==="%%")return"%";z++;let K=r.formatters[me];if(typeof K==="function"){let lt=y[z];H=K.call(g,lt),y.splice(z,1),z--}return H}),r.formatArgs.call(g,y),(g.log||r.log).apply(g,y)}if(x.namespace=l,x.useColors=r.useColors(),x.color=r.selectColor(l),x.extend=n,x.destroy=r.destroy,Object.defineProperty(x,"enabled",{enumerable:!0,configurable:!1,get:()=>{if(m!==null)return m;if(d!==r.namespaces)d=r.namespaces,h=r.enabled(l);return h},set:(y)=>{m=y}}),typeof r.init==="function")r.init(x);return x}function n(l,p){let m=r(this.namespace+(typeof p>"u"?":":p)+l);return m.log=this.log,m}function o(l){r.save(l),r.namespaces=l,r.names=[],r.skips=[];let p=(typeof l==="string"?l:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let m of p)if(m[0]==="-")r.skips.push(m.slice(1));else r.names.push(m)}function i(l,p){let m=0,d=0,h=-1,x=0;while(m<l.length)if(d<p.length&&(p[d]===l[m]||p[d]==="*"))if(p[d]==="*")h=d,x=m,d++;else m++,d++;else if(h!==-1)d=h+1,x++,m=x;else return!1;while(d<p.length&&p[d]==="*")d++;return d===p.length}function s(){let l=[...r.names,...r.skips.map((p)=>"-"+p)].join(",");return r.enable(""),l}function a(l){for(let p of r.skips)if(i(l,p))return!1;for(let p of r.names)if(i(l,p))return!0;return!1}function c(l){if(l instanceof Error)return l.stack||l.message;return l}function u(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}ux.exports=LP});var px=_(function(lx,Ls){lx.formatArgs=qP;lx.save=UP;lx.load=FP;lx.useColors=MP;lx.storage=ZP();lx.destroy=(()=>{let e=!1;return()=>{if(!e)e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}})();lx.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function MP(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function qP(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+Ls.exports.humanize(this.diff),!this.useColors)return;let t="color: "+this.color;e.splice(1,0,t,"color: inherit");let r=0,n=0;e[0].replace(/%[a-zA-Z%]/g,(o)=>{if(o==="%%")return;if(r++,o==="%c")n=r}),e.splice(n,0,t)}lx.log=console.debug||console.log||(()=>{});function UP(e){try{if(e)lx.storage.setItem("debug",e);else lx.storage.removeItem("debug")}catch(t){}}function FP(){let e;try{e=lx.storage.getItem("debug")||lx.storage.getItem("DEBUG")}catch(t){}if(!e&&typeof process<"u"&&"env"in process)e=process.env.DEBUG;return e}function ZP(){try{return localStorage}catch(e){}}Ls.exports=Pu()(lx);var{formatters:BP}=Ls.exports;BP.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}});var mx=_(function(X3,dx){dx.exports=(e,t=process.argv)=>{let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),o=t.indexOf("--");return n!==-1&&(o===-1||n<o)}});var gx=_(function(Q3,hx){var XP=ge("os"),fx=ge("tty"),zt=mx(),{env:Ve}=process,Tr;if(zt("no-color")||zt("no-colors")||zt("color=false")||zt("color=never"))Tr=0;else if(zt("color")||zt("colors")||zt("color=true")||zt("color=always"))Tr=1;if("FORCE_COLOR"in Ve)if(Ve.FORCE_COLOR==="true")Tr=1;else if(Ve.FORCE_COLOR==="false")Tr=0;else Tr=Ve.FORCE_COLOR.length===0?1:Math.min(parseInt(Ve.FORCE_COLOR,10),3);function zu(e){if(e===0)return!1;return{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Ou(e,t){if(Tr===0)return 0;if(zt("color=16m")||zt("color=full")||zt("color=truecolor"))return 3;if(zt("color=256"))return 2;if(e&&!t&&Tr===void 0)return 0;let r=Tr||0;if(Ve.TERM==="dumb")return r;if(process.platform==="win32"){let n=XP.release().split(".");if(Number(n[0])>=10&&Number(n[2])>=10586)return Number(n[2])>=14931?3:2;return 1}if("CI"in Ve){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((n)=>(n in Ve))||Ve.CI_NAME==="codeship")return 1;return r}if("TEAMCITY_VERSION"in Ve)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Ve.TEAMCITY_VERSION)?1:0;if(Ve.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Ve){let n=parseInt((Ve.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Ve.TERM_PROGRAM){case"iTerm.app":return n>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(Ve.TERM))return 2;if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Ve.TERM))return 1;if("COLORTERM"in Ve)return 1;return r}function QP(e){let t=Ou(e,e&&e.isTTY);return zu(t)}hx.exports={supportsColor:QP,stdout:zu(Ou(!0,fx.isatty(1))),stderr:zu(Ou(!0,fx.isatty(2)))}});var bx=_(function(vx,qs){var ez=ge("tty"),Ms=ge("util");vx.init=az;vx.log=oz;vx.formatArgs=rz;vx.save=iz;vx.load=sz;vx.useColors=tz;vx.destroy=Ms.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");vx.colors=[6,2,3,4,5,1];try{let e=gx();if(e&&(e.stderr||e).level>=2)vx.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}catch(e){}vx.inspectOpts=Object.keys(process.env).filter((e)=>/^debug_/i.test(e)).reduce((e,t)=>{let r=t.substring(6).toLowerCase().replace(/_([a-z])/g,(o,i)=>i.toUpperCase()),n=process.env[t];if(/^(yes|on|true|enabled)$/i.test(n))n=!0;else if(/^(no|off|false|disabled)$/i.test(n))n=!1;else if(n==="null")n=null;else n=Number(n);return e[r]=n,e},{});function tz(){return"colors"in vx.inspectOpts?Boolean(vx.inspectOpts.colors):ez.isatty(process.stderr.fd)}function rz(e){let{namespace:t,useColors:r}=this;if(r){let n=this.color,o="\x1B[3"+(n<8?n:"8;5;"+n),i=` ${o};1m${t} \x1B[0m`;e[0]=i+e[0].split(`
|
|
7
|
+
*/var fs=Lf(),uT=ge("path").extname,qf=/^\s*([^;\s]*)(?:;|\s|$)/,lT=/^text\//i;hT.charset=Uf;hT.charsets={lookup:Uf};hT.contentType=pT;hT.extension=dT;hT.extensions=Object.create(null);hT.lookup=mT;hT.types=Object.create(null);fT(hT.extensions,hT.types);function Uf(e){if(!e||typeof e!=="string")return!1;var t=qf.exec(e),r=t&&fs[t[1].toLowerCase()];if(r&&r.charset)return r.charset;if(t&&lT.test(t[1]))return"UTF-8";return!1}function pT(e){if(!e||typeof e!=="string")return!1;var t=e.indexOf("/")===-1?hT.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var r=hT.charset(t);if(r)t+="; charset="+r.toLowerCase()}return t}function dT(e){if(!e||typeof e!=="string")return!1;var t=qf.exec(e),r=t&&hT.extensions[t[1].toLowerCase()];if(!r||!r.length)return!1;return r[0]}function mT(e){if(!e||typeof e!=="string")return!1;var t=uT("x."+e).toLowerCase().substr(1);if(!t)return!1;return hT.types[t]||!1}function fT(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys(fs).forEach(function(o){var i=fs[o],s=i.extensions;if(!s||!s.length)return;e[o]=s;for(var a=0;a<s.length;a++){var c=s[a];if(t[c]){var u=r.indexOf(fs[t[c]].source),l=r.indexOf(i.source);if(t[c]!=="application/octet-stream"&&(u>l||u===l&&t[c].substr(0,12)==="application/"))continue}t[c]=o}})}});var Vf=b(function(G4,Hf){Hf.exports=yT;function yT(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;if(t)t(e);else setTimeout(e,0)}});var Hc=b(function(J4,Jf){var Gf=Vf();Jf.exports=bT;function bT(e){var t=!1;return Gf(function(){t=!0}),function(n,o){if(t)e(n,o);else Gf(function(){e(n,o)})}}});var Vc=b(function(W4,Wf){Wf.exports=_T;function _T(e){Object.keys(e.jobs).forEach(wT.bind(e)),e.jobs={}}function wT(e){if(typeof this.jobs[e]=="function")this.jobs[e]()}});var Gc=b(function(K4,Yf){var Kf=Hc(),kT=Vc();Yf.exports=ST;function ST(e,t,r,n){var o=r.keyedList?r.keyedList[r.index]:r.index;r.jobs[o]=$T(t,o,e[o],function(i,s){if(!(o in r.jobs))return;if(delete r.jobs[o],i)kT(r);else r.results[o]=s;n(i,r.results)})}function $T(e,t,r,n){var o;if(e.length==2)o=e(r,Kf(n));else o=e(r,t,Kf(n));return o}});var Jc=b(function(Y4,Xf){Xf.exports=TT;function TT(e,t){var r=!Array.isArray(e),n={index:0,keyedList:r||t?Object.keys(e):null,jobs:{},results:r?{}:[],size:r?Object.keys(e).length:e.length};if(t)n.keyedList.sort(r?t:function(o,i){return t(e[o],e[i])});return n}});var Wc=b(function(X4,Qf){var ET=Vc(),RT=Hc();Qf.exports=PT;function PT(e){if(!Object.keys(this.jobs).length)return;this.index=this.size,ET(this),RT(e)(null,this.results)}});var th=b(function(Q4,eh){var zT=Gc(),OT=Jc(),AT=Wc();eh.exports=CT;function CT(e,t,r){var n=OT(e);while(n.index<(n.keyedList||e).length)zT(e,t,n,function(o,i){if(o){r(o,i);return}if(Object.keys(n.jobs).length===0){r(null,n.results);return}}),n.index++;return AT.bind(n,r)}});var Kc=b(function(eZ,hs){var rh=Gc(),IT=Jc(),jT=Wc();hs.exports=NT;hs.exports.ascending=nh;hs.exports.descending=DT;function NT(e,t,r,n){var o=IT(e,r);return rh(e,t,o,function i(s,a){if(s){n(s,a);return}if(o.index++,o.index<(o.keyedList||e).length){rh(e,t,o,i);return}n(null,o.results)}),jT.bind(o,n)}function nh(e,t){return e<t?-1:e>t?1:0}function DT(e,t){return-1*nh(e,t)}});var ih=b(function(tZ,oh){var MT=Kc();oh.exports=LT;function LT(e,t,r){return MT(e,t,null,r)}});var ah=b(function(rZ,sh){sh.exports={parallel:th(),serial:ih(),serialOrdered:Kc()}});var Yc=b(function(nZ,ch){ch.exports=Object});var lh=b(function(oZ,uh){uh.exports=Error});var dh=b(function(iZ,ph){ph.exports=EvalError});var fh=b(function(sZ,mh){mh.exports=RangeError});var gh=b(function(aZ,hh){hh.exports=ReferenceError});var vh=b(function(cZ,xh){xh.exports=SyntaxError});var gs=b(function(uZ,yh){yh.exports=TypeError});var _h=b(function(lZ,bh){bh.exports=URIError});var kh=b(function(pZ,wh){wh.exports=Math.abs});var $h=b(function(dZ,Sh){Sh.exports=Math.floor});var Eh=b(function(mZ,Th){Th.exports=Math.max});var Ph=b(function(fZ,Rh){Rh.exports=Math.min});var Oh=b(function(hZ,zh){zh.exports=Math.pow});var Ch=b(function(gZ,Ah){Ah.exports=Math.round});var jh=b(function(xZ,Ih){Ih.exports=Number.isNaN||function(t){return t!==t}});var Dh=b(function(vZ,Nh){var qT=jh();Nh.exports=function(t){if(qT(t)||t===0)return t;return t<0?-1:1}});var Lh=b(function(yZ,Mh){Mh.exports=Object.getOwnPropertyDescriptor});var Xc=b(function(bZ,qh){var xs=Lh();if(xs)try{xs([],"length")}catch(e){xs=null}qh.exports=xs});var Fh=b(function(_Z,Uh){var vs=Object.defineProperty||!1;if(vs)try{vs({},"a",{value:1})}catch(e){vs=!1}Uh.exports=vs});var Qc=b(function(wZ,Zh){Zh.exports=function(){if(typeof Symbol!=="function"||typeof Object.getOwnPropertySymbols!=="function")return!1;if(typeof Symbol.iterator==="symbol")return!0;var t={},r=Symbol("test"),n=Object(r);if(typeof r==="string")return!1;if(Object.prototype.toString.call(r)!=="[object Symbol]")return!1;if(Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;t[r]=o;for(var i in t)return!1;if(typeof Object.keys==="function"&&Object.keys(t).length!==0)return!1;if(typeof Object.getOwnPropertyNames==="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var s=Object.getOwnPropertySymbols(t);if(s.length!==1||s[0]!==r)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor==="function"){var a=Object.getOwnPropertyDescriptor(t,r);if(a.value!==o||a.enumerable!==!0)return!1}return!0}});var Vh=b(function(kZ,Hh){var Bh=typeof Symbol<"u"&&Symbol,UT=Qc();Hh.exports=function(){if(typeof Bh!=="function")return!1;if(typeof Symbol!=="function")return!1;if(typeof Bh("foo")!=="symbol")return!1;if(typeof Symbol("bar")!=="symbol")return!1;return UT()}});var eu=b(function(SZ,Gh){Gh.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var tu=b(function($Z,Jh){var FT=Yc();Jh.exports=FT.getPrototypeOf||null});var Yh=b(function(TZ,Kh){var ZT="Function.prototype.bind called on incompatible ",BT=Object.prototype.toString,HT=Math.max,VT="[object Function]",Wh=function(t,r){var n=[];for(var o=0;o<t.length;o+=1)n[o]=t[o];for(var i=0;i<r.length;i+=1)n[i+t.length]=r[i];return n},GT=function(t,r){var n=[];for(var o=r||0,i=0;o<t.length;o+=1,i+=1)n[i]=t[o];return n},JT=function(e,t){var r="";for(var n=0;n<e.length;n+=1)if(r+=e[n],n+1<e.length)r+=t;return r};Kh.exports=function(t){var r=this;if(typeof r!=="function"||BT.apply(r)!==VT)throw TypeError(ZT+r);var n=GT(arguments,1),o,i=function(){if(this instanceof o){var l=r.apply(this,Wh(n,arguments));if(Object(l)===l)return l;return this}return r.apply(t,Wh(n,arguments))},s=HT(0,r.length-n.length),a=[];for(var c=0;c<s;c++)a[c]="$"+c;if(o=Function("binder","return function ("+JT(a,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var u=function(){};u.prototype=r.prototype,o.prototype=new u,u.prototype=null}return o}});var Oo=b(function(EZ,Xh){var WT=Yh();Xh.exports=Function.prototype.bind||WT});var ys=b(function(RZ,Qh){Qh.exports=Function.prototype.call});var ru=b(function(PZ,eg){eg.exports=Function.prototype.apply});var rg=b(function(zZ,tg){tg.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var og=b(function(OZ,ng){var KT=Oo(),YT=ru(),XT=ys(),QT=rg();ng.exports=QT||KT.call(XT,YT)});var sg=b(function(AZ,ig){var eE=Oo(),tE=gs(),rE=ys(),nE=og();ig.exports=function(t){if(t.length<1||typeof t[0]!=="function")throw new tE("a function is required");return nE(eE,rE,t)}});var dg=b(function(CZ,pg){var oE=sg(),ag=Xc(),ug;try{ug=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!=="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var nu=!!ug&&ag&&ag(Object.prototype,"__proto__"),lg=Object,cg=lg.getPrototypeOf;pg.exports=nu&&typeof nu.get==="function"?oE([nu.get]):typeof cg==="function"?function(t){return cg(t==null?t:lg(t))}:!1});var xg=b(function(IZ,gg){var mg=eu(),fg=tu(),hg=dg();gg.exports=mg?function(t){return mg(t)}:fg?function(t){if(!t||typeof t!=="object"&&typeof t!=="function")throw TypeError("getProto: not an object");return fg(t)}:hg?function(t){return hg(t)}:null});var bs=b(function(jZ,vg){var iE=Function.prototype.call,sE=Object.prototype.hasOwnProperty,aE=Oo();vg.exports=aE.call(iE,sE)});var Sg=b(function(NZ,kg){var Q,cE=Yc(),uE=lh(),lE=dh(),pE=fh(),dE=gh(),In=vh(),Cn=gs(),mE=_h(),fE=kh(),hE=$h(),gE=Eh(),xE=Ph(),vE=Oh(),yE=Ch(),bE=Dh(),_g=Function,ou=function(e){try{return _g('"use strict"; return ('+e+").constructor;")()}catch(t){}},Ao=Xc(),_E=Fh(),iu=function(){throw new Cn},wE=Ao?function(){try{return arguments.callee,iu}catch(e){try{return Ao(arguments,"callee").get}catch(t){return iu}}}():iu,On=Vh()(),Ge=xg(),kE=tu(),SE=eu(),wg=ru(),Co=ys(),An={},$E=typeof Uint8Array>"u"||!Ge?Q:Ge(Uint8Array),Xr={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?Q:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Q:ArrayBuffer,"%ArrayIteratorPrototype%":On&&Ge?Ge([][Symbol.iterator]()):Q,"%AsyncFromSyncIteratorPrototype%":Q,"%AsyncFunction%":An,"%AsyncGenerator%":An,"%AsyncGeneratorFunction%":An,"%AsyncIteratorPrototype%":An,"%Atomics%":typeof Atomics>"u"?Q:Atomics,"%BigInt%":typeof BigInt>"u"?Q:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?Q:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?Q:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Q:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":uE,"%eval%":eval,"%EvalError%":lE,"%Float16Array%":typeof Float16Array>"u"?Q:Float16Array,"%Float32Array%":typeof Float32Array>"u"?Q:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Q:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Q:FinalizationRegistry,"%Function%":_g,"%GeneratorFunction%":An,"%Int8Array%":typeof Int8Array>"u"?Q:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Q:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Q:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":On&&Ge?Ge(Ge([][Symbol.iterator]())):Q,"%JSON%":typeof JSON==="object"?JSON:Q,"%Map%":typeof Map>"u"?Q:Map,"%MapIteratorPrototype%":typeof Map>"u"||!On||!Ge?Q:Ge(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":cE,"%Object.getOwnPropertyDescriptor%":Ao,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Q:Promise,"%Proxy%":typeof Proxy>"u"?Q:Proxy,"%RangeError%":pE,"%ReferenceError%":dE,"%Reflect%":typeof Reflect>"u"?Q:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Q:Set,"%SetIteratorPrototype%":typeof Set>"u"||!On||!Ge?Q:Ge(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Q:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":On&&Ge?Ge(""[Symbol.iterator]()):Q,"%Symbol%":On?Symbol:Q,"%SyntaxError%":In,"%ThrowTypeError%":wE,"%TypedArray%":$E,"%TypeError%":Cn,"%Uint8Array%":typeof Uint8Array>"u"?Q:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Q:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Q:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Q:Uint32Array,"%URIError%":mE,"%WeakMap%":typeof WeakMap>"u"?Q:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Q:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Q:WeakSet,"%Function.prototype.call%":Co,"%Function.prototype.apply%":wg,"%Object.defineProperty%":_E,"%Object.getPrototypeOf%":kE,"%Math.abs%":fE,"%Math.floor%":hE,"%Math.max%":gE,"%Math.min%":xE,"%Math.pow%":vE,"%Math.round%":yE,"%Math.sign%":bE,"%Reflect.getPrototypeOf%":SE};if(Ge)try{null.error}catch(e){su=Ge(Ge(e)),Xr["%Error.prototype%"]=su}var su,TE=function e(t){var r;if(t==="%AsyncFunction%")r=ou("async function () {}");else if(t==="%GeneratorFunction%")r=ou("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=ou("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");if(n)r=n.prototype}else if(t==="%AsyncIteratorPrototype%"){var o=e("%AsyncGenerator%");if(o&&Ge)r=Ge(o.prototype)}return Xr[t]=r,r},yg={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Io=Oo(),_s=bs(),EE=Io.call(Co,Array.prototype.concat),RE=Io.call(wg,Array.prototype.splice),bg=Io.call(Co,String.prototype.replace),ws=Io.call(Co,String.prototype.slice),PE=Io.call(Co,RegExp.prototype.exec),zE=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,OE=/\\(\\)?/g,AE=function(t){var r=ws(t,0,1),n=ws(t,-1);if(r==="%"&&n!=="%")throw new In("invalid intrinsic syntax, expected closing `%`");else if(n==="%"&&r!=="%")throw new In("invalid intrinsic syntax, expected opening `%`");var o=[];return bg(t,zE,function(i,s,a,c){o[o.length]=a?bg(c,OE,"$1"):s||i}),o},CE=function(t,r){var n=t,o;if(_s(yg,n))o=yg[n],n="%"+o[0]+"%";if(_s(Xr,n)){var i=Xr[n];if(i===An)i=TE(n);if(typeof i>"u"&&!r)throw new Cn("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new In("intrinsic "+t+" does not exist!")};kg.exports=function(t,r){if(typeof t!=="string"||t.length===0)throw new Cn("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!=="boolean")throw new Cn('"allowMissing" argument must be a boolean');if(PE(/^%?[^%]*%?$/,t)===null)throw new In("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=AE(t),o=n.length>0?n[0]:"",i=CE("%"+o+"%",r),{name:s,value:a}=i,c=!1,u=i.alias;if(u)o=u[0],RE(n,EE([0,1],u));for(var l=1,p=!0;l<n.length;l+=1){var m=n[l],d=ws(m,0,1),h=ws(m,-1);if((d==='"'||d==="'"||d==="`"||(h==='"'||h==="'"||h==="`"))&&d!==h)throw new In("property names with quotes must have matching quotes");if(m==="constructor"||!p)c=!0;if(o+="."+m,s="%"+o+"%",_s(Xr,s))a=Xr[s];else if(a!=null){if(!(m in a)){if(!r)throw new Cn("base intrinsic for "+t+" exists, but the property is not available.");return}if(Ao&&l+1>=n.length){var x=Ao(a,m);if(p=!!x,p&&"get"in x&&!("originalValue"in x.get))a=x.get;else a=a[m]}else p=_s(a,m),a=a[m];if(p&&!c)Xr[s]=a}}return a}});var Tg=b(function(DZ,$g){var IE=Qc();$g.exports=function(){return IE()&&!!Symbol.toStringTag}});var Pg=b(function(MZ,Rg){var jE=Sg(),Eg=jE("%Object.defineProperty%",!0),NE=Tg()(),DE=bs(),ME=gs(),ks=NE?Symbol.toStringTag:null;Rg.exports=function(t,r){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,o=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!=="boolean"||typeof o<"u"&&typeof o!=="boolean")throw new ME("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");if(ks&&(n||!DE(t,ks)))if(Eg)Eg(t,ks,{configurable:!o,enumerable:!1,value:r,writable:!1});else t[ks]=r}});var Og=b(function(LZ,zg){zg.exports=function(e,t){return Object.keys(t).forEach(function(r){e[r]=e[r]||t[r]}),e}});var Ig=b(function(qZ,Cg){var lu=Mf(),LE=ge("util"),au=ge("path"),qE=ge("http"),UE=ge("https"),FE=ge("url").parse,ZE=ge("fs"),BE=ge("stream").Stream,HE=ge("crypto"),cu=Bf(),VE=ah(),GE=Pg(),$r=bs(),uu=Og();function Ag(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}function ie(e){if(!(this instanceof ie))return new ie(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],lu.call(this),e=e||{};for(var t in e)this[t]=e[t]}LE.inherits(ie,lu);ie.LINE_BREAK=`\r
|
|
8
|
+
`;ie.DEFAULT_CONTENT_TYPE="application/octet-stream";ie.prototype.append=function(e,t,r){if(r=r||{},typeof r==="string")r={filename:r};var n=lu.prototype.append.bind(this);if(typeof t==="number"||t==null)t=String(t);if(Array.isArray(t)){this._error(Error("Arrays are not supported."));return}var o=this._multiPartHeader(e,t,r),i=this._multiPartFooter();n(o),n(t),n(i),this._trackLength(o,t,r)};ie.prototype._trackLength=function(e,t,r){var n=0;if(r.knownLength!=null)n+=Number(r.knownLength);else if(Buffer.isBuffer(t))n=t.length;else if(typeof t==="string")n=Buffer.byteLength(t);if(this._valueLength+=n,this._overheadLength+=Buffer.byteLength(e)+ie.LINE_BREAK.length,!t||!t.path&&!(t.readable&&$r(t,"httpVersion"))&&!(t instanceof BE))return;if(!r.knownLength)this._valuesToMeasure.push(t)};ie.prototype._lengthRetriever=function(e,t){if($r(e,"fd"))if(e.end!=null&&e.end!=1/0&&e.start!=null)t(null,e.end+1-(e.start?e.start:0));else ZE.stat(e.path,function(r,n){if(r){t(r);return}var o=n.size-(e.start?e.start:0);t(null,o)});else if($r(e,"httpVersion"))t(null,Number(e.headers["content-length"]));else if($r(e,"httpModule"))e.on("response",function(r){e.pause(),t(null,Number(r.headers["content-length"]))}),e.resume();else t("Unknown stream")};ie.prototype._multiPartHeader=function(e,t,r){if(typeof r.header==="string")return r.header;var n=this._getContentDisposition(t,r),o=this._getContentType(t,r),i="",s={"Content-Disposition":["form-data",'name="'+Ag(e)+'"'].concat(n||[]),"Content-Type":[].concat(o||[])};if(typeof r.header==="object")uu(s,r.header);var a;for(var c in s)if($r(s,c)){if(a=s[c],a==null)continue;if(!Array.isArray(a))a=[a];if(a.length)i+=c+": "+a.join("; ")+ie.LINE_BREAK}return"--"+this.getBoundary()+ie.LINE_BREAK+i+ie.LINE_BREAK};ie.prototype._getContentDisposition=function(e,t){var r;if(typeof t.filepath==="string")r=au.normalize(t.filepath).replace(/\\/g,"/");else if(t.filename||e&&(e.name||e.path))r=au.basename(t.filename||e&&(e.name||e.path));else if(e&&e.readable&&$r(e,"httpVersion"))r=au.basename(e.client._httpMessage.path||"");if(r)return'filename="'+Ag(r)+'"'};ie.prototype._getContentType=function(e,t){var r=t.contentType;if(!r&&e&&e.name)r=cu.lookup(e.name);if(!r&&e&&e.path)r=cu.lookup(e.path);if(!r&&e&&e.readable&&$r(e,"httpVersion"))r=e.headers["content-type"];if(!r&&(t.filepath||t.filename))r=cu.lookup(t.filepath||t.filename);if(!r&&e&&typeof e==="object")r=ie.DEFAULT_CONTENT_TYPE;return r};ie.prototype._multiPartFooter=function(){return function(e){var t=ie.LINE_BREAK,r=this._streams.length===0;if(r)t+=this._lastBoundary();e(t)}.bind(this)};ie.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+ie.LINE_BREAK};ie.prototype.getHeaders=function(e){var t,r={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)if($r(e,t))r[t.toLowerCase()]=e[t];return r};ie.prototype.setBoundary=function(e){if(typeof e!=="string")throw TypeError("FormData boundary must be a string");this._boundary=e};ie.prototype.getBoundary=function(){if(!this._boundary)this._generateBoundary();return this._boundary};ie.prototype.getBuffer=function(){var e=new Buffer.alloc(0),t=this.getBoundary();for(var r=0,n=this._streams.length;r<n;r++)if(typeof this._streams[r]!=="function"){if(Buffer.isBuffer(this._streams[r]))e=Buffer.concat([e,this._streams[r]]);else e=Buffer.concat([e,Buffer.from(this._streams[r])]);if(typeof this._streams[r]!=="string"||this._streams[r].substring(2,t.length+2)!==t)e=Buffer.concat([e,Buffer.from(ie.LINE_BREAK)])}return Buffer.concat([e,Buffer.from(this._lastBoundary())])};ie.prototype._generateBoundary=function(){this._boundary="--------------------------"+HE.randomBytes(12).toString("hex")};ie.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;if(this._streams.length)e+=this._lastBoundary().length;if(!this.hasKnownLength())this._error(Error("Cannot calculate proper length in synchronous way."));return e};ie.prototype.hasKnownLength=function(){var e=!0;if(this._valuesToMeasure.length)e=!1;return e};ie.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;if(this._streams.length)t+=this._lastBoundary().length;if(!this._valuesToMeasure.length){process.nextTick(e.bind(this,null,t));return}VE.parallel(this._valuesToMeasure,this._lengthRetriever,function(r,n){if(r){e(r);return}n.forEach(function(o){t+=o}),e(null,t)})};ie.prototype.submit=function(e,t){var r,n,o={method:"post"};if(typeof e==="string")e=FE(e),n=uu({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},o);else if(n=uu(e,o),!n.port)n.port=n.protocol==="https:"?443:80;if(n.headers=this.getHeaders(e.headers),n.protocol==="https:")r=UE.request(n);else r=qE.request(n);return this.getLength(function(i,s){if(i&&i!=="Unknown stream"){this._error(i);return}if(s)r.setHeader("Content-Length",s);if(this.pipe(r),t){var a,c=function(u,l){return r.removeListener("error",c),r.removeListener("response",a),t.call(this,u,l)};a=c.bind(this,null),r.on("error",c),r.on("response",a)}}.bind(this)),r};ie.prototype._error=function(e){if(!this.error)this.error=e,this.pause(),this.emit("error",e)};ie.prototype.toString=function(){return"[object FormData]"};GE(ie.prototype,"FormData");Cg.exports=ie});var Xg=b(function(q9,Yg){var Dn=1000,Mn=Dn*60,Ln=Mn*60,tn=Ln*24,hR=tn*7,gR=tn*365.25;Yg.exports=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return xR(e);else if(r==="number"&&isFinite(e))return t.long?yR(e):vR(e);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function xR(e){if(e=String(e),e.length>100)return;var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!t)return;var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*gR;case"weeks":case"week":case"w":return r*hR;case"days":case"day":case"d":return r*tn;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Ln;case"minutes":case"minute":case"mins":case"min":case"m":return r*Mn;case"seconds":case"second":case"secs":case"sec":case"s":return r*Dn;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}function vR(e){var t=Math.abs(e);if(t>=tn)return Math.round(e/tn)+"d";if(t>=Ln)return Math.round(e/Ln)+"h";if(t>=Mn)return Math.round(e/Mn)+"m";if(t>=Dn)return Math.round(e/Dn)+"s";return e+"ms"}function yR(e){var t=Math.abs(e);if(t>=tn)return Ts(e,t,tn,"day");if(t>=Ln)return Ts(e,t,Ln,"hour");if(t>=Mn)return Ts(e,t,Mn,"minute");if(t>=Dn)return Ts(e,t,Dn,"second");return e+" ms"}function Ts(e,t,r,n){var o=t>=r*1.5;return Math.round(e/r)+" "+n+(o?"s":"")}});var Su=b(function(U9,Qg){function bR(e){r.debug=r,r.default=r,r.coerce=c,r.disable=s,r.enable=o,r.enabled=a,r.humanize=Xg(),r.destroy=u,Object.keys(e).forEach((l)=>{r[l]=e[l]}),r.names=[],r.skips=[],r.formatters={};function t(l){let p=0;for(let m=0;m<l.length;m++)p=(p<<5)-p+l.charCodeAt(m),p|=0;return r.colors[Math.abs(p)%r.colors.length]}r.selectColor=t;function r(l){let p,m=null,d,h;function x(...v){if(!x.enabled)return;let g=x,y=Number(new Date),w=y-(p||y);if(g.diff=w,g.prev=p,g.curr=y,p=y,v[0]=r.coerce(v[0]),typeof v[0]!=="string")v.unshift("%O");let P=0;v[0]=v[0].replace(/%([a-zA-Z%])/g,(H,me)=>{if(H==="%%")return"%";P++;let K=r.formatters[me];if(typeof K==="function"){let dt=v[P];H=K.call(g,dt),v.splice(P,1),P--}return H}),r.formatArgs.call(g,v),(g.log||r.log).apply(g,v)}if(x.namespace=l,x.useColors=r.useColors(),x.color=r.selectColor(l),x.extend=n,x.destroy=r.destroy,Object.defineProperty(x,"enabled",{enumerable:!0,configurable:!1,get:()=>{if(m!==null)return m;if(d!==r.namespaces)d=r.namespaces,h=r.enabled(l);return h},set:(v)=>{m=v}}),typeof r.init==="function")r.init(x);return x}function n(l,p){let m=r(this.namespace+(typeof p>"u"?":":p)+l);return m.log=this.log,m}function o(l){r.save(l),r.namespaces=l,r.names=[],r.skips=[];let p=(typeof l==="string"?l:"").trim().replace(/\s+/g,",").split(",").filter(Boolean);for(let m of p)if(m[0]==="-")r.skips.push(m.slice(1));else r.names.push(m)}function i(l,p){let m=0,d=0,h=-1,x=0;while(m<l.length)if(d<p.length&&(p[d]===l[m]||p[d]==="*"))if(p[d]==="*")h=d,x=m,d++;else m++,d++;else if(h!==-1)d=h+1,x++,m=x;else return!1;while(d<p.length&&p[d]==="*")d++;return d===p.length}function s(){let l=[...r.names,...r.skips.map((p)=>"-"+p)].join(",");return r.enable(""),l}function a(l){for(let p of r.skips)if(i(l,p))return!1;for(let p of r.names)if(i(l,p))return!0;return!1}function c(l){if(l instanceof Error)return l.stack||l.message;return l}function u(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}return r.enable(r.load()),r}Qg.exports=bR});var ex=b(function($u,Es){$u.formatArgs=wR;$u.save=kR;$u.load=SR;$u.useColors=_R;$u.storage=$R();$u.destroy=(()=>{let e=!1;return()=>{if(!e)e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")}})();$u.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function _R(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function wR(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+Es.exports.humanize(this.diff),!this.useColors)return;let t="color: "+this.color;e.splice(1,0,t,"color: inherit");let r=0,n=0;e[0].replace(/%[a-zA-Z%]/g,(o)=>{if(o==="%%")return;if(r++,o==="%c")n=r}),e.splice(n,0,t)}$u.log=console.debug||console.log||(()=>{});function kR(e){try{if(e)$u.storage.setItem("debug",e);else $u.storage.removeItem("debug")}catch(t){}}function SR(){let e;try{e=$u.storage.getItem("debug")||$u.storage.getItem("DEBUG")}catch(t){}if(!e&&typeof process<"u"&&"env"in process)e=process.env.DEBUG;return e}function $R(){try{return localStorage}catch(e){}}Es.exports=Su()($u);var{formatters:TR}=Es.exports;TR.j=function(e){try{return JSON.stringify(e)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}});var rx=b(function(Z9,tx){tx.exports=(e,t=process.argv)=>{let r=e.startsWith("-")?"":e.length===1?"-":"--",n=t.indexOf(r+e),o=t.indexOf("--");return n!==-1&&(o===-1||n<o)}});var ix=b(function(B9,ox){var IR=ge("os"),nx=ge("tty"),Ot=rx(),{env:Je}=process,Rr;if(Ot("no-color")||Ot("no-colors")||Ot("color=false")||Ot("color=never"))Rr=0;else if(Ot("color")||Ot("colors")||Ot("color=true")||Ot("color=always"))Rr=1;if("FORCE_COLOR"in Je)if(Je.FORCE_COLOR==="true")Rr=1;else if(Je.FORCE_COLOR==="false")Rr=0;else Rr=Je.FORCE_COLOR.length===0?1:Math.min(parseInt(Je.FORCE_COLOR,10),3);function Tu(e){if(e===0)return!1;return{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function Eu(e,t){if(Rr===0)return 0;if(Ot("color=16m")||Ot("color=full")||Ot("color=truecolor"))return 3;if(Ot("color=256"))return 2;if(e&&!t&&Rr===void 0)return 0;let r=Rr||0;if(Je.TERM==="dumb")return r;if(process.platform==="win32"){let n=IR.release().split(".");if(Number(n[0])>=10&&Number(n[2])>=10586)return Number(n[2])>=14931?3:2;return 1}if("CI"in Je){if(["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((n)=>(n in Je))||Je.CI_NAME==="codeship")return 1;return r}if("TEAMCITY_VERSION"in Je)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Je.TEAMCITY_VERSION)?1:0;if(Je.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Je){let n=parseInt((Je.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Je.TERM_PROGRAM){case"iTerm.app":return n>=3?3:2;case"Apple_Terminal":return 2}}if(/-256(color)?$/i.test(Je.TERM))return 2;if(/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Je.TERM))return 1;if("COLORTERM"in Je)return 1;return r}function jR(e){let t=Eu(e,e&&e.isTTY);return Tu(t)}ox.exports={supportsColor:jR,stdout:Tu(Eu(!0,nx.isatty(1))),stderr:Tu(Eu(!0,nx.isatty(2)))}});var cx=b(function(Ru,Ps){var NR=ge("tty"),Rs=ge("util");Ru.init=ZR;Ru.log=qR;Ru.formatArgs=MR;Ru.save=UR;Ru.load=FR;Ru.useColors=DR;Ru.destroy=Rs.deprecate(()=>{},"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");Ru.colors=[6,2,3,4,5,1];try{let e=ix();if(e&&(e.stderr||e).level>=2)Ru.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221]}catch(e){}Ru.inspectOpts=Object.keys(process.env).filter((e)=>/^debug_/i.test(e)).reduce((e,t)=>{let r=t.substring(6).toLowerCase().replace(/_([a-z])/g,(o,i)=>i.toUpperCase()),n=process.env[t];if(/^(yes|on|true|enabled)$/i.test(n))n=!0;else if(/^(no|off|false|disabled)$/i.test(n))n=!1;else if(n==="null")n=null;else n=Number(n);return e[r]=n,e},{});function DR(){return"colors"in Ru.inspectOpts?Boolean(Ru.inspectOpts.colors):NR.isatty(process.stderr.fd)}function MR(e){let{namespace:t,useColors:r}=this;if(r){let n=this.color,o="\x1B[3"+(n<8?n:"8;5;"+n),i=` ${o};1m${t} \x1B[0m`;e[0]=i+e[0].split(`
|
|
9
9
|
`).join(`
|
|
10
|
-
`+i),e.push(o+"m+"+
|
|
11
|
-
`)}function
|
|
12
|
-
`).map((t)=>t.trim()).join(" ")};
|
|
13
|
-
`).some((t)=>t.indexOf("(https.js:")!==-1||t.indexOf("node:https:")!==-1)}function
|
|
10
|
+
`+i),e.push(o+"m+"+Ps.exports.humanize(this.diff)+"\x1B[0m")}else e[0]=LR()+t+" "+e[0]}function LR(){if(Ru.inspectOpts.hideDate)return"";return new Date().toISOString()+" "}function qR(...e){return process.stderr.write(Rs.formatWithOptions(Ru.inspectOpts,...e)+`
|
|
11
|
+
`)}function UR(e){if(e)process.env.DEBUG=e;else delete process.env.DEBUG}function FR(){return process.env.DEBUG}function ZR(e){e.inspectOpts={};let t=Object.keys(Ru.inspectOpts);for(let r=0;r<t.length;r++)e.inspectOpts[t[r]]=Ru.inspectOpts[t[r]]}Ps.exports=Su()(Ru);var{formatters:sx}=Ps.exports;sx.o=function(e){return this.inspectOpts.colors=this.useColors,Rs.inspect(e,this.inspectOpts).split(`
|
|
12
|
+
`).map((t)=>t.trim()).join(" ")};sx.O=function(e){return this.inspectOpts.colors=this.useColors,Rs.inspect(e,this.inspectOpts)}});var Mo=b(function(V9,Pu){if(typeof process>"u"||process.type==="renderer"||!1||process.__nwjs)Pu.exports=ex();else Pu.exports=cx()});var lx=b(function(ux){Object.defineProperty(ux,"__esModule",{value:!0});function YR(e){return function(t,r){return new Promise((n,o)=>{e.call(this,t,r,(i,s)=>{if(i)o(i);else n(s)})})}}ux.default=YR});var mx=b(function(Ou,dx){var px=Ou&&Ou.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},QR=ge("events"),eP=px(Mo()),tP=px(lx()),Lo=eP.default("agent-base");function rP(e){return Boolean(e)&&typeof e.addRequest==="function"}function zu(){let{stack:e}=Error();if(typeof e!=="string")return!1;return e.split(`
|
|
13
|
+
`).some((t)=>t.indexOf("(https.js:")!==-1||t.indexOf("node:https:")!==-1)}function zs(e,t){return new zs.Agent(e,t)}(function(e){class t extends QR.EventEmitter{constructor(r,n){super();let o=n;if(typeof r==="function")this.callback=r;else if(r)o=r;if(this.timeout=null,o&&typeof o.timeout==="number")this.timeout=o.timeout;this.maxFreeSockets=1,this.maxSockets=1,this.maxTotalSockets=1/0,this.sockets={},this.freeSockets={},this.requests={},this.options={}}get defaultPort(){if(typeof this.explicitDefaultPort==="number")return this.explicitDefaultPort;return zu()?443:80}set defaultPort(r){this.explicitDefaultPort=r}get protocol(){if(typeof this.explicitProtocol==="string")return this.explicitProtocol;return zu()?"https:":"http:"}set protocol(r){this.explicitProtocol=r}callback(r,n,o){throw Error('"agent-base" has no default implementation, you must subclass and override `callback()`')}addRequest(r,n){let o=Object.assign({},n);if(typeof o.secureEndpoint!=="boolean")o.secureEndpoint=zu();if(o.host==null)o.host="localhost";if(o.port==null)o.port=o.secureEndpoint?443:80;if(o.protocol==null)o.protocol=o.secureEndpoint?"https:":"http:";if(o.host&&o.path)delete o.path;delete o.agent,delete o.hostname,delete o._defaultAgent,delete o.defaultPort,delete o.createConnection,r._last=!0,r.shouldKeepAlive=!1;let i=!1,s=null,a=o.timeout||this.timeout,c=(m)=>{if(r._hadError)return;r.emit("error",m),r._hadError=!0},u=()=>{s=null,i=!0;let m=Error(`A "socket" was not created for HTTP request before ${a}ms`);m.code="ETIMEOUT",c(m)},l=(m)=>{if(i)return;if(s!==null)clearTimeout(s),s=null;c(m)},p=(m)=>{if(i)return;if(s!=null)clearTimeout(s),s=null;if(rP(m)){Lo("Callback returned another Agent instance %o",m.constructor.name),m.addRequest(r,o);return}if(m){m.once("free",()=>{this.freeSocket(m,o)}),r.onSocket(m);return}let d=Error(`no Duplex stream was returned to agent-base for \`${r.method} ${r.path}\``);c(d)};if(typeof this.callback!=="function"){c(Error("`callback` is not defined"));return}if(!this.promisifiedCallback)if(this.callback.length>=3)Lo("Converting legacy callback function to promise"),this.promisifiedCallback=tP.default(this.callback);else this.promisifiedCallback=this.callback;if(typeof a==="number"&&a>0)s=setTimeout(u,a);if("port"in o&&typeof o.port!=="number")o.port=Number(o.port);try{Lo("Resolving socket for %o request: %o",o.protocol,`${r.method} ${r.path}`),Promise.resolve(this.promisifiedCallback(r,o)).then(p,l)}catch(m){Promise.reject(m).catch(l)}}freeSocket(r,n){Lo("Freeing socket %o %o",r.constructor.name,n),r.destroy()}destroy(){Lo("Destroying agent %o",this.constructor.name)}}e.Agent=t,e.prototype=e.Agent.prototype})(zs||(zs={}));dx.exports=zs});var fx=b(function(Uo){var nP=Uo&&Uo.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Uo,"__esModule",{value:!0});var oP=nP(Mo()),qo=oP.default("https-proxy-agent:parse-proxy-response");function iP(e){return new Promise((t,r)=>{let n=0,o=[];function i(){let p=e.read();if(p)l(p);else e.once("readable",i)}function s(){e.removeListener("end",c),e.removeListener("error",u),e.removeListener("close",a),e.removeListener("readable",i)}function a(p){qo("onclose had error %o",p)}function c(){qo("onend")}function u(p){s(),qo("onerror %o",p),r(p)}function l(p){o.push(p),n+=p.length;let m=Buffer.concat(o,n);if(m.indexOf(`\r
|
|
14
14
|
\r
|
|
15
|
-
`)===-1){
|
|
16
|
-
`)),x=+h.split(" ")[1];
|
|
17
|
-
`;if(r.auth)i["Proxy-Authorization"]=`Basic ${Buffer.from(r.auth).toString("base64")}`;let{host:c,port:u,secureEndpoint:l}=t;if(!
|
|
18
|
-
`;let p=
|
|
19
|
-
`);let{statusCode:m,buffered:d}=yield p;if(m===200){if(e.once("socket",zz),t.secureEndpoint){ei("Upgrading socket connection to TLS");let x=t.servername||t.host;return Rx.default.connect(Object.assign(Object.assign({},Cz(t,"host","hostname","path","port")),{socket:o,servername:x}))}return o}o.destroy();let h=new Ex.default.Socket({writable:!1});return h.readable=!0,e.once("socket",(x)=>{ei("replaying proxy buffer for failed request"),Tz.default(x.listenerCount("data")>0),x.push(d),x.push(null)}),h})}}sn.default=Px;function zz(e){e.resume()}function Oz(e,t){return Boolean(!t&&e===80||t&&e===443)}function Az(e){return typeof e==="string"?/^https:?$/i.test(e):!1}function Cz(e,...t){let r={},n;for(n in e)if(!t.includes(n))r[n]=e[n];return r}});var Ax=_(function(Du,Ox){var Iz=Du&&Du.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},ju=Iz(zx());function Nu(e){return new ju.default(e)}(function(e){e.HttpsProxyAgent=ju.default,e.prototype=ju.default.prototype})(Nu||(Nu={}));Ox.exports=Nu});var Ix=_(function(iB,Cx){var ti;Cx.exports=function(){if(!ti){try{ti=Ko()("follow-redirects")}catch(e){}if(typeof ti!=="function")ti=function(){}}ti.apply(null,arguments)}});var Mx=_(function(sB,Wu){var ni=ge("url"),ri=ni.URL,jz=ge("http"),Nz=ge("https"),Fu=ge("stream").Writable,Zu=ge("assert"),jx=Ix();(function(){var t=typeof process<"u",r=typeof window<"u"&&typeof document<"u",n=cn(Error.captureStackTrace);if(!t&&(r||!n))console.warn("The follow-redirects package should be excluded from browser builds.")})();var Bu=!1;try{Zu(new ri(""))}catch(e){Bu=e.code==="ERR_INVALID_URL"}var Dz=["Authorization","Proxy-Authorization","Cookie"],Lz=["auth","host","hostname","href","path","pathname","port","protocol","query","search","hash"],Hu=["abort","aborted","connect","error","socket","timeout"],Vu=Object.create(null);Hu.forEach(function(e){Vu[e]=function(t,r,n){this._redirectable.emit(e,t,r,n)}});var Mu=oi("ERR_INVALID_URL","Invalid URL",TypeError),qu=oi("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),Mz=oi("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded",qu),qz=oi("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),Uz=oi("ERR_STREAM_WRITE_AFTER_END","write after end"),Fz=Fu.prototype.destroy||Dx;function mt(e,t){if(Fu.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],t)this.on("response",t);var r=this;this._onNativeResponse=function(n){try{r._processResponse(n)}catch(o){r.emit("error",o instanceof qu?o:new qu({cause:o}))}},this._headerFilter=new RegExp("^(?:"+Dz.concat(e.sensitiveHeaders).map(Jz).join("|")+")$","i"),this._performRequest()}mt.prototype=Object.create(Fu.prototype);mt.prototype.abort=function(){Ju(this._currentRequest),this._currentRequest.abort(),this.emit("abort")};mt.prototype.destroy=function(e){return Ju(this._currentRequest,e),Fz.call(this,e),this};mt.prototype.write=function(e,t,r){if(this._ending)throw new Uz;if(!an(e)&&!Vz(e))throw TypeError("data should be a string, Buffer or Uint8Array");if(cn(t))r=t,t=null;if(e.length===0){if(r)r();return}if(this._requestBodyLength+e.length<=this._options.maxBodyLength)this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:t}),this._currentRequest.write(e,t,r);else this.emit("error",new qz),this.abort()};mt.prototype.end=function(e,t,r){if(cn(e))r=e,e=t=null;else if(cn(t))r=t,t=null;if(!e)this._ended=this._ending=!0,this._currentRequest.end(null,null,r);else{var n=this,o=this._currentRequest;this.write(e,t,function(){n._ended=!0,o.end(null,null,r)}),this._ending=!0}};mt.prototype.setHeader=function(e,t){this._options.headers[e]=t,this._currentRequest.setHeader(e,t)};mt.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)};mt.prototype.setTimeout=function(e,t){var r=this;function n(s){s.setTimeout(e),s.removeListener("timeout",s.destroy),s.addListener("timeout",s.destroy)}function o(s){if(r._timeout)clearTimeout(r._timeout);r._timeout=setTimeout(function(){r.emit("timeout"),i()},e),n(s)}function i(){if(r._timeout)clearTimeout(r._timeout),r._timeout=null;if(r.removeListener("abort",i),r.removeListener("error",i),r.removeListener("response",i),r.removeListener("close",i),t)r.removeListener("timeout",t);if(!r.socket)r._currentRequest.removeListener("socket",o)}if(t)this.on("timeout",t);if(this.socket)o(this.socket);else this._currentRequest.once("socket",o);return this.on("socket",n),this.on("abort",i),this.on("error",i),this.on("response",i),this.on("close",i),this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach(function(e){mt.prototype[e]=function(t,r){return this._currentRequest[e](t,r)}});["aborted","connection","socket"].forEach(function(e){Object.defineProperty(mt.prototype,e,{get:function(){return this._currentRequest[e]}})});mt.prototype._sanitizeOptions=function(e){if(!e.headers)e.headers={};if(!Hz(e.sensitiveHeaders))e.sensitiveHeaders=[];if(e.host){if(!e.hostname)e.hostname=e.host;delete e.host}if(!e.pathname&&e.path){var t=e.path.indexOf("?");if(t<0)e.pathname=e.path;else e.pathname=e.path.substring(0,t),e.search=e.path.substring(t)}};mt.prototype._performRequest=function(){var e=this._options.protocol,t=this._options.nativeProtocols[e];if(!t)throw TypeError("Unsupported protocol "+e);if(this._options.agents){var r=e.slice(0,-1);this._options.agent=this._options.agents[r]}var n=this._currentRequest=t.request(this._options,this._onNativeResponse);n._redirectable=this;for(var o of Hu)n.on(o,Vu[o]);if(this._currentUrl=/^\//.test(this._options.path)?ni.format(this._options):this._options.path,this._isRedirect){var i=0,s=this,a=this._requestBodyBuffers;(function c(u){if(n===s._currentRequest){if(u)s.emit("error",u);else if(i<a.length){var l=a[i++];if(!n.finished)n.write(l.data,l.encoding,c)}else if(s._ended)n.end()}})()}};mt.prototype._processResponse=function(e){var t=e.statusCode;if(this._options.trackRedirects)this._redirects.push({url:this._currentUrl,headers:e.headers,statusCode:t});var r=e.headers.location;if(!r||this._options.followRedirects===!1||t<300||t>=400){e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),this._requestBodyBuffers=[];return}if(Ju(this._currentRequest),e.destroy(),++this._redirectCount>this._options.maxRedirects)throw new Mz;var n,o=this._options.beforeRedirect;if(o)n=Object.assign({Host:e.req.getHeader("host")},this._options.headers);var i=this._options.method;if((t===301||t===302)&&this._options.method==="POST"||t===303&&!/^(?:GET|HEAD)$/.test(this._options.method))this._options.method="GET",this._requestBodyBuffers=[],Lu(/^content-/i,this._options.headers);var s=Lu(/^host$/i,this._options.headers),a=Gu(this._currentUrl),c=s||a.host,u=/^\w+:/.test(r)?this._currentUrl:ni.format(Object.assign(a,{host:c})),l=Zz(r,u);if(jx("redirecting to",l.href),this._isRedirect=!0,Uu(l,this._options),l.protocol!==a.protocol&&l.protocol!=="https:"||l.host!==c&&!Bz(l.host,c))Lu(this._headerFilter,this._options.headers);if(cn(o)){var p={headers:e.headers,statusCode:t},m={url:u,method:i,headers:n};o(this._options,p,m),this._sanitizeOptions(this._options)}this._performRequest()};function Nx(e){var t={maxRedirects:21,maxBodyLength:10485760},r={};return Object.keys(e).forEach(function(n){var o=n+":",i=r[o]=e[n],s=t[n]=Object.create(i);function a(u,l,p){if(Gz(u))u=Uu(u);else if(an(u))u=Uu(Gu(u));else p=l,l=Lx(u),u={protocol:o};if(cn(l))p=l,l=null;if(l=Object.assign({maxRedirects:t.maxRedirects,maxBodyLength:t.maxBodyLength},u,l),l.nativeProtocols=r,!an(l.host)&&!an(l.hostname))l.hostname="::1";return Zu.equal(l.protocol,o,"protocol mismatch"),jx("options",l),new mt(l,p)}function c(u,l,p){var m=s.request(u,l,p);return m.end(),m}Object.defineProperties(s,{request:{value:a,configurable:!0,enumerable:!0,writable:!0},get:{value:c,configurable:!0,enumerable:!0,writable:!0}})}),t}function Dx(){}function Gu(e){var t;if(Bu)t=new ri(e);else if(t=Lx(ni.parse(e)),!an(t.protocol))throw new Mu({input:e});return t}function Zz(e,t){return Bu?new ri(e,t):Gu(ni.resolve(t,e))}function Lx(e){if(/^\[/.test(e.hostname)&&!/^\[[:0-9a-f]+\]$/i.test(e.hostname))throw new Mu({input:e.href||e});if(/^\[/.test(e.host)&&!/^\[[:0-9a-f]+\](:\d+)?$/i.test(e.host))throw new Mu({input:e.href||e});return e}function Uu(e,t){var r=t||{};for(var n of Lz)r[n]=e[n];if(r.hostname.startsWith("["))r.hostname=r.hostname.slice(1,-1);if(r.port!=="")r.port=Number(r.port);return r.path=r.search?r.pathname+r.search:r.pathname,r}function Lu(e,t){var r;for(var n in t)if(e.test(n))r=t[n],delete t[n];return r===null||typeof r>"u"?void 0:String(r).trim()}function oi(e,t,r){function n(o){if(cn(Error.captureStackTrace))Error.captureStackTrace(this,this.constructor);Object.assign(this,o||{}),this.code=e,this.message=this.cause?t+": "+this.cause.message:t}return n.prototype=new(r||Error),Object.defineProperties(n.prototype,{constructor:{value:n,enumerable:!1},name:{value:"Error ["+e+"]",enumerable:!1}}),n}function Ju(e,t){for(var r of Hu)e.removeListener(r,Vu[r]);e.on("error",Dx),e.destroy(t)}function Bz(e,t){Zu(an(e)&&an(t));var r=e.length-t.length-1;return r>0&&e[r]==="."&&e.endsWith(t)}function Hz(e){return e instanceof Array}function an(e){return typeof e==="string"||e instanceof String}function cn(e){return typeof e==="function"}function Vz(e){return typeof e==="object"&&"length"in e}function Gz(e){return ri&&e instanceof ri}function Jz(e){return e.replace(/[\]\\/()*+?.$]/g,"\\$&")}Wu.exports=Nx({http:jz,https:Nz});Wu.exports.wrap=Nx});var Zi=_(function(E_){Object.defineProperty(E_,"__esModule",{value:!0});E_.regexpCode=E_.getEsmExportName=E_.getProperty=E_.safeStringify=E_.stringify=E_.strConcat=E_.addCodeArg=E_.str=E_._=E_.nil=E_._Code=E_.Name=E_.IDENTIFIER=E_._CodeOrName=void 0;class Ja{}E_._CodeOrName=Ja;E_.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class vo extends Ja{constructor(e){super();if(!E_.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}E_.Name=vo;class Wt extends Ja{constructor(e){super();this._items=typeof e==="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((t,r)=>`${t}${r}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((t,r)=>{if(r instanceof vo)t[r.str]=(t[r.str]||0)+1;return t},{})}}E_._Code=Wt;E_.nil=new Wt("");function $_(e,...t){let r=[e[0]],n=0;while(n<t.length)Gd(r,t[n]),r.push(e[++n]);return new Wt(r)}E_._=$_;var Vd=new Wt("+");function T_(e,...t){let r=[Fi(e[0])],n=0;while(n<t.length)r.push(Vd),Gd(r,t[n]),r.push(Vd,Fi(e[++n]));return rN(r),new Wt(r)}E_.str=T_;function Gd(e,t){if(t instanceof Wt)e.push(...t._items);else if(t instanceof vo)e.push(t);else e.push(iN(t))}E_.addCodeArg=Gd;function rN(e){let t=1;while(t<e.length-1){if(e[t]===Vd){let r=nN(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function nN(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string"){if(t instanceof vo||e[e.length-1]!=='"')return;if(typeof t!="string")return`${e.slice(0,-1)}${t}"`;if(t[0]==='"')return e.slice(0,-1)+t.slice(1);return}if(typeof t=="string"&&t[0]==='"'&&!(e instanceof vo))return`"${e}${t.slice(1)}`;return}function oN(e,t){return t.emptyStr()?e:e.emptyStr()?t:T_`${e}${t}`}E_.strConcat=oN;function iN(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:Fi(Array.isArray(e)?e.join(","):e)}function sN(e){return new Wt(Fi(e))}E_.stringify=sN;function Fi(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}E_.safeStringify=Fi;function aN(e){return typeof e=="string"&&E_.IDENTIFIER.test(e)?new Wt(`.${e}`):$_`[${e}]`}E_.getProperty=aN;function cN(e){if(typeof e=="string"&&E_.IDENTIFIER.test(e))return new Wt(`${e}`);throw Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}E_.getEsmExportName=cN;function uN(e){return new Wt(e.toString())}E_.regexpCode=uN});var Yd=_(function(O_){Object.defineProperty(O_,"__esModule",{value:!0});O_.ValueScope=O_.ValueScopeName=O_.Scope=O_.varKinds=O_.UsedValueState=void 0;var gt=Zi();class P_ extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`);this.value=e.value}}var Ka;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(Ka||(O_.UsedValueState=Ka={}));O_.varKinds={const:new gt.Name("const"),let:new gt.Name("let"),var:new gt.Name("var")};class Wd{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof gt.Name?e:this.name(e)}name(e){return new gt.Name(this._newName(e))}_newName(e){let t=this._names[e]||this._nameGroup(e);return`${e}${t.index++}`}_nameGroup(e){var t,r;if(((r=(t=this._parent)===null||t===void 0?void 0:t._prefixes)===null||r===void 0?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}O_.Scope=Wd;class Kd extends gt.Name{constructor(e,t){super(t);this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=gt._`.${new gt.Name(t)}[${r}]`}}O_.ValueScopeName=Kd;var wN=gt._`\n`;class z_ extends Wd{constructor(e){super(e);this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?wN:gt.nil}}get(){return this._scope}name(e){return new Kd(e,this._newName(e))}value(e,t){var r;if(t.ref===void 0)throw Error("CodeGen: ref must be passed in value");let n=this.toName(e),{prefix:o}=n,i=(r=t.key)!==null&&r!==void 0?r:t.ref,s=this._values[o];if(s){let u=s.get(i);if(u)return u}else s=this._values[o]=new Map;s.set(i,n);let a=this._scope[o]||(this._scope[o]=[]),c=a.length;return a[c]=t.ref,n.setValue(t,{property:o,itemIndex:c}),n}getValue(e,t){let r=this._values[e];if(!r)return;return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,(r)=>{if(r.scopePath===void 0)throw Error(`CodeGen: name "${r}" has no value`);return gt._`${e}${r.scopePath}`})}scopeCode(e=this._values,t,r){return this._reduceValues(e,(n)=>{if(n.value===void 0)throw Error(`CodeGen: name "${n}" has no value`);return n.value.code},t,r)}_reduceValues(e,t,r={},n){let o=gt.nil;for(let i in e){let s=e[i];if(!s)continue;let a=r[i]=r[i]||new Map;s.forEach((c)=>{if(a.has(c))return;a.set(c,Ka.Started);let u=t(c);if(u){let l=this.opts.es5?O_.varKinds.var:O_.varKinds.const;o=gt._`${o}${l} ${c} = ${u};${this.opts._n}`}else if(u=n===null||n===void 0?void 0:n(c))o=gt._`${o}${u}${this.opts._n}`;else throw new P_(c);a.set(c,Ka.Completed)})}return o}}O_.ValueScope=z_});var W=_(function(xt){Object.defineProperty(xt,"__esModule",{value:!0});xt.or=xt.and=xt.not=xt.CodeGen=xt.operators=xt.varKinds=xt.ValueScopeName=xt.ValueScope=xt.Scope=xt.Name=xt.regexpCode=xt.stringify=xt.getProperty=xt.nil=xt.strConcat=xt.str=xt._=void 0;var ie=Zi(),Kt=Yd(),Mr=Zi();Object.defineProperty(xt,"_",{enumerable:!0,get:function(){return Mr._}});Object.defineProperty(xt,"str",{enumerable:!0,get:function(){return Mr.str}});Object.defineProperty(xt,"strConcat",{enumerable:!0,get:function(){return Mr.strConcat}});Object.defineProperty(xt,"nil",{enumerable:!0,get:function(){return Mr.nil}});Object.defineProperty(xt,"getProperty",{enumerable:!0,get:function(){return Mr.getProperty}});Object.defineProperty(xt,"stringify",{enumerable:!0,get:function(){return Mr.stringify}});Object.defineProperty(xt,"regexpCode",{enumerable:!0,get:function(){return Mr.regexpCode}});Object.defineProperty(xt,"Name",{enumerable:!0,get:function(){return Mr.Name}});var rc=Yd();Object.defineProperty(xt,"Scope",{enumerable:!0,get:function(){return rc.Scope}});Object.defineProperty(xt,"ValueScope",{enumerable:!0,get:function(){return rc.ValueScope}});Object.defineProperty(xt,"ValueScopeName",{enumerable:!0,get:function(){return rc.ValueScopeName}});Object.defineProperty(xt,"varKinds",{enumerable:!0,get:function(){return rc.varKinds}});xt.operators={GT:new ie._Code(">"),GTE:new ie._Code(">="),LT:new ie._Code("<"),LTE:new ie._Code("<="),EQ:new ie._Code("==="),NEQ:new ie._Code("!=="),NOT:new ie._Code("!"),OR:new ie._Code("||"),AND:new ie._Code("&&"),ADD:new ie._Code("+")};class qr{optimizeNodes(){return this}optimizeNames(e,t){return this}}class C_ extends qr{constructor(e,t,r){super();this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){let r=e?Kt.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${r} ${this.name}${n};`+t}optimizeNames(e,t){if(!e[this.name.str])return;if(this.rhs)this.rhs=bo(this.rhs,e,t);return this}get names(){return this.rhs instanceof ie._CodeOrName?this.rhs.names:{}}}class em extends qr{constructor(e,t,r){super();this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(this.lhs instanceof ie.Name&&!e[this.lhs.str]&&!this.sideEffects)return;return this.rhs=bo(this.rhs,e,t),this}get names(){let e=this.lhs instanceof ie.Name?{}:{...this.lhs.names};return tc(e,this.rhs)}}class I_ extends em{constructor(e,t,r,n){super(e,r,n);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class j_ extends qr{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class N_ extends qr{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class D_ extends qr{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class L_ extends qr{constructor(e){super();this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=bo(this.code,e,t),this}get names(){return this.code instanceof ie._CodeOrName?this.code.names:{}}}class nc extends qr{constructor(e=[]){super();this.nodes=e}render(e){return this.nodes.reduce((t,r)=>t+r.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;while(t--){let r=e[t].optimizeNodes();if(Array.isArray(r))e.splice(t,1,...r);else if(r)e[t]=r;else e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:r}=this,n=r.length;while(n--){let o=r[n];if(o.optimizeNames(e,t))continue;TN(e,o.names),r.splice(n,1)}return r.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>wn(e,t.names),{})}}class Ur extends nc{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class M_ extends nc{}class Bi extends Ur{}Bi.kind="else";class hr extends Ur{constructor(e,t){super(t);this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);if(this.else)t+="else "+this.else.render(e);return t}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let t=this.else;if(t){let r=t.optimizeNodes();t=this.else=Array.isArray(r)?new Bi(r):r}if(t){if(e===!1)return t instanceof hr?t:t.nodes;if(this.nodes.length)return this;return new hr(B_(e),t instanceof hr?[t]:t.nodes)}if(e===!1||!this.nodes.length)return;return this}optimizeNames(e,t){var r;if(this.else=(r=this.else)===null||r===void 0?void 0:r.optimizeNames(e,t),!(super.optimizeNames(e,t)||this.else))return;return this.condition=bo(this.condition,e,t),this}get names(){let e=super.names;if(tc(e,this.condition),this.else)wn(e,this.else.names);return e}}hr.kind="if";class yo extends Ur{}yo.kind="for";class q_ extends yo{constructor(e){super();this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iteration=bo(this.iteration,e,t),this}get names(){return wn(super.names,this.iteration.names)}}class U_ extends yo{constructor(e,t,r,n){super();this.varKind=e,this.name=t,this.from=r,this.to=n}render(e){let t=e.es5?Kt.varKinds.var:this.varKind,{name:r,from:n,to:o}=this;return`for(${t} ${r}=${n}; ${r}<${o}; ${r}++)`+super.render(e)}get names(){let e=tc(super.names,this.from);return tc(e,this.to)}}class Xd extends yo{constructor(e,t,r,n){super();this.loop=e,this.varKind=t,this.name=r,this.iterable=n}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iterable=bo(this.iterable,e,t),this}get names(){return wn(super.names,this.iterable.names)}}class Ya extends Ur{constructor(e,t,r){super();this.name=e,this.args=t,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}Ya.kind="func";class Xa extends nc{render(e){return"return "+super.render(e)}}Xa.kind="return";class F_ extends Ur{render(e){let t="try"+super.render(e);if(this.catch)t+=this.catch.render(e);if(this.finally)t+=this.finally.render(e);return t}optimizeNodes(){var e,t;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(e,t){var r,n;return super.optimizeNames(e,t),(r=this.catch)===null||r===void 0||r.optimizeNames(e,t),(n=this.finally)===null||n===void 0||n.optimizeNames(e,t),this}get names(){let e=super.names;if(this.catch)wn(e,this.catch.names);if(this.finally)wn(e,this.finally.names);return e}}class Qa extends Ur{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}Qa.kind="catch";class ec extends Ur{render(e){return"finally"+super.render(e)}}ec.kind="finally";class Z_{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?`
|
|
20
|
-
`:""},this._extScope=e,this._scope=new Kt.Scope({parent:e}),this._nodes=[new M_]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){let r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,r,n){let o=this._scope.toName(t);if(r!==void 0&&n)this._constants[o.str]=r;return this._leafNode(new C_(e,o,r)),o}const(e,t,r){return this._def(Kt.varKinds.const,e,t,r)}let(e,t,r){return this._def(Kt.varKinds.let,e,t,r)}var(e,t,r){return this._def(Kt.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new em(e,t,r))}add(e,t){return this._leafNode(new I_(e,xt.operators.ADD,t))}code(e){if(typeof e=="function")e();else if(e!==ie.nil)this._leafNode(new L_(e));return this}object(...e){let t=["{"];for(let[r,n]of e){if(t.length>1)t.push(",");if(t.push(r),r!==n||this.opts.es5)t.push(":"),(0,ie.addCodeArg)(t,n)}return t.push("}"),new ie._Code(t)}if(e,t,r){if(this._blockNode(new hr(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new hr(e))}else(){return this._elseNode(new Bi)}endIf(){return this._endBlockNode(hr,Bi)}_for(e,t){if(this._blockNode(e),t)this.code(t).endFor();return this}for(e,t){return this._for(new q_(e),t)}forRange(e,t,r,n,o=this.opts.es5?Kt.varKinds.var:Kt.varKinds.let){let i=this._scope.toName(e);return this._for(new U_(o,i,t,r),()=>n(i))}forOf(e,t,r,n=Kt.varKinds.const){let o=this._scope.toName(e);if(this.opts.es5){let i=t instanceof ie.Name?t:this.var("_arr",t);return this.forRange("_i",0,ie._`${i}.length`,(s)=>{this.var(o,ie._`${i}[${s}]`),r(o)})}return this._for(new Xd("of",n,o,t),()=>r(o))}forIn(e,t,r,n=this.opts.es5?Kt.varKinds.var:Kt.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,ie._`Object.keys(${t})`,r);let o=this._scope.toName(e);return this._for(new Xd("in",n,o,t),()=>r(o))}endFor(){return this._endBlockNode(yo)}label(e){return this._leafNode(new j_(e))}break(e){return this._leafNode(new N_(e))}return(e){let t=new Xa;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(Xa)}try(e,t,r){if(!t&&!r)throw Error('CodeGen: "try" without "catch" and "finally"');let n=new F_;if(this._blockNode(n),this.code(e),t){let o=this.name("e");this._currNode=n.catch=new Qa(o),t(o)}if(r)this._currNode=n.finally=new ec,this.code(r);return this._endBlockNode(Qa,ec)}throw(e){return this._leafNode(new D_(e))}block(e,t){if(this._blockStarts.push(this._nodes.length),e)this.code(e).endBlock(t);return this}endBlock(e){let t=this._blockStarts.pop();if(t===void 0)throw Error("CodeGen: not in self-balancing block");let r=this._nodes.length-t;if(r<0||e!==void 0&&r!==e)throw Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=ie.nil,r,n){if(this._blockNode(new Ya(e,t,r)),n)this.code(n).endFunc();return this}endFunc(){return this._endBlockNode(Ya)}optimize(e=1){while(e-- >0)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){let r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof hr))throw Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let t=this._nodes;t[t.length-1]=e}}xt.CodeGen=Z_;function wn(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function tc(e,t){return t instanceof ie._CodeOrName?wn(e,t.names):e}function bo(e,t,r){if(e instanceof ie.Name)return n(e);if(!o(e))return e;return new ie._Code(e._items.reduce((i,s)=>{if(s instanceof ie.Name)s=n(s);if(s instanceof ie._Code)i.push(...s._items);else i.push(s);return i},[]));function n(i){let s=r[i.str];if(s===void 0||t[i.str]!==1)return i;return delete t[i.str],s}function o(i){return i instanceof ie._Code&&i._items.some((s)=>s instanceof ie.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function TN(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function B_(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:ie._`!${Qd(e)}`}xt.not=B_;var EN=H_(xt.operators.AND);function RN(...e){return e.reduce(EN)}xt.and=RN;var PN=H_(xt.operators.OR);function zN(...e){return e.reduce(PN)}xt.or=zN;function H_(e){return(t,r)=>t===ie.nil?r:r===ie.nil?t:ie._`${Qd(t)} ${e} ${Qd(r)}`}function Qd(e){return e instanceof ie.Name?e:ie._`(${e})`}});var ae=_(function(ew){Object.defineProperty(ew,"__esModule",{value:!0});ew.checkStrictMode=ew.getErrorPath=ew.Type=ew.useFunc=ew.setEvaluated=ew.evaluatedPropsToName=ew.mergeEvaluated=ew.eachItem=ew.unescapeJsonPointer=ew.escapeJsonPointer=ew.escapeFragment=ew.unescapeFragment=ew.schemaRefOrVal=ew.schemaHasRulesButRef=ew.schemaHasRules=ew.checkUnknownRules=ew.alwaysValidSchema=ew.toHash=void 0;var xe=W(),IN=Zi();function jN(e){let t={};for(let r of e)t[r]=!0;return t}ew.toHash=jN;function NN(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return!0;return W_(e,t),!K_(t,e.self.RULES.all)}ew.alwaysValidSchema=NN;function W_(e,t=e.schema){let{opts:r,self:n}=e;if(!r.strictSchema)return;if(typeof t==="boolean")return;let o=n.RULES.keywords;for(let i in t)if(!o[i])Q_(e,`unknown keyword: "${i}"`)}ew.checkUnknownRules=W_;function K_(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}ew.schemaHasRules=K_;function DN(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}ew.schemaHasRulesButRef=DN;function LN({topSchemaRef:e,schemaPath:t},r,n,o){if(!o){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return xe._`${r}`}return xe._`${e}${t}${(0,xe.getProperty)(n)}`}ew.schemaRefOrVal=LN;function MN(e){return Y_(decodeURIComponent(e))}ew.unescapeFragment=MN;function qN(e){return encodeURIComponent(rm(e))}ew.escapeFragment=qN;function rm(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}ew.escapeJsonPointer=rm;function Y_(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}ew.unescapeJsonPointer=Y_;function UN(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}ew.eachItem=UN;function G_({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:n}){return(o,i,s,a)=>{let c=s===void 0?i:s instanceof xe.Name?(i instanceof xe.Name?e(o,i,s):t(o,i,s),s):i instanceof xe.Name?(t(o,s,i),i):r(i,s);return a===xe.Name&&!(c instanceof xe.Name)?n(o,c):c}}ew.mergeEvaluated={props:G_({mergeNames:(e,t,r)=>e.if(xe._`${r} !== true && ${t} !== undefined`,()=>{e.if(xe._`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,xe._`${r} || {}`).code(xe._`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if(xe._`${r} !== true`,()=>{if(t===!0)e.assign(r,!0);else e.assign(r,xe._`${r} || {}`),nm(e,r,t)}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:X_}),items:G_({mergeNames:(e,t,r)=>e.if(xe._`${r} !== true && ${t} !== undefined`,()=>e.assign(r,xe._`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if(xe._`${r} !== true`,()=>e.assign(r,t===!0?!0:xe._`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function X_(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",xe._`{}`);if(t!==void 0)nm(e,r,t);return r}ew.evaluatedPropsToName=X_;function nm(e,t,r){Object.keys(r).forEach((n)=>e.assign(xe._`${t}${(0,xe.getProperty)(n)}`,!0))}ew.setEvaluated=nm;var J_={};function FN(e,t){return e.scopeValue("func",{ref:t,code:J_[t.code]||(J_[t.code]=new IN._Code(t.code))})}ew.useFunc=FN;var tm;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(tm||(ew.Type=tm={}));function ZN(e,t,r){if(e instanceof xe.Name){let n=t===tm.Num;return r?n?xe._`"[" + ${e} + "]"`:xe._`"['" + ${e} + "']"`:n?xe._`"/" + ${e}`:xe._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,xe.getProperty)(e).toString():"/"+rm(e)}ew.getErrorPath=ZN;function Q_(e,t,r=e.opts.strictSchema){if(!r)return;if(t=`strict mode: ${t}`,r===!0)throw Error(t);e.self.logger.warn(t)}ew.checkStrictMode=Q_});var gr=_(function(rw){Object.defineProperty(rw,"__esModule",{value:!0});var it=W(),aD={data:new it.Name("data"),valCxt:new it.Name("valCxt"),instancePath:new it.Name("instancePath"),parentData:new it.Name("parentData"),parentDataProperty:new it.Name("parentDataProperty"),rootData:new it.Name("rootData"),dynamicAnchors:new it.Name("dynamicAnchors"),vErrors:new it.Name("vErrors"),errors:new it.Name("errors"),this:new it.Name("this"),self:new it.Name("self"),scope:new it.Name("scope"),json:new it.Name("json"),jsonPos:new it.Name("jsonPos"),jsonLen:new it.Name("jsonLen"),jsonPart:new it.Name("jsonPart")};rw.default=aD});var Hi=_(function(sw){Object.defineProperty(sw,"__esModule",{value:!0});sw.extendErrors=sw.resetErrorsCount=sw.reportExtraError=sw.reportError=sw.keyword$DataError=sw.keywordError=void 0;var ce=W(),ic=ae(),ct=gr();sw.keywordError={message:({keyword:e})=>ce.str`must pass "${e}" keyword validation`};sw.keyword$DataError={message:({keyword:e,schemaType:t})=>t?ce.str`"${e}" keyword must be ${t} ($data)`:ce.str`"${e}" keyword is invalid ($data)`};function uD(e,t=sw.keywordError,r,n){let{it:o}=e,{gen:i,compositeRule:s,allErrors:a}=o,c=iw(e,t,r);if(n!==null&&n!==void 0?n:s||a)nw(i,c);else ow(o,ce._`[${c}]`)}sw.reportError=uD;function lD(e,t=sw.keywordError,r){let{it:n}=e,{gen:o,compositeRule:i,allErrors:s}=n,a=iw(e,t,r);if(nw(o,a),!(i||s))ow(n,ct.default.vErrors)}sw.reportExtraError=lD;function pD(e,t){e.assign(ct.default.errors,t),e.if(ce._`${ct.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(ce._`${ct.default.vErrors}.length`,t),()=>e.assign(ct.default.vErrors,null)))}sw.resetErrorsCount=pD;function dD({gen:e,keyword:t,schemaValue:r,data:n,errsCount:o,it:i}){if(o===void 0)throw Error("ajv implementation error");let s=e.name("err");e.forRange("i",o,ct.default.errors,(a)=>{if(e.const(s,ce._`${ct.default.vErrors}[${a}]`),e.if(ce._`${s}.instancePath === undefined`,()=>e.assign(ce._`${s}.instancePath`,(0,ce.strConcat)(ct.default.instancePath,i.errorPath))),e.assign(ce._`${s}.schemaPath`,ce.str`${i.errSchemaPath}/${t}`),i.opts.verbose)e.assign(ce._`${s}.schema`,r),e.assign(ce._`${s}.data`,n)})}sw.extendErrors=dD;function nw(e,t){let r=e.const("err",t);e.if(ce._`${ct.default.vErrors} === null`,()=>e.assign(ct.default.vErrors,ce._`[${r}]`),ce._`${ct.default.vErrors}.push(${r})`),e.code(ce._`${ct.default.errors}++`)}function ow(e,t){let{gen:r,validateName:n,schemaEnv:o}=e;if(o.$async)r.throw(ce._`new ${e.ValidationError}(${t})`);else r.assign(ce._`${n}.errors`,t),r.return(!1)}var kn={keyword:new ce.Name("keyword"),schemaPath:new ce.Name("schemaPath"),params:new ce.Name("params"),propertyName:new ce.Name("propertyName"),message:new ce.Name("message"),schema:new ce.Name("schema"),parentSchema:new ce.Name("parentSchema")};function iw(e,t,r){let{createErrors:n}=e.it;if(n===!1)return ce._`{}`;return mD(e,t,r)}function mD(e,t,r={}){let{gen:n,it:o}=e,i=[fD(o,r),hD(e,r)];return gD(e,t,i),n.object(...i)}function fD({errorPath:e},{instancePath:t}){let r=t?ce.str`${e}${(0,ic.getErrorPath)(t,ic.Type.Str)}`:e;return[ct.default.instancePath,(0,ce.strConcat)(ct.default.instancePath,r)]}function hD({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:n}){let o=n?t:ce.str`${t}/${e}`;if(r)o=ce.str`${o}${(0,ic.getErrorPath)(r,ic.Type.Str)}`;return[kn.schemaPath,o]}function gD(e,{params:t,message:r},n){let{keyword:o,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:p}=a;if(n.push([kn.keyword,o],[kn.params,typeof t=="function"?t(e):t||ce._`{}`]),c.messages)n.push([kn.message,typeof r=="function"?r(e):r]);if(c.verbose)n.push([kn.schema,s],[kn.parentSchema,ce._`${l}${p}`],[ct.default.data,i]);if(u)n.push([kn.propertyName,u])}});var pw=_(function(uw){Object.defineProperty(uw,"__esModule",{value:!0});uw.boolOrEmptySchema=uw.topBoolOrEmptySchema=void 0;var _D=Hi(),wD=W(),kD=gr(),SD={message:"boolean schema is false"};function $D(e){let{gen:t,schema:r,validateName:n}=e;if(r===!1)cw(e,!1);else if(typeof r=="object"&&r.$async===!0)t.return(kD.default.data);else t.assign(wD._`${n}.errors`,null),t.return(!0)}uw.topBoolOrEmptySchema=$D;function TD(e,t){let{gen:r,schema:n}=e;if(n===!1)r.var(t,!1),cw(e);else r.var(t,!0)}uw.boolOrEmptySchema=TD;function cw(e,t){let{gen:r,data:n}=e,o={gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,_D.reportError)(o,SD,void 0,t)}});var im=_(function(dw){Object.defineProperty(dw,"__esModule",{value:!0});dw.getRules=dw.isJSONType=void 0;var RD=["string","number","integer","boolean","null","object","array"],PD=new Set(RD);function zD(e){return typeof e=="string"&&PD.has(e)}dw.isJSONType=zD;function OD(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}dw.getRules=OD});var sm=_(function(gw){Object.defineProperty(gw,"__esModule",{value:!0});gw.shouldUseRule=gw.shouldUseGroup=gw.schemaHasRulesForType=void 0;function CD({schema:e,self:t},r){let n=t.RULES.types[r];return n&&n!==!0&&fw(e,n)}gw.schemaHasRulesForType=CD;function fw(e,t){return t.rules.some((r)=>hw(e,r))}gw.shouldUseGroup=fw;function hw(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some((n)=>e[n]!==void 0))}gw.shouldUseRule=hw});var Vi=_(function(_w){Object.defineProperty(_w,"__esModule",{value:!0});_w.reportTypeError=_w.checkDataTypes=_w.checkDataType=_w.coerceAndCheckDataType=_w.getJSONTypes=_w.getSchemaTypes=_w.DataType=void 0;var ND=im(),DD=sm(),LD=Hi(),J=W(),vw=ae(),_o;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(_o||(_w.DataType=_o={}));function MD(e){let t=yw(e.type);if(t.includes("null")){if(e.nullable===!1)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw Error('"nullable" cannot be used without "type"');if(e.nullable===!0)t.push("null")}return t}_w.getSchemaTypes=MD;function yw(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(ND.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}_w.getJSONTypes=yw;function qD(e,t){let{gen:r,data:n,opts:o}=e,i=UD(t,o.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&(0,DD.schemaHasRulesForType)(e,t[0]));if(s){let a=cm(t,n,o.strictNumbers,_o.Wrong);r.if(a,()=>{if(i.length)FD(e,t,i);else um(e)})}return s}_w.coerceAndCheckDataType=qD;var bw=new Set(["string","number","integer","boolean","null"]);function UD(e,t){return t?e.filter((r)=>bw.has(r)||t==="array"&&r==="array"):[]}function FD(e,t,r){let{gen:n,data:o,opts:i}=e,s=n.let("dataType",J._`typeof ${o}`),a=n.let("coerced",J._`undefined`);if(i.coerceTypes==="array")n.if(J._`${s} == 'object' && Array.isArray(${o}) && ${o}.length == 1`,()=>n.assign(o,J._`${o}[0]`).assign(s,J._`typeof ${o}`).if(cm(t,o,i.strictNumbers),()=>n.assign(a,o)));n.if(J._`${a} !== undefined`);for(let u of r)if(bw.has(u)||u==="array"&&i.coerceTypes==="array")c(u);n.else(),um(e),n.endIf(),n.if(J._`${a} !== undefined`,()=>{n.assign(o,a),ZD(e,a)});function c(u){switch(u){case"string":n.elseIf(J._`${s} == "number" || ${s} == "boolean"`).assign(a,J._`"" + ${o}`).elseIf(J._`${o} === null`).assign(a,J._`""`);return;case"number":n.elseIf(J._`${s} == "boolean" || ${o} === null
|
|
15
|
+
`)===-1){qo("have not received end of HTTP headers yet..."),i();return}let h=m.toString("ascii",0,m.indexOf(`\r
|
|
16
|
+
`)),x=+h.split(" ")[1];qo("got proxy server response: %o",h),t({statusCode:x,buffered:m})}e.on("error",u),e.on("close",a),e.on("end",c),i()})}Uo.default=iP});var vx=b(function(nn){var sP=nn&&nn.__awaiter||function(e,t,r,n){function o(i){return i instanceof r?i:new r(function(s){s(i)})}return new(r||(r=Promise))(function(i,s){function a(l){try{u(n.next(l))}catch(p){s(p)}}function c(l){try{u(n.throw(l))}catch(p){s(p)}}function u(l){l.done?i(l.value):o(l.value).then(a,c)}u((n=n.apply(e,t||[])).next())})},qn=nn&&nn.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(nn,"__esModule",{value:!0});var hx=qn(ge("net")),gx=qn(ge("tls")),aP=qn(ge("url")),cP=qn(ge("assert")),uP=qn(Mo()),lP=mx(),pP=qn(fx()),Fo=uP.default("https-proxy-agent:agent");class xx extends lP.Agent{constructor(e){let t;if(typeof e==="string")t=aP.default.parse(e);else t=e;if(!t)throw Error("an HTTP(S) proxy server `host` and `port` must be specified!");Fo("creating new HttpsProxyAgent instance: %o",t);super(t);let r=Object.assign({},t);if(this.secureProxy=t.secureProxy||fP(r.protocol),r.host=r.hostname||r.host,typeof r.port==="string")r.port=parseInt(r.port,10);if(!r.port&&r.host)r.port=this.secureProxy?443:80;if(this.secureProxy&&!("ALPNProtocols"in r))r.ALPNProtocols=["http 1.1"];if(r.host&&r.path)delete r.path,delete r.pathname;this.proxy=r}callback(e,t){return sP(this,void 0,void 0,function*(){let{proxy:r,secureProxy:n}=this,o;if(n)Fo("Creating `tls.Socket`: %o",r),o=gx.default.connect(r);else Fo("Creating `net.Socket`: %o",r),o=hx.default.connect(r);let i=Object.assign({},r.headers),a=`CONNECT ${`${t.host}:${t.port}`} HTTP/1.1\r
|
|
17
|
+
`;if(r.auth)i["Proxy-Authorization"]=`Basic ${Buffer.from(r.auth).toString("base64")}`;let{host:c,port:u,secureEndpoint:l}=t;if(!mP(u,l))c+=`:${u}`;i.Host=c,i.Connection="close";for(let x of Object.keys(i))a+=`${x}: ${i[x]}\r
|
|
18
|
+
`;let p=pP.default(o);o.write(`${a}\r
|
|
19
|
+
`);let{statusCode:m,buffered:d}=yield p;if(m===200){if(e.once("socket",dP),t.secureEndpoint){Fo("Upgrading socket connection to TLS");let x=t.servername||t.host;return gx.default.connect(Object.assign(Object.assign({},hP(t,"host","hostname","path","port")),{socket:o,servername:x}))}return o}o.destroy();let h=new hx.default.Socket({writable:!1});return h.readable=!0,e.once("socket",(x)=>{Fo("replaying proxy buffer for failed request"),cP.default(x.listenerCount("data")>0),x.push(d),x.push(null)}),h})}}nn.default=xx;function dP(e){e.resume()}function mP(e,t){return Boolean(!t&&e===80||t&&e===443)}function fP(e){return typeof e==="string"?/^https:?$/i.test(e):!1}function hP(e,...t){let r={},n;for(n in e)if(!t.includes(n))r[n]=e[n];return r}});var bx=b(function(Iu,yx){var gP=Iu&&Iu.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},Au=gP(vx());function Cu(e){return new Au.default(e)}(function(e){e.HttpsProxyAgent=Au.default,e.prototype=Au.default.prototype})(Cu||(Cu={}));yx.exports=Cu});var wx=b(function(K9,_x){var Zo;_x.exports=function(){if(!Zo){try{Zo=Mo()("follow-redirects")}catch(e){}if(typeof Zo!=="function")Zo=function(){}}Zo.apply(null,arguments)}});var Ex=b(function(Y9,Vu){var Ho=ge("url"),Bo=Ho.URL,xP=ge("http"),vP=ge("https"),Lu=ge("stream").Writable,qu=ge("assert"),kx=wx();(function(){var t=typeof process<"u",r=typeof window<"u"&&typeof document<"u",n=sn(Error.captureStackTrace);if(!t&&(r||!n))console.warn("The follow-redirects package should be excluded from browser builds.")})();var Uu=!1;try{qu(new Bo(""))}catch(e){Uu=e.code==="ERR_INVALID_URL"}var yP=["Authorization","Proxy-Authorization","Cookie"],bP=["auth","host","hostname","href","path","pathname","port","protocol","query","search","hash"],Fu=["abort","aborted","connect","error","socket","timeout"],Zu=Object.create(null);Fu.forEach(function(e){Zu[e]=function(t,r,n){this._redirectable.emit(e,t,r,n)}});var Nu=Vo("ERR_INVALID_URL","Invalid URL",TypeError),Du=Vo("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),_P=Vo("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded",Du),wP=Vo("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),kP=Vo("ERR_STREAM_WRITE_AFTER_END","write after end"),SP=Lu.prototype.destroy||$x;function ht(e,t){if(Lu.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],t)this.on("response",t);var r=this;this._onNativeResponse=function(n){try{r._processResponse(n)}catch(o){r.emit("error",o instanceof Du?o:new Du({cause:o}))}},this._headerFilter=new RegExp("^(?:"+yP.concat(e.sensitiveHeaders).map(zP).join("|")+")$","i"),this._performRequest()}ht.prototype=Object.create(Lu.prototype);ht.prototype.abort=function(){Hu(this._currentRequest),this._currentRequest.abort(),this.emit("abort")};ht.prototype.destroy=function(e){return Hu(this._currentRequest,e),SP.call(this,e),this};ht.prototype.write=function(e,t,r){if(this._ending)throw new kP;if(!on(e)&&!RP(e))throw TypeError("data should be a string, Buffer or Uint8Array");if(sn(t))r=t,t=null;if(e.length===0){if(r)r();return}if(this._requestBodyLength+e.length<=this._options.maxBodyLength)this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:t}),this._currentRequest.write(e,t,r);else this.emit("error",new wP),this.abort()};ht.prototype.end=function(e,t,r){if(sn(e))r=e,e=t=null;else if(sn(t))r=t,t=null;if(!e)this._ended=this._ending=!0,this._currentRequest.end(null,null,r);else{var n=this,o=this._currentRequest;this.write(e,t,function(){n._ended=!0,o.end(null,null,r)}),this._ending=!0}};ht.prototype.setHeader=function(e,t){this._options.headers[e]=t,this._currentRequest.setHeader(e,t)};ht.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)};ht.prototype.setTimeout=function(e,t){var r=this;function n(s){s.setTimeout(e),s.removeListener("timeout",s.destroy),s.addListener("timeout",s.destroy)}function o(s){if(r._timeout)clearTimeout(r._timeout);r._timeout=setTimeout(function(){r.emit("timeout"),i()},e),n(s)}function i(){if(r._timeout)clearTimeout(r._timeout),r._timeout=null;if(r.removeListener("abort",i),r.removeListener("error",i),r.removeListener("response",i),r.removeListener("close",i),t)r.removeListener("timeout",t);if(!r.socket)r._currentRequest.removeListener("socket",o)}if(t)this.on("timeout",t);if(this.socket)o(this.socket);else this._currentRequest.once("socket",o);return this.on("socket",n),this.on("abort",i),this.on("error",i),this.on("response",i),this.on("close",i),this};["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach(function(e){ht.prototype[e]=function(t,r){return this._currentRequest[e](t,r)}});["aborted","connection","socket"].forEach(function(e){Object.defineProperty(ht.prototype,e,{get:function(){return this._currentRequest[e]}})});ht.prototype._sanitizeOptions=function(e){if(!e.headers)e.headers={};if(!EP(e.sensitiveHeaders))e.sensitiveHeaders=[];if(e.host){if(!e.hostname)e.hostname=e.host;delete e.host}if(!e.pathname&&e.path){var t=e.path.indexOf("?");if(t<0)e.pathname=e.path;else e.pathname=e.path.substring(0,t),e.search=e.path.substring(t)}};ht.prototype._performRequest=function(){var e=this._options.protocol,t=this._options.nativeProtocols[e];if(!t)throw TypeError("Unsupported protocol "+e);if(this._options.agents){var r=e.slice(0,-1);this._options.agent=this._options.agents[r]}var n=this._currentRequest=t.request(this._options,this._onNativeResponse);n._redirectable=this;for(var o of Fu)n.on(o,Zu[o]);if(this._currentUrl=/^\//.test(this._options.path)?Ho.format(this._options):this._options.path,this._isRedirect){var i=0,s=this,a=this._requestBodyBuffers;(function c(u){if(n===s._currentRequest){if(u)s.emit("error",u);else if(i<a.length){var l=a[i++];if(!n.finished)n.write(l.data,l.encoding,c)}else if(s._ended)n.end()}})()}};ht.prototype._processResponse=function(e){var t=e.statusCode;if(this._options.trackRedirects)this._redirects.push({url:this._currentUrl,headers:e.headers,statusCode:t});var r=e.headers.location;if(!r||this._options.followRedirects===!1||t<300||t>=400){e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),this._requestBodyBuffers=[];return}if(Hu(this._currentRequest),e.destroy(),++this._redirectCount>this._options.maxRedirects)throw new _P;var n,o=this._options.beforeRedirect;if(o)n=Object.assign({Host:e.req.getHeader("host")},this._options.headers);var i=this._options.method;if((t===301||t===302)&&this._options.method==="POST"||t===303&&!/^(?:GET|HEAD)$/.test(this._options.method))this._options.method="GET",this._requestBodyBuffers=[],ju(/^content-/i,this._options.headers);var s=ju(/^host$/i,this._options.headers),a=Bu(this._currentUrl),c=s||a.host,u=/^\w+:/.test(r)?this._currentUrl:Ho.format(Object.assign(a,{host:c})),l=$P(r,u);if(kx("redirecting to",l.href),this._isRedirect=!0,Mu(l,this._options),l.protocol!==a.protocol&&l.protocol!=="https:"||l.host!==c&&!TP(l.host,c))ju(this._headerFilter,this._options.headers);if(sn(o)){var p={headers:e.headers,statusCode:t},m={url:u,method:i,headers:n};o(this._options,p,m),this._sanitizeOptions(this._options)}this._performRequest()};function Sx(e){var t={maxRedirects:21,maxBodyLength:10485760},r={};return Object.keys(e).forEach(function(n){var o=n+":",i=r[o]=e[n],s=t[n]=Object.create(i);function a(u,l,p){if(PP(u))u=Mu(u);else if(on(u))u=Mu(Bu(u));else p=l,l=Tx(u),u={protocol:o};if(sn(l))p=l,l=null;if(l=Object.assign({maxRedirects:t.maxRedirects,maxBodyLength:t.maxBodyLength},u,l),l.nativeProtocols=r,!on(l.host)&&!on(l.hostname))l.hostname="::1";return qu.equal(l.protocol,o,"protocol mismatch"),kx("options",l),new ht(l,p)}function c(u,l,p){var m=s.request(u,l,p);return m.end(),m}Object.defineProperties(s,{request:{value:a,configurable:!0,enumerable:!0,writable:!0},get:{value:c,configurable:!0,enumerable:!0,writable:!0}})}),t}function $x(){}function Bu(e){var t;if(Uu)t=new Bo(e);else if(t=Tx(Ho.parse(e)),!on(t.protocol))throw new Nu({input:e});return t}function $P(e,t){return Uu?new Bo(e,t):Bu(Ho.resolve(t,e))}function Tx(e){if(/^\[/.test(e.hostname)&&!/^\[[:0-9a-f]+\]$/i.test(e.hostname))throw new Nu({input:e.href||e});if(/^\[/.test(e.host)&&!/^\[[:0-9a-f]+\](:\d+)?$/i.test(e.host))throw new Nu({input:e.href||e});return e}function Mu(e,t){var r=t||{};for(var n of bP)r[n]=e[n];if(r.hostname.startsWith("["))r.hostname=r.hostname.slice(1,-1);if(r.port!=="")r.port=Number(r.port);return r.path=r.search?r.pathname+r.search:r.pathname,r}function ju(e,t){var r;for(var n in t)if(e.test(n))r=t[n],delete t[n];return r===null||typeof r>"u"?void 0:String(r).trim()}function Vo(e,t,r){function n(o){if(sn(Error.captureStackTrace))Error.captureStackTrace(this,this.constructor);Object.assign(this,o||{}),this.code=e,this.message=this.cause?t+": "+this.cause.message:t}return n.prototype=new(r||Error),Object.defineProperties(n.prototype,{constructor:{value:n,enumerable:!1},name:{value:"Error ["+e+"]",enumerable:!1}}),n}function Hu(e,t){for(var r of Fu)e.removeListener(r,Zu[r]);e.on("error",$x),e.destroy(t)}function TP(e,t){qu(on(e)&&on(t));var r=e.length-t.length-1;return r>0&&e[r]==="."&&e.endsWith(t)}function EP(e){return e instanceof Array}function on(e){return typeof e==="string"||e instanceof String}function sn(e){return typeof e==="function"}function RP(e){return typeof e==="object"&&"length"in e}function PP(e){return Bo&&e instanceof Bo}function zP(e){return e.replace(/[\]\\/()*+?.$]/g,"\\$&")}Vu.exports=Sx({http:xP,https:vP});Vu.exports.wrap=Sx});var ji=b(function(l_){Object.defineProperty(l_,"__esModule",{value:!0});l_.regexpCode=l_.getEsmExportName=l_.getProperty=l_.safeStringify=l_.stringify=l_.strConcat=l_.addCodeArg=l_.str=l_._=l_.nil=l_._Code=l_.Name=l_.IDENTIFIER=l_._CodeOrName=void 0;class Ba{}l_._CodeOrName=Ba;l_.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class io extends Ba{constructor(e){super();if(!l_.IDENTIFIER.test(e))throw Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}l_.Name=io;class Wt extends Ba{constructor(e){super();this._items=typeof e==="string"?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let e=this._items[0];return e===""||e==='""'}get str(){var e;return(e=this._str)!==null&&e!==void 0?e:this._str=this._items.reduce((t,r)=>`${t}${r}`,"")}get names(){var e;return(e=this._names)!==null&&e!==void 0?e:this._names=this._items.reduce((t,r)=>{if(r instanceof io)t[r.str]=(t[r.str]||0)+1;return t},{})}}l_._Code=Wt;l_.nil=new Wt("");function c_(e,...t){let r=[e[0]],n=0;while(n<t.length)Ld(r,t[n]),r.push(e[++n]);return new Wt(r)}l_._=c_;var Md=new Wt("+");function u_(e,...t){let r=[Ii(e[0])],n=0;while(n<t.length)r.push(Md),Ld(r,t[n]),r.push(Md,Ii(e[++n]));return VI(r),new Wt(r)}l_.str=u_;function Ld(e,t){if(t instanceof Wt)e.push(...t._items);else if(t instanceof io)e.push(t);else e.push(WI(t))}l_.addCodeArg=Ld;function VI(e){let t=1;while(t<e.length-1){if(e[t]===Md){let r=GI(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function GI(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string"){if(t instanceof io||e[e.length-1]!=='"')return;if(typeof t!="string")return`${e.slice(0,-1)}${t}"`;if(t[0]==='"')return e.slice(0,-1)+t.slice(1);return}if(typeof t=="string"&&t[0]==='"'&&!(e instanceof io))return`"${e}${t.slice(1)}`;return}function JI(e,t){return t.emptyStr()?e:e.emptyStr()?t:u_`${e}${t}`}l_.strConcat=JI;function WI(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:Ii(Array.isArray(e)?e.join(","):e)}function KI(e){return new Wt(Ii(e))}l_.stringify=KI;function Ii(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}l_.safeStringify=Ii;function YI(e){return typeof e=="string"&&l_.IDENTIFIER.test(e)?new Wt(`.${e}`):c_`[${e}]`}l_.getProperty=YI;function XI(e){if(typeof e=="string"&&l_.IDENTIFIER.test(e))return new Wt(`${e}`);throw Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}l_.getEsmExportName=XI;function QI(e){return new Wt(e.toString())}l_.regexpCode=QI});var Zd=b(function(f_){Object.defineProperty(f_,"__esModule",{value:!0});f_.ValueScope=f_.ValueScopeName=f_.Scope=f_.varKinds=f_.UsedValueState=void 0;var xt=ji();class d_ extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`);this.value=e.value}}var Va;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(Va||(f_.UsedValueState=Va={}));f_.varKinds={const:new xt.Name("const"),let:new xt.Name("let"),var:new xt.Name("var")};class Ud{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof xt.Name?e:this.name(e)}name(e){return new xt.Name(this._newName(e))}_newName(e){let t=this._names[e]||this._nameGroup(e);return`${e}${t.index++}`}_nameGroup(e){var t,r;if(((r=(t=this._parent)===null||t===void 0?void 0:t._prefixes)===null||r===void 0?void 0:r.has(e))||this._prefixes&&!this._prefixes.has(e))throw Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}f_.Scope=Ud;class Fd extends xt.Name{constructor(e,t){super(t);this.prefix=e}setValue(e,{property:t,itemIndex:r}){this.value=e,this.scopePath=xt._`.${new xt.Name(t)}[${r}]`}}f_.ValueScopeName=Fd;var dj=xt._`\n`;class m_ extends Ud{constructor(e){super(e);this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?dj:xt.nil}}get(){return this._scope}name(e){return new Fd(e,this._newName(e))}value(e,t){var r;if(t.ref===void 0)throw Error("CodeGen: ref must be passed in value");let n=this.toName(e),{prefix:o}=n,i=(r=t.key)!==null&&r!==void 0?r:t.ref,s=this._values[o];if(s){let u=s.get(i);if(u)return u}else s=this._values[o]=new Map;s.set(i,n);let a=this._scope[o]||(this._scope[o]=[]),c=a.length;return a[c]=t.ref,n.setValue(t,{property:o,itemIndex:c}),n}getValue(e,t){let r=this._values[e];if(!r)return;return r.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,(r)=>{if(r.scopePath===void 0)throw Error(`CodeGen: name "${r}" has no value`);return xt._`${e}${r.scopePath}`})}scopeCode(e=this._values,t,r){return this._reduceValues(e,(n)=>{if(n.value===void 0)throw Error(`CodeGen: name "${n}" has no value`);return n.value.code},t,r)}_reduceValues(e,t,r={},n){let o=xt.nil;for(let i in e){let s=e[i];if(!s)continue;let a=r[i]=r[i]||new Map;s.forEach((c)=>{if(a.has(c))return;a.set(c,Va.Started);let u=t(c);if(u){let l=this.opts.es5?f_.varKinds.var:f_.varKinds.const;o=xt._`${o}${l} ${c} = ${u};${this.opts._n}`}else if(u=n===null||n===void 0?void 0:n(c))o=xt._`${o}${u}${this.opts._n}`;else throw new d_(c);a.set(c,Va.Completed)})}return o}}f_.ValueScope=m_});var W=b(function(vt){Object.defineProperty(vt,"__esModule",{value:!0});vt.or=vt.and=vt.not=vt.CodeGen=vt.operators=vt.varKinds=vt.ValueScopeName=vt.ValueScope=vt.Scope=vt.Name=vt.regexpCode=vt.stringify=vt.getProperty=vt.nil=vt.strConcat=vt.str=vt._=void 0;var oe=ji(),Kt=Zd(),Dr=ji();Object.defineProperty(vt,"_",{enumerable:!0,get:function(){return Dr._}});Object.defineProperty(vt,"str",{enumerable:!0,get:function(){return Dr.str}});Object.defineProperty(vt,"strConcat",{enumerable:!0,get:function(){return Dr.strConcat}});Object.defineProperty(vt,"nil",{enumerable:!0,get:function(){return Dr.nil}});Object.defineProperty(vt,"getProperty",{enumerable:!0,get:function(){return Dr.getProperty}});Object.defineProperty(vt,"stringify",{enumerable:!0,get:function(){return Dr.stringify}});Object.defineProperty(vt,"regexpCode",{enumerable:!0,get:function(){return Dr.regexpCode}});Object.defineProperty(vt,"Name",{enumerable:!0,get:function(){return Dr.Name}});var Xa=Zd();Object.defineProperty(vt,"Scope",{enumerable:!0,get:function(){return Xa.Scope}});Object.defineProperty(vt,"ValueScope",{enumerable:!0,get:function(){return Xa.ValueScope}});Object.defineProperty(vt,"ValueScopeName",{enumerable:!0,get:function(){return Xa.ValueScopeName}});Object.defineProperty(vt,"varKinds",{enumerable:!0,get:function(){return Xa.varKinds}});vt.operators={GT:new oe._Code(">"),GTE:new oe._Code(">="),LT:new oe._Code("<"),LTE:new oe._Code("<="),EQ:new oe._Code("==="),NEQ:new oe._Code("!=="),NOT:new oe._Code("!"),OR:new oe._Code("||"),AND:new oe._Code("&&"),ADD:new oe._Code("+")};class Mr{optimizeNodes(){return this}optimizeNames(e,t){return this}}class g_ extends Mr{constructor(e,t,r){super();this.varKind=e,this.name=t,this.rhs=r}render({es5:e,_n:t}){let r=e?Kt.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${r} ${this.name}${n};`+t}optimizeNames(e,t){if(!e[this.name.str])return;if(this.rhs)this.rhs=ao(this.rhs,e,t);return this}get names(){return this.rhs instanceof oe._CodeOrName?this.rhs.names:{}}}class Vd extends Mr{constructor(e,t,r){super();this.lhs=e,this.rhs=t,this.sideEffects=r}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(this.lhs instanceof oe.Name&&!e[this.lhs.str]&&!this.sideEffects)return;return this.rhs=ao(this.rhs,e,t),this}get names(){let e=this.lhs instanceof oe.Name?{}:{...this.lhs.names};return Ya(e,this.rhs)}}class x_ extends Vd{constructor(e,t,r,n){super(e,r,n);this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class v_ extends Mr{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class y_ extends Mr{constructor(e){super();this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class b_ extends Mr{constructor(e){super();this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class __ extends Mr{constructor(e){super();this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=ao(this.code,e,t),this}get names(){return this.code instanceof oe._CodeOrName?this.code.names:{}}}class Qa extends Mr{constructor(e=[]){super();this.nodes=e}render(e){return this.nodes.reduce((t,r)=>t+r.render(e),"")}optimizeNodes(){let{nodes:e}=this,t=e.length;while(t--){let r=e[t].optimizeNodes();if(Array.isArray(r))e.splice(t,1,...r);else if(r)e[t]=r;else e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){let{nodes:r}=this,n=r.length;while(n--){let o=r[n];if(o.optimizeNames(e,t))continue;gj(e,o.names),r.splice(n,1)}return r.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>xn(e,t.names),{})}}class Lr extends Qa{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class w_ extends Qa{}class Ni extends Lr{}Ni.kind="else";class vr extends Lr{constructor(e,t){super(t);this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);if(this.else)t+="else "+this.else.render(e);return t}optimizeNodes(){super.optimizeNodes();let e=this.condition;if(e===!0)return this.nodes;let t=this.else;if(t){let r=t.optimizeNodes();t=this.else=Array.isArray(r)?new Ni(r):r}if(t){if(e===!1)return t instanceof vr?t:t.nodes;if(this.nodes.length)return this;return new vr(E_(e),t instanceof vr?[t]:t.nodes)}if(e===!1||!this.nodes.length)return;return this}optimizeNames(e,t){var r;if(this.else=(r=this.else)===null||r===void 0?void 0:r.optimizeNames(e,t),!(super.optimizeNames(e,t)||this.else))return;return this.condition=ao(this.condition,e,t),this}get names(){let e=super.names;if(Ya(e,this.condition),this.else)xn(e,this.else.names);return e}}vr.kind="if";class so extends Lr{}so.kind="for";class k_ extends so{constructor(e){super();this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iteration=ao(this.iteration,e,t),this}get names(){return xn(super.names,this.iteration.names)}}class S_ extends so{constructor(e,t,r,n){super();this.varKind=e,this.name=t,this.from=r,this.to=n}render(e){let t=e.es5?Kt.varKinds.var:this.varKind,{name:r,from:n,to:o}=this;return`for(${t} ${r}=${n}; ${r}<${o}; ${r}++)`+super.render(e)}get names(){let e=Ya(super.names,this.from);return Ya(e,this.to)}}class Bd extends so{constructor(e,t,r,n){super();this.loop=e,this.varKind=t,this.name=r,this.iterable=n}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(!super.optimizeNames(e,t))return;return this.iterable=ao(this.iterable,e,t),this}get names(){return xn(super.names,this.iterable.names)}}class Ga extends Lr{constructor(e,t,r){super();this.name=e,this.args=t,this.async=r}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}Ga.kind="func";class Ja extends Qa{render(e){return"return "+super.render(e)}}Ja.kind="return";class $_ extends Lr{render(e){let t="try"+super.render(e);if(this.catch)t+=this.catch.render(e);if(this.finally)t+=this.finally.render(e);return t}optimizeNodes(){var e,t;return super.optimizeNodes(),(e=this.catch)===null||e===void 0||e.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(e,t){var r,n;return super.optimizeNames(e,t),(r=this.catch)===null||r===void 0||r.optimizeNames(e,t),(n=this.finally)===null||n===void 0||n.optimizeNames(e,t),this}get names(){let e=super.names;if(this.catch)xn(e,this.catch.names);if(this.finally)xn(e,this.finally.names);return e}}class Wa extends Lr{constructor(e){super();this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}Wa.kind="catch";class Ka extends Lr{render(e){return"finally"+super.render(e)}}Ka.kind="finally";class T_{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?`
|
|
20
|
+
`:""},this._extScope=e,this._scope=new Kt.Scope({parent:e}),this._nodes=[new w_]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){let r=this._extScope.value(e,t);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,r,n){let o=this._scope.toName(t);if(r!==void 0&&n)this._constants[o.str]=r;return this._leafNode(new g_(e,o,r)),o}const(e,t,r){return this._def(Kt.varKinds.const,e,t,r)}let(e,t,r){return this._def(Kt.varKinds.let,e,t,r)}var(e,t,r){return this._def(Kt.varKinds.var,e,t,r)}assign(e,t,r){return this._leafNode(new Vd(e,t,r))}add(e,t){return this._leafNode(new x_(e,vt.operators.ADD,t))}code(e){if(typeof e=="function")e();else if(e!==oe.nil)this._leafNode(new __(e));return this}object(...e){let t=["{"];for(let[r,n]of e){if(t.length>1)t.push(",");if(t.push(r),r!==n||this.opts.es5)t.push(":"),oe.addCodeArg(t,n)}return t.push("}"),new oe._Code(t)}if(e,t,r){if(this._blockNode(new vr(e)),t&&r)this.code(t).else().code(r).endIf();else if(t)this.code(t).endIf();else if(r)throw Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new vr(e))}else(){return this._elseNode(new Ni)}endIf(){return this._endBlockNode(vr,Ni)}_for(e,t){if(this._blockNode(e),t)this.code(t).endFor();return this}for(e,t){return this._for(new k_(e),t)}forRange(e,t,r,n,o=this.opts.es5?Kt.varKinds.var:Kt.varKinds.let){let i=this._scope.toName(e);return this._for(new S_(o,i,t,r),()=>n(i))}forOf(e,t,r,n=Kt.varKinds.const){let o=this._scope.toName(e);if(this.opts.es5){let i=t instanceof oe.Name?t:this.var("_arr",t);return this.forRange("_i",0,oe._`${i}.length`,(s)=>{this.var(o,oe._`${i}[${s}]`),r(o)})}return this._for(new Bd("of",n,o,t),()=>r(o))}forIn(e,t,r,n=this.opts.es5?Kt.varKinds.var:Kt.varKinds.const){if(this.opts.ownProperties)return this.forOf(e,oe._`Object.keys(${t})`,r);let o=this._scope.toName(e);return this._for(new Bd("in",n,o,t),()=>r(o))}endFor(){return this._endBlockNode(so)}label(e){return this._leafNode(new v_(e))}break(e){return this._leafNode(new y_(e))}return(e){let t=new Ja;if(this._blockNode(t),this.code(e),t.nodes.length!==1)throw Error('CodeGen: "return" should have one node');return this._endBlockNode(Ja)}try(e,t,r){if(!t&&!r)throw Error('CodeGen: "try" without "catch" and "finally"');let n=new $_;if(this._blockNode(n),this.code(e),t){let o=this.name("e");this._currNode=n.catch=new Wa(o),t(o)}if(r)this._currNode=n.finally=new Ka,this.code(r);return this._endBlockNode(Wa,Ka)}throw(e){return this._leafNode(new b_(e))}block(e,t){if(this._blockStarts.push(this._nodes.length),e)this.code(e).endBlock(t);return this}endBlock(e){let t=this._blockStarts.pop();if(t===void 0)throw Error("CodeGen: not in self-balancing block");let r=this._nodes.length-t;if(r<0||e!==void 0&&r!==e)throw Error(`CodeGen: wrong number of nodes: ${r} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=oe.nil,r,n){if(this._blockNode(new Ga(e,t,r)),n)this.code(n).endFunc();return this}endFunc(){return this._endBlockNode(Ga)}optimize(e=1){while(e-- >0)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){let r=this._currNode;if(r instanceof e||t&&r instanceof t)return this._nodes.pop(),this;throw Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){let t=this._currNode;if(!(t instanceof vr))throw Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){let e=this._nodes;return e[e.length-1]}set _currNode(e){let t=this._nodes;t[t.length-1]=e}}vt.CodeGen=T_;function xn(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function Ya(e,t){return t instanceof oe._CodeOrName?xn(e,t.names):e}function ao(e,t,r){if(e instanceof oe.Name)return n(e);if(!o(e))return e;return new oe._Code(e._items.reduce((i,s)=>{if(s instanceof oe.Name)s=n(s);if(s instanceof oe._Code)i.push(...s._items);else i.push(s);return i},[]));function n(i){let s=r[i.str];if(s===void 0||t[i.str]!==1)return i;return delete t[i.str],s}function o(i){return i instanceof oe._Code&&i._items.some((s)=>s instanceof oe.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function gj(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function E_(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:oe._`!${Hd(e)}`}vt.not=E_;var xj=R_(vt.operators.AND);function vj(...e){return e.reduce(xj)}vt.and=vj;var yj=R_(vt.operators.OR);function bj(...e){return e.reduce(yj)}vt.or=bj;function R_(e){return(t,r)=>t===oe.nil?r:r===oe.nil?t:oe._`${Hd(t)} ${e} ${Hd(r)}`}function Hd(e){return e instanceof oe.Name?e:oe._`(${e})`}});var se=b(function(D_){Object.defineProperty(D_,"__esModule",{value:!0});D_.checkStrictMode=D_.getErrorPath=D_.Type=D_.useFunc=D_.setEvaluated=D_.evaluatedPropsToName=D_.mergeEvaluated=D_.eachItem=D_.unescapeJsonPointer=D_.escapeJsonPointer=D_.escapeFragment=D_.unescapeFragment=D_.schemaRefOrVal=D_.schemaHasRulesButRef=D_.schemaHasRules=D_.checkUnknownRules=D_.alwaysValidSchema=D_.toHash=void 0;var ve=W(),Sj=ji();function $j(e){let t={};for(let r of e)t[r]=!0;return t}D_.toHash=$j;function Tj(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return!0;return A_(e,t),!C_(t,e.self.RULES.all)}D_.alwaysValidSchema=Tj;function A_(e,t=e.schema){let{opts:r,self:n}=e;if(!r.strictSchema)return;if(typeof t==="boolean")return;let o=n.RULES.keywords;for(let i in t)if(!o[i])N_(e,`unknown keyword: "${i}"`)}D_.checkUnknownRules=A_;function C_(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}D_.schemaHasRules=C_;function Ej(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}D_.schemaHasRulesButRef=Ej;function Rj({topSchemaRef:e,schemaPath:t},r,n,o){if(!o){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return ve._`${r}`}return ve._`${e}${t}${ve.getProperty(n)}`}D_.schemaRefOrVal=Rj;function Pj(e){return I_(decodeURIComponent(e))}D_.unescapeFragment=Pj;function zj(e){return encodeURIComponent(Jd(e))}D_.escapeFragment=zj;function Jd(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}D_.escapeJsonPointer=Jd;function I_(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}D_.unescapeJsonPointer=I_;function Oj(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}D_.eachItem=Oj;function z_({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:n}){return(o,i,s,a)=>{let c=s===void 0?i:s instanceof ve.Name?(i instanceof ve.Name?e(o,i,s):t(o,i,s),s):i instanceof ve.Name?(t(o,s,i),i):r(i,s);return a===ve.Name&&!(c instanceof ve.Name)?n(o,c):c}}D_.mergeEvaluated={props:z_({mergeNames:(e,t,r)=>e.if(ve._`${r} !== true && ${t} !== undefined`,()=>{e.if(ve._`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,ve._`${r} || {}`).code(ve._`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if(ve._`${r} !== true`,()=>{if(t===!0)e.assign(r,!0);else e.assign(r,ve._`${r} || {}`),Wd(e,r,t)}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:j_}),items:z_({mergeNames:(e,t,r)=>e.if(ve._`${r} !== true && ${t} !== undefined`,()=>e.assign(r,ve._`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if(ve._`${r} !== true`,()=>e.assign(r,t===!0?!0:ve._`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function j_(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",ve._`{}`);if(t!==void 0)Wd(e,r,t);return r}D_.evaluatedPropsToName=j_;function Wd(e,t,r){Object.keys(r).forEach((n)=>e.assign(ve._`${t}${ve.getProperty(n)}`,!0))}D_.setEvaluated=Wd;var O_={};function Aj(e,t){return e.scopeValue("func",{ref:t,code:O_[t.code]||(O_[t.code]=new Sj._Code(t.code))})}D_.useFunc=Aj;var Gd;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Gd||(D_.Type=Gd={}));function Cj(e,t,r){if(e instanceof ve.Name){let n=t===Gd.Num;return r?n?ve._`"[" + ${e} + "]"`:ve._`"['" + ${e} + "']"`:n?ve._`"/" + ${e}`:ve._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?ve.getProperty(e).toString():"/"+Jd(e)}D_.getErrorPath=Cj;function N_(e,t,r=e.opts.strictSchema){if(!r)return;if(t=`strict mode: ${t}`,r===!0)throw Error(t);e.self.logger.warn(t)}D_.checkStrictMode=N_});var yr=b(function(L_){Object.defineProperty(L_,"__esModule",{value:!0});var st=W(),Yj={data:new st.Name("data"),valCxt:new st.Name("valCxt"),instancePath:new st.Name("instancePath"),parentData:new st.Name("parentData"),parentDataProperty:new st.Name("parentDataProperty"),rootData:new st.Name("rootData"),dynamicAnchors:new st.Name("dynamicAnchors"),vErrors:new st.Name("vErrors"),errors:new st.Name("errors"),this:new st.Name("this"),self:new st.Name("self"),scope:new st.Name("scope"),json:new st.Name("json"),jsonPos:new st.Name("jsonPos"),jsonLen:new st.Name("jsonLen"),jsonPart:new st.Name("jsonPart")};L_.default=Yj});var Di=b(function(Z_){Object.defineProperty(Z_,"__esModule",{value:!0});Z_.extendErrors=Z_.resetErrorsCount=Z_.reportExtraError=Z_.reportError=Z_.keyword$DataError=Z_.keywordError=void 0;var ae=W(),tc=se(),lt=yr();Z_.keywordError={message:({keyword:e})=>ae.str`must pass "${e}" keyword validation`};Z_.keyword$DataError={message:({keyword:e,schemaType:t})=>t?ae.str`"${e}" keyword must be ${t} ($data)`:ae.str`"${e}" keyword is invalid ($data)`};function Qj(e,t=Z_.keywordError,r,n){let{it:o}=e,{gen:i,compositeRule:s,allErrors:a}=o,c=F_(e,t,r);if(n!==null&&n!==void 0?n:s||a)q_(i,c);else U_(o,ae._`[${c}]`)}Z_.reportError=Qj;function eN(e,t=Z_.keywordError,r){let{it:n}=e,{gen:o,compositeRule:i,allErrors:s}=n,a=F_(e,t,r);if(q_(o,a),!(i||s))U_(n,lt.default.vErrors)}Z_.reportExtraError=eN;function tN(e,t){e.assign(lt.default.errors,t),e.if(ae._`${lt.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(ae._`${lt.default.vErrors}.length`,t),()=>e.assign(lt.default.vErrors,null)))}Z_.resetErrorsCount=tN;function rN({gen:e,keyword:t,schemaValue:r,data:n,errsCount:o,it:i}){if(o===void 0)throw Error("ajv implementation error");let s=e.name("err");e.forRange("i",o,lt.default.errors,(a)=>{if(e.const(s,ae._`${lt.default.vErrors}[${a}]`),e.if(ae._`${s}.instancePath === undefined`,()=>e.assign(ae._`${s}.instancePath`,ae.strConcat(lt.default.instancePath,i.errorPath))),e.assign(ae._`${s}.schemaPath`,ae.str`${i.errSchemaPath}/${t}`),i.opts.verbose)e.assign(ae._`${s}.schema`,r),e.assign(ae._`${s}.data`,n)})}Z_.extendErrors=rN;function q_(e,t){let r=e.const("err",t);e.if(ae._`${lt.default.vErrors} === null`,()=>e.assign(lt.default.vErrors,ae._`[${r}]`),ae._`${lt.default.vErrors}.push(${r})`),e.code(ae._`${lt.default.errors}++`)}function U_(e,t){let{gen:r,validateName:n,schemaEnv:o}=e;if(o.$async)r.throw(ae._`new ${e.ValidationError}(${t})`);else r.assign(ae._`${n}.errors`,t),r.return(!1)}var vn={keyword:new ae.Name("keyword"),schemaPath:new ae.Name("schemaPath"),params:new ae.Name("params"),propertyName:new ae.Name("propertyName"),message:new ae.Name("message"),schema:new ae.Name("schema"),parentSchema:new ae.Name("parentSchema")};function F_(e,t,r){let{createErrors:n}=e.it;if(n===!1)return ae._`{}`;return nN(e,t,r)}function nN(e,t,r={}){let{gen:n,it:o}=e,i=[oN(o,r),iN(e,r)];return sN(e,t,i),n.object(...i)}function oN({errorPath:e},{instancePath:t}){let r=t?ae.str`${e}${tc.getErrorPath(t,tc.Type.Str)}`:e;return[lt.default.instancePath,ae.strConcat(lt.default.instancePath,r)]}function iN({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:n}){let o=n?t:ae.str`${t}/${e}`;if(r)o=ae.str`${o}${tc.getErrorPath(r,tc.Type.Str)}`;return[vn.schemaPath,o]}function sN(e,{params:t,message:r},n){let{keyword:o,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:p}=a;if(n.push([vn.keyword,o],[vn.params,typeof t=="function"?t(e):t||ae._`{}`]),c.messages)n.push([vn.message,typeof r=="function"?r(e):r]);if(c.verbose)n.push([vn.schema,s],[vn.parentSchema,ae._`${l}${p}`],[lt.default.data,i]);if(u)n.push([vn.propertyName,u])}});var J_=b(function(V_){Object.defineProperty(V_,"__esModule",{value:!0});V_.boolOrEmptySchema=V_.topBoolOrEmptySchema=void 0;var pN=Di(),dN=W(),mN=yr(),fN={message:"boolean schema is false"};function hN(e){let{gen:t,schema:r,validateName:n}=e;if(r===!1)H_(e,!1);else if(typeof r=="object"&&r.$async===!0)t.return(mN.default.data);else t.assign(dN._`${n}.errors`,null),t.return(!0)}V_.topBoolOrEmptySchema=hN;function gN(e,t){let{gen:r,schema:n}=e;if(n===!1)r.var(t,!1),H_(e);else r.var(t,!0)}V_.boolOrEmptySchema=gN;function H_(e,t){let{gen:r,data:n}=e;pN.reportError({gen:r,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e},fN,void 0,t)}});var Yd=b(function(W_){Object.defineProperty(W_,"__esModule",{value:!0});W_.getRules=W_.isJSONType=void 0;var vN=["string","number","integer","boolean","null","object","array"],yN=new Set(vN);function bN(e){return typeof e=="string"&&yN.has(e)}W_.isJSONType=bN;function _N(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}W_.getRules=_N});var Xd=b(function(Q_){Object.defineProperty(Q_,"__esModule",{value:!0});Q_.shouldUseRule=Q_.shouldUseGroup=Q_.schemaHasRulesForType=void 0;function kN({schema:e,self:t},r){let n=t.RULES.types[r];return n&&n!==!0&&Y_(e,n)}Q_.schemaHasRulesForType=kN;function Y_(e,t){return t.rules.some((r)=>X_(e,r))}Q_.shouldUseGroup=Y_;function X_(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some((n)=>e[n]!==void 0))}Q_.shouldUseRule=X_});var Mi=b(function(ow){Object.defineProperty(ow,"__esModule",{value:!0});ow.reportTypeError=ow.checkDataTypes=ow.checkDataType=ow.coerceAndCheckDataType=ow.getJSONTypes=ow.getSchemaTypes=ow.DataType=void 0;var TN=Yd(),EN=Xd(),RN=Di(),J=W(),tw=se(),co;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(co||(ow.DataType=co={}));function PN(e){let t=rw(e.type);if(t.includes("null")){if(e.nullable===!1)throw Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw Error('"nullable" cannot be used without "type"');if(e.nullable===!0)t.push("null")}return t}ow.getSchemaTypes=PN;function rw(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(TN.isJSONType))return t;throw Error("type must be JSONType or JSONType[]: "+t.join(","))}ow.getJSONTypes=rw;function zN(e,t){let{gen:r,data:n,opts:o}=e,i=ON(t,o.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&EN.schemaHasRulesForType(e,t[0]));if(s){let a=em(t,n,o.strictNumbers,co.Wrong);r.if(a,()=>{if(i.length)AN(e,t,i);else tm(e)})}return s}ow.coerceAndCheckDataType=zN;var nw=new Set(["string","number","integer","boolean","null"]);function ON(e,t){return t?e.filter((r)=>nw.has(r)||t==="array"&&r==="array"):[]}function AN(e,t,r){let{gen:n,data:o,opts:i}=e,s=n.let("dataType",J._`typeof ${o}`),a=n.let("coerced",J._`undefined`);if(i.coerceTypes==="array")n.if(J._`${s} == 'object' && Array.isArray(${o}) && ${o}.length == 1`,()=>n.assign(o,J._`${o}[0]`).assign(s,J._`typeof ${o}`).if(em(t,o,i.strictNumbers),()=>n.assign(a,o)));n.if(J._`${a} !== undefined`);for(let u of r)if(nw.has(u)||u==="array"&&i.coerceTypes==="array")c(u);n.else(),tm(e),n.endIf(),n.if(J._`${a} !== undefined`,()=>{n.assign(o,a),CN(e,a)});function c(u){switch(u){case"string":n.elseIf(J._`${s} == "number" || ${s} == "boolean"`).assign(a,J._`"" + ${o}`).elseIf(J._`${o} === null`).assign(a,J._`""`);return;case"number":n.elseIf(J._`${s} == "boolean" || ${o} === null
|
|
21
21
|
|| (${s} == "string" && ${o} && ${o} == +${o})`).assign(a,J._`+${o}`);return;case"integer":n.elseIf(J._`${s} === "boolean" || ${o} === null
|
|
22
22
|
|| (${s} === "string" && ${o} && ${o} == +${o} && !(${o} % 1))`).assign(a,J._`+${o}`);return;case"boolean":n.elseIf(J._`${o} === "false" || ${o} === 0 || ${o} === null`).assign(a,!1).elseIf(J._`${o} === "true" || ${o} === 1`).assign(a,!0);return;case"null":n.elseIf(J._`${o} === "" || ${o} === 0 || ${o} === false`),n.assign(a,null);return;case"array":n.elseIf(J._`${s} === "string" || ${s} === "number"
|
|
23
|
-
|| ${s} === "boolean" || ${o} === null`).assign(a,J._`[${o}]`)}}}function ZD({gen:e,parentData:t,parentDataProperty:r},n){e.if(J._`${t} !== undefined`,()=>e.assign(J._`${t}[${r}]`,n))}function am(e,t,r,n=_o.Correct){let o=n===_o.Correct?J.operators.EQ:J.operators.NEQ,i;switch(e){case"null":return J._`${t} ${o} null`;case"array":i=J._`Array.isArray(${t})`;break;case"object":i=J._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s(J._`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return J._`typeof ${t} ${o} ${e}`}return n===_o.Correct?i:(0,J.not)(i);function s(a=J.nil){return(0,J.and)(J._`typeof ${t} == "number"`,a,r?J._`isFinite(${t})`:J.nil)}}_w.checkDataType=am;function cm(e,t,r,n){if(e.length===1)return am(e[0],t,r,n);let o,i=(0,vw.toHash)(e);if(i.array&&i.object){let s=J._`typeof ${t} != "object"`;o=i.null?s:J._`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else o=J.nil;if(i.number)delete i.integer;for(let s in i)o=(0,J.and)(o,am(s,t,r,n));return o}_w.checkDataTypes=cm;var BD={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?J._`{type: ${e}}`:J._`{type: ${t}}`};function um(e){let t=HD(e);(0,LD.reportError)(t,BD)}_w.reportTypeError=um;function HD(e){let{gen:t,data:r,schema:n}=e,o=(0,vw.schemaRefOrVal)(e,n,"type");return{gen:t,keyword:"type",data:r,schema:n.type,schemaCode:o,schemaValue:o,parentSchema:n,params:{},it:e}}});var Tw=_(function(Sw){Object.defineProperty(Sw,"__esModule",{value:!0});Sw.assignDefaults=void 0;var wo=W(),XD=ae();function QD(e,t){let{properties:r,items:n}=e.schema;if(t==="object"&&r)for(let o in r)kw(e,o,r[o].default);else if(t==="array"&&Array.isArray(n))n.forEach((o,i)=>kw(e,i,o.default))}Sw.assignDefaults=QD;function kw(e,t,r){let{gen:n,compositeRule:o,data:i,opts:s}=e;if(r===void 0)return;let a=wo._`${i}${(0,wo.getProperty)(t)}`;if(o){(0,XD.checkStrictMode)(e,`default is ignored for: ${a}`);return}let c=wo._`${a} === undefined`;if(s.useDefaults==="empty")c=wo._`${c} || ${a} === null || ${a} === ""`;n.if(c,wo._`${a} = ${(0,wo.stringify)(r)}`)}});var jt=_(function(Pw){Object.defineProperty(Pw,"__esModule",{value:!0});Pw.validateUnion=Pw.validateArray=Pw.usePattern=Pw.callValidateCode=Pw.schemaProperties=Pw.allSchemaProperties=Pw.noPropertyInData=Pw.propertyInData=Pw.isOwnProperty=Pw.hasPropFunc=Pw.reportMissingProp=Pw.checkMissingProp=Pw.checkReportMissingProp=void 0;var $e=W(),lm=ae(),Fr=gr(),eL=ae();function tL(e,t){let{gen:r,data:n,it:o}=e;r.if(dm(r,n,t,o.opts.ownProperties),()=>{e.setParams({missingProperty:$e._`${t}`},!0),e.error()})}Pw.checkReportMissingProp=tL;function rL({gen:e,data:t,it:{opts:r}},n,o){return(0,$e.or)(...n.map((i)=>(0,$e.and)(dm(e,t,i,r.ownProperties),$e._`${o} = ${i}`)))}Pw.checkMissingProp=rL;function nL(e,t){e.setParams({missingProperty:t},!0),e.error()}Pw.reportMissingProp=nL;function Ew(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:$e._`Object.prototype.hasOwnProperty`})}Pw.hasPropFunc=Ew;function pm(e,t,r){return $e._`${Ew(e)}.call(${t}, ${r})`}Pw.isOwnProperty=pm;function oL(e,t,r,n){let o=$e._`${t}${(0,$e.getProperty)(r)} !== undefined`;return n?$e._`${o} && ${pm(e,t,r)}`:o}Pw.propertyInData=oL;function dm(e,t,r,n){let o=$e._`${t}${(0,$e.getProperty)(r)} === undefined`;return n?(0,$e.or)(o,(0,$e.not)(pm(e,t,r))):o}Pw.noPropertyInData=dm;function Rw(e){return e?Object.keys(e).filter((t)=>t!=="__proto__"):[]}Pw.allSchemaProperties=Rw;function iL(e,t){return Rw(t).filter((r)=>!(0,lm.alwaysValidSchema)(e,t[r]))}Pw.schemaProperties=iL;function sL({schemaCode:e,data:t,it:{gen:r,topSchemaRef:n,schemaPath:o,errorPath:i},it:s},a,c,u){let l=u?$e._`${e}, ${t}, ${n}${o}`:t,p=[[Fr.default.instancePath,(0,$e.strConcat)(Fr.default.instancePath,i)],[Fr.default.parentData,s.parentData],[Fr.default.parentDataProperty,s.parentDataProperty],[Fr.default.rootData,Fr.default.rootData]];if(s.opts.dynamicRef)p.push([Fr.default.dynamicAnchors,Fr.default.dynamicAnchors]);let m=$e._`${l}, ${r.object(...p)}`;return c!==$e.nil?$e._`${a}.call(${c}, ${m})`:$e._`${a}(${m})`}Pw.callValidateCode=sL;var aL=$e._`new RegExp`;function cL({gen:e,it:{opts:t}},r){let n=t.unicodeRegExp?"u":"",{regExp:o}=t.code,i=o(r,n);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:$e._`${o.code==="new RegExp"?aL:(0,eL.useFunc)(e,o)}(${r}, ${n})`})}Pw.usePattern=cL;function uL(e){let{gen:t,data:r,keyword:n,it:o}=e,i=t.name("valid");if(o.allErrors){let a=t.let("valid",!0);return s(()=>t.assign(a,!1)),a}return t.var(i,!0),s(()=>t.break()),i;function s(a){let c=t.const("len",$e._`${r}.length`);t.forRange("i",0,c,(u)=>{e.subschema({keyword:n,dataProp:u,dataPropType:lm.Type.Num},i),t.if((0,$e.not)(i),a)})}}Pw.validateArray=uL;function lL(e){let{gen:t,schema:r,keyword:n,it:o}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(r.some((c)=>(0,lm.alwaysValidSchema)(o,c))&&!o.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:n,schemaProp:u,compositeRule:!0},a);if(t.assign(s,$e._`${s} || ${a}`),!e.mergeValidEvaluated(l,a))t.if((0,$e.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}Pw.validateUnion=lL});var jw=_(function(Cw){Object.defineProperty(Cw,"__esModule",{value:!0});Cw.validateKeywordUsage=Cw.validSchemaType=Cw.funcKeywordCode=Cw.macroKeywordCode=void 0;var ut=W(),Sn=gr(),kL=jt(),SL=Hi();function $L(e,t){let{gen:r,keyword:n,schema:o,parentSchema:i,it:s}=e,a=t.macro.call(s.self,o,i,s),c=Aw(r,n,a);if(s.opts.validateSchema!==!1)s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:ut.nil,errSchemaPath:`${s.errSchemaPath}/${n}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}Cw.macroKeywordCode=$L;function TL(e,t){var r;let{gen:n,keyword:o,schema:i,parentSchema:s,$data:a,it:c}=e;RL(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=Aw(n,o,u),p=n.let("valid");e.block$data(p,m),e.ok((r=t.valid)!==null&&r!==void 0?r:p);function m(){if(t.errors===!1){if(x(),t.modifying)Ow(e);y(()=>e.error())}else{let g=t.async?d():h();if(t.modifying)Ow(e);y(()=>EL(e,g))}}function d(){let g=n.let("ruleErrs",null);return n.try(()=>x(ut._`await `),(b)=>n.assign(p,!1).if(ut._`${b} instanceof ${c.ValidationError}`,()=>n.assign(g,ut._`${b}.errors`),()=>n.throw(b))),g}function h(){let g=ut._`${l}.errors`;return n.assign(g,null),x(ut.nil),g}function x(g=t.async?ut._`await `:ut.nil){let b=c.opts.passContext?Sn.default.this:Sn.default.self,k=!(("compile"in t)&&!a||t.schema===!1);n.assign(p,ut._`${g}${(0,kL.callValidateCode)(e,l,b,k)}`,t.modifying)}function y(g){var b;n.if((0,ut.not)((b=t.valid)!==null&&b!==void 0?b:p),g)}}Cw.funcKeywordCode=TL;function Ow(e){let{gen:t,data:r,it:n}=e;t.if(n.parentData,()=>t.assign(r,ut._`${n.parentData}[${n.parentDataProperty}]`))}function EL(e,t){let{gen:r}=e;r.if(ut._`Array.isArray(${t})`,()=>{r.assign(Sn.default.vErrors,ut._`${Sn.default.vErrors} === null ? ${t} : ${Sn.default.vErrors}.concat(${t})`).assign(Sn.default.errors,ut._`${Sn.default.vErrors}.length`),(0,SL.extendErrors)(e)},()=>e.error())}function RL({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}function Aw(e,t,r){if(r===void 0)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,ut.stringify)(r)})}function PL(e,t,r=!1){return!t.length||t.some((n)=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||r&&typeof e>"u")}Cw.validSchemaType=PL;function zL({schema:e,opts:t,self:r,errSchemaPath:n},o,i){if(Array.isArray(o.keyword)?!o.keyword.includes(i):o.keyword!==i)throw Error("ajv implementation error");let s=o.dependencies;if(s===null||s===void 0?void 0:s.some((a)=>!Object.prototype.hasOwnProperty.call(e,a)))throw Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(o.validateSchema){if(!o.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${n}": `+r.errorsText(o.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw Error(c)}}}Cw.validateKeywordUsage=zL});var Mw=_(function(Dw){Object.defineProperty(Dw,"__esModule",{value:!0});Dw.extendSubschemaMode=Dw.extendSubschemaData=Dw.getSubschema=void 0;var cr=W(),Nw=ae();function IL(e,{keyword:t,schemaProp:r,schema:n,schemaPath:o,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&n!==void 0)throw Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let a=e.schema[t];return r===void 0?{schema:a,schemaPath:cr._`${e.schemaPath}${(0,cr.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:cr._`${e.schemaPath}${(0,cr.getProperty)(t)}${(0,cr.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Nw.escapeFragment)(r)}`}}if(n!==void 0){if(o===void 0||i===void 0||s===void 0)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:o,topSchemaRef:s,errSchemaPath:i}}throw Error('either "keyword" or "schema" must be passed')}Dw.getSubschema=IL;function jL(e,t,{dataProp:r,dataPropType:n,data:o,dataTypes:i,propertyName:s}){if(o!==void 0&&r!==void 0)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:p}=t,m=a.let("data",cr._`${t.data}${(0,cr.getProperty)(r)}`,!0);c(m),e.errorPath=cr.str`${u}${(0,Nw.getErrorPath)(r,n,p.jsPropertySyntax)}`,e.parentDataProperty=cr._`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(o!==void 0){let u=o instanceof cr.Name?o:a.let("data",o,!0);if(c(u),s!==void 0)e.propertyName=s}if(i)e.dataTypes=i;function c(u){e.data=u,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,u]}}Dw.extendSubschemaData=jL;function NL(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:n,createErrors:o,allErrors:i}){if(n!==void 0)e.compositeRule=n;if(o!==void 0)e.createErrors=o;if(i!==void 0)e.allErrors=i;e.jtdDiscriminator=t,e.jtdMetadata=r}Dw.extendSubschemaMode=NL});var mm=_(function(OW,qw){qw.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,o,i;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(o=n;o--!==0;)if(!e(t[o],r[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),n=i.length,n!==Object.keys(r).length)return!1;for(o=n;o--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[o]))return!1;for(o=n;o--!==0;){var s=i[o];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var Fw=_(function(AW,Uw){var Zr=Uw.exports=function(e,t,r){if(typeof t=="function")r=t,t={};r=t.cb||r;var n=typeof r=="function"?r:r.pre||function(){},o=r.post||function(){};sc(t,n,o,e,"",e)};Zr.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Zr.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Zr.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Zr.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function sc(e,t,r,n,o,i,s,a,c,u){if(n&&typeof n=="object"&&!Array.isArray(n)){t(n,o,i,s,a,c,u);for(var l in n){var p=n[l];if(Array.isArray(p)){if(l in Zr.arrayKeywords)for(var m=0;m<p.length;m++)sc(e,t,r,p[m],o+"/"+l+"/"+m,i,o,l,n,m)}else if(l in Zr.propsKeywords){if(p&&typeof p=="object")for(var d in p)sc(e,t,r,p[d],o+"/"+l+"/"+ML(d),i,o,l,n,d)}else if(l in Zr.keywords||e.allKeys&&!(l in Zr.skipKeywords))sc(e,t,r,p,o+"/"+l,i,o,l,n)}r(n,o,i,s,a,c,u)}}function ML(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var Gi=_(function(Vw){Object.defineProperty(Vw,"__esModule",{value:!0});Vw.getSchemaRefs=Vw.resolveUrl=Vw.normalizeId=Vw._getFullPath=Vw.getFullPath=Vw.inlineRef=void 0;var qL=ae(),UL=mm(),FL=Fw(),ZL=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function BL(e,t=!0){if(typeof e=="boolean")return!0;if(t===!0)return!fm(e);if(!t)return!1;return Zw(e)<=t}Vw.inlineRef=BL;var HL=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function fm(e){for(let t in e){if(HL.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(fm))return!0;if(typeof r=="object"&&fm(r))return!0}return!1}function Zw(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,ZL.has(r))continue;if(typeof e[r]=="object")(0,qL.eachItem)(e[r],(n)=>t+=Zw(n));if(t===1/0)return 1/0}return t}function Bw(e,t="",r){if(r!==!1)t=ko(t);let n=e.parse(t);return Hw(e,n)}Vw.getFullPath=Bw;function Hw(e,t){return e.serialize(t).split("#")[0]+"#"}Vw._getFullPath=Hw;var VL=/#\/?$/;function ko(e){return e?e.replace(VL,""):""}Vw.normalizeId=ko;function GL(e,t,r){return r=ko(r),e.resolve(t,r)}Vw.resolveUrl=GL;var JL=/^[a-z_][-a-z0-9._]*$/i;function WL(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:n}=this.opts,o=ko(e[r]||t),i={"":o},s=Bw(n,o,!1),a={},c=new Set;return FL(e,{allKeys:!0},(p,m,d,h)=>{if(h===void 0)return;let x=s+m,y=i[h];if(typeof p[r]=="string")y=g.call(this,p[r]);b.call(this,p.$anchor),b.call(this,p.$dynamicAnchor),i[m]=y;function g(k){let z=this.opts.uriResolver.resolve;if(k=ko(y?z(y,k):k),c.has(k))throw l(k);c.add(k);let I=this.refs[k];if(typeof I=="string")I=this.refs[I];if(typeof I=="object")u(p,I.schema,k);else if(k!==ko(x))if(k[0]==="#")u(p,a[k],k),a[k]=p;else this.refs[k]=x;return k}function b(k){if(typeof k=="string"){if(!JL.test(k))throw Error(`invalid anchor "${k}"`);g.call(this,`#${k}`)}}}),a;function u(p,m,d){if(m!==void 0&&!UL(p,m))throw l(d)}function l(p){return Error(`reference "${p}" resolves to more than one schema`)}}Vw.getSchemaRefs=WL});var Ki=_(function(c0){Object.defineProperty(c0,"__esModule",{value:!0});c0.getData=c0.KeywordCxt=c0.validateFunctionCode=void 0;var Xw=pw(),Jw=Vi(),gm=sm(),ac=Vi(),tM=Tw(),Wi=jw(),hm=Mw(),M=W(),B=gr(),rM=Gi(),xr=ae(),Ji=Hi();function nM(e){if(t0(e)){if(r0(e),e0(e)){sM(e);return}}Qw(e,()=>(0,Xw.topBoolOrEmptySchema)(e))}c0.validateFunctionCode=nM;function Qw({gen:e,validateName:t,schema:r,schemaEnv:n,opts:o},i){if(o.code.es5)e.func(t,M._`${B.default.data}, ${B.default.valCxt}`,n.$async,()=>{e.code(M._`"use strict"; ${Ww(r,o)}`),iM(e,o),e.code(i)});else e.func(t,M._`${B.default.data}, ${oM(o)}`,n.$async,()=>e.code(Ww(r,o)).code(i))}function oM(e){return M._`{${B.default.instancePath}="", ${B.default.parentData}, ${B.default.parentDataProperty}, ${B.default.rootData}=${B.default.data}${e.dynamicRef?M._`, ${B.default.dynamicAnchors}={}`:M.nil}}={}`}function iM(e,t){e.if(B.default.valCxt,()=>{if(e.var(B.default.instancePath,M._`${B.default.valCxt}.${B.default.instancePath}`),e.var(B.default.parentData,M._`${B.default.valCxt}.${B.default.parentData}`),e.var(B.default.parentDataProperty,M._`${B.default.valCxt}.${B.default.parentDataProperty}`),e.var(B.default.rootData,M._`${B.default.valCxt}.${B.default.rootData}`),t.dynamicRef)e.var(B.default.dynamicAnchors,M._`${B.default.valCxt}.${B.default.dynamicAnchors}`)},()=>{if(e.var(B.default.instancePath,M._`""`),e.var(B.default.parentData,M._`undefined`),e.var(B.default.parentDataProperty,M._`undefined`),e.var(B.default.rootData,B.default.data),t.dynamicRef)e.var(B.default.dynamicAnchors,M._`{}`)})}function sM(e){let{schema:t,opts:r,gen:n}=e;Qw(e,()=>{if(r.$comment&&t.$comment)o0(e);if(pM(e),n.let(B.default.vErrors,null),n.let(B.default.errors,0),r.unevaluated)aM(e);n0(e),fM(e)});return}function aM(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",M._`${r}.evaluated`),t.if(M._`${e.evaluated}.dynamicProps`,()=>t.assign(M._`${e.evaluated}.props`,M._`undefined`)),t.if(M._`${e.evaluated}.dynamicItems`,()=>t.assign(M._`${e.evaluated}.items`,M._`undefined`))}function Ww(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?M._`/*# sourceURL=${r} */`:M.nil}function cM(e,t){if(t0(e)){if(r0(e),e0(e)){uM(e,t);return}}(0,Xw.boolOrEmptySchema)(e,t)}function e0({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let r in e)if(t.RULES.all[r])return!0;return!1}function t0(e){return typeof e.schema!="boolean"}function uM(e,t){let{schema:r,gen:n,opts:o}=e;if(o.$comment&&r.$comment)o0(e);dM(e),mM(e);let i=n.const("_errs",B.default.errors);n0(e,i),n.var(t,M._`${i} === ${B.default.errors}`)}function r0(e){(0,xr.checkUnknownRules)(e),lM(e)}function n0(e,t){if(e.opts.jtd)return Kw(e,[],!1,t);let r=(0,Jw.getSchemaTypes)(e.schema),n=(0,Jw.coerceAndCheckDataType)(e,r);Kw(e,r,!n,t)}function lM(e){let{schema:t,errSchemaPath:r,opts:n,self:o}=e;if(t.$ref&&n.ignoreKeywordsWithRef&&(0,xr.schemaHasRulesButRef)(t,o.RULES))o.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function pM(e){let{schema:t,opts:r}=e;if(t.default!==void 0&&r.useDefaults&&r.strictSchema)(0,xr.checkStrictMode)(e,"default is ignored in the schema root")}function dM(e){let t=e.schema[e.opts.schemaId];if(t)e.baseId=(0,rM.resolveUrl)(e.opts.uriResolver,e.baseId,t)}function mM(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}function o0({gen:e,schemaEnv:t,schema:r,errSchemaPath:n,opts:o}){let i=r.$comment;if(o.$comment===!0)e.code(M._`${B.default.self}.logger.log(${i})`);else if(typeof o.$comment=="function"){let s=M.str`${n}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(M._`${B.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function fM(e){let{gen:t,schemaEnv:r,validateName:n,ValidationError:o,opts:i}=e;if(r.$async)t.if(M._`${B.default.errors} === 0`,()=>t.return(B.default.data),()=>t.throw(M._`new ${o}(${B.default.vErrors})`));else{if(t.assign(M._`${n}.errors`,B.default.vErrors),i.unevaluated)hM(e);t.return(M._`${B.default.errors} === 0`)}}function hM({gen:e,evaluated:t,props:r,items:n}){if(r instanceof M.Name)e.assign(M._`${t}.props`,r);if(n instanceof M.Name)e.assign(M._`${t}.items`,n)}function Kw(e,t,r,n){let{gen:o,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,xr.schemaHasRulesButRef)(i,l))){o.block(()=>s0(e,"$ref",l.all.$ref.definition));return}if(!c.jtd)gM(e,t);o.block(()=>{for(let m of l.rules)p(m);p(l.post)});function p(m){if(!(0,gm.shouldUseGroup)(i,m))return;if(m.type){if(o.if((0,ac.checkDataType)(m.type,s,c.strictNumbers)),Yw(e,m),t.length===1&&t[0]===m.type&&r)o.else(),(0,ac.reportTypeError)(e);o.endIf()}else Yw(e,m);if(!a)o.if(M._`${B.default.errors} === ${n||0}`)}}function Yw(e,t){let{gen:r,schema:n,opts:{useDefaults:o}}=e;if(o)(0,tM.assignDefaults)(e,t.type);r.block(()=>{for(let i of t.rules)if((0,gm.shouldUseRule)(n,i))s0(e,i.keyword,i.definition,t.type)})}function gM(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;if(xM(e,t),!e.opts.allowUnionTypes)vM(e,t);yM(e,e.dataTypes)}function xM(e,t){if(!t.length)return;if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach((r)=>{if(!i0(e.dataTypes,r))xm(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),_M(e,t)}function vM(e,t){if(t.length>1&&!(t.length===2&&t.includes("null")))xm(e,"use allowUnionTypes to allow union type keyword")}function yM(e,t){let r=e.self.RULES.all;for(let n in r){let o=r[n];if(typeof o=="object"&&(0,gm.shouldUseRule)(e.schema,o)){let{type:i}=o.definition;if(i.length&&!i.some((s)=>bM(t,s)))xm(e,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function bM(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function i0(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function _M(e,t){let r=[];for(let n of e.dataTypes)if(i0(t,n))r.push(n);else if(t.includes("integer")&&n==="number")r.push("integer");e.dataTypes=r}function xm(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,xr.checkStrictMode)(e,t,e.opts.strictTypes)}class vm{constructor(e,t,r){if((0,Wi.validateKeywordUsage)(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,xr.schemaRefOrVal)(e,this.schema,r,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",a0(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,Wi.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);if("code"in t?t.trackErrors:t.errors!==!1)this.errsCount=e.gen.const("_errs",B.default.errors)}result(e,t,r){this.failResult((0,M.not)(e),t,r)}failResult(e,t,r){if(this.gen.if(e),r)r();else this.error();if(t){if(this.gen.else(),t(),this.allErrors)this.gen.endIf()}else if(this.allErrors)this.gen.endIf();else this.gen.else()}pass(e,t){this.failResult((0,M.not)(e),void 0,t)}fail(e){if(e===void 0){if(this.error(),!this.allErrors)this.gen.if(!1);return}if(this.gen.if(e),this.error(),this.allErrors)this.gen.endIf();else this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:t}=this;this.fail(M._`${t} !== undefined && (${(0,M.or)(this.invalid$data(),e)})`)}error(e,t,r){if(t){this.setParams(t),this._error(e,r),this.setParams({});return}this._error(e,r)}_error(e,t){(e?Ji.reportExtraError:Ji.reportError)(this,this.def.error,t)}$dataError(){(0,Ji.reportError)(this,this.def.$dataError||Ji.keyword$DataError)}reset(){if(this.errsCount===void 0)throw Error('add "trackErrors" to keyword definition');(0,Ji.resetErrorsCount)(this.gen,this.errsCount)}ok(e){if(!this.allErrors)this.gen.if(e)}setParams(e,t){if(t)Object.assign(this.params,e);else this.params=e}block$data(e,t,r=M.nil){this.gen.block(()=>{this.check$data(e,r),t()})}check$data(e=M.nil,t=M.nil){if(!this.$data)return;let{gen:r,schemaCode:n,schemaType:o,def:i}=this;if(r.if((0,M.or)(M._`${n} === undefined`,t)),e!==M.nil)r.assign(e,!0);if(o.length||i.validateSchema){if(r.elseIf(this.invalid$data()),this.$dataError(),e!==M.nil)r.assign(e,!1)}r.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:r,def:n,it:o}=this;return(0,M.or)(i(),s());function i(){if(r.length){if(!(t instanceof M.Name))throw Error("ajv implementation error");let a=Array.isArray(r)?r:[r];return M._`${(0,ac.checkDataTypes)(a,t,o.opts.strictNumbers,ac.DataType.Wrong)}`}return M.nil}function s(){if(n.validateSchema){let a=e.scopeValue("validate$data",{ref:n.validateSchema});return M._`!${a}(${t})`}return M.nil}}subschema(e,t){let r=(0,hm.getSubschema)(this.it,e);(0,hm.extendSubschemaData)(r,this.it,e),(0,hm.extendSubschemaMode)(r,e);let n={...this.it,...r,items:void 0,props:void 0};return cM(n,t),n}mergeEvaluated(e,t){let{it:r,gen:n}=this;if(!r.opts.unevaluated)return;if(r.props!==!0&&e.props!==void 0)r.props=xr.mergeEvaluated.props(n,e.props,r.props,t);if(r.items!==!0&&e.items!==void 0)r.items=xr.mergeEvaluated.items(n,e.items,r.items,t)}mergeValidEvaluated(e,t){let{it:r,gen:n}=this;if(r.opts.unevaluated&&(r.props!==!0||r.items!==!0))return n.if(t,()=>this.mergeEvaluated(e,M.Name)),!0}}c0.KeywordCxt=vm;function s0(e,t,r,n){let o=new vm(e,r,t);if("code"in r)r.code(o,n);else if(o.$data&&r.validate)(0,Wi.funcKeywordCode)(o,r);else if("macro"in r)(0,Wi.macroKeywordCode)(o,r);else if(r.compile||r.validate)(0,Wi.funcKeywordCode)(o,r)}var wM=/^\/(?:[^~]|~0|~1)*$/,kM=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function a0(e,{dataLevel:t,dataNames:r,dataPathArr:n}){let o,i;if(e==="")return B.default.rootData;if(e[0]==="/"){if(!wM.test(e))throw Error(`Invalid JSON-pointer: ${e}`);o=e,i=B.default.rootData}else{let u=kM.exec(e);if(!u)throw Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(o=u[2],o==="#"){if(l>=t)throw Error(c("property/index",l));return n[t-l]}if(l>t)throw Error(c("data",l));if(i=r[t-l],!o)return i}let s=i,a=o.split("/");for(let u of a)if(u)i=M._`${i}${(0,M.getProperty)((0,xr.unescapeJsonPointer)(u))}`,s=M._`${s} && ${i}`;return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}c0.getData=a0});var cc=_(function(p0){Object.defineProperty(p0,"__esModule",{value:!0});class l0 extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}}p0.default=l0});var Yi=_(function(m0){Object.defineProperty(m0,"__esModule",{value:!0});var ym=Gi();class d0 extends Error{constructor(e,t,r,n){super(n||`can't resolve reference ${r} from id ${t}`);this.missingRef=(0,ym.resolveUrl)(e,t,r),this.missingSchema=(0,ym.normalizeId)((0,ym.getFullPath)(e,this.missingRef))}}m0.default=d0});var lc=_(function(g0){Object.defineProperty(g0,"__esModule",{value:!0});g0.resolveSchema=g0.getCompilingSchema=g0.resolveRef=g0.compileSchema=g0.SchemaEnv=void 0;var Yt=W(),RM=cc(),$n=gr(),Xt=Gi(),f0=ae(),PM=Ki();class Xi{constructor(e){var t;this.refs={},this.dynamicAnchors={};let r;if(typeof e.schema=="object")r=e.schema;this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(t=e.baseId)!==null&&t!==void 0?t:(0,Xt.normalizeId)(r===null||r===void 0?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=r===null||r===void 0?void 0:r.$async,this.refs={}}}g0.SchemaEnv=Xi;function _m(e){let t=h0.call(this,e);if(t)return t;let r=(0,Xt.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:n,lines:o}=this.opts.code,{ownProperties:i}=this.opts,s=new Yt.CodeGen(this.scope,{es5:n,lines:o,ownProperties:i}),a;if(e.$async)a=s.scopeValue("Error",{ref:RM.default,code:Yt._`require("ajv/dist/runtime/validation_error").default`});let c=s.scopeName("validate");e.validateName=c;let u={gen:s,allErrors:this.opts.allErrors,data:$n.default.data,parentData:$n.default.parentData,parentDataProperty:$n.default.parentDataProperty,dataNames:[$n.default.data],dataPathArr:[Yt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Yt.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:Yt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:Yt._`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),(0,PM.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let p=s.toString();if(l=`${s.scopeRefs($n.default.scope)}return ${p}`,this.opts.code.process)l=this.opts.code.process(l,e);let d=Function(`${$n.default.self}`,`${$n.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:d}),d.errors=null,d.schema=e.schema,d.schemaEnv=e,e.$async)d.$async=!0;if(this.opts.code.source===!0)d.source={validateName:c,validateCode:p,scopeValues:s._values};if(this.opts.unevaluated){let{props:h,items:x}=u;if(d.evaluated={props:h instanceof Yt.Name?void 0:h,items:x instanceof Yt.Name?void 0:x,dynamicProps:h instanceof Yt.Name,dynamicItems:x instanceof Yt.Name},d.source)d.source.evaluated=(0,Yt.stringify)(d.evaluated)}return e.validate=d,e}catch(p){if(delete e.validate,delete e.validateName,l)this.logger.error("Error compiling schema, function code:",l);throw p}finally{this._compilations.delete(e)}}g0.compileSchema=_m;function zM(e,t,r){var n;r=(0,Xt.resolveUrl)(this.opts.uriResolver,t,r);let o=e.refs[r];if(o)return o;let i=CM.call(this,e,r);if(i===void 0){let s=(n=e.localRefs)===null||n===void 0?void 0:n[r],{schemaId:a}=this.opts;if(s)i=new Xi({schema:s,schemaId:a,root:e,baseId:t})}if(i===void 0)return;return e.refs[r]=OM.call(this,i)}g0.resolveRef=zM;function OM(e){if((0,Xt.inlineRef)(e.schema,this.opts.inlineRefs))return e.schema;return e.validate?e:_m.call(this,e)}function h0(e){for(let t of this._compilations)if(AM(t,e))return t}g0.getCompilingSchema=h0;function AM(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function CM(e,t){let r;while(typeof(r=this.refs[t])=="string")t=r;return r||this.schemas[t]||uc.call(this,e,t)}function uc(e,t){let r=this.opts.uriResolver.parse(t),n=(0,Xt._getFullPath)(this.opts.uriResolver,r),o=(0,Xt.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===o)return bm.call(this,r,e);let i=(0,Xt.normalizeId)(n),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=uc.call(this,e,s);if(typeof(a===null||a===void 0?void 0:a.schema)!=="object")return;return bm.call(this,r,a)}if(typeof(s===null||s===void 0?void 0:s.schema)!=="object")return;if(!s.validate)_m.call(this,s);if(i===(0,Xt.normalizeId)(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];if(u)o=(0,Xt.resolveUrl)(this.opts.uriResolver,o,u);return new Xi({schema:a,schemaId:c,root:e,baseId:o})}return bm.call(this,r,s)}g0.resolveSchema=uc;var IM=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function bm(e,{baseId:t,schema:r,root:n}){var o;if(((o=e.fragment)===null||o===void 0?void 0:o[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r==="boolean")return;let c=r[(0,f0.unescapeFragment)(a)];if(c===void 0)return;r=c;let u=typeof r==="object"&&r[this.opts.schemaId];if(!IM.has(a)&&u)t=(0,Xt.resolveUrl)(this.opts.uriResolver,t,u)}let i;if(typeof r!="boolean"&&r.$ref&&!(0,f0.schemaHasRulesButRef)(r,this.RULES)){let a=(0,Xt.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=uc.call(this,n,a)}let{schemaId:s}=this.opts;if(i=i||new Xi({schema:r,schemaId:s,root:n,baseId:t}),i.schema!==i.root.schema)return i;return}});var v0=_(function(LW,MM){MM.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var Sm=_(function(MW,S0){var qM=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),b0=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),wm=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),_0=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),UM=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function km(e){let t="",r=0,n=0;for(n=0;n<e.length;n++){if(r=e[n].charCodeAt(0),r===48)continue;if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[n];break}for(n+=1;n<e.length;n++){if(r=e[n].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[n]}return t}var FM=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function y0(e){return e.length=0,!0}function ZM(e,t,r){if(e.length){let n=km(e);if(n!=="")t.push(n);else return r.error=!0,!1;e.length=0}return!0}function BM(e){let t=0,r={error:!1,address:"",zone:""},n=[],o=[],i=!1,s=!1,a=ZM;for(let c=0;c<e.length;c++){let u=e[c];if(u==="["||u==="]")continue;if(u===":"){if(i===!0)s=!0;if(!a(o,n,r))break;if(++t>7){r.error=!0;break}if(c>0&&e[c-1]===":")i=!0;n.push(":");continue}else if(u==="%"){if(!a(o,n,r))break;a=y0}else{o.push(u);continue}}if(o.length)if(a===y0)r.zone=o.join("");else if(s)n.push(o.join(""));else n.push(km(o));return r.address=n.join(""),r}function w0(e){if(HM(e,":")<2)return{host:e,isIPV6:!1};let t=BM(e);if(!t.error){let{address:r,address:n}=t;if(t.zone)r+="%"+t.zone,n+="%25"+t.zone;return{host:r,isIPV6:!0,escapedHost:n}}else return{host:e,isIPV6:!1}}function HM(e,t){let r=0;for(let n=0;n<e.length;n++)if(e[n]===t)r++;return r}function VM(e){let t=e,r=[],n=-1,o=0;while(o=t.length){if(o===1)if(t===".")break;else if(t==="/"){r.push("/");break}else{r.push(t);break}else if(o===2){if(t[0]==="."){if(t[1]===".")break;else if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"){if(t[1]==="."||t[1]==="/"){r.push("/");break}}}else if(o===3){if(t==="/.."){if(r.length!==0)r.pop();r.push("/");break}}if(t[0]==="."){if(t[1]==="."){if(t[2]==="/"){t=t.slice(3);continue}}else if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"){if(t[1]==="."){if(t[2]==="/"){t=t.slice(2);continue}else if(t[2]==="."){if(t[3]==="/"){if(t=t.slice(3),r.length!==0)r.pop();continue}}}}if((n=t.indexOf("/",1))===-1){r.push(t);break}else r.push(t.slice(0,n)),t=t.slice(n)}return r.join("")}var GM={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},JM=/[@/?#:]/g,WM=/[@/?#]/g;function k0(e,t){let r=t?WM:JM;return r.lastIndex=0,e.replace(r,(n)=>GM[n])}function KM(e,t=!1){if(e.indexOf("%")===-1)return e;let r="";for(let n=0;n<e.length;n++){if(e[n]==="%"&&n+2<e.length){let o=e.slice(n+1,n+3);if(wm(o)){let i=o.toUpperCase(),s=String.fromCharCode(parseInt(i,16));if(t&&_0(s))r+=s;else r+="%"+i;n+=2;continue}}r+=e[n]}return r}function YM(e){let t="";for(let r=0;r<e.length;r++){if(e[r]==="%"&&r+2<e.length){let n=e.slice(r+1,r+3);if(wm(n)){let o=n.toUpperCase(),i=String.fromCharCode(parseInt(o,16));if(i!=="."&&_0(i))t+=i;else t+="%"+o;r+=2;continue}}if(UM(e[r]))t+=e[r];else t+=escape(e[r])}return t}function XM(e){let t="";for(let r=0;r<e.length;r++){if(e[r]==="%"&&r+2<e.length){let n=e.slice(r+1,r+3);if(wm(n)){t+="%"+n.toUpperCase(),r+=2;continue}}t+=escape(e[r])}return t}function QM(e){let t=[];if(e.userinfo!==void 0)t.push(e.userinfo),t.push("@");if(e.host!==void 0){let r=unescape(e.host);if(!b0(r)){let n=w0(r);if(n.isIPV6===!0)r=`[${n.escapedHost}]`;else r=k0(r,!1)}t.push(r)}if(typeof e.port==="number"||typeof e.port==="string")t.push(":"),t.push(String(e.port));return t.length?t.join(""):void 0}S0.exports={nonSimpleDomain:FM,recomposeAuthority:QM,reescapeHostDelimiters:k0,normalizePercentEncoding:KM,normalizePathEncoding:YM,escapePreservingEscapes:XM,removeDotSegments:VM,isIPv4:b0,isUUID:qM,normalizeIPv6:w0,stringArrayToHexStripped:km}});var P0=_(function(qW,R0){var{isUUID:eq}=Sm(),tq=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,rq=["http","https","ws","wss","urn","urn:uuid"];function nq(e){return rq.indexOf(e)!==-1}function $m(e){if(e.secure===!0)return!0;else if(e.secure===!1)return!1;else if(e.scheme)return e.scheme.length===3&&(e.scheme[0]==="w"||e.scheme[0]==="W")&&(e.scheme[1]==="s"||e.scheme[1]==="S")&&(e.scheme[2]==="s"||e.scheme[2]==="S");else return!1}function $0(e){if(!e.host)e.error=e.error||"HTTP URIs must have a host.";return e}function T0(e){let t=String(e.scheme).toLowerCase()==="https";if(e.port===(t?443:80)||e.port==="")e.port=void 0;if(!e.path)e.path="/";return e}function oq(e){return e.secure=$m(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function iq(e){if(e.port===($m(e)?443:80)||e.port==="")e.port=void 0;if(typeof e.secure==="boolean")e.scheme=e.secure?"wss":"ws",e.secure=void 0;if(e.resourceName){let[t,r]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=r,e.resourceName=void 0}return e.fragment=void 0,e}function sq(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(tq);if(r){let n=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let o=`${n}:${t.nid||e.nid}`,i=Tm(o);if(e.path=void 0,i)e=i.parse(e,t)}else e.error=e.error||"URN can not be parsed.";return e}function aq(e,t){if(e.nid===void 0)throw Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",n=e.nid.toLowerCase(),o=`${r}:${t.nid||n}`,i=Tm(o);if(i)e=i.serialize(e,t);let s=e,a=e.nss;return s.path=`${n||t.nid}:${a}`,t.skipEscape=!0,s}function cq(e,t){let r=e;if(r.uuid=r.nss,r.nss=void 0,!t.tolerant&&(!r.uuid||!eq(r.uuid)))r.error=r.error||"UUID is not valid.";return r}function uq(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var E0={scheme:"http",domainHost:!0,parse:$0,serialize:T0},lq={scheme:"https",domainHost:E0.domainHost,parse:$0,serialize:T0},pc={scheme:"ws",domainHost:!0,parse:oq,serialize:iq},pq={scheme:"wss",domainHost:pc.domainHost,parse:pc.parse,serialize:pc.serialize},dq={scheme:"urn",parse:sq,serialize:aq,skipNormalize:!0},mq={scheme:"urn:uuid",parse:cq,serialize:uq,skipNormalize:!0},dc={http:E0,https:lq,ws:pc,wss:pq,urn:dq,"urn:uuid":mq};Object.setPrototypeOf(dc,null);function Tm(e){return e&&(dc[e]||dc[e.toLowerCase()])||void 0}R0.exports={wsIsSecure:$m,SCHEMES:dc,isValidSchemeName:nq,getSchemeHandler:Tm}});var j0=_(function(UW,mc){var{normalizeIPv6:fq,removeDotSegments:Qi,recomposeAuthority:hq,normalizePercentEncoding:gq,normalizePathEncoding:xq,escapePreservingEscapes:vq,reescapeHostDelimiters:yq,isIPv4:bq,nonSimpleDomain:_q}=Sm(),{SCHEMES:wq,getSchemeHandler:O0}=P0();function kq(e,t){if(typeof e==="string")e=Rq(e,t);else if(typeof e==="object")e=So(Tn(e,t),t);return e}function Sq(e,t,r){let n=r?Object.assign({scheme:"null"},r):{scheme:"null"},o=A0(So(e,n),So(t,n),n,!0);return n.skipEscape=!0,Tn(o,n)}function A0(e,t,r,n){let o={};if(!n)e=So(Tn(e,r),r),t=So(Tn(t,r),r);if(r=r||{},!r.tolerant&&t.scheme)o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=Qi(t.path||""),o.query=t.query;else{if(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0)o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=Qi(t.path||""),o.query=t.query;else{if(!t.path)if(o.path=e.path,t.query!==void 0)o.query=t.query;else o.query=e.query;else{if(t.path[0]==="/")o.path=Qi(t.path);else{if((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path)o.path="/"+t.path;else if(!e.path)o.path=t.path;else o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path;o.path=Qi(o.path)}o.query=t.query}o.userinfo=e.userinfo,o.host=e.host,o.port=e.port}o.scheme=e.scheme}return o.fragment=t.fragment,o}function $q(e,t,r){let n=z0(e,r),o=z0(t,r);return n!==void 0&&o!==void 0&&n.toLowerCase()===o.toLowerCase()}function Tn(e,t){let r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},n=Object.assign({},t),o=[],i=O0(n.scheme||r.scheme);if(i&&i.serialize)i.serialize(r,n);if(r.path!==void 0)if(!n.skipEscape){if(r.path=vq(r.path),r.scheme!==void 0)r.path=r.path.split("%3A").join(":")}else r.path=gq(r.path);if(n.reference!=="suffix"&&r.scheme)o.push(r.scheme,":");let s=hq(r);if(s!==void 0){if(n.reference!=="suffix")o.push("//");if(o.push(s),r.path&&r.path[0]!=="/")o.push("/")}if(r.path!==void 0){let a=r.path;if(!n.absolutePath&&(!i||!i.absolutePath))a=Qi(a);if(s===void 0&&a[0]==="/"&&a[1]==="/")a="/%2F"+a.slice(2);o.push(a)}if(r.query!==void 0)o.push("?",r.query);if(r.fragment!==void 0)o.push("#",r.fragment);return o.join("")}var Tq=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function Eq(e,t){if(t[2]!==void 0&&e.path&&e.path[0]!=="/")return'URI path must start with "/" when authority is present.';if(typeof e.port==="number"&&(e.port<0||e.port>65535))return"URI port is malformed.";return}function C0(e,t){let r=Object.assign({},t),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},o=!1,i=!1;if(r.reference==="suffix")if(r.scheme)e=r.scheme+":"+e;else e="//"+e;let s=e.match(Tq);if(s){if(n.scheme=s[1],n.userinfo=s[3],n.host=s[4],n.port=parseInt(s[5],10),n.path=s[6]||"",n.query=s[7],n.fragment=s[8],isNaN(n.port))n.port=s[5];let a=Eq(n,s);if(a!==void 0)n.error=n.error||a,o=!0;if(n.host)if(bq(n.host)===!1){let l=fq(n.host);n.host=l.host.toLowerCase(),i=l.isIPV6}else i=!0;if(n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&n.query===void 0&&!n.path)n.reference="same-document";else if(n.scheme===void 0)n.reference="relative";else if(n.fragment===void 0)n.reference="absolute";else n.reference="uri";if(r.reference&&r.reference!=="suffix"&&r.reference!==n.reference)n.error=n.error||"URI is not a "+r.reference+" reference.";let c=O0(r.scheme||n.scheme);if(!r.unicodeSupport&&(!c||!c.unicodeSupport)){if(n.host&&(r.domainHost||c&&c.domainHost)&&i===!1&&_q(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(u){n.error=n.error||"Host's domain name can not be converted to ASCII: "+u}}if(!c||c&&!c.skipNormalize){if(e.indexOf("%")!==-1){if(n.scheme!==void 0)n.scheme=unescape(n.scheme);if(n.host!==void 0)n.host=yq(unescape(n.host),i)}if(n.path)n.path=xq(n.path);if(n.fragment)try{n.fragment=encodeURI(decodeURIComponent(n.fragment))}catch{n.error=n.error||"URI malformed"}}if(c&&c.parse)c.parse(n,r)}else n.error=n.error||"URI can not be parsed.";return{parsed:n,malformedAuthorityOrPort:o}}function So(e,t){return C0(e,t).parsed}function Rq(e,t){return I0(e,t).normalized}function I0(e,t){let{parsed:r,malformedAuthorityOrPort:n}=C0(e,t);return{normalized:n?e:Tn(r,t),malformedAuthorityOrPort:n}}function z0(e,t){if(typeof e==="string"){let{normalized:r,malformedAuthorityOrPort:n}=I0(e,t);return n?void 0:r}if(typeof e==="object")return Tn(e,t)}var Em={SCHEMES:wq,normalize:kq,resolve:Sq,resolveComponent:A0,equal:$q,serialize:Tn,parse:So};mc.exports=Em;mc.exports.default=Em;mc.exports.fastUri=Em});var L0=_(function(D0){Object.defineProperty(D0,"__esModule",{value:!0});var N0=j0();N0.code='require("ajv/dist/runtime/uri").default';D0.default=N0});var V0=_(function(vr){Object.defineProperty(vr,"__esModule",{value:!0});vr.CodeGen=vr.Name=vr.nil=vr.stringify=vr.str=vr._=vr.KeywordCxt=void 0;var zq=Ki();Object.defineProperty(vr,"KeywordCxt",{enumerable:!0,get:function(){return zq.KeywordCxt}});var $o=W();Object.defineProperty(vr,"_",{enumerable:!0,get:function(){return $o._}});Object.defineProperty(vr,"str",{enumerable:!0,get:function(){return $o.str}});Object.defineProperty(vr,"stringify",{enumerable:!0,get:function(){return $o.stringify}});Object.defineProperty(vr,"nil",{enumerable:!0,get:function(){return $o.nil}});Object.defineProperty(vr,"Name",{enumerable:!0,get:function(){return $o.Name}});Object.defineProperty(vr,"CodeGen",{enumerable:!0,get:function(){return $o.CodeGen}});var Oq=cc(),Z0=Yi(),Aq=im(),es=lc(),Cq=W(),ts=Gi(),fc=Vi(),Pm=ae(),M0=v0(),Iq=L0(),B0=(e,t)=>new RegExp(e,t);B0.code="new RegExp";var jq=["removeAdditional","useDefaults","coerceTypes"],Nq=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),Dq={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},Lq={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},q0=200;function Mq(e){var t,r,n,o,i,s,a,c,u,l,p,m,d,h,x,y,g,b,k,z,I,H,me,K,lt;let tt=e.strict,Ze=(t=e.code)===null||t===void 0?void 0:t.optimize,Je=Ze===!0||Ze===void 0?1:Ze||0,tr=(n=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:B0,pt=(o=e.uriResolver)!==null&&o!==void 0?o:Iq.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:tt)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:tt)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:tt)!==null&&l!==void 0?l:"log",strictTuples:(m=(p=e.strictTuples)!==null&&p!==void 0?p:tt)!==null&&m!==void 0?m:"log",strictRequired:(h=(d=e.strictRequired)!==null&&d!==void 0?d:tt)!==null&&h!==void 0?h:!1,code:e.code?{...e.code,optimize:Je,regExp:tr}:{optimize:Je,regExp:tr},loopRequired:(x=e.loopRequired)!==null&&x!==void 0?x:q0,loopEnum:(y=e.loopEnum)!==null&&y!==void 0?y:q0,meta:(g=e.meta)!==null&&g!==void 0?g:!0,messages:(b=e.messages)!==null&&b!==void 0?b:!0,inlineRefs:(k=e.inlineRefs)!==null&&k!==void 0?k:!0,schemaId:(z=e.schemaId)!==null&&z!==void 0?z:"$id",addUsedSchema:(I=e.addUsedSchema)!==null&&I!==void 0?I:!0,validateSchema:(H=e.validateSchema)!==null&&H!==void 0?H:!0,validateFormats:(me=e.validateFormats)!==null&&me!==void 0?me:!0,unicodeRegExp:(K=e.unicodeRegExp)!==null&&K!==void 0?K:!0,int32range:(lt=e.int32range)!==null&<!==void 0?lt:!0,uriResolver:pt}}class hc{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...Mq(e)};let{es5:t,lines:r}=this.opts.code;this.scope=new Cq.ValueScope({scope:{},prefixes:Nq,es5:t,lines:r}),this.logger=Hq(e.logger);let n=e.validateFormats;if(e.validateFormats=!1,this.RULES=(0,Aq.getRules)(),U0.call(this,Dq,e,"NOT SUPPORTED"),U0.call(this,Lq,e,"DEPRECATED","warn"),this._metaOpts=Zq.call(this),e.formats)Uq.call(this);if(this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords)Fq.call(this,e.keywords);if(typeof e.meta=="object")this.addMetaSchema(e.meta);qq.call(this),e.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:r}=this.opts,n=M0;if(r==="id")n={...M0},n.id=n.$id,delete n.$id;if(t&&e)this.addMetaSchema(n,n[r],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[t]||e:void 0}validate(e,t){let r;if(typeof e=="string"){if(r=this.getSchema(e),!r)throw Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);let n=r(t);if(!("$async"in r))this.errors=r.errors;return n}compile(e,t){let r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if(typeof this.opts.loadSchema!="function")throw Error("options.loadSchema should be a function");let{loadSchema:r}=this.opts;return n.call(this,e,t);async function n(u,l){await o.call(this,u.$schema);let p=this._addSchema(u,l);return p.validate||i.call(this,p)}async function o(u){if(u&&!this.getSchema(u))await n.call(this,{$ref:u},!0)}async function i(u){try{return this._compileSchemaEnv(u)}catch(l){if(!(l instanceof Z0.default))throw l;return s.call(this,l),await a.call(this,l.missingSchema),i.call(this,u)}}function s({missingSchema:u,missingRef:l}){if(this.refs[u])throw Error(`AnySchema ${u} is loaded but ${l} cannot be resolved`)}async function a(u){let l=await c.call(this,u);if(!this.refs[u])await o.call(this,l.$schema);if(!this.refs[u])this.addSchema(l,u,t)}async function c(u){let l=this._loading[u];if(l)return l;try{return await(this._loading[u]=r(u))}finally{delete this._loading[u]}}}addSchema(e,t,r,n=this.opts.validateSchema){if(Array.isArray(e)){for(let i of e)this.addSchema(i,void 0,r,n);return this}let o;if(typeof e==="object"){let{schemaId:i}=this.opts;if(o=e[i],o!==void 0&&typeof o!="string")throw Error(`schema ${i} must be string`)}return t=(0,ts.normalizeId)(t||o),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,n,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){if(typeof e=="boolean")return!0;let r;if(r=e.$schema,r!==void 0&&typeof r!="string")throw Error("$schema must be a string");if(r=r||this.opts.defaultMeta||this.defaultMeta(),!r)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(r,e);if(!n&&t){let o="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(o);else throw Error(o)}return n}getSchema(e){let t;while(typeof(t=F0.call(this,e))=="string")e=t;if(t===void 0){let{schemaId:r}=this.opts,n=new es.SchemaEnv({schema:{},schemaId:r});if(t=es.resolveSchema.call(this,n,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let t=F0.call(this,e);if(typeof t=="object")this._cache.delete(t.schema);return delete this.schemas[e],delete this.refs[e],this}case"object":{let t=e;this._cache.delete(t);let r=e[this.opts.schemaId];if(r)r=(0,ts.normalizeId)(r),delete this.schemas[r],delete this.refs[r];return this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if(typeof e=="string"){if(r=e,typeof t=="object")this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r}else if(typeof e=="object"&&t===void 0){if(t=e,r=t.keyword,Array.isArray(r)&&!r.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(Gq.call(this,r,t),!t)return(0,Pm.eachItem)(r,(o)=>Rm.call(this,o)),this;Wq.call(this,t);let n={...t,type:(0,fc.getJSONTypes)(t.type),schemaType:(0,fc.getJSONTypes)(t.schemaType)};return(0,Pm.eachItem)(r,n.type.length===0?(o)=>Rm.call(this,o,n):(o)=>n.type.forEach((i)=>Rm.call(this,o,n,i))),this}getKeyword(e){let t=this.RULES.all[e];return typeof t=="object"?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(let r of t.rules){let n=r.rules.findIndex((o)=>o.keyword===e);if(n>=0)r.rules.splice(n,1)}return this}addFormat(e,t){if(typeof t=="string")t=new RegExp(t);return this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){if(!e||e.length===0)return"No errors";return e.map((n)=>`${r}${n.instancePath} ${n.message}`).reduce((n,o)=>n+t+o)}$dataMetaSchema(e,t){let r=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let n of t){let o=n.split("/").slice(1),i=e;for(let s of o)i=i[s];for(let s in r){let a=r[s];if(typeof a!="object")continue;let{$data:c}=a.definition,u=i[s];if(c&&u)i[s]=H0(u)}}return e}_removeAllSchemas(e,t){for(let r in e){let n=e[r];if(!t||t.test(r)){if(typeof n=="string")delete e[r];else if(n&&!n.meta)this._cache.delete(n.schema),delete e[r]}}}_addSchema(e,t,r,n=this.opts.validateSchema,o=this.opts.addUsedSchema){let i,{schemaId:s}=this.opts;if(typeof e=="object")i=e[s];else if(this.opts.jtd)throw Error("schema must be object");else if(typeof e!="boolean")throw Error("schema must be object or boolean");let a=this._cache.get(e);if(a!==void 0)return a;r=(0,ts.normalizeId)(i||r);let c=ts.getSchemaRefs.call(this,e,r);if(a=new es.SchemaEnv({schema:e,schemaId:s,meta:t,baseId:r,localRefs:c}),this._cache.set(a.schema,a),o&&!r.startsWith("#")){if(r)this._checkUnique(r);this.refs[r]=a}if(n)this.validateSchema(e,!0);return a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta)this._compileMetaSchema(e);else es.compileSchema.call(this,e);if(!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{es.compileSchema.call(this,e)}finally{this.opts=t}}}hc.ValidationError=Oq.default;hc.MissingRefError=Z0.default;vr.default=hc;function U0(e,t,r,n="error"){for(let o in e){let i=o;if(i in t)this.logger[n](`${r}: option ${o}. ${e[i]}`)}}function F0(e){return e=(0,ts.normalizeId)(e),this.schemas[e]||this.refs[e]}function qq(){let e=this.opts.schemas;if(!e)return;if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function Uq(){for(let e in this.opts.formats){let t=this.opts.formats[e];if(t)this.addFormat(e,t)}}function Fq(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let r=e[t];if(!r.keyword)r.keyword=t;this.addKeyword(r)}}function Zq(){let e={...this.opts};for(let t of jq)delete e[t];return e}var Bq={log(){},warn(){},error(){}};function Hq(e){if(e===!1)return Bq;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}var Vq=/^[a-z_$][a-z0-9_$:-]*$/i;function Gq(e,t){let{RULES:r}=this;if((0,Pm.eachItem)(e,(n)=>{if(r.keywords[n])throw Error(`Keyword ${n} is already defined`);if(!Vq.test(n))throw Error(`Keyword ${n} has invalid name`)}),!t)return;if(t.$data&&!(("code"in t)||("validate"in t)))throw Error('$data keyword must have "code" or "validate" function')}function Rm(e,t,r){var n;let o=t===null||t===void 0?void 0:t.post;if(r&&o)throw Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=o?i.post:i.rules.find(({type:c})=>c===r);if(!s)s={type:r,rules:[]},i.rules.push(s);if(i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:(0,fc.getJSONTypes)(t.type),schemaType:(0,fc.getJSONTypes)(t.schemaType)}};if(t.before)Jq.call(this,s,a,t.before);else s.rules.push(a);i.all[e]=a,(n=t.implements)===null||n===void 0||n.forEach((c)=>this.addKeyword(c))}function Jq(e,t,r){let n=e.rules.findIndex((o)=>o.keyword===r);if(n>=0)e.rules.splice(n,0,t);else e.rules.push(t),this.logger.warn(`rule ${r} is not defined`)}function Wq(e){let{metaSchema:t}=e;if(t===void 0)return;if(e.$data&&this.opts.$data)t=H0(t);e.validateSchema=this.compile(t,!0)}var Kq={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function H0(e){return{anyOf:[e,Kq]}}});var J0=_(function(G0){Object.defineProperty(G0,"__esModule",{value:!0});var Qq={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};G0.default=Qq});var ek=_(function(X0){Object.defineProperty(X0,"__esModule",{value:!0});X0.callRef=X0.getValidate=void 0;var t2=Yi(),W0=jt(),vt=W(),To=gr(),K0=lc(),gc=ae(),r2={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:n}=e,{baseId:o,schemaEnv:i,validateName:s,opts:a,self:c}=n,{root:u}=i;if((r==="#"||r==="#/")&&o===u.baseId)return p();let l=K0.resolveRef.call(c,u,o,r);if(l===void 0)throw new t2.default(n.opts.uriResolver,o,r);if(l instanceof K0.SchemaEnv)return m(l);return d(l);function p(){if(i===u)return xc(e,s,i,i.$async);let h=t.scopeValue("root",{ref:u});return xc(e,vt._`${h}.validate`,u,u.$async)}function m(h){let x=Y0(e,h);xc(e,x,h,h.$async)}function d(h){let x=t.scopeValue("schema",a.code.source===!0?{ref:h,code:(0,vt.stringify)(h)}:{ref:h}),y=t.name("valid"),g=e.subschema({schema:h,dataTypes:[],schemaPath:vt.nil,topSchemaRef:x,errSchemaPath:r},y);e.mergeEvaluated(g),e.ok(y)}}};function Y0(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):vt._`${r.scopeValue("wrapper",{ref:t})}.validate`}X0.getValidate=Y0;function xc(e,t,r,n){let{gen:o,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?To.default.this:vt.nil;if(n)l();else p();function l(){if(!a.$async)throw Error("async schema referenced by sync schema");let h=o.let("valid");o.try(()=>{if(o.code(vt._`await ${(0,W0.callValidateCode)(e,t,u)}`),d(t),!s)o.assign(h,!0)},(x)=>{if(o.if(vt._`!(${x} instanceof ${i.ValidationError})`,()=>o.throw(x)),m(x),!s)o.assign(h,!1)}),e.ok(h)}function p(){e.result((0,W0.callValidateCode)(e,t,u),()=>d(t),()=>m(t))}function m(h){let x=vt._`${h}.errors`;o.assign(To.default.vErrors,vt._`${To.default.vErrors} === null ? ${x} : ${To.default.vErrors}.concat(${x})`),o.assign(To.default.errors,vt._`${To.default.vErrors}.length`)}function d(h){var x;if(!i.opts.unevaluated)return;let y=(x=r===null||r===void 0?void 0:r.validate)===null||x===void 0?void 0:x.evaluated;if(i.props!==!0)if(y&&!y.dynamicProps){if(y.props!==void 0)i.props=gc.mergeEvaluated.props(o,y.props,i.props)}else{let g=o.var("props",vt._`${h}.evaluated.props`);i.props=gc.mergeEvaluated.props(o,g,i.props,vt.Name)}if(i.items!==!0)if(y&&!y.dynamicItems){if(y.items!==void 0)i.items=gc.mergeEvaluated.items(o,y.items,i.items)}else{let g=o.var("items",vt._`${h}.evaluated.items`);i.items=gc.mergeEvaluated.items(o,g,i.items,vt.Name)}}}X0.callRef=xc;X0.default=r2});var rk=_(function(tk){Object.defineProperty(tk,"__esModule",{value:!0});var i2=J0(),s2=ek(),a2=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",i2.default,s2.default];tk.default=a2});var ok=_(function(nk){Object.defineProperty(nk,"__esModule",{value:!0});var vc=W(),Br=vc.operators,yc={maximum:{okStr:"<=",ok:Br.LTE,fail:Br.GT},minimum:{okStr:">=",ok:Br.GTE,fail:Br.LT},exclusiveMaximum:{okStr:"<",ok:Br.LT,fail:Br.GTE},exclusiveMinimum:{okStr:">",ok:Br.GT,fail:Br.LTE}},u2={message:({keyword:e,schemaCode:t})=>vc.str`must be ${yc[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>vc._`{comparison: ${yc[e].okStr}, limit: ${t}}`},l2={keyword:Object.keys(yc),type:"number",schemaType:"number",$data:!0,error:u2,code(e){let{keyword:t,data:r,schemaCode:n}=e;e.fail$data(vc._`${r} ${yc[t].fail} ${n} || isNaN(${r})`)}};nk.default=l2});var sk=_(function(ik){Object.defineProperty(ik,"__esModule",{value:!0});var rs=W(),d2={message:({schemaCode:e})=>rs.str`must be multiple of ${e}`,params:({schemaCode:e})=>rs._`{multipleOf: ${e}}`},m2={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:d2,code(e){let{gen:t,data:r,schemaCode:n,it:o}=e,i=o.opts.multipleOfPrecision,s=t.let("res"),a=i?rs._`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:rs._`${s} !== parseInt(${s})`;e.fail$data(rs._`(${n} === 0 || (${s} = ${r}/${n}, ${a}))`)}};ik.default=m2});var uk=_(function(ck){Object.defineProperty(ck,"__esModule",{value:!0});function ak(e){let t=e.length,r=0,n=0,o;while(n<t)if(r++,o=e.charCodeAt(n++),o>=55296&&o<=56319&&n<t){if(o=e.charCodeAt(n),(o&64512)===56320)n++}return r}ck.default=ak;ak.code='require("ajv/dist/runtime/ucs2length").default'});var pk=_(function(lk){Object.defineProperty(lk,"__esModule",{value:!0});var En=W(),g2=ae(),x2=uk(),v2={message({keyword:e,schemaCode:t}){let r=e==="maxLength"?"more":"fewer";return En.str`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>En._`{limit: ${e}}`},y2={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:v2,code(e){let{keyword:t,data:r,schemaCode:n,it:o}=e,i=t==="maxLength"?En.operators.GT:En.operators.LT,s=o.opts.unicode===!1?En._`${r}.length`:En._`${(0,g2.useFunc)(e.gen,x2.default)}(${r})`;e.fail$data(En._`${s} ${i} ${n}`)}};lk.default=y2});var mk=_(function(dk){Object.defineProperty(dk,"__esModule",{value:!0});var _2=jt(),w2=ae(),Eo=W(),k2={message:({schemaCode:e})=>Eo.str`must match pattern "${e}"`,params:({schemaCode:e})=>Eo._`{pattern: ${e}}`},S2={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:k2,code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:i,it:s}=e,a=s.opts.unicodeRegExp?"u":"";if(n){let{regExp:c}=s.opts.code,u=c.code==="new RegExp"?Eo._`new RegExp`:(0,w2.useFunc)(t,c),l=t.let("valid");t.try(()=>t.assign(l,Eo._`${u}(${i}, ${a}).test(${r})`),()=>t.assign(l,!1)),e.fail$data(Eo._`!${l}`)}else{let c=(0,_2.usePattern)(e,o);e.fail$data(Eo._`!${c}.test(${r})`)}}};dk.default=S2});var hk=_(function(fk){Object.defineProperty(fk,"__esModule",{value:!0});var ns=W(),T2={message({keyword:e,schemaCode:t}){let r=e==="maxProperties"?"more":"fewer";return ns.str`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>ns._`{limit: ${e}}`},E2={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:T2,code(e){let{keyword:t,data:r,schemaCode:n}=e,o=t==="maxProperties"?ns.operators.GT:ns.operators.LT;e.fail$data(ns._`Object.keys(${r}).length ${o} ${n}`)}};fk.default=E2});var xk=_(function(gk){Object.defineProperty(gk,"__esModule",{value:!0});var os=jt(),is=W(),P2=ae(),z2={message:({params:{missingProperty:e}})=>is.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>is._`{missingProperty: ${e}}`},O2={keyword:"required",type:"object",schemaType:"array",$data:!0,error:z2,code(e){let{gen:t,schema:r,schemaCode:n,data:o,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors)u();else l();if(a.strictRequired){let d=e.parentSchema.properties,{definedProperties:h}=e.it;for(let x of r)if((d===null||d===void 0?void 0:d[x])===void 0&&!h.has(x)){let y=s.schemaEnv.baseId+s.errSchemaPath,g=`required property "${x}" is not defined at "${y}" (strictRequired)`;(0,P2.checkStrictMode)(s,g,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(is.nil,p);else for(let d of r)(0,os.checkReportMissingProp)(e,d)}function l(){let d=t.let("missing");if(c||i){let h=t.let("valid",!0);e.block$data(h,()=>m(d,h)),e.ok(h)}else t.if((0,os.checkMissingProp)(e,r,d)),(0,os.reportMissingProp)(e,d),t.else()}function p(){t.forOf("prop",n,(d)=>{e.setParams({missingProperty:d}),t.if((0,os.noPropertyInData)(t,o,d,a.ownProperties),()=>e.error())})}function m(d,h){e.setParams({missingProperty:d}),t.forOf(d,n,()=>{t.assign(h,(0,os.propertyInData)(t,o,d,a.ownProperties)),t.if((0,is.not)(h),()=>{e.error(),t.break()})},is.nil)}}};gk.default=O2});var yk=_(function(vk){Object.defineProperty(vk,"__esModule",{value:!0});var ss=W(),C2={message({keyword:e,schemaCode:t}){let r=e==="maxItems"?"more":"fewer";return ss.str`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>ss._`{limit: ${e}}`},I2={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:C2,code(e){let{keyword:t,data:r,schemaCode:n}=e,o=t==="maxItems"?ss.operators.GT:ss.operators.LT;e.fail$data(ss._`${r}.length ${o} ${n}`)}};vk.default=I2});var bc=_(function(_k){Object.defineProperty(_k,"__esModule",{value:!0});var bk=mm();bk.code='require("ajv/dist/runtime/equal").default';_k.default=bk});var kk=_(function(wk){Object.defineProperty(wk,"__esModule",{value:!0});var zm=Vi(),et=W(),D2=ae(),L2=bc(),M2={message:({params:{i:e,j:t}})=>et.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>et._`{i: ${e}, j: ${t}}`},q2={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:M2,code(e){let{gen:t,data:r,$data:n,schema:o,parentSchema:i,schemaCode:s,it:a}=e;if(!n&&!o)return;let c=t.let("valid"),u=i.items?(0,zm.getSchemaTypes)(i.items):[];e.block$data(c,l,et._`${s} === false`),e.ok(c);function l(){let h=t.let("i",et._`${r}.length`),x=t.let("j");e.setParams({i:h,j:x}),t.assign(c,!0),t.if(et._`${h} > 1`,()=>(p()?m:d)(h,x))}function p(){return u.length>0&&!u.some((h)=>h==="object"||h==="array")}function m(h,x){let y=t.name("item"),g=(0,zm.checkDataTypes)(u,y,a.opts.strictNumbers,zm.DataType.Wrong),b=t.const("indices",et._`{}`);t.for(et._`;${h}--;`,()=>{if(t.let(y,et._`${r}[${h}]`),t.if(g,et._`continue`),u.length>1)t.if(et._`typeof ${y} == "string"`,et._`${y} += "_"`);t.if(et._`typeof ${b}[${y}] == "number"`,()=>{t.assign(x,et._`${b}[${y}]`),e.error(),t.assign(c,!1).break()}).code(et._`${b}[${y}] = ${h}`)})}function d(h,x){let y=(0,D2.useFunc)(t,L2.default),g=t.name("outer");t.label(g).for(et._`;${h}--;`,()=>t.for(et._`${x} = ${h}; ${x}--;`,()=>t.if(et._`${y}(${r}[${h}], ${r}[${x}])`,()=>{e.error(),t.assign(c,!1).break(g)})))}}};wk.default=q2});var $k=_(function(Sk){Object.defineProperty(Sk,"__esModule",{value:!0});var Om=W(),F2=ae(),Z2=bc(),B2={message:"must be equal to constant",params:({schemaCode:e})=>Om._`{allowedValue: ${e}}`},H2={keyword:"const",$data:!0,error:B2,code(e){let{gen:t,data:r,$data:n,schemaCode:o,schema:i}=e;if(n||i&&typeof i=="object")e.fail$data(Om._`!${(0,F2.useFunc)(t,Z2.default)}(${r}, ${o})`);else e.fail(Om._`${i} !== ${r}`)}};Sk.default=H2});var Ek=_(function(Tk){Object.defineProperty(Tk,"__esModule",{value:!0});var as=W(),G2=ae(),J2=bc(),W2={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>as._`{allowedValues: ${e}}`},K2={keyword:"enum",schemaType:"array",$data:!0,error:W2,code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:i,it:s}=e;if(!n&&o.length===0)throw Error("enum must have non-empty array");let a=o.length>=s.opts.loopEnum,c,u=()=>c!==null&&c!==void 0?c:c=(0,G2.useFunc)(t,J2.default),l;if(a||n)l=t.let("valid"),e.block$data(l,p);else{if(!Array.isArray(o))throw Error("ajv implementation error");let d=t.const("vSchema",i);l=(0,as.or)(...o.map((h,x)=>m(d,x)))}e.pass(l);function p(){t.assign(l,!1),t.forOf("v",i,(d)=>t.if(as._`${u()}(${r}, ${d})`,()=>t.assign(l,!0).break()))}function m(d,h){let x=o[h];return typeof x==="object"&&x!==null?as._`${u()}(${r}, ${d}[${h}])`:as._`${r} === ${x}`}}};Tk.default=K2});var Pk=_(function(Rk){Object.defineProperty(Rk,"__esModule",{value:!0});var X2=ok(),Q2=sk(),eU=pk(),tU=mk(),rU=hk(),nU=xk(),oU=yk(),iU=kk(),sU=$k(),aU=Ek(),cU=[X2.default,Q2.default,eU.default,tU.default,rU.default,nU.default,oU.default,iU.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},sU.default,aU.default];Rk.default=cU});var Cm=_(function(Ok){Object.defineProperty(Ok,"__esModule",{value:!0});Ok.validateAdditionalItems=void 0;var Rn=W(),Am=ae(),lU={message:({params:{len:e}})=>Rn.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Rn._`{limit: ${e}}`},pU={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:lU,code(e){let{parentSchema:t,it:r}=e,{items:n}=t;if(!Array.isArray(n)){(0,Am.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}zk(e,n)}};function zk(e,t){let{gen:r,schema:n,data:o,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",Rn._`${o}.length`);if(n===!1)e.setParams({len:t.length}),e.pass(Rn._`${a} <= ${t.length}`);else if(typeof n=="object"&&!(0,Am.alwaysValidSchema)(s,n)){let u=r.var("valid",Rn._`${a} <= ${t.length}`);r.if((0,Rn.not)(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,(l)=>{if(e.subschema({keyword:i,dataProp:l,dataPropType:Am.Type.Num},u),!s.allErrors)r.if((0,Rn.not)(u),()=>r.break())})}}Ok.validateAdditionalItems=zk;Ok.default=pU});var Im=_(function(jk){Object.defineProperty(jk,"__esModule",{value:!0});jk.validateTuple=void 0;var Ck=W(),_c=ae(),mU=jt(),fU={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return Ik(e,"additionalItems",t);if(r.items=!0,(0,_c.alwaysValidSchema)(r,t))return;e.ok((0,mU.validateArray)(e))}};function Ik(e,t,r=e.schema){let{gen:n,parentSchema:o,data:i,keyword:s,it:a}=e;if(l(o),a.opts.unevaluated&&r.length&&a.items!==!0)a.items=_c.mergeEvaluated.items(n,r.length,a.items);let c=n.name("valid"),u=n.const("len",Ck._`${i}.length`);r.forEach((p,m)=>{if((0,_c.alwaysValidSchema)(a,p))return;n.if(Ck._`${u} > ${m}`,()=>e.subschema({keyword:s,schemaProp:m,dataProp:m},c)),e.ok(c)});function l(p){let{opts:m,errSchemaPath:d}=a,h=r.length,x=h===p.minItems&&(h===p.maxItems||p[t]===!1);if(m.strictTuples&&!x){let y=`"${s}" is ${h}-tuple, but minItems or maxItems/${t} are not specified or different at path "${d}"`;(0,_c.checkStrictMode)(a,y,m.strictTuples)}}}jk.validateTuple=Ik;jk.default=fU});var Lk=_(function(Dk){Object.defineProperty(Dk,"__esModule",{value:!0});var gU=Im(),xU={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:(e)=>(0,gU.validateTuple)(e,"items")};Dk.default=xU});var Uk=_(function(qk){Object.defineProperty(qk,"__esModule",{value:!0});var Mk=W(),yU=ae(),bU=jt(),_U=Cm(),wU={message:({params:{len:e}})=>Mk.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>Mk._`{limit: ${e}}`},kU={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:wU,code(e){let{schema:t,parentSchema:r,it:n}=e,{prefixItems:o}=r;if(n.items=!0,(0,yU.alwaysValidSchema)(n,t))return;if(o)(0,_U.validateAdditionalItems)(e,o);else e.ok((0,bU.validateArray)(e))}};qk.default=kU});var Zk=_(function(Fk){Object.defineProperty(Fk,"__esModule",{value:!0});var Nt=W(),wc=ae(),$U={message:({params:{min:e,max:t}})=>t===void 0?Nt.str`must contain at least ${e} valid item(s)`:Nt.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?Nt._`{minContains: ${e}}`:Nt._`{minContains: ${e}, maxContains: ${t}}`},TU={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:$U,code(e){let{gen:t,schema:r,parentSchema:n,data:o,it:i}=e,s,a,{minContains:c,maxContains:u}=n;if(i.opts.next)s=c===void 0?1:c,a=u;else s=1;let l=t.const("len",Nt._`${o}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){(0,wc.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,wc.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,wc.alwaysValidSchema)(i,r)){let x=Nt._`${l} >= ${s}`;if(a!==void 0)x=Nt._`${x} && ${l} <= ${a}`;e.pass(x);return}i.items=!0;let p=t.name("valid");if(a===void 0&&s===1)d(p,()=>t.if(p,()=>t.break()));else if(s===0){if(t.let(p,!0),a!==void 0)t.if(Nt._`${o}.length > 0`,m)}else t.let(p,!1),m();e.result(p,()=>e.reset());function m(){let x=t.name("_valid"),y=t.let("count",0);d(x,()=>t.if(x,()=>h(y)))}function d(x,y){t.forRange("i",0,l,(g)=>{e.subschema({keyword:"contains",dataProp:g,dataPropType:wc.Type.Num,compositeRule:!0},x),y()})}function h(x){if(t.code(Nt._`${x}++`),a===void 0)t.if(Nt._`${x} >= ${s}`,()=>t.assign(p,!0).break());else if(t.if(Nt._`${x} > ${a}`,()=>t.assign(p,!1).break()),s===1)t.assign(p,!0);else t.if(Nt._`${x} >= ${s}`,()=>t.assign(p,!0))}}};Fk.default=TU});var Wk=_(function(Vk){Object.defineProperty(Vk,"__esModule",{value:!0});Vk.validateSchemaDeps=Vk.validatePropertyDeps=Vk.error=void 0;var jm=W(),RU=ae(),cs=jt();Vk.error={message:({params:{property:e,depsCount:t,deps:r}})=>{let n=t===1?"property":"properties";return jm.str`must have ${n} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:n}})=>jm._`{property: ${e},
|
|
23
|
+
|| ${s} === "boolean" || ${o} === null`).assign(a,J._`[${o}]`)}}}function CN({gen:e,parentData:t,parentDataProperty:r},n){e.if(J._`${t} !== undefined`,()=>e.assign(J._`${t}[${r}]`,n))}function Qd(e,t,r,n=co.Correct){let o=n===co.Correct?J.operators.EQ:J.operators.NEQ,i;switch(e){case"null":return J._`${t} ${o} null`;case"array":i=J._`Array.isArray(${t})`;break;case"object":i=J._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s(J._`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return J._`typeof ${t} ${o} ${e}`}return n===co.Correct?i:J.not(i);function s(a=J.nil){return J.and(J._`typeof ${t} == "number"`,a,r?J._`isFinite(${t})`:J.nil)}}ow.checkDataType=Qd;function em(e,t,r,n){if(e.length===1)return Qd(e[0],t,r,n);let o,i=tw.toHash(e);if(i.array&&i.object){let s=J._`typeof ${t} != "object"`;o=i.null?s:J._`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else o=J.nil;if(i.number)delete i.integer;for(let s in i)o=J.and(o,Qd(s,t,r,n));return o}ow.checkDataTypes=em;var IN={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?J._`{type: ${e}}`:J._`{type: ${t}}`};function tm(e){let t=jN(e);RN.reportError(t,IN)}ow.reportTypeError=tm;function jN(e){let{gen:t,data:r,schema:n}=e,o=tw.schemaRefOrVal(e,n,"type");return{gen:t,keyword:"type",data:r,schema:n.type,schemaCode:o,schemaValue:o,parentSchema:n,params:{},it:e}}});var uw=b(function(aw){Object.defineProperty(aw,"__esModule",{value:!0});aw.assignDefaults=void 0;var uo=W(),FN=se();function ZN(e,t){let{properties:r,items:n}=e.schema;if(t==="object"&&r)for(let o in r)sw(e,o,r[o].default);else if(t==="array"&&Array.isArray(n))n.forEach((o,i)=>sw(e,i,o.default))}aw.assignDefaults=ZN;function sw(e,t,r){let{gen:n,compositeRule:o,data:i,opts:s}=e;if(r===void 0)return;let a=uo._`${i}${uo.getProperty(t)}`;if(o){FN.checkStrictMode(e,`default is ignored for: ${a}`);return}let c=uo._`${a} === undefined`;if(s.useDefaults==="empty")c=uo._`${c} || ${a} === null || ${a} === ""`;n.if(c,uo._`${a} = ${uo.stringify(r)}`)}});var Lt=b(function(dw){Object.defineProperty(dw,"__esModule",{value:!0});dw.validateUnion=dw.validateArray=dw.usePattern=dw.callValidateCode=dw.schemaProperties=dw.allSchemaProperties=dw.noPropertyInData=dw.propertyInData=dw.isOwnProperty=dw.hasPropFunc=dw.reportMissingProp=dw.checkMissingProp=dw.checkReportMissingProp=void 0;var $e=W(),rm=se(),qr=yr(),BN=se();function HN(e,t){let{gen:r,data:n,it:o}=e;r.if(om(r,n,t,o.opts.ownProperties),()=>{e.setParams({missingProperty:$e._`${t}`},!0),e.error()})}dw.checkReportMissingProp=HN;function VN({gen:e,data:t,it:{opts:r}},n,o){return $e.or(...n.map((i)=>$e.and(om(e,t,i,r.ownProperties),$e._`${o} = ${i}`)))}dw.checkMissingProp=VN;function GN(e,t){e.setParams({missingProperty:t},!0),e.error()}dw.reportMissingProp=GN;function lw(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:$e._`Object.prototype.hasOwnProperty`})}dw.hasPropFunc=lw;function nm(e,t,r){return $e._`${lw(e)}.call(${t}, ${r})`}dw.isOwnProperty=nm;function JN(e,t,r,n){let o=$e._`${t}${$e.getProperty(r)} !== undefined`;return n?$e._`${o} && ${nm(e,t,r)}`:o}dw.propertyInData=JN;function om(e,t,r,n){let o=$e._`${t}${$e.getProperty(r)} === undefined`;return n?$e.or(o,$e.not(nm(e,t,r))):o}dw.noPropertyInData=om;function pw(e){return e?Object.keys(e).filter((t)=>t!=="__proto__"):[]}dw.allSchemaProperties=pw;function WN(e,t){return pw(t).filter((r)=>!rm.alwaysValidSchema(e,t[r]))}dw.schemaProperties=WN;function KN({schemaCode:e,data:t,it:{gen:r,topSchemaRef:n,schemaPath:o,errorPath:i},it:s},a,c,u){let l=u?$e._`${e}, ${t}, ${n}${o}`:t,p=[[qr.default.instancePath,$e.strConcat(qr.default.instancePath,i)],[qr.default.parentData,s.parentData],[qr.default.parentDataProperty,s.parentDataProperty],[qr.default.rootData,qr.default.rootData]];if(s.opts.dynamicRef)p.push([qr.default.dynamicAnchors,qr.default.dynamicAnchors]);let m=$e._`${l}, ${r.object(...p)}`;return c!==$e.nil?$e._`${a}.call(${c}, ${m})`:$e._`${a}(${m})`}dw.callValidateCode=KN;var YN=$e._`new RegExp`;function XN({gen:e,it:{opts:t}},r){let n=t.unicodeRegExp?"u":"",{regExp:o}=t.code,i=o(r,n);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:$e._`${o.code==="new RegExp"?YN:BN.useFunc(e,o)}(${r}, ${n})`})}dw.usePattern=XN;function QN(e){let{gen:t,data:r,keyword:n,it:o}=e,i=t.name("valid");if(o.allErrors){let a=t.let("valid",!0);return s(()=>t.assign(a,!1)),a}return t.var(i,!0),s(()=>t.break()),i;function s(a){let c=t.const("len",$e._`${r}.length`);t.forRange("i",0,c,(u)=>{e.subschema({keyword:n,dataProp:u,dataPropType:rm.Type.Num},i),t.if($e.not(i),a)})}}dw.validateArray=QN;function eD(e){let{gen:t,schema:r,keyword:n,it:o}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(r.some((c)=>rm.alwaysValidSchema(o,c))&&!o.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:n,schemaProp:u,compositeRule:!0},a);if(t.assign(s,$e._`${s} || ${a}`),!e.mergeValidEvaluated(l,a))t.if($e.not(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}dw.validateUnion=eD});var vw=b(function(gw){Object.defineProperty(gw,"__esModule",{value:!0});gw.validateKeywordUsage=gw.validSchemaType=gw.funcKeywordCode=gw.macroKeywordCode=void 0;var pt=W(),yn=yr(),mD=Lt(),fD=Di();function hD(e,t){let{gen:r,keyword:n,schema:o,parentSchema:i,it:s}=e,a=t.macro.call(s.self,o,i,s),c=hw(r,n,a);if(s.opts.validateSchema!==!1)s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:pt.nil,errSchemaPath:`${s.errSchemaPath}/${n}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}gw.macroKeywordCode=hD;function gD(e,t){var r;let{gen:n,keyword:o,schema:i,parentSchema:s,$data:a,it:c}=e;vD(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=hw(n,o,u),p=n.let("valid");e.block$data(p,m),e.ok((r=t.valid)!==null&&r!==void 0?r:p);function m(){if(t.errors===!1){if(x(),t.modifying)fw(e);v(()=>e.error())}else{let g=t.async?d():h();if(t.modifying)fw(e);v(()=>xD(e,g))}}function d(){let g=n.let("ruleErrs",null);return n.try(()=>x(pt._`await `),(y)=>n.assign(p,!1).if(pt._`${y} instanceof ${c.ValidationError}`,()=>n.assign(g,pt._`${y}.errors`),()=>n.throw(y))),g}function h(){let g=pt._`${l}.errors`;return n.assign(g,null),x(pt.nil),g}function x(g=t.async?pt._`await `:pt.nil){let y=c.opts.passContext?yn.default.this:yn.default.self,w=!(("compile"in t)&&!a||t.schema===!1);n.assign(p,pt._`${g}${mD.callValidateCode(e,l,y,w)}`,t.modifying)}function v(g){var y;n.if(pt.not((y=t.valid)!==null&&y!==void 0?y:p),g)}}gw.funcKeywordCode=gD;function fw(e){let{gen:t,data:r,it:n}=e;t.if(n.parentData,()=>t.assign(r,pt._`${n.parentData}[${n.parentDataProperty}]`))}function xD(e,t){let{gen:r}=e;r.if(pt._`Array.isArray(${t})`,()=>{r.assign(yn.default.vErrors,pt._`${yn.default.vErrors} === null ? ${t} : ${yn.default.vErrors}.concat(${t})`).assign(yn.default.errors,pt._`${yn.default.vErrors}.length`),fD.extendErrors(e)},()=>e.error())}function vD({schemaEnv:e},t){if(t.async&&!e.$async)throw Error("async keyword in sync schema")}function hw(e,t,r){if(r===void 0)throw Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:pt.stringify(r)})}function yD(e,t,r=!1){return!t.length||t.some((n)=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||r&&typeof e>"u")}gw.validSchemaType=yD;function bD({schema:e,opts:t,self:r,errSchemaPath:n},o,i){if(Array.isArray(o.keyword)?!o.keyword.includes(i):o.keyword!==i)throw Error("ajv implementation error");let s=o.dependencies;if(s===null||s===void 0?void 0:s.some((a)=>!Object.prototype.hasOwnProperty.call(e,a)))throw Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(o.validateSchema){if(!o.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${n}": `+r.errorsText(o.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw Error(c)}}}gw.validateKeywordUsage=bD});var ww=b(function(bw){Object.defineProperty(bw,"__esModule",{value:!0});bw.extendSubschemaMode=bw.extendSubschemaData=bw.getSubschema=void 0;var ar=W(),yw=se();function SD(e,{keyword:t,schemaProp:r,schema:n,schemaPath:o,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&n!==void 0)throw Error('both "keyword" and "schema" passed, only one allowed');if(t!==void 0){let a=e.schema[t];return r===void 0?{schema:a,schemaPath:ar._`${e.schemaPath}${ar.getProperty(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:ar._`${e.schemaPath}${ar.getProperty(t)}${ar.getProperty(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${yw.escapeFragment(r)}`}}if(n!==void 0){if(o===void 0||i===void 0||s===void 0)throw Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:n,schemaPath:o,topSchemaRef:s,errSchemaPath:i}}throw Error('either "keyword" or "schema" must be passed')}bw.getSubschema=SD;function $D(e,t,{dataProp:r,dataPropType:n,data:o,dataTypes:i,propertyName:s}){if(o!==void 0&&r!==void 0)throw Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:p}=t,m=a.let("data",ar._`${t.data}${ar.getProperty(r)}`,!0);c(m),e.errorPath=ar.str`${u}${yw.getErrorPath(r,n,p.jsPropertySyntax)}`,e.parentDataProperty=ar._`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(o!==void 0){let u=o instanceof ar.Name?o:a.let("data",o,!0);if(c(u),s!==void 0)e.propertyName=s}if(i)e.dataTypes=i;function c(u){e.data=u,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,u]}}bw.extendSubschemaData=$D;function TD(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:n,createErrors:o,allErrors:i}){if(n!==void 0)e.compositeRule=n;if(o!==void 0)e.createErrors=o;if(i!==void 0)e.allErrors=i;e.jtdDiscriminator=t,e.jtdMetadata=r}bw.extendSubschemaMode=TD});var im=b(function(pW,kw){kw.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,o,i;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(o=n;o--!==0;)if(!e(t[o],r[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),n=i.length,n!==Object.keys(r).length)return!1;for(o=n;o--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[o]))return!1;for(o=n;o--!==0;){var s=i[o];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var $w=b(function(dW,Sw){var Ur=Sw.exports=function(e,t,r){if(typeof t=="function")r=t,t={};r=t.cb||r;var n=typeof r=="function"?r:r.pre||function(){},o=r.post||function(){};rc(t,n,o,e,"",e)};Ur.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Ur.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Ur.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Ur.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function rc(e,t,r,n,o,i,s,a,c,u){if(n&&typeof n=="object"&&!Array.isArray(n)){t(n,o,i,s,a,c,u);for(var l in n){var p=n[l];if(Array.isArray(p)){if(l in Ur.arrayKeywords)for(var m=0;m<p.length;m++)rc(e,t,r,p[m],o+"/"+l+"/"+m,i,o,l,n,m)}else if(l in Ur.propsKeywords){if(p&&typeof p=="object")for(var d in p)rc(e,t,r,p[d],o+"/"+l+"/"+PD(d),i,o,l,n,d)}else if(l in Ur.keywords||e.allKeys&&!(l in Ur.skipKeywords))rc(e,t,r,p,o+"/"+l,i,o,l,n)}r(n,o,i,s,a,c,u)}}function PD(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var Li=b(function(Pw){Object.defineProperty(Pw,"__esModule",{value:!0});Pw.getSchemaRefs=Pw.resolveUrl=Pw.normalizeId=Pw._getFullPath=Pw.getFullPath=Pw.inlineRef=void 0;var zD=se(),OD=im(),AD=$w(),CD=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function ID(e,t=!0){if(typeof e=="boolean")return!0;if(t===!0)return!sm(e);if(!t)return!1;return Tw(e)<=t}Pw.inlineRef=ID;var jD=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function sm(e){for(let t in e){if(jD.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(sm))return!0;if(typeof r=="object"&&sm(r))return!0}return!1}function Tw(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,CD.has(r))continue;if(typeof e[r]=="object")zD.eachItem(e[r],(n)=>t+=Tw(n));if(t===1/0)return 1/0}return t}function Ew(e,t="",r){if(r!==!1)t=lo(t);let n=e.parse(t);return Rw(e,n)}Pw.getFullPath=Ew;function Rw(e,t){return e.serialize(t).split("#")[0]+"#"}Pw._getFullPath=Rw;var ND=/#\/?$/;function lo(e){return e?e.replace(ND,""):""}Pw.normalizeId=lo;function DD(e,t,r){return r=lo(r),e.resolve(t,r)}Pw.resolveUrl=DD;var MD=/^[a-z_][-a-z0-9._]*$/i;function LD(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:n}=this.opts,o=lo(e[r]||t),i={"":o},s=Ew(n,o,!1),a={},c=new Set;return AD(e,{allKeys:!0},(p,m,d,h)=>{if(h===void 0)return;let x=s+m,v=i[h];if(typeof p[r]=="string")v=g.call(this,p[r]);y.call(this,p.$anchor),y.call(this,p.$dynamicAnchor),i[m]=v;function g(w){let P=this.opts.uriResolver.resolve;if(w=lo(v?P(v,w):w),c.has(w))throw l(w);c.add(w);let I=this.refs[w];if(typeof I=="string")I=this.refs[I];if(typeof I=="object")u(p,I.schema,w);else if(w!==lo(x))if(w[0]==="#")u(p,a[w],w),a[w]=p;else this.refs[w]=x;return w}function y(w){if(typeof w=="string"){if(!MD.test(w))throw Error(`invalid anchor "${w}"`);g.call(this,`#${w}`)}}}),a;function u(p,m,d){if(m!==void 0&&!OD(p,m))throw l(d)}function l(p){return Error(`reference "${p}" resolves to more than one schema`)}}Pw.getSchemaRefs=LD});var Fi=b(function(Hw){Object.defineProperty(Hw,"__esModule",{value:!0});Hw.getData=Hw.KeywordCxt=Hw.validateFunctionCode=void 0;var Iw=J_(),jw=Mi(),am=Xd(),nc=Mi(),HD=uw(),qi=vw(),cm=ww(),q=W(),B=yr(),VD=Li(),br=se(),Ui=Di();function GD(e){if(Mw(e)){if(Lw(e),Dw(e)){KD(e);return}}Nw(e,()=>Iw.topBoolOrEmptySchema(e))}Hw.validateFunctionCode=GD;function Nw({gen:e,validateName:t,schema:r,schemaEnv:n,opts:o},i){if(o.code.es5)e.func(t,q._`${B.default.data}, ${B.default.valCxt}`,n.$async,()=>{e.code(q._`"use strict"; ${Ow(r,o)}`),WD(e,o),e.code(i)});else e.func(t,q._`${B.default.data}, ${JD(o)}`,n.$async,()=>e.code(Ow(r,o)).code(i))}function JD(e){return q._`{${B.default.instancePath}="", ${B.default.parentData}, ${B.default.parentDataProperty}, ${B.default.rootData}=${B.default.data}${e.dynamicRef?q._`, ${B.default.dynamicAnchors}={}`:q.nil}}={}`}function WD(e,t){e.if(B.default.valCxt,()=>{if(e.var(B.default.instancePath,q._`${B.default.valCxt}.${B.default.instancePath}`),e.var(B.default.parentData,q._`${B.default.valCxt}.${B.default.parentData}`),e.var(B.default.parentDataProperty,q._`${B.default.valCxt}.${B.default.parentDataProperty}`),e.var(B.default.rootData,q._`${B.default.valCxt}.${B.default.rootData}`),t.dynamicRef)e.var(B.default.dynamicAnchors,q._`${B.default.valCxt}.${B.default.dynamicAnchors}`)},()=>{if(e.var(B.default.instancePath,q._`""`),e.var(B.default.parentData,q._`undefined`),e.var(B.default.parentDataProperty,q._`undefined`),e.var(B.default.rootData,B.default.data),t.dynamicRef)e.var(B.default.dynamicAnchors,q._`{}`)})}function KD(e){let{schema:t,opts:r,gen:n}=e;Nw(e,()=>{if(r.$comment&&t.$comment)Uw(e);if(tM(e),n.let(B.default.vErrors,null),n.let(B.default.errors,0),r.unevaluated)YD(e);qw(e),oM(e)});return}function YD(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",q._`${r}.evaluated`),t.if(q._`${e.evaluated}.dynamicProps`,()=>t.assign(q._`${e.evaluated}.props`,q._`undefined`)),t.if(q._`${e.evaluated}.dynamicItems`,()=>t.assign(q._`${e.evaluated}.items`,q._`undefined`))}function Ow(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?q._`/*# sourceURL=${r} */`:q.nil}function XD(e,t){if(Mw(e)){if(Lw(e),Dw(e)){QD(e,t);return}}Iw.boolOrEmptySchema(e,t)}function Dw({schema:e,self:t}){if(typeof e=="boolean")return!e;for(let r in e)if(t.RULES.all[r])return!0;return!1}function Mw(e){return typeof e.schema!="boolean"}function QD(e,t){let{schema:r,gen:n,opts:o}=e;if(o.$comment&&r.$comment)Uw(e);rM(e),nM(e);let i=n.const("_errs",B.default.errors);qw(e,i),n.var(t,q._`${i} === ${B.default.errors}`)}function Lw(e){br.checkUnknownRules(e),eM(e)}function qw(e,t){if(e.opts.jtd)return Aw(e,[],!1,t);let r=jw.getSchemaTypes(e.schema),n=jw.coerceAndCheckDataType(e,r);Aw(e,r,!n,t)}function eM(e){let{schema:t,errSchemaPath:r,opts:n,self:o}=e;if(t.$ref&&n.ignoreKeywordsWithRef&&br.schemaHasRulesButRef(t,o.RULES))o.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function tM(e){let{schema:t,opts:r}=e;if(t.default!==void 0&&r.useDefaults&&r.strictSchema)br.checkStrictMode(e,"default is ignored in the schema root")}function rM(e){let t=e.schema[e.opts.schemaId];if(t)e.baseId=VD.resolveUrl(e.opts.uriResolver,e.baseId,t)}function nM(e){if(e.schema.$async&&!e.schemaEnv.$async)throw Error("async schema in sync schema")}function Uw({gen:e,schemaEnv:t,schema:r,errSchemaPath:n,opts:o}){let i=r.$comment;if(o.$comment===!0)e.code(q._`${B.default.self}.logger.log(${i})`);else if(typeof o.$comment=="function"){let s=q.str`${n}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code(q._`${B.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function oM(e){let{gen:t,schemaEnv:r,validateName:n,ValidationError:o,opts:i}=e;if(r.$async)t.if(q._`${B.default.errors} === 0`,()=>t.return(B.default.data),()=>t.throw(q._`new ${o}(${B.default.vErrors})`));else{if(t.assign(q._`${n}.errors`,B.default.vErrors),i.unevaluated)iM(e);t.return(q._`${B.default.errors} === 0`)}}function iM({gen:e,evaluated:t,props:r,items:n}){if(r instanceof q.Name)e.assign(q._`${t}.props`,r);if(n instanceof q.Name)e.assign(q._`${t}.items`,n)}function Aw(e,t,r,n){let{gen:o,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!br.schemaHasRulesButRef(i,l))){o.block(()=>Zw(e,"$ref",l.all.$ref.definition));return}if(!c.jtd)sM(e,t);o.block(()=>{for(let m of l.rules)p(m);p(l.post)});function p(m){if(!am.shouldUseGroup(i,m))return;if(m.type){if(o.if(nc.checkDataType(m.type,s,c.strictNumbers)),Cw(e,m),t.length===1&&t[0]===m.type&&r)o.else(),nc.reportTypeError(e);o.endIf()}else Cw(e,m);if(!a)o.if(q._`${B.default.errors} === ${n||0}`)}}function Cw(e,t){let{gen:r,schema:n,opts:{useDefaults:o}}=e;if(o)HD.assignDefaults(e,t.type);r.block(()=>{for(let i of t.rules)if(am.shouldUseRule(n,i))Zw(e,i.keyword,i.definition,t.type)})}function sM(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;if(aM(e,t),!e.opts.allowUnionTypes)cM(e,t);uM(e,e.dataTypes)}function aM(e,t){if(!t.length)return;if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach((r)=>{if(!Fw(e.dataTypes,r))um(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),pM(e,t)}function cM(e,t){if(t.length>1&&!(t.length===2&&t.includes("null")))um(e,"use allowUnionTypes to allow union type keyword")}function uM(e,t){let r=e.self.RULES.all;for(let n in r){let o=r[n];if(typeof o=="object"&&am.shouldUseRule(e.schema,o)){let{type:i}=o.definition;if(i.length&&!i.some((s)=>lM(t,s)))um(e,`missing type "${i.join(",")}" for keyword "${n}"`)}}}function lM(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Fw(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function pM(e,t){let r=[];for(let n of e.dataTypes)if(Fw(t,n))r.push(n);else if(t.includes("integer")&&n==="number")r.push("integer");e.dataTypes=r}function um(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,br.checkStrictMode(e,t,e.opts.strictTypes)}class lm{constructor(e,t,r){if(qi.validateKeywordUsage(e,t,r),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=r,this.data=e.data,this.schema=e.schema[r],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=br.schemaRefOrVal(e,this.schema,r,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",Bw(this.$data,e));else if(this.schemaCode=this.schemaValue,!qi.validSchemaType(this.schema,t.schemaType,t.allowUndefined))throw Error(`${r} value must be ${JSON.stringify(t.schemaType)}`);if("code"in t?t.trackErrors:t.errors!==!1)this.errsCount=e.gen.const("_errs",B.default.errors)}result(e,t,r){this.failResult(q.not(e),t,r)}failResult(e,t,r){if(this.gen.if(e),r)r();else this.error();if(t){if(this.gen.else(),t(),this.allErrors)this.gen.endIf()}else if(this.allErrors)this.gen.endIf();else this.gen.else()}pass(e,t){this.failResult(q.not(e),void 0,t)}fail(e){if(e===void 0){if(this.error(),!this.allErrors)this.gen.if(!1);return}if(this.gen.if(e),this.error(),this.allErrors)this.gen.endIf();else this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);let{schemaCode:t}=this;this.fail(q._`${t} !== undefined && (${q.or(this.invalid$data(),e)})`)}error(e,t,r){if(t){this.setParams(t),this._error(e,r),this.setParams({});return}this._error(e,r)}_error(e,t){(e?Ui.reportExtraError:Ui.reportError)(this,this.def.error,t)}$dataError(){Ui.reportError(this,this.def.$dataError||Ui.keyword$DataError)}reset(){if(this.errsCount===void 0)throw Error('add "trackErrors" to keyword definition');Ui.resetErrorsCount(this.gen,this.errsCount)}ok(e){if(!this.allErrors)this.gen.if(e)}setParams(e,t){if(t)Object.assign(this.params,e);else this.params=e}block$data(e,t,r=q.nil){this.gen.block(()=>{this.check$data(e,r),t()})}check$data(e=q.nil,t=q.nil){if(!this.$data)return;let{gen:r,schemaCode:n,schemaType:o,def:i}=this;if(r.if(q.or(q._`${n} === undefined`,t)),e!==q.nil)r.assign(e,!0);if(o.length||i.validateSchema){if(r.elseIf(this.invalid$data()),this.$dataError(),e!==q.nil)r.assign(e,!1)}r.else()}invalid$data(){let{gen:e,schemaCode:t,schemaType:r,def:n,it:o}=this;return q.or(i(),s());function i(){if(r.length){if(!(t instanceof q.Name))throw Error("ajv implementation error");let a=Array.isArray(r)?r:[r];return q._`${nc.checkDataTypes(a,t,o.opts.strictNumbers,nc.DataType.Wrong)}`}return q.nil}function s(){if(n.validateSchema){let a=e.scopeValue("validate$data",{ref:n.validateSchema});return q._`!${a}(${t})`}return q.nil}}subschema(e,t){let r=cm.getSubschema(this.it,e);cm.extendSubschemaData(r,this.it,e),cm.extendSubschemaMode(r,e);let n={...this.it,...r,items:void 0,props:void 0};return XD(n,t),n}mergeEvaluated(e,t){let{it:r,gen:n}=this;if(!r.opts.unevaluated)return;if(r.props!==!0&&e.props!==void 0)r.props=br.mergeEvaluated.props(n,e.props,r.props,t);if(r.items!==!0&&e.items!==void 0)r.items=br.mergeEvaluated.items(n,e.items,r.items,t)}mergeValidEvaluated(e,t){let{it:r,gen:n}=this;if(r.opts.unevaluated&&(r.props!==!0||r.items!==!0))return n.if(t,()=>this.mergeEvaluated(e,q.Name)),!0}}Hw.KeywordCxt=lm;function Zw(e,t,r,n){let o=new lm(e,r,t);if("code"in r)r.code(o,n);else if(o.$data&&r.validate)qi.funcKeywordCode(o,r);else if("macro"in r)qi.macroKeywordCode(o,r);else if(r.compile||r.validate)qi.funcKeywordCode(o,r)}var dM=/^\/(?:[^~]|~0|~1)*$/,mM=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Bw(e,{dataLevel:t,dataNames:r,dataPathArr:n}){let o,i;if(e==="")return B.default.rootData;if(e[0]==="/"){if(!dM.test(e))throw Error(`Invalid JSON-pointer: ${e}`);o=e,i=B.default.rootData}else{let u=mM.exec(e);if(!u)throw Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(o=u[2],o==="#"){if(l>=t)throw Error(c("property/index",l));return n[t-l]}if(l>t)throw Error(c("data",l));if(i=r[t-l],!o)return i}let s=i,a=o.split("/");for(let u of a)if(u)i=q._`${i}${q.getProperty(br.unescapeJsonPointer(u))}`,s=q._`${s} && ${i}`;return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}Hw.getData=Bw});var oc=b(function(Jw){Object.defineProperty(Jw,"__esModule",{value:!0});class Gw extends Error{constructor(e){super("validation failed");this.errors=e,this.ajv=this.validation=!0}}Jw.default=Gw});var Zi=b(function(Kw){Object.defineProperty(Kw,"__esModule",{value:!0});var pm=Li();class Ww extends Error{constructor(e,t,r,n){super(n||`can't resolve reference ${r} from id ${t}`);this.missingRef=pm.resolveUrl(e,t,r),this.missingSchema=pm.normalizeId(pm.getFullPath(e,this.missingRef))}}Kw.default=Ww});var sc=b(function(Qw){Object.defineProperty(Qw,"__esModule",{value:!0});Qw.resolveSchema=Qw.getCompilingSchema=Qw.resolveRef=Qw.compileSchema=Qw.SchemaEnv=void 0;var Yt=W(),vM=oc(),bn=yr(),Xt=Li(),Yw=se(),yM=Fi();class Bi{constructor(e){var t;this.refs={},this.dynamicAnchors={};let r;if(typeof e.schema=="object")r=e.schema;this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=(t=e.baseId)!==null&&t!==void 0?t:Xt.normalizeId(r===null||r===void 0?void 0:r[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=r===null||r===void 0?void 0:r.$async,this.refs={}}}Qw.SchemaEnv=Bi;function mm(e){let t=Xw.call(this,e);if(t)return t;let r=Xt.getFullPath(this.opts.uriResolver,e.root.baseId),{es5:n,lines:o}=this.opts.code,{ownProperties:i}=this.opts,s=new Yt.CodeGen(this.scope,{es5:n,lines:o,ownProperties:i}),a;if(e.$async)a=s.scopeValue("Error",{ref:vM.default,code:Yt._`require("ajv/dist/runtime/validation_error").default`});let c=s.scopeName("validate");e.validateName=c;let u={gen:s,allErrors:this.opts.allErrors,data:bn.default.data,parentData:bn.default.parentData,parentDataProperty:bn.default.parentDataProperty,dataNames:[bn.default.data],dataPathArr:[Yt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:Yt.stringify(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:Yt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:Yt._`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),yM.validateFunctionCode(u),s.optimize(this.opts.code.optimize);let p=s.toString();if(l=`${s.scopeRefs(bn.default.scope)}return ${p}`,this.opts.code.process)l=this.opts.code.process(l,e);let d=Function(`${bn.default.self}`,`${bn.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:d}),d.errors=null,d.schema=e.schema,d.schemaEnv=e,e.$async)d.$async=!0;if(this.opts.code.source===!0)d.source={validateName:c,validateCode:p,scopeValues:s._values};if(this.opts.unevaluated){let{props:h,items:x}=u;if(d.evaluated={props:h instanceof Yt.Name?void 0:h,items:x instanceof Yt.Name?void 0:x,dynamicProps:h instanceof Yt.Name,dynamicItems:x instanceof Yt.Name},d.source)d.source.evaluated=Yt.stringify(d.evaluated)}return e.validate=d,e}catch(p){if(delete e.validate,delete e.validateName,l)this.logger.error("Error compiling schema, function code:",l);throw p}finally{this._compilations.delete(e)}}Qw.compileSchema=mm;function bM(e,t,r){var n;r=Xt.resolveUrl(this.opts.uriResolver,t,r);let o=e.refs[r];if(o)return o;let i=kM.call(this,e,r);if(i===void 0){let s=(n=e.localRefs)===null||n===void 0?void 0:n[r],{schemaId:a}=this.opts;if(s)i=new Bi({schema:s,schemaId:a,root:e,baseId:t})}if(i===void 0)return;return e.refs[r]=_M.call(this,i)}Qw.resolveRef=bM;function _M(e){if(Xt.inlineRef(e.schema,this.opts.inlineRefs))return e.schema;return e.validate?e:mm.call(this,e)}function Xw(e){for(let t of this._compilations)if(wM(t,e))return t}Qw.getCompilingSchema=Xw;function wM(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function kM(e,t){let r;while(typeof(r=this.refs[t])=="string")t=r;return r||this.schemas[t]||ic.call(this,e,t)}function ic(e,t){let r=this.opts.uriResolver.parse(t),n=Xt._getFullPath(this.opts.uriResolver,r),o=Xt.getFullPath(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===o)return dm.call(this,r,e);let i=Xt.normalizeId(n),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=ic.call(this,e,s);if(typeof(a===null||a===void 0?void 0:a.schema)!=="object")return;return dm.call(this,r,a)}if(typeof(s===null||s===void 0?void 0:s.schema)!=="object")return;if(!s.validate)mm.call(this,s);if(i===Xt.normalizeId(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];if(u)o=Xt.resolveUrl(this.opts.uriResolver,o,u);return new Bi({schema:a,schemaId:c,root:e,baseId:o})}return dm.call(this,r,s)}Qw.resolveSchema=ic;var SM=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function dm(e,{baseId:t,schema:r,root:n}){var o;if(((o=e.fragment)===null||o===void 0?void 0:o[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r==="boolean")return;let c=r[Yw.unescapeFragment(a)];if(c===void 0)return;r=c;let u=typeof r==="object"&&r[this.opts.schemaId];if(!SM.has(a)&&u)t=Xt.resolveUrl(this.opts.uriResolver,t,u)}let i;if(typeof r!="boolean"&&r.$ref&&!Yw.schemaHasRulesButRef(r,this.RULES)){let a=Xt.resolveUrl(this.opts.uriResolver,t,r.$ref);i=ic.call(this,n,a)}let{schemaId:s}=this.opts;if(i=i||new Bi({schema:r,schemaId:s,root:n,baseId:t}),i.schema!==i.root.schema)return i;return}});var t0=b(function(vW,PM){PM.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}});var gm=b(function(yW,a0){var zM=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),n0=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),fm=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),o0=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),OM=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function hm(e){let t="",r=0,n=0;for(n=0;n<e.length;n++){if(r=e[n].charCodeAt(0),r===48)continue;if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[n];break}for(n+=1;n<e.length;n++){if(r=e[n].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[n]}return t}var AM=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function r0(e){return e.length=0,!0}function CM(e,t,r){if(e.length){let n=hm(e);if(n!=="")t.push(n);else return r.error=!0,!1;e.length=0}return!0}function IM(e){let t=0,r={error:!1,address:"",zone:""},n=[],o=[],i=!1,s=!1,a=CM;for(let c=0;c<e.length;c++){let u=e[c];if(u==="["||u==="]")continue;if(u===":"){if(i===!0)s=!0;if(!a(o,n,r))break;if(++t>7){r.error=!0;break}if(c>0&&e[c-1]===":")i=!0;n.push(":");continue}else if(u==="%"){if(!a(o,n,r))break;a=r0}else{o.push(u);continue}}if(o.length)if(a===r0)r.zone=o.join("");else if(s)n.push(o.join(""));else n.push(hm(o));return r.address=n.join(""),r}function i0(e){if(jM(e,":")<2)return{host:e,isIPV6:!1};let t=IM(e);if(!t.error){let{address:r,address:n}=t;if(t.zone)r+="%"+t.zone,n+="%25"+t.zone;return{host:r,isIPV6:!0,escapedHost:n}}else return{host:e,isIPV6:!1}}function jM(e,t){let r=0;for(let n=0;n<e.length;n++)if(e[n]===t)r++;return r}function NM(e){let t=e,r=[],n=-1,o=0;while(o=t.length){if(o===1)if(t===".")break;else if(t==="/"){r.push("/");break}else{r.push(t);break}else if(o===2){if(t[0]==="."){if(t[1]===".")break;else if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"){if(t[1]==="."||t[1]==="/"){r.push("/");break}}}else if(o===3){if(t==="/.."){if(r.length!==0)r.pop();r.push("/");break}}if(t[0]==="."){if(t[1]==="."){if(t[2]==="/"){t=t.slice(3);continue}}else if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"){if(t[1]==="."){if(t[2]==="/"){t=t.slice(2);continue}else if(t[2]==="."){if(t[3]==="/"){if(t=t.slice(3),r.length!==0)r.pop();continue}}}}if((n=t.indexOf("/",1))===-1){r.push(t);break}else r.push(t.slice(0,n)),t=t.slice(n)}return r.join("")}var DM={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},MM=/[@/?#:]/g,LM=/[@/?#]/g;function s0(e,t){let r=t?LM:MM;return r.lastIndex=0,e.replace(r,(n)=>DM[n])}function qM(e,t=!1){if(e.indexOf("%")===-1)return e;let r="";for(let n=0;n<e.length;n++){if(e[n]==="%"&&n+2<e.length){let o=e.slice(n+1,n+3);if(fm(o)){let i=o.toUpperCase(),s=String.fromCharCode(parseInt(i,16));if(t&&o0(s))r+=s;else r+="%"+i;n+=2;continue}}r+=e[n]}return r}function UM(e){let t="";for(let r=0;r<e.length;r++){if(e[r]==="%"&&r+2<e.length){let n=e.slice(r+1,r+3);if(fm(n)){let o=n.toUpperCase(),i=String.fromCharCode(parseInt(o,16));if(i!=="."&&o0(i))t+=i;else t+="%"+o;r+=2;continue}}if(OM(e[r]))t+=e[r];else t+=escape(e[r])}return t}function FM(e){let t="";for(let r=0;r<e.length;r++){if(e[r]==="%"&&r+2<e.length){let n=e.slice(r+1,r+3);if(fm(n)){t+="%"+n.toUpperCase(),r+=2;continue}}t+=escape(e[r])}return t}function ZM(e){let t=[];if(e.userinfo!==void 0)t.push(e.userinfo),t.push("@");if(e.host!==void 0){let r=unescape(e.host);if(!n0(r)){let n=i0(r);if(n.isIPV6===!0)r=`[${n.escapedHost}]`;else r=s0(r,!1)}t.push(r)}if(typeof e.port==="number"||typeof e.port==="string")t.push(":"),t.push(String(e.port));return t.length?t.join(""):void 0}a0.exports={nonSimpleDomain:AM,recomposeAuthority:ZM,reescapeHostDelimiters:s0,normalizePercentEncoding:qM,normalizePathEncoding:UM,escapePreservingEscapes:FM,removeDotSegments:NM,isIPv4:n0,isUUID:zM,normalizeIPv6:i0,stringArrayToHexStripped:hm}});var d0=b(function(bW,p0){var{isUUID:BM}=gm(),HM=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,VM=["http","https","ws","wss","urn","urn:uuid"];function GM(e){return VM.indexOf(e)!==-1}function xm(e){if(e.secure===!0)return!0;else if(e.secure===!1)return!1;else if(e.scheme)return e.scheme.length===3&&(e.scheme[0]==="w"||e.scheme[0]==="W")&&(e.scheme[1]==="s"||e.scheme[1]==="S")&&(e.scheme[2]==="s"||e.scheme[2]==="S");else return!1}function c0(e){if(!e.host)e.error=e.error||"HTTP URIs must have a host.";return e}function u0(e){let t=String(e.scheme).toLowerCase()==="https";if(e.port===(t?443:80)||e.port==="")e.port=void 0;if(!e.path)e.path="/";return e}function JM(e){return e.secure=xm(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function WM(e){if(e.port===(xm(e)?443:80)||e.port==="")e.port=void 0;if(typeof e.secure==="boolean")e.scheme=e.secure?"wss":"ws",e.secure=void 0;if(e.resourceName){let[t,r]=e.resourceName.split("?");e.path=t&&t!=="/"?t:void 0,e.query=r,e.resourceName=void 0}return e.fragment=void 0,e}function KM(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(HM);if(r){let n=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let o=`${n}:${t.nid||e.nid}`,i=vm(o);if(e.path=void 0,i)e=i.parse(e,t)}else e.error=e.error||"URN can not be parsed.";return e}function YM(e,t){if(e.nid===void 0)throw Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",n=e.nid.toLowerCase(),o=`${r}:${t.nid||n}`,i=vm(o);if(i)e=i.serialize(e,t);let s=e,a=e.nss;return s.path=`${n||t.nid}:${a}`,t.skipEscape=!0,s}function XM(e,t){let r=e;if(r.uuid=r.nss,r.nss=void 0,!t.tolerant&&(!r.uuid||!BM(r.uuid)))r.error=r.error||"UUID is not valid.";return r}function QM(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var l0={scheme:"http",domainHost:!0,parse:c0,serialize:u0},eL={scheme:"https",domainHost:l0.domainHost,parse:c0,serialize:u0},ac={scheme:"ws",domainHost:!0,parse:JM,serialize:WM},tL={scheme:"wss",domainHost:ac.domainHost,parse:ac.parse,serialize:ac.serialize},rL={scheme:"urn",parse:KM,serialize:YM,skipNormalize:!0},nL={scheme:"urn:uuid",parse:XM,serialize:QM,skipNormalize:!0},cc={http:l0,https:eL,ws:ac,wss:tL,urn:rL,"urn:uuid":nL};Object.setPrototypeOf(cc,null);function vm(e){return e&&(cc[e]||cc[e.toLowerCase()])||void 0}p0.exports={wsIsSecure:xm,SCHEMES:cc,isValidSchemeName:GM,getSchemeHandler:vm}});var v0=b(function(_W,uc){var{normalizeIPv6:oL,removeDotSegments:Hi,recomposeAuthority:iL,normalizePercentEncoding:sL,normalizePathEncoding:aL,escapePreservingEscapes:cL,reescapeHostDelimiters:uL,isIPv4:lL,nonSimpleDomain:pL}=gm(),{SCHEMES:dL,getSchemeHandler:f0}=d0();function mL(e,t){if(typeof e==="string")e=vL(e,t);else if(typeof e==="object")e=po(_n(e,t),t);return e}function fL(e,t,r){let n=r?Object.assign({scheme:"null"},r):{scheme:"null"},o=h0(po(e,n),po(t,n),n,!0);return n.skipEscape=!0,_n(o,n)}function h0(e,t,r,n){let o={};if(!n)e=po(_n(e,r),r),t=po(_n(t,r),r);if(r=r||{},!r.tolerant&&t.scheme)o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=Hi(t.path||""),o.query=t.query;else{if(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0)o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=Hi(t.path||""),o.query=t.query;else{if(!t.path)if(o.path=e.path,t.query!==void 0)o.query=t.query;else o.query=e.query;else{if(t.path[0]==="/")o.path=Hi(t.path);else{if((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path)o.path="/"+t.path;else if(!e.path)o.path=t.path;else o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path;o.path=Hi(o.path)}o.query=t.query}o.userinfo=e.userinfo,o.host=e.host,o.port=e.port}o.scheme=e.scheme}return o.fragment=t.fragment,o}function hL(e,t,r){let n=m0(e,r),o=m0(t,r);return n!==void 0&&o!==void 0&&n.toLowerCase()===o.toLowerCase()}function _n(e,t){let r={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},n=Object.assign({},t),o=[],i=f0(n.scheme||r.scheme);if(i&&i.serialize)i.serialize(r,n);if(r.path!==void 0)if(!n.skipEscape){if(r.path=cL(r.path),r.scheme!==void 0)r.path=r.path.split("%3A").join(":")}else r.path=sL(r.path);if(n.reference!=="suffix"&&r.scheme)o.push(r.scheme,":");let s=iL(r);if(s!==void 0){if(n.reference!=="suffix")o.push("//");if(o.push(s),r.path&&r.path[0]!=="/")o.push("/")}if(r.path!==void 0){let a=r.path;if(!n.absolutePath&&(!i||!i.absolutePath))a=Hi(a);if(s===void 0&&a[0]==="/"&&a[1]==="/")a="/%2F"+a.slice(2);o.push(a)}if(r.query!==void 0)o.push("?",r.query);if(r.fragment!==void 0)o.push("#",r.fragment);return o.join("")}var gL=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function xL(e,t){if(t[2]!==void 0&&e.path&&e.path[0]!=="/")return'URI path must start with "/" when authority is present.';if(typeof e.port==="number"&&(e.port<0||e.port>65535))return"URI port is malformed.";return}function g0(e,t){let r=Object.assign({},t),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},o=!1,i=!1;if(r.reference==="suffix")if(r.scheme)e=r.scheme+":"+e;else e="//"+e;let s=e.match(gL);if(s){if(n.scheme=s[1],n.userinfo=s[3],n.host=s[4],n.port=parseInt(s[5],10),n.path=s[6]||"",n.query=s[7],n.fragment=s[8],isNaN(n.port))n.port=s[5];let a=xL(n,s);if(a!==void 0)n.error=n.error||a,o=!0;if(n.host)if(lL(n.host)===!1){let l=oL(n.host);n.host=l.host.toLowerCase(),i=l.isIPV6}else i=!0;if(n.scheme===void 0&&n.userinfo===void 0&&n.host===void 0&&n.port===void 0&&n.query===void 0&&!n.path)n.reference="same-document";else if(n.scheme===void 0)n.reference="relative";else if(n.fragment===void 0)n.reference="absolute";else n.reference="uri";if(r.reference&&r.reference!=="suffix"&&r.reference!==n.reference)n.error=n.error||"URI is not a "+r.reference+" reference.";let c=f0(r.scheme||n.scheme);if(!r.unicodeSupport&&(!c||!c.unicodeSupport)){if(n.host&&(r.domainHost||c&&c.domainHost)&&i===!1&&pL(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(u){n.error=n.error||"Host's domain name can not be converted to ASCII: "+u}}if(!c||c&&!c.skipNormalize){if(e.indexOf("%")!==-1){if(n.scheme!==void 0)n.scheme=unescape(n.scheme);if(n.host!==void 0)n.host=uL(unescape(n.host),i)}if(n.path)n.path=aL(n.path);if(n.fragment)try{n.fragment=encodeURI(decodeURIComponent(n.fragment))}catch{n.error=n.error||"URI malformed"}}if(c&&c.parse)c.parse(n,r)}else n.error=n.error||"URI can not be parsed.";return{parsed:n,malformedAuthorityOrPort:o}}function po(e,t){return g0(e,t).parsed}function vL(e,t){return x0(e,t).normalized}function x0(e,t){let{parsed:r,malformedAuthorityOrPort:n}=g0(e,t);return{normalized:n?e:_n(r,t),malformedAuthorityOrPort:n}}function m0(e,t){if(typeof e==="string"){let{normalized:r,malformedAuthorityOrPort:n}=x0(e,t);return n?void 0:r}if(typeof e==="object")return _n(e,t)}var ym={SCHEMES:dL,normalize:mL,resolve:fL,resolveComponent:h0,equal:hL,serialize:_n,parse:po};uc.exports=ym;uc.exports.default=ym;uc.exports.fastUri=ym});var _0=b(function(b0){Object.defineProperty(b0,"__esModule",{value:!0});var y0=v0();y0.code='require("ajv/dist/runtime/uri").default';b0.default=y0});var P0=b(function(_r){Object.defineProperty(_r,"__esModule",{value:!0});_r.CodeGen=_r.Name=_r.nil=_r.stringify=_r.str=_r._=_r.KeywordCxt=void 0;var bL=Fi();Object.defineProperty(_r,"KeywordCxt",{enumerable:!0,get:function(){return bL.KeywordCxt}});var mo=W();Object.defineProperty(_r,"_",{enumerable:!0,get:function(){return mo._}});Object.defineProperty(_r,"str",{enumerable:!0,get:function(){return mo.str}});Object.defineProperty(_r,"stringify",{enumerable:!0,get:function(){return mo.stringify}});Object.defineProperty(_r,"nil",{enumerable:!0,get:function(){return mo.nil}});Object.defineProperty(_r,"Name",{enumerable:!0,get:function(){return mo.Name}});Object.defineProperty(_r,"CodeGen",{enumerable:!0,get:function(){return mo.CodeGen}});var _L=oc(),T0=Zi(),wL=Yd(),Gi=sc(),kL=W(),Vi=Li(),lc=Mi(),_m=se(),w0=t0(),SL=_0(),E0=(e,t)=>new RegExp(e,t);E0.code="new RegExp";var $L=["removeAdditional","useDefaults","coerceTypes"],TL=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),EL={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},RL={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},k0=200;function PL(e){var t,r,n,o,i,s,a,c,u,l,p,m,d,h,x,v,g,y,w,P,I,H,me,K,dt;let rt=e.strict,He=(t=e.code)===null||t===void 0?void 0:t.optimize,Ke=He===!0||He===void 0?1:He||0,tr=(n=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:E0,mt=(o=e.uriResolver)!==null&&o!==void 0?o:SL.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:rt)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:rt)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:rt)!==null&&l!==void 0?l:"log",strictTuples:(m=(p=e.strictTuples)!==null&&p!==void 0?p:rt)!==null&&m!==void 0?m:"log",strictRequired:(h=(d=e.strictRequired)!==null&&d!==void 0?d:rt)!==null&&h!==void 0?h:!1,code:e.code?{...e.code,optimize:Ke,regExp:tr}:{optimize:Ke,regExp:tr},loopRequired:(x=e.loopRequired)!==null&&x!==void 0?x:k0,loopEnum:(v=e.loopEnum)!==null&&v!==void 0?v:k0,meta:(g=e.meta)!==null&&g!==void 0?g:!0,messages:(y=e.messages)!==null&&y!==void 0?y:!0,inlineRefs:(w=e.inlineRefs)!==null&&w!==void 0?w:!0,schemaId:(P=e.schemaId)!==null&&P!==void 0?P:"$id",addUsedSchema:(I=e.addUsedSchema)!==null&&I!==void 0?I:!0,validateSchema:(H=e.validateSchema)!==null&&H!==void 0?H:!0,validateFormats:(me=e.validateFormats)!==null&&me!==void 0?me:!0,unicodeRegExp:(K=e.unicodeRegExp)!==null&&K!==void 0?K:!0,int32range:(dt=e.int32range)!==null&&dt!==void 0?dt:!0,uriResolver:mt}}class pc{constructor(e={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...PL(e)};let{es5:t,lines:r}=this.opts.code;this.scope=new kL.ValueScope({scope:{},prefixes:TL,es5:t,lines:r}),this.logger=jL(e.logger);let n=e.validateFormats;if(e.validateFormats=!1,this.RULES=wL.getRules(),S0.call(this,EL,e,"NOT SUPPORTED"),S0.call(this,RL,e,"DEPRECATED","warn"),this._metaOpts=CL.call(this),e.formats)OL.call(this);if(this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords)AL.call(this,e.keywords);if(typeof e.meta=="object")this.addMetaSchema(e.meta);zL.call(this),e.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:e,meta:t,schemaId:r}=this.opts,n=w0;if(r==="id")n={...w0},n.id=n.$id,delete n.$id;if(t&&e)this.addMetaSchema(n,n[r],!1)}defaultMeta(){let{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta=typeof e=="object"?e[t]||e:void 0}validate(e,t){let r;if(typeof e=="string"){if(r=this.getSchema(e),!r)throw Error(`no schema with key or ref "${e}"`)}else r=this.compile(e);let n=r(t);if(!("$async"in r))this.errors=r.errors;return n}compile(e,t){let r=this._addSchema(e,t);return r.validate||this._compileSchemaEnv(r)}compileAsync(e,t){if(typeof this.opts.loadSchema!="function")throw Error("options.loadSchema should be a function");let{loadSchema:r}=this.opts;return n.call(this,e,t);async function n(u,l){await o.call(this,u.$schema);let p=this._addSchema(u,l);return p.validate||i.call(this,p)}async function o(u){if(u&&!this.getSchema(u))await n.call(this,{$ref:u},!0)}async function i(u){try{return this._compileSchemaEnv(u)}catch(l){if(!(l instanceof T0.default))throw l;return s.call(this,l),await a.call(this,l.missingSchema),i.call(this,u)}}function s({missingSchema:u,missingRef:l}){if(this.refs[u])throw Error(`AnySchema ${u} is loaded but ${l} cannot be resolved`)}async function a(u){let l=await c.call(this,u);if(!this.refs[u])await o.call(this,l.$schema);if(!this.refs[u])this.addSchema(l,u,t)}async function c(u){let l=this._loading[u];if(l)return l;try{return await(this._loading[u]=r(u))}finally{delete this._loading[u]}}}addSchema(e,t,r,n=this.opts.validateSchema){if(Array.isArray(e)){for(let i of e)this.addSchema(i,void 0,r,n);return this}let o;if(typeof e==="object"){let{schemaId:i}=this.opts;if(o=e[i],o!==void 0&&typeof o!="string")throw Error(`schema ${i} must be string`)}return t=Vi.normalizeId(t||o),this._checkUnique(t),this.schemas[t]=this._addSchema(e,r,t,n,!0),this}addMetaSchema(e,t,r=this.opts.validateSchema){return this.addSchema(e,t,!0,r),this}validateSchema(e,t){if(typeof e=="boolean")return!0;let r;if(r=e.$schema,r!==void 0&&typeof r!="string")throw Error("$schema must be a string");if(r=r||this.opts.defaultMeta||this.defaultMeta(),!r)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(r,e);if(!n&&t){let o="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(o);else throw Error(o)}return n}getSchema(e){let t;while(typeof(t=$0.call(this,e))=="string")e=t;if(t===void 0){let{schemaId:r}=this.opts,n=new Gi.SchemaEnv({schema:{},schemaId:r});if(t=Gi.resolveSchema.call(this,n,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let t=$0.call(this,e);if(typeof t=="object")this._cache.delete(t.schema);return delete this.schemas[e],delete this.refs[e],this}case"object":{let t=e;this._cache.delete(t);let r=e[this.opts.schemaId];if(r)r=Vi.normalizeId(r),delete this.schemas[r],delete this.refs[r];return this}default:throw Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(let t of e)this.addKeyword(t);return this}addKeyword(e,t){let r;if(typeof e=="string"){if(r=e,typeof t=="object")this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=r}else if(typeof e=="object"&&t===void 0){if(t=e,r=t.keyword,Array.isArray(r)&&!r.length)throw Error("addKeywords: keyword must be string or non-empty array")}else throw Error("invalid addKeywords parameters");if(DL.call(this,r,t),!t)return _m.eachItem(r,(o)=>bm.call(this,o)),this;LL.call(this,t);let n={...t,type:lc.getJSONTypes(t.type),schemaType:lc.getJSONTypes(t.schemaType)};return _m.eachItem(r,n.type.length===0?(o)=>bm.call(this,o,n):(o)=>n.type.forEach((i)=>bm.call(this,o,n,i))),this}getKeyword(e){let t=this.RULES.all[e];return typeof t=="object"?t.definition:!!t}removeKeyword(e){let{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(let r of t.rules){let n=r.rules.findIndex((o)=>o.keyword===e);if(n>=0)r.rules.splice(n,1)}return this}addFormat(e,t){if(typeof t=="string")t=new RegExp(t);return this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:r="data"}={}){if(!e||e.length===0)return"No errors";return e.map((n)=>`${r}${n.instancePath} ${n.message}`).reduce((n,o)=>n+t+o)}$dataMetaSchema(e,t){let r=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(let n of t){let o=n.split("/").slice(1),i=e;for(let s of o)i=i[s];for(let s in r){let a=r[s];if(typeof a!="object")continue;let{$data:c}=a.definition,u=i[s];if(c&&u)i[s]=R0(u)}}return e}_removeAllSchemas(e,t){for(let r in e){let n=e[r];if(!t||t.test(r)){if(typeof n=="string")delete e[r];else if(n&&!n.meta)this._cache.delete(n.schema),delete e[r]}}}_addSchema(e,t,r,n=this.opts.validateSchema,o=this.opts.addUsedSchema){let i,{schemaId:s}=this.opts;if(typeof e=="object")i=e[s];else if(this.opts.jtd)throw Error("schema must be object");else if(typeof e!="boolean")throw Error("schema must be object or boolean");let a=this._cache.get(e);if(a!==void 0)return a;r=Vi.normalizeId(i||r);let c=Vi.getSchemaRefs.call(this,e,r);if(a=new Gi.SchemaEnv({schema:e,schemaId:s,meta:t,baseId:r,localRefs:c}),this._cache.set(a.schema,a),o&&!r.startsWith("#")){if(r)this._checkUnique(r);this.refs[r]=a}if(n)this.validateSchema(e,!0);return a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta)this._compileMetaSchema(e);else Gi.compileSchema.call(this,e);if(!e.validate)throw Error("ajv implementation error");return e.validate}_compileMetaSchema(e){let t=this.opts;this.opts=this._metaOpts;try{Gi.compileSchema.call(this,e)}finally{this.opts=t}}}pc.ValidationError=_L.default;pc.MissingRefError=T0.default;_r.default=pc;function S0(e,t,r,n="error"){for(let o in e){let i=o;if(i in t)this.logger[n](`${r}: option ${o}. ${e[i]}`)}}function $0(e){return e=Vi.normalizeId(e),this.schemas[e]||this.refs[e]}function zL(){let e=this.opts.schemas;if(!e)return;if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function OL(){for(let e in this.opts.formats){let t=this.opts.formats[e];if(t)this.addFormat(e,t)}}function AL(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(let t in e){let r=e[t];if(!r.keyword)r.keyword=t;this.addKeyword(r)}}function CL(){let e={...this.opts};for(let t of $L)delete e[t];return e}var IL={log(){},warn(){},error(){}};function jL(e){if(e===!1)return IL;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw Error("logger must implement log, warn and error methods")}var NL=/^[a-z_$][a-z0-9_$:-]*$/i;function DL(e,t){let{RULES:r}=this;if(_m.eachItem(e,(n)=>{if(r.keywords[n])throw Error(`Keyword ${n} is already defined`);if(!NL.test(n))throw Error(`Keyword ${n} has invalid name`)}),!t)return;if(t.$data&&!(("code"in t)||("validate"in t)))throw Error('$data keyword must have "code" or "validate" function')}function bm(e,t,r){var n;let o=t===null||t===void 0?void 0:t.post;if(r&&o)throw Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=o?i.post:i.rules.find(({type:c})=>c===r);if(!s)s={type:r,rules:[]},i.rules.push(s);if(i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:lc.getJSONTypes(t.type),schemaType:lc.getJSONTypes(t.schemaType)}};if(t.before)ML.call(this,s,a,t.before);else s.rules.push(a);i.all[e]=a,(n=t.implements)===null||n===void 0||n.forEach((c)=>this.addKeyword(c))}function ML(e,t,r){let n=e.rules.findIndex((o)=>o.keyword===r);if(n>=0)e.rules.splice(n,0,t);else e.rules.push(t),this.logger.warn(`rule ${r} is not defined`)}function LL(e){let{metaSchema:t}=e;if(t===void 0)return;if(e.$data&&this.opts.$data)t=R0(t);e.validateSchema=this.compile(t,!0)}var qL={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function R0(e){return{anyOf:[e,qL]}}});var O0=b(function(z0){Object.defineProperty(z0,"__esModule",{value:!0});var ZL={keyword:"id",code(){throw Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};z0.default=ZL});var D0=b(function(j0){Object.defineProperty(j0,"__esModule",{value:!0});j0.callRef=j0.getValidate=void 0;var HL=Zi(),A0=Lt(),yt=W(),fo=yr(),C0=sc(),dc=se(),VL={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:n}=e,{baseId:o,schemaEnv:i,validateName:s,opts:a,self:c}=n,{root:u}=i;if((r==="#"||r==="#/")&&o===u.baseId)return p();let l=C0.resolveRef.call(c,u,o,r);if(l===void 0)throw new HL.default(n.opts.uriResolver,o,r);if(l instanceof C0.SchemaEnv)return m(l);return d(l);function p(){if(i===u)return mc(e,s,i,i.$async);let h=t.scopeValue("root",{ref:u});return mc(e,yt._`${h}.validate`,u,u.$async)}function m(h){let x=I0(e,h);mc(e,x,h,h.$async)}function d(h){let x=t.scopeValue("schema",a.code.source===!0?{ref:h,code:yt.stringify(h)}:{ref:h}),v=t.name("valid"),g=e.subschema({schema:h,dataTypes:[],schemaPath:yt.nil,topSchemaRef:x,errSchemaPath:r},v);e.mergeEvaluated(g),e.ok(v)}}};function I0(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):yt._`${r.scopeValue("wrapper",{ref:t})}.validate`}j0.getValidate=I0;function mc(e,t,r,n){let{gen:o,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?fo.default.this:yt.nil;if(n)l();else p();function l(){if(!a.$async)throw Error("async schema referenced by sync schema");let h=o.let("valid");o.try(()=>{if(o.code(yt._`await ${A0.callValidateCode(e,t,u)}`),d(t),!s)o.assign(h,!0)},(x)=>{if(o.if(yt._`!(${x} instanceof ${i.ValidationError})`,()=>o.throw(x)),m(x),!s)o.assign(h,!1)}),e.ok(h)}function p(){e.result(A0.callValidateCode(e,t,u),()=>d(t),()=>m(t))}function m(h){let x=yt._`${h}.errors`;o.assign(fo.default.vErrors,yt._`${fo.default.vErrors} === null ? ${x} : ${fo.default.vErrors}.concat(${x})`),o.assign(fo.default.errors,yt._`${fo.default.vErrors}.length`)}function d(h){var x;if(!i.opts.unevaluated)return;let v=(x=r===null||r===void 0?void 0:r.validate)===null||x===void 0?void 0:x.evaluated;if(i.props!==!0)if(v&&!v.dynamicProps){if(v.props!==void 0)i.props=dc.mergeEvaluated.props(o,v.props,i.props)}else{let g=o.var("props",yt._`${h}.evaluated.props`);i.props=dc.mergeEvaluated.props(o,g,i.props,yt.Name)}if(i.items!==!0)if(v&&!v.dynamicItems){if(v.items!==void 0)i.items=dc.mergeEvaluated.items(o,v.items,i.items)}else{let g=o.var("items",yt._`${h}.evaluated.items`);i.items=dc.mergeEvaluated.items(o,g,i.items,yt.Name)}}}j0.callRef=mc;j0.default=VL});var L0=b(function(M0){Object.defineProperty(M0,"__esModule",{value:!0});var WL=O0(),KL=D0(),YL=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",WL.default,KL.default];M0.default=YL});var U0=b(function(q0){Object.defineProperty(q0,"__esModule",{value:!0});var hc=W(),Fr=hc.operators,fc={maximum:{okStr:"<=",ok:Fr.LTE,fail:Fr.GT},minimum:{okStr:">=",ok:Fr.GTE,fail:Fr.LT},exclusiveMaximum:{okStr:"<",ok:Fr.LT,fail:Fr.GTE},exclusiveMinimum:{okStr:">",ok:Fr.GT,fail:Fr.LTE}},QL={message:({keyword:e,schemaCode:t})=>hc.str`must be ${fc[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>hc._`{comparison: ${fc[e].okStr}, limit: ${t}}`},eq={keyword:Object.keys(fc),type:"number",schemaType:"number",$data:!0,error:QL,code(e){let{keyword:t,data:r,schemaCode:n}=e;e.fail$data(hc._`${r} ${fc[t].fail} ${n} || isNaN(${r})`)}};q0.default=eq});var Z0=b(function(F0){Object.defineProperty(F0,"__esModule",{value:!0});var Ji=W(),rq={message:({schemaCode:e})=>Ji.str`must be multiple of ${e}`,params:({schemaCode:e})=>Ji._`{multipleOf: ${e}}`},nq={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:rq,code(e){let{gen:t,data:r,schemaCode:n,it:o}=e,i=o.opts.multipleOfPrecision,s=t.let("res"),a=i?Ji._`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:Ji._`${s} !== parseInt(${s})`;e.fail$data(Ji._`(${n} === 0 || (${s} = ${r}/${n}, ${a}))`)}};F0.default=nq});var V0=b(function(H0){Object.defineProperty(H0,"__esModule",{value:!0});function B0(e){let t=e.length,r=0,n=0,o;while(n<t)if(r++,o=e.charCodeAt(n++),o>=55296&&o<=56319&&n<t){if(o=e.charCodeAt(n),(o&64512)===56320)n++}return r}H0.default=B0;B0.code='require("ajv/dist/runtime/ucs2length").default'});var J0=b(function(G0){Object.defineProperty(G0,"__esModule",{value:!0});var wn=W(),sq=se(),aq=V0(),cq={message({keyword:e,schemaCode:t}){return wn.str`must NOT have ${e==="maxLength"?"more":"fewer"} than ${t} characters`},params:({schemaCode:e})=>wn._`{limit: ${e}}`},uq={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:cq,code(e){let{keyword:t,data:r,schemaCode:n,it:o}=e,i=t==="maxLength"?wn.operators.GT:wn.operators.LT,s=o.opts.unicode===!1?wn._`${r}.length`:wn._`${sq.useFunc(e.gen,aq.default)}(${r})`;e.fail$data(wn._`${s} ${i} ${n}`)}};G0.default=uq});var K0=b(function(W0){Object.defineProperty(W0,"__esModule",{value:!0});var pq=Lt(),dq=se(),ho=W(),mq={message:({schemaCode:e})=>ho.str`must match pattern "${e}"`,params:({schemaCode:e})=>ho._`{pattern: ${e}}`},fq={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:mq,code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:i,it:s}=e,a=s.opts.unicodeRegExp?"u":"";if(n){let{regExp:c}=s.opts.code,u=c.code==="new RegExp"?ho._`new RegExp`:dq.useFunc(t,c),l=t.let("valid");t.try(()=>t.assign(l,ho._`${u}(${i}, ${a}).test(${r})`),()=>t.assign(l,!1)),e.fail$data(ho._`!${l}`)}else{let c=pq.usePattern(e,o);e.fail$data(ho._`!${c}.test(${r})`)}}};W0.default=fq});var X0=b(function(Y0){Object.defineProperty(Y0,"__esModule",{value:!0});var Wi=W(),gq={message({keyword:e,schemaCode:t}){return Wi.str`must NOT have ${e==="maxProperties"?"more":"fewer"} than ${t} properties`},params:({schemaCode:e})=>Wi._`{limit: ${e}}`},xq={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:gq,code(e){let{keyword:t,data:r,schemaCode:n}=e,o=t==="maxProperties"?Wi.operators.GT:Wi.operators.LT;e.fail$data(Wi._`Object.keys(${r}).length ${o} ${n}`)}};Y0.default=xq});var ek=b(function(Q0){Object.defineProperty(Q0,"__esModule",{value:!0});var Yi=Lt(),Ki=W(),yq=se(),bq={message:({params:{missingProperty:e}})=>Ki.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>Ki._`{missingProperty: ${e}}`},_q={keyword:"required",type:"object",schemaType:"array",$data:!0,error:bq,code(e){let{gen:t,schema:r,schemaCode:n,data:o,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors)u();else l();if(a.strictRequired){let d=e.parentSchema.properties,{definedProperties:h}=e.it;for(let x of r)if((d===null||d===void 0?void 0:d[x])===void 0&&!h.has(x)){let v=s.schemaEnv.baseId+s.errSchemaPath,g=`required property "${x}" is not defined at "${v}" (strictRequired)`;yq.checkStrictMode(s,g,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(Ki.nil,p);else for(let d of r)Yi.checkReportMissingProp(e,d)}function l(){let d=t.let("missing");if(c||i){let h=t.let("valid",!0);e.block$data(h,()=>m(d,h)),e.ok(h)}else t.if(Yi.checkMissingProp(e,r,d)),Yi.reportMissingProp(e,d),t.else()}function p(){t.forOf("prop",n,(d)=>{e.setParams({missingProperty:d}),t.if(Yi.noPropertyInData(t,o,d,a.ownProperties),()=>e.error())})}function m(d,h){e.setParams({missingProperty:d}),t.forOf(d,n,()=>{t.assign(h,Yi.propertyInData(t,o,d,a.ownProperties)),t.if(Ki.not(h),()=>{e.error(),t.break()})},Ki.nil)}}};Q0.default=_q});var rk=b(function(tk){Object.defineProperty(tk,"__esModule",{value:!0});var Xi=W(),kq={message({keyword:e,schemaCode:t}){return Xi.str`must NOT have ${e==="maxItems"?"more":"fewer"} than ${t} items`},params:({schemaCode:e})=>Xi._`{limit: ${e}}`},Sq={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:kq,code(e){let{keyword:t,data:r,schemaCode:n}=e,o=t==="maxItems"?Xi.operators.GT:Xi.operators.LT;e.fail$data(Xi._`${r}.length ${o} ${n}`)}};tk.default=Sq});var gc=b(function(ok){Object.defineProperty(ok,"__esModule",{value:!0});var nk=im();nk.code='require("ajv/dist/runtime/equal").default';ok.default=nk});var sk=b(function(ik){Object.defineProperty(ik,"__esModule",{value:!0});var wm=Mi(),tt=W(),Eq=se(),Rq=gc(),Pq={message:({params:{i:e,j:t}})=>tt.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>tt._`{i: ${e}, j: ${t}}`},zq={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Pq,code(e){let{gen:t,data:r,$data:n,schema:o,parentSchema:i,schemaCode:s,it:a}=e;if(!n&&!o)return;let c=t.let("valid"),u=i.items?wm.getSchemaTypes(i.items):[];e.block$data(c,l,tt._`${s} === false`),e.ok(c);function l(){let h=t.let("i",tt._`${r}.length`),x=t.let("j");e.setParams({i:h,j:x}),t.assign(c,!0),t.if(tt._`${h} > 1`,()=>(p()?m:d)(h,x))}function p(){return u.length>0&&!u.some((h)=>h==="object"||h==="array")}function m(h,x){let v=t.name("item"),g=wm.checkDataTypes(u,v,a.opts.strictNumbers,wm.DataType.Wrong),y=t.const("indices",tt._`{}`);t.for(tt._`;${h}--;`,()=>{if(t.let(v,tt._`${r}[${h}]`),t.if(g,tt._`continue`),u.length>1)t.if(tt._`typeof ${v} == "string"`,tt._`${v} += "_"`);t.if(tt._`typeof ${y}[${v}] == "number"`,()=>{t.assign(x,tt._`${y}[${v}]`),e.error(),t.assign(c,!1).break()}).code(tt._`${y}[${v}] = ${h}`)})}function d(h,x){let v=Eq.useFunc(t,Rq.default),g=t.name("outer");t.label(g).for(tt._`;${h}--;`,()=>t.for(tt._`${x} = ${h}; ${x}--;`,()=>t.if(tt._`${v}(${r}[${h}], ${r}[${x}])`,()=>{e.error(),t.assign(c,!1).break(g)})))}}};ik.default=zq});var ck=b(function(ak){Object.defineProperty(ak,"__esModule",{value:!0});var km=W(),Aq=se(),Cq=gc(),Iq={message:"must be equal to constant",params:({schemaCode:e})=>km._`{allowedValue: ${e}}`},jq={keyword:"const",$data:!0,error:Iq,code(e){let{gen:t,data:r,$data:n,schemaCode:o,schema:i}=e;if(n||i&&typeof i=="object")e.fail$data(km._`!${Aq.useFunc(t,Cq.default)}(${r}, ${o})`);else e.fail(km._`${i} !== ${r}`)}};ak.default=jq});var lk=b(function(uk){Object.defineProperty(uk,"__esModule",{value:!0});var Qi=W(),Dq=se(),Mq=gc(),Lq={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>Qi._`{allowedValues: ${e}}`},qq={keyword:"enum",schemaType:"array",$data:!0,error:Lq,code(e){let{gen:t,data:r,$data:n,schema:o,schemaCode:i,it:s}=e;if(!n&&o.length===0)throw Error("enum must have non-empty array");let a=o.length>=s.opts.loopEnum,c,u=()=>c!==null&&c!==void 0?c:c=Dq.useFunc(t,Mq.default),l;if(a||n)l=t.let("valid"),e.block$data(l,p);else{if(!Array.isArray(o))throw Error("ajv implementation error");let d=t.const("vSchema",i);l=Qi.or(...o.map((h,x)=>m(d,x)))}e.pass(l);function p(){t.assign(l,!1),t.forOf("v",i,(d)=>t.if(Qi._`${u()}(${r}, ${d})`,()=>t.assign(l,!0).break()))}function m(d,h){let x=o[h];return typeof x==="object"&&x!==null?Qi._`${u()}(${r}, ${d}[${h}])`:Qi._`${r} === ${x}`}}};uk.default=qq});var dk=b(function(pk){Object.defineProperty(pk,"__esModule",{value:!0});var Fq=U0(),Zq=Z0(),Bq=J0(),Hq=K0(),Vq=X0(),Gq=ek(),Jq=rk(),Wq=sk(),Kq=ck(),Yq=lk(),Xq=[Fq.default,Zq.default,Bq.default,Hq.default,Vq.default,Gq.default,Jq.default,Wq.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},Kq.default,Yq.default];pk.default=Xq});var $m=b(function(fk){Object.defineProperty(fk,"__esModule",{value:!0});fk.validateAdditionalItems=void 0;var kn=W(),Sm=se(),e2={message:({params:{len:e}})=>kn.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>kn._`{limit: ${e}}`},t2={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:e2,code(e){let{parentSchema:t,it:r}=e,{items:n}=t;if(!Array.isArray(n)){Sm.checkStrictMode(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}mk(e,n)}};function mk(e,t){let{gen:r,schema:n,data:o,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",kn._`${o}.length`);if(n===!1)e.setParams({len:t.length}),e.pass(kn._`${a} <= ${t.length}`);else if(typeof n=="object"&&!Sm.alwaysValidSchema(s,n)){let u=r.var("valid",kn._`${a} <= ${t.length}`);r.if(kn.not(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,(l)=>{if(e.subschema({keyword:i,dataProp:l,dataPropType:Sm.Type.Num},u),!s.allErrors)r.if(kn.not(u),()=>r.break())})}}fk.validateAdditionalItems=mk;fk.default=t2});var Tm=b(function(vk){Object.defineProperty(vk,"__esModule",{value:!0});vk.validateTuple=void 0;var gk=W(),xc=se(),n2=Lt(),o2={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return xk(e,"additionalItems",t);if(r.items=!0,xc.alwaysValidSchema(r,t))return;e.ok(n2.validateArray(e))}};function xk(e,t,r=e.schema){let{gen:n,parentSchema:o,data:i,keyword:s,it:a}=e;if(l(o),a.opts.unevaluated&&r.length&&a.items!==!0)a.items=xc.mergeEvaluated.items(n,r.length,a.items);let c=n.name("valid"),u=n.const("len",gk._`${i}.length`);r.forEach((p,m)=>{if(xc.alwaysValidSchema(a,p))return;n.if(gk._`${u} > ${m}`,()=>e.subschema({keyword:s,schemaProp:m,dataProp:m},c)),e.ok(c)});function l(p){let{opts:m,errSchemaPath:d}=a,h=r.length,x=h===p.minItems&&(h===p.maxItems||p[t]===!1);if(m.strictTuples&&!x){let v=`"${s}" is ${h}-tuple, but minItems or maxItems/${t} are not specified or different at path "${d}"`;xc.checkStrictMode(a,v,m.strictTuples)}}}vk.validateTuple=xk;vk.default=o2});var _k=b(function(bk){Object.defineProperty(bk,"__esModule",{value:!0});var s2=Tm(),a2={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:(e)=>s2.validateTuple(e,"items")};bk.default=a2});var Sk=b(function(kk){Object.defineProperty(kk,"__esModule",{value:!0});var wk=W(),u2=se(),l2=Lt(),p2=$m(),d2={message:({params:{len:e}})=>wk.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>wk._`{limit: ${e}}`},m2={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:d2,code(e){let{schema:t,parentSchema:r,it:n}=e,{prefixItems:o}=r;if(n.items=!0,u2.alwaysValidSchema(n,t))return;if(o)p2.validateAdditionalItems(e,o);else e.ok(l2.validateArray(e))}};kk.default=m2});var Tk=b(function($k){Object.defineProperty($k,"__esModule",{value:!0});var qt=W(),vc=se(),h2={message:({params:{min:e,max:t}})=>t===void 0?qt.str`must contain at least ${e} valid item(s)`:qt.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?qt._`{minContains: ${e}}`:qt._`{minContains: ${e}, maxContains: ${t}}`},g2={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:h2,code(e){let{gen:t,schema:r,parentSchema:n,data:o,it:i}=e,s,a,{minContains:c,maxContains:u}=n;if(i.opts.next)s=c===void 0?1:c,a=u;else s=1;let l=t.const("len",qt._`${o}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){vc.checkStrictMode(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){vc.checkStrictMode(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if(vc.alwaysValidSchema(i,r)){let x=qt._`${l} >= ${s}`;if(a!==void 0)x=qt._`${x} && ${l} <= ${a}`;e.pass(x);return}i.items=!0;let p=t.name("valid");if(a===void 0&&s===1)d(p,()=>t.if(p,()=>t.break()));else if(s===0){if(t.let(p,!0),a!==void 0)t.if(qt._`${o}.length > 0`,m)}else t.let(p,!1),m();e.result(p,()=>e.reset());function m(){let x=t.name("_valid"),v=t.let("count",0);d(x,()=>t.if(x,()=>h(v)))}function d(x,v){t.forRange("i",0,l,(g)=>{e.subschema({keyword:"contains",dataProp:g,dataPropType:vc.Type.Num,compositeRule:!0},x),v()})}function h(x){if(t.code(qt._`${x}++`),a===void 0)t.if(qt._`${x} >= ${s}`,()=>t.assign(p,!0).break());else if(t.if(qt._`${x} > ${a}`,()=>t.assign(p,!1).break()),s===1)t.assign(p,!0);else t.if(qt._`${x} >= ${s}`,()=>t.assign(p,!0))}}};$k.default=g2});var Ak=b(function(Pk){Object.defineProperty(Pk,"__esModule",{value:!0});Pk.validateSchemaDeps=Pk.validatePropertyDeps=Pk.error=void 0;var Em=W(),v2=se(),es=Lt();Pk.error={message:({params:{property:e,depsCount:t,deps:r}})=>Em.str`must have ${t===1?"property":"properties"} ${r} when property ${e} is present`,params:({params:{property:e,depsCount:t,deps:r,missingProperty:n}})=>Em._`{property: ${e},
|
|
24
24
|
missingProperty: ${n},
|
|
25
25
|
depsCount: ${t},
|
|
26
|
-
deps: ${r}}`};var PU={keyword:"dependencies",type:"object",schemaType:"object",error:Vk.error,code(e){let[t,r]=zU(e);Bk(e,t),Hk(e,r)}};function zU({schema:e}){let t={},r={};for(let n in e){if(n==="__proto__")continue;let o=Array.isArray(e[n])?t:r;o[n]=e[n]}return[t,r]}function Bk(e,t=e.schema){let{gen:r,data:n,it:o}=e;if(Object.keys(t).length===0)return;let i=r.let("missing");for(let s in t){let a=t[s];if(a.length===0)continue;let c=(0,cs.propertyInData)(r,n,s,o.opts.ownProperties);if(e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),o.allErrors)r.if(c,()=>{for(let u of a)(0,cs.checkReportMissingProp)(e,u)});else r.if(jm._`${c} && (${(0,cs.checkMissingProp)(e,a,i)})`),(0,cs.reportMissingProp)(e,i),r.else()}}Vk.validatePropertyDeps=Bk;function Hk(e,t=e.schema){let{gen:r,data:n,keyword:o,it:i}=e,s=r.name("valid");for(let a in t){if((0,RU.alwaysValidSchema)(i,t[a]))continue;r.if((0,cs.propertyInData)(r,n,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:o,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s)}}Vk.validateSchemaDeps=Hk;Vk.default=PU});var Xk=_(function(Yk){Object.defineProperty(Yk,"__esModule",{value:!0});var Kk=W(),CU=ae(),IU={message:"property name must be valid",params:({params:e})=>Kk._`{propertyName: ${e.propertyName}}`},jU={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:IU,code(e){let{gen:t,schema:r,data:n,it:o}=e;if((0,CU.alwaysValidSchema)(o,r))return;let i=t.name("valid");t.forIn("key",n,(s)=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if((0,Kk.not)(i),()=>{if(e.error(!0),!o.allErrors)t.break()})}),e.ok(i)}};Yk.default=jU});var Nm=_(function(Qk){Object.defineProperty(Qk,"__esModule",{value:!0});var kc=jt(),Qt=W(),DU=gr(),Sc=ae(),LU={message:"must NOT have additional properties",params:({params:e})=>Qt._`{additionalProperty: ${e.additionalProperty}}`},MU={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:LU,code(e){let{gen:t,schema:r,parentSchema:n,data:o,errsCount:i,it:s}=e;if(!i)throw Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&(0,Sc.alwaysValidSchema)(s,r))return;let u=(0,kc.allSchemaProperties)(n.properties),l=(0,kc.allSchemaProperties)(n.patternProperties);p(),e.ok(Qt._`${i} === ${DU.default.errors}`);function p(){t.forIn("key",o,(y)=>{if(!u.length&&!l.length)h(y);else t.if(m(y),()=>h(y))})}function m(y){let g;if(u.length>8){let b=(0,Sc.schemaRefOrVal)(s,n.properties,"properties");g=(0,kc.isOwnProperty)(t,b,y)}else if(u.length)g=(0,Qt.or)(...u.map((b)=>Qt._`${y} === ${b}`));else g=Qt.nil;if(l.length)g=(0,Qt.or)(g,...l.map((b)=>Qt._`${(0,kc.usePattern)(e,b)}.test(${y})`));return(0,Qt.not)(g)}function d(y){t.code(Qt._`delete ${o}[${y}]`)}function h(y){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){d(y);return}if(r===!1){if(e.setParams({additionalProperty:y}),e.error(),!a)t.break();return}if(typeof r=="object"&&!(0,Sc.alwaysValidSchema)(s,r)){let g=t.name("valid");if(c.removeAdditional==="failing")x(y,g,!1),t.if((0,Qt.not)(g),()=>{e.reset(),d(y)});else if(x(y,g),!a)t.if((0,Qt.not)(g),()=>t.break())}}function x(y,g,b){let k={keyword:"additionalProperties",dataProp:y,dataPropType:Sc.Type.Str};if(b===!1)Object.assign(k,{compositeRule:!0,createErrors:!1,allErrors:!1});e.subschema(k,g)}}};Qk.default=MU});var nS=_(function(rS){Object.defineProperty(rS,"__esModule",{value:!0});var UU=Ki(),eS=jt(),Dm=ae(),tS=Nm(),FU={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:n,data:o,it:i}=e;if(i.opts.removeAdditional==="all"&&n.additionalProperties===void 0)tS.default.code(new UU.KeywordCxt(i,tS.default,"additionalProperties"));let s=(0,eS.allSchemaProperties)(r);for(let p of s)i.definedProperties.add(p);if(i.opts.unevaluated&&s.length&&i.props!==!0)i.props=Dm.mergeEvaluated.props(t,(0,Dm.toHash)(s),i.props);let a=s.filter((p)=>!(0,Dm.alwaysValidSchema)(i,r[p]));if(a.length===0)return;let c=t.name("valid");for(let p of a){if(u(p))l(p);else{if(t.if((0,eS.propertyInData)(t,o,p,i.opts.ownProperties)),l(p),!i.allErrors)t.else().var(c,!0);t.endIf()}e.it.definedProperties.add(p),e.ok(c)}function u(p){return i.opts.useDefaults&&!i.compositeRule&&r[p].default!==void 0}function l(p){e.subschema({keyword:"properties",schemaProp:p,dataProp:p},c)}}};rS.default=FU});var cS=_(function(aS){Object.defineProperty(aS,"__esModule",{value:!0});var oS=jt(),$c=W(),iS=ae(),sS=ae(),BU={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:n,parentSchema:o,it:i}=e,{opts:s}=i,a=(0,oS.allSchemaProperties)(r),c=a.filter((x)=>(0,iS.alwaysValidSchema)(i,r[x]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&o.properties,l=t.name("valid");if(i.props!==!0&&!(i.props instanceof $c.Name))i.props=(0,sS.evaluatedPropsToName)(t,i.props);let{props:p}=i;m();function m(){for(let x of a){if(u)d(x);if(i.allErrors)h(x);else t.var(l,!0),h(x),t.if(l)}}function d(x){for(let y in u)if(new RegExp(x).test(y))(0,iS.checkStrictMode)(i,`property ${y} matches pattern ${x} (use allowMatchingProperties)`)}function h(x){t.forIn("key",n,(y)=>{t.if($c._`${(0,oS.usePattern)(e,x)}.test(${y})`,()=>{let g=c.includes(x);if(!g)e.subschema({keyword:"patternProperties",schemaProp:x,dataProp:y,dataPropType:sS.Type.Str},l);if(i.opts.unevaluated&&p!==!0)t.assign($c._`${p}[${y}]`,!0);else if(!g&&!i.allErrors)t.if((0,$c.not)(l),()=>t.break())})})}}};aS.default=BU});var lS=_(function(uS){Object.defineProperty(uS,"__esModule",{value:!0});var VU=ae(),GU={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:n}=e;if((0,VU.alwaysValidSchema)(n,r)){e.fail();return}let o=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},o),e.failResult(o,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};uS.default=GU});var dS=_(function(pS){Object.defineProperty(pS,"__esModule",{value:!0});var WU=jt(),KU={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:WU.validateUnion,error:{message:"must match a schema in anyOf"}};pS.default=KU});var fS=_(function(mS){Object.defineProperty(mS,"__esModule",{value:!0});var Tc=W(),XU=ae(),QU={message:"must match exactly one schema in oneOf",params:({params:e})=>Tc._`{passingSchemas: ${e.passing}}`},eF={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:QU,code(e){let{gen:t,schema:r,parentSchema:n,it:o}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(o.opts.discriminator&&n.discriminator)return;let i=r,s=t.let("valid",!1),a=t.let("passing",null),c=t.name("_valid");e.setParams({passing:a}),t.block(u),e.result(s,()=>e.reset(),()=>e.error(!0));function u(){i.forEach((l,p)=>{let m;if((0,XU.alwaysValidSchema)(o,l))t.var(c,!0);else m=e.subschema({keyword:"oneOf",schemaProp:p,compositeRule:!0},c);if(p>0)t.if(Tc._`${c} && ${s}`).assign(s,!1).assign(a,Tc._`[${a}, ${p}]`).else();t.if(c,()=>{if(t.assign(s,!0),t.assign(a,p),m)e.mergeEvaluated(m,Tc.Name)})})}}};mS.default=eF});var gS=_(function(hS){Object.defineProperty(hS,"__esModule",{value:!0});var rF=ae(),nF={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");let o=t.name("valid");r.forEach((i,s)=>{if((0,rF.alwaysValidSchema)(n,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},o);e.ok(o),e.mergeEvaluated(a)})}};hS.default=nF});var bS=_(function(yS){Object.defineProperty(yS,"__esModule",{value:!0});var Ec=W(),vS=ae(),iF={message:({params:e})=>Ec.str`must match "${e.ifClause}" schema`,params:({params:e})=>Ec._`{failingKeyword: ${e.ifClause}}`},sF={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:iF,code(e){let{gen:t,parentSchema:r,it:n}=e;if(r.then===void 0&&r.else===void 0)(0,vS.checkStrictMode)(n,'"if" without "then" and "else" is ignored');let o=xS(n,"then"),i=xS(n,"else");if(!o&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),o&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else if(o)t.if(a,u("then"));else t.if((0,Ec.not)(a),u("else"));e.pass(s,()=>e.error(!0));function c(){let l=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(l)}function u(l,p){return()=>{let m=e.subschema({keyword:l},a);if(t.assign(s,a),e.mergeValidEvaluated(m,s),p)t.assign(p,Ec._`${l}`);else e.setParams({ifClause:l})}}}};function xS(e,t){let r=e.schema[t];return r!==void 0&&!(0,vS.alwaysValidSchema)(e,r)}yS.default=sF});var wS=_(function(_S){Object.defineProperty(_S,"__esModule",{value:!0});var cF=ae(),uF={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){if(t.if===void 0)(0,cF.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};_S.default=uF});var SS=_(function(kS){Object.defineProperty(kS,"__esModule",{value:!0});var pF=Cm(),dF=Lk(),mF=Im(),fF=Uk(),hF=Zk(),gF=Wk(),xF=Xk(),vF=Nm(),yF=nS(),bF=cS(),_F=lS(),wF=dS(),kF=fS(),SF=gS(),$F=bS(),TF=wS();function EF(e=!1){let t=[_F.default,wF.default,kF.default,SF.default,$F.default,TF.default,xF.default,vF.default,gF.default,yF.default,bF.default];if(e)t.push(dF.default,fF.default);else t.push(pF.default,mF.default);return t.push(hF.default),t}kS.default=EF});var TS=_(function($S){Object.defineProperty($S,"__esModule",{value:!0});var De=W(),PF={message:({schemaCode:e})=>De.str`must match format "${e}"`,params:({schemaCode:e})=>De._`{format: ${e}}`},zF={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:PF,code(e,t){let{gen:r,data:n,$data:o,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:p}=a;if(!c.validateFormats)return;if(o)m();else d();function m(){let h=r.scopeValue("formats",{ref:p.formats,code:c.code.formats}),x=r.const("fDef",De._`${h}[${s}]`),y=r.let("fType"),g=r.let("format");r.if(De._`typeof ${x} == "object" && !(${x} instanceof RegExp)`,()=>r.assign(y,De._`${x}.type || "string"`).assign(g,De._`${x}.validate`),()=>r.assign(y,De._`"string"`).assign(g,x)),e.fail$data((0,De.or)(b(),k()));function b(){if(c.strictSchema===!1)return De.nil;return De._`${s} && !${g}`}function k(){let z=l.$async?De._`(${x}.async ? await ${g}(${n}) : ${g}(${n}))`:De._`${g}(${n})`,I=De._`(typeof ${g} == "function" ? ${z} : ${g}.test(${n}))`;return De._`${g} && ${g} !== true && ${y} === ${t} && !${I}`}}function d(){let h=p.formats[i];if(!h){b();return}if(h===!0)return;let[x,y,g]=k(h);if(x===t)e.pass(z());function b(){if(c.strictSchema===!1){p.logger.warn(I());return}throw Error(I());function I(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function k(I){let H=I instanceof RegExp?(0,De.regexpCode)(I):c.code.formats?De._`${c.code.formats}${(0,De.getProperty)(i)}`:void 0,me=r.scopeValue("formats",{key:i,ref:I,code:H});if(typeof I=="object"&&!(I instanceof RegExp))return[I.type||"string",I.validate,De._`${me}.validate`];return["string",I,me]}function z(){if(typeof h=="object"&&!(h instanceof RegExp)&&h.async){if(!l.$async)throw Error("async format in sync schema");return De._`await ${g}(${n})`}return typeof y=="function"?De._`${g}(${n})`:De._`${g}.test(${n})`}}}};$S.default=zF});var RS=_(function(ES){Object.defineProperty(ES,"__esModule",{value:!0});var AF=TS(),CF=[AF.default];ES.default=CF});var OS=_(function(PS){Object.defineProperty(PS,"__esModule",{value:!0});PS.contentVocabulary=PS.metadataVocabulary=void 0;PS.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];PS.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var IS=_(function(CS){Object.defineProperty(CS,"__esModule",{value:!0});var NF=rk(),DF=Pk(),LF=SS(),MF=RS(),AS=OS(),qF=[NF.default,DF.default,(0,LF.default)(),MF.default,AS.metadataVocabulary,AS.contentVocabulary];CS.default=qF});var LS=_(function(NS){Object.defineProperty(NS,"__esModule",{value:!0});NS.DiscrError=void 0;var jS;(function(e){e.Tag="tag",e.Mapping="mapping"})(jS||(NS.DiscrError=jS={}))});var US=_(function(qS){Object.defineProperty(qS,"__esModule",{value:!0});var Ro=W(),Lm=LS(),MS=lc(),FF=Yi(),ZF=ae(),BF={message:({params:{discrError:e,tagName:t}})=>e===Lm.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>Ro._`{error: ${e}, tag: ${r}, tagValue: ${t}}`},HF={keyword:"discriminator",type:"object",schemaType:"object",error:BF,code(e){let{gen:t,data:r,schema:n,parentSchema:o,it:i}=e,{oneOf:s}=o;if(!i.opts.discriminator)throw Error("discriminator: requires discriminator option");let a=n.propertyName;if(typeof a!="string")throw Error("discriminator: requires propertyName");if(n.mapping)throw Error("discriminator: mapping is not supported");if(!s)throw Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",Ro._`${r}${(0,Ro.getProperty)(a)}`);t.if(Ro._`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:Lm.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let d=m();t.if(!1);for(let h in d)t.elseIf(Ro._`${u} === ${h}`),t.assign(c,p(d[h]));t.else(),e.error(!1,{discrError:Lm.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function p(d){let h=t.name("valid"),x=e.subschema({keyword:"oneOf",schemaProp:d},h);return e.mergeEvaluated(x,Ro.Name),h}function m(){var d;let h={},x=g(o),y=!0;for(let z=0;z<s.length;z++){let I=s[z];if((I===null||I===void 0?void 0:I.$ref)&&!(0,ZF.schemaHasRulesButRef)(I,i.self.RULES)){let me=I.$ref;if(I=MS.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,me),I instanceof MS.SchemaEnv)I=I.schema;if(I===void 0)throw new FF.default(i.opts.uriResolver,i.baseId,me)}let H=(d=I===null||I===void 0?void 0:I.properties)===null||d===void 0?void 0:d[a];if(typeof H!="object")throw Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);y=y&&(x||g(I)),b(H,z)}if(!y)throw Error(`discriminator: "${a}" must be required`);return h;function g({required:z}){return Array.isArray(z)&&z.includes(a)}function b(z,I){if(z.const)k(z.const,I);else if(z.enum)for(let H of z.enum)k(H,I);else throw Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function k(z,I){if(typeof z!="string"||z in h)throw Error(`discriminator: "${a}" values must be unique strings`);h[z]=I}}}};qS.default=HF});var FS=_(function(j7,GF){GF.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var qm=_(function(yt,Mm){Object.defineProperty(yt,"__esModule",{value:!0});yt.MissingRefError=yt.ValidationError=yt.CodeGen=yt.Name=yt.nil=yt.stringify=yt.str=yt._=yt.KeywordCxt=yt.Ajv=void 0;var JF=V0(),WF=IS(),KF=US(),ZS=FS(),YF=["/properties"],Rc="http://json-schema.org/draft-07/schema";class us extends JF.default{_addVocabularies(){if(super._addVocabularies(),WF.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(KF.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(ZS,YF):ZS;this.addMetaSchema(e,Rc,!1),this.refs["http://json-schema.org/schema"]=Rc}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Rc)?Rc:void 0)}}yt.Ajv=us;Mm.exports=yt=us;Mm.exports.Ajv=us;Object.defineProperty(yt,"__esModule",{value:!0});yt.default=us;var XF=Ki();Object.defineProperty(yt,"KeywordCxt",{enumerable:!0,get:function(){return XF.KeywordCxt}});var Po=W();Object.defineProperty(yt,"_",{enumerable:!0,get:function(){return Po._}});Object.defineProperty(yt,"str",{enumerable:!0,get:function(){return Po.str}});Object.defineProperty(yt,"stringify",{enumerable:!0,get:function(){return Po.stringify}});Object.defineProperty(yt,"nil",{enumerable:!0,get:function(){return Po.nil}});Object.defineProperty(yt,"Name",{enumerable:!0,get:function(){return Po.Name}});Object.defineProperty(yt,"CodeGen",{enumerable:!0,get:function(){return Po.CodeGen}});var QF=cc();Object.defineProperty(yt,"ValidationError",{enumerable:!0,get:function(){return QF.default}});var e4=Yi();Object.defineProperty(yt,"MissingRefError",{enumerable:!0,get:function(){return e4.default}})});var QS=_(function(YS){Object.defineProperty(YS,"__esModule",{value:!0});YS.formatNames=YS.fastFormats=YS.fullFormats=void 0;function ur(e,t){return{validate:e,compare:t}}YS.fullFormats={date:ur(GS,Bm),time:ur(Fm(!0),Hm),"date-time":ur(BS(!0),WS),"iso-time":ur(Fm(),JS),"iso-date-time":ur(BS(),KS),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:c4,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:h4,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:u4,int32:{type:"number",validate:d4},int64:{type:"number",validate:m4},float:{type:"number",validate:VS},double:{type:"number",validate:VS},password:!0,binary:!0};YS.fastFormats={...YS.fullFormats,date:ur(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,Bm),time:ur(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Hm),"date-time":ur(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,WS),"iso-time":ur(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,JS),"iso-date-time":ur(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,KS),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i};YS.formatNames=Object.keys(YS.fullFormats);function n4(e){return e%4===0&&(e%100!==0||e%400===0)}var o4=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,i4=[0,31,28,31,30,31,30,31,31,30,31,30,31];function GS(e){let t=o4.exec(e);if(!t)return!1;let r=+t[1],n=+t[2],o=+t[3];return n>=1&&n<=12&&o>=1&&o<=(n===2&&n4(r)?29:i4[n])}function Bm(e,t){if(!(e&&t))return;if(e>t)return 1;if(e<t)return-1;return 0}var Um=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function Fm(e){return function(r){let n=Um.exec(r);if(!n)return!1;let o=+n[1],i=+n[2],s=+n[3],a=n[4],c=n[5]==="-"?-1:1,u=+(n[6]||0),l=+(n[7]||0);if(u>23||l>59||e&&!a)return!1;if(o<=23&&i<=59&&s<60)return!0;let p=i-l*c,m=o-u*c-(p<0?1:0);return(m===23||m===-1)&&(p===59||p===-1)&&s<61}}function Hm(e,t){if(!(e&&t))return;let r=new Date("2020-01-01T"+e).valueOf(),n=new Date("2020-01-01T"+t).valueOf();if(!(r&&n))return;return r-n}function JS(e,t){if(!(e&&t))return;let r=Um.exec(e),n=Um.exec(t);if(!(r&&n))return;if(e=r[1]+r[2]+r[3],t=n[1]+n[2]+n[3],e>t)return 1;if(e<t)return-1;return 0}var Zm=/t|\s/i;function BS(e){let t=Fm(e);return function(n){let o=n.split(Zm);return o.length===2&&GS(o[0])&&t(o[1])}}function WS(e,t){if(!(e&&t))return;let r=new Date(e).valueOf(),n=new Date(t).valueOf();if(!(r&&n))return;return r-n}function KS(e,t){if(!(e&&t))return;let[r,n]=e.split(Zm),[o,i]=t.split(Zm),s=Bm(r,o);if(s===void 0)return;return s||Hm(n,i)}var s4=/\/|:/,a4=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function c4(e){return s4.test(e)&&a4.test(e)}var HS=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function u4(e){return HS.lastIndex=0,HS.test(e)}var l4=-2147483648,p4=2147483647;function d4(e){return Number.isInteger(e)&&e<=p4&&e>=l4}function m4(e){return Number.isInteger(e)}function VS(){return!0}var f4=/[^\\]\\Z/;function h4(e){if(f4.test(e))return!1;try{return new RegExp(e),!0}catch(t){return!1}}});var t$=_(function(e$){Object.defineProperty(e$,"__esModule",{value:!0});e$.formatLimitDefinition=void 0;var x4=qm(),er=W(),Hr=er.operators,Pc={formatMaximum:{okStr:"<=",ok:Hr.LTE,fail:Hr.GT},formatMinimum:{okStr:">=",ok:Hr.GTE,fail:Hr.LT},formatExclusiveMaximum:{okStr:"<",ok:Hr.LT,fail:Hr.GTE},formatExclusiveMinimum:{okStr:">",ok:Hr.GT,fail:Hr.LTE}},v4={message:({keyword:e,schemaCode:t})=>er.str`should be ${Pc[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>er._`{comparison: ${Pc[e].okStr}, limit: ${t}}`};e$.formatLimitDefinition={keyword:Object.keys(Pc),type:"string",schemaType:"string",$data:!0,error:v4,code(e){let{gen:t,data:r,schemaCode:n,keyword:o,it:i}=e,{opts:s,self:a}=i;if(!s.validateFormats)return;let c=new x4.KeywordCxt(i,a.RULES.all.format.definition,"format");if(c.$data)u();else l();function u(){let m=t.scopeValue("formats",{ref:a.formats,code:s.code.formats}),d=t.const("fmt",er._`${m}[${c.schemaCode}]`);e.fail$data((0,er.or)(er._`typeof ${d} != "object"`,er._`${d} instanceof RegExp`,er._`typeof ${d}.compare != "function"`,p(d)))}function l(){let m=c.schema,d=a.formats[m];if(!d||d===!0)return;if(typeof d!="object"||d instanceof RegExp||typeof d.compare!="function")throw Error(`"${o}": format "${m}" does not define "compare" function`);let h=t.scopeValue("formats",{key:m,ref:d,code:s.code.formats?er._`${s.code.formats}${(0,er.getProperty)(m)}`:void 0});e.fail$data(p(h))}function p(m){return er._`${m}.compare(${r}, ${n}) ${Pc[o].fail} 0`}},dependencies:["format"]};var y4=(e)=>(e.addKeyword(e$.formatLimitDefinition),e);e$.default=y4});var i$=_(function(ls,o$){Object.defineProperty(ls,"__esModule",{value:!0});var zo=QS(),_4=t$(),Jm=W(),r$=new Jm.Name("fullFormats"),w4=new Jm.Name("fastFormats"),Wm=(e,t={keywords:!0})=>{if(Array.isArray(t))return n$(e,t,zo.fullFormats,r$),e;let[r,n]=t.mode==="fast"?[zo.fastFormats,w4]:[zo.fullFormats,r$],o=t.formats||zo.formatNames;if(n$(e,o,r,n),t.keywords)(0,_4.default)(e);return e};Wm.get=(e,t="full")=>{let n=(t==="fast"?zo.fastFormats:zo.fullFormats)[e];if(!n)throw Error(`Unknown format "${e}"`);return n};function n$(e,t,r,n){var o,i;(o=(i=e.opts.code).formats)!==null&&o!==void 0||(i.formats=Jm._`require("ajv-formats/dist/formats").${n}`);for(let s of t)e.addFormat(s,r[s])}o$.exports=ls=Wm;Object.defineProperty(ls,"__esModule",{value:!0});ls.default=Wm});function Y4(e,t=[]){for(let r=0;r<e.length;r++){if(e[r].startsWith("-"))continue;if(r>0&&t.includes(e[r-1]))continue;return{before:e.slice(0,r),script:e[r],after:e.slice(r+1)}}return{before:e,script:void 0,after:[]}}function pf(e,t,r=[]){return(n)=>{let{before:o,script:i,after:s}=Y4(n,r);if(i===void 0)return[e,t,...o];if(s.length>0)return[e,t,...o,i,"--",...s];return[e,t,...o,i]}}function N$(e){return{agent:[e,0],run:[e,"run",0],install:[e,"i",0],frozen:[e,"i","--frozen-lockfile",0],global:[e,"add","-g",0],add:[e,"add",0],upgrade:[e,"update",0],"upgrade-interactive":[e,"update","-i",0],dedupe:[e,"dedupe",0],execute:[e,"dlx",0],"execute-local":[e,"exec",0],uninstall:[e,"remove",0],global_uninstall:[e,"remove","--global",0]}}function D$(e,t,r){let n=df[e][t];return mf(n,r)}function mf(e,t){if(e==null)return null;let r=typeof e==="function"?e(t):e.flatMap((n)=>{if(typeof n==="number")return t;return[n]});return{command:r[0],args:r.slice(1)}}var X4,j$,Q4,I$,eZ,tZ,rZ,nZ,oZ,df;var L$=bs(()=>{X4={agent:["npm",0],run:pf("npm","run",["-w","--workspace"]),install:["npm","i",0],frozen:["npm","ci",0],global:["npm","i","-g",0],add:["npm","i",0],upgrade:["npm","update",0],"upgrade-interactive":null,dedupe:["npm","dedupe",0],execute:["npx",0],"execute-local":["npx",0],uninstall:["npm","uninstall",0],global_uninstall:["npm","uninstall","-g",0]},j$={agent:["yarn",0],run:["yarn","run",0],install:["yarn","install",0],frozen:["yarn","install","--frozen-lockfile",0],global:["yarn","global","add",0],add:["yarn","add",0],upgrade:["yarn","upgrade",0],"upgrade-interactive":["yarn","upgrade-interactive",0],dedupe:null,execute:["npx",0],"execute-local":pf("yarn","exec"),uninstall:["yarn","remove",0],global_uninstall:["yarn","global","remove",0]},Q4={...j$,frozen:["yarn","install","--immutable",0],upgrade:["yarn","up",0],"upgrade-interactive":["yarn","up","-i",0],dedupe:["yarn","dedupe",0],execute:["yarn","dlx",0],"execute-local":["yarn","exec",0],global:["npm","i","-g",0],global_uninstall:["npm","uninstall","-g",0]};I$=N$("pnpm"),eZ=N$("rush-pnpm"),tZ={agent:["bun",0],run:["bun","run",0],install:["bun","install",0],frozen:["bun","install","--frozen-lockfile",0],global:["bun","add","-g",0],add:["bun","add",0],upgrade:["bun","update",0],"upgrade-interactive":["bun","update","-i",0],dedupe:null,execute:["bun","x",0],"execute-local":["bun","x",0],uninstall:["bun","remove",0],global_uninstall:["bun","remove","-g",0]},rZ={agent:["aube",0],run:["aube","run",0],install:["aube","install",0],frozen:["aube","install","--frozen-lockfile",0],global:["aube","add","-g",0],add:["aube","add",0],upgrade:["aube","update",0],"upgrade-interactive":["aube","update","-i",0],dedupe:["aube","dedupe",0],execute:["aube","dlx",0],"execute-local":["aube","exec",0],uninstall:["aube","remove",0],global_uninstall:["aube","remove","-g",0]},nZ={agent:["deno",0],run:["deno","task",0],install:["deno","install",0],frozen:["deno","install","--frozen",0],global:["deno","install","-g",0],add:["deno","add",0],upgrade:["deno","outdated","--update",0],"upgrade-interactive":["deno","outdated","--update",0],dedupe:null,execute:["deno","x",0],"execute-local":["deno","task","--eval",0],uninstall:["deno","remove",0],global_uninstall:["deno","uninstall","-g",0]},oZ={agent:["nub",0],run:["nub","run",0],install:["nub","install",0],frozen:["nub","install","--frozen-lockfile",0],global:["nub","add","-g",0],add:["nub","add",0],upgrade:["nub","update",0],"upgrade-interactive":["nub","update","-i",0],dedupe:["nub","dedupe",0],execute:["nubx",0],"execute-local":["nub","exec",0],uninstall:["nub","remove",0],global_uninstall:["nub","remove","-g",0]},df={npm:X4,yarn:j$,"yarn@berry":Q4,pnpm:I$,"pnpm@6":{...I$,run:pf("pnpm","run",["-F","--filter"])},"pnpm-rush":eZ,bun:tZ,aube:rZ,deno:nZ,nub:oZ}});var ms,fs,hs,M$;var ff=bs(()=>{ms=["npm","yarn","yarn@berry","pnpm","pnpm@6","pnpm-rush","bun","deno","nub","aube"],fs={"aube-lock.yaml":"aube","aube-workspace.yaml":"aube","bun.lock":"bun","bun.lockb":"bun","deno.lock":"deno","nub.lock":"nub","pnpm-lock.yaml":"pnpm","pnpm-workspace.yaml":"pnpm","yarn.lock":"yarn","package-lock.json":"npm","npm-shrinkwrap.json":"npm"},hs={"node_modules/.aube/":"aube","node_modules/.deno/":"deno","node_modules/.pnpm/":"pnpm","node_modules/.yarn-state.yml":"yarn","node_modules/.yarn_integrity":"yarn","node_modules/.package-lock.json":"npm",".pnp.cjs":"yarn",".pnp.js":"yarn","bun.lock":"bun","bun.lockb":"bun"},M$={aube:"https://aube.en.dev/installation",bun:"https://bun.sh",deno:"https://deno.com",pnpm:"https://pnpm.io/installation","pnpm@6":"https://pnpm.io/6.x/installation","pnpm-rush":"https://rushjs.io/pages/intro/get_started/",yarn:"https://classic.yarnpkg.com/en/docs/install","yarn@berry":"https://yarnpkg.com/getting-started/install",npm:"https://docs.npmjs.com/cli/configuring-npm/install",nub:"https://nubjs.com/docs/install"}});import U$ from"node:fs/promises";import yr from"node:path";import F$ from"node:process";async function Ic(e,t){try{let r=await U$.stat(e);return t==="file"?r.isFile():r.isDirectory()}catch{return!1}}function Z$(){let e=F$.env.npm_config_user_agent;if(!e)return null;let t=e.split("/")[0];return ms.includes(t)?t:null}function*iZ(e=F$.cwd()){let t=yr.resolve(e),{root:r}=yr.parse(t);while(t&&t!==r)yield t,t=yr.dirname(t)}async function q$(e,t){if(!e||!await Ic(e,"file"))return null;return await aZ(e,t)}async function B$(e={}){let{cwd:t,strategies:r=["lockfile","packageManager-field","devEngines-field"]}=e,n;if(typeof e.stopDir==="string"){let o=yr.resolve(e.stopDir);n=(i)=>i===o}else n=e.stopDir;for(let o of iZ(t)){for(let i of r)switch(i){case"lockfile":{if(await Ic(yr.join(o,"rush.json"),"file"))return{name:"pnpm",agent:"pnpm-rush"};for(let s of Object.keys(fs))if(await Ic(yr.join(o,s),"file")){let a=fs[s],c=await q$(yr.join(o,"package.json"),e);if(c)return c;else return{name:a,agent:a}}break}case"packageManager-field":case"devEngines-field":{let s=await q$(yr.join(o,"package.json"),e);if(s)return s;break}case"install-metadata":{for(let s of Object.keys(hs)){let a=s.endsWith("/")?"dir":"file";if(await Ic(yr.join(o,s),a)){let c=hs[s],u=c==="yarn"?cZ(s)?"yarn":"yarn@berry":c;return{name:c,agent:u}}}break}}if(n?.(o))break}return null}function sZ(e){let t=(r)=>r?.match(/\d+(\.\d+){0,2}/)?.[0]??r;if(typeof e.packageManager==="string"){let[r,n]=e.packageManager.replace(/^\^/,"").split("@");return{name:r,ver:t(n)}}if(typeof e.devEngines?.packageManager?.name==="string")return{name:e.devEngines.packageManager.name,ver:t(e.devEngines.packageManager.version)};return}async function aZ(e,t){try{let r=await U$.readFile(e,"utf8"),n=t.packageJsonParser?await t.packageJsonParser(r,e):JSON.parse(r),o,i=sZ(n);if(i){let{name:s,ver:a}=i,c=a;if(s==="yarn"&&a&&Number.parseInt(a)>1)return o="yarn@berry",c="berry",{name:s,agent:o,version:c};else if(s==="pnpm"&&a&&Number.parseInt(a)<7)return o="pnpm@6",{name:s,agent:o,version:c};else if(ms.includes(s))return o=s,{name:s,agent:o,version:c};else return t.onUnknown?.(n.packageManager)??null}}catch{}return null}function cZ(e){return e.endsWith(".yarn_integrity")}var H$=bs(()=>{ff()});var V$={};No(V$,{AGENTS:()=>ms,COMMANDS:()=>df,INSTALL_METADATA:()=>hs,INSTALL_PAGE:()=>M$,LOCKS:()=>fs,constructCommand:()=>mf,detect:()=>B$,getUserAgent:()=>Z$,resolveCommand:()=>D$});var G$=bs(()=>{L$();ff();H$()});import{promises as wf,readFileSync as vZ}from"node:fs";function Do(e,t){return function(){return e.apply(t,arguments)}}var{toString:wT}=Object.prototype,{getPrototypeOf:zn}=Object,{iterator:Mo,toStringTag:Of}=Symbol,ws=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),Lo=(e,t)=>{let r=e,n=[];while(r!=null&&r!==Object.prototype){if(n.indexOf(r)!==-1)return!1;if(n.push(r),ws(r,t))return!0;r=zn(r)}return!1},kT=(e,t)=>e!=null&&Lo(e,t)?e[t]:void 0,Hc=((e)=>(t)=>{let r=wT.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Lt=(e)=>(e=e.toLowerCase(),(t)=>Hc(t)===e),ks=(e)=>(t)=>typeof t===e,{isArray:Qr}=Array,On=ks("undefined");function An(e){return e!==null&&!On(e)&&e.constructor!==null&&!On(e.constructor)&&dt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}var Af=Lt("ArrayBuffer");function ST(e){let t;if(typeof ArrayBuffer<"u"&&ArrayBuffer.isView)t=ArrayBuffer.isView(e);else t=e&&e.buffer&&Af(e.buffer);return t}var $T=ks("string"),dt=ks("function"),Cf=ks("number"),Cn=(e)=>e!==null&&typeof e==="object",TT=(e)=>e===!0||e===!1,_s=(e)=>{if(!Cn(e))return!1;let t=zn(e);return(t===null||t===Object.prototype||zn(t)===null)&&!Lo(e,Of)&&!Lo(e,Mo)},ET=(e)=>{if(!Cn(e)||An(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},RT=Lt("Date"),PT=Lt("File"),zT=(e)=>!!(e&&typeof e.uri<"u"),OT=(e)=>e&&typeof e.getParts<"u",AT=Lt("Blob"),CT=Lt("FileList"),IT=(e)=>Cn(e)&&dt(e.pipe);function jT(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;return{}}var Pf=jT(),zf=typeof Pf.FormData<"u"?Pf.FormData:void 0,NT=(e)=>{if(!e)return!1;if(zf&&e instanceof zf)return!0;let t=zn(e);if(!t||t===Object.prototype)return!1;if(!dt(e.append))return!1;let r=Hc(e);return r==="formdata"||r==="object"&&dt(e.toString)&&e.toString()==="[object FormData]"},DT=Lt("URLSearchParams"),[LT,MT,qT,UT]=["ReadableStream","Request","Response","Headers"].map(Lt),FT=(e)=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function qo(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,o;if(typeof e!=="object")e=[e];if(Qr(e))for(n=0,o=e.length;n<o;n++)t.call(null,e[n],n,e);else{if(An(e))return;let i=r?Object.getOwnPropertyNames(e):Object.keys(e),s=i.length,a;for(n=0;n<s;n++)a=i[n],t.call(null,e[a],a,e)}}function If(e,t){if(An(e))return null;t=t.toLowerCase();let r=Object.keys(e),n=r.length,o;while(n-- >0)if(o=r[n],t===o.toLowerCase())return o;return null}var Xr=(()=>{if(typeof globalThis<"u")return globalThis;return typeof self<"u"?self:typeof window<"u"?window:global})(),jf=(e)=>!On(e)&&e!==Xr;function Bc(...e){let{caseless:t,skipUndefined:r}=jf(this)&&this||{},n={},o=(i,s)=>{if(s==="__proto__"||s==="constructor"||s==="prototype")return;let a=t&&typeof s==="string"&&If(n,s)||s,c=ws(n,a)?n[a]:void 0;if(_s(c)&&_s(i))n[a]=Bc(c,i);else if(_s(i))n[a]=Bc({},i);else if(Qr(i))n[a]=i.slice();else if(!r||!On(i))n[a]=i};for(let i=0,s=e.length;i<s;i++){let a=e[i];if(!a||An(a))continue;if(qo(a,o),typeof a!=="object"||Qr(a))continue;let c=Object.getOwnPropertySymbols(a);for(let u=0;u<c.length;u++){let l=c[u];if(eE.call(a,l))o(a[l],l)}}return n}var ZT=(e,t,r,{allOwnKeys:n}={})=>(qo(t,(o,i)=>{if(r&&dt(o))Object.defineProperty(e,i,{__proto__:null,value:Do(o,r),writable:!0,enumerable:!0,configurable:!0});else Object.defineProperty(e,i,{__proto__:null,value:o,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),BT=(e)=>{if(e.charCodeAt(0)===65279)e=e.slice(1);return e},HT=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),r&&Object.assign(e.prototype,r)},VT=(e,t,r,n)=>{let o,i,s,a={};if(t=t||{},e==null)return t;do{o=Object.getOwnPropertyNames(e),i=o.length;while(i-- >0)if(s=o[i],(!n||n(s,e,t))&&!a[s])t[s]=e[s],a[s]=!0;e=r!==!1&&zn(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},GT=(e,t,r)=>{if(e=String(e),r===void 0||r>e.length)r=e.length;r-=t.length;let n=e.indexOf(t,r);return n!==-1&&n===r},JT=(e)=>{if(!e)return null;if(Qr(e))return e;let t=e.length;if(!Cf(t))return null;let r=Array(t);while(t-- >0)r[t]=e[t];return r},WT=((e)=>(t)=>e&&t instanceof e)(typeof Uint8Array<"u"&&zn(Uint8Array)),KT=(e,t)=>{let n=(e&&e[Mo]).call(e),o;while((o=n.next())&&!o.done){let i=o.value;t.call(e,i[0],i[1])}},YT=(e,t)=>{let r,n=[];while((r=e.exec(t))!==null)n.push(r);return n},XT=Lt("HTMLFormElement"),QT=(e)=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,o){return n.toUpperCase()+o}),{propertyIsEnumerable:eE}=Object.prototype,tE=Lt("RegExp"),Nf=(e,t)=>{let r=Object.getOwnPropertyDescriptors(e),n={};qo(r,(o,i)=>{let s;if((s=t(o,i,e))!==!1)n[i]=s||o}),Object.defineProperties(e,n)},rE=(e)=>{Nf(e,(t,r)=>{if(dt(e)&&["arguments","caller","callee"].includes(r))return!1;let n=e[r];if(!dt(n))return;if(t.enumerable=!1,"writable"in t){t.writable=!1;return}if(!t.set)t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")}})},nE=(e,t)=>{let r={},n=(o)=>{o.forEach((i)=>{r[i]=!0})};return Qr(e)?n(e):n(String(e).split(t)),r},oE=()=>{},iE=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function sE(e){return!!(e&&dt(e.append)&&e[Of]==="FormData"&&e[Mo])}var aE=(e)=>{let t=new WeakSet,r=(n)=>{if(Cn(n)){if(t.has(n))return;if(An(n))return n;if(!("toJSON"in n)){t.add(n);let o=Qr(n)?[]:{};return qo(n,(i,s)=>{let a=r(i);!On(a)&&(o[s]=a)}),t.delete(n),o}}return n};return r(e)},cE=Lt("AsyncFunction"),uE=(e)=>e&&(Cn(e)||dt(e))&&dt(e.then)&&dt(e.catch),Df=((e,t)=>{if(e)return setImmediate;return t?((r,n)=>(Xr.addEventListener("message",({source:o,data:i})=>{if(o===Xr&&i===r)n.length&&n.shift()()},!1),(o)=>{n.push(o),Xr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):(r)=>setTimeout(r)})(typeof setImmediate==="function",dt(Xr.postMessage)),lE=typeof queueMicrotask<"u"?queueMicrotask.bind(Xr):typeof process<"u"&&process.nextTick||Df,Lf=(e)=>e!=null&&dt(e[Mo]),pE=(e)=>e!=null&&Lo(e,Mo)&&Lf(e),f={isArray:Qr,isArrayBuffer:Af,isBuffer:An,isFormData:NT,isArrayBufferView:ST,isString:$T,isNumber:Cf,isBoolean:TT,isObject:Cn,isPlainObject:_s,isEmptyObject:ET,isReadableStream:LT,isRequest:MT,isResponse:qT,isHeaders:UT,isUndefined:On,isDate:RT,isFile:PT,isReactNativeBlob:zT,isReactNative:OT,isBlob:AT,isRegExp:tE,isFunction:dt,isStream:IT,isURLSearchParams:DT,isTypedArray:WT,isFileList:CT,forEach:qo,merge:Bc,extend:ZT,trim:FT,stripBOM:BT,inherits:HT,toFlatObject:VT,kindOf:Hc,kindOfTest:Lt,endsWith:GT,toArray:JT,forEachEntry:KT,matchAll:YT,isHTMLForm:XT,hasOwnProperty:ws,hasOwnProp:ws,hasOwnInPrototypeChain:Lo,getSafeProp:kT,reduceDescriptors:Nf,freezeMethods:rE,toObjectSet:nE,toCamelCase:QT,noop:oE,toFiniteNumber:iE,findKey:If,global:Xr,isContextDefined:jf,isSpecCompliantForm:sE,toJSONObject:aE,isAsyncFn:cE,isThenable:uE,setImmediate:Df,asap:lE,isIterable:Lf,isSafeIterable:pE};var dE=f.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"]),Mf=(e)=>{let t={},r,n,o;return e&&e.split(`
|
|
27
|
-
`).forEach(function(s){if(o=s.indexOf(":"),r=s.substring(0,o).trim().toLowerCase(),n=s.substring(o+1).trim(),!r||t[r]&&
|
|
28
|
-
`)}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((n)=>r.set(n)),r}static accessor(e){let r=(this[Uf]=this[Uf]={accessors:{}}).accessors,n=this.prototype;function o(i){let s=Uo(i);if(!r[s])bE(n,i),r[s]=!0}return f.isArray(e)?e.forEach(o):o(e),this}}Fo.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);f.reduceDescriptors(Fo.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});f.freezeMethods(Fo);var ye=Fo;var _E="[REDACTED ****]";function wE(e){if(f.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);while(t&&t!==Object.prototype){if(f.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function kE(e,t){let r=new Set(t.map((i)=>String(i).toLowerCase())),n=[],o=(i)=>{if(i===null||typeof i!=="object")return i;if(f.isBuffer(i))return i;if(n.indexOf(i)!==-1)return;if(i instanceof ye)i=i.toJSON();n.push(i);let s;if(f.isArray(i))s=[],i.forEach((a,c)=>{let u=o(a);if(!f.isUndefined(u))s[c]=u});else{if(!f.isPlainObject(i)&&wE(i))return n.pop(),i;s=Object.create(null);for(let[a,c]of Object.entries(i)){let u=r.has(a.toLowerCase())?_E:o(c);if(!f.isUndefined(u))s[a]=u}}return n.pop(),s};return o(e)}class We extends Error{static from(e,t,r,n,o,i){let s=new We(e.message,t||e.code,r,n,o);if(s.cause=e,s.name=e.name,e.status!=null&&s.status==null)s.status=e.status;return i&&Object.assign(s,i),s}constructor(e,t,r,n,o){super(e);if(Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),o)this.response=o,this.status=o.status}toJSON(){let e=this.config,t=e&&f.hasOwnProp(e,"redact")?e.redact:void 0,r=f.isArray(t)&&t.length>0?kE(e,t):f.toJSONObject(e);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:r,code:this.code,status:this.status}}}We.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";We.ERR_BAD_OPTION="ERR_BAD_OPTION";We.ECONNABORTED="ECONNABORTED";We.ETIMEDOUT="ETIMEDOUT";We.ECONNREFUSED="ECONNREFUSED";We.ERR_NETWORK="ERR_NETWORK";We.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";We.ERR_DEPRECATED="ERR_DEPRECATED";We.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";We.ERR_BAD_REQUEST="ERR_BAD_REQUEST";We.ERR_CANCELED="ERR_CANCELED";We.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";We.ERR_INVALID_URL="ERR_INVALID_URL";We.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";var T=We;var Hg=jo(Bg(),1),js=Hg.default;var vu=100;function xu(e){return f.isPlainObject(e)||f.isArray(e)}function Vg(e){return f.endsWith(e,"[]")?e.slice(0,-2):e}function gu(e,t,r){if(!e)return t;return e.concat(t).map(function(o,i){return o=Vg(o),!r&&i?"["+o+"]":o}).join(r?".":"")}function dP(e){return f.isArray(e)&&!e.some(xu)}var mP=f.toFlatObject(f,{},null,function(t){return/^is[A-Z]/.test(t)});function fP(e,t,r){if(!f.isObject(e))throw TypeError("target must be an object");t=t||new(js||FormData),r=f.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(b,k){return!f.isUndefined(k[b])});let n=r.metaTokens,o=r.visitor||h,i=r.dots,s=r.indexes,a=r.Blob||typeof Blob<"u"&&Blob,c=r.maxDepth===void 0?vu:r.maxDepth,u=a&&f.isSpecCompliantForm(t),l=[];if(!f.isFunction(o))throw TypeError("visitor must be a function");function p(g){if(g===null)return"";if(f.isDate(g))return g.toISOString();if(f.isBoolean(g))return g.toString();if(!u&&f.isBlob(g))throw new T("Blob is not supported. Use a Buffer instead.");if(f.isArrayBuffer(g)||f.isTypedArray(g))return u&&typeof Blob==="function"?new Blob([g]):Buffer.from(g);return g}function m(g){if(g>c)throw new T("Object is too deeply nested ("+g+" levels). Max depth: "+c,T.ERR_FORM_DATA_DEPTH_EXCEEDED)}function d(g,b){if(c===1/0)return JSON.stringify(g);let k=[];return JSON.stringify(g,function(I,H){if(!f.isObject(H))return H;while(k.length&&k[k.length-1]!==this)k.pop();return k.push(H),m(b+k.length-1),H})}function h(g,b,k){let z=g;if(f.isReactNative(t)&&f.isReactNativeBlob(g))return t.append(gu(k,b,i),p(g)),!1;if(g&&!k&&typeof g==="object"){if(f.endsWith(b,"{}"))b=n?b:b.slice(0,-2),g=d(g,1);else if(f.isArray(g)&&dP(g)||(f.isFileList(g)||f.endsWith(b,"[]"))&&(z=f.toArray(g)))return b=Vg(b),z.forEach(function(H,me){!(f.isUndefined(H)||H===null)&&t.append(s===!0?gu([b],me,i):s===null?b:b+"[]",p(H))}),!1}if(xu(g))return!0;return t.append(gu(k,b,i),p(g)),!1}let x=Object.assign(mP,{defaultVisitor:h,convertValue:p,isVisitable:xu});function y(g,b,k=0){if(f.isUndefined(g))return;if(m(k),l.indexOf(g)!==-1)throw Error("Circular reference detected in "+b.join("."));l.push(g),f.forEach(g,function(I,H){if((!(f.isUndefined(I)||I===null)&&o.call(t,I,f.isString(H)?H.trim():H,b,x))===!0)y(I,b?b.concat(H):[H],k+1)}),l.pop()}if(!f.isObject(e))throw TypeError("data must be an object");return y(e),t}var Sr=fP;function Gg(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(n){return t[n]})}function Jg(e,t){this._pairs=[],e&&Sr(e,this,t)}var Wg=Jg.prototype;Wg.append=function(t,r){this._pairs.push([t,r])};Wg.toString=function(t){let r=t?function(n){return t.call(this,n,Gg)}:Gg;return this._pairs.map(function(o){return r(o[0])+"="+r(o[1])},"").join("&")};var Kg=Jg;function hP(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function tn(e,t,r){if(!t)return e;let n=f.isFunction(r)?{serialize:r}:r,o=f.getSafeProp(n,"encode")||hP,i=f.getSafeProp(n,"serialize"),s;if(i)s=i(t,n);else s=f.isURLSearchParams(t)?t.toString():new Kg(t,n).toString(o);if(s){let a=e.indexOf("#");if(a!==-1)e=e.slice(0,a);e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class Yg{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){if(this.handlers[e])this.handlers[e]=null}clear(){if(this.handlers)this.handlers=[]}forEach(e){f.forEach(this.handlers,function(r){if(r!==null)e(r)})}}var yu=Yg;var $r={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0};import xP from"crypto";import gP from"url";var Xg=gP.URLSearchParams;var bu="abcdefghijklmnopqrstuvwxyz",Qg="0123456789",ex={DIGIT:Qg,ALPHA:bu,ALPHA_DIGIT:bu+bu.toUpperCase()+Qg},vP=(e=16,t=ex.ALPHA_DIGIT)=>{let r="",{length:n}=t,o=new Uint32Array(e);xP.randomFillSync(o);for(let i=0;i<e;i++)r+=t[o[i]%n];return r},tx={isNode:!0,classes:{URLSearchParams:Xg,FormData:js,Blob:typeof Blob<"u"&&Blob||null},ALPHABET:ex,generateString:vP,protocols:["http","https","file","data"]};var ku={};No(ku,{hasBrowserEnv:()=>wu,hasStandardBrowserEnv:()=>yP,hasStandardBrowserWebWorkerEnv:()=>bP,navigator:()=>_u,origin:()=>_P});var wu=typeof window<"u"&&typeof document<"u",_u=typeof navigator==="object"&&navigator||void 0,yP=wu&&(!_u||["ReactNative","NativeScript","NS"].indexOf(_u.product)<0),bP=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts==="function")(),_P=wu&&window.location.href||"http://localhost";var ue={...ku,...tx};function Su(e,t){return Sr(e,new ue.classes.URLSearchParams,{visitor:function(r,n,o,i){if(ue.isNode&&f.isBuffer(r))return this.append(n,r.toString("base64")),!1;return i.defaultVisitor.apply(this,arguments)},...t})}var rx=vu;function nx(e){if(e>rx)throw new T("FormData field is too deeply nested ("+e+" levels). Max depth: "+rx,T.ERR_FORM_DATA_DEPTH_EXCEEDED)}function wP(e){let t=[],r=/\w+|\[(\w*)]/g,n;while((n=r.exec(e))!==null)nx(t.length),t.push(n[0]==="[]"?"":n[1]||n[0]);return t}function kP(e){let t={},r=Object.keys(e),n,o=r.length,i;for(n=0;n<o;n++)i=r[n],t[i]=e[i];return t}function SP(e){function t(r,n,o,i){nx(i);let s=r[i++];if(s==="__proto__")return!0;let a=Number.isFinite(+s),c=i>=r.length;if(s=!s&&f.isArray(o)?o.length:s,c){if(f.hasOwnProp(o,s))o[s]=f.isArray(o[s])?o[s].concat(n):[o[s],n];else o[s]=n;return!a}if(!f.hasOwnProp(o,s)||!f.isObject(o[s]))o[s]=[];if(t(r,n,o[s],i)&&f.isArray(o[s]))o[s]=kP(o[s]);return!a}if(f.isFormData(e)&&f.isFunction(e.entries)){let r={};return f.forEachEntry(e,(n,o)=>{t(wP(n),o,r,0)}),r}return null}var Ns=SP;var Mn=(e,t)=>e!=null&&f.hasOwnProp(e,t)?e[t]:void 0;function $P(e,t,r){if(f.isString(e))try{return(t||JSON.parse)(e),f.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}var $u={transitional:$r,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){let n=r.getContentType()||"",o=n.indexOf("application/json")>-1,i=f.isObject(t);if(i&&f.isHTMLForm(t))t=new FormData(t);if(f.isFormData(t))return o?JSON.stringify(Ns(t)):t;if(f.isArrayBuffer(t)||f.isBuffer(t)||f.isStream(t)||f.isFile(t)||f.isBlob(t)||f.isReadableStream(t))return t;if(f.isArrayBufferView(t))return t.buffer;if(f.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(i){let c=Mn(this,"formSerializer");if(n.indexOf("application/x-www-form-urlencoded")>-1)return Su(t,c).toString();if((a=f.isFileList(t))||n.indexOf("multipart/form-data")>-1){let u=Mn(this,"env"),l=u&&u.FormData;return Sr(a?{"files[]":t}:t,l&&new l,c)}}if(i||o)return r.setContentType("application/json",!1),$P(t);return t}],transformResponse:[function(t){let r=Mn(this,"transitional")||$u.transitional,n=r&&r.forcedJSONParsing,o=Mn(this,"responseType"),i=o==="json";if(f.isResponse(t)||f.isReadableStream(t))return t;if(t&&f.isString(t)&&(n&&!o||i)){let a=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(t,Mn(this,"parseReviver"))}catch(c){if(a){if(c.name==="SyntaxError")throw T.from(c,T.ERR_BAD_RESPONSE,this,null,Mn(this,"response"));throw c}}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ue.classes.FormData,Blob:ue.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};f.forEach(["delete","get","head","post","put","patch","query"],(e)=>{$u.headers[e]={}});var qn=$u;function Go(e,t){let r=this||qn,n=t||r,o=ye.from(n.headers),i=n.data;return f.forEach(e,function(a){i=a.call(r,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function Jo(e){return!!(e&&e.__CANCEL__)}class ox extends T{constructor(e,t,r){super(e==null?"canceled":e,T.ERR_CANCELED,t,r);this.name="CanceledError",this.__CANCEL__=!0}}var wt=ox;function nr(e,t,r){let n=r.config.validateStatus;if(!r.status||!n||n(r.status))e(r);else t(new T("Request failed with status code "+r.status,r.status>=400&&r.status<500?T.ERR_BAD_REQUEST:T.ERR_BAD_RESPONSE,r.config,r.request,r))}function Tu(e){if(typeof e!=="string")return!1;return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Eu(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}var TP=/^https?:(?!\/\/)/i,EP=/[\t\n\r]/g;function RP(e){let t=0;while(t<e.length&&e.charCodeAt(t)<=32)t++;return e.slice(t)}function PP(e){return RP(e).replace(EP,"")}function ix(e,t){if(typeof e==="string"&&TP.test(PP(e)))throw new T('Invalid URL: missing "//" after protocol',T.ERR_INVALID_URL,t)}function rn(e,t,r,n){ix(t,n);let o=!Tu(t);if(e&&(o||r===!1))return ix(e,n),Eu(e,t);return t}var zP={ftp:21,gopher:70,http:80,https:443,ws:80,wss:443};function OP(e){try{return new URL(e)}catch{return null}}function sx(e){var t=(typeof e==="string"?OP(e):e)||{},r=t.protocol,n=t.host,o=t.port;if(typeof n!=="string"||!n||typeof r!=="string")return"";if(r=r.split(":",1)[0],n=n.replace(/:\d*$/,""),o=parseInt(o)||zP[r]||0,!AP(n,o))return"";var i=Ru(r+"_proxy")||Ru("all_proxy");if(i&&i.indexOf("://")===-1)i=r+"://"+i;return i}function AP(e,t){var r=Ru("no_proxy").toLowerCase();if(!r)return!0;if(r==="*")return!1;return r.split(/[,\s]/).every(function(n){if(!n)return!0;var o=n.match(/^(.+):(\d+)$/),i=o?o[1]:n,s=o?parseInt(o[2]):0;if(s&&s!==t)return!0;if(!/^[.*]/.test(i))return e!==i;if(i.charAt(0)==="*")i=i.slice(1);return!e.endsWith(i)})}function Ru(e){return process.env[e.toLowerCase()]||process.env[e.toUpperCase()]||""}var tl=jo(Ax(),1),cv=jo(Mx(),1);import yO from"http";import bO from"https";import _O from"http2";import wO from"util";import{resolve as ev}from"path";import Ot from"zlib";var lr="1.18.0";function ii(e){let t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}var Wz=/^([^,;]+\/[^,;]+)?((?:;[^,;=]+=[^,;]+)*)(;base64)?,([\s\S]*)$/;function Ku(e,t,r){let n=r&&r.Blob||ue.classes.Blob,o=ii(e);if(t===void 0&&n)t=!0;if(o==="data"){e=o.length?e.slice(o.length+1):e;let i=Wz.exec(e);if(!i)throw new T("Invalid URL",T.ERR_INVALID_URL);let s=i[1],a=i[2],c=i[3]?"base64":"utf8",u=i[4],l;if(s)l=a?s+a:s;else if(a)l="text/plain"+a;let p=Buffer.from(decodeURIComponent(u),c);if(t){if(!n)throw new T("Blob is not supported",T.ERR_NOT_SUPPORT);return new n([p],{type:l})}return p}throw new T("Unsupported protocol "+o,T.ERR_NOT_SUPPORT)}import qt from"stream";import Kz from"stream";var Yu=Symbol("internals");class qx extends Kz.Transform{constructor(e){e=f.toFlatObject(e,{maxRate:0,chunkSize:65536,minChunkSize:100,timeWindow:500,ticksRate:2,samplesCount:15},null,(r,n)=>!f.isUndefined(n[r]));super({readableHighWaterMark:e.chunkSize});let t=this[Yu]={timeWindow:e.timeWindow,chunkSize:e.chunkSize,maxRate:e.maxRate,minChunkSize:e.minChunkSize,bytesSeen:0,isCaptured:!1,notifiedBytesLoaded:0,ts:Date.now(),bytes:0,onReadCallback:null};this.on("newListener",(r)=>{if(r==="progress"){if(!t.isCaptured)t.isCaptured=!0}})}_read(e){let t=this[Yu];if(t.onReadCallback)t.onReadCallback();return super._read(e)}_transform(e,t,r){let n=this[Yu],o=n.maxRate,i=this.readableHighWaterMark,s=n.timeWindow,a=1000/s,c=o/a,u=n.minChunkSize!==!1?Math.max(n.minChunkSize,c*0.01):0,l=(m,d)=>{let h=Buffer.byteLength(m);if(n.bytesSeen+=h,n.bytes+=h,n.isCaptured&&this.emit("progress",n.bytesSeen),this.push(m))process.nextTick(d);else n.onReadCallback=()=>{n.onReadCallback=null,process.nextTick(d)}},p=(m,d)=>{let h=Buffer.byteLength(m),x=null,y=i,g,b=0;if(o){let k=Date.now();if(!n.ts||(b=k-n.ts)>=s)n.ts=k,g=c-n.bytes,n.bytes=g<0?-g:0,b=0;g=c-n.bytes}if(o){if(g<=0)return setTimeout(()=>{d(null,m)},s-b);if(g<y)y=g}if(y&&h>y&&h-y>u)x=m.subarray(y),m=m.subarray(0,y);l(m,x?()=>{process.nextTick(d,null,x)}:d)};p(e,function m(d,h){if(d)return r(d);if(h)p(h,m);else r(null)})}}var Xu=qx;import{EventEmitter as kO}from"events";import Xz from"util";import{Readable as Qz}from"stream";var{asyncIterator:Ux}=Symbol,Yz=async function*(e){if(e.stream)yield*e.stream();else if(e.arrayBuffer)yield await e.arrayBuffer();else if(e[Ux])yield*e[Ux]();else yield e},Fs=Yz;var eO=ue.ALPHABET.ALPHA_DIGIT+"-_",si=typeof TextEncoder==="function"?new TextEncoder:new Xz.TextEncoder,un=`\r
|
|
29
|
-
`,tO=si.encode(un),rO=2;class Fx{constructor(e,t){let{escapeName:r}=this.constructor,n=f.isString(t),o=`Content-Disposition: form-data; name="${r(e)}"${!n&&t.name?`; filename="${r(t.name)}"`:""}${un}`;if(n)t=si.encode(String(t).replace(/\r?\n|\r\n?/g,un));else{let i=String(t.type||"application/octet-stream").replace(/[\r\n]/g,"");o+=`Content-Type: ${i}${un}`}this.headers=si.encode(o+un),this.contentLength=n?t.byteLength:t.size,this.size=this.headers.byteLength+this.contentLength+rO,this.name=e,this.value=t}async*encode(){yield this.headers;let{value:e}=this;if(f.isTypedArray(e))yield e;else yield*Fs(e);yield tO}static escapeName(e){return String(e).replace(/[\r\n"]/g,(t)=>({"\r":"%0D","\n":"%0A",'"':"%22"})[t])}}var nO=(e,t,r)=>{let{tag:n="form-data-boundary",size:o=25,boundary:i=n+"-"+ue.generateString(o,eO)}=r||{};if(!f.isFormData(e))throw TypeError("FormData instance required");if(i.length<1||i.length>70)throw Error("boundary must be 1-70 characters long");let s=si.encode("--"+i+un),a=si.encode("--"+i+"--"+un),c=a.byteLength,u=Array.from(e.entries()).map(([p,m])=>{let d=new Fx(p,m);return c+=d.size,d});c+=s.byteLength*u.length,c=f.toFiniteNumber(c);let l={"Content-Type":`multipart/form-data; boundary=${i}`};if(Number.isFinite(c))l["Content-Length"]=c;return t&&t(l),Qz.from(async function*(){for(let p of u)yield s,yield*p.encode();yield a}())},Zx=nO;import oO from"stream";class Bx extends oO.Transform{__transform(e,t,r){this.push(e),r()}_transform(e,t,r){if(e.length!==0){if(this._transform=this.__transform,e[0]!==120){let n=Buffer.alloc(2);n[0]=120,n[1]=156,this.push(n,t)}}this.__transform(e,t,r)}}var Hx=Bx;import iO from"http2";import sO from"util";class Vx{constructor(){this.sessions=Object.create(null)}getSession(e,t){t=Object.assign({sessionTimeout:1000},t);let r=this.sessions[e];if(r){let l=r.length;for(let p=0;p<l;p++){let[m,d]=r[p];if(!m.destroyed&&!m.closed&&sO.isDeepStrictEqual(d,t))return m}}let n=iO.connect(e,t),o,i,s=()=>{if(o)return;if(o=!0,i)clearTimeout(i),i=null;let l=r,p=l.length,m=p;while(m--)if(l[m][0]===n){if(p===1)delete this.sessions[e];else l.splice(m,1);if(!n.closed)n.close();return}},a=n.request,{sessionTimeout:c}=t;if(c!=null){let l=0;n.request=function(){let p=a.apply(this,arguments);if(l++,i)clearTimeout(i),i=null;return p.once("close",()=>{if(!--l)i=setTimeout(()=>{i=null,s()},c)}),p}}n.once("close",s);let u=[n,t];return r?r.push(u):r=this.sessions[e]=[u],n}}var Gx=Vx;var aO=(e,t)=>f.isAsyncFn(e)?function(...r){let n=r.pop();e.apply(this,r).then((o)=>{try{t?n(null,...t(o)):n(null,o)}catch(i){n(i)}},n)}:e,Jx=aO;var cO=new Set(["localhost","0.0.0.0"]),Yx=(e)=>{let t=e.split(".");if(t.length!==4)return!1;if(t[0]!=="127")return!1;return t.every((r)=>/^\d+$/.test(r)&&Number(r)>=0&&Number(r)<=255)},Qu=(e)=>/^0{1,4}$/.test(e),uO=(e)=>{if(e==="::")return!0;let t=e.indexOf("::");if(t!==-1){if(t!==e.lastIndexOf("::"))return!1;let n=e.slice(0,t),o=e.slice(t+2),i=n?n.split(":"):[],s=o?o.split(":"):[];return i.length+s.length<8&&i.every(Qu)&&s.every(Qu)}let r=e.split(":");return r.length===8&&r.every(Qu)},lO=(e)=>{if(e==="::1")return!0;let t=e.match(/^::ffff:(\d+\.\d+\.\d+\.\d+)$/i);if(t)return Yx(t[1]);let r=e.match(/^::ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i);if(r){let o=parseInt(r[1],16);return o>=32512&&o<=32767}let n=e.split(":");if(n.length===8){for(let o=0;o<7;o++)if(!/^0+$/.test(n[o]))return!1;return/^0*1$/.test(n[7])}return!1},Wx=(e)=>{if(!e)return!1;if(cO.has(e))return!0;if(Yx(e))return!0;if(uO(e))return!0;return lO(e)},pO={http:80,https:443,ws:80,wss:443,ftp:21},dO=(e)=>{let t=e,r=0;if(t.charAt(0)==="["){let i=t.indexOf("]");if(i!==-1){let s=t.slice(1,i),a=t.slice(i+1);if(a.charAt(0)===":"&&/^\d+$/.test(a.slice(1)))r=Number.parseInt(a.slice(1),10);return[s,r]}}let n=t.indexOf(":"),o=t.lastIndexOf(":");if(n!==-1&&n===o&&/^\d+$/.test(t.slice(o+1)))r=Number.parseInt(t.slice(o+1),10),t=t.slice(0,o);return[t,r]},mO=/^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:(\d+\.\d+\.\d+\.\d+)$/i,fO=/^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i,hO=(e)=>{if(typeof e!=="string"||e.indexOf(":")===-1)return e;let t=e.match(mO);if(t)return t[1];let r=e.match(fO);if(r){let n=parseInt(r[1],16),o=parseInt(r[2],16);return`${n>>8}.${n&255}.${o>>8}.${o&255}`}return e},Kx=(e)=>{if(!e)return e;if(e.charAt(0)==="["&&e.charAt(e.length-1)==="]")e=e.slice(1,-1);return hO(e.replace(/\.+$/,""))};function el(e){let t;try{t=new URL(e)}catch(i){return!1}let r=(process.env.no_proxy||process.env.NO_PROXY||"").toLowerCase();if(!r)return!1;if(r==="*")return!0;let n=Number.parseInt(t.port,10)||pO[t.protocol.split(":",1)[0]]||0,o=Kx(t.hostname.toLowerCase());return r.split(/[\s,]+/).some((i)=>{if(!i)return!1;let[s,a]=dO(i);if(s=Kx(s),!s)return!1;if(a&&a!==n)return!1;if(s.charAt(0)==="*")s=s.slice(1);if(s.charAt(0)===".")return o.endsWith(s);return o===s||Wx(o)&&Wx(s)})}function gO(e,t){e=e||10;let r=Array(e),n=Array(e),o=0,i=0,s;return t=t!==void 0?t:1000,function(c){let u=Date.now(),l=n[i];if(!s)s=u;r[o]=c,n[o]=u;let p=i,m=0;while(p!==o)m+=r[p++],p=p%e;if(o=(o+1)%e,o===i)i=(i+1)%e;if(u-s<t)return;let d=l&&u-l;return d?Math.round(m*1000/d):void 0}}var Xx=gO;function xO(e,t){let r=0,n=1000/t,o,i,s=(u,l=Date.now())=>{if(r=l,o=null,i)clearTimeout(i),i=null;e(...u)};return[(...u)=>{let l=Date.now(),p=l-r;if(p>=n)s(u,l);else if(o=u,!i)i=setTimeout(()=>{i=null,s(o)},n-p)},()=>o&&s(o)]}var Qx=xO;var pr=(e,t,r=3)=>{let n=0,o=Xx(50,250);return Qx((i)=>{if(!i||typeof i.loaded!=="number")return;let s=i.loaded,a=i.lengthComputable?i.total:void 0,c=a!=null?Math.min(s,a):s,u=Math.max(0,c-n),l=o(u);n=Math.max(n,c);let p={loaded:c,total:a,progress:a?c/a:void 0,bytes:u,rate:l?l:void 0,estimated:l&&a?(a-c)/l:void 0,event:i,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(p)},r)},Hn=(e,t)=>{let r=e!=null;return[(n)=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},Vn=(e)=>(...t)=>f.asap(()=>e(...t));var Zs=(e)=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,vO=(e,t,r)=>t+2<r&&Zs(e.charCodeAt(t+1))&&Zs(e.charCodeAt(t+2));function ai(e){if(!e||typeof e!=="string")return 0;if(!e.startsWith("data:"))return 0;let t=e.indexOf(",");if(t<0)return 0;let r=e.slice(5,t),n=e.slice(t+1);if(/;base64/i.test(r)){let{length:s,length:a}=n;for(let d=0;d<a;d++)if(n.charCodeAt(d)===37&&d+2<a){let h=n.charCodeAt(d+1),x=n.charCodeAt(d+2);if(Zs(h)&&Zs(x))s-=2,d+=2}let c=0,u=a-1,l=(d)=>d>=2&&n.charCodeAt(d-2)===37&&n.charCodeAt(d-1)===51&&(n.charCodeAt(d)===68||n.charCodeAt(d)===100);if(u>=0){if(n.charCodeAt(u)===61)c++,u--;else if(l(u))c++,u-=3}if(c===1&&u>=0){if(n.charCodeAt(u)===61)c++;else if(l(u))c++}let m=Math.floor(s/4)*3-(c||0);return m>0?m:0}let i=0;for(let s=0,a=n.length;s<a;s++){let c=n.charCodeAt(s);if(c===37&&vO(n,s,a))i+=1,s+=2;else if(c<128)i+=1;else if(c<2048)i+=2;else if(c>=55296&&c<=56319&&s+1<a){let u=n.charCodeAt(s+1);if(u>=56320&&u<=57343)i+=4,s++;else i+=3}else i+=3}return i}var tv={flush:Ot.constants.Z_SYNC_FLUSH,finishFlush:Ot.constants.Z_SYNC_FLUSH},SO={flush:Ot.constants.BROTLI_OPERATION_FLUSH,finishFlush:Ot.constants.BROTLI_OPERATION_FLUSH},$O={flush:Ot.constants.ZSTD_e_flush,finishFlush:Ot.constants.ZSTD_e_flush},uv=f.isFunction(Ot.createBrotliDecompress),lv=f.isFunction(Ot.createZstdDecompress),pv="gzip, compress, deflate"+(uv?", br":""),TO=pv+(lv?", zstd":""),{http:EO,https:RO}=cv.default,dv=/https:?/,PO=["content-type","content-length"];function zO(e,t,r){if(r!=="content-only"){e.set(t);return}Object.entries(t).forEach(([n,o])=>{if(PO.includes(n.toLowerCase()))e.set(n,o)})}var rv=Symbol("axios.http.socketListener"),Bs=Symbol("axios.http.currentReq"),mv=Symbol("axios.http.installedTunnel"),OO=new Map,nv=new WeakMap;function AO(e,t){let r=e.protocol+"//"+e.hostname+":"+(e.port||"")+"#"+(e.auth||""),n=t?nv.get(t)||nv.set(t,new Map).get(t):OO,o=n.get(r);if(o)return o;let i=t&&t.options?{...t.options,...e}:e;if(o=new tl.default(i),t&&t.options){let s={...t.options},a=o.callback;o.callback=function(u,l){return a.call(this,u,{...s,...l})}}return o[mv]=!0,n.set(r,o),o}var ov=ue.protocols.map((e)=>e+":"),iv=(e)=>{if(!f.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},sv=(e,[t,r])=>(e.on("end",r).on("error",r),t),CO=new Gx;function IO(e,t,r){if(e.beforeRedirects.proxy)e.beforeRedirects.proxy(e);if(e.beforeRedirects.auth)e.beforeRedirects.auth(e);if(e.beforeRedirects.sensitiveHeaders)e.beforeRedirects.sensitiveHeaders(e,r);if(e.beforeRedirects.config)e.beforeRedirects.config(e,t,r)}function jO(e,t){if(!e)return;Object.keys(e).forEach((r)=>{if(t.has(r.toLowerCase()))delete e[r]})}function NO(e,t){if(!t)return!1;try{return new URL(t.url).origin===new URL(e.href).origin}catch(r){return!1}}function fv(e,t,r,n,o){let i=t;if(!i&&i!==!1){let s=sx(r);if(s){if(!el(r))i=new URL(s)}}if(n&&e.headers){for(let s of Object.keys(e.headers))if(s.toLowerCase()==="proxy-authorization")delete e.headers[s]}if(n&&e.agent&&e.agent[mv])e.agent=void 0;if(i){let s=i instanceof URL,a=(m)=>s||f.hasOwnProp(i,m)?i[m]:void 0,c=a("username"),u=a("password"),l=f.hasOwnProp(i,"auth")?i.auth:void 0;if(c)l=(c||"")+":"+(u||"");if(l){let m=typeof l==="object",d=m&&f.hasOwnProp(l,"username")?l.username:void 0,h=m&&f.hasOwnProp(l,"password")?l.password:void 0;if(Boolean(d||h))l=(d||"")+":"+(h||"");else if(m)throw new T("Invalid proxy authorization",T.ERR_BAD_OPTION,{proxy:i})}if(dv.test(e.protocol)){if(!(o instanceof tl.default)){let m=a("hostname")||a("host"),d=a("port"),h=a("protocol"),x=h?h.includes(":")?h:`${h}:`:"http:",y=m&&m.includes(":")&&!m.startsWith("[")?`[${m}]`:m,g=new URL(`${x}//${y}${d?":"+d:""}`),b={protocol:g.protocol,hostname:g.hostname.replace(/^\[|\]$/g,""),port:g.port,auth:l&&typeof l==="string"?l:void 0};if(g.protocol==="https:")b.ALPNProtocols=["http/1.1"];let k=AO(b,o);if(e.agent=k,e.agents)e.agents.https=k}}else{if(l){let x=Buffer.from(l,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+x}let m=!1;for(let x of Object.keys(e.headers))if(x.toLowerCase()==="host"){m=!0;break}if(!m)e.headers.host=e.hostname+(e.port?":"+e.port:"");let d=a("hostname")||a("host");e.hostname=d,e.host=d,e.port=a("port"),e.path=r;let h=a("protocol");if(h)e.protocol=h.includes(":")?h:`${h}:`}}e.beforeRedirects.proxy=function(a){fv(a,t,a.href,!0,o)}}var DO=typeof process<"u"&&f.kindOf(process)==="process",LO=(e)=>new Promise((t,r)=>{let n,o,i=(c,u)=>{if(o)return;o=!0,n&&n(c,u)},s=(c)=>{i(c),t(c)},a=(c)=>{i(c,!0),r(c)};e(s,a,(c)=>n=c).catch(a)}),MO=({address:e,family:t})=>{if(!f.isString(e))throw TypeError("address must be a string");return{address:e,family:t||(e.indexOf(".")<0?6:4)}},av=(e,t)=>MO(f.isObject(e)?e:{address:e,family:t}),qO={request(e,t){let r=e.protocol+"//"+e.hostname+":"+(e.port||(e.protocol==="https:"?443:80)),{http2Options:n,headers:o}=e,i=CO.getSession(r,n),{HTTP2_HEADER_SCHEME:s,HTTP2_HEADER_METHOD:a,HTTP2_HEADER_PATH:c,HTTP2_HEADER_STATUS:u}=_O.constants,l={[s]:e.protocol.replace(":",""),[a]:e.method,[c]:e.path};f.forEach(o,(m,d)=>{d.charAt(0)!==":"&&(l[d]=m)});let p=i.request(l);return p.once("response",(m)=>{let d=p;m=Object.assign({},m);let h=m[u];delete m[u],d.headers=m,d.statusCode=+h,t(d)}),p}},hv=DO&&function(t){return LO(async function(n,o,i){let s=(E)=>f.getSafeProp(t,E),a=s("transitional")||$r,c=s("data"),u=s("lookup"),l=s("family"),p=s("httpVersion");if(p===void 0)p=1;let m=s("http2Options"),d=s("responseType"),h=s("responseEncoding"),x=s("httpAgent"),y=s("httpsAgent"),g=s("method").toUpperCase(),b=s("maxRedirects"),k=s("maxBodyLength"),z=s("maxContentLength"),I=s("decompress"),H,me=!1,K,lt;if(p=+p,Number.isNaN(p))throw TypeError(`Invalid protocol version: '${t.httpVersion}' is not a number`);if(p!==1&&p!==2)throw TypeError(`Unsupported protocol version '${p}'`);let tt=p===2;if(u){let E=Jx(u,(A)=>f.isArray(A)?A:[A]);u=(A,G,pe)=>{E(A,G,(X,Le,Ce)=>{if(X)return pe(X);let Ne=f.isArray(Le)?Le.map((Pn)=>av(Pn)):[av(Le,Ce)];G.all?pe(X,Ne):pe(X,Ne[0].address,Ne[0].family)})}}let Ze=new kO;function Je(E){try{Ze.emit("abort",!E||E.type?new wt(null,t,K):E)}catch(A){}}function tr(){if(lt)clearTimeout(lt),lt=null}function pt(){let E=s("timeout"),A=E?"timeout of "+E+"ms exceeded":"timeout exceeded",G=s("timeoutErrorMessage");if(G)A=G;return new T(A,a.clarifyTimeoutError?T.ETIMEDOUT:T.ECONNABORTED,t,K)}Ze.once("abort",o);let br=()=>{if(tr(),t.cancelToken)t.cancelToken.unsubscribe(Je);if(t.signal)t.signal.removeEventListener("abort",Je);Ze.removeAllListeners()};if(t.cancelToken||t.signal){if(t.cancelToken&&t.cancelToken.subscribe(Je),t.signal)t.signal.aborted?Je():t.signal.addEventListener("abort",Je)}i((E,A)=>{if(H=!0,tr(),A){me=!0,br();return}let{data:G}=E;if(G instanceof qt.Readable||G instanceof qt.Duplex){let pe=qt.finished(G,()=>{pe(),br()})}else br()});let _r=rn(s("baseURL"),s("url"),s("allowAbsoluteUrls"),t),qe=new URL(_r,ue.hasBrowserEnv?ue.origin:void 0),Jr=qe.protocol||ov[0];if(Jr==="data:"){if(z>-1){let A=String(s("url")||_r||"");if(ai(A)>z)return o(new T("maxContentLength size of "+z+" exceeded",T.ERR_BAD_RESPONSE,t))}let E;if(g!=="GET")return nr(n,o,{status:405,statusText:"method not allowed",headers:{},config:t});try{E=Ku(s("url"),d==="blob",{Blob:t.env&&t.env.Blob})}catch(A){throw T.from(A,T.ERR_BAD_REQUEST,t)}if(d==="text"){if(E=E.toString(h),!h||h==="utf8")E=f.stripBOM(E)}else if(d==="stream")E=qt.Readable.from(E);return nr(n,o,{data:E,status:200,statusText:"OK",headers:new ye,config:t})}if(ov.indexOf(Jr)===-1)return o(new T("Unsupported protocol "+Jr,T.ERR_BAD_REQUEST,t));let rt=ye.from(t.headers).normalize();rt.set("User-Agent","axios/"+lr,!1);let{onUploadProgress:Et,onDownloadProgress:je}=t,Rt=t.maxRate,Dt=void 0,rr=void 0;if(f.isSpecCompliantForm(c)){let E=rt.getContentType(/boundary=([-_\w\d]{10,70})/i);c=Zx(c,(A)=>{rt.set(A)},{tag:`axios-${lr}-boundary`,boundary:E&&E[1]||void 0})}else if(f.isFormData(c)&&f.isFunction(c.getHeaders)&&c.getHeaders!==Object.prototype.getHeaders){if(zO(rt,c.getHeaders(),s("formDataHeaderPolicy")),!rt.hasContentLength())try{let E=await wO.promisify(c.getLength).call(c);Number.isFinite(E)&&E>=0&&rt.setContentLength(E)}catch(E){}}else if(f.isBlob(c)||f.isFile(c))c.size&&rt.setContentType(c.type||"application/octet-stream"),rt.setContentLength(c.size||0),c=qt.Readable.from(Fs(c));else if(c&&!f.isStream(c)){if(Buffer.isBuffer(c));else if(f.isArrayBuffer(c))c=Buffer.from(new Uint8Array(c));else if(f.isString(c))c=Buffer.from(c,"utf-8");else return o(new T("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",T.ERR_BAD_REQUEST,t));if(rt.setContentLength(c.length,!1),k>-1&&c.length>k)return o(new T("Request body larger than maxBodyLength limit",T.ERR_BAD_REQUEST,t))}let ys=f.toFiniteNumber(rt.getContentLength());if(f.isArray(Rt))Dt=Rt[0],rr=Rt[1];else Dt=rr=Rt;if(c&&(Et||Dt)){if(!f.isStream(c))c=qt.Readable.from(c,{objectMode:!1});c=qt.pipeline([c,new Xu({maxRate:f.toFiniteNumber(Dt)})],f.noop),Et&&c.on("progress",sv(c,Hn(ys,pr(Vn(Et),!1,3))))}let te=void 0,bt=s("auth");if(bt){let E=f.getSafeProp(bt,"username")||"",A=f.getSafeProp(bt,"password")||"";te=E+":"+A}if(!te&&(qe.username||qe.password)){let E=iv(qe.username),A=iv(qe.password);te=E+":"+A}te&&rt.delete("authorization");let Wr;try{Wr=tn(qe.pathname+qe.search,s("params"),s("paramsSerializer")).replace(/^\?/,"")}catch(E){let A=Error(E.message);return A.config=t,A.url=s("url"),A.exists=!0,o(A)}rt.set("Accept-Encoding",f.hasOwnProp(a,"advertiseZstdAcceptEncoding")&&a.advertiseZstdAcceptEncoding===!0?TO:pv,!1);let Ae=Object.assign(Object.create(null),{path:Wr,method:g,headers:In(rt),agents:{http:x,https:y},auth:te,protocol:Jr,family:l,beforeRedirect:IO,beforeRedirects:Object.create(null),http2Options:m});!f.isUndefined(u)&&(Ae.lookup=u);let Kr=s("socketPath");if(Kr){if(typeof Kr!=="string")return o(new T("socketPath must be a string",T.ERR_BAD_OPTION_VALUE,t));let E=s("allowedSocketPaths");if(E!=null){let A=Array.isArray(E)?E:[E],G=ev(Kr);if(!A.some((X)=>typeof X==="string"&&ev(X)===G))return o(new T(`socketPath "${Kr}" is not permitted by allowedSocketPaths`,T.ERR_BAD_OPTION_VALUE,t))}Ae.socketPath=Kr}else Ae.hostname=qe.hostname.startsWith("[")?qe.hostname.slice(1,-1):qe.hostname,Ae.port=qe.port,fv(Ae,s("proxy"),Jr+"//"+qe.hostname+(qe.port?":"+qe.port:"")+Ae.path,!1,y);let wr,Pt=!1,Co=!1,Yr=dv.test(Ae.protocol);if(Ae.agent==null)Ae.agent=Yr?y:x;if(tt)wr=qO;else{let E=s("transport");if(E)wr=E;else if(b===0)wr=Yr?bO:yO,Pt=!0;else{if(Co=!0,Ae.sensitiveHeaders=[],b)Ae.maxRedirects=b;let A=s("beforeRedirect");if(A)Ae.beforeRedirects.config=A;if(te){let pe=qe.origin,X=te;Ae.beforeRedirects.auth=function(Ce){try{if(new URL(Ce.href).origin===pe)Ce.auth=X}catch(Ne){}}}let G=s("sensitiveHeaders");if(G!=null){if(!f.isArray(G))return o(new T("sensitiveHeaders must be an array of strings",T.ERR_BAD_OPTION_VALUE,t));let pe=new Set;for(let X of G){if(!f.isString(X))return o(new T("sensitiveHeaders must be an array of strings",T.ERR_BAD_OPTION_VALUE,t));pe.add(X.toLowerCase())}if(pe.size)Ae.sensitiveHeaders=Array.from(pe),Ae.beforeRedirects.sensitiveHeaders=function(Le,Ce){if(!NO(Le,Ce))jO(Le.headers,pe)}}wr=Yr?RO:EO}}if(k>-1)Ae.maxBodyLength=k;else Ae.maxBodyLength=1/0;Ae.insecureHTTPParser=Boolean(s("insecureHTTPParser")),K=wr.request(Ae,function(A){if(tr(),K.destroyed)return;let G=[A],pe=f.toFiniteNumber(A.headers["content-length"]);if(je||rr){let Ne=new Xu({maxRate:f.toFiniteNumber(rr)});je&&Ne.on("progress",sv(Ne,Hn(pe,pr(Vn(je),!0,3)))),G.push(Ne)}let X=A,Le=A.req||K;if(I!==!1&&A.headers["content-encoding"]){if(g==="HEAD"||A.statusCode===204)delete A.headers["content-encoding"];switch((A.headers["content-encoding"]||"").toLowerCase()){case"gzip":case"x-gzip":case"compress":case"x-compress":G.push(Ot.createUnzip(tv)),delete A.headers["content-encoding"];break;case"deflate":G.push(new Hx),G.push(Ot.createUnzip(tv)),delete A.headers["content-encoding"];break;case"br":if(uv)G.push(Ot.createBrotliDecompress(SO)),delete A.headers["content-encoding"];break;case"zstd":if(lv)G.push(Ot.createZstdDecompress($O)),delete A.headers["content-encoding"];break}}X=G.length>1?qt.pipeline(G,f.noop):G[0];let Ce={status:A.statusCode,statusText:A.statusMessage,headers:new ye(A.headers),config:t,request:Le};if(d==="stream"){if(z>-1){let Ne=z,Pn=X;async function*Io(){let Be=0;for await(let Rf of Pn){if(Be+=Rf.length,Be>Ne)throw new T("maxContentLength size of "+Ne+" exceeded",T.ERR_BAD_RESPONSE,t,Le);yield Rf}}X=qt.Readable.from(Io(),{objectMode:!1})}Ce.data=X,nr(n,o,Ce)}else{let Ne=[],Pn=0;X.on("data",function(Be){if(Ne.push(Be),Pn+=Be.length,z>-1&&Pn>z)me=!0,X.destroy(),Je(new T("maxContentLength size of "+z+" exceeded",T.ERR_BAD_RESPONSE,t,Le))}),X.on("aborted",function(){if(me)return;let Be=new T("stream has been aborted",T.ERR_BAD_RESPONSE,t,Le,Ce);X.destroy(Be),o(Be)}),X.on("error",function(Be){if(me)return;o(T.from(Be,null,t,Le,Ce))}),X.on("end",function(){try{let Be=Ne.length===1?Ne[0]:Buffer.concat(Ne);if(d!=="arraybuffer"){if(Be=Be.toString(h),!h||h==="utf8")Be=f.stripBOM(Be)}Ce.data=Be}catch(Be){return o(T.from(Be,null,t,Ce.request,Ce))}nr(n,o,Ce)})}Ze.once("abort",(Ne)=>{if(!X.destroyed)X.emit("error",Ne),X.destroy()})}),Ze.once("abort",(E)=>{if(K.close)K.close();else K.destroy(E)}),K.on("error",function(A){o(T.from(A,null,t,K))});let _t=new Set;if(K.on("socket",function(A){if(A.setKeepAlive(!0,60000),!A[rv])A.on("error",function(pe){let X=A[Bs];if(X&&!X.destroyed)X.destroy(pe)}),A[rv]=!0;A[Bs]=K,_t.add(A)}),K.once("close",function(){tr();for(let A of _t)if(A[Bs]===K)A[Bs]=null;_t.clear()}),s("timeout")){let E=parseInt(s("timeout"),10);if(Number.isNaN(E)){Je(new T("error trying to parse `config.timeout` to int",T.ERR_BAD_OPTION_VALUE,t,K));return}let A=function(){if(H)return;Je(pt())};if(Pt&&E>0)lt=setTimeout(A,E);K.setTimeout(E,A)}else K.setTimeout(0);if(f.isStream(c)){let E=!1,A=!1;c.on("end",()=>{E=!0}),c.once("error",(pe)=>{A=!0,K.destroy(pe)}),c.on("close",()=>{if(!E&&!A)Je(new wt("Request stream has been aborted",t,K))});let G=c;if(k>-1&&!Co){let pe=k,X=0;G=qt.pipeline([c,new qt.Transform({transform(Le,Ce,Ne){if(X+=Le.length,X>pe)return Ne(new T("Request body larger than maxBodyLength limit",T.ERR_BAD_REQUEST,t,K));Ne(null,Le)}})],f.noop),G.on("error",(Le)=>{if(!K.destroyed)K.destroy(Le)})}G.pipe(K)}else c&&K.write(c),K.end()})};var gv=ue.hasStandardBrowserEnv?((e,t)=>(r)=>(r=new URL(r,ue.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(ue.origin),ue.navigator&&/(msie|trident)/i.test(ue.navigator.userAgent)):()=>!0;var xv=ue.hasStandardBrowserEnv?{write(e,t,r,n,o,i,s){if(typeof document>"u")return;let a=[`${e}=${encodeURIComponent(t)}`];if(f.isNumber(r))a.push(`expires=${new Date(r).toUTCString()}`);if(f.isString(n))a.push(`path=${n}`);if(f.isString(o))a.push(`domain=${o}`);if(i===!0)a.push("secure");if(f.isString(s))a.push(`SameSite=${s}`);document.cookie=a.join("; ")},read(e){if(typeof document>"u")return null;let t=document.cookie.split(";");for(let r=0;r<t.length;r++){let n=t[r].replace(/^\s+/,""),o=n.indexOf("=");if(o!==-1&&n.slice(0,o)===e)return decodeURIComponent(n.slice(o+1))}return null},remove(e){this.write(e,"",Date.now()-86400000,"/")}}:{write(){},read(){return null},remove(){}};var vv=(e)=>e instanceof ye?{...e}:e;function Ut(e,t){t=t||{};let r=Object.create(null);Object.defineProperty(r,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function n(l,p,m,d){if(f.isPlainObject(l)&&f.isPlainObject(p))return f.merge.call({caseless:d},l,p);else if(f.isPlainObject(p))return f.merge({},p);else if(f.isArray(p))return p.slice();return p}function o(l,p,m,d){if(!f.isUndefined(p))return n(l,p,m,d);else if(!f.isUndefined(l))return n(void 0,l,m,d)}function i(l,p){if(!f.isUndefined(p))return n(void 0,p)}function s(l,p){if(!f.isUndefined(p))return n(void 0,p);else if(!f.isUndefined(l))return n(void 0,l)}function a(l){let p=f.hasOwnProp(t,"transitional")?t.transitional:void 0;if(!f.isUndefined(p))if(f.isPlainObject(p)){if(f.hasOwnProp(p,l))return p[l]}else return;let m=f.hasOwnProp(e,"transitional")?e.transitional:void 0;if(f.isPlainObject(m)&&f.hasOwnProp(m,l))return m[l];return}function c(l,p,m){if(f.hasOwnProp(t,m))return n(l,p);else if(f.hasOwnProp(e,m))return n(void 0,l)}let u={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,allowedSocketPaths:s,responseEncoding:s,validateStatus:c,headers:(l,p,m)=>o(vv(l),vv(p),m,!0)};if(f.forEach(Object.keys({...e,...t}),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;let m=f.hasOwnProp(u,p)?u[p]:o,d=f.hasOwnProp(e,p)?e[p]:void 0,h=f.hasOwnProp(t,p)?t[p]:void 0,x=m(d,h,p);f.isUndefined(x)&&m!==c||(r[p]=x)}),f.hasOwnProp(t,"validateStatus")&&f.isUndefined(t.validateStatus)&&a("validateStatusUndefinedResolves")===!1)if(f.hasOwnProp(e,"validateStatus"))r.validateStatus=n(void 0,e.validateStatus);else delete r.validateStatus;return r}var UO=["content-type","content-length"];function FO(e,t,r){if(r!=="content-only"){e.set(t);return}Object.entries(t).forEach(([n,o])=>{if(UO.includes(n.toLowerCase()))e.set(n,o)})}var ZO=(e)=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,r)=>String.fromCharCode(parseInt(r,16)));function BO(e){let t=Ut({},e),r=(m)=>f.hasOwnProp(t,m)?t[m]:void 0,n=r("data"),o=r("withXSRFToken"),i=r("xsrfHeaderName"),s=r("xsrfCookieName"),a=r("headers"),c=r("auth"),u=r("baseURL"),l=r("allowAbsoluteUrls"),p=r("url");if(t.headers=a=ye.from(a),t.url=tn(rn(u,p,l,t),r("params"),r("paramsSerializer")),c){let m=f.getSafeProp(c,"username")||"",d=f.getSafeProp(c,"password")||"";a.set("Authorization","Basic "+btoa(m+":"+(d?ZO(d):"")))}if(f.isFormData(n)){if(ue.hasStandardBrowserEnv||ue.hasStandardBrowserWebWorkerEnv||f.isReactNative(n))a.setContentType(void 0);else if(f.isFunction(n.getHeaders))FO(a,n.getHeaders(),r("formDataHeaderPolicy"))}if(ue.hasStandardBrowserEnv){if(f.isFunction(o))o=o(t);if(o===!0||o==null&&gv(t.url)){let d=i&&s&&xv.read(s);if(d)a.set(i,d)}}return t}var Hs=BO;var HO=typeof XMLHttpRequest<"u",yv=HO&&function(e){return new Promise(function(r,n){let o=Hs(e),i=o.data,s=ye.from(o.headers).normalize(),{responseType:a,onUploadProgress:c,onDownloadProgress:u}=o,l,p,m,d,h;function x(){d&&d(),h&&h(),o.cancelToken&&o.cancelToken.unsubscribe(l),o.signal&&o.signal.removeEventListener("abort",l)}let y=new XMLHttpRequest;y.open(o.method.toUpperCase(),o.url,!0),y.timeout=o.timeout;function g(){if(!y)return;let k=ye.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),I={data:!a||a==="text"||a==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:k,config:e,request:y};nr(function(me){r(me),x()},function(me){n(me),x()},I),y=null}if("onloadend"in y)y.onloadend=g;else y.onreadystatechange=function(){if(!y||y.readyState!==4)return;if(y.status===0&&!(y.responseURL&&y.responseURL.startsWith("file:")))return;setTimeout(g)};if(y.onabort=function(){if(!y)return;n(new T("Request aborted",T.ECONNABORTED,e,y)),x(),y=null},y.onerror=function(z){let I=z&&z.message?z.message:"Network Error",H=new T(I,T.ERR_NETWORK,e,y);H.event=z||null,n(H),x(),y=null},y.ontimeout=function(){let z=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded",I=o.transitional||$r;if(o.timeoutErrorMessage)z=o.timeoutErrorMessage;n(new T(z,I.clarifyTimeoutError?T.ETIMEDOUT:T.ECONNABORTED,e,y)),x(),y=null},i===void 0&&s.setContentType(null),"setRequestHeader"in y)f.forEach(In(s),function(z,I){y.setRequestHeader(I,z)});if(!f.isUndefined(o.withCredentials))y.withCredentials=!!o.withCredentials;if(a&&a!=="json")y.responseType=o.responseType;if(u)[m,h]=pr(u,!0),y.addEventListener("progress",m);if(c&&y.upload)[p,d]=pr(c),y.upload.addEventListener("progress",p),y.upload.addEventListener("loadend",d);if(o.cancelToken||o.signal){if(l=(k)=>{if(!y)return;n(!k||k.type?new wt(null,e,y):k),y.abort(),x(),y=null},o.cancelToken&&o.cancelToken.subscribe(l),o.signal)o.signal.aborted?l():o.signal.addEventListener("abort",l)}let b=ii(o.url);if(b&&!ue.protocols.includes(b)){n(new T("Unsupported protocol "+b+":",T.ERR_BAD_REQUEST,e));return}y.send(i||null)})};var VO=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;let r=new AbortController,n=!1,o=function(c){if(!n){n=!0,s();let u=c instanceof Error?c:this.reason;r.abort(u instanceof T?u:new wt(u instanceof Error?u.message:u))}},i=t&&setTimeout(()=>{i=null,o(new T(`timeout of ${t}ms exceeded`,T.ETIMEDOUT))},t),s=()=>{if(!e)return;i&&clearTimeout(i),i=null,e.forEach((c)=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null};e.forEach((c)=>c.addEventListener("abort",o));let{signal:a}=r;return a.unsubscribe=()=>f.asap(s),a},bv=VO;var GO=function*(e,t){let r=e.byteLength;if(!t||r<t){yield e;return}let n=0,o;while(n<r)o=n+t,yield e.slice(n,o),n=o},JO=async function*(e,t){for await(let r of WO(e))yield*GO(r,t)},WO=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}let t=e.getReader();try{for(;;){let{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},rl=(e,t,r,n)=>{let o=JO(e,t),i=0,s,a=(c)=>{if(!s)s=!0,n&&n(c)};return new ReadableStream({async pull(c){try{let{done:u,value:l}=await o.next();if(u){a(),c.close();return}let p=l.byteLength;if(r){let m=i+=p;r(m)}c.enqueue(new Uint8Array(l))}catch(u){throw a(u),u}},cancel(c){return a(c),o.return()}},{highWaterMark:2})};var _v=65536,{isFunction:Vs}=f,KO=(e)=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,r)=>String.fromCharCode(parseInt(r,16))),wv=(e)=>{if(!f.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},kv=(e,...t)=>{try{return!!e(...t)}catch(r){return!1}},YO=(e)=>{let t=e.indexOf("://"),r=e;if(t!==-1)r=r.slice(t+3);return r.includes("@")||r.includes(":")},XO=(e)=>{let t=f.global!==void 0&&f.global!==null?f.global:globalThis,{ReadableStream:r,TextEncoder:n}=t;e=f.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);let{fetch:o,Request:i,Response:s}=e,a=o?Vs(o):typeof fetch==="function",c=Vs(i),u=Vs(s);if(!a)return!1;let l=a&&Vs(r),p=a&&(typeof n==="function"?((g)=>(b)=>g.encode(b))(new n):async(g)=>new Uint8Array(await new i(g).arrayBuffer())),m=c&&l&&kv(()=>{let g=!1,b=new i(ue.origin,{body:new r,method:"POST",get duplex(){return g=!0,"half"}}),k=b.headers.has("Content-Type");if(b.body!=null)b.body.cancel();return g&&!k}),d=u&&l&&kv(()=>f.isReadableStream(new s("").body)),h={stream:d&&((g)=>g.body)};a&&(()=>{["text","arrayBuffer","blob","formData","stream"].forEach((g)=>{!h[g]&&(h[g]=(b,k)=>{let z=b&&b[g];if(z)return z.call(b);throw new T(`Response type '${g}' is not supported`,T.ERR_NOT_SUPPORT,k)})})})();let x=async(g)=>{if(g==null)return 0;if(f.isBlob(g))return g.size;if(f.isSpecCompliantForm(g))return(await new i(ue.origin,{method:"POST",body:g}).arrayBuffer()).byteLength;if(f.isArrayBufferView(g)||f.isArrayBuffer(g))return g.byteLength;if(f.isURLSearchParams(g))g=g+"";if(f.isString(g))return(await p(g)).byteLength},y=async(g,b)=>{let k=f.toFiniteNumber(g.getContentLength());return k==null?x(b):k};return async(g)=>{let{url:b,method:k,data:z,signal:I,cancelToken:H,timeout:me,onDownloadProgress:K,onUploadProgress:lt,responseType:tt,headers:Ze,withCredentials:Je="same-origin",fetchOptions:tr,maxContentLength:pt,maxBodyLength:br}=Hs(g),_r=f.isNumber(pt)&&pt>-1,qe=f.isNumber(br)&&br>-1,Jr=(te)=>f.hasOwnProp(g,te)?g[te]:void 0,rt=o||fetch;tt=tt?(tt+"").toLowerCase():"text";let Et=bv([I,H&&H.toAbortSignal()],me),je=null,Rt=Et&&Et.unsubscribe&&(()=>{Et.unsubscribe()}),Dt,rr=null,ys=()=>new T("Request body larger than maxBodyLength limit",T.ERR_BAD_REQUEST,g,je);try{let te=void 0,bt=Jr("auth");if(bt){let E=f.getSafeProp(bt,"username")||"",A=f.getSafeProp(bt,"password")||"";te={username:E,password:A}}if(YO(b)){let E=new URL(b,ue.origin);if(!te&&(E.username||E.password)){let A=wv(E.username),G=wv(E.password);te={username:A,password:G}}if(E.username||E.password)E.username="",E.password="",b=E.href}if(te)Ze.delete("authorization"),Ze.set("Authorization","Basic "+btoa(KO((te.username||"")+":"+(te.password||""))));if(_r&&typeof b==="string"&&b.startsWith("data:")){if(ai(b)>pt)throw new T("maxContentLength size of "+pt+" exceeded",T.ERR_BAD_RESPONSE,g,je)}if(qe&&k!=="get"&&k!=="head"){let E=await x(z);if(typeof E==="number"&&isFinite(E)){if(Dt=E,E>br)throw ys()}}let Wr=qe&&(f.isReadableStream(z)||f.isStream(z)),Ae=(E,A,G)=>rl(E,_v,(pe)=>{if(qe&&pe>br)throw rr=ys();A&&A(pe)},G);if(m&&k!=="get"&&k!=="head"&&(lt||Wr)){if(Dt=Dt==null?await y(Ze,z):Dt,Dt!==0||Wr){let E=new i(b,{method:"POST",body:z,duplex:"half"}),A;if(f.isFormData(z)&&(A=E.headers.get("content-type")))Ze.setContentType(A);if(E.body){let[G,pe]=lt&&Hn(Dt,pr(Vn(lt)))||[];z=Ae(E.body,G,pe)}}}else if(Wr&&!c&&l&&k!=="get"&&k!=="head")z=Ae(z);else if(Wr&&c&&!m&&k!=="get"&&k!=="head")throw new T("Stream request bodies are not supported by the current fetch implementation",T.ERR_NOT_SUPPORT,g,je);if(!f.isString(Je))Je=Je?"include":"omit";let Kr=c&&"credentials"in i.prototype;if(f.isFormData(z)){let E=Ze.getContentType();if(E&&/^multipart\/form-data/i.test(E)&&!/boundary=/i.test(E))Ze.delete("content-type")}Ze.set("User-Agent","axios/"+lr,!1);let wr={...tr,signal:Et,method:k.toUpperCase(),headers:In(Ze.normalize()),body:z,duplex:"half",credentials:Kr?Je:void 0};je=c&&new i(b,wr);let Pt=await(c?rt(je,tr):rt(b,wr)),Co=ye.from(Pt.headers);if(_r){let E=f.toFiniteNumber(Co.getContentLength());if(E!=null&&E>pt)throw new T("maxContentLength size of "+pt+" exceeded",T.ERR_BAD_RESPONSE,g,je)}let Yr=d&&(tt==="stream"||tt==="response");if(d&&Pt.body&&(K||_r||Yr&&Rt)){let E={};["status","statusText","headers"].forEach((Ce)=>{E[Ce]=Pt[Ce]});let A=f.toFiniteNumber(Co.getContentLength()),[G,pe]=K&&Hn(A,pr(Vn(K),!0))||[],X=0,Le=(Ce)=>{if(_r){if(X=Ce,X>pt)throw new T("maxContentLength size of "+pt+" exceeded",T.ERR_BAD_RESPONSE,g,je)}G&&G(Ce)};Pt=new s(rl(Pt.body,_v,Le,()=>{pe&&pe(),Rt&&Rt()}),E)}tt=tt||"text";let _t=await h[f.findKey(h,tt)||"text"](Pt,g);if(_r&&!d&&!Yr){let E;if(_t!=null){if(typeof _t.byteLength==="number")E=_t.byteLength;else if(typeof _t.size==="number")E=_t.size;else if(typeof _t==="string")E=typeof n==="function"?new n().encode(_t).byteLength:_t.length}if(typeof E==="number"&&E>pt)throw new T("maxContentLength size of "+pt+" exceeded",T.ERR_BAD_RESPONSE,g,je)}return!Yr&&Rt&&Rt(),await new Promise((E,A)=>{nr(E,A,{data:_t,headers:ye.from(Pt.headers),status:Pt.status,statusText:Pt.statusText,config:g,request:je})})}catch(te){if(Rt&&Rt(),Et&&Et.aborted&&Et.reason instanceof T){let bt=Et.reason;throw bt.config=g,je&&(bt.request=je),te!==bt&&(bt.cause=te),bt}if(rr)throw je&&!rr.request&&(rr.request=je),rr;if(te instanceof T)throw je&&!te.request&&(te.request=je),te;if(te&&te.name==="TypeError"&&/Load failed|fetch/i.test(te.message))throw Object.assign(new T("Network Error",T.ERR_NETWORK,g,je,te&&te.response),{cause:te.cause||te});throw T.from(te,te&&te.code,g,je,te&&te.response)}}},QO=new Map,nl=(e)=>{let t=e&&e.env||{},{fetch:r,Request:n,Response:o}=t,i=[n,o,r],s=i.length,a=s,c,u,l=QO;while(a--)c=i[a],u=l.get(c),u===void 0&&l.set(c,u=a?new Map:XO(t)),l=u;return u},aH=nl();var ol={http:hv,xhr:yv,fetch:{get:nl}};f.forEach(ol,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(r){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});var Sv=(e)=>`- ${e}`,tA=(e)=>f.isFunction(e)||e===null||e===!1;function rA(e,t){e=f.isArray(e)?e:[e];let{length:r}=e,n,o,i={};for(let s=0;s<r;s++){n=e[s];let a;if(o=n,!tA(n)){if(o=ol[(a=String(n)).toLowerCase()],o===void 0)throw new T(`Unknown adapter '${a}'`)}if(o&&(f.isFunction(o)||(o=o.get(t))))break;i[a||"#"+s]=o}if(!o){let s=Object.entries(i).map(([c,u])=>`adapter ${c} `+(u===!1?"is not supported by the environment":"is not available in the build")),a=r?s.length>1?`since :
|
|
30
|
-
`+s.map(
|
|
31
|
-
`):" "+
|
|
26
|
+
deps: ${r}}`};var y2={keyword:"dependencies",type:"object",schemaType:"object",error:Pk.error,code(e){let[t,r]=b2(e);Ek(e,t),Rk(e,r)}};function b2({schema:e}){let t={},r={};for(let n in e){if(n==="__proto__")continue;let o=Array.isArray(e[n])?t:r;o[n]=e[n]}return[t,r]}function Ek(e,t=e.schema){let{gen:r,data:n,it:o}=e;if(Object.keys(t).length===0)return;let i=r.let("missing");for(let s in t){let a=t[s];if(a.length===0)continue;let c=es.propertyInData(r,n,s,o.opts.ownProperties);if(e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),o.allErrors)r.if(c,()=>{for(let u of a)es.checkReportMissingProp(e,u)});else r.if(Em._`${c} && (${es.checkMissingProp(e,a,i)})`),es.reportMissingProp(e,i),r.else()}}Pk.validatePropertyDeps=Ek;function Rk(e,t=e.schema){let{gen:r,data:n,keyword:o,it:i}=e,s=r.name("valid");for(let a in t){if(v2.alwaysValidSchema(i,t[a]))continue;r.if(es.propertyInData(r,n,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:o,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s)}}Pk.validateSchemaDeps=Rk;Pk.default=y2});var jk=b(function(Ik){Object.defineProperty(Ik,"__esModule",{value:!0});var Ck=W(),k2=se(),S2={message:"property name must be valid",params:({params:e})=>Ck._`{propertyName: ${e.propertyName}}`},$2={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:S2,code(e){let{gen:t,schema:r,data:n,it:o}=e;if(k2.alwaysValidSchema(o,r))return;let i=t.name("valid");t.forIn("key",n,(s)=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if(Ck.not(i),()=>{if(e.error(!0),!o.allErrors)t.break()})}),e.ok(i)}};Ik.default=$2});var Rm=b(function(Nk){Object.defineProperty(Nk,"__esModule",{value:!0});var yc=Lt(),Qt=W(),E2=yr(),bc=se(),R2={message:"must NOT have additional properties",params:({params:e})=>Qt._`{additionalProperty: ${e.additionalProperty}}`},P2={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:R2,code(e){let{gen:t,schema:r,parentSchema:n,data:o,errsCount:i,it:s}=e;if(!i)throw Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&bc.alwaysValidSchema(s,r))return;let u=yc.allSchemaProperties(n.properties),l=yc.allSchemaProperties(n.patternProperties);p(),e.ok(Qt._`${i} === ${E2.default.errors}`);function p(){t.forIn("key",o,(v)=>{if(!u.length&&!l.length)h(v);else t.if(m(v),()=>h(v))})}function m(v){let g;if(u.length>8){let y=bc.schemaRefOrVal(s,n.properties,"properties");g=yc.isOwnProperty(t,y,v)}else if(u.length)g=Qt.or(...u.map((y)=>Qt._`${v} === ${y}`));else g=Qt.nil;if(l.length)g=Qt.or(g,...l.map((y)=>Qt._`${yc.usePattern(e,y)}.test(${v})`));return Qt.not(g)}function d(v){t.code(Qt._`delete ${o}[${v}]`)}function h(v){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){d(v);return}if(r===!1){if(e.setParams({additionalProperty:v}),e.error(),!a)t.break();return}if(typeof r=="object"&&!bc.alwaysValidSchema(s,r)){let g=t.name("valid");if(c.removeAdditional==="failing")x(v,g,!1),t.if(Qt.not(g),()=>{e.reset(),d(v)});else if(x(v,g),!a)t.if(Qt.not(g),()=>t.break())}}function x(v,g,y){let w={keyword:"additionalProperties",dataProp:v,dataPropType:bc.Type.Str};if(y===!1)Object.assign(w,{compositeRule:!0,createErrors:!1,allErrors:!1});e.subschema(w,g)}}};Nk.default=P2});var qk=b(function(Lk){Object.defineProperty(Lk,"__esModule",{value:!0});var O2=Fi(),Mk=Lt(),Pm=se(),Dk=Rm(),A2={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:n,data:o,it:i}=e;if(i.opts.removeAdditional==="all"&&n.additionalProperties===void 0)Dk.default.code(new O2.KeywordCxt(i,Dk.default,"additionalProperties"));let s=Mk.allSchemaProperties(r);for(let p of s)i.definedProperties.add(p);if(i.opts.unevaluated&&s.length&&i.props!==!0)i.props=Pm.mergeEvaluated.props(t,Pm.toHash(s),i.props);let a=s.filter((p)=>!Pm.alwaysValidSchema(i,r[p]));if(a.length===0)return;let c=t.name("valid");for(let p of a){if(u(p))l(p);else{if(t.if(Mk.propertyInData(t,o,p,i.opts.ownProperties)),l(p),!i.allErrors)t.else().var(c,!0);t.endIf()}e.it.definedProperties.add(p),e.ok(c)}function u(p){return i.opts.useDefaults&&!i.compositeRule&&r[p].default!==void 0}function l(p){e.subschema({keyword:"properties",schemaProp:p,dataProp:p},c)}}};Lk.default=A2});var Hk=b(function(Bk){Object.defineProperty(Bk,"__esModule",{value:!0});var Uk=Lt(),_c=W(),Fk=se(),Zk=se(),I2={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:n,parentSchema:o,it:i}=e,{opts:s}=i,a=Uk.allSchemaProperties(r),c=a.filter((x)=>Fk.alwaysValidSchema(i,r[x]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&o.properties,l=t.name("valid");if(i.props!==!0&&!(i.props instanceof _c.Name))i.props=Zk.evaluatedPropsToName(t,i.props);let{props:p}=i;m();function m(){for(let x of a){if(u)d(x);if(i.allErrors)h(x);else t.var(l,!0),h(x),t.if(l)}}function d(x){for(let v in u)if(new RegExp(x).test(v))Fk.checkStrictMode(i,`property ${v} matches pattern ${x} (use allowMatchingProperties)`)}function h(x){t.forIn("key",n,(v)=>{t.if(_c._`${Uk.usePattern(e,x)}.test(${v})`,()=>{let g=c.includes(x);if(!g)e.subschema({keyword:"patternProperties",schemaProp:x,dataProp:v,dataPropType:Zk.Type.Str},l);if(i.opts.unevaluated&&p!==!0)t.assign(_c._`${p}[${v}]`,!0);else if(!g&&!i.allErrors)t.if(_c.not(l),()=>t.break())})})}}};Bk.default=I2});var Gk=b(function(Vk){Object.defineProperty(Vk,"__esModule",{value:!0});var N2=se(),D2={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:n}=e;if(N2.alwaysValidSchema(n,r)){e.fail();return}let o=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},o),e.failResult(o,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};Vk.default=D2});var Wk=b(function(Jk){Object.defineProperty(Jk,"__esModule",{value:!0});var L2=Lt(),q2={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:L2.validateUnion,error:{message:"must match a schema in anyOf"}};Jk.default=q2});var Yk=b(function(Kk){Object.defineProperty(Kk,"__esModule",{value:!0});var wc=W(),F2=se(),Z2={message:"must match exactly one schema in oneOf",params:({params:e})=>wc._`{passingSchemas: ${e.passing}}`},B2={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:Z2,code(e){let{gen:t,schema:r,parentSchema:n,it:o}=e;if(!Array.isArray(r))throw Error("ajv implementation error");if(o.opts.discriminator&&n.discriminator)return;let i=r,s=t.let("valid",!1),a=t.let("passing",null),c=t.name("_valid");e.setParams({passing:a}),t.block(u),e.result(s,()=>e.reset(),()=>e.error(!0));function u(){i.forEach((l,p)=>{let m;if(F2.alwaysValidSchema(o,l))t.var(c,!0);else m=e.subschema({keyword:"oneOf",schemaProp:p,compositeRule:!0},c);if(p>0)t.if(wc._`${c} && ${s}`).assign(s,!1).assign(a,wc._`[${a}, ${p}]`).else();t.if(c,()=>{if(t.assign(s,!0),t.assign(a,p),m)e.mergeEvaluated(m,wc.Name)})})}}};Kk.default=B2});var Qk=b(function(Xk){Object.defineProperty(Xk,"__esModule",{value:!0});var V2=se(),G2={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:n}=e;if(!Array.isArray(r))throw Error("ajv implementation error");let o=t.name("valid");r.forEach((i,s)=>{if(V2.alwaysValidSchema(n,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},o);e.ok(o),e.mergeEvaluated(a)})}};Xk.default=G2});var nS=b(function(rS){Object.defineProperty(rS,"__esModule",{value:!0});var kc=W(),tS=se(),W2={message:({params:e})=>kc.str`must match "${e.ifClause}" schema`,params:({params:e})=>kc._`{failingKeyword: ${e.ifClause}}`},K2={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:W2,code(e){let{gen:t,parentSchema:r,it:n}=e;if(r.then===void 0&&r.else===void 0)tS.checkStrictMode(n,'"if" without "then" and "else" is ignored');let o=eS(n,"then"),i=eS(n,"else");if(!o&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),o&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else if(o)t.if(a,u("then"));else t.if(kc.not(a),u("else"));e.pass(s,()=>e.error(!0));function c(){let l=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},a);e.mergeEvaluated(l)}function u(l,p){return()=>{let m=e.subschema({keyword:l},a);if(t.assign(s,a),e.mergeValidEvaluated(m,s),p)t.assign(p,kc._`${l}`);else e.setParams({ifClause:l})}}}};function eS(e,t){let r=e.schema[t];return r!==void 0&&!tS.alwaysValidSchema(e,r)}rS.default=K2});var iS=b(function(oS){Object.defineProperty(oS,"__esModule",{value:!0});var X2=se(),Q2={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){if(t.if===void 0)X2.checkStrictMode(r,`"${e}" without "if" is ignored`)}};oS.default=Q2});var aS=b(function(sS){Object.defineProperty(sS,"__esModule",{value:!0});var tU=$m(),rU=_k(),nU=Tm(),oU=Sk(),iU=Tk(),sU=Ak(),aU=jk(),cU=Rm(),uU=qk(),lU=Hk(),pU=Gk(),dU=Wk(),mU=Yk(),fU=Qk(),hU=nS(),gU=iS();function xU(e=!1){let t=[pU.default,dU.default,mU.default,fU.default,hU.default,gU.default,aU.default,cU.default,sU.default,uU.default,lU.default];if(e)t.push(rU.default,oU.default);else t.push(tU.default,nU.default);return t.push(iU.default),t}sS.default=xU});var uS=b(function(cS){Object.defineProperty(cS,"__esModule",{value:!0});var Le=W(),yU={message:({schemaCode:e})=>Le.str`must match format "${e}"`,params:({schemaCode:e})=>Le._`{format: ${e}}`},bU={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:yU,code(e,t){let{gen:r,data:n,$data:o,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:p}=a;if(!c.validateFormats)return;if(o)m();else d();function m(){let h=r.scopeValue("formats",{ref:p.formats,code:c.code.formats}),x=r.const("fDef",Le._`${h}[${s}]`),v=r.let("fType"),g=r.let("format");r.if(Le._`typeof ${x} == "object" && !(${x} instanceof RegExp)`,()=>r.assign(v,Le._`${x}.type || "string"`).assign(g,Le._`${x}.validate`),()=>r.assign(v,Le._`"string"`).assign(g,x)),e.fail$data(Le.or(y(),w()));function y(){if(c.strictSchema===!1)return Le.nil;return Le._`${s} && !${g}`}function w(){let P=l.$async?Le._`(${x}.async ? await ${g}(${n}) : ${g}(${n}))`:Le._`${g}(${n})`,I=Le._`(typeof ${g} == "function" ? ${P} : ${g}.test(${n}))`;return Le._`${g} && ${g} !== true && ${v} === ${t} && !${I}`}}function d(){let h=p.formats[i];if(!h){y();return}if(h===!0)return;let[x,v,g]=w(h);if(x===t)e.pass(P());function y(){if(c.strictSchema===!1){p.logger.warn(I());return}throw Error(I());function I(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function w(I){let H=I instanceof RegExp?Le.regexpCode(I):c.code.formats?Le._`${c.code.formats}${Le.getProperty(i)}`:void 0,me=r.scopeValue("formats",{key:i,ref:I,code:H});if(typeof I=="object"&&!(I instanceof RegExp))return[I.type||"string",I.validate,Le._`${me}.validate`];return["string",I,me]}function P(){if(typeof h=="object"&&!(h instanceof RegExp)&&h.async){if(!l.$async)throw Error("async format in sync schema");return Le._`await ${g}(${n})`}return typeof v=="function"?Le._`${g}(${n})`:Le._`${g}.test(${n})`}}}};cS.default=bU});var pS=b(function(lS){Object.defineProperty(lS,"__esModule",{value:!0});var wU=uS(),kU=[wU.default];lS.default=kU});var fS=b(function(dS){Object.defineProperty(dS,"__esModule",{value:!0});dS.contentVocabulary=dS.metadataVocabulary=void 0;dS.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];dS.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var xS=b(function(gS){Object.defineProperty(gS,"__esModule",{value:!0});var TU=L0(),EU=dk(),RU=aS(),PU=pS(),hS=fS(),zU=[TU.default,EU.default,(0,RU.default)(),PU.default,hS.metadataVocabulary,hS.contentVocabulary];gS.default=zU});var _S=b(function(yS){Object.defineProperty(yS,"__esModule",{value:!0});yS.DiscrError=void 0;var vS;(function(e){e.Tag="tag",e.Mapping="mapping"})(vS||(yS.DiscrError=vS={}))});var SS=b(function(kS){Object.defineProperty(kS,"__esModule",{value:!0});var go=W(),zm=_S(),wS=sc(),AU=Zi(),CU=se(),IU={message:({params:{discrError:e,tagName:t}})=>e===zm.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>go._`{error: ${e}, tag: ${r}, tagValue: ${t}}`},jU={keyword:"discriminator",type:"object",schemaType:"object",error:IU,code(e){let{gen:t,data:r,schema:n,parentSchema:o,it:i}=e,{oneOf:s}=o;if(!i.opts.discriminator)throw Error("discriminator: requires discriminator option");let a=n.propertyName;if(typeof a!="string")throw Error("discriminator: requires propertyName");if(n.mapping)throw Error("discriminator: mapping is not supported");if(!s)throw Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",go._`${r}${go.getProperty(a)}`);t.if(go._`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:zm.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let d=m();t.if(!1);for(let h in d)t.elseIf(go._`${u} === ${h}`),t.assign(c,p(d[h]));t.else(),e.error(!1,{discrError:zm.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function p(d){let h=t.name("valid"),x=e.subschema({keyword:"oneOf",schemaProp:d},h);return e.mergeEvaluated(x,go.Name),h}function m(){var d;let h={},x=g(o),v=!0;for(let P=0;P<s.length;P++){let I=s[P];if((I===null||I===void 0?void 0:I.$ref)&&!CU.schemaHasRulesButRef(I,i.self.RULES)){let me=I.$ref;if(I=wS.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,me),I instanceof wS.SchemaEnv)I=I.schema;if(I===void 0)throw new AU.default(i.opts.uriResolver,i.baseId,me)}let H=(d=I===null||I===void 0?void 0:I.properties)===null||d===void 0?void 0:d[a];if(typeof H!="object")throw Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);v=v&&(x||g(I)),y(H,P)}if(!v)throw Error(`discriminator: "${a}" must be required`);return h;function g({required:P}){return Array.isArray(P)&&P.includes(a)}function y(P,I){if(P.const)w(P.const,I);else if(P.enum)for(let H of P.enum)w(H,I);else throw Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function w(P,I){if(typeof P!="string"||P in h)throw Error(`discriminator: "${a}" values must be unique strings`);h[P]=I}}}};kS.default=jU});var $S=b(function(h7,DU){DU.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}});var Am=b(function(bt,Om){Object.defineProperty(bt,"__esModule",{value:!0});bt.MissingRefError=bt.ValidationError=bt.CodeGen=bt.Name=bt.nil=bt.stringify=bt.str=bt._=bt.KeywordCxt=bt.Ajv=void 0;var MU=P0(),LU=xS(),qU=SS(),TS=$S(),UU=["/properties"],Sc="http://json-schema.org/draft-07/schema";class ts extends MU.default{_addVocabularies(){if(super._addVocabularies(),LU.default.forEach((e)=>this.addVocabulary(e)),this.opts.discriminator)this.addKeyword(qU.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let e=this.opts.$data?this.$dataMetaSchema(TS,UU):TS;this.addMetaSchema(e,Sc,!1),this.refs["http://json-schema.org/schema"]=Sc}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Sc)?Sc:void 0)}}bt.Ajv=ts;Om.exports=bt=ts;Om.exports.Ajv=ts;Object.defineProperty(bt,"__esModule",{value:!0});bt.default=ts;var FU=Fi();Object.defineProperty(bt,"KeywordCxt",{enumerable:!0,get:function(){return FU.KeywordCxt}});var xo=W();Object.defineProperty(bt,"_",{enumerable:!0,get:function(){return xo._}});Object.defineProperty(bt,"str",{enumerable:!0,get:function(){return xo.str}});Object.defineProperty(bt,"stringify",{enumerable:!0,get:function(){return xo.stringify}});Object.defineProperty(bt,"nil",{enumerable:!0,get:function(){return xo.nil}});Object.defineProperty(bt,"Name",{enumerable:!0,get:function(){return xo.Name}});Object.defineProperty(bt,"CodeGen",{enumerable:!0,get:function(){return xo.CodeGen}});var ZU=oc();Object.defineProperty(bt,"ValidationError",{enumerable:!0,get:function(){return ZU.default}});var BU=Zi();Object.defineProperty(bt,"MissingRefError",{enumerable:!0,get:function(){return BU.default}})});var NS=b(function(IS){Object.defineProperty(IS,"__esModule",{value:!0});IS.formatNames=IS.fastFormats=IS.fullFormats=void 0;function cr(e,t){return{validate:e,compare:t}}IS.fullFormats={date:cr(zS,Nm),time:cr(Im(!0),Dm),"date-time":cr(ES(!0),AS),"iso-time":cr(Im(),OS),"iso-date-time":cr(ES(),CS),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:XU,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:iF,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:QU,int32:{type:"number",validate:rF},int64:{type:"number",validate:nF},float:{type:"number",validate:PS},double:{type:"number",validate:PS},password:!0,binary:!0};IS.fastFormats={...IS.fullFormats,date:cr(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,Nm),time:cr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,Dm),"date-time":cr(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,AS),"iso-time":cr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,OS),"iso-date-time":cr(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,CS),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i};IS.formatNames=Object.keys(IS.fullFormats);function GU(e){return e%4===0&&(e%100!==0||e%400===0)}var JU=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,WU=[0,31,28,31,30,31,30,31,31,30,31,30,31];function zS(e){let t=JU.exec(e);if(!t)return!1;let r=+t[1],n=+t[2],o=+t[3];return n>=1&&n<=12&&o>=1&&o<=(n===2&&GU(r)?29:WU[n])}function Nm(e,t){if(!(e&&t))return;if(e>t)return 1;if(e<t)return-1;return 0}var Cm=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function Im(e){return function(r){let n=Cm.exec(r);if(!n)return!1;let o=+n[1],i=+n[2],s=+n[3],a=n[4],c=n[5]==="-"?-1:1,u=+(n[6]||0),l=+(n[7]||0);if(u>23||l>59||e&&!a)return!1;if(o<=23&&i<=59&&s<60)return!0;let p=i-l*c,m=o-u*c-(p<0?1:0);return(m===23||m===-1)&&(p===59||p===-1)&&s<61}}function Dm(e,t){if(!(e&&t))return;let r=new Date("2020-01-01T"+e).valueOf(),n=new Date("2020-01-01T"+t).valueOf();if(!(r&&n))return;return r-n}function OS(e,t){if(!(e&&t))return;let r=Cm.exec(e),n=Cm.exec(t);if(!(r&&n))return;if(e=r[1]+r[2]+r[3],t=n[1]+n[2]+n[3],e>t)return 1;if(e<t)return-1;return 0}var jm=/t|\s/i;function ES(e){let t=Im(e);return function(n){let o=n.split(jm);return o.length===2&&zS(o[0])&&t(o[1])}}function AS(e,t){if(!(e&&t))return;let r=new Date(e).valueOf(),n=new Date(t).valueOf();if(!(r&&n))return;return r-n}function CS(e,t){if(!(e&&t))return;let[r,n]=e.split(jm),[o,i]=t.split(jm),s=Nm(r,o);if(s===void 0)return;return s||Dm(n,i)}var KU=/\/|:/,YU=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function XU(e){return KU.test(e)&&YU.test(e)}var RS=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function QU(e){return RS.lastIndex=0,RS.test(e)}var eF=-2147483648,tF=2147483647;function rF(e){return Number.isInteger(e)&&e<=tF&&e>=eF}function nF(e){return Number.isInteger(e)}function PS(){return!0}var oF=/[^\\]\\Z/;function iF(e){if(oF.test(e))return!1;try{return new RegExp(e),!0}catch(t){return!1}}});var MS=b(function(DS){Object.defineProperty(DS,"__esModule",{value:!0});DS.formatLimitDefinition=void 0;var aF=Am(),er=W(),Zr=er.operators,$c={formatMaximum:{okStr:"<=",ok:Zr.LTE,fail:Zr.GT},formatMinimum:{okStr:">=",ok:Zr.GTE,fail:Zr.LT},formatExclusiveMaximum:{okStr:"<",ok:Zr.LT,fail:Zr.GTE},formatExclusiveMinimum:{okStr:">",ok:Zr.GT,fail:Zr.LTE}},cF={message:({keyword:e,schemaCode:t})=>er.str`should be ${$c[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>er._`{comparison: ${$c[e].okStr}, limit: ${t}}`};DS.formatLimitDefinition={keyword:Object.keys($c),type:"string",schemaType:"string",$data:!0,error:cF,code(e){let{gen:t,data:r,schemaCode:n,keyword:o,it:i}=e,{opts:s,self:a}=i;if(!s.validateFormats)return;let c=new aF.KeywordCxt(i,a.RULES.all.format.definition,"format");if(c.$data)u();else l();function u(){let m=t.scopeValue("formats",{ref:a.formats,code:s.code.formats}),d=t.const("fmt",er._`${m}[${c.schemaCode}]`);e.fail$data(er.or(er._`typeof ${d} != "object"`,er._`${d} instanceof RegExp`,er._`typeof ${d}.compare != "function"`,p(d)))}function l(){let m=c.schema,d=a.formats[m];if(!d||d===!0)return;if(typeof d!="object"||d instanceof RegExp||typeof d.compare!="function")throw Error(`"${o}": format "${m}" does not define "compare" function`);let h=t.scopeValue("formats",{key:m,ref:d,code:s.code.formats?er._`${s.code.formats}${er.getProperty(m)}`:void 0});e.fail$data(p(h))}function p(m){return er._`${m}.compare(${r}, ${n}) ${$c[o].fail} 0`}},dependencies:["format"]};var uF=(e)=>(e.addKeyword(DS.formatLimitDefinition),e);DS.default=uF});var FS=b(function(rs,US){Object.defineProperty(rs,"__esModule",{value:!0});var vo=NS(),pF=MS(),qm=W(),LS=new qm.Name("fullFormats"),dF=new qm.Name("fastFormats"),Um=(e,t={keywords:!0})=>{if(Array.isArray(t))return qS(e,t,vo.fullFormats,LS),e;let[r,n]=t.mode==="fast"?[vo.fastFormats,dF]:[vo.fullFormats,LS],o=t.formats||vo.formatNames;if(qS(e,o,r,n),t.keywords)(0,pF.default)(e);return e};Um.get=(e,t="full")=>{let n=(t==="fast"?vo.fastFormats:vo.fullFormats)[e];if(!n)throw Error(`Unknown format "${e}"`);return n};function qS(e,t,r,n){var o,i;(o=(i=e.opts.code).formats)!==null&&o!==void 0||(i.formats=qm._`require("ajv-formats/dist/formats").${n}`);for(let s of t)e.addFormat(s,r[s])}US.exports=rs=Um;Object.defineProperty(rs,"__esModule",{value:!0});rs.default=Um});function HF(e,t=[]){for(let r=0;r<e.length;r++){if(e[r].startsWith("-"))continue;if(r>0&&t.includes(e[r-1]))continue;return{before:e.slice(0,r),script:e[r],after:e.slice(r+1)}}return{before:e,script:void 0,after:[]}}function nf(e,t,r=[]){return(n)=>{let{before:o,script:i,after:s}=HF(n,r);if(i===void 0)return[e,t,...o];if(s.length>0)return[e,t,...o,i,"--",...s];return[e,t,...o,i]}}function y$(e){return{agent:[e,0],run:[e,"run",0],install:[e,"i",0],frozen:[e,"i","--frozen-lockfile",0],global:[e,"add","-g",0],add:[e,"add",0],upgrade:[e,"update",0],"upgrade-interactive":[e,"update","-i",0],dedupe:[e,"dedupe",0],execute:[e,"dlx",0],"execute-local":[e,"exec",0],uninstall:[e,"remove",0],global_uninstall:[e,"remove","--global",0]}}function _$(e,t,r){let n=b$[e][t];return w$(n,r)}function w$(e,t){if(e==null)return null;let r=typeof e==="function"?e(t):e.flatMap((n)=>{if(typeof n==="number")return t;return[n]});return{command:r[0],args:r.slice(1)}}var VF,v$,GF,x$,JF,WF,KF,YF,XF,b$;var k$=us(()=>{VF={agent:["npm",0],run:nf("npm","run",["-w","--workspace"]),install:["npm","i",0],frozen:["npm","ci",0],global:["npm","i","-g",0],add:["npm","i",0],upgrade:["npm","update",0],"upgrade-interactive":null,dedupe:["npm","dedupe",0],execute:["npx",0],"execute-local":["npx",0],uninstall:["npm","uninstall",0],global_uninstall:["npm","uninstall","-g",0]},v$={agent:["yarn",0],run:["yarn","run",0],install:["yarn","install",0],frozen:["yarn","install","--frozen-lockfile",0],global:["yarn","global","add",0],add:["yarn","add",0],upgrade:["yarn","upgrade",0],"upgrade-interactive":["yarn","upgrade-interactive",0],dedupe:null,execute:["npx",0],"execute-local":nf("yarn","exec"),uninstall:["yarn","remove",0],global_uninstall:["yarn","global","remove",0]},GF={...v$,frozen:["yarn","install","--immutable",0],upgrade:["yarn","up",0],"upgrade-interactive":["yarn","up","-i",0],dedupe:["yarn","dedupe",0],execute:["yarn","dlx",0],"execute-local":["yarn","exec",0],global:["npm","i","-g",0],global_uninstall:["npm","uninstall","-g",0]};x$=y$("pnpm"),JF=y$("rush-pnpm"),WF={agent:["bun",0],run:["bun","run",0],install:["bun","install",0],frozen:["bun","install","--frozen-lockfile",0],global:["bun","add","-g",0],add:["bun","add",0],upgrade:["bun","update",0],"upgrade-interactive":["bun","update","-i",0],dedupe:null,execute:["bun","x",0],"execute-local":["bun","x",0],uninstall:["bun","remove",0],global_uninstall:["bun","remove","-g",0]},KF={agent:["aube",0],run:["aube","run",0],install:["aube","install",0],frozen:["aube","install","--frozen-lockfile",0],global:["aube","add","-g",0],add:["aube","add",0],upgrade:["aube","update",0],"upgrade-interactive":["aube","update","-i",0],dedupe:["aube","dedupe",0],execute:["aube","dlx",0],"execute-local":["aube","exec",0],uninstall:["aube","remove",0],global_uninstall:["aube","remove","-g",0]},YF={agent:["deno",0],run:["deno","task",0],install:["deno","install",0],frozen:["deno","install","--frozen",0],global:["deno","install","-g",0],add:["deno","add",0],upgrade:["deno","outdated","--update",0],"upgrade-interactive":["deno","outdated","--update",0],dedupe:null,execute:["deno","x",0],"execute-local":["deno","task","--eval",0],uninstall:["deno","remove",0],global_uninstall:["deno","uninstall","-g",0]},XF={agent:["nub",0],run:["nub","run",0],install:["nub","install",0],frozen:["nub","install","--frozen-lockfile",0],global:["nub","add","-g",0],add:["nub","add",0],upgrade:["nub","update",0],"upgrade-interactive":["nub","update","-i",0],dedupe:["nub","dedupe",0],execute:["nubx",0],"execute-local":["nub","exec",0],uninstall:["nub","remove",0],global_uninstall:["nub","remove","-g",0]},b$={npm:VF,yarn:v$,"yarn@berry":GF,pnpm:x$,"pnpm@6":{...x$,run:nf("pnpm","run",["-F","--filter"])},"pnpm-rush":JF,bun:WF,aube:KF,deno:YF,nub:XF}});var S$;var $$=us(()=>{S$=["npm","yarn","yarn@berry","pnpm","pnpm@6","pnpm-rush","bun","deno","nub","aube"]});import QF from"node:process";function T$(){let e=QF.env.npm_config_user_agent;if(!e)return null;let t=e.split("/")[0];return S$.includes(t)?t:null}var E$=us(()=>{$$()});var R$=us(()=>{k$();E$()});import{promises as N$,readFileSync as u4}from"node:fs";function $o(e,t){return function(){return e.apply(t,arguments)}}var{toString:o1}=Object.prototype,{getPrototypeOf:Tn}=Object,{iterator:Eo,toStringTag:_f}=Symbol,ps=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),To=(e,t)=>{let r=e,n=[];while(r!=null&&r!==Object.prototype){if(n.indexOf(r)!==-1)return!1;if(n.push(r),ps(r,t))return!0;r=Tn(r)}return!1},i1=(e,t)=>e!=null&&To(e,t)?e[t]:void 0,qc=((e)=>(t)=>{let r=o1.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Ft=(e)=>(e=e.toLowerCase(),(t)=>qc(t)===e),ds=(e)=>(t)=>typeof t===e,{isArray:Yr}=Array,En=ds("undefined");function Rn(e){return e!==null&&!En(e)&&e.constructor!==null&&!En(e.constructor)&&ft(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}var wf=Ft("ArrayBuffer");function s1(e){let t;if(typeof ArrayBuffer<"u"&&ArrayBuffer.isView)t=ArrayBuffer.isView(e);else t=e&&e.buffer&&wf(e.buffer);return t}var a1=ds("string"),ft=ds("function"),kf=ds("number"),Pn=(e)=>e!==null&&typeof e==="object",c1=(e)=>e===!0||e===!1,ls=(e)=>{if(!Pn(e))return!1;let t=Tn(e);return(t===null||t===Object.prototype||Tn(t)===null)&&!To(e,_f)&&!To(e,Eo)},u1=(e)=>{if(!Pn(e)||Rn(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(t){return!1}},l1=Ft("Date"),p1=Ft("File"),d1=(e)=>!!(e&&typeof e.uri<"u"),m1=(e)=>e&&typeof e.getParts<"u",f1=Ft("Blob"),h1=Ft("FileList"),g1=(e)=>Pn(e)&&ft(e.pipe);function x1(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;return{}}var yf=x1(),bf=typeof yf.FormData<"u"?yf.FormData:void 0,v1=(e)=>{if(!e)return!1;if(bf&&e instanceof bf)return!0;let t=Tn(e);if(!t||t===Object.prototype)return!1;if(!ft(e.append))return!1;let r=qc(e);return r==="formdata"||r==="object"&&ft(e.toString)&&e.toString()==="[object FormData]"},y1=Ft("URLSearchParams"),[b1,_1,w1,k1]=["ReadableStream","Request","Response","Headers"].map(Ft),S1=(e)=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ro(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,o;if(typeof e!=="object")e=[e];if(Yr(e))for(n=0,o=e.length;n<o;n++)t.call(null,e[n],n,e);else{if(Rn(e))return;let i=r?Object.getOwnPropertyNames(e):Object.keys(e),s=i.length,a;for(n=0;n<s;n++)a=i[n],t.call(null,e[a],a,e)}}function Sf(e,t){if(Rn(e))return null;t=t.toLowerCase();let r=Object.keys(e),n=r.length,o;while(n-- >0)if(o=r[n],t===o.toLowerCase())return o;return null}var Kr=(()=>{if(typeof globalThis<"u")return globalThis;return typeof self<"u"?self:typeof window<"u"?window:global})(),$f=(e)=>!En(e)&&e!==Kr;function Lc(...e){let{caseless:t,skipUndefined:r}=$f(this)&&this||{},n={},o=(i,s)=>{if(s==="__proto__"||s==="constructor"||s==="prototype")return;let a=t&&typeof s==="string"&&Sf(n,s)||s,c=ps(n,a)?n[a]:void 0;if(ls(c)&&ls(i))n[a]=Lc(c,i);else if(ls(i))n[a]=Lc({},i);else if(Yr(i))n[a]=i.slice();else if(!r||!En(i))n[a]=i};for(let i=0,s=e.length;i<s;i++){let a=e[i];if(!a||Rn(a))continue;if(Ro(a,o),typeof a!=="object"||Yr(a))continue;let c=Object.getOwnPropertySymbols(a);for(let u=0;u<c.length;u++){let l=c[u];if(N1.call(a,l))o(a[l],l)}}return n}var $1=(e,t,r,{allOwnKeys:n}={})=>(Ro(t,(o,i)=>{if(r&&ft(o))Object.defineProperty(e,i,{__proto__:null,value:$o(o,r),writable:!0,enumerable:!0,configurable:!0});else Object.defineProperty(e,i,{__proto__:null,value:o,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),T1=(e)=>{if(e.charCodeAt(0)===65279)e=e.slice(1);return e},E1=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),r&&Object.assign(e.prototype,r)},R1=(e,t,r,n)=>{let o,i,s,a={};if(t=t||{},e==null)return t;do{o=Object.getOwnPropertyNames(e),i=o.length;while(i-- >0)if(s=o[i],(!n||n(s,e,t))&&!a[s])t[s]=e[s],a[s]=!0;e=r!==!1&&Tn(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},P1=(e,t,r)=>{if(e=String(e),r===void 0||r>e.length)r=e.length;r-=t.length;let n=e.indexOf(t,r);return n!==-1&&n===r},z1=(e)=>{if(!e)return null;if(Yr(e))return e;let t=e.length;if(!kf(t))return null;let r=Array(t);while(t-- >0)r[t]=e[t];return r},O1=((e)=>(t)=>e&&t instanceof e)(typeof Uint8Array<"u"&&Tn(Uint8Array)),A1=(e,t)=>{let n=(e&&e[Eo]).call(e),o;while((o=n.next())&&!o.done){let i=o.value;t.call(e,i[0],i[1])}},C1=(e,t)=>{let r,n=[];while((r=e.exec(t))!==null)n.push(r);return n},I1=Ft("HTMLFormElement"),j1=(e)=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,o){return n.toUpperCase()+o}),{propertyIsEnumerable:N1}=Object.prototype,D1=Ft("RegExp"),Tf=(e,t)=>{let r=Object.getOwnPropertyDescriptors(e),n={};Ro(r,(o,i)=>{let s;if((s=t(o,i,e))!==!1)n[i]=s||o}),Object.defineProperties(e,n)},M1=(e)=>{Tf(e,(t,r)=>{if(ft(e)&&["arguments","caller","callee"].includes(r))return!1;let n=e[r];if(!ft(n))return;if(t.enumerable=!1,"writable"in t){t.writable=!1;return}if(!t.set)t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")}})},L1=(e,t)=>{let r={},n=(o)=>{o.forEach((i)=>{r[i]=!0})};return Yr(e)?n(e):n(String(e).split(t)),r},q1=()=>{},U1=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function F1(e){return!!(e&&ft(e.append)&&e[_f]==="FormData"&&e[Eo])}var Z1=(e)=>{let t=new WeakSet,r=(n)=>{if(Pn(n)){if(t.has(n))return;if(Rn(n))return n;if(!("toJSON"in n)){t.add(n);let o=Yr(n)?[]:{};return Ro(n,(i,s)=>{let a=r(i);!En(a)&&(o[s]=a)}),t.delete(n),o}}return n};return r(e)},B1=Ft("AsyncFunction"),H1=(e)=>e&&(Pn(e)||ft(e))&&ft(e.then)&&ft(e.catch),Ef=((e,t)=>{if(e)return setImmediate;return t?((r,n)=>(Kr.addEventListener("message",({source:o,data:i})=>{if(o===Kr&&i===r)n.length&&n.shift()()},!1),(o)=>{n.push(o),Kr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):(r)=>setTimeout(r)})(typeof setImmediate==="function",ft(Kr.postMessage)),V1=typeof queueMicrotask<"u"?queueMicrotask.bind(Kr):typeof process<"u"&&process.nextTick||Ef,Rf=(e)=>e!=null&&ft(e[Eo]),G1=(e)=>e!=null&&To(e,Eo)&&Rf(e),f={isArray:Yr,isArrayBuffer:wf,isBuffer:Rn,isFormData:v1,isArrayBufferView:s1,isString:a1,isNumber:kf,isBoolean:c1,isObject:Pn,isPlainObject:ls,isEmptyObject:u1,isReadableStream:b1,isRequest:_1,isResponse:w1,isHeaders:k1,isUndefined:En,isDate:l1,isFile:p1,isReactNativeBlob:d1,isReactNative:m1,isBlob:f1,isRegExp:D1,isFunction:ft,isStream:g1,isURLSearchParams:y1,isTypedArray:O1,isFileList:h1,forEach:Ro,merge:Lc,extend:$1,trim:S1,stripBOM:T1,inherits:E1,toFlatObject:R1,kindOf:qc,kindOfTest:Ft,endsWith:P1,toArray:z1,forEachEntry:A1,matchAll:C1,isHTMLForm:I1,hasOwnProperty:ps,hasOwnProp:ps,hasOwnInPrototypeChain:To,getSafeProp:i1,reduceDescriptors:Tf,freezeMethods:M1,toObjectSet:L1,toCamelCase:j1,noop:q1,toFiniteNumber:U1,findKey:Sf,global:Kr,isContextDefined:$f,isSpecCompliantForm:F1,toJSONObject:Z1,isAsyncFn:B1,isThenable:H1,setImmediate:Ef,asap:V1,isIterable:Rf,isSafeIterable:G1};var J1=f.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"]),Pf=(e)=>{let t={},r,n,o;return e&&e.split(`
|
|
27
|
+
`).forEach(function(s){if(o=s.indexOf(":"),r=s.substring(0,o).trim().toLowerCase(),n=s.substring(o+1).trim(),!r||t[r]&&J1[r])return;if(r==="set-cookie")if(t[r])t[r].push(n);else t[r]=[n];else t[r]=t[r]?t[r]+", "+n:n}),t};function W1(e){let t=0,r=e.length;while(t<r){let n=e.charCodeAt(t);if(n!==9&&n!==32)break;t+=1}while(r>t){let n=e.charCodeAt(r-1);if(n!==9&&n!==32)break;r-=1}return t===0&&r===e.length?e:e.slice(t,r)}var K1=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),Y1=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function Uc(e,t){if(f.isArray(e))return e.map((r)=>Uc(r,t));return W1(String(e).replace(t,""))}var zf=(e)=>Uc(e,K1),X1=(e)=>Uc(e,Y1);function zn(e){let t=Object.create(null);return f.forEach(e.toJSON(),(r,n)=>{t[n]=X1(r)}),t}var Of=Symbol("internals");function Po(e){return e&&String(e).trim().toLowerCase()}function ms(e){if(e===!1||e==null)return e;return f.isArray(e)?e.map(ms):zf(String(e))}function Q1(e){let t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,n;while(n=r.exec(e))t[n[1]]=n[2];return t}var eT=(e)=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Fc(e,t,r,n,o){if(f.isFunction(n))return n.call(this,t,r);if(o)t=r;if(!f.isString(t))return;if(f.isString(n))return t.indexOf(n)!==-1;if(f.isRegExp(n))return n.test(t)}function tT(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function rT(e,t){let r=f.toCamelCase(" "+t);["get","set","has"].forEach((n)=>{Object.defineProperty(e,n+r,{__proto__:null,value:function(o,i,s){return this[n].call(this,t,o,i,s)},configurable:!0})})}class zo{constructor(e){e&&this.set(e)}set(e,t,r){let n=this;function o(s,a,c){let u=Po(a);if(!u)return;let l=f.findKey(n,u);if(!l||n[l]===void 0||c===!0||c===void 0&&n[l]!==!1)n[l||a]=ms(s)}let i=(s,a)=>f.forEach(s,(c,u)=>o(c,u,a));if(f.isPlainObject(e)||e instanceof this.constructor)i(e,t);else if(f.isString(e)&&(e=e.trim())&&!eT(e))i(Pf(e),t);else if(f.isObject(e)&&f.isSafeIterable(e)){let s=Object.create(null),a,c;for(let u of e){if(!f.isArray(u))throw TypeError("Object iterator must return a key-value pair");if(c=u[0],f.hasOwnProp(s,c))a=s[c],s[c]=f.isArray(a)?[...a,u[1]]:[a,u[1]];else s[c]=u[1]}i(s,t)}else e!=null&&o(t,e,r);return this}get(e,t){if(e=Po(e),e){let r=f.findKey(this,e);if(r){let n=this[r];if(!t)return n;if(t===!0)return Q1(n);if(f.isFunction(t))return t.call(this,n,r);if(f.isRegExp(t))return t.exec(n);throw TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Po(e),e){let r=f.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||Fc(this,this[r],r,t)))}return!1}delete(e,t){let r=this,n=!1;function o(i){if(i=Po(i),i){let s=f.findKey(r,i);if(s&&(!t||Fc(r,r[s],s,t)))delete r[s],n=!0}}if(f.isArray(e))e.forEach(o);else o(e);return n}clear(e){let t=Object.keys(this),r=t.length,n=!1;while(r--){let o=t[r];if(!e||Fc(this,this[o],o,e,!0))delete this[o],n=!0}return n}normalize(e){let t=this,r={};return f.forEach(this,(n,o)=>{let i=f.findKey(r,o);if(i){t[i]=ms(n),delete t[o];return}let s=e?tT(o):String(o).trim();if(s!==o)delete t[o];t[s]=ms(n),r[s]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let t=Object.create(null);return f.forEach(this,(r,n)=>{r!=null&&r!==!1&&(t[n]=e&&f.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(`
|
|
28
|
+
`)}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((n)=>r.set(n)),r}static accessor(e){let r=(this[Of]=this[Of]={accessors:{}}).accessors,n=this.prototype;function o(i){let s=Po(i);if(!r[s])rT(n,i),r[s]=!0}return f.isArray(e)?e.forEach(o):o(e),this}}zo.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);f.reduceDescriptors(zo.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});f.freezeMethods(zo);var be=zo;var nT="[REDACTED ****]";function oT(e){if(f.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);while(t&&t!==Object.prototype){if(f.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function iT(e,t){let r=new Set(t.map((i)=>String(i).toLowerCase())),n=[],o=(i)=>{if(i===null||typeof i!=="object")return i;if(f.isBuffer(i))return i;if(n.indexOf(i)!==-1)return;if(i instanceof be)i=i.toJSON();n.push(i);let s;if(f.isArray(i))s=[],i.forEach((a,c)=>{let u=o(a);if(!f.isUndefined(u))s[c]=u});else{if(!f.isPlainObject(i)&&oT(i))return n.pop(),i;s=Object.create(null);for(let[a,c]of Object.entries(i)){let u=r.has(a.toLowerCase())?nT:o(c);if(!f.isUndefined(u))s[a]=u}}return n.pop(),s};return o(e)}class Ye extends Error{static from(e,t,r,n,o,i){let s=new Ye(e.message,t||e.code,r,n,o);if(s.cause=e,s.name=e.name,e.status!=null&&s.status==null)s.status=e.status;return i&&Object.assign(s,i),s}constructor(e,t,r,n,o){super(e);if(Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),o)this.response=o,this.status=o.status}toJSON(){let e=this.config,t=e&&f.hasOwnProp(e,"redact")?e.redact:void 0,r=f.isArray(t)&&t.length>0?iT(e,t):f.toJSONObject(e);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:r,code:this.code,status:this.status}}}Ye.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";Ye.ERR_BAD_OPTION="ERR_BAD_OPTION";Ye.ECONNABORTED="ECONNABORTED";Ye.ETIMEDOUT="ETIMEDOUT";Ye.ECONNREFUSED="ECONNREFUSED";Ye.ERR_NETWORK="ERR_NETWORK";Ye.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";Ye.ERR_DEPRECATED="ERR_DEPRECATED";Ye.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";Ye.ERR_BAD_REQUEST="ERR_BAD_REQUEST";Ye.ERR_CANCELED="ERR_CANCELED";Ye.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";Ye.ERR_INVALID_URL="ERR_INVALID_URL";Ye.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";var S=Ye;var jg=So(Ig(),1),Ss=jg.default;var mu=100;function du(e){return f.isPlainObject(e)||f.isArray(e)}function Ng(e){return f.endsWith(e,"[]")?e.slice(0,-2):e}function pu(e,t,r){if(!e)return t;return e.concat(t).map(function(o,i){return o=Ng(o),!r&&i?"["+o+"]":o}).join(r?".":"")}function JE(e){return f.isArray(e)&&!e.some(du)}var WE=f.toFlatObject(f,{},null,function(t){return/^is[A-Z]/.test(t)});function KE(e,t,r){if(!f.isObject(e))throw TypeError("target must be an object");t=t||new(Ss||FormData),r=f.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(y,w){return!f.isUndefined(w[y])});let n=r.metaTokens,o=r.visitor||h,i=r.dots,s=r.indexes,a=r.Blob||typeof Blob<"u"&&Blob,c=r.maxDepth===void 0?mu:r.maxDepth,u=a&&f.isSpecCompliantForm(t),l=[];if(!f.isFunction(o))throw TypeError("visitor must be a function");function p(g){if(g===null)return"";if(f.isDate(g))return g.toISOString();if(f.isBoolean(g))return g.toString();if(!u&&f.isBlob(g))throw new S("Blob is not supported. Use a Buffer instead.");if(f.isArrayBuffer(g)||f.isTypedArray(g))return u&&typeof Blob==="function"?new Blob([g]):Buffer.from(g);return g}function m(g){if(g>c)throw new S("Object is too deeply nested ("+g+" levels). Max depth: "+c,S.ERR_FORM_DATA_DEPTH_EXCEEDED)}function d(g,y){if(c===1/0)return JSON.stringify(g);let w=[];return JSON.stringify(g,function(I,H){if(!f.isObject(H))return H;while(w.length&&w[w.length-1]!==this)w.pop();return w.push(H),m(y+w.length-1),H})}function h(g,y,w){let P=g;if(f.isReactNative(t)&&f.isReactNativeBlob(g))return t.append(pu(w,y,i),p(g)),!1;if(g&&!w&&typeof g==="object"){if(f.endsWith(y,"{}"))y=n?y:y.slice(0,-2),g=d(g,1);else if(f.isArray(g)&&JE(g)||(f.isFileList(g)||f.endsWith(y,"[]"))&&(P=f.toArray(g)))return y=Ng(y),P.forEach(function(H,me){!(f.isUndefined(H)||H===null)&&t.append(s===!0?pu([y],me,i):s===null?y:y+"[]",p(H))}),!1}if(du(g))return!0;return t.append(pu(w,y,i),p(g)),!1}let x=Object.assign(WE,{defaultVisitor:h,convertValue:p,isVisitable:du});function v(g,y,w=0){if(f.isUndefined(g))return;if(m(w),l.indexOf(g)!==-1)throw Error("Circular reference detected in "+y.join("."));l.push(g),f.forEach(g,function(I,H){if((!(f.isUndefined(I)||I===null)&&o.call(t,I,f.isString(H)?H.trim():H,y,x))===!0)v(I,y?y.concat(H):[H],w+1)}),l.pop()}if(!f.isObject(e))throw TypeError("data must be an object");return v(e),t}var Tr=KE;function Dg(e){let t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(n){return t[n]})}function Mg(e,t){this._pairs=[],e&&Tr(e,this,t)}var Lg=Mg.prototype;Lg.append=function(t,r){this._pairs.push([t,r])};Lg.toString=function(t){let r=t?function(n){return t.call(this,n,Dg)}:Dg;return this._pairs.map(function(o){return r(o[0])+"="+r(o[1])},"").join("&")};var qg=Mg;function YE(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Qr(e,t,r){if(!t)return e;let n=f.isFunction(r)?{serialize:r}:r,o=f.getSafeProp(n,"encode")||YE,i=f.getSafeProp(n,"serialize"),s;if(i)s=i(t,n);else s=f.isURLSearchParams(t)?t.toString():new qg(t,n).toString(o);if(s){let a=e.indexOf("#");if(a!==-1)e=e.slice(0,a);e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class Ug{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){if(this.handlers[e])this.handlers[e]=null}clear(){if(this.handlers)this.handlers=[]}forEach(e){f.forEach(this.handlers,function(r){if(r!==null)e(r)})}}var fu=Ug;var Er={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1,validateStatusUndefinedResolves:!0};import QE from"crypto";import XE from"url";var Fg=XE.URLSearchParams;var hu="abcdefghijklmnopqrstuvwxyz",Zg="0123456789",Bg={DIGIT:Zg,ALPHA:hu,ALPHA_DIGIT:hu+hu.toUpperCase()+Zg},eR=(e=16,t=Bg.ALPHA_DIGIT)=>{let r="",{length:n}=t,o=new Uint32Array(e);QE.randomFillSync(o);for(let i=0;i<e;i++)r+=t[o[i]%n];return r},Hg={isNode:!0,classes:{URLSearchParams:Fg,FormData:Ss,Blob:typeof Blob<"u"&&Blob||null},ALPHABET:Bg,generateString:eR,protocols:["http","https","file","data"]};var vu={};r1(vu,{hasBrowserEnv:()=>xu,hasStandardBrowserEnv:()=>tR,hasStandardBrowserWebWorkerEnv:()=>rR,navigator:()=>gu,origin:()=>nR});var xu=typeof window<"u"&&typeof document<"u",gu=typeof navigator==="object"&&navigator||void 0,tR=xu&&(!gu||["ReactNative","NativeScript","NS"].indexOf(gu.product)<0),rR=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts==="function")(),nR=xu&&window.location.href||"http://localhost";var ce={...vu,...Hg};function yu(e,t){return Tr(e,new ce.classes.URLSearchParams,{visitor:function(r,n,o,i){if(ce.isNode&&f.isBuffer(r))return this.append(n,r.toString("base64")),!1;return i.defaultVisitor.apply(this,arguments)},...t})}var Vg=mu;function Gg(e){if(e>Vg)throw new S("FormData field is too deeply nested ("+e+" levels). Max depth: "+Vg,S.ERR_FORM_DATA_DEPTH_EXCEEDED)}function oR(e){let t=[],r=/\w+|\[(\w*)]/g,n;while((n=r.exec(e))!==null)Gg(t.length),t.push(n[0]==="[]"?"":n[1]||n[0]);return t}function iR(e){let t={},r=Object.keys(e),n,o=r.length,i;for(n=0;n<o;n++)i=r[n],t[i]=e[i];return t}function sR(e){function t(r,n,o,i){Gg(i);let s=r[i++];if(s==="__proto__")return!0;let a=Number.isFinite(+s),c=i>=r.length;if(s=!s&&f.isArray(o)?o.length:s,c){if(f.hasOwnProp(o,s))o[s]=f.isArray(o[s])?o[s].concat(n):[o[s],n];else o[s]=n;return!a}if(!f.hasOwnProp(o,s)||!f.isObject(o[s]))o[s]=[];if(t(r,n,o[s],i)&&f.isArray(o[s]))o[s]=iR(o[s]);return!a}if(f.isFormData(e)&&f.isFunction(e.entries)){let r={};return f.forEachEntry(e,(n,o)=>{t(oR(n),o,r,0)}),r}return null}var $s=sR;var jn=(e,t)=>e!=null&&f.hasOwnProp(e,t)?e[t]:void 0;function aR(e,t,r){if(f.isString(e))try{return(t||JSON.parse)(e),f.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}var bu={transitional:Er,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){let n=r.getContentType()||"",o=n.indexOf("application/json")>-1,i=f.isObject(t);if(i&&f.isHTMLForm(t))t=new FormData(t);if(f.isFormData(t))return o?JSON.stringify($s(t)):t;if(f.isArrayBuffer(t)||f.isBuffer(t)||f.isStream(t)||f.isFile(t)||f.isBlob(t)||f.isReadableStream(t))return t;if(f.isArrayBufferView(t))return t.buffer;if(f.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(i){let c=jn(this,"formSerializer");if(n.indexOf("application/x-www-form-urlencoded")>-1)return yu(t,c).toString();if((a=f.isFileList(t))||n.indexOf("multipart/form-data")>-1){let u=jn(this,"env"),l=u&&u.FormData;return Tr(a?{"files[]":t}:t,l&&new l,c)}}if(i||o)return r.setContentType("application/json",!1),aR(t);return t}],transformResponse:[function(t){let r=jn(this,"transitional")||bu.transitional,n=r&&r.forcedJSONParsing,o=jn(this,"responseType"),i=o==="json";if(f.isResponse(t)||f.isReadableStream(t))return t;if(t&&f.isString(t)&&(n&&!o||i)){let a=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(t,jn(this,"parseReviver"))}catch(c){if(a){if(c.name==="SyntaxError")throw S.from(c,S.ERR_BAD_RESPONSE,this,null,jn(this,"response"));throw c}}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ce.classes.FormData,Blob:ce.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};f.forEach(["delete","get","head","post","put","patch","query"],(e)=>{bu.headers[e]={}});var Nn=bu;function jo(e,t){let r=this||Nn,n=t||r,o=be.from(n.headers),i=n.data;return f.forEach(e,function(a){i=a.call(r,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function No(e){return!!(e&&e.__CANCEL__)}class Jg extends S{constructor(e,t,r){super(e==null?"canceled":e,S.ERR_CANCELED,t,r);this.name="CanceledError",this.__CANCEL__=!0}}var kt=Jg;function nr(e,t,r){let n=r.config.validateStatus;if(!r.status||!n||n(r.status))e(r);else t(new S("Request failed with status code "+r.status,r.status>=400&&r.status<500?S.ERR_BAD_REQUEST:S.ERR_BAD_RESPONSE,r.config,r.request,r))}function _u(e){if(typeof e!=="string")return!1;return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function wu(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}var cR=/^https?:(?!\/\/)/i,uR=/[\t\n\r]/g;function lR(e){let t=0;while(t<e.length&&e.charCodeAt(t)<=32)t++;return e.slice(t)}function pR(e){return lR(e).replace(uR,"")}function Wg(e,t){if(typeof e==="string"&&cR.test(pR(e)))throw new S('Invalid URL: missing "//" after protocol',S.ERR_INVALID_URL,t)}function en(e,t,r,n){Wg(t,n);let o=!_u(t);if(e&&(o||r===!1))return Wg(e,n),wu(e,t);return t}var dR={ftp:21,gopher:70,http:80,https:443,ws:80,wss:443};function mR(e){try{return new URL(e)}catch{return null}}function Kg(e){var t=(typeof e==="string"?mR(e):e)||{},{protocol:r,host:n,port:o}=t;if(typeof n!=="string"||!n||typeof r!=="string")return"";if(r=r.split(":",1)[0],n=n.replace(/:\d*$/,""),o=parseInt(o)||dR[r]||0,!fR(n,o))return"";var i=ku(r+"_proxy")||ku("all_proxy");if(i&&i.indexOf("://")===-1)i=r+"://"+i;return i}function fR(e,t){var r=ku("no_proxy").toLowerCase();if(!r)return!0;if(r==="*")return!1;return r.split(/[,\s]/).every(function(n){if(!n)return!0;var o=n.match(/^(.+):(\d+)$/),i=o?o[1]:n,s=o?parseInt(o[2]):0;if(s&&s!==t)return!0;if(!/^[.*]/.test(i))return e!==i;if(i.charAt(0)==="*")i=i.slice(1);return!e.endsWith(i)})}function ku(e){return process.env[e.toLowerCase()]||process.env[e.toUpperCase()]||""}var Xu=So(bx(),1),Kx=So(Ex(),1);import tz from"http";import rz from"https";import nz from"http2";import oz from"util";import{resolve as Fx}from"path";import At from"zlib";var ur="1.18.0";function Go(e){let t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}var OP=/^([^,;]+\/[^,;]+)?((?:;[^,;=]+=[^,;]+)*)(;base64)?,([\s\S]*)$/;function Gu(e,t,r){let n=r&&r.Blob||ce.classes.Blob,o=Go(e);if(t===void 0&&n)t=!0;if(o==="data"){e=o.length?e.slice(o.length+1):e;let i=OP.exec(e);if(!i)throw new S("Invalid URL",S.ERR_INVALID_URL);let s=i[1],a=i[2],c=i[3]?"base64":"utf8",u=i[4],l;if(s)l=a?s+a:s;else if(a)l="text/plain"+a;let p=Buffer.from(decodeURIComponent(u),c);if(t){if(!n)throw new S("Blob is not supported",S.ERR_NOT_SUPPORT);return new n([p],{type:l})}return p}throw new S("Unsupported protocol "+o,S.ERR_NOT_SUPPORT)}import Bt from"stream";import AP from"stream";var Ju=Symbol("internals");class Rx extends AP.Transform{constructor(e){e=f.toFlatObject(e,{maxRate:0,chunkSize:65536,minChunkSize:100,timeWindow:500,ticksRate:2,samplesCount:15},null,(r,n)=>!f.isUndefined(n[r]));super({readableHighWaterMark:e.chunkSize});let t=this[Ju]={timeWindow:e.timeWindow,chunkSize:e.chunkSize,maxRate:e.maxRate,minChunkSize:e.minChunkSize,bytesSeen:0,isCaptured:!1,notifiedBytesLoaded:0,ts:Date.now(),bytes:0,onReadCallback:null};this.on("newListener",(r)=>{if(r==="progress"){if(!t.isCaptured)t.isCaptured=!0}})}_read(e){let t=this[Ju];if(t.onReadCallback)t.onReadCallback();return super._read(e)}_transform(e,t,r){let n=this[Ju],o=n.maxRate,i=this.readableHighWaterMark,s=n.timeWindow,a=1000/s,c=o/a,u=n.minChunkSize!==!1?Math.max(n.minChunkSize,c*0.01):0,l=(m,d)=>{let h=Buffer.byteLength(m);if(n.bytesSeen+=h,n.bytes+=h,n.isCaptured&&this.emit("progress",n.bytesSeen),this.push(m))process.nextTick(d);else n.onReadCallback=()=>{n.onReadCallback=null,process.nextTick(d)}},p=(m,d)=>{let h=Buffer.byteLength(m),x=null,v=i,g,y=0;if(o){let w=Date.now();if(!n.ts||(y=w-n.ts)>=s)n.ts=w,g=c-n.bytes,n.bytes=g<0?-g:0,y=0;g=c-n.bytes}if(o){if(g<=0)return setTimeout(()=>{d(null,m)},s-y);if(g<v)v=g}if(v&&h>v&&h-v>u)x=m.subarray(v),m=m.subarray(0,v);l(m,x?()=>{process.nextTick(d,null,x)}:d)};p(e,function m(d,h){if(d)return r(d);if(h)p(h,m);else r(null)})}}var Wu=Rx;import{EventEmitter as iz}from"events";import IP from"util";import{Readable as jP}from"stream";var{asyncIterator:Px}=Symbol,CP=async function*(e){if(e.stream)yield*e.stream();else if(e.arrayBuffer)yield await e.arrayBuffer();else if(e[Px])yield*e[Px]();else yield e},Os=CP;var NP=ce.ALPHABET.ALPHA_DIGIT+"-_",Jo=typeof TextEncoder==="function"?new TextEncoder:new IP.TextEncoder,an=`\r
|
|
29
|
+
`,DP=Jo.encode(an),MP=2;class zx{constructor(e,t){let{escapeName:r}=this.constructor,n=f.isString(t),o=`Content-Disposition: form-data; name="${r(e)}"${!n&&t.name?`; filename="${r(t.name)}"`:""}${an}`;if(n)t=Jo.encode(String(t).replace(/\r?\n|\r\n?/g,an));else{let i=String(t.type||"application/octet-stream").replace(/[\r\n]/g,"");o+=`Content-Type: ${i}${an}`}this.headers=Jo.encode(o+an),this.contentLength=n?t.byteLength:t.size,this.size=this.headers.byteLength+this.contentLength+MP,this.name=e,this.value=t}async*encode(){yield this.headers;let{value:e}=this;if(f.isTypedArray(e))yield e;else yield*Os(e);yield DP}static escapeName(e){return String(e).replace(/[\r\n"]/g,(t)=>({"\r":"%0D","\n":"%0A",'"':"%22"})[t])}}var LP=(e,t,r)=>{let{tag:n="form-data-boundary",size:o=25,boundary:i=n+"-"+ce.generateString(o,NP)}=r||{};if(!f.isFormData(e))throw TypeError("FormData instance required");if(i.length<1||i.length>70)throw Error("boundary must be 1-70 characters long");let s=Jo.encode("--"+i+an),a=Jo.encode("--"+i+"--"+an),c=a.byteLength,u=Array.from(e.entries()).map(([p,m])=>{let d=new zx(p,m);return c+=d.size,d});c+=s.byteLength*u.length,c=f.toFiniteNumber(c);let l={"Content-Type":`multipart/form-data; boundary=${i}`};if(Number.isFinite(c))l["Content-Length"]=c;return t&&t(l),jP.from(async function*(){for(let p of u)yield s,yield*p.encode();yield a}())},Ox=LP;import qP from"stream";class Ax extends qP.Transform{__transform(e,t,r){this.push(e),r()}_transform(e,t,r){if(e.length!==0){if(this._transform=this.__transform,e[0]!==120){let n=Buffer.alloc(2);n[0]=120,n[1]=156,this.push(n,t)}}this.__transform(e,t,r)}}var Cx=Ax;import UP from"http2";import FP from"util";class Ix{constructor(){this.sessions=Object.create(null)}getSession(e,t){t=Object.assign({sessionTimeout:1000},t);let r=this.sessions[e];if(r){let l=r.length;for(let p=0;p<l;p++){let[m,d]=r[p];if(!m.destroyed&&!m.closed&&FP.isDeepStrictEqual(d,t))return m}}let n=UP.connect(e,t),o,i,s=()=>{if(o)return;if(o=!0,i)clearTimeout(i),i=null;let l=r,p=l.length,m=p;while(m--)if(l[m][0]===n){if(p===1)delete this.sessions[e];else l.splice(m,1);if(!n.closed)n.close();return}},a=n.request,{sessionTimeout:c}=t;if(c!=null){let l=0;n.request=function(){let p=a.apply(this,arguments);if(l++,i)clearTimeout(i),i=null;return p.once("close",()=>{if(!--l)i=setTimeout(()=>{i=null,s()},c)}),p}}n.once("close",s);let u=[n,t];return r?r.push(u):r=this.sessions[e]=[u],n}}var jx=Ix;var ZP=(e,t)=>f.isAsyncFn(e)?function(...r){let n=r.pop();e.apply(this,r).then((o)=>{try{t?n(null,...t(o)):n(null,o)}catch(i){n(i)}},n)}:e,Nx=ZP;var BP=new Set(["localhost","0.0.0.0"]),Lx=(e)=>{let t=e.split(".");if(t.length!==4)return!1;if(t[0]!=="127")return!1;return t.every((r)=>/^\d+$/.test(r)&&Number(r)>=0&&Number(r)<=255)},Ku=(e)=>/^0{1,4}$/.test(e),HP=(e)=>{if(e==="::")return!0;let t=e.indexOf("::");if(t!==-1){if(t!==e.lastIndexOf("::"))return!1;let n=e.slice(0,t),o=e.slice(t+2),i=n?n.split(":"):[],s=o?o.split(":"):[];return i.length+s.length<8&&i.every(Ku)&&s.every(Ku)}let r=e.split(":");return r.length===8&&r.every(Ku)},VP=(e)=>{if(e==="::1")return!0;let t=e.match(/^::ffff:(\d+\.\d+\.\d+\.\d+)$/i);if(t)return Lx(t[1]);let r=e.match(/^::ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i);if(r){let o=parseInt(r[1],16);return o>=32512&&o<=32767}let n=e.split(":");if(n.length===8){for(let o=0;o<7;o++)if(!/^0+$/.test(n[o]))return!1;return/^0*1$/.test(n[7])}return!1},Dx=(e)=>{if(!e)return!1;if(BP.has(e))return!0;if(Lx(e))return!0;if(HP(e))return!0;return VP(e)},GP={http:80,https:443,ws:80,wss:443,ftp:21},JP=(e)=>{let t=e,r=0;if(t.charAt(0)==="["){let i=t.indexOf("]");if(i!==-1){let s=t.slice(1,i),a=t.slice(i+1);if(a.charAt(0)===":"&&/^\d+$/.test(a.slice(1)))r=Number.parseInt(a.slice(1),10);return[s,r]}}let n=t.indexOf(":"),o=t.lastIndexOf(":");if(n!==-1&&n===o&&/^\d+$/.test(t.slice(o+1)))r=Number.parseInt(t.slice(o+1),10),t=t.slice(0,o);return[t,r]},WP=/^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:(\d+\.\d+\.\d+\.\d+)$/i,KP=/^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i,YP=(e)=>{if(typeof e!=="string"||e.indexOf(":")===-1)return e;let t=e.match(WP);if(t)return t[1];let r=e.match(KP);if(r){let n=parseInt(r[1],16),o=parseInt(r[2],16);return`${n>>8}.${n&255}.${o>>8}.${o&255}`}return e},Mx=(e)=>{if(!e)return e;if(e.charAt(0)==="["&&e.charAt(e.length-1)==="]")e=e.slice(1,-1);return YP(e.replace(/\.+$/,""))};function Yu(e){let t;try{t=new URL(e)}catch(i){return!1}let r=(process.env.no_proxy||process.env.NO_PROXY||"").toLowerCase();if(!r)return!1;if(r==="*")return!0;let n=Number.parseInt(t.port,10)||GP[t.protocol.split(":",1)[0]]||0,o=Mx(t.hostname.toLowerCase());return r.split(/[\s,]+/).some((i)=>{if(!i)return!1;let[s,a]=JP(i);if(s=Mx(s),!s)return!1;if(a&&a!==n)return!1;if(s.charAt(0)==="*")s=s.slice(1);if(s.charAt(0)===".")return o.endsWith(s);return o===s||Dx(o)&&Dx(s)})}function XP(e,t){e=e||10;let r=Array(e),n=Array(e),o=0,i=0,s;return t=t!==void 0?t:1000,function(c){let u=Date.now(),l=n[i];if(!s)s=u;r[o]=c,n[o]=u;let p=i,m=0;while(p!==o)m+=r[p++],p=p%e;if(o=(o+1)%e,o===i)i=(i+1)%e;if(u-s<t)return;let d=l&&u-l;return d?Math.round(m*1000/d):void 0}}var qx=XP;function QP(e,t){let r=0,n=1000/t,o,i,s=(u,l=Date.now())=>{if(r=l,o=null,i)clearTimeout(i),i=null;e(...u)};return[(...u)=>{let l=Date.now(),p=l-r;if(p>=n)s(u,l);else if(o=u,!i)i=setTimeout(()=>{i=null,s(o)},n-p)},()=>o&&s(o)]}var Ux=QP;var lr=(e,t,r=3)=>{let n=0,o=qx(50,250);return Ux((i)=>{if(!i||typeof i.loaded!=="number")return;let s=i.loaded,a=i.lengthComputable?i.total:void 0,c=a!=null?Math.min(s,a):s,u=Math.max(0,c-n),l=o(u);n=Math.max(n,c);let p={loaded:c,total:a,progress:a?c/a:void 0,bytes:u,rate:l?l:void 0,estimated:l&&a?(a-c)/l:void 0,event:i,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(p)},r)},Un=(e,t)=>{let r=e!=null;return[(n)=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},Fn=(e)=>(...t)=>f.asap(()=>e(...t));var As=(e)=>e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102,ez=(e,t,r)=>t+2<r&&As(e.charCodeAt(t+1))&&As(e.charCodeAt(t+2));function Wo(e){if(!e||typeof e!=="string")return 0;if(!e.startsWith("data:"))return 0;let t=e.indexOf(",");if(t<0)return 0;let r=e.slice(5,t),n=e.slice(t+1);if(/;base64/i.test(r)){let{length:s,length:a}=n;for(let d=0;d<a;d++)if(n.charCodeAt(d)===37&&d+2<a){let h=n.charCodeAt(d+1),x=n.charCodeAt(d+2);if(As(h)&&As(x))s-=2,d+=2}let c=0,u=a-1,l=(d)=>d>=2&&n.charCodeAt(d-2)===37&&n.charCodeAt(d-1)===51&&(n.charCodeAt(d)===68||n.charCodeAt(d)===100);if(u>=0){if(n.charCodeAt(u)===61)c++,u--;else if(l(u))c++,u-=3}if(c===1&&u>=0){if(n.charCodeAt(u)===61)c++;else if(l(u))c++}let m=Math.floor(s/4)*3-(c||0);return m>0?m:0}let i=0;for(let s=0,a=n.length;s<a;s++){let c=n.charCodeAt(s);if(c===37&&ez(n,s,a))i+=1,s+=2;else if(c<128)i+=1;else if(c<2048)i+=2;else if(c>=55296&&c<=56319&&s+1<a){let u=n.charCodeAt(s+1);if(u>=56320&&u<=57343)i+=4,s++;else i+=3}else i+=3}return i}var Zx={flush:At.constants.Z_SYNC_FLUSH,finishFlush:At.constants.Z_SYNC_FLUSH},sz={flush:At.constants.BROTLI_OPERATION_FLUSH,finishFlush:At.constants.BROTLI_OPERATION_FLUSH},az={flush:At.constants.ZSTD_e_flush,finishFlush:At.constants.ZSTD_e_flush},Yx=f.isFunction(At.createBrotliDecompress),Xx=f.isFunction(At.createZstdDecompress),Qx="gzip, compress, deflate"+(Yx?", br":""),cz=Qx+(Xx?", zstd":""),{http:uz,https:lz}=Kx.default,ev=/https:?/,pz=["content-type","content-length"];function dz(e,t,r){if(r!=="content-only"){e.set(t);return}Object.entries(t).forEach(([n,o])=>{if(pz.includes(n.toLowerCase()))e.set(n,o)})}var Bx=Symbol("axios.http.socketListener"),Cs=Symbol("axios.http.currentReq"),tv=Symbol("axios.http.installedTunnel"),mz=new Map,Hx=new WeakMap;function fz(e,t){let r=e.protocol+"//"+e.hostname+":"+(e.port||"")+"#"+(e.auth||""),n=t?Hx.get(t)||Hx.set(t,new Map).get(t):mz,o=n.get(r);if(o)return o;let i=t&&t.options?{...t.options,...e}:e;if(o=new Xu.default(i),t&&t.options){let s={...t.options},a=o.callback;o.callback=function(u,l){return a.call(this,u,{...s,...l})}}return o[tv]=!0,n.set(r,o),o}var Vx=ce.protocols.map((e)=>e+":"),Gx=(e)=>{if(!f.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},Jx=(e,[t,r])=>(e.on("end",r).on("error",r),t),hz=new jx;function gz(e,t,r){if(e.beforeRedirects.proxy)e.beforeRedirects.proxy(e);if(e.beforeRedirects.auth)e.beforeRedirects.auth(e);if(e.beforeRedirects.sensitiveHeaders)e.beforeRedirects.sensitiveHeaders(e,r);if(e.beforeRedirects.config)e.beforeRedirects.config(e,t,r)}function xz(e,t){if(!e)return;Object.keys(e).forEach((r)=>{if(t.has(r.toLowerCase()))delete e[r]})}function vz(e,t){if(!t)return!1;try{return new URL(t.url).origin===new URL(e.href).origin}catch(r){return!1}}function rv(e,t,r,n,o){let i=t;if(!i&&i!==!1){let s=Kg(r);if(s){if(!Yu(r))i=new URL(s)}}if(n&&e.headers){for(let s of Object.keys(e.headers))if(s.toLowerCase()==="proxy-authorization")delete e.headers[s]}if(n&&e.agent&&e.agent[tv])e.agent=void 0;if(i){let s=i instanceof URL,a=(m)=>s||f.hasOwnProp(i,m)?i[m]:void 0,c=a("username"),u=a("password"),l=f.hasOwnProp(i,"auth")?i.auth:void 0;if(c)l=(c||"")+":"+(u||"");if(l){let m=typeof l==="object",d=m&&f.hasOwnProp(l,"username")?l.username:void 0,h=m&&f.hasOwnProp(l,"password")?l.password:void 0;if(Boolean(d||h))l=(d||"")+":"+(h||"");else if(m)throw new S("Invalid proxy authorization",S.ERR_BAD_OPTION,{proxy:i})}if(ev.test(e.protocol)){if(!(o instanceof Xu.default)){let m=a("hostname")||a("host"),d=a("port"),h=a("protocol"),x=h?h.includes(":")?h:`${h}:`:"http:",v=m&&m.includes(":")&&!m.startsWith("[")?`[${m}]`:m,g=new URL(`${x}//${v}${d?":"+d:""}`),y={protocol:g.protocol,hostname:g.hostname.replace(/^\[|\]$/g,""),port:g.port,auth:l&&typeof l==="string"?l:void 0};if(g.protocol==="https:")y.ALPNProtocols=["http/1.1"];let w=fz(y,o);if(e.agent=w,e.agents)e.agents.https=w}}else{if(l){let x=Buffer.from(l,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+x}let m=!1;for(let x of Object.keys(e.headers))if(x.toLowerCase()==="host"){m=!0;break}if(!m)e.headers.host=e.hostname+(e.port?":"+e.port:"");let d=a("hostname")||a("host");e.hostname=d,e.host=d,e.port=a("port"),e.path=r;let h=a("protocol");if(h)e.protocol=h.includes(":")?h:`${h}:`}}e.beforeRedirects.proxy=function(a){rv(a,t,a.href,!0,o)}}var yz=typeof process<"u"&&f.kindOf(process)==="process",bz=(e)=>new Promise((t,r)=>{let n,o,i=(c,u)=>{if(o)return;o=!0,n&&n(c,u)},s=(c)=>{i(c),t(c)},a=(c)=>{i(c,!0),r(c)};e(s,a,(c)=>n=c).catch(a)}),_z=({address:e,family:t})=>{if(!f.isString(e))throw TypeError("address must be a string");return{address:e,family:t||(e.indexOf(".")<0?6:4)}},Wx=(e,t)=>_z(f.isObject(e)?e:{address:e,family:t}),wz={request(e,t){let r=e.protocol+"//"+e.hostname+":"+(e.port||(e.protocol==="https:"?443:80)),{http2Options:n,headers:o}=e,i=hz.getSession(r,n),{HTTP2_HEADER_SCHEME:s,HTTP2_HEADER_METHOD:a,HTTP2_HEADER_PATH:c,HTTP2_HEADER_STATUS:u}=nz.constants,l={[s]:e.protocol.replace(":",""),[a]:e.method,[c]:e.path};f.forEach(o,(m,d)=>{d.charAt(0)!==":"&&(l[d]=m)});let p=i.request(l);return p.once("response",(m)=>{let d=p;m=Object.assign({},m);let h=m[u];delete m[u],d.headers=m,d.statusCode=+h,t(d)}),p}},nv=yz&&function(t){return bz(async function(n,o,i){let s=(T)=>f.getSafeProp(t,T),a=s("transitional")||Er,c=s("data"),u=s("lookup"),l=s("family"),p=s("httpVersion");if(p===void 0)p=1;let m=s("http2Options"),d=s("responseType"),h=s("responseEncoding"),x=s("httpAgent"),v=s("httpsAgent"),g=s("method").toUpperCase(),y=s("maxRedirects"),w=s("maxBodyLength"),P=s("maxContentLength"),I=s("decompress"),H,me=!1,K,dt;if(p=+p,Number.isNaN(p))throw TypeError(`Invalid protocol version: '${t.httpVersion}' is not a number`);if(p!==1&&p!==2)throw TypeError(`Unsupported protocol version '${p}'`);let rt=p===2;if(u){let T=Nx(u,(O)=>f.isArray(O)?O:[O]);u=(O,G,pe)=>{T(O,G,(X,qe,Ae)=>{if(X)return pe(X);let De=f.isArray(qe)?qe.map(($n)=>Wx($n)):[Wx(qe,Ae)];G.all?pe(X,De):pe(X,De[0].address,De[0].family)})}}let He=new iz;function Ke(T){try{He.emit("abort",!T||T.type?new kt(null,t,K):T)}catch(O){}}function tr(){if(dt)clearTimeout(dt),dt=null}function mt(){let T=s("timeout"),O=T?"timeout of "+T+"ms exceeded":"timeout exceeded",G=s("timeoutErrorMessage");if(G)O=G;return new S(O,a.clarifyTimeoutError?S.ETIMEDOUT:S.ECONNABORTED,t,K)}He.once("abort",o);let wr=()=>{if(tr(),t.cancelToken)t.cancelToken.unsubscribe(Ke);if(t.signal)t.signal.removeEventListener("abort",Ke);He.removeAllListeners()};if(t.cancelToken||t.signal){if(t.cancelToken&&t.cancelToken.subscribe(Ke),t.signal)t.signal.aborted?Ke():t.signal.addEventListener("abort",Ke)}i((T,O)=>{if(H=!0,tr(),O){me=!0,wr();return}let{data:G}=T;if(G instanceof Bt.Readable||G instanceof Bt.Duplex){let pe=Bt.finished(G,()=>{pe(),wr()})}else wr()});let kr=en(s("baseURL"),s("url"),s("allowAbsoluteUrls"),t),Fe=new URL(kr,ce.hasBrowserEnv?ce.origin:void 0),Vr=Fe.protocol||Vx[0];if(Vr==="data:"){if(P>-1){let O=String(s("url")||kr||"");if(Wo(O)>P)return o(new S("maxContentLength size of "+P+" exceeded",S.ERR_BAD_RESPONSE,t))}let T;if(g!=="GET")return nr(n,o,{status:405,statusText:"method not allowed",headers:{},config:t});try{T=Gu(s("url"),d==="blob",{Blob:t.env&&t.env.Blob})}catch(O){throw S.from(O,S.ERR_BAD_REQUEST,t)}if(d==="text"){if(T=T.toString(h),!h||h==="utf8")T=f.stripBOM(T)}else if(d==="stream")T=Bt.Readable.from(T);return nr(n,o,{data:T,status:200,statusText:"OK",headers:new be,config:t})}if(Vx.indexOf(Vr)===-1)return o(new S("Unsupported protocol "+Vr,S.ERR_BAD_REQUEST,t));let nt=be.from(t.headers).normalize();nt.set("User-Agent","axios/"+ur,!1);let{onUploadProgress:Rt,onDownloadProgress:Ne}=t,Pt=t.maxRate,Ut=void 0,rr=void 0;if(f.isSpecCompliantForm(c)){let T=nt.getContentType(/boundary=([-_\w\d]{10,70})/i);c=Ox(c,(O)=>{nt.set(O)},{tag:`axios-${ur}-boundary`,boundary:T&&T[1]||void 0})}else if(f.isFormData(c)&&f.isFunction(c.getHeaders)&&c.getHeaders!==Object.prototype.getHeaders){if(dz(nt,c.getHeaders(),s("formDataHeaderPolicy")),!nt.hasContentLength())try{let T=await oz.promisify(c.getLength).call(c);Number.isFinite(T)&&T>=0&&nt.setContentLength(T)}catch(T){}}else if(f.isBlob(c)||f.isFile(c))c.size&&nt.setContentType(c.type||"application/octet-stream"),nt.setContentLength(c.size||0),c=Bt.Readable.from(Os(c));else if(c&&!f.isStream(c)){if(Buffer.isBuffer(c));else if(f.isArrayBuffer(c))c=Buffer.from(new Uint8Array(c));else if(f.isString(c))c=Buffer.from(c,"utf-8");else return o(new S("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",S.ERR_BAD_REQUEST,t));if(nt.setContentLength(c.length,!1),w>-1&&c.length>w)return o(new S("Request body larger than maxBodyLength limit",S.ERR_BAD_REQUEST,t))}let cs=f.toFiniteNumber(nt.getContentLength());if(f.isArray(Pt))Ut=Pt[0],rr=Pt[1];else Ut=rr=Pt;if(c&&(Rt||Ut)){if(!f.isStream(c))c=Bt.Readable.from(c,{objectMode:!1});c=Bt.pipeline([c,new Wu({maxRate:f.toFiniteNumber(Ut)})],f.noop),Rt&&c.on("progress",Jx(c,Un(cs,lr(Fn(Rt),!1,3))))}let ee=void 0,_t=s("auth");if(_t){let T=f.getSafeProp(_t,"username")||"",O=f.getSafeProp(_t,"password")||"";ee=T+":"+O}if(!ee&&(Fe.username||Fe.password)){let T=Gx(Fe.username),O=Gx(Fe.password);ee=T+":"+O}ee&&nt.delete("authorization");let Gr;try{Gr=Qr(Fe.pathname+Fe.search,s("params"),s("paramsSerializer")).replace(/^\?/,"")}catch(T){let O=Error(T.message);return O.config=t,O.url=s("url"),O.exists=!0,o(O)}nt.set("Accept-Encoding",f.hasOwnProp(a,"advertiseZstdAcceptEncoding")&&a.advertiseZstdAcceptEncoding===!0?cz:Qx,!1);let Oe=Object.assign(Object.create(null),{path:Gr,method:g,headers:zn(nt),agents:{http:x,https:v},auth:ee,protocol:Vr,family:l,beforeRedirect:gz,beforeRedirects:Object.create(null),http2Options:m});!f.isUndefined(u)&&(Oe.lookup=u);let Jr=s("socketPath");if(Jr){if(typeof Jr!=="string")return o(new S("socketPath must be a string",S.ERR_BAD_OPTION_VALUE,t));let T=s("allowedSocketPaths");if(T!=null){let O=Array.isArray(T)?T:[T],G=Fx(Jr);if(!O.some((X)=>typeof X==="string"&&Fx(X)===G))return o(new S(`socketPath "${Jr}" is not permitted by allowedSocketPaths`,S.ERR_BAD_OPTION_VALUE,t))}Oe.socketPath=Jr}else Oe.hostname=Fe.hostname.startsWith("[")?Fe.hostname.slice(1,-1):Fe.hostname,Oe.port=Fe.port,rv(Oe,s("proxy"),Vr+"//"+Fe.hostname+(Fe.port?":"+Fe.port:"")+Oe.path,!1,v);let Sr,zt=!1,wo=!1,Wr=ev.test(Oe.protocol);if(Oe.agent==null)Oe.agent=Wr?v:x;if(rt)Sr=wz;else{let T=s("transport");if(T)Sr=T;else if(y===0)Sr=Wr?rz:tz,zt=!0;else{if(wo=!0,Oe.sensitiveHeaders=[],y)Oe.maxRedirects=y;let O=s("beforeRedirect");if(O)Oe.beforeRedirects.config=O;if(ee){let pe=Fe.origin,X=ee;Oe.beforeRedirects.auth=function(Ae){try{if(new URL(Ae.href).origin===pe)Ae.auth=X}catch(De){}}}let G=s("sensitiveHeaders");if(G!=null){if(!f.isArray(G))return o(new S("sensitiveHeaders must be an array of strings",S.ERR_BAD_OPTION_VALUE,t));let pe=new Set;for(let X of G){if(!f.isString(X))return o(new S("sensitiveHeaders must be an array of strings",S.ERR_BAD_OPTION_VALUE,t));pe.add(X.toLowerCase())}if(pe.size)Oe.sensitiveHeaders=Array.from(pe),Oe.beforeRedirects.sensitiveHeaders=function(qe,Ae){if(!vz(qe,Ae))xz(qe.headers,pe)}}Sr=Wr?lz:uz}}if(w>-1)Oe.maxBodyLength=w;else Oe.maxBodyLength=1/0;Oe.insecureHTTPParser=Boolean(s("insecureHTTPParser")),K=Sr.request(Oe,function(O){if(tr(),K.destroyed)return;let G=[O],pe=f.toFiniteNumber(O.headers["content-length"]);if(Ne||rr){let De=new Wu({maxRate:f.toFiniteNumber(rr)});Ne&&De.on("progress",Jx(De,Un(pe,lr(Fn(Ne),!0,3)))),G.push(De)}let X=O,qe=O.req||K;if(I!==!1&&O.headers["content-encoding"]){if(g==="HEAD"||O.statusCode===204)delete O.headers["content-encoding"];switch((O.headers["content-encoding"]||"").toLowerCase()){case"gzip":case"x-gzip":case"compress":case"x-compress":G.push(At.createUnzip(Zx)),delete O.headers["content-encoding"];break;case"deflate":G.push(new Cx),G.push(At.createUnzip(Zx)),delete O.headers["content-encoding"];break;case"br":if(Yx)G.push(At.createBrotliDecompress(sz)),delete O.headers["content-encoding"];break;case"zstd":if(Xx)G.push(At.createZstdDecompress(az)),delete O.headers["content-encoding"];break}}X=G.length>1?Bt.pipeline(G,f.noop):G[0];let Ae={status:O.statusCode,statusText:O.statusMessage,headers:new be(O.headers),config:t,request:qe};if(d==="stream"){if(P>-1){let De=P,$n=X;async function*ko(){let Ve=0;for await(let xf of $n){if(Ve+=xf.length,Ve>De)throw new S("maxContentLength size of "+De+" exceeded",S.ERR_BAD_RESPONSE,t,qe);yield xf}}X=Bt.Readable.from(ko(),{objectMode:!1})}Ae.data=X,nr(n,o,Ae)}else{let De=[],$n=0;X.on("data",function(Ve){if(De.push(Ve),$n+=Ve.length,P>-1&&$n>P)me=!0,X.destroy(),Ke(new S("maxContentLength size of "+P+" exceeded",S.ERR_BAD_RESPONSE,t,qe))}),X.on("aborted",function(){if(me)return;let Ve=new S("stream has been aborted",S.ERR_BAD_RESPONSE,t,qe,Ae);X.destroy(Ve),o(Ve)}),X.on("error",function(Ve){if(me)return;o(S.from(Ve,null,t,qe,Ae))}),X.on("end",function(){try{let Ve=De.length===1?De[0]:Buffer.concat(De);if(d!=="arraybuffer"){if(Ve=Ve.toString(h),!h||h==="utf8")Ve=f.stripBOM(Ve)}Ae.data=Ve}catch(Ve){return o(S.from(Ve,null,t,Ae.request,Ae))}nr(n,o,Ae)})}He.once("abort",(De)=>{if(!X.destroyed)X.emit("error",De),X.destroy()})}),He.once("abort",(T)=>{if(K.close)K.close();else K.destroy(T)}),K.on("error",function(O){o(S.from(O,null,t,K))});let wt=new Set;if(K.on("socket",function(O){if(O.setKeepAlive(!0,60000),!O[Bx])O.on("error",function(pe){let X=O[Cs];if(X&&!X.destroyed)X.destroy(pe)}),O[Bx]=!0;O[Cs]=K,wt.add(O)}),K.once("close",function(){tr();for(let O of wt)if(O[Cs]===K)O[Cs]=null;wt.clear()}),s("timeout")){let T=parseInt(s("timeout"),10);if(Number.isNaN(T)){Ke(new S("error trying to parse `config.timeout` to int",S.ERR_BAD_OPTION_VALUE,t,K));return}let O=function(){if(H)return;Ke(mt())};if(zt&&T>0)dt=setTimeout(O,T);K.setTimeout(T,O)}else K.setTimeout(0);if(f.isStream(c)){let T=!1,O=!1;c.on("end",()=>{T=!0}),c.once("error",(pe)=>{O=!0,K.destroy(pe)}),c.on("close",()=>{if(!T&&!O)Ke(new kt("Request stream has been aborted",t,K))});let G=c;if(w>-1&&!wo){let pe=w,X=0;G=Bt.pipeline([c,new Bt.Transform({transform(qe,Ae,De){if(X+=qe.length,X>pe)return De(new S("Request body larger than maxBodyLength limit",S.ERR_BAD_REQUEST,t,K));De(null,qe)}})],f.noop),G.on("error",(qe)=>{if(!K.destroyed)K.destroy(qe)})}G.pipe(K)}else c&&K.write(c),K.end()})};var ov=ce.hasStandardBrowserEnv?((e,t)=>(r)=>(r=new URL(r,ce.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(ce.origin),ce.navigator&&/(msie|trident)/i.test(ce.navigator.userAgent)):()=>!0;var iv=ce.hasStandardBrowserEnv?{write(e,t,r,n,o,i,s){if(typeof document>"u")return;let a=[`${e}=${encodeURIComponent(t)}`];if(f.isNumber(r))a.push(`expires=${new Date(r).toUTCString()}`);if(f.isString(n))a.push(`path=${n}`);if(f.isString(o))a.push(`domain=${o}`);if(i===!0)a.push("secure");if(f.isString(s))a.push(`SameSite=${s}`);document.cookie=a.join("; ")},read(e){if(typeof document>"u")return null;let t=document.cookie.split(";");for(let r=0;r<t.length;r++){let n=t[r].replace(/^\s+/,""),o=n.indexOf("=");if(o!==-1&&n.slice(0,o)===e)return decodeURIComponent(n.slice(o+1))}return null},remove(e){this.write(e,"",Date.now()-86400000,"/")}}:{write(){},read(){return null},remove(){}};var sv=(e)=>e instanceof be?{...e}:e;function Ht(e,t){t=t||{};let r=Object.create(null);Object.defineProperty(r,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function n(l,p,m,d){if(f.isPlainObject(l)&&f.isPlainObject(p))return f.merge.call({caseless:d},l,p);else if(f.isPlainObject(p))return f.merge({},p);else if(f.isArray(p))return p.slice();return p}function o(l,p,m,d){if(!f.isUndefined(p))return n(l,p,m,d);else if(!f.isUndefined(l))return n(void 0,l,m,d)}function i(l,p){if(!f.isUndefined(p))return n(void 0,p)}function s(l,p){if(!f.isUndefined(p))return n(void 0,p);else if(!f.isUndefined(l))return n(void 0,l)}function a(l){let p=f.hasOwnProp(t,"transitional")?t.transitional:void 0;if(!f.isUndefined(p))if(f.isPlainObject(p)){if(f.hasOwnProp(p,l))return p[l]}else return;let m=f.hasOwnProp(e,"transitional")?e.transitional:void 0;if(f.isPlainObject(m)&&f.hasOwnProp(m,l))return m[l];return}function c(l,p,m){if(f.hasOwnProp(t,m))return n(l,p);else if(f.hasOwnProp(e,m))return n(void 0,l)}let u={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,allowedSocketPaths:s,responseEncoding:s,validateStatus:c,headers:(l,p,m)=>o(sv(l),sv(p),m,!0)};if(f.forEach(Object.keys({...e,...t}),function(p){if(p==="__proto__"||p==="constructor"||p==="prototype")return;let m=f.hasOwnProp(u,p)?u[p]:o,d=f.hasOwnProp(e,p)?e[p]:void 0,h=f.hasOwnProp(t,p)?t[p]:void 0,x=m(d,h,p);f.isUndefined(x)&&m!==c||(r[p]=x)}),f.hasOwnProp(t,"validateStatus")&&f.isUndefined(t.validateStatus)&&a("validateStatusUndefinedResolves")===!1)if(f.hasOwnProp(e,"validateStatus"))r.validateStatus=n(void 0,e.validateStatus);else delete r.validateStatus;return r}var kz=["content-type","content-length"];function Sz(e,t,r){if(r!=="content-only"){e.set(t);return}Object.entries(t).forEach(([n,o])=>{if(kz.includes(n.toLowerCase()))e.set(n,o)})}var $z=(e)=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,r)=>String.fromCharCode(parseInt(r,16)));function Tz(e){let t=Ht({},e),r=(m)=>f.hasOwnProp(t,m)?t[m]:void 0,n=r("data"),o=r("withXSRFToken"),i=r("xsrfHeaderName"),s=r("xsrfCookieName"),a=r("headers"),c=r("auth"),u=r("baseURL"),l=r("allowAbsoluteUrls"),p=r("url");if(t.headers=a=be.from(a),t.url=Qr(en(u,p,l,t),r("params"),r("paramsSerializer")),c){let m=f.getSafeProp(c,"username")||"",d=f.getSafeProp(c,"password")||"";a.set("Authorization","Basic "+btoa(m+":"+(d?$z(d):"")))}if(f.isFormData(n)){if(ce.hasStandardBrowserEnv||ce.hasStandardBrowserWebWorkerEnv||f.isReactNative(n))a.setContentType(void 0);else if(f.isFunction(n.getHeaders))Sz(a,n.getHeaders(),r("formDataHeaderPolicy"))}if(ce.hasStandardBrowserEnv){if(f.isFunction(o))o=o(t);if(o===!0||o==null&&ov(t.url)){let d=i&&s&&iv.read(s);if(d)a.set(i,d)}}return t}var Is=Tz;var Ez=typeof XMLHttpRequest<"u",av=Ez&&function(e){return new Promise(function(r,n){let o=Is(e),i=o.data,s=be.from(o.headers).normalize(),{responseType:a,onUploadProgress:c,onDownloadProgress:u}=o,l,p,m,d,h;function x(){d&&d(),h&&h(),o.cancelToken&&o.cancelToken.unsubscribe(l),o.signal&&o.signal.removeEventListener("abort",l)}let v=new XMLHttpRequest;v.open(o.method.toUpperCase(),o.url,!0),v.timeout=o.timeout;function g(){if(!v)return;let w=be.from("getAllResponseHeaders"in v&&v.getAllResponseHeaders()),I={data:!a||a==="text"||a==="json"?v.responseText:v.response,status:v.status,statusText:v.statusText,headers:w,config:e,request:v};nr(function(me){r(me),x()},function(me){n(me),x()},I),v=null}if("onloadend"in v)v.onloadend=g;else v.onreadystatechange=function(){if(!v||v.readyState!==4)return;if(v.status===0&&!(v.responseURL&&v.responseURL.startsWith("file:")))return;setTimeout(g)};if(v.onabort=function(){if(!v)return;n(new S("Request aborted",S.ECONNABORTED,e,v)),x(),v=null},v.onerror=function(P){let I=P&&P.message?P.message:"Network Error",H=new S(I,S.ERR_NETWORK,e,v);H.event=P||null,n(H),x(),v=null},v.ontimeout=function(){let P=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded",I=o.transitional||Er;if(o.timeoutErrorMessage)P=o.timeoutErrorMessage;n(new S(P,I.clarifyTimeoutError?S.ETIMEDOUT:S.ECONNABORTED,e,v)),x(),v=null},i===void 0&&s.setContentType(null),"setRequestHeader"in v)f.forEach(zn(s),function(P,I){v.setRequestHeader(I,P)});if(!f.isUndefined(o.withCredentials))v.withCredentials=!!o.withCredentials;if(a&&a!=="json")v.responseType=o.responseType;if(u)[m,h]=lr(u,!0),v.addEventListener("progress",m);if(c&&v.upload)[p,d]=lr(c),v.upload.addEventListener("progress",p),v.upload.addEventListener("loadend",d);if(o.cancelToken||o.signal){if(l=(w)=>{if(!v)return;n(!w||w.type?new kt(null,e,v):w),v.abort(),x(),v=null},o.cancelToken&&o.cancelToken.subscribe(l),o.signal)o.signal.aborted?l():o.signal.addEventListener("abort",l)}let y=Go(o.url);if(y&&!ce.protocols.includes(y)){n(new S("Unsupported protocol "+y+":",S.ERR_BAD_REQUEST,e));return}v.send(i||null)})};var Rz=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;let r=new AbortController,n=!1,o=function(c){if(!n){n=!0,s();let u=c instanceof Error?c:this.reason;r.abort(u instanceof S?u:new kt(u instanceof Error?u.message:u))}},i=t&&setTimeout(()=>{i=null,o(new S(`timeout of ${t}ms exceeded`,S.ETIMEDOUT))},t),s=()=>{if(!e)return;i&&clearTimeout(i),i=null,e.forEach((c)=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null};e.forEach((c)=>c.addEventListener("abort",o));let{signal:a}=r;return a.unsubscribe=()=>f.asap(s),a},cv=Rz;var Pz=function*(e,t){let r=e.byteLength;if(!t||r<t){yield e;return}let n=0,o;while(n<r)o=n+t,yield e.slice(n,o),n=o},zz=async function*(e,t){for await(let r of Oz(e))yield*Pz(r,t)},Oz=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}let t=e.getReader();try{for(;;){let{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},Qu=(e,t,r,n)=>{let o=zz(e,t),i=0,s,a=(c)=>{if(!s)s=!0,n&&n(c)};return new ReadableStream({async pull(c){try{let{done:u,value:l}=await o.next();if(u){a(),c.close();return}let p=l.byteLength;if(r){let m=i+=p;r(m)}c.enqueue(new Uint8Array(l))}catch(u){throw a(u),u}},cancel(c){return a(c),o.return()}},{highWaterMark:2})};var uv=65536,{isFunction:js}=f,Az=(e)=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,r)=>String.fromCharCode(parseInt(r,16))),lv=(e)=>{if(!f.isString(e))return e;try{return decodeURIComponent(e)}catch(t){return e}},pv=(e,...t)=>{try{return!!e(...t)}catch(r){return!1}},Cz=(e)=>{let t=e.indexOf("://"),r=e;if(t!==-1)r=r.slice(t+3);return r.includes("@")||r.includes(":")},Iz=(e)=>{let t=f.global!==void 0&&f.global!==null?f.global:globalThis,{ReadableStream:r,TextEncoder:n}=t;e=f.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);let{fetch:o,Request:i,Response:s}=e,a=o?js(o):typeof fetch==="function",c=js(i),u=js(s);if(!a)return!1;let l=a&&js(r),p=a&&(typeof n==="function"?((g)=>(y)=>g.encode(y))(new n):async(g)=>new Uint8Array(await new i(g).arrayBuffer())),m=c&&l&&pv(()=>{let g=!1,y=new i(ce.origin,{body:new r,method:"POST",get duplex(){return g=!0,"half"}}),w=y.headers.has("Content-Type");if(y.body!=null)y.body.cancel();return g&&!w}),d=u&&l&&pv(()=>f.isReadableStream(new s("").body)),h={stream:d&&((g)=>g.body)};a&&(()=>{["text","arrayBuffer","blob","formData","stream"].forEach((g)=>{!h[g]&&(h[g]=(y,w)=>{let P=y&&y[g];if(P)return P.call(y);throw new S(`Response type '${g}' is not supported`,S.ERR_NOT_SUPPORT,w)})})})();let x=async(g)=>{if(g==null)return 0;if(f.isBlob(g))return g.size;if(f.isSpecCompliantForm(g))return(await new i(ce.origin,{method:"POST",body:g}).arrayBuffer()).byteLength;if(f.isArrayBufferView(g)||f.isArrayBuffer(g))return g.byteLength;if(f.isURLSearchParams(g))g=g+"";if(f.isString(g))return(await p(g)).byteLength},v=async(g,y)=>{let w=f.toFiniteNumber(g.getContentLength());return w==null?x(y):w};return async(g)=>{let{url:y,method:w,data:P,signal:I,cancelToken:H,timeout:me,onDownloadProgress:K,onUploadProgress:dt,responseType:rt,headers:He,withCredentials:Ke="same-origin",fetchOptions:tr,maxContentLength:mt,maxBodyLength:wr}=Is(g),kr=f.isNumber(mt)&&mt>-1,Fe=f.isNumber(wr)&&wr>-1,Vr=(ee)=>f.hasOwnProp(g,ee)?g[ee]:void 0,nt=o||fetch;rt=rt?(rt+"").toLowerCase():"text";let Rt=cv([I,H&&H.toAbortSignal()],me),Ne=null,Pt=Rt&&Rt.unsubscribe&&(()=>{Rt.unsubscribe()}),Ut,rr=null,cs=()=>new S("Request body larger than maxBodyLength limit",S.ERR_BAD_REQUEST,g,Ne);try{let ee=void 0,_t=Vr("auth");if(_t){let T=f.getSafeProp(_t,"username")||"",O=f.getSafeProp(_t,"password")||"";ee={username:T,password:O}}if(Cz(y)){let T=new URL(y,ce.origin);if(!ee&&(T.username||T.password)){let O=lv(T.username),G=lv(T.password);ee={username:O,password:G}}if(T.username||T.password)T.username="",T.password="",y=T.href}if(ee)He.delete("authorization"),He.set("Authorization","Basic "+btoa(Az((ee.username||"")+":"+(ee.password||""))));if(kr&&typeof y==="string"&&y.startsWith("data:")){if(Wo(y)>mt)throw new S("maxContentLength size of "+mt+" exceeded",S.ERR_BAD_RESPONSE,g,Ne)}if(Fe&&w!=="get"&&w!=="head"){let T=await x(P);if(typeof T==="number"&&isFinite(T)){if(Ut=T,T>wr)throw cs()}}let Gr=Fe&&(f.isReadableStream(P)||f.isStream(P)),Oe=(T,O,G)=>Qu(T,uv,(pe)=>{if(Fe&&pe>wr)throw rr=cs();O&&O(pe)},G);if(m&&w!=="get"&&w!=="head"&&(dt||Gr)){if(Ut=Ut==null?await v(He,P):Ut,Ut!==0||Gr){let T=new i(y,{method:"POST",body:P,duplex:"half"}),O;if(f.isFormData(P)&&(O=T.headers.get("content-type")))He.setContentType(O);if(T.body){let[G,pe]=dt&&Un(Ut,lr(Fn(dt)))||[];P=Oe(T.body,G,pe)}}}else if(Gr&&!c&&l&&w!=="get"&&w!=="head")P=Oe(P);else if(Gr&&c&&!m&&w!=="get"&&w!=="head")throw new S("Stream request bodies are not supported by the current fetch implementation",S.ERR_NOT_SUPPORT,g,Ne);if(!f.isString(Ke))Ke=Ke?"include":"omit";let Jr=c&&"credentials"in i.prototype;if(f.isFormData(P)){let T=He.getContentType();if(T&&/^multipart\/form-data/i.test(T)&&!/boundary=/i.test(T))He.delete("content-type")}He.set("User-Agent","axios/"+ur,!1);let Sr={...tr,signal:Rt,method:w.toUpperCase(),headers:zn(He.normalize()),body:P,duplex:"half",credentials:Jr?Ke:void 0};Ne=c&&new i(y,Sr);let zt=await(c?nt(Ne,tr):nt(y,Sr)),wo=be.from(zt.headers);if(kr){let T=f.toFiniteNumber(wo.getContentLength());if(T!=null&&T>mt)throw new S("maxContentLength size of "+mt+" exceeded",S.ERR_BAD_RESPONSE,g,Ne)}let Wr=d&&(rt==="stream"||rt==="response");if(d&&zt.body&&(K||kr||Wr&&Pt)){let T={};["status","statusText","headers"].forEach((Ae)=>{T[Ae]=zt[Ae]});let O=f.toFiniteNumber(wo.getContentLength()),[G,pe]=K&&Un(O,lr(Fn(K),!0))||[],X=0,qe=(Ae)=>{if(kr){if(X=Ae,X>mt)throw new S("maxContentLength size of "+mt+" exceeded",S.ERR_BAD_RESPONSE,g,Ne)}G&&G(Ae)};zt=new s(Qu(zt.body,uv,qe,()=>{pe&&pe(),Pt&&Pt()}),T)}rt=rt||"text";let wt=await h[f.findKey(h,rt)||"text"](zt,g);if(kr&&!d&&!Wr){let T;if(wt!=null){if(typeof wt.byteLength==="number")T=wt.byteLength;else if(typeof wt.size==="number")T=wt.size;else if(typeof wt==="string")T=typeof n==="function"?new n().encode(wt).byteLength:wt.length}if(typeof T==="number"&&T>mt)throw new S("maxContentLength size of "+mt+" exceeded",S.ERR_BAD_RESPONSE,g,Ne)}return!Wr&&Pt&&Pt(),await new Promise((T,O)=>{nr(T,O,{data:wt,headers:be.from(zt.headers),status:zt.status,statusText:zt.statusText,config:g,request:Ne})})}catch(ee){if(Pt&&Pt(),Rt&&Rt.aborted&&Rt.reason instanceof S){let _t=Rt.reason;throw _t.config=g,Ne&&(_t.request=Ne),ee!==_t&&(_t.cause=ee),_t}if(rr)throw Ne&&!rr.request&&(rr.request=Ne),rr;if(ee instanceof S)throw Ne&&!ee.request&&(ee.request=Ne),ee;if(ee&&ee.name==="TypeError"&&/Load failed|fetch/i.test(ee.message))throw Object.assign(new S("Network Error",S.ERR_NETWORK,g,Ne,ee&&ee.response),{cause:ee.cause||ee});throw S.from(ee,ee&&ee.code,g,Ne,ee&&ee.response)}}},jz=new Map,el=(e)=>{let t=e&&e.env||{},{fetch:r,Request:n,Response:o}=t,i=[n,o,r],s=i.length,a=s,c,u,l=jz;while(a--)c=i[a],u=l.get(c),u===void 0&&l.set(c,u=a?new Map:Iz(t)),l=u;return u},XB=el();var tl={http:nv,xhr:av,fetch:{get:el}};f.forEach(tl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(r){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});var dv=(e)=>`- ${e}`,Dz=(e)=>f.isFunction(e)||e===null||e===!1;function Mz(e,t){e=f.isArray(e)?e:[e];let{length:r}=e,n,o,i={};for(let s=0;s<r;s++){n=e[s];let a;if(o=n,!Dz(n)){if(o=tl[(a=String(n)).toLowerCase()],o===void 0)throw new S(`Unknown adapter '${a}'`)}if(o&&(f.isFunction(o)||(o=o.get(t))))break;i[a||"#"+s]=o}if(!o){let s=Object.entries(i).map(([c,u])=>`adapter ${c} `+(u===!1?"is not supported by the environment":"is not available in the build")),a=r?s.length>1?`since :
|
|
30
|
+
`+s.map(dv).join(`
|
|
31
|
+
`):" "+dv(s[0]):"as no adapter specified";throw new S("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return o}var Ns={getAdapter:Mz,adapters:tl};function rl(e){if(e.cancelToken)e.cancelToken.throwIfRequested();if(e.signal&&e.signal.aborted)throw new kt(null,e)}function Ds(e){if(rl(e),e.headers=be.from(e.headers),e.data=jo.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1)e.headers.setContentType("application/x-www-form-urlencoded",!1);return Ns.getAdapter(e.adapter||Nn.adapter,e)(e).then(function(n){rl(e),e.response=n;try{n.data=jo.call(e,e.transformResponse,n)}finally{delete e.response}return n.headers=be.from(n.headers),n},function(n){if(!No(n)){if(rl(e),n&&n.response){e.response=n.response;try{n.response.data=jo.call(e,e.transformResponse,n.response)}finally{delete e.response}n.response.headers=be.from(n.response.headers)}}return Promise.reject(n)})}var Ms={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Ms[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});var mv={};Ms.transitional=function(t,r,n){function o(i,s){return"[Axios v"+ur+"] Transitional option '"+i+"'"+s+(n?". "+n:"")}return(i,s,a)=>{if(t===!1)throw new S(o(s," has been removed"+(r?" in "+r:"")),S.ERR_DEPRECATED);if(r&&!mv[s])mv[s]=!0,console.warn(o(s," has been deprecated since v"+r+" and will be removed in the near future"));return t?t(i,s,a):!0}};Ms.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function Lz(e,t,r){if(typeof e!=="object")throw new S("options must be an object",S.ERR_BAD_OPTION_VALUE);let n=Object.keys(e),o=n.length;while(o-- >0){let i=n[o],s=Object.prototype.hasOwnProperty.call(t,i)?t[i]:void 0;if(s){let a=e[i],c=a===void 0||s(a,i,e);if(c!==!0)throw new S("option "+i+" must be "+c,S.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new S("Unknown option "+i,S.ERR_BAD_OPTION)}}var Ko={assertOptions:Lz,validators:Ms};var ot=Ko.validators;class Yo{constructor(e){this.defaults=e||{},this.interceptors={request:new fu,response:new fu}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let n={};Error.captureStackTrace?Error.captureStackTrace(n):n=Error();let o=(()=>{if(!n.stack)return"";let i=n.stack.indexOf(`
|
|
32
32
|
`);return i===-1?"":n.stack.slice(i+1)})();try{if(!r.stack)r.stack=o;else if(o){let i=o.indexOf(`
|
|
33
33
|
`),s=i===-1?-1:o.indexOf(`
|
|
34
34
|
`,i+1),a=s===-1?"":o.slice(s+1);if(!String(r.stack).endsWith(a))r.stack+=`
|
|
35
|
-
`+o}}catch(i){}}throw r}}_request(e,t){if(typeof e==="string")t=t||{},t.url=e;else t=e||{};t=Ut(this.defaults,t);let{transitional:r,paramsSerializer:n,headers:o}=t;if(r!==void 0)ci.assertOptions(r,{silentJSONParsing:nt.transitional(nt.boolean),forcedJSONParsing:nt.transitional(nt.boolean),clarifyTimeoutError:nt.transitional(nt.boolean),legacyInterceptorReqResOrdering:nt.transitional(nt.boolean),advertiseZstdAcceptEncoding:nt.transitional(nt.boolean),validateStatusUndefinedResolves:nt.transitional(nt.boolean)},!1);if(n!=null)if(f.isFunction(n))t.paramsSerializer={serialize:n};else ci.assertOptions(n,{encode:nt.function,serialize:nt.function},!0);if(t.allowAbsoluteUrls!==void 0);else if(this.defaults.allowAbsoluteUrls!==void 0)t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls;else t.allowAbsoluteUrls=!0;ci.assertOptions(t,{baseUrl:nt.spelling("baseURL"),withXsrfToken:nt.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&f.merge(o.common,o[t.method]);o&&f.forEach(["delete","get","head","post","put","patch","query","common"],(d)=>{delete o[d]}),t.headers=ye.concat(i,o);let s=[],a=!0;this.interceptors.request.forEach(function(h){if(typeof h.runWhen==="function"&&h.runWhen(t)===!1)return;a=a&&h.synchronous;let x=t.transitional||$r;if(x&&x.legacyInterceptorReqResOrdering)s.unshift(h.fulfilled,h.rejected);else s.push(h.fulfilled,h.rejected)});let c=[];this.interceptors.response.forEach(function(h){c.push(h.fulfilled,h.rejected)});let u,l=0,p;if(!a){let d=[Js.bind(this),void 0];d.unshift(...s),d.push(...c),p=d.length,u=Promise.resolve(t);while(l<p)u=u.then(d[l++],d[l++]);return u}p=s.length;let m=t;while(l<p){let d=s[l++],h=s[l++];try{m=d(m)}catch(x){h.call(this,x);break}}try{u=Js.call(this,m)}catch(d){return Promise.reject(d)}l=0,p=c.length;while(l<p)u=u.then(c[l++],c[l++]);return u}getUri(e){e=Ut(this.defaults,e);let t=rn(e.baseURL,e.url,e.allowAbsoluteUrls,e);return tn(t,e.params,e.paramsSerializer)}}f.forEach(["delete","get","head","options"],function(t){ui.prototype[t]=function(r,n){return this.request(Ut(n||{},{method:t,url:r,data:n&&f.hasOwnProp(n,"data")?n.data:void 0}))}});f.forEach(["post","put","patch","query"],function(t){function r(n){return function(i,s,a){return this.request(Ut(a||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:s}))}}if(ui.prototype[t]=r(),t!=="query")ui.prototype[t+"Form"]=r(!0)});var li=ui;class sl{constructor(e){if(typeof e!=="function")throw TypeError("executor must be a function.");let t;this.promise=new Promise(function(o){t=o});let r=this;this.promise.then((n)=>{if(!r._listeners)return;let o=r._listeners.length;while(o-- >0)r._listeners[o](n);r._listeners=null}),this.promise.then=(n)=>{let o,i=new Promise((s)=>{r.subscribe(s),o=s}).then(n);return i.cancel=function(){r.unsubscribe(o)},i},e(function(o,i,s){if(r.reason)return;r.reason=new wt(o,i,s),t(r.reason)})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}if(this._listeners)this._listeners.push(e);else this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);if(t!==-1)this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=(r)=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new sl(function(n){e=n}),cancel:e}}}var Tv=sl;function al(e){return function(r){return e.apply(null,r)}}function cl(e){return f.isObject(e)&&e.isAxiosError===!0}var ul={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(ul).forEach(([e,t])=>{ul[t]=e});var Ev=ul;function Rv(e){let t=new li(e),r=Do(li.prototype.request,t);return f.extend(r,li.prototype,t,{allOwnKeys:!0}),f.extend(r,t,null,{allOwnKeys:!0}),r.create=function(o){return Rv(Ut(e,o))},r}var Me=Rv(qn);Me.Axios=li;Me.CanceledError=wt;Me.CancelToken=Tv;Me.isCancel=Jo;Me.VERSION=lr;Me.toFormData=Sr;Me.AxiosError=T;Me.Cancel=Me.CanceledError;Me.all=function(t){return Promise.all(t)};Me.spread=al;Me.isAxiosError=cl;Me.mergeConfig=Ut;Me.AxiosHeaders=ye;Me.formToJSON=(e)=>Ns(f.isHTMLForm(e)?new FormData(e):e);Me.getAdapter=Gs.getAdapter;Me.HttpStatusCode=Ev;Me.default=Me;var Ks=Me;var v={};No(v,{BRAND:()=>PA,DIRTY:()=>ln,EMPTY_PATH:()=>aA,INVALID:()=>U,NEVER:()=>dC,OK:()=>ot,ParseStatus:()=>Ke,Schema:()=>Y,ZodAny:()=>dn,ZodArray:()=>Zt,ZodBigInt:()=>zr,ZodBoolean:()=>Yn,ZodBranded:()=>ea,ZodCatch:()=>so,ZodDate:()=>pn,ZodDefault:()=>io,ZodDiscriminatedUnion:()=>Qs,ZodEffects:()=>Ht,ZodEnum:()=>Or,ZodError:()=>ft,ZodFirstPartyTypeKind:()=>P,ZodFunction:()=>Kn,ZodIntersection:()=>to,ZodIssueCode:()=>R,ZodLazy:()=>ro,ZodLiteral:()=>no,ZodMap:()=>hi,ZodNaN:()=>gi,ZodNativeEnum:()=>oo,ZodNever:()=>ir,ZodNull:()=>Qn,ZodNullable:()=>fr,ZodNumber:()=>Pr,ZodObject:()=>ze,ZodOptional:()=>kt,ZodParsedType:()=>O,ZodPipeline:()=>xi,ZodPromise:()=>fn,ZodReadonly:()=>ao,ZodRecord:()=>fi,ZodSchema:()=>Y,ZodSet:()=>mn,ZodString:()=>Ft,ZodSymbol:()=>di,ZodTransformer:()=>Ht,ZodTuple:()=>sr,ZodType:()=>Y,ZodUndefined:()=>Xn,ZodUnion:()=>eo,ZodUnknown:()=>Rr,ZodVoid:()=>mi,addIssueToContext:()=>C,any:()=>LA,array:()=>FA,bigint:()=>CA,boolean:()=>Mv,coerce:()=>pC,custom:()=>Nv,date:()=>IA,datetimeRegex:()=>Iv,defaultErrorMap:()=>dr,discriminatedUnion:()=>HA,effect:()=>nC,enum:()=>eC,function:()=>YA,getErrorMap:()=>Gn,getParsedType:()=>or,instanceof:()=>OA,intersection:()=>VA,isAborted:()=>Ys,isAsync:()=>Jn,isDirty:()=>Xs,isValid:()=>Er,late:()=>zA,lazy:()=>XA,literal:()=>QA,makeIssue:()=>pi,map:()=>WA,nan:()=>AA,nativeEnum:()=>tC,never:()=>qA,null:()=>DA,nullable:()=>iC,number:()=>Lv,object:()=>ml,objectUtil:()=>ll,oboolean:()=>lC,onumber:()=>uC,optional:()=>oC,ostring:()=>cC,pipeline:()=>aC,preprocess:()=>sC,promise:()=>rC,quotelessJson:()=>oA,record:()=>JA,set:()=>KA,setErrorMap:()=>sA,strictObject:()=>ZA,string:()=>Dv,symbol:()=>jA,transformer:()=>nC,tuple:()=>GA,undefined:()=>NA,union:()=>BA,unknown:()=>MA,util:()=>ee,void:()=>UA});var ee;(function(e){e.assertEqual=(o)=>{};function t(o){}e.assertIs=t;function r(o){throw Error()}e.assertNever=r,e.arrayToEnum=(o)=>{let i={};for(let s of o)i[s]=s;return i},e.getValidEnumValues=(o)=>{let i=e.objectKeys(o).filter((a)=>typeof o[o[a]]!=="number"),s={};for(let a of i)s[a]=o[a];return e.objectValues(s)},e.objectValues=(o)=>e.objectKeys(o).map(function(i){return o[i]}),e.objectKeys=typeof Object.keys==="function"?(o)=>Object.keys(o):(o)=>{let i=[];for(let s in o)if(Object.prototype.hasOwnProperty.call(o,s))i.push(s);return i},e.find=(o,i)=>{for(let s of o)if(i(s))return s;return},e.isInteger=typeof Number.isInteger==="function"?(o)=>Number.isInteger(o):(o)=>typeof o==="number"&&Number.isFinite(o)&&Math.floor(o)===o;function n(o,i=" | "){return o.map((s)=>typeof s==="string"?`'${s}'`:s).join(i)}e.joinValues=n,e.jsonStringifyReplacer=(o,i)=>{if(typeof i==="bigint")return i.toString();return i}})(ee||(ee={}));var ll;(function(e){e.mergeShapes=(t,r)=>({...t,...r})})(ll||(ll={}));var O=ee.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),or=(e)=>{switch(typeof e){case"undefined":return O.undefined;case"string":return O.string;case"number":return Number.isNaN(e)?O.nan:O.number;case"boolean":return O.boolean;case"function":return O.function;case"bigint":return O.bigint;case"symbol":return O.symbol;case"object":if(Array.isArray(e))return O.array;if(e===null)return O.null;if(e.then&&typeof e.then==="function"&&e.catch&&typeof e.catch==="function")return O.promise;if(typeof Map<"u"&&e instanceof Map)return O.map;if(typeof Set<"u"&&e instanceof Set)return O.set;if(typeof Date<"u"&&e instanceof Date)return O.date;return O.object;default:return O.unknown}};var R=ee.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"]),oA=(e)=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:");class ft extends Error{get errors(){return this.issues}constructor(e){super();this.issues=[],this.addIssue=(r)=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let t=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,t);else this.__proto__=t;this.name="ZodError",this.issues=e}format(e){let t=e||function(o){return o.message},r={_errors:[]},n=(o)=>{for(let i of o.issues)if(i.code==="invalid_union")i.unionErrors.map(n);else if(i.code==="invalid_return_type")n(i.returnTypeError);else if(i.code==="invalid_arguments")n(i.argumentsError);else if(i.path.length===0)r._errors.push(t(i));else{let s=r,a=0;while(a<i.path.length){let c=i.path[a];if(a!==i.path.length-1)s[c]=s[c]||{_errors:[]};else s[c]=s[c]||{_errors:[]},s[c]._errors.push(t(i));s=s[c],a++}}};return n(this),r}static assert(e){if(!(e instanceof ft))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ee.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=(t)=>t.message){let t={},r=[];for(let n of this.issues)if(n.path.length>0){let o=n.path[0];t[o]=t[o]||[],t[o].push(e(n))}else r.push(e(n));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}ft.create=(e)=>new ft(e);var iA=(e,t)=>{let r;switch(e.code){case R.invalid_type:if(e.received===O.undefined)r="Required";else r=`Expected ${e.expected}, received ${e.received}`;break;case R.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,ee.jsonStringifyReplacer)}`;break;case R.unrecognized_keys:r=`Unrecognized key(s) in object: ${ee.joinValues(e.keys,", ")}`;break;case R.invalid_union:r="Invalid input";break;case R.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${ee.joinValues(e.options)}`;break;case R.invalid_enum_value:r=`Invalid enum value. Expected ${ee.joinValues(e.options)}, received '${e.received}'`;break;case R.invalid_arguments:r="Invalid function arguments";break;case R.invalid_return_type:r="Invalid function return type";break;case R.invalid_date:r="Invalid date";break;case R.invalid_string:if(typeof e.validation==="object")if("includes"in e.validation){if(r=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position==="number")r=`${r} at one or more positions greater than or equal to ${e.validation.position}`}else if("startsWith"in e.validation)r=`Invalid input: must start with "${e.validation.startsWith}"`;else if("endsWith"in e.validation)r=`Invalid input: must end with "${e.validation.endsWith}"`;else ee.assertNever(e.validation);else if(e.validation!=="regex")r=`Invalid ${e.validation}`;else r="Invalid";break;case R.too_small:if(e.type==="array")r=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`;else if(e.type==="string")r=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`;else if(e.type==="number")r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`;else if(e.type==="bigint")r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`;else if(e.type==="date")r=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`;else r="Invalid input";break;case R.too_big:if(e.type==="array")r=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`;else if(e.type==="string")r=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`;else if(e.type==="number")r=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`;else if(e.type==="bigint")r=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`;else if(e.type==="date")r=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`;else r="Invalid input";break;case R.custom:r="Invalid input";break;case R.invalid_intersection_types:r="Intersection results could not be merged";break;case R.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case R.not_finite:r="Number must be finite";break;default:r=t.defaultError,ee.assertNever(e)}return{message:r}},dr=iA;var Pv=dr;function sA(e){Pv=e}function Gn(){return Pv}var pi=(e)=>{let{data:t,path:r,errorMaps:n,issueData:o}=e,i=[...r,...o.path||[]],s={...o,path:i};if(o.message!==void 0)return{...o,path:i,message:o.message};let a="",c=n.filter((u)=>!!u).slice().reverse();for(let u of c)a=u(s,{data:t,defaultError:a}).message;return{...o,path:i,message:a}},aA=[];function C(e,t){let r=Gn(),n=pi({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===dr?void 0:dr].filter((o)=>!!o)});e.common.issues.push(n)}class Ke{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray(e,t){let r=[];for(let n of t){if(n.status==="aborted")return U;if(n.status==="dirty")e.dirty();r.push(n.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let n of t){let o=await n.key,i=await n.value;r.push({key:o,value:i})}return Ke.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let n of t){let{key:o,value:i}=n;if(o.status==="aborted")return U;if(i.status==="aborted")return U;if(o.status==="dirty")e.dirty();if(i.status==="dirty")e.dirty();if(o.value!=="__proto__"&&(typeof i.value<"u"||n.alwaysSet))r[o.value]=i.value}return{status:e.value,value:r}}}var U=Object.freeze({status:"aborted"}),ln=(e)=>({status:"dirty",value:e}),ot=(e)=>({status:"valid",value:e}),Ys=(e)=>e.status==="aborted",Xs=(e)=>e.status==="dirty",Er=(e)=>e.status==="valid",Jn=(e)=>typeof Promise<"u"&&e instanceof Promise;var N;(function(e){e.errToObj=(t)=>typeof t==="string"?{message:t}:t||{},e.toString=(t)=>typeof t==="string"?t:t?.message})(N||(N={}));class Bt{constructor(e,t,r,n){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=n}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}var zv=(e,t)=>{if(Er(t))return{success:!0,data:t.value};else{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 r=new ft(e.common.issues);return this._error=r,this._error}}}};function V(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:n,description:o}=e;if(t&&(r||n))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(t)return{errorMap:t,description:o};return{errorMap:(s,a)=>{let{message:c}=e;if(s.code==="invalid_enum_value")return{message:c??a.defaultError};if(typeof a.data>"u")return{message:c??n??a.defaultError};if(s.code!=="invalid_type")return{message:a.defaultError};return{message:c??r??a.defaultError}},description:o}}class Y{get description(){return this._def.description}_getType(e){return or(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:or(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new Ke,ctx:{common:e.parent.common,data:e.data,parsedType:or(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(Jn(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){let t=this._parse(e);return Promise.resolve(t)}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:or(e)},n=this._parseSync({data:e,path:r.path,parent:r});return zv(r,n)}"~validate"(e){let t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:or(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:t});return Er(r)?{value:r.value}:{issues:t.common.issues}}catch(r){if(r?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then((r)=>Er(r)?{value:r.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:or(e)},n=this._parse({data:e,path:r.path,parent:r}),o=await(Jn(n)?n:Promise.resolve(n));return zv(r,o)}refine(e,t){let r=(n)=>{if(typeof t==="string"||typeof t>"u")return{message:t};else if(typeof t==="function")return t(n);else return t};return this._refinement((n,o)=>{let i=e(n),s=()=>o.addIssue({code:R.custom,...r(n)});if(typeof Promise<"u"&&i instanceof Promise)return i.then((a)=>{if(!a)return s(),!1;else return!0});if(!i)return s(),!1;else return!0})}refinement(e,t){return this._refinement((r,n)=>{if(!e(r))return n.addIssue(typeof t==="function"?t(r,n):t),!1;else return!0})}_refinement(e){return new Ht({schema:this,typeName:P.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:(t)=>this["~validate"](t)}}optional(){return kt.create(this,this._def)}nullable(){return fr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Zt.create(this)}promise(){return fn.create(this,this._def)}or(e){return eo.create([this,e],this._def)}and(e){return to.create(this,e,this._def)}transform(e){return new Ht({...V(this._def),schema:this,typeName:P.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let t=typeof e==="function"?e:()=>e;return new io({...V(this._def),innerType:this,defaultValue:t,typeName:P.ZodDefault})}brand(){return new ea({typeName:P.ZodBranded,type:this,...V(this._def)})}catch(e){let t=typeof e==="function"?e:()=>e;return new so({...V(this._def),innerType:this,catchValue:t,typeName:P.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return xi.create(this,e)}readonly(){return ao.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}var cA=/^c[^\s-]{8,}$/i,uA=/^[0-9a-z]+$/,lA=/^[0-9A-HJKMNP-TV-Z]{26}$/i,pA=/^[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,dA=/^[a-z0-9_-]{21}$/i,mA=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,fA=/^[-+]?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)?)??$/,hA=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,gA="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",pl,xA=/^(?:(?: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])$/,vA=/^(?:(?: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])$/,yA=/^(([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]))$/,bA=/^(([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])$/,_A=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,wA=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,Av="((\\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])))",kA=new RegExp(`^${Av}$`);function Cv(e){let t="[0-5]\\d";if(e.precision)t=`${t}\\.\\d{${e.precision}}`;else if(e.precision==null)t=`${t}(\\.\\d+)?`;let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}function SA(e){return new RegExp(`^${Cv(e)}$`)}function Iv(e){let t=`${Av}T${Cv(e)}`,r=[];if(r.push(e.local?"Z?":"Z"),e.offset)r.push("([+-]\\d{2}:?\\d{2})");return t=`${t}(${r.join("|")})`,new RegExp(`^${t}$`)}function $A(e,t){if((t==="v4"||!t)&&xA.test(e))return!0;if((t==="v6"||!t)&&yA.test(e))return!0;return!1}function TA(e,t){if(!mA.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let n=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),o=JSON.parse(atob(n));if(typeof o!=="object"||o===null)return!1;if("typ"in o&&o?.typ!=="JWT")return!1;if(!o.alg)return!1;if(t&&o.alg!==t)return!1;return!0}catch{return!1}}function EA(e,t){if((t==="v4"||!t)&&vA.test(e))return!0;if((t==="v6"||!t)&&bA.test(e))return!0;return!1}class Ft extends Y{_parse(e){if(this._def.coerce)e.data=String(e.data);if(this._getType(e)!==O.string){let o=this._getOrReturnCtx(e);return C(o,{code:R.invalid_type,expected:O.string,received:o.parsedType}),U}let r=new Ke,n=void 0;for(let o of this._def.checks)if(o.kind==="min"){if(e.data.length<o.value)n=this._getOrReturnCtx(e,n),C(n,{code:R.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty()}else if(o.kind==="max"){if(e.data.length>o.value)n=this._getOrReturnCtx(e,n),C(n,{code:R.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty()}else if(o.kind==="length"){let i=e.data.length>o.value,s=e.data.length<o.value;if(i||s){if(n=this._getOrReturnCtx(e,n),i)C(n,{code:R.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message});else if(s)C(n,{code:R.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message});r.dirty()}}else if(o.kind==="email"){if(!hA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"email",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="emoji"){if(!pl)pl=new RegExp(gA,"u");if(!pl.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"emoji",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="uuid"){if(!pA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"uuid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="nanoid"){if(!dA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"nanoid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cuid"){if(!cA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"cuid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cuid2"){if(!uA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"cuid2",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="ulid"){if(!lA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"ulid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="url")try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),C(n,{validation:"url",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="regex"){if(o.regex.lastIndex=0,!o.regex.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"regex",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="trim")e.data=e.data.trim();else if(o.kind==="includes"){if(!e.data.includes(o.value,o.position))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),r.dirty()}else if(o.kind==="toLowerCase")e.data=e.data.toLowerCase();else if(o.kind==="toUpperCase")e.data=e.data.toUpperCase();else if(o.kind==="startsWith"){if(!e.data.startsWith(o.value))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:{startsWith:o.value},message:o.message}),r.dirty()}else if(o.kind==="endsWith"){if(!e.data.endsWith(o.value))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:{endsWith:o.value},message:o.message}),r.dirty()}else if(o.kind==="datetime"){if(!Iv(o).test(e.data))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:"datetime",message:o.message}),r.dirty()}else if(o.kind==="date"){if(!kA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:"date",message:o.message}),r.dirty()}else if(o.kind==="time"){if(!SA(o).test(e.data))n=this._getOrReturnCtx(e,n),C(n,{code:R.invalid_string,validation:"time",message:o.message}),r.dirty()}else if(o.kind==="duration"){if(!fA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"duration",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="ip"){if(!$A(e.data,o.version))n=this._getOrReturnCtx(e,n),C(n,{validation:"ip",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="jwt"){if(!TA(e.data,o.alg))n=this._getOrReturnCtx(e,n),C(n,{validation:"jwt",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cidr"){if(!EA(e.data,o.version))n=this._getOrReturnCtx(e,n),C(n,{validation:"cidr",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="base64"){if(!_A.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"base64",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="base64url"){if(!wA.test(e.data))n=this._getOrReturnCtx(e,n),C(n,{validation:"base64url",code:R.invalid_string,message:o.message}),r.dirty()}else ee.assertNever(o);return{status:r.value,value:e.data}}_regex(e,t,r){return this.refinement((n)=>e.test(n),{validation:t,code:R.invalid_string,...N.errToObj(r)})}_addCheck(e){return new Ft({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...N.errToObj(e)})}url(e){return this._addCheck({kind:"url",...N.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...N.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...N.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...N.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...N.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...N.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...N.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...N.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...N.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...N.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...N.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...N.errToObj(e)})}datetime(e){if(typeof e==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e});return this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...N.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){if(typeof e==="string")return this._addCheck({kind:"time",precision:null,message:e});return this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...N.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...N.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...N.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...N.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...N.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...N.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...N.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...N.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...N.errToObj(t)})}nonempty(e){return this.min(1,N.errToObj(e))}trim(){return new Ft({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Ft({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Ft({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e)=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find((e)=>e.kind==="date")}get isTime(){return!!this._def.checks.find((e)=>e.kind==="time")}get isDuration(){return!!this._def.checks.find((e)=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find((e)=>e.kind==="email")}get isURL(){return!!this._def.checks.find((e)=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find((e)=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find((e)=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find((e)=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find((e)=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find((e)=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find((e)=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find((e)=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find((e)=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find((e)=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find((e)=>e.kind==="base64url")}get minLength(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxLength(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}}Ft.create=(e)=>new Ft({checks:[],typeName:P.ZodString,coerce:e?.coerce??!1,...V(e)});function RA(e,t){let r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,o=r>n?r:n,i=Number.parseInt(e.toFixed(o).replace(".","")),s=Number.parseInt(t.toFixed(o).replace(".",""));return i%s/10**o}class Pr extends Y{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce)e.data=Number(e.data);if(this._getType(e)!==O.number){let o=this._getOrReturnCtx(e);return C(o,{code:R.invalid_type,expected:O.number,received:o.parsedType}),U}let r=void 0,n=new Ke;for(let o of this._def.checks)if(o.kind==="int"){if(!ee.isInteger(e.data))r=this._getOrReturnCtx(e,r),C(r,{code:R.invalid_type,expected:"integer",received:"float",message:o.message}),n.dirty()}else if(o.kind==="min"){if(o.inclusive?e.data<o.value:e.data<=o.value)r=this._getOrReturnCtx(e,r),C(r,{code:R.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()}else if(o.kind==="max"){if(o.inclusive?e.data>o.value:e.data>=o.value)r=this._getOrReturnCtx(e,r),C(r,{code:R.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()}else if(o.kind==="multipleOf"){if(RA(e.data,o.value)!==0)r=this._getOrReturnCtx(e,r),C(r,{code:R.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()}else if(o.kind==="finite"){if(!Number.isFinite(e.data))r=this._getOrReturnCtx(e,r),C(r,{code:R.not_finite,message:o.message}),n.dirty()}else ee.assertNever(o);return{status:n.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,N.toString(t))}gt(e,t){return this.setLimit("min",e,!1,N.toString(t))}lte(e,t){return this.setLimit("max",e,!0,N.toString(t))}lt(e,t){return this.setLimit("max",e,!1,N.toString(t))}setLimit(e,t,r,n){return new Pr({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:N.toString(n)}]})}_addCheck(e){return new Pr({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:N.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:N.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:N.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:N.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:N.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:N.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:N.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:N.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:N.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxValue(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}get isInt(){return!!this._def.checks.find((e)=>e.kind==="int"||e.kind==="multipleOf"&&ee.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks)if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;else if(r.kind==="min"){if(t===null||r.value>t)t=r.value}else if(r.kind==="max"){if(e===null||r.value<e)e=r.value}return Number.isFinite(t)&&Number.isFinite(e)}}Pr.create=(e)=>new Pr({checks:[],typeName:P.ZodNumber,coerce:e?.coerce||!1,...V(e)});class zr extends Y{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==O.bigint)return this._getInvalidInput(e);let r=void 0,n=new Ke;for(let o of this._def.checks)if(o.kind==="min"){if(o.inclusive?e.data<o.value:e.data<=o.value)r=this._getOrReturnCtx(e,r),C(r,{code:R.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()}else if(o.kind==="max"){if(o.inclusive?e.data>o.value:e.data>=o.value)r=this._getOrReturnCtx(e,r),C(r,{code:R.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()}else if(o.kind==="multipleOf"){if(e.data%o.value!==BigInt(0))r=this._getOrReturnCtx(e,r),C(r,{code:R.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()}else ee.assertNever(o);return{status:n.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return C(t,{code:R.invalid_type,expected:O.bigint,received:t.parsedType}),U}gte(e,t){return this.setLimit("min",e,!0,N.toString(t))}gt(e,t){return this.setLimit("min",e,!1,N.toString(t))}lte(e,t){return this.setLimit("max",e,!0,N.toString(t))}lt(e,t){return this.setLimit("max",e,!1,N.toString(t))}setLimit(e,t,r,n){return new zr({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:N.toString(n)}]})}_addCheck(e){return new zr({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:N.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:N.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:N.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:N.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:N.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxValue(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}}zr.create=(e)=>new zr({checks:[],typeName:P.ZodBigInt,coerce:e?.coerce??!1,...V(e)});class Yn extends Y{_parse(e){if(this._def.coerce)e.data=Boolean(e.data);if(this._getType(e)!==O.boolean){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.boolean,received:r.parsedType}),U}return ot(e.data)}}Yn.create=(e)=>new Yn({typeName:P.ZodBoolean,coerce:e?.coerce||!1,...V(e)});class pn extends Y{_parse(e){if(this._def.coerce)e.data=new Date(e.data);if(this._getType(e)!==O.date){let o=this._getOrReturnCtx(e);return C(o,{code:R.invalid_type,expected:O.date,received:o.parsedType}),U}if(Number.isNaN(e.data.getTime())){let o=this._getOrReturnCtx(e);return C(o,{code:R.invalid_date}),U}let r=new Ke,n=void 0;for(let o of this._def.checks)if(o.kind==="min"){if(e.data.getTime()<o.value)n=this._getOrReturnCtx(e,n),C(n,{code:R.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),r.dirty()}else if(o.kind==="max"){if(e.data.getTime()>o.value)n=this._getOrReturnCtx(e,n),C(n,{code:R.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),r.dirty()}else ee.assertNever(o);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new pn({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:N.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:N.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e!=null?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e!=null?new Date(e):null}}pn.create=(e)=>new pn({checks:[],coerce:e?.coerce||!1,typeName:P.ZodDate,...V(e)});class di extends Y{_parse(e){if(this._getType(e)!==O.symbol){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.symbol,received:r.parsedType}),U}return ot(e.data)}}di.create=(e)=>new di({typeName:P.ZodSymbol,...V(e)});class Xn extends Y{_parse(e){if(this._getType(e)!==O.undefined){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.undefined,received:r.parsedType}),U}return ot(e.data)}}Xn.create=(e)=>new Xn({typeName:P.ZodUndefined,...V(e)});class Qn extends Y{_parse(e){if(this._getType(e)!==O.null){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.null,received:r.parsedType}),U}return ot(e.data)}}Qn.create=(e)=>new Qn({typeName:P.ZodNull,...V(e)});class dn extends Y{constructor(){super(...arguments);this._any=!0}_parse(e){return ot(e.data)}}dn.create=(e)=>new dn({typeName:P.ZodAny,...V(e)});class Rr extends Y{constructor(){super(...arguments);this._unknown=!0}_parse(e){return ot(e.data)}}Rr.create=(e)=>new Rr({typeName:P.ZodUnknown,...V(e)});class ir extends Y{_parse(e){let t=this._getOrReturnCtx(e);return C(t,{code:R.invalid_type,expected:O.never,received:t.parsedType}),U}}ir.create=(e)=>new ir({typeName:P.ZodNever,...V(e)});class mi extends Y{_parse(e){if(this._getType(e)!==O.undefined){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.void,received:r.parsedType}),U}return ot(e.data)}}mi.create=(e)=>new mi({typeName:P.ZodVoid,...V(e)});class Zt extends Y{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),n=this._def;if(t.parsedType!==O.array)return C(t,{code:R.invalid_type,expected:O.array,received:t.parsedType}),U;if(n.exactLength!==null){let i=t.data.length>n.exactLength.value,s=t.data.length<n.exactLength.value;if(i||s)C(t,{code:i?R.too_big:R.too_small,minimum:s?n.exactLength.value:void 0,maximum:i?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),r.dirty()}if(n.minLength!==null){if(t.data.length<n.minLength.value)C(t,{code:R.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),r.dirty()}if(n.maxLength!==null){if(t.data.length>n.maxLength.value)C(t,{code:R.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),r.dirty()}if(t.common.async)return Promise.all([...t.data].map((i,s)=>n.type._parseAsync(new Bt(t,i,t.path,s)))).then((i)=>Ke.mergeArray(r,i));let o=[...t.data].map((i,s)=>n.type._parseSync(new Bt(t,i,t.path,s)));return Ke.mergeArray(r,o)}get element(){return this._def.type}min(e,t){return new Zt({...this._def,minLength:{value:e,message:N.toString(t)}})}max(e,t){return new Zt({...this._def,maxLength:{value:e,message:N.toString(t)}})}length(e,t){return new Zt({...this._def,exactLength:{value:e,message:N.toString(t)}})}nonempty(e){return this.min(1,e)}}Zt.create=(e,t)=>new Zt({type:e,minLength:null,maxLength:null,exactLength:null,typeName:P.ZodArray,...V(t)});function Wn(e){if(e instanceof ze){let t={};for(let r in e.shape){let n=e.shape[r];t[r]=kt.create(Wn(n))}return new ze({...e._def,shape:()=>t})}else if(e instanceof Zt)return new Zt({...e._def,type:Wn(e.element)});else if(e instanceof kt)return kt.create(Wn(e.unwrap()));else if(e instanceof fr)return fr.create(Wn(e.unwrap()));else if(e instanceof sr)return sr.create(e.items.map((t)=>Wn(t)));else return e}class ze extends Y{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),t=ee.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==O.object){let c=this._getOrReturnCtx(e);return C(c,{code:R.invalid_type,expected:O.object,received:c.parsedType}),U}let{status:r,ctx:n}=this._processInputParams(e),{shape:o,keys:i}=this._getCached(),s=[];if(!(this._def.catchall instanceof ir&&this._def.unknownKeys==="strip")){for(let c in n.data)if(!i.includes(c))s.push(c)}let a=[];for(let c of i){let u=o[c],l=n.data[c];a.push({key:{status:"valid",value:c},value:u._parse(new Bt(n,l,n.path,c)),alwaysSet:c in n.data})}if(this._def.catchall instanceof ir){let c=this._def.unknownKeys;if(c==="passthrough")for(let u of s)a.push({key:{status:"valid",value:u},value:{status:"valid",value:n.data[u]}});else if(c==="strict"){if(s.length>0)C(n,{code:R.unrecognized_keys,keys:s}),r.dirty()}else if(c==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let c=this._def.catchall;for(let u of s){let l=n.data[u];a.push({key:{status:"valid",value:u},value:c._parse(new Bt(n,l,n.path,u)),alwaysSet:u in n.data})}}if(n.common.async)return Promise.resolve().then(async()=>{let c=[];for(let u of a){let l=await u.key,p=await u.value;c.push({key:l,value:p,alwaysSet:u.alwaysSet})}return c}).then((c)=>Ke.mergeObjectSync(r,c));else return Ke.mergeObjectSync(r,a)}get shape(){return this._def.shape()}strict(e){return N.errToObj,new ze({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,r)=>{let n=this._def.errorMap?.(t,r).message??r.defaultError;if(t.code==="unrecognized_keys")return{message:N.errToObj(e).message??n};return{message:n}}}:{}})}strip(){return new ze({...this._def,unknownKeys:"strip"})}passthrough(){return new ze({...this._def,unknownKeys:"passthrough"})}extend(e){return new ze({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new ze({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:P.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new ze({...this._def,catchall:e})}pick(e){let t={};for(let r of ee.objectKeys(e))if(e[r]&&this.shape[r])t[r]=this.shape[r];return new ze({...this._def,shape:()=>t})}omit(e){let t={};for(let r of ee.objectKeys(this.shape))if(!e[r])t[r]=this.shape[r];return new ze({...this._def,shape:()=>t})}deepPartial(){return Wn(this)}partial(e){let t={};for(let r of ee.objectKeys(this.shape)){let n=this.shape[r];if(e&&!e[r])t[r]=n;else t[r]=n.optional()}return new ze({...this._def,shape:()=>t})}required(e){let t={};for(let r of ee.objectKeys(this.shape))if(e&&!e[r])t[r]=this.shape[r];else{let o=this.shape[r];while(o instanceof kt)o=o._def.innerType;t[r]=o}return new ze({...this._def,shape:()=>t})}keyof(){return jv(ee.objectKeys(this.shape))}}ze.create=(e,t)=>new ze({shape:()=>e,unknownKeys:"strip",catchall:ir.create(),typeName:P.ZodObject,...V(t)});ze.strictCreate=(e,t)=>new ze({shape:()=>e,unknownKeys:"strict",catchall:ir.create(),typeName:P.ZodObject,...V(t)});ze.lazycreate=(e,t)=>new ze({shape:e,unknownKeys:"strip",catchall:ir.create(),typeName:P.ZodObject,...V(t)});class eo extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;function n(o){for(let s of o)if(s.result.status==="valid")return s.result;for(let s of o)if(s.result.status==="dirty")return t.common.issues.push(...s.ctx.common.issues),s.result;let i=o.map((s)=>new ft(s.ctx.common.issues));return C(t,{code:R.invalid_union,unionErrors:i}),U}if(t.common.async)return Promise.all(r.map(async(o)=>{let i={...t,common:{...t.common,issues:[]},parent:null};return{result:await o._parseAsync({data:t.data,path:t.path,parent:i}),ctx:i}})).then(n);else{let o=void 0,i=[];for(let a of r){let c={...t,common:{...t.common,issues:[]},parent:null},u=a._parseSync({data:t.data,path:t.path,parent:c});if(u.status==="valid")return u;else if(u.status==="dirty"&&!o)o={result:u,ctx:c};if(c.common.issues.length)i.push(c.common.issues)}if(o)return t.common.issues.push(...o.ctx.common.issues),o.result;let s=i.map((a)=>new ft(a));return C(t,{code:R.invalid_union,unionErrors:s}),U}}get options(){return this._def.options}}eo.create=(e,t)=>new eo({options:e,typeName:P.ZodUnion,...V(t)});var mr=(e)=>{if(e instanceof ro)return mr(e.schema);else if(e instanceof Ht)return mr(e.innerType());else if(e instanceof no)return[e.value];else if(e instanceof Or)return e.options;else if(e instanceof oo)return ee.objectValues(e.enum);else if(e instanceof io)return mr(e._def.innerType);else if(e instanceof Xn)return[void 0];else if(e instanceof Qn)return[null];else if(e instanceof kt)return[void 0,...mr(e.unwrap())];else if(e instanceof fr)return[null,...mr(e.unwrap())];else if(e instanceof ea)return mr(e.unwrap());else if(e instanceof ao)return mr(e.unwrap());else if(e instanceof so)return mr(e._def.innerType);else return[]};class Qs extends Y{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==O.object)return C(t,{code:R.invalid_type,expected:O.object,received:t.parsedType}),U;let r=this.discriminator,n=t.data[r],o=this.optionsMap.get(n);if(!o)return C(t,{code:R.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),U;if(t.common.async)return o._parseAsync({data:t.data,path:t.path,parent:t});else return o._parseSync({data:t.data,path:t.path,parent:t})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let n=new Map;for(let o of t){let i=mr(o.shape[e]);if(!i.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let s of i){if(n.has(s))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(s)}`);n.set(s,o)}}return new Qs({typeName:P.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:n,...V(r)})}}function dl(e,t){let r=or(e),n=or(t);if(e===t)return{valid:!0,data:e};else if(r===O.object&&n===O.object){let o=ee.objectKeys(t),i=ee.objectKeys(e).filter((a)=>o.indexOf(a)!==-1),s={...e,...t};for(let a of i){let c=dl(e[a],t[a]);if(!c.valid)return{valid:!1};s[a]=c.data}return{valid:!0,data:s}}else if(r===O.array&&n===O.array){if(e.length!==t.length)return{valid:!1};let o=[];for(let i=0;i<e.length;i++){let s=e[i],a=t[i],c=dl(s,a);if(!c.valid)return{valid:!1};o.push(c.data)}return{valid:!0,data:o}}else if(r===O.date&&n===O.date&&+e===+t)return{valid:!0,data:e};else return{valid:!1}}class to extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=(o,i)=>{if(Ys(o)||Ys(i))return U;let s=dl(o.value,i.value);if(!s.valid)return C(r,{code:R.invalid_intersection_types}),U;if(Xs(o)||Xs(i))t.dirty();return{status:t.value,value:s.data}};if(r.common.async)return 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(([o,i])=>n(o,i));else return n(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}to.create=(e,t,r)=>new to({left:e,right:t,typeName:P.ZodIntersection,...V(r)});class sr extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==O.array)return C(r,{code:R.invalid_type,expected:O.array,received:r.parsedType}),U;if(r.data.length<this._def.items.length)return C(r,{code:R.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),U;if(!this._def.rest&&r.data.length>this._def.items.length)C(r,{code:R.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty();let o=[...r.data].map((i,s)=>{let a=this._def.items[s]||this._def.rest;if(!a)return null;return a._parse(new Bt(r,i,r.path,s))}).filter((i)=>!!i);if(r.common.async)return Promise.all(o).then((i)=>Ke.mergeArray(t,i));else return Ke.mergeArray(t,o)}get items(){return this._def.items}rest(e){return new sr({...this._def,rest:e})}}sr.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new sr({items:e,typeName:P.ZodTuple,rest:null,...V(t)})};class fi extends Y{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!==O.object)return C(r,{code:R.invalid_type,expected:O.object,received:r.parsedType}),U;let n=[],o=this._def.keyType,i=this._def.valueType;for(let s in r.data)n.push({key:o._parse(new Bt(r,s,r.path,s)),value:i._parse(new Bt(r,r.data[s],r.path,s)),alwaysSet:s in r.data});if(r.common.async)return Ke.mergeObjectAsync(t,n);else return Ke.mergeObjectSync(t,n)}get element(){return this._def.valueType}static create(e,t,r){if(t instanceof Y)return new fi({keyType:e,valueType:t,typeName:P.ZodRecord,...V(r)});return new fi({keyType:Ft.create(),valueType:e,typeName:P.ZodRecord,...V(t)})}}class hi extends Y{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!==O.map)return C(r,{code:R.invalid_type,expected:O.map,received:r.parsedType}),U;let n=this._def.keyType,o=this._def.valueType,i=[...r.data.entries()].map(([s,a],c)=>({key:n._parse(new Bt(r,s,r.path,[c,"key"])),value:o._parse(new Bt(r,a,r.path,[c,"value"]))}));if(r.common.async){let s=new Map;return Promise.resolve().then(async()=>{for(let a of i){let c=await a.key,u=await a.value;if(c.status==="aborted"||u.status==="aborted")return U;if(c.status==="dirty"||u.status==="dirty")t.dirty();s.set(c.value,u.value)}return{status:t.value,value:s}})}else{let s=new Map;for(let a of i){let{key:c,value:u}=a;if(c.status==="aborted"||u.status==="aborted")return U;if(c.status==="dirty"||u.status==="dirty")t.dirty();s.set(c.value,u.value)}return{status:t.value,value:s}}}}hi.create=(e,t,r)=>new hi({valueType:t,keyType:e,typeName:P.ZodMap,...V(r)});class mn extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==O.set)return C(r,{code:R.invalid_type,expected:O.set,received:r.parsedType}),U;let n=this._def;if(n.minSize!==null){if(r.data.size<n.minSize.value)C(r,{code:R.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),t.dirty()}if(n.maxSize!==null){if(r.data.size>n.maxSize.value)C(r,{code:R.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),t.dirty()}let o=this._def.valueType;function i(a){let c=new Set;for(let u of a){if(u.status==="aborted")return U;if(u.status==="dirty")t.dirty();c.add(u.value)}return{status:t.value,value:c}}let s=[...r.data.values()].map((a,c)=>o._parse(new Bt(r,a,r.path,c)));if(r.common.async)return Promise.all(s).then((a)=>i(a));else return i(s)}min(e,t){return new mn({...this._def,minSize:{value:e,message:N.toString(t)}})}max(e,t){return new mn({...this._def,maxSize:{value:e,message:N.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}mn.create=(e,t)=>new mn({valueType:e,minSize:null,maxSize:null,typeName:P.ZodSet,...V(t)});class Kn extends Y{constructor(){super(...arguments);this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==O.function)return C(t,{code:R.invalid_type,expected:O.function,received:t.parsedType}),U;function r(s,a){return pi({data:s,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Gn(),dr].filter((c)=>!!c),issueData:{code:R.invalid_arguments,argumentsError:a}})}function n(s,a){return pi({data:s,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,Gn(),dr].filter((c)=>!!c),issueData:{code:R.invalid_return_type,returnTypeError:a}})}let o={errorMap:t.common.contextualErrorMap},i=t.data;if(this._def.returns instanceof fn){let s=this;return ot(async function(...a){let c=new ft([]),u=await s._def.args.parseAsync(a,o).catch((m)=>{throw c.addIssue(r(a,m)),c}),l=await Reflect.apply(i,this,u);return await s._def.returns._def.type.parseAsync(l,o).catch((m)=>{throw c.addIssue(n(l,m)),c})})}else{let s=this;return ot(function(...a){let c=s._def.args.safeParse(a,o);if(!c.success)throw new ft([r(a,c.error)]);let u=Reflect.apply(i,this,c.data),l=s._def.returns.safeParse(u,o);if(!l.success)throw new ft([n(u,l.error)]);return l.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new Kn({...this._def,args:sr.create(e).rest(Rr.create())})}returns(e){return new Kn({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new Kn({args:e?e:sr.create([]).rest(Rr.create()),returns:t||Rr.create(),typeName:P.ZodFunction,...V(r)})}}class ro extends Y{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})}}ro.create=(e,t)=>new ro({getter:e,typeName:P.ZodLazy,...V(t)});class no extends Y{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return C(t,{received:t.data,code:R.invalid_literal,expected:this._def.value}),U}return{status:"valid",value:e.data}}get value(){return this._def.value}}no.create=(e,t)=>new no({value:e,typeName:P.ZodLiteral,...V(t)});function jv(e,t){return new Or({values:e,typeName:P.ZodEnum,...V(t)})}class Or extends Y{_parse(e){if(typeof e.data!=="string"){let t=this._getOrReturnCtx(e),r=this._def.values;return C(t,{expected:ee.joinValues(r),received:t.parsedType,code:R.invalid_type}),U}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return C(t,{received:t.data,code:R.invalid_enum_value,options:r}),U}return ot(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 Or.create(e,{...this._def,...t})}exclude(e,t=this._def){return Or.create(this.options.filter((r)=>!e.includes(r)),{...this._def,...t})}}Or.create=jv;class oo extends Y{_parse(e){let t=ee.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==O.string&&r.parsedType!==O.number){let n=ee.objectValues(t);return C(r,{expected:ee.joinValues(n),received:r.parsedType,code:R.invalid_type}),U}if(!this._cache)this._cache=new Set(ee.getValidEnumValues(this._def.values));if(!this._cache.has(e.data)){let n=ee.objectValues(t);return C(r,{received:r.data,code:R.invalid_enum_value,options:n}),U}return ot(e.data)}get enum(){return this._def.values}}oo.create=(e,t)=>new oo({values:e,typeName:P.ZodNativeEnum,...V(t)});class fn extends Y{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==O.promise&&t.common.async===!1)return C(t,{code:R.invalid_type,expected:O.promise,received:t.parsedType}),U;let r=t.parsedType===O.promise?t.data:Promise.resolve(t.data);return ot(r.then((n)=>this._def.type.parseAsync(n,{path:t.path,errorMap:t.common.contextualErrorMap})))}}fn.create=(e,t)=>new fn({type:e,typeName:P.ZodPromise,...V(t)});class Ht extends Y{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===P.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=this._def.effect||null,o={addIssue:(i)=>{if(C(r,i),i.fatal)t.abort();else t.dirty()},get path(){return r.path}};if(o.addIssue=o.addIssue.bind(o),n.type==="preprocess"){let i=n.transform(r.data,o);if(r.common.async)return Promise.resolve(i).then(async(s)=>{if(t.value==="aborted")return U;let a=await this._def.schema._parseAsync({data:s,path:r.path,parent:r});if(a.status==="aborted")return U;if(a.status==="dirty")return ln(a.value);if(t.value==="dirty")return ln(a.value);return a});else{if(t.value==="aborted")return U;let s=this._def.schema._parseSync({data:i,path:r.path,parent:r});if(s.status==="aborted")return U;if(s.status==="dirty")return ln(s.value);if(t.value==="dirty")return ln(s.value);return s}}if(n.type==="refinement"){let i=(s)=>{let a=n.refinement(s,o);if(r.common.async)return Promise.resolve(a);if(a instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return s};if(r.common.async===!1){let s=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(s.status==="aborted")return U;if(s.status==="dirty")t.dirty();return i(s.value),{status:t.value,value:s.value}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((s)=>{if(s.status==="aborted")return U;if(s.status==="dirty")t.dirty();return i(s.value).then(()=>({status:t.value,value:s.value}))})}if(n.type==="transform")if(r.common.async===!1){let i=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!Er(i))return U;let s=n.transform(i.value,o);if(s instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:s}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((i)=>{if(!Er(i))return U;return Promise.resolve(n.transform(i.value,o)).then((s)=>({status:t.value,value:s}))});ee.assertNever(n)}}Ht.create=(e,t,r)=>new Ht({schema:e,typeName:P.ZodEffects,effect:t,...V(r)});Ht.createWithPreprocess=(e,t,r)=>new Ht({schema:t,effect:{type:"preprocess",transform:e},typeName:P.ZodEffects,...V(r)});class kt extends Y{_parse(e){if(this._getType(e)===O.undefined)return ot(void 0);return this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}kt.create=(e,t)=>new kt({innerType:e,typeName:P.ZodOptional,...V(t)});class fr extends Y{_parse(e){if(this._getType(e)===O.null)return ot(null);return this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}fr.create=(e,t)=>new fr({innerType:e,typeName:P.ZodNullable,...V(t)});class io extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;if(t.parsedType===O.undefined)r=this._def.defaultValue();return this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}io.create=(e,t)=>new io({innerType:e,typeName:P.ZodDefault,defaultValue:typeof t.default==="function"?t.default:()=>t.default,...V(t)});class so extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},n=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});if(Jn(n))return n.then((o)=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new ft(r.common.issues)},input:r.data})}));else return{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new ft(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}so.create=(e,t)=>new so({innerType:e,typeName:P.ZodCatch,catchValue:typeof t.catch==="function"?t.catch:()=>t.catch,...V(t)});class gi extends Y{_parse(e){if(this._getType(e)!==O.nan){let r=this._getOrReturnCtx(e);return C(r,{code:R.invalid_type,expected:O.nan,received:r.parsedType}),U}return{status:"valid",value:e.data}}}gi.create=(e)=>new gi({typeName:P.ZodNaN,...V(e)});var PA=Symbol("zod_brand");class ea extends Y{_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 xi extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let o=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});if(o.status==="aborted")return U;if(o.status==="dirty")return t.dirty(),ln(o.value);else return this._def.out._parseAsync({data:o.value,path:r.path,parent:r})})();else{let n=this._def.in._parseSync({data:r.data,path:r.path,parent:r});if(n.status==="aborted")return U;if(n.status==="dirty")return t.dirty(),{status:"dirty",value:n.value};else return this._def.out._parseSync({data:n.value,path:r.path,parent:r})}}static create(e,t){return new xi({in:e,out:t,typeName:P.ZodPipeline})}}class ao extends Y{_parse(e){let t=this._def.innerType._parse(e),r=(n)=>{if(Er(n))n.value=Object.freeze(n.value);return n};return Jn(t)?t.then((n)=>r(n)):r(t)}unwrap(){return this._def.innerType}}ao.create=(e,t)=>new ao({innerType:e,typeName:P.ZodReadonly,...V(t)});function Ov(e,t){let r=typeof e==="function"?e(t):typeof e==="string"?{message:e}:e;return typeof r==="string"?{message:r}:r}function Nv(e,t={},r){if(e)return dn.create().superRefine((n,o)=>{let i=e(n);if(i instanceof Promise)return i.then((s)=>{if(!s){let a=Ov(t,n),c=a.fatal??r??!0;o.addIssue({code:"custom",...a,fatal:c})}});if(!i){let s=Ov(t,n),a=s.fatal??r??!0;o.addIssue({code:"custom",...s,fatal:a})}return});return dn.create()}var zA={object:ze.lazycreate},P;(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"})(P||(P={}));var OA=(e,t={message:`Input not instance of ${e.name}`})=>Nv((r)=>r instanceof e,t),Dv=Ft.create,Lv=Pr.create,AA=gi.create,CA=zr.create,Mv=Yn.create,IA=pn.create,jA=di.create,NA=Xn.create,DA=Qn.create,LA=dn.create,MA=Rr.create,qA=ir.create,UA=mi.create,FA=Zt.create,ml=ze.create,ZA=ze.strictCreate,BA=eo.create,HA=Qs.create,VA=to.create,GA=sr.create,JA=fi.create,WA=hi.create,KA=mn.create,YA=Kn.create,XA=ro.create,QA=no.create,eC=Or.create,tC=oo.create,rC=fn.create,nC=Ht.create,oC=kt.create,iC=fr.create,sC=Ht.createWithPreprocess,aC=xi.create,cC=()=>Dv().optional(),uC=()=>Lv().optional(),lC=()=>Mv().optional(),pC={string:(e)=>Ft.create({...e,coerce:!0}),number:(e)=>Pr.create({...e,coerce:!0}),boolean:(e)=>Yn.create({...e,coerce:!0}),bigint:(e)=>zr.create({...e,coerce:!0}),date:(e)=>pn.create({...e,coerce:!0})};var dC=U;var mC=Object.freeze({status:"aborted"});function S(e,t,r){function n(a,c){var u;Object.defineProperty(a,"_zod",{value:a._zod??{},enumerable:!1}),(u=a._zod).traits??(u.traits=new Set),a._zod.traits.add(e),t(a,c);for(let l in s.prototype)if(!(l in a))Object.defineProperty(a,l,{value:s.prototype[l].bind(a)});a._zod.constr=s,a._zod.def=c}let o=r?.Parent??Object;class i extends o{}Object.defineProperty(i,"name",{value:e});function s(a){var c;let u=r?.Parent?new i:this;n(u,a),(c=u._zod).deferred??(c.deferred=[]);for(let l of u._zod.deferred)l();return u}return Object.defineProperty(s,"init",{value:n}),Object.defineProperty(s,Symbol.hasInstance,{value:(a)=>{if(r?.Parent&&a instanceof r.Parent)return!0;return a?._zod?.traits?.has(e)}}),Object.defineProperty(s,"name",{value:e}),s}var fC=Symbol("zod_brand");class Ar extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}var ta={};function St(e){if(e)Object.assign(ta,e);return ta}var re={};No(re,{BIGINT_FORMAT_RANGES:()=>Uv,Class:()=>Zv,NUMBER_FORMAT_RANGES:()=>_l,aborted:()=>gn,allowsEval:()=>vl,assert:()=>yC,assertEqual:()=>hC,assertIs:()=>xC,assertNever:()=>vC,assertNotEqual:()=>gC,assignProp:()=>xl,cached:()=>bi,captureStackTrace:()=>na,cleanEnum:()=>AC,cleanRegex:()=>wi,clone:()=>$t,createTransparentProxy:()=>$C,defineLazy:()=>be,esc:()=>hn,escapeRegex:()=>Cr,extend:()=>RC,finalizeIssue:()=>Vt,floatSafeRemainder:()=>gl,getElementAtPath:()=>bC,getEnumValues:()=>yi,getLengthableOrigin:()=>ki,getParsedType:()=>SC,getSizableOrigin:()=>Fv,isObject:()=>co,isPlainObject:()=>uo,issue:()=>wl,joinValues:()=>ra,jsonStringifyReplacer:()=>hl,merge:()=>PC,normalizeParams:()=>F,nullish:()=>_i,numKeys:()=>kC,omit:()=>EC,optionalKeys:()=>bl,partial:()=>zC,pick:()=>TC,prefixIssues:()=>ar,primitiveTypes:()=>qv,promiseAllObject:()=>_C,propertyKeyTypes:()=>yl,randomString:()=>wC,required:()=>OC,stringifyPrimitive:()=>oa,unwrapMessage:()=>vi});function hC(e){return e}function gC(e){return e}function xC(e){}function vC(e){throw Error()}function yC(e){}function yi(e){let t=Object.values(e).filter((n)=>typeof n==="number");return Object.entries(e).filter(([n,o])=>t.indexOf(+n)===-1).map(([n,o])=>o)}function ra(e,t="|"){return e.map((r)=>oa(r)).join(t)}function hl(e,t){if(typeof t==="bigint")return t.toString();return t}function bi(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw Error("cached value already set")}}}function _i(e){return e===null||e===void 0}function wi(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}function gl(e,t){let r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,o=r>n?r:n,i=Number.parseInt(e.toFixed(o).replace(".","")),s=Number.parseInt(t.toFixed(o).replace(".",""));return i%s/10**o}function be(e,t,r){Object.defineProperty(e,t,{get(){{let o=r();return e[t]=o,o}throw Error("cached value already set")},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function xl(e,t,r){Object.defineProperty(e,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}function bC(e,t){if(!t)return e;return t.reduce((r,n)=>r?.[n],e)}function _C(e){let t=Object.keys(e),r=t.map((n)=>e[n]);return Promise.all(r).then((n)=>{let o={};for(let i=0;i<t.length;i++)o[t[i]]=n[i];return o})}function wC(e=10){let r="";for(let n=0;n<e;n++)r+="abcdefghijklmnopqrstuvwxyz"[Math.floor(Math.random()*26)];return r}function hn(e){return JSON.stringify(e)}var na=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};function co(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)}var vl=bi(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{return new Function(""),!0}catch(e){return!1}});function uo(e){if(co(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let r=t.prototype;if(co(r)===!1)return!1;if(Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)return!1;return!0}function kC(e){let t=0;for(let r in e)if(Object.prototype.hasOwnProperty.call(e,r))t++;return t}var SC=(e)=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":if(Array.isArray(e))return"array";if(e===null)return"null";if(e.then&&typeof e.then==="function"&&e.catch&&typeof e.catch==="function")return"promise";if(typeof Map<"u"&&e instanceof Map)return"map";if(typeof Set<"u"&&e instanceof Set)return"set";if(typeof Date<"u"&&e instanceof Date)return"date";if(typeof File<"u"&&e instanceof File)return"file";return"object";default:throw Error(`Unknown data type: ${t}`)}},yl=new Set(["string","number","symbol"]),qv=new Set(["string","number","bigint","boolean","symbol","undefined"]);function Cr(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function $t(e,t,r){let n=new e._zod.constr(t??e._zod.def);if(!t||r?.parent)n._zod.parent=e;return n}function F(e){let t=e;if(!t)return{};if(typeof t==="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");t.error=t.message}if(delete t.message,typeof t.error==="string")return{...t,error:()=>t.error};return t}function $C(e){let t;return new Proxy({},{get(r,n,o){return t??(t=e()),Reflect.get(t,n,o)},set(r,n,o,i){return t??(t=e()),Reflect.set(t,n,o,i)},has(r,n){return t??(t=e()),Reflect.has(t,n)},deleteProperty(r,n){return t??(t=e()),Reflect.deleteProperty(t,n)},ownKeys(r){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(r,n){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,n)},defineProperty(r,n,o){return t??(t=e()),Reflect.defineProperty(t,n,o)}})}function oa(e){if(typeof e==="bigint")return e.toString()+"n";if(typeof e==="string")return`"${e}"`;return`${e}`}function bl(e){return Object.keys(e).filter((t)=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var _l={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-340282346638528860000000000000000000000,340282346638528860000000000000000000000],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},Uv={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function TC(e,t){let r={},n=e._zod.def;for(let o in t){if(!(o in n.shape))throw Error(`Unrecognized key: "${o}"`);if(!t[o])continue;r[o]=n.shape[o]}return $t(e,{...e._zod.def,shape:r,checks:[]})}function EC(e,t){let r={...e._zod.def.shape},n=e._zod.def;for(let o in t){if(!(o in n.shape))throw Error(`Unrecognized key: "${o}"`);if(!t[o])continue;delete r[o]}return $t(e,{...e._zod.def,shape:r,checks:[]})}function RC(e,t){if(!uo(t))throw Error("Invalid input to extend: expected a plain object");let r={...e._zod.def,get shape(){let n={...e._zod.def.shape,...t};return xl(this,"shape",n),n},checks:[]};return $t(e,r)}function PC(e,t){return $t(e,{...e._zod.def,get shape(){let r={...e._zod.def.shape,...t._zod.def.shape};return xl(this,"shape",r),r},catchall:t._zod.def.catchall,checks:[]})}function zC(e,t,r){let n=t._zod.def.shape,o={...n};if(r)for(let i in r){if(!(i in n))throw Error(`Unrecognized key: "${i}"`);if(!r[i])continue;o[i]=e?new e({type:"optional",innerType:n[i]}):n[i]}else for(let i in n)o[i]=e?new e({type:"optional",innerType:n[i]}):n[i];return $t(t,{...t._zod.def,shape:o,checks:[]})}function OC(e,t,r){let n=t._zod.def.shape,o={...n};if(r)for(let i in r){if(!(i in o))throw Error(`Unrecognized key: "${i}"`);if(!r[i])continue;o[i]=new e({type:"nonoptional",innerType:n[i]})}else for(let i in n)o[i]=new e({type:"nonoptional",innerType:n[i]});return $t(t,{...t._zod.def,shape:o,checks:[]})}function gn(e,t=0){for(let r=t;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}function ar(e,t){return t.map((r)=>{var n;return(n=r).path??(n.path=[]),r.path.unshift(e),r})}function vi(e){return typeof e==="string"?e:e?.message}function Vt(e,t,r){let n={...e,path:e.path??[]};if(!e.message){let o=vi(e.inst?._zod.def?.error?.(e))??vi(t?.error?.(e))??vi(r.customError?.(e))??vi(r.localeError?.(e))??"Invalid input";n.message=o}if(delete n.inst,delete n.continue,!t?.reportInput)delete n.input;return n}function Fv(e){if(e instanceof Set)return"set";if(e instanceof Map)return"map";if(e instanceof File)return"file";return"unknown"}function ki(e){if(Array.isArray(e))return"array";if(typeof e==="string")return"string";return"unknown"}function wl(...e){let[t,r,n]=e;if(typeof t==="string")return{message:t,code:"custom",input:r,inst:n};return{...t}}function AC(e){return Object.entries(e).filter(([t,r])=>Number.isNaN(Number.parseInt(t,10))).map((t)=>t[1])}class Zv{constructor(...e){}}var Bv=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),Object.defineProperty(e,"message",{get(){return JSON.stringify(t,hl,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ia=S("$ZodError",Bv),Si=S("$ZodError",Bv,{Parent:Error});function kl(e,t=(r)=>r.message){let r={},n=[];for(let o of e.issues)if(o.path.length>0)r[o.path[0]]=r[o.path[0]]||[],r[o.path[0]].push(t(o));else n.push(t(o));return{formErrors:n,fieldErrors:r}}function Sl(e,t){let r=t||function(i){return i.message},n={_errors:[]},o=(i)=>{for(let s of i.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map((a)=>o({issues:a}));else if(s.code==="invalid_key")o({issues:s.issues});else if(s.code==="invalid_element")o({issues:s.issues});else if(s.path.length===0)n._errors.push(r(s));else{let a=n,c=0;while(c<s.path.length){let u=s.path[c];if(c!==s.path.length-1)a[u]=a[u]||{_errors:[]};else a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s));a=a[u],c++}}};return o(e),n}var $l=(e)=>(t,r,n,o)=>{let i=n?Object.assign(n,{async:!1}):{async:!1},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)throw new Ar;if(s.issues.length){let a=new(o?.Err??e)(s.issues.map((c)=>Vt(c,i,St())));throw na(a,o?.callee),a}return s.value},Tl=$l(Si),El=(e)=>async(t,r,n,o)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)s=await s;if(s.issues.length){let a=new(o?.Err??e)(s.issues.map((c)=>Vt(c,i,St())));throw na(a,o?.callee),a}return s.value},Rl=El(Si),Pl=(e)=>(t,r,n)=>{let o=n?{...n,async:!1}:{async:!1},i=t._zod.run({value:r,issues:[]},o);if(i instanceof Promise)throw new Ar;return i.issues.length?{success:!1,error:new(e??ia)(i.issues.map((s)=>Vt(s,o,St())))}:{success:!0,data:i.value}},xn=Pl(Si),zl=(e)=>async(t,r,n)=>{let o=n?Object.assign(n,{async:!0}):{async:!0},i=t._zod.run({value:r,issues:[]},o);if(i instanceof Promise)i=await i;return i.issues.length?{success:!1,error:new e(i.issues.map((s)=>Vt(s,o,St())))}:{success:!0,data:i.value}},vn=zl(Si);var Hv=/^[cC][^\s-]{8,}$/,Vv=/^[0-9a-z]+$/,Gv=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Jv=/^[0-9a-vA-V]{20}$/,Wv=/^[A-Za-z0-9]{27}$/,Kv=/^[a-zA-Z0-9_-]{21}$/,Yv=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/;var Xv=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,Ol=(e)=>{if(!e)return/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/;return new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`)};var Qv=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/;function ey(){return new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")}var ty=/^(?:(?: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])$/,ry=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})$/,ny=/^((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])\/([0-9]|[1-2][0-9]|3[0-2])$/,oy=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,iy=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Al=/^[A-Za-z0-9_-]*$/,sy=/^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/;var ay=/^\+(?:[0-9]){6,14}[0-9]$/,cy="(?:(?:\\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])))",uy=new RegExp(`^${cy}$`);function ly(e){return typeof e.precision==="number"?e.precision===-1?"(?:[01]\\d|2[0-3]):[0-5]\\d":e.precision===0?"(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d":`(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d\\.\\d{${e.precision}}`:"(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?"}function py(e){return new RegExp(`^${ly(e)}$`)}function dy(e){let t=ly({precision:e.precision}),r=["Z"];if(e.local)r.push("");if(e.offset)r.push("([+-]\\d{2}:\\d{2})");let n=`${t}(?:${r.join("|")})`;return new RegExp(`^${cy}T(?:${n})$`)}var my=(e)=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)};var fy=/^\d+$/,hy=/^-?\d+(?:\.\d+)?/i,gy=/true|false/i,xy=/null/i;var vy=/^[^A-Z]*$/,yy=/^[^a-z]*$/;var Ye=S("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),by={number:"number",bigint:"bigint",object:"date"},Cl=S("$ZodCheckLessThan",(e,t)=>{Ye.init(e,t);let r=by[typeof t.value];e._zod.onattach.push((n)=>{let o=n._zod.bag,i=(t.inclusive?o.maximum:o.exclusiveMaximum)??Number.POSITIVE_INFINITY;if(t.value<i)if(t.inclusive)o.maximum=t.value;else o.exclusiveMaximum=t.value}),e._zod.check=(n)=>{if(t.inclusive?n.value<=t.value:n.value<t.value)return;n.issues.push({origin:r,code:"too_big",maximum:t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Il=S("$ZodCheckGreaterThan",(e,t)=>{Ye.init(e,t);let r=by[typeof t.value];e._zod.onattach.push((n)=>{let o=n._zod.bag,i=(t.inclusive?o.minimum:o.exclusiveMinimum)??Number.NEGATIVE_INFINITY;if(t.value>i)if(t.inclusive)o.minimum=t.value;else o.exclusiveMinimum=t.value}),e._zod.check=(n)=>{if(t.inclusive?n.value>=t.value:n.value>t.value)return;n.issues.push({origin:r,code:"too_small",minimum:t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),_y=S("$ZodCheckMultipleOf",(e,t)=>{Ye.init(e,t),e._zod.onattach.push((r)=>{var n;(n=r._zod.bag).multipleOf??(n.multipleOf=t.value)}),e._zod.check=(r)=>{if(typeof r.value!==typeof t.value)throw Error("Cannot mix number and bigint in multiple_of check.");if(typeof r.value==="bigint"?r.value%t.value===BigInt(0):gl(r.value,t.value)===0)return;r.issues.push({origin:typeof r.value,code:"not_multiple_of",divisor:t.value,input:r.value,inst:e,continue:!t.abort})}}),wy=S("$ZodCheckNumberFormat",(e,t)=>{Ye.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),n=r?"int":"number",[o,i]=_l[t.format];e._zod.onattach.push((s)=>{let a=s._zod.bag;if(a.format=t.format,a.minimum=o,a.maximum=i,r)a.pattern=fy}),e._zod.check=(s)=>{let a=s.value;if(r){if(!Number.isInteger(a)){s.issues.push({expected:n,format:t.format,code:"invalid_type",input:a,inst:e});return}if(!Number.isSafeInteger(a)){if(a>0)s.issues.push({input:a,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,continue:!t.abort});else s.issues.push({input:a,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,continue:!t.abort});return}}if(a<o)s.issues.push({origin:"number",input:a,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort});if(a>i)s.issues.push({origin:"number",input:a,code:"too_big",maximum:i,inst:e})}});var ky=S("$ZodCheckMaxLength",(e,t)=>{var r;Ye.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!_i(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag.maximum??Number.POSITIVE_INFINITY;if(t.maximum<o)n._zod.bag.maximum=t.maximum}),e._zod.check=(n)=>{let o=n.value;if(o.length<=t.maximum)return;let s=ki(o);n.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),Sy=S("$ZodCheckMinLength",(e,t)=>{var r;Ye.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!_i(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(t.minimum>o)n._zod.bag.minimum=t.minimum}),e._zod.check=(n)=>{let o=n.value;if(o.length>=t.minimum)return;let s=ki(o);n.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),$y=S("$ZodCheckLengthEquals",(e,t)=>{var r;Ye.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!_i(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.minimum=t.length,o.maximum=t.length,o.length=t.length}),e._zod.check=(n)=>{let o=n.value,i=o.length;if(i===t.length)return;let s=ki(o),a=i>t.length;n.issues.push({origin:s,...a?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),$i=S("$ZodCheckStringFormat",(e,t)=>{var r,n;if(Ye.init(e,t),e._zod.onattach.push((o)=>{let i=o._zod.bag;if(i.format=t.format,t.pattern)i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern)}),t.pattern)(r=e._zod).check??(r.check=(o)=>{if(t.pattern.lastIndex=0,t.pattern.test(o.value))return;o.issues.push({origin:"string",code:"invalid_format",format:t.format,input:o.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})});else(n=e._zod).check??(n.check=()=>{})}),Ty=S("$ZodCheckRegex",(e,t)=>{$i.init(e,t),e._zod.check=(r)=>{if(t.pattern.lastIndex=0,t.pattern.test(r.value))return;r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Ey=S("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=vy),$i.init(e,t)}),Ry=S("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=yy),$i.init(e,t)}),Py=S("$ZodCheckIncludes",(e,t)=>{Ye.init(e,t);let r=Cr(t.includes),n=new RegExp(typeof t.position==="number"?`^.{${t.position}}${r}`:r);t.pattern=n,e._zod.onattach.push((o)=>{let i=o._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(n)}),e._zod.check=(o)=>{if(o.value.includes(t.includes,t.position))return;o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),zy=S("$ZodCheckStartsWith",(e,t)=>{Ye.init(e,t);let r=new RegExp(`^${Cr(t.prefix)}.*`);t.pattern??(t.pattern=r),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(r)}),e._zod.check=(n)=>{if(n.value.startsWith(t.prefix))return;n.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:n.value,inst:e,continue:!t.abort})}}),Oy=S("$ZodCheckEndsWith",(e,t)=>{Ye.init(e,t);let r=new RegExp(`.*${Cr(t.suffix)}$`);t.pattern??(t.pattern=r),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(r)}),e._zod.check=(n)=>{if(n.value.endsWith(t.suffix))return;n.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:n.value,inst:e,continue:!t.abort})}});var Ay=S("$ZodCheckOverwrite",(e,t)=>{Ye.init(e,t),e._zod.check=(r)=>{r.value=t.tx(r.value)}});class jl{constructor(e=[]){if(this.content=[],this.indent=0,this)this.args=e}indented(e){this.indent+=1,e(this),this.indent-=1}write(e){if(typeof e==="function"){e(this,{execution:"sync"}),e(this,{execution:"async"});return}let r=e.split(`
|
|
35
|
+
`+o}}catch(i){}}throw r}}_request(e,t){if(typeof e==="string")t=t||{},t.url=e;else t=e||{};t=Ht(this.defaults,t);let{transitional:r,paramsSerializer:n,headers:o}=t;if(r!==void 0)Ko.assertOptions(r,{silentJSONParsing:ot.transitional(ot.boolean),forcedJSONParsing:ot.transitional(ot.boolean),clarifyTimeoutError:ot.transitional(ot.boolean),legacyInterceptorReqResOrdering:ot.transitional(ot.boolean),advertiseZstdAcceptEncoding:ot.transitional(ot.boolean),validateStatusUndefinedResolves:ot.transitional(ot.boolean)},!1);if(n!=null)if(f.isFunction(n))t.paramsSerializer={serialize:n};else Ko.assertOptions(n,{encode:ot.function,serialize:ot.function},!0);if(t.allowAbsoluteUrls!==void 0);else if(this.defaults.allowAbsoluteUrls!==void 0)t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls;else t.allowAbsoluteUrls=!0;Ko.assertOptions(t,{baseUrl:ot.spelling("baseURL"),withXsrfToken:ot.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&f.merge(o.common,o[t.method]);o&&f.forEach(["delete","get","head","post","put","patch","query","common"],(d)=>{delete o[d]}),t.headers=be.concat(i,o);let s=[],a=!0;this.interceptors.request.forEach(function(h){if(typeof h.runWhen==="function"&&h.runWhen(t)===!1)return;a=a&&h.synchronous;let x=t.transitional||Er;if(x&&x.legacyInterceptorReqResOrdering)s.unshift(h.fulfilled,h.rejected);else s.push(h.fulfilled,h.rejected)});let c=[];this.interceptors.response.forEach(function(h){c.push(h.fulfilled,h.rejected)});let u,l=0,p;if(!a){let d=[Ds.bind(this),void 0];d.unshift(...s),d.push(...c),p=d.length,u=Promise.resolve(t);while(l<p)u=u.then(d[l++],d[l++]);return u}p=s.length;let m=t;while(l<p){let d=s[l++],h=s[l++];try{m=d(m)}catch(x){h.call(this,x);break}}try{u=Ds.call(this,m)}catch(d){return Promise.reject(d)}l=0,p=c.length;while(l<p)u=u.then(c[l++],c[l++]);return u}getUri(e){e=Ht(this.defaults,e);let t=en(e.baseURL,e.url,e.allowAbsoluteUrls,e);return Qr(t,e.params,e.paramsSerializer)}}f.forEach(["delete","get","head","options"],function(t){Yo.prototype[t]=function(r,n){return this.request(Ht(n||{},{method:t,url:r,data:n&&f.hasOwnProp(n,"data")?n.data:void 0}))}});f.forEach(["post","put","patch","query"],function(t){function r(n){return function(i,s,a){return this.request(Ht(a||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:s}))}}if(Yo.prototype[t]=r(),t!=="query")Yo.prototype[t+"Form"]=r(!0)});var Xo=Yo;class nl{constructor(e){if(typeof e!=="function")throw TypeError("executor must be a function.");let t;this.promise=new Promise(function(o){t=o});let r=this;this.promise.then((n)=>{if(!r._listeners)return;let o=r._listeners.length;while(o-- >0)r._listeners[o](n);r._listeners=null}),this.promise.then=(n)=>{let o,i=new Promise((s)=>{r.subscribe(s),o=s}).then(n);return i.cancel=function(){r.unsubscribe(o)},i},e(function(o,i,s){if(r.reason)return;r.reason=new kt(o,i,s),t(r.reason)})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}if(this._listeners)this._listeners.push(e);else this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;let t=this._listeners.indexOf(e);if(t!==-1)this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=(r)=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new nl(function(n){e=n}),cancel:e}}}var fv=nl;function ol(e){return function(r){return e.apply(null,r)}}function il(e){return f.isObject(e)&&e.isAxiosError===!0}var sl={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(sl).forEach(([e,t])=>{sl[t]=e});var hv=sl;function gv(e){let t=new Xo(e),r=$o(Xo.prototype.request,t);return f.extend(r,Xo.prototype,t,{allOwnKeys:!0}),f.extend(r,t,null,{allOwnKeys:!0}),r.create=function(o){return gv(Ht(e,o))},r}var Ue=gv(Nn);Ue.Axios=Xo;Ue.CanceledError=kt;Ue.CancelToken=fv;Ue.isCancel=No;Ue.VERSION=ur;Ue.toFormData=Tr;Ue.AxiosError=S;Ue.Cancel=Ue.CanceledError;Ue.all=function(t){return Promise.all(t)};Ue.spread=ol;Ue.isAxiosError=il;Ue.mergeConfig=Ht;Ue.AxiosHeaders=be;Ue.formToJSON=(e)=>$s(f.isHTMLForm(e)?new FormData(e):e);Ue.getAdapter=Ns.getAdapter;Ue.HttpStatusCode=hv;Ue.default=Ue;var Qo=Ue;var{Axios:W6,AxiosError:K6,CanceledError:Y6,isCancel:X6,CancelToken:Q6,VERSION:eH,all:tH,Cancel:rH,isAxiosError:nH,spread:oH,toFormData:iH,AxiosHeaders:sH,HttpStatusCode:aH,formToJSON:cH,getAdapter:uH,mergeConfig:lH,create:pH}=Qo;var te;(function(e){e.assertEqual=(o)=>{};function t(o){}e.assertIs=t;function r(o){throw Error()}e.assertNever=r,e.arrayToEnum=(o)=>{let i={};for(let s of o)i[s]=s;return i},e.getValidEnumValues=(o)=>{let i=e.objectKeys(o).filter((a)=>typeof o[o[a]]!=="number"),s={};for(let a of i)s[a]=o[a];return e.objectValues(s)},e.objectValues=(o)=>e.objectKeys(o).map(function(i){return o[i]}),e.objectKeys=typeof Object.keys==="function"?(o)=>Object.keys(o):(o)=>{let i=[];for(let s in o)if(Object.prototype.hasOwnProperty.call(o,s))i.push(s);return i},e.find=(o,i)=>{for(let s of o)if(i(s))return s;return},e.isInteger=typeof Number.isInteger==="function"?(o)=>Number.isInteger(o):(o)=>typeof o==="number"&&Number.isFinite(o)&&Math.floor(o)===o;function n(o,i=" | "){return o.map((s)=>typeof s==="string"?`'${s}'`:s).join(i)}e.joinValues=n,e.jsonStringifyReplacer=(o,i)=>{if(typeof i==="bigint")return i.toString();return i}})(te||(te={}));var xv;(function(e){e.mergeShapes=(t,r)=>({...t,...r})})(xv||(xv={}));var C=te.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),pr=(e)=>{switch(typeof e){case"undefined":return C.undefined;case"string":return C.string;case"number":return Number.isNaN(e)?C.nan:C.number;case"boolean":return C.boolean;case"function":return C.function;case"bigint":return C.bigint;case"symbol":return C.symbol;case"object":if(Array.isArray(e))return C.array;if(e===null)return C.null;if(e.then&&typeof e.then==="function"&&e.catch&&typeof e.catch==="function")return C.promise;if(typeof Map<"u"&&e instanceof Map)return C.map;if(typeof Set<"u"&&e instanceof Set)return C.set;if(typeof Date<"u"&&e instanceof Date)return C.date;return C.object;default:return C.unknown}};var R=te.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 St extends Error{get errors(){return this.issues}constructor(e){super();this.issues=[],this.addIssue=(r)=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};let t=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,t);else this.__proto__=t;this.name="ZodError",this.issues=e}format(e){let t=e||function(o){return o.message},r={_errors:[]},n=(o)=>{for(let i of o.issues)if(i.code==="invalid_union")i.unionErrors.map(n);else if(i.code==="invalid_return_type")n(i.returnTypeError);else if(i.code==="invalid_arguments")n(i.argumentsError);else if(i.path.length===0)r._errors.push(t(i));else{let s=r,a=0;while(a<i.path.length){let c=i.path[a];if(a!==i.path.length-1)s[c]=s[c]||{_errors:[]};else s[c]=s[c]||{_errors:[]},s[c]._errors.push(t(i));s=s[c],a++}}};return n(this),r}static assert(e){if(!(e instanceof St))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,te.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(e=(t)=>t.message){let t={},r=[];for(let n of this.issues)if(n.path.length>0){let o=n.path[0];t[o]=t[o]||[],t[o].push(e(n))}else r.push(e(n));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}St.create=(e)=>new St(e);var qz=(e,t)=>{let r;switch(e.code){case R.invalid_type:if(e.received===C.undefined)r="Required";else r=`Expected ${e.expected}, received ${e.received}`;break;case R.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,te.jsonStringifyReplacer)}`;break;case R.unrecognized_keys:r=`Unrecognized key(s) in object: ${te.joinValues(e.keys,", ")}`;break;case R.invalid_union:r="Invalid input";break;case R.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${te.joinValues(e.options)}`;break;case R.invalid_enum_value:r=`Invalid enum value. Expected ${te.joinValues(e.options)}, received '${e.received}'`;break;case R.invalid_arguments:r="Invalid function arguments";break;case R.invalid_return_type:r="Invalid function return type";break;case R.invalid_date:r="Invalid date";break;case R.invalid_string:if(typeof e.validation==="object")if("includes"in e.validation){if(r=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position==="number")r=`${r} at one or more positions greater than or equal to ${e.validation.position}`}else if("startsWith"in e.validation)r=`Invalid input: must start with "${e.validation.startsWith}"`;else if("endsWith"in e.validation)r=`Invalid input: must end with "${e.validation.endsWith}"`;else te.assertNever(e.validation);else if(e.validation!=="regex")r=`Invalid ${e.validation}`;else r="Invalid";break;case R.too_small:if(e.type==="array")r=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`;else if(e.type==="string")r=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`;else if(e.type==="number")r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`;else if(e.type==="bigint")r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`;else if(e.type==="date")r=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`;else r="Invalid input";break;case R.too_big:if(e.type==="array")r=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`;else if(e.type==="string")r=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`;else if(e.type==="number")r=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`;else if(e.type==="bigint")r=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`;else if(e.type==="date")r=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`;else r="Invalid input";break;case R.custom:r="Invalid input";break;case R.invalid_intersection_types:r="Intersection results could not be merged";break;case R.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case R.not_finite:r="Number must be finite";break;default:r=t.defaultError,te.assertNever(e)}return{message:r}},Pr=qz;var Uz=Pr;function ei(){return Uz}var Ls=(e)=>{let{data:t,path:r,errorMaps:n,issueData:o}=e,i=[...r,...o.path||[]],s={...o,path:i};if(o.message!==void 0)return{...o,path:i,message:o.message};let a="",c=n.filter((u)=>!!u).slice().reverse();for(let u of c)a=u(s,{data:t,defaultError:a}).message;return{...o,path:i,message:a}};function A(e,t){let r=ei(),n=Ls({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===Pr?void 0:Pr].filter((o)=>!!o)});e.common.issues.push(n)}class it{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray(e,t){let r=[];for(let n of t){if(n.status==="aborted")return F;if(n.status==="dirty")e.dirty();r.push(n.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let n of t){let o=await n.key,i=await n.value;r.push({key:o,value:i})}return it.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let n of t){let{key:o,value:i}=n;if(o.status==="aborted")return F;if(i.status==="aborted")return F;if(o.status==="dirty")e.dirty();if(i.status==="dirty")e.dirty();if(o.value!=="__proto__"&&(typeof i.value<"u"||n.alwaysSet))r[o.value]=i.value}return{status:e.value,value:r}}}var F=Object.freeze({status:"aborted"}),Zn=(e)=>({status:"dirty",value:e}),at=(e)=>({status:"valid",value:e}),al=(e)=>e.status==="aborted",cl=(e)=>e.status==="dirty",cn=(e)=>e.status==="valid",ti=(e)=>typeof Promise<"u"&&e instanceof Promise;var N;(function(e){e.errToObj=(t)=>typeof t==="string"?{message:t}:t||{},e.toString=(t)=>typeof t==="string"?t:t?.message})(N||(N={}));class Vt{constructor(e,t,r,n){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=n}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}var vv=(e,t)=>{if(cn(t))return{success:!0,data:t.value};else{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 r=new St(e.common.issues);return this._error=r,this._error}}}};function V(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:n,description:o}=e;if(t&&(r||n))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(t)return{errorMap:t,description:o};return{errorMap:(s,a)=>{let{message:c}=e;if(s.code==="invalid_enum_value")return{message:c??a.defaultError};if(typeof a.data>"u")return{message:c??n??a.defaultError};if(s.code!=="invalid_type")return{message:a.defaultError};return{message:c??r??a.defaultError}},description:o}}class Y{get description(){return this._def.description}_getType(e){return pr(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new it,ctx:{common:e.parent.common,data:e.data,parsedType:pr(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(ti(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){let t=this._parse(e);return Promise.resolve(t)}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:pr(e)},n=this._parseSync({data:e,path:r.path,parent:r});return vv(r,n)}"~validate"(e){let t={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:pr(e)};if(!this["~standard"].async)try{let r=this._parseSync({data:e,path:[],parent:t});return cn(r)?{value:r.value}:{issues:t.common.issues}}catch(r){if(r?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;t.common={issues:[],async:!0}}return this._parseAsync({data:e,path:[],parent:t}).then((r)=>cn(r)?{value:r.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:pr(e)},n=this._parse({data:e,path:r.path,parent:r}),o=await(ti(n)?n:Promise.resolve(n));return vv(r,o)}refine(e,t){let r=(n)=>{if(typeof t==="string"||typeof t>"u")return{message:t};else if(typeof t==="function")return t(n);else return t};return this._refinement((n,o)=>{let i=e(n),s=()=>o.addIssue({code:R.custom,...r(n)});if(typeof Promise<"u"&&i instanceof Promise)return i.then((a)=>{if(!a)return s(),!1;else return!0});if(!i)return s(),!1;else return!0})}refinement(e,t){return this._refinement((r,n)=>{if(!e(r))return n.addIssue(typeof t==="function"?t(r,n):t),!1;else return!0})}_refinement(e){return new ir({schema:this,typeName:z.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:(t)=>this["~validate"](t)}}optional(){return Ct.create(this,this._def)}nullable(){return zr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return or.create(this)}promise(){return Jn.create(this,this._def)}or(e){return si.create([this,e],this._def)}and(e){return ai.create(this,e,this._def)}transform(e){return new ir({...V(this._def),schema:this,typeName:z.ZodEffects,effect:{type:"transform",transform:e}})}default(e){let t=typeof e==="function"?e:()=>e;return new pi({...V(this._def),innerType:this,defaultValue:t,typeName:z.ZodDefault})}brand(){return new dl({typeName:z.ZodBranded,type:this,...V(this._def)})}catch(e){let t=typeof e==="function"?e:()=>e;return new di({...V(this._def),innerType:this,catchValue:t,typeName:z.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return Gs.create(this,e)}readonly(){return mi.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}var Fz=/^c[^\s-]{8,}$/i,Zz=/^[0-9a-z]+$/,Bz=/^[0-9A-HJKMNP-TV-Z]{26}$/i,Hz=/^[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,Vz=/^[a-z0-9_-]{21}$/i,Gz=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,Jz=/^[-+]?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)?)??$/,Wz=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,Kz="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",ul,Yz=/^(?:(?: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])$/,Xz=/^(?:(?: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])$/,Qz=/^(([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]))$/,eO=/^(([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])$/,tO=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,rO=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,yv="((\\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])))",nO=new RegExp(`^${yv}$`);function bv(e){let t="[0-5]\\d";if(e.precision)t=`${t}\\.\\d{${e.precision}}`;else if(e.precision==null)t=`${t}(\\.\\d+)?`;let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}function oO(e){return new RegExp(`^${bv(e)}$`)}function iO(e){let t=`${yv}T${bv(e)}`,r=[];if(r.push(e.local?"Z?":"Z"),e.offset)r.push("([+-]\\d{2}:?\\d{2})");return t=`${t}(${r.join("|")})`,new RegExp(`^${t}$`)}function sO(e,t){if((t==="v4"||!t)&&Yz.test(e))return!0;if((t==="v6"||!t)&&Qz.test(e))return!0;return!1}function aO(e,t){if(!Gz.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let n=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),o=JSON.parse(atob(n));if(typeof o!=="object"||o===null)return!1;if("typ"in o&&o?.typ!=="JWT")return!1;if(!o.alg)return!1;if(t&&o.alg!==t)return!1;return!0}catch{return!1}}function cO(e,t){if((t==="v4"||!t)&&Xz.test(e))return!0;if((t==="v6"||!t)&&eO.test(e))return!0;return!1}class mr extends Y{_parse(e){if(this._def.coerce)e.data=String(e.data);if(this._getType(e)!==C.string){let o=this._getOrReturnCtx(e);return A(o,{code:R.invalid_type,expected:C.string,received:o.parsedType}),F}let r=new it,n=void 0;for(let o of this._def.checks)if(o.kind==="min"){if(e.data.length<o.value)n=this._getOrReturnCtx(e,n),A(n,{code:R.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty()}else if(o.kind==="max"){if(e.data.length>o.value)n=this._getOrReturnCtx(e,n),A(n,{code:R.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty()}else if(o.kind==="length"){let i=e.data.length>o.value,s=e.data.length<o.value;if(i||s){if(n=this._getOrReturnCtx(e,n),i)A(n,{code:R.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message});else if(s)A(n,{code:R.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message});r.dirty()}}else if(o.kind==="email"){if(!Wz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"email",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="emoji"){if(!ul)ul=new RegExp(Kz,"u");if(!ul.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"emoji",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="uuid"){if(!Hz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"uuid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="nanoid"){if(!Vz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"nanoid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cuid"){if(!Fz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"cuid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cuid2"){if(!Zz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"cuid2",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="ulid"){if(!Bz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"ulid",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="url")try{new URL(e.data)}catch{n=this._getOrReturnCtx(e,n),A(n,{validation:"url",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="regex"){if(o.regex.lastIndex=0,!o.regex.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"regex",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="trim")e.data=e.data.trim();else if(o.kind==="includes"){if(!e.data.includes(o.value,o.position))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),r.dirty()}else if(o.kind==="toLowerCase")e.data=e.data.toLowerCase();else if(o.kind==="toUpperCase")e.data=e.data.toUpperCase();else if(o.kind==="startsWith"){if(!e.data.startsWith(o.value))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:{startsWith:o.value},message:o.message}),r.dirty()}else if(o.kind==="endsWith"){if(!e.data.endsWith(o.value))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:{endsWith:o.value},message:o.message}),r.dirty()}else if(o.kind==="datetime"){if(!iO(o).test(e.data))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:"datetime",message:o.message}),r.dirty()}else if(o.kind==="date"){if(!nO.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:"date",message:o.message}),r.dirty()}else if(o.kind==="time"){if(!oO(o).test(e.data))n=this._getOrReturnCtx(e,n),A(n,{code:R.invalid_string,validation:"time",message:o.message}),r.dirty()}else if(o.kind==="duration"){if(!Jz.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"duration",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="ip"){if(!sO(e.data,o.version))n=this._getOrReturnCtx(e,n),A(n,{validation:"ip",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="jwt"){if(!aO(e.data,o.alg))n=this._getOrReturnCtx(e,n),A(n,{validation:"jwt",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="cidr"){if(!cO(e.data,o.version))n=this._getOrReturnCtx(e,n),A(n,{validation:"cidr",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="base64"){if(!tO.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"base64",code:R.invalid_string,message:o.message}),r.dirty()}else if(o.kind==="base64url"){if(!rO.test(e.data))n=this._getOrReturnCtx(e,n),A(n,{validation:"base64url",code:R.invalid_string,message:o.message}),r.dirty()}else te.assertNever(o);return{status:r.value,value:e.data}}_regex(e,t,r){return this.refinement((n)=>e.test(n),{validation:t,code:R.invalid_string,...N.errToObj(r)})}_addCheck(e){return new mr({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...N.errToObj(e)})}url(e){return this._addCheck({kind:"url",...N.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...N.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...N.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...N.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...N.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...N.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...N.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...N.errToObj(e)})}base64url(e){return this._addCheck({kind:"base64url",...N.errToObj(e)})}jwt(e){return this._addCheck({kind:"jwt",...N.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...N.errToObj(e)})}cidr(e){return this._addCheck({kind:"cidr",...N.errToObj(e)})}datetime(e){if(typeof e==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e});return this._addCheck({kind:"datetime",precision:typeof e?.precision>"u"?null:e?.precision,offset:e?.offset??!1,local:e?.local??!1,...N.errToObj(e?.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){if(typeof e==="string")return this._addCheck({kind:"time",precision:null,message:e});return this._addCheck({kind:"time",precision:typeof e?.precision>"u"?null:e?.precision,...N.errToObj(e?.message)})}duration(e){return this._addCheck({kind:"duration",...N.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...N.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:t?.position,...N.errToObj(t?.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...N.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...N.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...N.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...N.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...N.errToObj(t)})}nonempty(e){return this.min(1,N.errToObj(e))}trim(){return new mr({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new mr({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new mr({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find((e)=>e.kind==="datetime")}get isDate(){return!!this._def.checks.find((e)=>e.kind==="date")}get isTime(){return!!this._def.checks.find((e)=>e.kind==="time")}get isDuration(){return!!this._def.checks.find((e)=>e.kind==="duration")}get isEmail(){return!!this._def.checks.find((e)=>e.kind==="email")}get isURL(){return!!this._def.checks.find((e)=>e.kind==="url")}get isEmoji(){return!!this._def.checks.find((e)=>e.kind==="emoji")}get isUUID(){return!!this._def.checks.find((e)=>e.kind==="uuid")}get isNANOID(){return!!this._def.checks.find((e)=>e.kind==="nanoid")}get isCUID(){return!!this._def.checks.find((e)=>e.kind==="cuid")}get isCUID2(){return!!this._def.checks.find((e)=>e.kind==="cuid2")}get isULID(){return!!this._def.checks.find((e)=>e.kind==="ulid")}get isIP(){return!!this._def.checks.find((e)=>e.kind==="ip")}get isCIDR(){return!!this._def.checks.find((e)=>e.kind==="cidr")}get isBase64(){return!!this._def.checks.find((e)=>e.kind==="base64")}get isBase64url(){return!!this._def.checks.find((e)=>e.kind==="base64url")}get minLength(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxLength(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}}mr.create=(e)=>new mr({checks:[],typeName:z.ZodString,coerce:e?.coerce??!1,...V(e)});function uO(e,t){let r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,o=r>n?r:n,i=Number.parseInt(e.toFixed(o).replace(".","")),s=Number.parseInt(t.toFixed(o).replace(".",""));return i%s/10**o}class Hn extends Y{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){if(this._def.coerce)e.data=Number(e.data);if(this._getType(e)!==C.number){let o=this._getOrReturnCtx(e);return A(o,{code:R.invalid_type,expected:C.number,received:o.parsedType}),F}let r=void 0,n=new it;for(let o of this._def.checks)if(o.kind==="int"){if(!te.isInteger(e.data))r=this._getOrReturnCtx(e,r),A(r,{code:R.invalid_type,expected:"integer",received:"float",message:o.message}),n.dirty()}else if(o.kind==="min"){if(o.inclusive?e.data<o.value:e.data<=o.value)r=this._getOrReturnCtx(e,r),A(r,{code:R.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()}else if(o.kind==="max"){if(o.inclusive?e.data>o.value:e.data>=o.value)r=this._getOrReturnCtx(e,r),A(r,{code:R.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),n.dirty()}else if(o.kind==="multipleOf"){if(uO(e.data,o.value)!==0)r=this._getOrReturnCtx(e,r),A(r,{code:R.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()}else if(o.kind==="finite"){if(!Number.isFinite(e.data))r=this._getOrReturnCtx(e,r),A(r,{code:R.not_finite,message:o.message}),n.dirty()}else te.assertNever(o);return{status:n.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,N.toString(t))}gt(e,t){return this.setLimit("min",e,!1,N.toString(t))}lte(e,t){return this.setLimit("max",e,!0,N.toString(t))}lt(e,t){return this.setLimit("max",e,!1,N.toString(t))}setLimit(e,t,r,n){return new Hn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:N.toString(n)}]})}_addCheck(e){return new Hn({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:N.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:N.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:N.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:N.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:N.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:N.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:N.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:N.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:N.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxValue(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}get isInt(){return!!this._def.checks.find((e)=>e.kind==="int"||e.kind==="multipleOf"&&te.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks)if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;else if(r.kind==="min"){if(t===null||r.value>t)t=r.value}else if(r.kind==="max"){if(e===null||r.value<e)e=r.value}return Number.isFinite(t)&&Number.isFinite(e)}}Hn.create=(e)=>new Hn({checks:[],typeName:z.ZodNumber,coerce:e?.coerce||!1,...V(e)});class Vn extends Y{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse(e){if(this._def.coerce)try{e.data=BigInt(e.data)}catch{return this._getInvalidInput(e)}if(this._getType(e)!==C.bigint)return this._getInvalidInput(e);let r=void 0,n=new it;for(let o of this._def.checks)if(o.kind==="min"){if(o.inclusive?e.data<o.value:e.data<=o.value)r=this._getOrReturnCtx(e,r),A(r,{code:R.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()}else if(o.kind==="max"){if(o.inclusive?e.data>o.value:e.data>=o.value)r=this._getOrReturnCtx(e,r),A(r,{code:R.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),n.dirty()}else if(o.kind==="multipleOf"){if(e.data%o.value!==BigInt(0))r=this._getOrReturnCtx(e,r),A(r,{code:R.not_multiple_of,multipleOf:o.value,message:o.message}),n.dirty()}else te.assertNever(o);return{status:n.value,value:e.data}}_getInvalidInput(e){let t=this._getOrReturnCtx(e);return A(t,{code:R.invalid_type,expected:C.bigint,received:t.parsedType}),F}gte(e,t){return this.setLimit("min",e,!0,N.toString(t))}gt(e,t){return this.setLimit("min",e,!1,N.toString(t))}lte(e,t){return this.setLimit("max",e,!0,N.toString(t))}lt(e,t){return this.setLimit("max",e,!1,N.toString(t))}setLimit(e,t,r,n){return new Vn({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:N.toString(n)}]})}_addCheck(e){return new Vn({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:N.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:N.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:N.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:N.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:N.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e}get maxValue(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e}}Vn.create=(e)=>new Vn({checks:[],typeName:z.ZodBigInt,coerce:e?.coerce??!1,...V(e)});class qs extends Y{_parse(e){if(this._def.coerce)e.data=Boolean(e.data);if(this._getType(e)!==C.boolean){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.boolean,received:r.parsedType}),F}return at(e.data)}}qs.create=(e)=>new qs({typeName:z.ZodBoolean,coerce:e?.coerce||!1,...V(e)});class ni extends Y{_parse(e){if(this._def.coerce)e.data=new Date(e.data);if(this._getType(e)!==C.date){let o=this._getOrReturnCtx(e);return A(o,{code:R.invalid_type,expected:C.date,received:o.parsedType}),F}if(Number.isNaN(e.data.getTime())){let o=this._getOrReturnCtx(e);return A(o,{code:R.invalid_date}),F}let r=new it,n=void 0;for(let o of this._def.checks)if(o.kind==="min"){if(e.data.getTime()<o.value)n=this._getOrReturnCtx(e,n),A(n,{code:R.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),r.dirty()}else if(o.kind==="max"){if(e.data.getTime()>o.value)n=this._getOrReturnCtx(e,n),A(n,{code:R.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),r.dirty()}else te.assertNever(o);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new ni({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:N.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:N.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)if(t.kind==="min"){if(e===null||t.value>e)e=t.value}return e!=null?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)if(t.kind==="max"){if(e===null||t.value<e)e=t.value}return e!=null?new Date(e):null}}ni.create=(e)=>new ni({checks:[],coerce:e?.coerce||!1,typeName:z.ZodDate,...V(e)});class Us extends Y{_parse(e){if(this._getType(e)!==C.symbol){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.symbol,received:r.parsedType}),F}return at(e.data)}}Us.create=(e)=>new Us({typeName:z.ZodSymbol,...V(e)});class oi extends Y{_parse(e){if(this._getType(e)!==C.undefined){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.undefined,received:r.parsedType}),F}return at(e.data)}}oi.create=(e)=>new oi({typeName:z.ZodUndefined,...V(e)});class ii extends Y{_parse(e){if(this._getType(e)!==C.null){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.null,received:r.parsedType}),F}return at(e.data)}}ii.create=(e)=>new ii({typeName:z.ZodNull,...V(e)});class Fs extends Y{constructor(){super(...arguments);this._any=!0}_parse(e){return at(e.data)}}Fs.create=(e)=>new Fs({typeName:z.ZodAny,...V(e)});class un extends Y{constructor(){super(...arguments);this._unknown=!0}_parse(e){return at(e.data)}}un.create=(e)=>new un({typeName:z.ZodUnknown,...V(e)});class fr extends Y{_parse(e){let t=this._getOrReturnCtx(e);return A(t,{code:R.invalid_type,expected:C.never,received:t.parsedType}),F}}fr.create=(e)=>new fr({typeName:z.ZodNever,...V(e)});class Zs extends Y{_parse(e){if(this._getType(e)!==C.undefined){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.void,received:r.parsedType}),F}return at(e.data)}}Zs.create=(e)=>new Zs({typeName:z.ZodVoid,...V(e)});class or extends Y{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),n=this._def;if(t.parsedType!==C.array)return A(t,{code:R.invalid_type,expected:C.array,received:t.parsedType}),F;if(n.exactLength!==null){let i=t.data.length>n.exactLength.value,s=t.data.length<n.exactLength.value;if(i||s)A(t,{code:i?R.too_big:R.too_small,minimum:s?n.exactLength.value:void 0,maximum:i?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),r.dirty()}if(n.minLength!==null){if(t.data.length<n.minLength.value)A(t,{code:R.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),r.dirty()}if(n.maxLength!==null){if(t.data.length>n.maxLength.value)A(t,{code:R.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),r.dirty()}if(t.common.async)return Promise.all([...t.data].map((i,s)=>n.type._parseAsync(new Vt(t,i,t.path,s)))).then((i)=>it.mergeArray(r,i));let o=[...t.data].map((i,s)=>n.type._parseSync(new Vt(t,i,t.path,s)));return it.mergeArray(r,o)}get element(){return this._def.type}min(e,t){return new or({...this._def,minLength:{value:e,message:N.toString(t)}})}max(e,t){return new or({...this._def,maxLength:{value:e,message:N.toString(t)}})}length(e,t){return new or({...this._def,exactLength:{value:e,message:N.toString(t)}})}nonempty(e){return this.min(1,e)}}or.create=(e,t)=>new or({type:e,minLength:null,maxLength:null,exactLength:null,typeName:z.ZodArray,...V(t)});function Bn(e){if(e instanceof Ie){let t={};for(let r in e.shape){let n=e.shape[r];t[r]=Ct.create(Bn(n))}return new Ie({...e._def,shape:()=>t})}else if(e instanceof or)return new or({...e._def,type:Bn(e.element)});else if(e instanceof Ct)return Ct.create(Bn(e.unwrap()));else if(e instanceof zr)return zr.create(Bn(e.unwrap()));else if(e instanceof hr)return hr.create(e.items.map((t)=>Bn(t)));else return e}class Ie extends Y{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let e=this._def.shape(),t=te.objectKeys(e);return this._cached={shape:e,keys:t},this._cached}_parse(e){if(this._getType(e)!==C.object){let c=this._getOrReturnCtx(e);return A(c,{code:R.invalid_type,expected:C.object,received:c.parsedType}),F}let{status:r,ctx:n}=this._processInputParams(e),{shape:o,keys:i}=this._getCached(),s=[];if(!(this._def.catchall instanceof fr&&this._def.unknownKeys==="strip")){for(let c in n.data)if(!i.includes(c))s.push(c)}let a=[];for(let c of i){let u=o[c],l=n.data[c];a.push({key:{status:"valid",value:c},value:u._parse(new Vt(n,l,n.path,c)),alwaysSet:c in n.data})}if(this._def.catchall instanceof fr){let c=this._def.unknownKeys;if(c==="passthrough")for(let u of s)a.push({key:{status:"valid",value:u},value:{status:"valid",value:n.data[u]}});else if(c==="strict"){if(s.length>0)A(n,{code:R.unrecognized_keys,keys:s}),r.dirty()}else if(c==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let c=this._def.catchall;for(let u of s){let l=n.data[u];a.push({key:{status:"valid",value:u},value:c._parse(new Vt(n,l,n.path,u)),alwaysSet:u in n.data})}}if(n.common.async)return Promise.resolve().then(async()=>{let c=[];for(let u of a){let l=await u.key,p=await u.value;c.push({key:l,value:p,alwaysSet:u.alwaysSet})}return c}).then((c)=>it.mergeObjectSync(r,c));else return it.mergeObjectSync(r,a)}get shape(){return this._def.shape()}strict(e){return N.errToObj,new Ie({...this._def,unknownKeys:"strict",...e!==void 0?{errorMap:(t,r)=>{let n=this._def.errorMap?.(t,r).message??r.defaultError;if(t.code==="unrecognized_keys")return{message:N.errToObj(e).message??n};return{message:n}}}:{}})}strip(){return new Ie({...this._def,unknownKeys:"strip"})}passthrough(){return new Ie({...this._def,unknownKeys:"passthrough"})}extend(e){return new Ie({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new Ie({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:z.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new Ie({...this._def,catchall:e})}pick(e){let t={};for(let r of te.objectKeys(e))if(e[r]&&this.shape[r])t[r]=this.shape[r];return new Ie({...this._def,shape:()=>t})}omit(e){let t={};for(let r of te.objectKeys(this.shape))if(!e[r])t[r]=this.shape[r];return new Ie({...this._def,shape:()=>t})}deepPartial(){return Bn(this)}partial(e){let t={};for(let r of te.objectKeys(this.shape)){let n=this.shape[r];if(e&&!e[r])t[r]=n;else t[r]=n.optional()}return new Ie({...this._def,shape:()=>t})}required(e){let t={};for(let r of te.objectKeys(this.shape))if(e&&!e[r])t[r]=this.shape[r];else{let o=this.shape[r];while(o instanceof Ct)o=o._def.innerType;t[r]=o}return new Ie({...this._def,shape:()=>t})}keyof(){return _v(te.objectKeys(this.shape))}}Ie.create=(e,t)=>new Ie({shape:()=>e,unknownKeys:"strip",catchall:fr.create(),typeName:z.ZodObject,...V(t)});Ie.strictCreate=(e,t)=>new Ie({shape:()=>e,unknownKeys:"strict",catchall:fr.create(),typeName:z.ZodObject,...V(t)});Ie.lazycreate=(e,t)=>new Ie({shape:e,unknownKeys:"strip",catchall:fr.create(),typeName:z.ZodObject,...V(t)});class si extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;function n(o){for(let s of o)if(s.result.status==="valid")return s.result;for(let s of o)if(s.result.status==="dirty")return t.common.issues.push(...s.ctx.common.issues),s.result;let i=o.map((s)=>new St(s.ctx.common.issues));return A(t,{code:R.invalid_union,unionErrors:i}),F}if(t.common.async)return Promise.all(r.map(async(o)=>{let i={...t,common:{...t.common,issues:[]},parent:null};return{result:await o._parseAsync({data:t.data,path:t.path,parent:i}),ctx:i}})).then(n);else{let o=void 0,i=[];for(let a of r){let c={...t,common:{...t.common,issues:[]},parent:null},u=a._parseSync({data:t.data,path:t.path,parent:c});if(u.status==="valid")return u;else if(u.status==="dirty"&&!o)o={result:u,ctx:c};if(c.common.issues.length)i.push(c.common.issues)}if(o)return t.common.issues.push(...o.ctx.common.issues),o.result;let s=i.map((a)=>new St(a));return A(t,{code:R.invalid_union,unionErrors:s}),F}}get options(){return this._def.options}}si.create=(e,t)=>new si({options:e,typeName:z.ZodUnion,...V(t)});var dr=(e)=>{if(e instanceof ci)return dr(e.schema);else if(e instanceof ir)return dr(e.innerType());else if(e instanceof ui)return[e.value];else if(e instanceof ln)return e.options;else if(e instanceof li)return te.objectValues(e.enum);else if(e instanceof pi)return dr(e._def.innerType);else if(e instanceof oi)return[void 0];else if(e instanceof ii)return[null];else if(e instanceof Ct)return[void 0,...dr(e.unwrap())];else if(e instanceof zr)return[null,...dr(e.unwrap())];else if(e instanceof dl)return dr(e.unwrap());else if(e instanceof mi)return dr(e.unwrap());else if(e instanceof di)return dr(e._def.innerType);else return[]};class pl extends Y{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==C.object)return A(t,{code:R.invalid_type,expected:C.object,received:t.parsedType}),F;let r=this.discriminator,n=t.data[r],o=this.optionsMap.get(n);if(!o)return A(t,{code:R.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),F;if(t.common.async)return o._parseAsync({data:t.data,path:t.path,parent:t});else return o._parseSync({data:t.data,path:t.path,parent:t})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let n=new Map;for(let o of t){let i=dr(o.shape[e]);if(!i.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let s of i){if(n.has(s))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(s)}`);n.set(s,o)}}return new pl({typeName:z.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:n,...V(r)})}}function ll(e,t){let r=pr(e),n=pr(t);if(e===t)return{valid:!0,data:e};else if(r===C.object&&n===C.object){let o=te.objectKeys(t),i=te.objectKeys(e).filter((a)=>o.indexOf(a)!==-1),s={...e,...t};for(let a of i){let c=ll(e[a],t[a]);if(!c.valid)return{valid:!1};s[a]=c.data}return{valid:!0,data:s}}else if(r===C.array&&n===C.array){if(e.length!==t.length)return{valid:!1};let o=[];for(let i=0;i<e.length;i++){let s=e[i],a=t[i],c=ll(s,a);if(!c.valid)return{valid:!1};o.push(c.data)}return{valid:!0,data:o}}else if(r===C.date&&n===C.date&&+e===+t)return{valid:!0,data:e};else return{valid:!1}}class ai extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=(o,i)=>{if(al(o)||al(i))return F;let s=ll(o.value,i.value);if(!s.valid)return A(r,{code:R.invalid_intersection_types}),F;if(cl(o)||cl(i))t.dirty();return{status:t.value,value:s.data}};if(r.common.async)return 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(([o,i])=>n(o,i));else return n(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}ai.create=(e,t,r)=>new ai({left:e,right:t,typeName:z.ZodIntersection,...V(r)});class hr extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==C.array)return A(r,{code:R.invalid_type,expected:C.array,received:r.parsedType}),F;if(r.data.length<this._def.items.length)return A(r,{code:R.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),F;if(!this._def.rest&&r.data.length>this._def.items.length)A(r,{code:R.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty();let o=[...r.data].map((i,s)=>{let a=this._def.items[s]||this._def.rest;if(!a)return null;return a._parse(new Vt(r,i,r.path,s))}).filter((i)=>!!i);if(r.common.async)return Promise.all(o).then((i)=>it.mergeArray(t,i));else return it.mergeArray(t,o)}get items(){return this._def.items}rest(e){return new hr({...this._def,rest:e})}}hr.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new hr({items:e,typeName:z.ZodTuple,rest:null,...V(t)})};class Bs extends Y{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!==C.object)return A(r,{code:R.invalid_type,expected:C.object,received:r.parsedType}),F;let n=[],o=this._def.keyType,i=this._def.valueType;for(let s in r.data)n.push({key:o._parse(new Vt(r,s,r.path,s)),value:i._parse(new Vt(r,r.data[s],r.path,s)),alwaysSet:s in r.data});if(r.common.async)return it.mergeObjectAsync(t,n);else return it.mergeObjectSync(t,n)}get element(){return this._def.valueType}static create(e,t,r){if(t instanceof Y)return new Bs({keyType:e,valueType:t,typeName:z.ZodRecord,...V(r)});return new Bs({keyType:mr.create(),valueType:e,typeName:z.ZodRecord,...V(t)})}}class Hs extends Y{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!==C.map)return A(r,{code:R.invalid_type,expected:C.map,received:r.parsedType}),F;let n=this._def.keyType,o=this._def.valueType,i=[...r.data.entries()].map(([s,a],c)=>({key:n._parse(new Vt(r,s,r.path,[c,"key"])),value:o._parse(new Vt(r,a,r.path,[c,"value"]))}));if(r.common.async){let s=new Map;return Promise.resolve().then(async()=>{for(let a of i){let c=await a.key,u=await a.value;if(c.status==="aborted"||u.status==="aborted")return F;if(c.status==="dirty"||u.status==="dirty")t.dirty();s.set(c.value,u.value)}return{status:t.value,value:s}})}else{let s=new Map;for(let a of i){let{key:c,value:u}=a;if(c.status==="aborted"||u.status==="aborted")return F;if(c.status==="dirty"||u.status==="dirty")t.dirty();s.set(c.value,u.value)}return{status:t.value,value:s}}}}Hs.create=(e,t,r)=>new Hs({valueType:t,keyType:e,typeName:z.ZodMap,...V(r)});class Gn extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==C.set)return A(r,{code:R.invalid_type,expected:C.set,received:r.parsedType}),F;let n=this._def;if(n.minSize!==null){if(r.data.size<n.minSize.value)A(r,{code:R.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),t.dirty()}if(n.maxSize!==null){if(r.data.size>n.maxSize.value)A(r,{code:R.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),t.dirty()}let o=this._def.valueType;function i(a){let c=new Set;for(let u of a){if(u.status==="aborted")return F;if(u.status==="dirty")t.dirty();c.add(u.value)}return{status:t.value,value:c}}let s=[...r.data.values()].map((a,c)=>o._parse(new Vt(r,a,r.path,c)));if(r.common.async)return Promise.all(s).then((a)=>i(a));else return i(s)}min(e,t){return new Gn({...this._def,minSize:{value:e,message:N.toString(t)}})}max(e,t){return new Gn({...this._def,maxSize:{value:e,message:N.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}Gn.create=(e,t)=>new Gn({valueType:e,minSize:null,maxSize:null,typeName:z.ZodSet,...V(t)});class ri extends Y{constructor(){super(...arguments);this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==C.function)return A(t,{code:R.invalid_type,expected:C.function,received:t.parsedType}),F;function r(s,a){return Ls({data:s,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,ei(),Pr].filter((c)=>!!c),issueData:{code:R.invalid_arguments,argumentsError:a}})}function n(s,a){return Ls({data:s,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,ei(),Pr].filter((c)=>!!c),issueData:{code:R.invalid_return_type,returnTypeError:a}})}let o={errorMap:t.common.contextualErrorMap},i=t.data;if(this._def.returns instanceof Jn){let s=this;return at(async function(...a){let c=new St([]),u=await s._def.args.parseAsync(a,o).catch((m)=>{throw c.addIssue(r(a,m)),c}),l=await Reflect.apply(i,this,u);return await s._def.returns._def.type.parseAsync(l,o).catch((m)=>{throw c.addIssue(n(l,m)),c})})}else{let s=this;return at(function(...a){let c=s._def.args.safeParse(a,o);if(!c.success)throw new St([r(a,c.error)]);let u=Reflect.apply(i,this,c.data),l=s._def.returns.safeParse(u,o);if(!l.success)throw new St([n(u,l.error)]);return l.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new ri({...this._def,args:hr.create(e).rest(un.create())})}returns(e){return new ri({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new ri({args:e?e:hr.create([]).rest(un.create()),returns:t||un.create(),typeName:z.ZodFunction,...V(r)})}}class ci extends Y{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})}}ci.create=(e,t)=>new ci({getter:e,typeName:z.ZodLazy,...V(t)});class ui extends Y{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return A(t,{received:t.data,code:R.invalid_literal,expected:this._def.value}),F}return{status:"valid",value:e.data}}get value(){return this._def.value}}ui.create=(e,t)=>new ui({value:e,typeName:z.ZodLiteral,...V(t)});function _v(e,t){return new ln({values:e,typeName:z.ZodEnum,...V(t)})}class ln extends Y{_parse(e){if(typeof e.data!=="string"){let t=this._getOrReturnCtx(e),r=this._def.values;return A(t,{expected:te.joinValues(r),received:t.parsedType,code:R.invalid_type}),F}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return A(t,{received:t.data,code:R.invalid_enum_value,options:r}),F}return at(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 ln.create(e,{...this._def,...t})}exclude(e,t=this._def){return ln.create(this.options.filter((r)=>!e.includes(r)),{...this._def,...t})}}ln.create=_v;class li extends Y{_parse(e){let t=te.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==C.string&&r.parsedType!==C.number){let n=te.objectValues(t);return A(r,{expected:te.joinValues(n),received:r.parsedType,code:R.invalid_type}),F}if(!this._cache)this._cache=new Set(te.getValidEnumValues(this._def.values));if(!this._cache.has(e.data)){let n=te.objectValues(t);return A(r,{received:r.data,code:R.invalid_enum_value,options:n}),F}return at(e.data)}get enum(){return this._def.values}}li.create=(e,t)=>new li({values:e,typeName:z.ZodNativeEnum,...V(t)});class Jn extends Y{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==C.promise&&t.common.async===!1)return A(t,{code:R.invalid_type,expected:C.promise,received:t.parsedType}),F;let r=t.parsedType===C.promise?t.data:Promise.resolve(t.data);return at(r.then((n)=>this._def.type.parseAsync(n,{path:t.path,errorMap:t.common.contextualErrorMap})))}}Jn.create=(e,t)=>new Jn({type:e,typeName:z.ZodPromise,...V(t)});class ir extends Y{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===z.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=this._def.effect||null,o={addIssue:(i)=>{if(A(r,i),i.fatal)t.abort();else t.dirty()},get path(){return r.path}};if(o.addIssue=o.addIssue.bind(o),n.type==="preprocess"){let i=n.transform(r.data,o);if(r.common.async)return Promise.resolve(i).then(async(s)=>{if(t.value==="aborted")return F;let a=await this._def.schema._parseAsync({data:s,path:r.path,parent:r});if(a.status==="aborted")return F;if(a.status==="dirty")return Zn(a.value);if(t.value==="dirty")return Zn(a.value);return a});else{if(t.value==="aborted")return F;let s=this._def.schema._parseSync({data:i,path:r.path,parent:r});if(s.status==="aborted")return F;if(s.status==="dirty")return Zn(s.value);if(t.value==="dirty")return Zn(s.value);return s}}if(n.type==="refinement"){let i=(s)=>{let a=n.refinement(s,o);if(r.common.async)return Promise.resolve(a);if(a instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return s};if(r.common.async===!1){let s=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(s.status==="aborted")return F;if(s.status==="dirty")t.dirty();return i(s.value),{status:t.value,value:s.value}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((s)=>{if(s.status==="aborted")return F;if(s.status==="dirty")t.dirty();return i(s.value).then(()=>({status:t.value,value:s.value}))})}if(n.type==="transform")if(r.common.async===!1){let i=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!cn(i))return F;let s=n.transform(i.value,o);if(s instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:s}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then((i)=>{if(!cn(i))return F;return Promise.resolve(n.transform(i.value,o)).then((s)=>({status:t.value,value:s}))});te.assertNever(n)}}ir.create=(e,t,r)=>new ir({schema:e,typeName:z.ZodEffects,effect:t,...V(r)});ir.createWithPreprocess=(e,t,r)=>new ir({schema:t,effect:{type:"preprocess",transform:e},typeName:z.ZodEffects,...V(r)});class Ct extends Y{_parse(e){if(this._getType(e)===C.undefined)return at(void 0);return this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}Ct.create=(e,t)=>new Ct({innerType:e,typeName:z.ZodOptional,...V(t)});class zr extends Y{_parse(e){if(this._getType(e)===C.null)return at(null);return this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}zr.create=(e,t)=>new zr({innerType:e,typeName:z.ZodNullable,...V(t)});class pi extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;if(t.parsedType===C.undefined)r=this._def.defaultValue();return this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}pi.create=(e,t)=>new pi({innerType:e,typeName:z.ZodDefault,defaultValue:typeof t.default==="function"?t.default:()=>t.default,...V(t)});class di extends Y{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},n=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});if(ti(n))return n.then((o)=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new St(r.common.issues)},input:r.data})}));else return{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new St(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}di.create=(e,t)=>new di({innerType:e,typeName:z.ZodCatch,catchValue:typeof t.catch==="function"?t.catch:()=>t.catch,...V(t)});class Vs extends Y{_parse(e){if(this._getType(e)!==C.nan){let r=this._getOrReturnCtx(e);return A(r,{code:R.invalid_type,expected:C.nan,received:r.parsedType}),F}return{status:"valid",value:e.data}}}Vs.create=(e)=>new Vs({typeName:z.ZodNaN,...V(e)});var zH=Symbol("zod_brand");class dl extends Y{_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 Gs extends Y{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let o=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});if(o.status==="aborted")return F;if(o.status==="dirty")return t.dirty(),Zn(o.value);else return this._def.out._parseAsync({data:o.value,path:r.path,parent:r})})();else{let n=this._def.in._parseSync({data:r.data,path:r.path,parent:r});if(n.status==="aborted")return F;if(n.status==="dirty")return t.dirty(),{status:"dirty",value:n.value};else return this._def.out._parseSync({data:n.value,path:r.path,parent:r})}}static create(e,t){return new Gs({in:e,out:t,typeName:z.ZodPipeline})}}class mi extends Y{_parse(e){let t=this._def.innerType._parse(e),r=(n)=>{if(cn(n))n.value=Object.freeze(n.value);return n};return ti(t)?t.then((n)=>r(n)):r(t)}unwrap(){return this._def.innerType}}mi.create=(e,t)=>new mi({innerType:e,typeName:z.ZodReadonly,...V(t)});var OH={object:Ie.lazycreate},z;(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"})(z||(z={}));var E=mr.create,$t=Hn.create,AH=Vs.create,CH=Vn.create,It=qs.create,IH=ni.create,jH=Us.create,NH=oi.create,DH=ii.create,MH=Fs.create,LH=un.create,qH=fr.create,UH=Zs.create,Me=or.create,{create:je,strictCreate:FH}=Ie,ZH=si.create,BH=pl.create,HH=ai.create,VH=hr.create,lO=Bs.create,GH=Hs.create,JH=Gn.create,WH=ri.create,KH=ci.create,YH=ui.create,ue=ln.create,XH=li.create,QH=Jn.create,eV=ir.create,tV=Ct.create,rV=zr.create,nV=ir.createWithPreprocess,oV=Gs.create;var pO=Object.freeze({status:"aborted"});function k(e,t,r){function n(a,c){var u;Object.defineProperty(a,"_zod",{value:a._zod??{},enumerable:!1}),(u=a._zod).traits??(u.traits=new Set),a._zod.traits.add(e),t(a,c);for(let l in s.prototype)if(!(l in a))Object.defineProperty(a,l,{value:s.prototype[l].bind(a)});a._zod.constr=s,a._zod.def=c}let o=r?.Parent??Object;class i extends o{}Object.defineProperty(i,"name",{value:e});function s(a){var c;let u=r?.Parent?new i:this;n(u,a),(c=u._zod).deferred??(c.deferred=[]);for(let l of u._zod.deferred)l();return u}return Object.defineProperty(s,"init",{value:n}),Object.defineProperty(s,Symbol.hasInstance,{value:(a)=>{if(r?.Parent&&a instanceof r.Parent)return!0;return a?._zod?.traits?.has(e)}}),Object.defineProperty(s,"name",{value:e}),s}var dO=Symbol("zod_brand");class Or extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}var Js={};function Tt(e){if(e)Object.assign(Js,e);return Js}function Ks(e){let t=Object.values(e).filter((n)=>typeof n==="number");return Object.entries(e).filter(([n,o])=>t.indexOf(+n)===-1).map(([n,o])=>o)}function fl(e,t="|"){return e.map((r)=>gl(r)).join(t)}function wv(e,t){if(typeof t==="bigint")return t.toString();return t}function Ys(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw Error("cached value already set")}}}function Xs(e){return e===null||e===void 0}function Qs(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}function kv(e,t){let r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,o=r>n?r:n,i=Number.parseInt(e.toFixed(o).replace(".","")),s=Number.parseInt(t.toFixed(o).replace(".",""));return i%s/10**o}function xe(e,t,r){Object.defineProperty(e,t,{get(){{let o=r();return e[t]=o,o}throw Error("cached value already set")},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function hi(e,t,r){Object.defineProperty(e,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}function Wn(e){return JSON.stringify(e)}var hl=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};function fi(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)}var Sv=Ys(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{return new Function(""),!0}catch(e){return!1}});function gi(e){if(fi(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let r=t.prototype;if(fi(r)===!1)return!1;if(Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)return!1;return!0}var $v=new Set(["string","number","symbol"]);function pn(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function jt(e,t,r){let n=new e._zod.constr(t??e._zod.def);if(!t||r?.parent)n._zod.parent=e;return n}function D(e){let t=e;if(!t)return{};if(typeof t==="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");t.error=t.message}if(delete t.message,typeof t.error==="string")return{...t,error:()=>t.error};return t}function gl(e){if(typeof e==="bigint")return e.toString()+"n";if(typeof e==="string")return`"${e}"`;return`${e}`}function Tv(e){return Object.keys(e).filter((t)=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var Ev={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-340282346638528860000000000000000000000,340282346638528860000000000000000000000],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]};function mO(e,t){let r={},n=e._zod.def;for(let o in t){if(!(o in n.shape))throw Error(`Unrecognized key: "${o}"`);if(!t[o])continue;r[o]=n.shape[o]}return jt(e,{...e._zod.def,shape:r,checks:[]})}function fO(e,t){let r={...e._zod.def.shape},n=e._zod.def;for(let o in t){if(!(o in n.shape))throw Error(`Unrecognized key: "${o}"`);if(!t[o])continue;delete r[o]}return jt(e,{...e._zod.def,shape:r,checks:[]})}function hO(e,t){if(!gi(t))throw Error("Invalid input to extend: expected a plain object");let r={...e._zod.def,get shape(){let n={...e._zod.def.shape,...t};return hi(this,"shape",n),n},checks:[]};return jt(e,r)}function gO(e,t){return jt(e,{...e._zod.def,get shape(){let r={...e._zod.def.shape,...t._zod.def.shape};return hi(this,"shape",r),r},catchall:t._zod.def.catchall,checks:[]})}function xO(e,t,r){let n=t._zod.def.shape,o={...n};if(r)for(let i in r){if(!(i in n))throw Error(`Unrecognized key: "${i}"`);if(!r[i])continue;o[i]=e?new e({type:"optional",innerType:n[i]}):n[i]}else for(let i in n)o[i]=e?new e({type:"optional",innerType:n[i]}):n[i];return jt(t,{...t._zod.def,shape:o,checks:[]})}function vO(e,t,r){let n=t._zod.def.shape,o={...n};if(r)for(let i in r){if(!(i in o))throw Error(`Unrecognized key: "${i}"`);if(!r[i])continue;o[i]=new e({type:"nonoptional",innerType:n[i]})}else for(let i in n)o[i]=new e({type:"nonoptional",innerType:n[i]});return jt(t,{...t._zod.def,shape:o,checks:[]})}function Kn(e,t=0){for(let r=t;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}function gr(e,t){return t.map((r)=>{var n;return(n=r).path??(n.path=[]),r.path.unshift(e),r})}function Ws(e){return typeof e==="string"?e:e?.message}function sr(e,t,r){let n={...e,path:e.path??[]};if(!e.message){let o=Ws(e.inst?._zod.def?.error?.(e))??Ws(t?.error?.(e))??Ws(r.customError?.(e))??Ws(r.localeError?.(e))??"Invalid input";n.message=o}if(delete n.inst,delete n.continue,!t?.reportInput)delete n.input;return n}function ea(e){if(Array.isArray(e))return"array";if(typeof e==="string")return"string";return"unknown"}function Yn(...e){let[t,r,n]=e;if(typeof t==="string")return{message:t,code:"custom",input:r,inst:n};return{...t}}var Rv=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),Object.defineProperty(e,"message",{get(){return JSON.stringify(t,wv,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ta=k("$ZodError",Rv),xi=k("$ZodError",Rv,{Parent:Error});function xl(e,t=(r)=>r.message){let r={},n=[];for(let o of e.issues)if(o.path.length>0)r[o.path[0]]=r[o.path[0]]||[],r[o.path[0]].push(t(o));else n.push(t(o));return{formErrors:n,fieldErrors:r}}function vl(e,t){let r=t||function(i){return i.message},n={_errors:[]},o=(i)=>{for(let s of i.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map((a)=>o({issues:a}));else if(s.code==="invalid_key")o({issues:s.issues});else if(s.code==="invalid_element")o({issues:s.issues});else if(s.path.length===0)n._errors.push(r(s));else{let a=n,c=0;while(c<s.path.length){let u=s.path[c];if(c!==s.path.length-1)a[u]=a[u]||{_errors:[]};else a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s));a=a[u],c++}}};return o(e),n}var yl=(e)=>(t,r,n,o)=>{let i=n?Object.assign(n,{async:!1}):{async:!1},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)throw new Or;if(s.issues.length){let a=new(o?.Err??e)(s.issues.map((c)=>sr(c,i,Tt())));throw hl(a,o?.callee),a}return s.value},bl=yl(xi),_l=(e)=>async(t,r,n,o)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)s=await s;if(s.issues.length){let a=new(o?.Err??e)(s.issues.map((c)=>sr(c,i,Tt())));throw hl(a,o?.callee),a}return s.value},wl=_l(xi),kl=(e)=>(t,r,n)=>{let o=n?{...n,async:!1}:{async:!1},i=t._zod.run({value:r,issues:[]},o);if(i instanceof Promise)throw new Or;return i.issues.length?{success:!1,error:new(e??ta)(i.issues.map((s)=>sr(s,o,Tt())))}:{success:!0,data:i.value}},dn=kl(xi),Sl=(e)=>async(t,r,n)=>{let o=n?Object.assign(n,{async:!0}):{async:!0},i=t._zod.run({value:r,issues:[]},o);if(i instanceof Promise)i=await i;return i.issues.length?{success:!1,error:new e(i.issues.map((s)=>sr(s,o,Tt())))}:{success:!0,data:i.value}},mn=Sl(xi);var Pv=/^[cC][^\s-]{8,}$/,zv=/^[0-9a-z]+$/,Ov=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Av=/^[0-9a-vA-V]{20}$/,Cv=/^[A-Za-z0-9]{27}$/,Iv=/^[a-zA-Z0-9_-]{21}$/,jv=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/;var Nv=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,$l=(e)=>{if(!e)return/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/;return new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`)};var Dv=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/;function Mv(){return new RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")}var Lv=/^(?:(?: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])$/,qv=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})$/,Uv=/^((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])\/([0-9]|[1-2][0-9]|3[0-2])$/,Fv=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Zv=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Tl=/^[A-Za-z0-9_-]*$/,Bv=/^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/;var Hv=/^\+(?:[0-9]){6,14}[0-9]$/,Vv="(?:(?:\\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])))",Gv=new RegExp(`^${Vv}$`);function Jv(e){return typeof e.precision==="number"?e.precision===-1?"(?:[01]\\d|2[0-3]):[0-5]\\d":e.precision===0?"(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d":`(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d\\.\\d{${e.precision}}`:"(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?"}function Wv(e){return new RegExp(`^${Jv(e)}$`)}function Kv(e){let t=Jv({precision:e.precision}),r=["Z"];if(e.local)r.push("");if(e.offset)r.push("([+-]\\d{2}:\\d{2})");let n=`${t}(?:${r.join("|")})`;return new RegExp(`^${Vv}T(?:${n})$`)}var Yv=(e)=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)};var Xv=/^\d+$/,Qv=/^-?\d+(?:\.\d+)?/i,ey=/true|false/i,ty=/null/i;var ry=/^[^A-Z]*$/,ny=/^[^a-z]*$/;var Xe=k("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),oy={number:"number",bigint:"bigint",object:"date"},El=k("$ZodCheckLessThan",(e,t)=>{Xe.init(e,t);let r=oy[typeof t.value];e._zod.onattach.push((n)=>{let o=n._zod.bag,i=(t.inclusive?o.maximum:o.exclusiveMaximum)??Number.POSITIVE_INFINITY;if(t.value<i)if(t.inclusive)o.maximum=t.value;else o.exclusiveMaximum=t.value}),e._zod.check=(n)=>{if(t.inclusive?n.value<=t.value:n.value<t.value)return;n.issues.push({origin:r,code:"too_big",maximum:t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Rl=k("$ZodCheckGreaterThan",(e,t)=>{Xe.init(e,t);let r=oy[typeof t.value];e._zod.onattach.push((n)=>{let o=n._zod.bag,i=(t.inclusive?o.minimum:o.exclusiveMinimum)??Number.NEGATIVE_INFINITY;if(t.value>i)if(t.inclusive)o.minimum=t.value;else o.exclusiveMinimum=t.value}),e._zod.check=(n)=>{if(t.inclusive?n.value>=t.value:n.value>t.value)return;n.issues.push({origin:r,code:"too_small",minimum:t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),iy=k("$ZodCheckMultipleOf",(e,t)=>{Xe.init(e,t),e._zod.onattach.push((r)=>{var n;(n=r._zod.bag).multipleOf??(n.multipleOf=t.value)}),e._zod.check=(r)=>{if(typeof r.value!==typeof t.value)throw Error("Cannot mix number and bigint in multiple_of check.");if(typeof r.value==="bigint"?r.value%t.value===BigInt(0):kv(r.value,t.value)===0)return;r.issues.push({origin:typeof r.value,code:"not_multiple_of",divisor:t.value,input:r.value,inst:e,continue:!t.abort})}}),sy=k("$ZodCheckNumberFormat",(e,t)=>{Xe.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),n=r?"int":"number",[o,i]=Ev[t.format];e._zod.onattach.push((s)=>{let a=s._zod.bag;if(a.format=t.format,a.minimum=o,a.maximum=i,r)a.pattern=Xv}),e._zod.check=(s)=>{let a=s.value;if(r){if(!Number.isInteger(a)){s.issues.push({expected:n,format:t.format,code:"invalid_type",input:a,inst:e});return}if(!Number.isSafeInteger(a)){if(a>0)s.issues.push({input:a,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,continue:!t.abort});else s.issues.push({input:a,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,continue:!t.abort});return}}if(a<o)s.issues.push({origin:"number",input:a,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort});if(a>i)s.issues.push({origin:"number",input:a,code:"too_big",maximum:i,inst:e})}});var ay=k("$ZodCheckMaxLength",(e,t)=>{var r;Xe.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!Xs(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag.maximum??Number.POSITIVE_INFINITY;if(t.maximum<o)n._zod.bag.maximum=t.maximum}),e._zod.check=(n)=>{let o=n.value;if(o.length<=t.maximum)return;let s=ea(o);n.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),cy=k("$ZodCheckMinLength",(e,t)=>{var r;Xe.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!Xs(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;if(t.minimum>o)n._zod.bag.minimum=t.minimum}),e._zod.check=(n)=>{let o=n.value;if(o.length>=t.minimum)return;let s=ea(o);n.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),uy=k("$ZodCheckLengthEquals",(e,t)=>{var r;Xe.init(e,t),(r=e._zod.def).when??(r.when=(n)=>{let o=n.value;return!Xs(o)&&o.length!==void 0}),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.minimum=t.length,o.maximum=t.length,o.length=t.length}),e._zod.check=(n)=>{let o=n.value,i=o.length;if(i===t.length)return;let s=ea(o),a=i>t.length;n.issues.push({origin:s,...a?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),vi=k("$ZodCheckStringFormat",(e,t)=>{var r,n;if(Xe.init(e,t),e._zod.onattach.push((o)=>{let i=o._zod.bag;if(i.format=t.format,t.pattern)i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern)}),t.pattern)(r=e._zod).check??(r.check=(o)=>{if(t.pattern.lastIndex=0,t.pattern.test(o.value))return;o.issues.push({origin:"string",code:"invalid_format",format:t.format,input:o.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})});else(n=e._zod).check??(n.check=()=>{})}),ly=k("$ZodCheckRegex",(e,t)=>{vi.init(e,t),e._zod.check=(r)=>{if(t.pattern.lastIndex=0,t.pattern.test(r.value))return;r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),py=k("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=ry),vi.init(e,t)}),dy=k("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=ny),vi.init(e,t)}),my=k("$ZodCheckIncludes",(e,t)=>{Xe.init(e,t);let r=pn(t.includes),n=new RegExp(typeof t.position==="number"?`^.{${t.position}}${r}`:r);t.pattern=n,e._zod.onattach.push((o)=>{let i=o._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(n)}),e._zod.check=(o)=>{if(o.value.includes(t.includes,t.position))return;o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),fy=k("$ZodCheckStartsWith",(e,t)=>{Xe.init(e,t);let r=new RegExp(`^${pn(t.prefix)}.*`);t.pattern??(t.pattern=r),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(r)}),e._zod.check=(n)=>{if(n.value.startsWith(t.prefix))return;n.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:n.value,inst:e,continue:!t.abort})}}),hy=k("$ZodCheckEndsWith",(e,t)=>{Xe.init(e,t);let r=new RegExp(`.*${pn(t.suffix)}$`);t.pattern??(t.pattern=r),e._zod.onattach.push((n)=>{let o=n._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(r)}),e._zod.check=(n)=>{if(n.value.endsWith(t.suffix))return;n.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:n.value,inst:e,continue:!t.abort})}});var gy=k("$ZodCheckOverwrite",(e,t)=>{Xe.init(e,t),e._zod.check=(r)=>{r.value=t.tx(r.value)}});class Pl{constructor(e=[]){if(this.content=[],this.indent=0,this)this.args=e}indented(e){this.indent+=1,e(this),this.indent-=1}write(e){if(typeof e==="function"){e(this,{execution:"sync"}),e(this,{execution:"async"});return}let r=e.split(`
|
|
36
36
|
`).filter((i)=>i),n=Math.min(...r.map((i)=>i.length-i.trimStart().length)),o=r.map((i)=>i.slice(n)).map((i)=>" ".repeat(this.indent*2)+i);for(let i of o)this.content.push(i)}compile(){let e=Function,t=this?.args,n=[...(this?.content??[""]).map((o)=>` ${o}`)];return new e(...t,n.join(`
|
|
37
|
-
`))}}var
|
|
38
|
-
if (${
|
|
39
|
-
if (input[${
|
|
40
|
-
if (${
|
|
41
|
-
newResult[${
|
|
37
|
+
`))}}var vy={major:4,minor:0,patch:0};var fe=k("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=vy;let n=[...e._zod.def.checks??[]];if(e._zod.traits.has("$ZodCheck"))n.unshift(e);for(let o of n)for(let i of o._zod.onattach)i(e);if(n.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let o=(i,s,a)=>{let c=Kn(i),u;for(let l of s){if(l._zod.def.when){if(!l._zod.def.when(i))continue}else if(c)continue;let p=i.issues.length,m=l._zod.check(i);if(m instanceof Promise&&a?.async===!1)throw new Or;if(u||m instanceof Promise)u=(u??Promise.resolve()).then(async()=>{if(await m,i.issues.length===p)return;if(!c)c=Kn(i,p)});else{if(i.issues.length===p)continue;if(!c)c=Kn(i,p)}}if(u)return u.then(()=>i);return i};e._zod.run=(i,s)=>{let a=e._zod.parse(i,s);if(a instanceof Promise){if(s.async===!1)throw new Or;return a.then((c)=>o(c,n,s))}return o(a,n,s)}}e["~standard"]={validate:(o)=>{try{let i=dn(e,o);return i.success?{value:i.data}:{issues:i.error?.issues}}catch(i){return mn(e,o).then((s)=>s.success?{value:s.data}:{issues:s.error?.issues})}},vendor:"zod",version:1}}),yi=k("$ZodString",(e,t)=>{fe.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Yv(e._zod.bag),e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=String(r.value)}catch(o){}if(typeof r.value==="string")return r;return r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),_e=k("$ZodStringFormat",(e,t)=>{vi.init(e,t),yi.init(e,t)}),Ol=k("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=Nv),_e.init(e,t)}),Al=k("$ZodUUID",(e,t)=>{if(t.version){let n={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(n===void 0)throw Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=$l(n))}else t.pattern??(t.pattern=$l());_e.init(e,t)}),Cl=k("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=Dv),_e.init(e,t)}),Il=k("$ZodURL",(e,t)=>{_e.init(e,t),e._zod.check=(r)=>{try{let n=r.value,o=new URL(n),i=o.href;if(t.hostname){if(t.hostname.lastIndex=0,!t.hostname.test(o.hostname))r.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:Bv.source,input:r.value,inst:e,continue:!t.abort})}if(t.protocol){if(t.protocol.lastIndex=0,!t.protocol.test(o.protocol.endsWith(":")?o.protocol.slice(0,-1):o.protocol))r.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:r.value,inst:e,continue:!t.abort})}if(!n.endsWith("/")&&i.endsWith("/"))r.value=i.slice(0,-1);else r.value=i;return}catch(n){r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}}),jl=k("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=Mv()),_e.init(e,t)}),Nl=k("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=Iv),_e.init(e,t)}),Dl=k("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=Pv),_e.init(e,t)}),Ml=k("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=zv),_e.init(e,t)}),Ll=k("$ZodULID",(e,t)=>{t.pattern??(t.pattern=Ov),_e.init(e,t)}),ql=k("$ZodXID",(e,t)=>{t.pattern??(t.pattern=Av),_e.init(e,t)}),Ul=k("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=Cv),_e.init(e,t)}),Ry=k("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=Kv(t)),_e.init(e,t)}),Py=k("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=Gv),_e.init(e,t)}),zy=k("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=Wv(t)),_e.init(e,t)}),Oy=k("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=jv),_e.init(e,t)}),Fl=k("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=Lv),_e.init(e,t),e._zod.onattach.push((r)=>{let n=r._zod.bag;n.format="ipv4"})}),Zl=k("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=qv),_e.init(e,t),e._zod.onattach.push((r)=>{let n=r._zod.bag;n.format="ipv6"}),e._zod.check=(r)=>{try{new URL(`http://[${r.value}]`)}catch{r.issues.push({code:"invalid_format",format:"ipv6",input:r.value,inst:e,continue:!t.abort})}}}),Bl=k("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=Uv),_e.init(e,t)}),Hl=k("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=Fv),_e.init(e,t),e._zod.check=(r)=>{let[n,o]=r.value.split("/");try{if(!o)throw Error();let i=Number(o);if(`${i}`!==o)throw Error();if(i<0||i>128)throw Error();new URL(`http://[${n}]`)}catch{r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!t.abort})}}});function Ay(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}var Vl=k("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=Zv),_e.init(e,t),e._zod.onattach.push((r)=>{r._zod.bag.contentEncoding="base64"}),e._zod.check=(r)=>{if(Ay(r.value))return;r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!t.abort})}});function bO(e){if(!Tl.test(e))return!1;let t=e.replace(/[-_]/g,(n)=>n==="-"?"+":"/"),r=t.padEnd(Math.ceil(t.length/4)*4,"=");return Ay(r)}var Gl=k("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=Tl),_e.init(e,t),e._zod.onattach.push((r)=>{r._zod.bag.contentEncoding="base64url"}),e._zod.check=(r)=>{if(bO(r.value))return;r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!t.abort})}}),Jl=k("$ZodE164",(e,t)=>{t.pattern??(t.pattern=Hv),_e.init(e,t)});function _O(e,t=null){try{let r=e.split(".");if(r.length!==3)return!1;let[n]=r;if(!n)return!1;let o=JSON.parse(atob(n));if("typ"in o&&o?.typ!=="JWT")return!1;if(!o.alg)return!1;if(t&&(!("alg"in o)||o.alg!==t))return!1;return!0}catch{return!1}}var Wl=k("$ZodJWT",(e,t)=>{_e.init(e,t),e._zod.check=(r)=>{if(_O(r.value,t.alg))return;r.issues.push({code:"invalid_format",format:"jwt",input:r.value,inst:e,continue:!t.abort})}});var oa=k("$ZodNumber",(e,t)=>{fe.init(e,t),e._zod.pattern=e._zod.bag.pattern??Qv,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=Number(r.value)}catch(s){}let o=r.value;if(typeof o==="number"&&!Number.isNaN(o)&&Number.isFinite(o))return r;let i=typeof o==="number"?Number.isNaN(o)?"NaN":!Number.isFinite(o)?"Infinity":void 0:void 0;return r.issues.push({expected:"number",code:"invalid_type",input:o,inst:e,...i?{received:i}:{}}),r}}),Kl=k("$ZodNumber",(e,t)=>{sy.init(e,t),oa.init(e,t)}),Yl=k("$ZodBoolean",(e,t)=>{fe.init(e,t),e._zod.pattern=ey,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=Boolean(r.value)}catch(i){}let o=r.value;if(typeof o==="boolean")return r;return r.issues.push({expected:"boolean",code:"invalid_type",input:o,inst:e}),r}});var Xl=k("$ZodNull",(e,t)=>{fe.init(e,t),e._zod.pattern=ty,e._zod.values=new Set([null]),e._zod.parse=(r,n)=>{let o=r.value;if(o===null)return r;return r.issues.push({expected:"null",code:"invalid_type",input:o,inst:e}),r}});var Ql=k("$ZodUnknown",(e,t)=>{fe.init(e,t),e._zod.parse=(r)=>r}),ep=k("$ZodNever",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>(r.issues.push({expected:"never",code:"invalid_type",input:r.value,inst:e}),r)});function yy(e,t,r){if(e.issues.length)t.issues.push(...gr(r,e.issues));t.value[r]=e.value}var tp=k("$ZodArray",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;if(!Array.isArray(o))return r.issues.push({expected:"array",code:"invalid_type",input:o,inst:e}),r;r.value=Array(o.length);let i=[];for(let s=0;s<o.length;s++){let a=o[s],c=t.element._zod.run({value:a,issues:[]},n);if(c instanceof Promise)i.push(c.then((u)=>yy(u,r,s)));else yy(c,r,s)}if(i.length)return Promise.all(i).then(()=>r);return r}});function na(e,t,r){if(e.issues.length)t.issues.push(...gr(r,e.issues));t.value[r]=e.value}function by(e,t,r,n){if(e.issues.length)if(n[r]===void 0)if(r in n)t.value[r]=void 0;else t.value[r]=e.value;else t.issues.push(...gr(r,e.issues));else if(e.value===void 0){if(r in n)t.value[r]=void 0}else t.value[r]=e.value}var ia=k("$ZodObject",(e,t)=>{fe.init(e,t);let r=Ys(()=>{let p=Object.keys(t.shape);for(let d of p)if(!(t.shape[d]instanceof fe))throw Error(`Invalid element at key "${d}": expected a Zod schema`);let m=Tv(t.shape);return{shape:t.shape,keys:p,keySet:new Set(p),numKeys:p.length,optionalKeys:new Set(m)}});xe(e._zod,"propValues",()=>{let p=t.shape,m={};for(let d in p){let h=p[d]._zod;if(h.values){m[d]??(m[d]=new Set);for(let x of h.values)m[d].add(x)}}return m});let n=(p)=>{let m=new Pl(["shape","payload","ctx"]),d=r.value,h=(y)=>{let w=Wn(y);return`shape[${w}]._zod.run({ value: input[${w}], issues: [] }, ctx)`};m.write("const input = payload.value;");let x=Object.create(null),v=0;for(let y of d.keys)x[y]=`key_${v++}`;m.write("const newResult = {}");for(let y of d.keys)if(d.optionalKeys.has(y)){let w=x[y];m.write(`const ${w} = ${h(y)};`);let P=Wn(y);m.write(`
|
|
38
|
+
if (${w}.issues.length) {
|
|
39
|
+
if (input[${P}] === undefined) {
|
|
40
|
+
if (${P} in input) {
|
|
41
|
+
newResult[${P}] = undefined;
|
|
42
42
|
}
|
|
43
43
|
} else {
|
|
44
44
|
payload.issues = payload.issues.concat(
|
|
45
|
-
${
|
|
45
|
+
${w}.issues.map((iss) => ({
|
|
46
46
|
...iss,
|
|
47
|
-
path: iss.path ? [${
|
|
47
|
+
path: iss.path ? [${P}, ...iss.path] : [${P}],
|
|
48
48
|
}))
|
|
49
49
|
);
|
|
50
50
|
}
|
|
51
|
-
} else if (${
|
|
52
|
-
if (${
|
|
51
|
+
} else if (${w}.value === undefined) {
|
|
52
|
+
if (${P} in input) newResult[${P}] = undefined;
|
|
53
53
|
} else {
|
|
54
|
-
newResult[${
|
|
54
|
+
newResult[${P}] = ${w}.value;
|
|
55
55
|
}
|
|
56
|
-
`)}else{let
|
|
57
|
-
if (${
|
|
56
|
+
`)}else{let w=x[y];m.write(`const ${w} = ${h(y)};`),m.write(`
|
|
57
|
+
if (${w}.issues.length) payload.issues = payload.issues.concat(${w}.issues.map(iss => ({
|
|
58
58
|
...iss,
|
|
59
|
-
path: iss.path ? [${
|
|
60
|
-
})));`),m.write(`newResult[${hn(b)}] = ${k}.value`)}m.write("payload.value = newResult;"),m.write("return payload;");let g=m.compile();return(b,k)=>g(p,b,k)},o,i=co,s=!ta.jitless,c=s&&vl.value,u=t.catchall,l;e._zod.parse=(p,m)=>{l??(l=r.value);let d=p.value;if(!i(d))return p.issues.push({expected:"object",code:"invalid_type",input:d,inst:e}),p;let h=[];if(s&&c&&m?.async===!1&&m.jitless!==!0){if(!o)o=n(t.shape);p=o(p,m)}else{p.value={};let k=l.shape;for(let z of l.keys){let I=k[z],H=I._zod.run({value:d[z],issues:[]},m),me=I._zod.optin==="optional"&&I._zod.optout==="optional";if(H instanceof Promise)h.push(H.then((K)=>me?Ny(K,p,z,d):aa(K,p,z)));else if(me)Ny(H,p,z,d);else aa(H,p,z)}}if(!u)return h.length?Promise.all(h).then(()=>p):p;let x=[],y=l.keySet,g=u._zod,b=g.def.type;for(let k of Object.keys(d)){if(y.has(k))continue;if(b==="never"){x.push(k);continue}let z=g.run({value:d[k],issues:[]},m);if(z instanceof Promise)h.push(z.then((I)=>aa(I,p,k)));else aa(z,p,k)}if(x.length)p.issues.push({code:"unrecognized_keys",keys:x,input:d,inst:e});if(!h.length)return p;return Promise.all(h).then(()=>p)}});function Dy(e,t,r,n){for(let o of e)if(o.issues.length===0)return t.value=o.value,t;return t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map((o)=>o.issues.map((i)=>Vt(i,n,St())))}),t}var la=S("$ZodUnion",(e,t)=>{fe.init(e,t),be(e._zod,"optin",()=>t.options.some((r)=>r._zod.optin==="optional")?"optional":void 0),be(e._zod,"optout",()=>t.options.some((r)=>r._zod.optout==="optional")?"optional":void 0),be(e._zod,"values",()=>{if(t.options.every((r)=>r._zod.values))return new Set(t.options.flatMap((r)=>Array.from(r._zod.values)));return}),be(e._zod,"pattern",()=>{if(t.options.every((r)=>r._zod.pattern)){let r=t.options.map((n)=>n._zod.pattern);return new RegExp(`^(${r.map((n)=>wi(n.source)).join("|")})$`)}return}),e._zod.parse=(r,n)=>{let o=!1,i=[];for(let s of t.options){let a=s._zod.run({value:r.value,issues:[]},n);if(a instanceof Promise)i.push(a),o=!0;else{if(a.issues.length===0)return a;i.push(a)}}if(!o)return Dy(i,r,e,n);return Promise.all(i).then((s)=>Dy(s,r,e,n))}}),cp=S("$ZodDiscriminatedUnion",(e,t)=>{la.init(e,t);let r=e._zod.parse;be(e._zod,"propValues",()=>{let o={};for(let i of t.options){let s=i._zod.propValues;if(!s||Object.keys(s).length===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[a,c]of Object.entries(s)){if(!o[a])o[a]=new Set;for(let u of c)o[a].add(u)}}return o});let n=bi(()=>{let o=t.options,i=new Map;for(let s of o){let a=s._zod.propValues[t.discriminator];if(!a||a.size===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(let c of a){if(i.has(c))throw Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,s)}}return i});e._zod.parse=(o,i)=>{let s=o.value;if(!co(s))return o.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),o;let a=n.value.get(s?.[t.discriminator]);if(a)return a._zod.run(o,i);if(t.unionFallback)return r(o,i);return o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:s,path:[t.discriminator],inst:e}),o}}),up=S("$ZodIntersection",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=r.value,i=t.left._zod.run({value:o,issues:[]},n),s=t.right._zod.run({value:o,issues:[]},n);if(i instanceof Promise||s instanceof Promise)return Promise.all([i,s]).then(([c,u])=>Ly(r,c,u));return Ly(r,i,s)}});function Nl(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e===+t)return{valid:!0,data:e};if(uo(e)&&uo(t)){let r=Object.keys(t),n=Object.keys(e).filter((i)=>r.indexOf(i)!==-1),o={...e,...t};for(let i of n){let s=Nl(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};o[i]=s.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let n=0;n<e.length;n++){let o=e[n],i=t[n],s=Nl(o,i);if(!s.valid)return{valid:!1,mergeErrorPath:[n,...s.mergeErrorPath]};r.push(s.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}function Ly(e,t,r){if(t.issues.length)e.issues.push(...t.issues);if(r.issues.length)e.issues.push(...r.issues);if(gn(e))return e;let n=Nl(t.value,r.value);if(!n.valid)throw Error(`Unmergable intersection. Error path: ${JSON.stringify(n.mergeErrorPath)}`);return e.value=n.data,e}var lp=S("$ZodRecord",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;if(!uo(o))return r.issues.push({expected:"record",code:"invalid_type",input:o,inst:e}),r;let i=[];if(t.keyType._zod.values){let s=t.keyType._zod.values;r.value={};for(let c of s)if(typeof c==="string"||typeof c==="number"||typeof c==="symbol"){let u=t.valueType._zod.run({value:o[c],issues:[]},n);if(u instanceof Promise)i.push(u.then((l)=>{if(l.issues.length)r.issues.push(...ar(c,l.issues));r.value[c]=l.value}));else{if(u.issues.length)r.issues.push(...ar(c,u.issues));r.value[c]=u.value}}let a;for(let c in o)if(!s.has(c))a=a??[],a.push(c);if(a&&a.length>0)r.issues.push({code:"unrecognized_keys",input:o,inst:e,keys:a})}else{r.value={};for(let s of Reflect.ownKeys(o)){if(s==="__proto__")continue;let a=t.keyType._zod.run({value:s,issues:[]},n);if(a instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(a.issues.length){r.issues.push({origin:"record",code:"invalid_key",issues:a.issues.map((u)=>Vt(u,n,St())),input:s,path:[s],inst:e}),r.value[a.value]=a.value;continue}let c=t.valueType._zod.run({value:o[s],issues:[]},n);if(c instanceof Promise)i.push(c.then((u)=>{if(u.issues.length)r.issues.push(...ar(s,u.issues));r.value[a.value]=u.value}));else{if(c.issues.length)r.issues.push(...ar(s,c.issues));r.value[a.value]=c.value}}}if(i.length)return Promise.all(i).then(()=>r);return r}});var pp=S("$ZodEnum",(e,t)=>{fe.init(e,t);let r=yi(t.entries);e._zod.values=new Set(r),e._zod.pattern=new RegExp(`^(${r.filter((n)=>yl.has(typeof n)).map((n)=>typeof n==="string"?Cr(n):n.toString()).join("|")})$`),e._zod.parse=(n,o)=>{let i=n.value;if(e._zod.values.has(i))return n;return n.issues.push({code:"invalid_value",values:r,input:i,inst:e}),n}}),dp=S("$ZodLiteral",(e,t)=>{fe.init(e,t),e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map((r)=>typeof r==="string"?Cr(r):r?r.toString():String(r)).join("|")})$`),e._zod.parse=(r,n)=>{let o=r.value;if(e._zod.values.has(o))return r;return r.issues.push({code:"invalid_value",values:t.values,input:o,inst:e}),r}});var mp=S("$ZodTransform",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=t.transform(r.value,r);if(n.async)return(o instanceof Promise?o:Promise.resolve(o)).then((s)=>(r.value=s,r));if(o instanceof Promise)throw new Ar;return r.value=o,r}}),fp=S("$ZodOptional",(e,t)=>{fe.init(e,t),e._zod.optin="optional",e._zod.optout="optional",be(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),be(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${wi(r.source)})?$`):void 0}),e._zod.parse=(r,n)=>{if(t.innerType._zod.optin==="optional")return t.innerType._zod.run(r,n);if(r.value===void 0)return r;return t.innerType._zod.run(r,n)}}),hp=S("$ZodNullable",(e,t)=>{fe.init(e,t),be(e._zod,"optin",()=>t.innerType._zod.optin),be(e._zod,"optout",()=>t.innerType._zod.optout),be(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${wi(r.source)}|null)$`):void 0}),be(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(r,n)=>{if(r.value===null)return r;return t.innerType._zod.run(r,n)}}),gp=S("$ZodDefault",(e,t)=>{fe.init(e,t),e._zod.optin="optional",be(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{if(r.value===void 0)return r.value=t.defaultValue,r;let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>My(i,t));return My(o,t)}});function My(e,t){if(e.value===void 0)e.value=t.defaultValue;return e}var xp=S("$ZodPrefault",(e,t)=>{fe.init(e,t),e._zod.optin="optional",be(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{if(r.value===void 0)r.value=t.defaultValue;return t.innerType._zod.run(r,n)}}),vp=S("$ZodNonOptional",(e,t)=>{fe.init(e,t),be(e._zod,"values",()=>{let r=t.innerType._zod.values;return r?new Set([...r].filter((n)=>n!==void 0)):void 0}),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>qy(i,e));return qy(o,e)}});function qy(e,t){if(!e.issues.length&&e.value===void 0)e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t});return e}var yp=S("$ZodCatch",(e,t)=>{fe.init(e,t),e._zod.optin="optional",be(e._zod,"optout",()=>t.innerType._zod.optout),be(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>{if(r.value=i.value,i.issues.length)r.value=t.catchValue({...r,error:{issues:i.issues.map((s)=>Vt(s,n,St()))},input:r.value}),r.issues=[];return r});if(r.value=o.value,o.issues.length)r.value=t.catchValue({...r,error:{issues:o.issues.map((i)=>Vt(i,n,St()))},input:r.value}),r.issues=[];return r}});var bp=S("$ZodPipe",(e,t)=>{fe.init(e,t),be(e._zod,"values",()=>t.in._zod.values),be(e._zod,"optin",()=>t.in._zod.optin),be(e._zod,"optout",()=>t.out._zod.optout),e._zod.parse=(r,n)=>{let o=t.in._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>Uy(i,t,n));return Uy(o,t,n)}});function Uy(e,t,r){if(gn(e))return e;return t.out._zod.run({value:e.value,issues:e.issues},r)}var _p=S("$ZodReadonly",(e,t)=>{fe.init(e,t),be(e._zod,"propValues",()=>t.innerType._zod.propValues),be(e._zod,"values",()=>t.innerType._zod.values),be(e._zod,"optin",()=>t.innerType._zod.optin),be(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then(Fy);return Fy(o)}});function Fy(e){return e.value=Object.freeze(e.value),e}var wp=S("$ZodCustom",(e,t)=>{Ye.init(e,t),fe.init(e,t),e._zod.parse=(r,n)=>r,e._zod.check=(r)=>{let n=r.value,o=t.fn(n);if(o instanceof Promise)return o.then((i)=>Zy(i,r,n,e));Zy(o,r,n,e);return}});function Zy(e,t,r,n){if(!e){let o={code:"custom",input:r,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};if(n._zod.def.params)o.params=n._zod.def.params;t.issues.push(wl(o))}}var NC=(e)=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},DC=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function t(n){return e[n]??null}let r={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return(n)=>{switch(n.code){case"invalid_type":return`Invalid input: expected ${n.expected}, received ${NC(n.input)}`;case"invalid_value":if(n.values.length===1)return`Invalid input: expected ${oa(n.values[0])}`;return`Invalid option: expected one of ${ra(n.values,"|")}`;case"too_big":{let o=n.inclusive?"<=":"<",i=t(n.origin);if(i)return`Too big: expected ${n.origin??"value"} to have ${o}${n.maximum.toString()} ${i.unit??"elements"}`;return`Too big: expected ${n.origin??"value"} to be ${o}${n.maximum.toString()}`}case"too_small":{let o=n.inclusive?">=":">",i=t(n.origin);if(i)return`Too small: expected ${n.origin} to have ${o}${n.minimum.toString()} ${i.unit}`;return`Too small: expected ${n.origin} to be ${o}${n.minimum.toString()}`}case"invalid_format":{let o=n;if(o.format==="starts_with")return`Invalid string: must start with "${o.prefix}"`;if(o.format==="ends_with")return`Invalid string: must end with "${o.suffix}"`;if(o.format==="includes")return`Invalid string: must include "${o.includes}"`;if(o.format==="regex")return`Invalid string: must match pattern ${o.pattern}`;return`Invalid ${r[o.format]??n.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${n.divisor}`;case"unrecognized_keys":return`Unrecognized key${n.keys.length>1?"s":""}: ${ra(n.keys,", ")}`;case"invalid_key":return`Invalid key in ${n.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${n.origin}`;default:return"Invalid input"}}};function kp(){return{localeError:DC()}}var LC=Symbol("ZodOutput"),MC=Symbol("ZodInput");class pa{constructor(){this._map=new Map,this._idmap=new Map}add(e,...t){let r=t[0];if(this._map.set(e,r),r&&typeof r==="object"&&"id"in r){if(this._idmap.has(r.id))throw Error(`ID ${r.id} already exists in the registry`);this._idmap.set(r.id,e)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(e){let t=this._map.get(e);if(t&&typeof t==="object"&&"id"in t)this._idmap.delete(t.id);return this._map.delete(e),this}get(e){let t=e._zod.parent;if(t){let r={...this.get(t)??{}};return delete r.id,{...r,...this._map.get(e)}}return this._map.get(e)}has(e){return this._map.has(e)}}function Wy(){return new pa}var Ir=Wy();function Sp(e,t){return new e({type:"string",...F(t)})}function $p(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...F(t)})}function da(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...F(t)})}function Tp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...F(t)})}function Ep(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...F(t)})}function Rp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...F(t)})}function Pp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...F(t)})}function zp(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...F(t)})}function Op(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...F(t)})}function Ap(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...F(t)})}function Cp(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...F(t)})}function Ip(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...F(t)})}function jp(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...F(t)})}function Np(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...F(t)})}function Dp(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...F(t)})}function Lp(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...F(t)})}function Mp(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...F(t)})}function qp(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...F(t)})}function Up(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...F(t)})}function Fp(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...F(t)})}function Zp(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...F(t)})}function Bp(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...F(t)})}function Hp(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...F(t)})}function Ky(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...F(t)})}function Yy(e,t){return new e({type:"string",format:"date",check:"string_format",...F(t)})}function Xy(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...F(t)})}function Qy(e,t){return new e({type:"string",format:"duration",check:"string_format",...F(t)})}function Vp(e,t){return new e({type:"number",checks:[],...F(t)})}function Gp(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...F(t)})}function Jp(e,t){return new e({type:"boolean",...F(t)})}function Wp(e,t){return new e({type:"null",...F(t)})}function Kp(e){return new e({type:"unknown"})}function Yp(e,t){return new e({type:"never",...F(t)})}function ma(e,t){return new Cl({check:"less_than",...F(t),value:e,inclusive:!1})}function Ei(e,t){return new Cl({check:"less_than",...F(t),value:e,inclusive:!0})}function fa(e,t){return new Il({check:"greater_than",...F(t),value:e,inclusive:!1})}function Ri(e,t){return new Il({check:"greater_than",...F(t),value:e,inclusive:!0})}function ha(e,t){return new _y({check:"multiple_of",...F(t),value:e})}function ga(e,t){return new ky({check:"max_length",...F(t),maximum:e})}function lo(e,t){return new Sy({check:"min_length",...F(t),minimum:e})}function xa(e,t){return new $y({check:"length_equals",...F(t),length:e})}function Xp(e,t){return new Ty({check:"string_format",format:"regex",...F(t),pattern:e})}function Qp(e){return new Ey({check:"string_format",format:"lowercase",...F(e)})}function ed(e){return new Ry({check:"string_format",format:"uppercase",...F(e)})}function td(e,t){return new Py({check:"string_format",format:"includes",...F(t),includes:e})}function rd(e,t){return new zy({check:"string_format",format:"starts_with",...F(t),prefix:e})}function nd(e,t){return new Oy({check:"string_format",format:"ends_with",...F(t),suffix:e})}function yn(e){return new Ay({check:"overwrite",tx:e})}function od(e){return yn((t)=>t.normalize(e))}function id(){return yn((e)=>e.trim())}function sd(){return yn((e)=>e.toLowerCase())}function ad(){return yn((e)=>e.toUpperCase())}function eb(e,t,r){return new e({type:"array",element:t,...F(r)})}function cd(e,t,r){let n=F(r);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}function ud(e,t,r){return new e({type:"custom",check:"custom",fn:t,...F(r)})}class ld{constructor(e){this.counter=0,this.metadataRegistry=e?.metadata??Ir,this.target=e?.target??"draft-2020-12",this.unrepresentable=e?.unrepresentable??"throw",this.override=e?.override??(()=>{}),this.io=e?.io??"output",this.seen=new Map}process(e,t={path:[],schemaPath:[]}){var r;let n=e._zod.def,o={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},i=this.seen.get(e);if(i){if(i.count++,t.schemaPath.includes(e))i.cycle=t.path;return i.schema}let s={schema:{},count:1,cycle:void 0,path:t.path};this.seen.set(e,s);let a=e._zod.toJSONSchema?.();if(a)s.schema=a;else{let l={...t,schemaPath:[...t.schemaPath,e],path:t.path},p=e._zod.parent;if(p)s.ref=p,this.process(p,l),this.seen.get(p).isParent=!0;else{let m=s.schema;switch(n.type){case"string":{let d=m;d.type="string";let{minimum:h,maximum:x,format:y,patterns:g,contentEncoding:b}=e._zod.bag;if(typeof h==="number")d.minLength=h;if(typeof x==="number")d.maxLength=x;if(y){if(d.format=o[y]??y,d.format==="")delete d.format}if(b)d.contentEncoding=b;if(g&&g.size>0){let k=[...g];if(k.length===1)d.pattern=k[0].source;else if(k.length>1)s.schema.allOf=[...k.map((z)=>({...this.target==="draft-7"?{type:"string"}:{},pattern:z.source}))]}break}case"number":{let d=m,{minimum:h,maximum:x,format:y,multipleOf:g,exclusiveMaximum:b,exclusiveMinimum:k}=e._zod.bag;if(typeof y==="string"&&y.includes("int"))d.type="integer";else d.type="number";if(typeof k==="number")d.exclusiveMinimum=k;if(typeof h==="number"){if(d.minimum=h,typeof k==="number")if(k>=h)delete d.minimum;else delete d.exclusiveMinimum}if(typeof b==="number")d.exclusiveMaximum=b;if(typeof x==="number"){if(d.maximum=x,typeof b==="number")if(b<=x)delete d.maximum;else delete d.exclusiveMaximum}if(typeof g==="number")d.multipleOf=g;break}case"boolean":{let d=m;d.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw Error("Symbols cannot be represented in JSON Schema");break}case"null":{m.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw Error("Void cannot be represented in JSON Schema");break}case"never":{m.not={};break}case"date":{if(this.unrepresentable==="throw")throw Error("Date cannot be represented in JSON Schema");break}case"array":{let d=m,{minimum:h,maximum:x}=e._zod.bag;if(typeof h==="number")d.minItems=h;if(typeof x==="number")d.maxItems=x;d.type="array",d.items=this.process(n.element,{...l,path:[...l.path,"items"]});break}case"object":{let d=m;d.type="object",d.properties={};let h=n.shape;for(let g in h)d.properties[g]=this.process(h[g],{...l,path:[...l.path,"properties",g]});let x=new Set(Object.keys(h)),y=new Set([...x].filter((g)=>{let b=n.shape[g]._zod;if(this.io==="input")return b.optin===void 0;else return b.optout===void 0}));if(y.size>0)d.required=Array.from(y);if(n.catchall?._zod.def.type==="never")d.additionalProperties=!1;else if(!n.catchall){if(this.io==="output")d.additionalProperties=!1}else if(n.catchall)d.additionalProperties=this.process(n.catchall,{...l,path:[...l.path,"additionalProperties"]});break}case"union":{let d=m;d.anyOf=n.options.map((h,x)=>this.process(h,{...l,path:[...l.path,"anyOf",x]}));break}case"intersection":{let d=m,h=this.process(n.left,{...l,path:[...l.path,"allOf",0]}),x=this.process(n.right,{...l,path:[...l.path,"allOf",1]}),y=(b)=>("allOf"in b)&&Object.keys(b).length===1,g=[...y(h)?h.allOf:[h],...y(x)?x.allOf:[x]];d.allOf=g;break}case"tuple":{let d=m;d.type="array";let h=n.items.map((g,b)=>this.process(g,{...l,path:[...l.path,"prefixItems",b]}));if(this.target==="draft-2020-12")d.prefixItems=h;else d.items=h;if(n.rest){let g=this.process(n.rest,{...l,path:[...l.path,"items"]});if(this.target==="draft-2020-12")d.items=g;else d.additionalItems=g}if(n.rest)d.items=this.process(n.rest,{...l,path:[...l.path,"items"]});let{minimum:x,maximum:y}=e._zod.bag;if(typeof x==="number")d.minItems=x;if(typeof y==="number")d.maxItems=y;break}case"record":{let d=m;d.type="object",d.propertyNames=this.process(n.keyType,{...l,path:[...l.path,"propertyNames"]}),d.additionalProperties=this.process(n.valueType,{...l,path:[...l.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw Error("Set cannot be represented in JSON Schema");break}case"enum":{let d=m,h=yi(n.entries);if(h.every((x)=>typeof x==="number"))d.type="number";if(h.every((x)=>typeof x==="string"))d.type="string";d.enum=h;break}case"literal":{let d=m,h=[];for(let x of n.values)if(x===void 0){if(this.unrepresentable==="throw")throw Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof x==="bigint")if(this.unrepresentable==="throw")throw Error("BigInt literals cannot be represented in JSON Schema");else h.push(Number(x));else h.push(x);if(h.length===0);else if(h.length===1){let x=h[0];d.type=x===null?"null":typeof x,d.const=x}else{if(h.every((x)=>typeof x==="number"))d.type="number";if(h.every((x)=>typeof x==="string"))d.type="string";if(h.every((x)=>typeof x==="boolean"))d.type="string";if(h.every((x)=>x===null))d.type="null";d.enum=h}break}case"file":{let d=m,h={type:"string",format:"binary",contentEncoding:"binary"},{minimum:x,maximum:y,mime:g}=e._zod.bag;if(x!==void 0)h.minLength=x;if(y!==void 0)h.maxLength=y;if(g)if(g.length===1)h.contentMediaType=g[0],Object.assign(d,h);else d.anyOf=g.map((b)=>({...h,contentMediaType:b}));else Object.assign(d,h);break}case"transform":{if(this.unrepresentable==="throw")throw Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let d=this.process(n.innerType,l);m.anyOf=[d,{type:"null"}];break}case"nonoptional":{this.process(n.innerType,l),s.ref=n.innerType;break}case"success":{let d=m;d.type="boolean";break}case"default":{this.process(n.innerType,l),s.ref=n.innerType,m.default=JSON.parse(JSON.stringify(n.defaultValue));break}case"prefault":{if(this.process(n.innerType,l),s.ref=n.innerType,this.io==="input")m._prefault=JSON.parse(JSON.stringify(n.defaultValue));break}case"catch":{this.process(n.innerType,l),s.ref=n.innerType;let d;try{d=n.catchValue(void 0)}catch{throw Error("Dynamic catch values are not supported in JSON Schema")}m.default=d;break}case"nan":{if(this.unrepresentable==="throw")throw Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let d=m,h=e._zod.pattern;if(!h)throw Error("Pattern not found in template literal");d.type="string",d.pattern=h.source;break}case"pipe":{let d=this.io==="input"?n.in._zod.def.type==="transform"?n.out:n.in:n.out;this.process(d,l),s.ref=d;break}case"readonly":{this.process(n.innerType,l),s.ref=n.innerType,m.readOnly=!0;break}case"promise":{this.process(n.innerType,l),s.ref=n.innerType;break}case"optional":{this.process(n.innerType,l),s.ref=n.innerType;break}case"lazy":{let d=e._zod.innerType;this.process(d,l),s.ref=d;break}case"custom":{if(this.unrepresentable==="throw")throw Error("Custom types cannot be represented in JSON Schema");break}default:}}}let c=this.metadataRegistry.get(e);if(c)Object.assign(s.schema,c);if(this.io==="input"&&Ue(e))delete s.schema.examples,delete s.schema.default;if(this.io==="input"&&s.schema._prefault)(r=s.schema).default??(r.default=s.schema._prefault);return delete s.schema._prefault,this.seen.get(e).schema}emit(e,t){let r={cycles:t?.cycles??"ref",reused:t?.reused??"inline",external:t?.external??void 0},n=this.seen.get(e);if(!n)throw Error("Unprocessed schema. This is a bug in Zod.");let o=(u)=>{let l=this.target==="draft-2020-12"?"$defs":"definitions";if(r.external){let h=r.external.registry.get(u[0])?.id,x=r.external.uri??((g)=>g);if(h)return{ref:x(h)};let y=u[1].defId??u[1].schema.id??`schema${this.counter++}`;return u[1].defId=y,{defId:y,ref:`${x("__shared")}#/${l}/${y}`}}if(u[1]===n)return{ref:"#"};let m=`${"#"}/${l}/`,d=u[1].schema.id??`__schema${this.counter++}`;return{defId:d,ref:m+d}},i=(u)=>{if(u[1].schema.$ref)return;let l=u[1],{ref:p,defId:m}=o(u);if(l.def={...l.schema},m)l.defId=m;let d=l.schema;for(let h in d)delete d[h];d.$ref=p};if(r.cycles==="throw")for(let u of this.seen.entries()){let l=u[1];if(l.cycle)throw Error(`Cycle detected: #/${l.cycle?.join("/")}/<root>
|
|
59
|
+
path: iss.path ? [${Wn(y)}, ...iss.path] : [${Wn(y)}]
|
|
60
|
+
})));`),m.write(`newResult[${Wn(y)}] = ${w}.value`)}m.write("payload.value = newResult;"),m.write("return payload;");let g=m.compile();return(y,w)=>g(p,y,w)},o,i=fi,s=!Js.jitless,c=s&&Sv.value,u=t.catchall,l;e._zod.parse=(p,m)=>{l??(l=r.value);let d=p.value;if(!i(d))return p.issues.push({expected:"object",code:"invalid_type",input:d,inst:e}),p;let h=[];if(s&&c&&m?.async===!1&&m.jitless!==!0){if(!o)o=n(t.shape);p=o(p,m)}else{p.value={};let w=l.shape;for(let P of l.keys){let I=w[P],H=I._zod.run({value:d[P],issues:[]},m),me=I._zod.optin==="optional"&&I._zod.optout==="optional";if(H instanceof Promise)h.push(H.then((K)=>me?by(K,p,P,d):na(K,p,P)));else if(me)by(H,p,P,d);else na(H,p,P)}}if(!u)return h.length?Promise.all(h).then(()=>p):p;let x=[],v=l.keySet,g=u._zod,y=g.def.type;for(let w of Object.keys(d)){if(v.has(w))continue;if(y==="never"){x.push(w);continue}let P=g.run({value:d[w],issues:[]},m);if(P instanceof Promise)h.push(P.then((I)=>na(I,p,w)));else na(P,p,w)}if(x.length)p.issues.push({code:"unrecognized_keys",keys:x,input:d,inst:e});if(!h.length)return p;return Promise.all(h).then(()=>p)}});function _y(e,t,r,n){for(let o of e)if(o.issues.length===0)return t.value=o.value,t;return t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map((o)=>o.issues.map((i)=>sr(i,n,Tt())))}),t}var sa=k("$ZodUnion",(e,t)=>{fe.init(e,t),xe(e._zod,"optin",()=>t.options.some((r)=>r._zod.optin==="optional")?"optional":void 0),xe(e._zod,"optout",()=>t.options.some((r)=>r._zod.optout==="optional")?"optional":void 0),xe(e._zod,"values",()=>{if(t.options.every((r)=>r._zod.values))return new Set(t.options.flatMap((r)=>Array.from(r._zod.values)));return}),xe(e._zod,"pattern",()=>{if(t.options.every((r)=>r._zod.pattern)){let r=t.options.map((n)=>n._zod.pattern);return new RegExp(`^(${r.map((n)=>Qs(n.source)).join("|")})$`)}return}),e._zod.parse=(r,n)=>{let o=!1,i=[];for(let s of t.options){let a=s._zod.run({value:r.value,issues:[]},n);if(a instanceof Promise)i.push(a),o=!0;else{if(a.issues.length===0)return a;i.push(a)}}if(!o)return _y(i,r,e,n);return Promise.all(i).then((s)=>_y(s,r,e,n))}}),rp=k("$ZodDiscriminatedUnion",(e,t)=>{sa.init(e,t);let r=e._zod.parse;xe(e._zod,"propValues",()=>{let o={};for(let i of t.options){let s=i._zod.propValues;if(!s||Object.keys(s).length===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[a,c]of Object.entries(s)){if(!o[a])o[a]=new Set;for(let u of c)o[a].add(u)}}return o});let n=Ys(()=>{let o=t.options,i=new Map;for(let s of o){let a=s._zod.propValues[t.discriminator];if(!a||a.size===0)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(let c of a){if(i.has(c))throw Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,s)}}return i});e._zod.parse=(o,i)=>{let s=o.value;if(!fi(s))return o.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),o;let a=n.value.get(s?.[t.discriminator]);if(a)return a._zod.run(o,i);if(t.unionFallback)return r(o,i);return o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:s,path:[t.discriminator],inst:e}),o}}),np=k("$ZodIntersection",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=r.value,i=t.left._zod.run({value:o,issues:[]},n),s=t.right._zod.run({value:o,issues:[]},n);if(i instanceof Promise||s instanceof Promise)return Promise.all([i,s]).then(([c,u])=>wy(r,c,u));return wy(r,i,s)}});function zl(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e===+t)return{valid:!0,data:e};if(gi(e)&&gi(t)){let r=Object.keys(t),n=Object.keys(e).filter((i)=>r.indexOf(i)!==-1),o={...e,...t};for(let i of n){let s=zl(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};o[i]=s.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let n=0;n<e.length;n++){let o=e[n],i=t[n],s=zl(o,i);if(!s.valid)return{valid:!1,mergeErrorPath:[n,...s.mergeErrorPath]};r.push(s.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}function wy(e,t,r){if(t.issues.length)e.issues.push(...t.issues);if(r.issues.length)e.issues.push(...r.issues);if(Kn(e))return e;let n=zl(t.value,r.value);if(!n.valid)throw Error(`Unmergable intersection. Error path: ${JSON.stringify(n.mergeErrorPath)}`);return e.value=n.data,e}var op=k("$ZodRecord",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;if(!gi(o))return r.issues.push({expected:"record",code:"invalid_type",input:o,inst:e}),r;let i=[];if(t.keyType._zod.values){let s=t.keyType._zod.values;r.value={};for(let c of s)if(typeof c==="string"||typeof c==="number"||typeof c==="symbol"){let u=t.valueType._zod.run({value:o[c],issues:[]},n);if(u instanceof Promise)i.push(u.then((l)=>{if(l.issues.length)r.issues.push(...gr(c,l.issues));r.value[c]=l.value}));else{if(u.issues.length)r.issues.push(...gr(c,u.issues));r.value[c]=u.value}}let a;for(let c in o)if(!s.has(c))a=a??[],a.push(c);if(a&&a.length>0)r.issues.push({code:"unrecognized_keys",input:o,inst:e,keys:a})}else{r.value={};for(let s of Reflect.ownKeys(o)){if(s==="__proto__")continue;let a=t.keyType._zod.run({value:s,issues:[]},n);if(a instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(a.issues.length){r.issues.push({origin:"record",code:"invalid_key",issues:a.issues.map((u)=>sr(u,n,Tt())),input:s,path:[s],inst:e}),r.value[a.value]=a.value;continue}let c=t.valueType._zod.run({value:o[s],issues:[]},n);if(c instanceof Promise)i.push(c.then((u)=>{if(u.issues.length)r.issues.push(...gr(s,u.issues));r.value[a.value]=u.value}));else{if(c.issues.length)r.issues.push(...gr(s,c.issues));r.value[a.value]=c.value}}}if(i.length)return Promise.all(i).then(()=>r);return r}});var ip=k("$ZodEnum",(e,t)=>{fe.init(e,t);let r=Ks(t.entries);e._zod.values=new Set(r),e._zod.pattern=new RegExp(`^(${r.filter((n)=>$v.has(typeof n)).map((n)=>typeof n==="string"?pn(n):n.toString()).join("|")})$`),e._zod.parse=(n,o)=>{let i=n.value;if(e._zod.values.has(i))return n;return n.issues.push({code:"invalid_value",values:r,input:i,inst:e}),n}}),sp=k("$ZodLiteral",(e,t)=>{fe.init(e,t),e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map((r)=>typeof r==="string"?pn(r):r?r.toString():String(r)).join("|")})$`),e._zod.parse=(r,n)=>{let o=r.value;if(e._zod.values.has(o))return r;return r.issues.push({code:"invalid_value",values:t.values,input:o,inst:e}),r}});var ap=k("$ZodTransform",(e,t)=>{fe.init(e,t),e._zod.parse=(r,n)=>{let o=t.transform(r.value,r);if(n.async)return(o instanceof Promise?o:Promise.resolve(o)).then((s)=>(r.value=s,r));if(o instanceof Promise)throw new Or;return r.value=o,r}}),cp=k("$ZodOptional",(e,t)=>{fe.init(e,t),e._zod.optin="optional",e._zod.optout="optional",xe(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),xe(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${Qs(r.source)})?$`):void 0}),e._zod.parse=(r,n)=>{if(t.innerType._zod.optin==="optional")return t.innerType._zod.run(r,n);if(r.value===void 0)return r;return t.innerType._zod.run(r,n)}}),up=k("$ZodNullable",(e,t)=>{fe.init(e,t),xe(e._zod,"optin",()=>t.innerType._zod.optin),xe(e._zod,"optout",()=>t.innerType._zod.optout),xe(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${Qs(r.source)}|null)$`):void 0}),xe(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(r,n)=>{if(r.value===null)return r;return t.innerType._zod.run(r,n)}}),lp=k("$ZodDefault",(e,t)=>{fe.init(e,t),e._zod.optin="optional",xe(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{if(r.value===void 0)return r.value=t.defaultValue,r;let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>ky(i,t));return ky(o,t)}});function ky(e,t){if(e.value===void 0)e.value=t.defaultValue;return e}var pp=k("$ZodPrefault",(e,t)=>{fe.init(e,t),e._zod.optin="optional",xe(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{if(r.value===void 0)r.value=t.defaultValue;return t.innerType._zod.run(r,n)}}),dp=k("$ZodNonOptional",(e,t)=>{fe.init(e,t),xe(e._zod,"values",()=>{let r=t.innerType._zod.values;return r?new Set([...r].filter((n)=>n!==void 0)):void 0}),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>Sy(i,e));return Sy(o,e)}});function Sy(e,t){if(!e.issues.length&&e.value===void 0)e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t});return e}var mp=k("$ZodCatch",(e,t)=>{fe.init(e,t),e._zod.optin="optional",xe(e._zod,"optout",()=>t.innerType._zod.optout),xe(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>{if(r.value=i.value,i.issues.length)r.value=t.catchValue({...r,error:{issues:i.issues.map((s)=>sr(s,n,Tt()))},input:r.value}),r.issues=[];return r});if(r.value=o.value,o.issues.length)r.value=t.catchValue({...r,error:{issues:o.issues.map((i)=>sr(i,n,Tt()))},input:r.value}),r.issues=[];return r}});var fp=k("$ZodPipe",(e,t)=>{fe.init(e,t),xe(e._zod,"values",()=>t.in._zod.values),xe(e._zod,"optin",()=>t.in._zod.optin),xe(e._zod,"optout",()=>t.out._zod.optout),e._zod.parse=(r,n)=>{let o=t.in._zod.run(r,n);if(o instanceof Promise)return o.then((i)=>$y(i,t,n));return $y(o,t,n)}});function $y(e,t,r){if(Kn(e))return e;return t.out._zod.run({value:e.value,issues:e.issues},r)}var hp=k("$ZodReadonly",(e,t)=>{fe.init(e,t),xe(e._zod,"propValues",()=>t.innerType._zod.propValues),xe(e._zod,"values",()=>t.innerType._zod.values),xe(e._zod,"optin",()=>t.innerType._zod.optin),xe(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(r,n)=>{let o=t.innerType._zod.run(r,n);if(o instanceof Promise)return o.then(Ty);return Ty(o)}});function Ty(e){return e.value=Object.freeze(e.value),e}var gp=k("$ZodCustom",(e,t)=>{Xe.init(e,t),fe.init(e,t),e._zod.parse=(r,n)=>r,e._zod.check=(r)=>{let n=r.value,o=t.fn(n);if(o instanceof Promise)return o.then((i)=>Ey(i,r,n,e));Ey(o,r,n,e);return}});function Ey(e,t,r,n){if(!e){let o={code:"custom",input:r,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};if(n._zod.def.params)o.params=n._zod.def.params;t.issues.push(Yn(o))}}var wO=(e)=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":{if(Array.isArray(e))return"array";if(e===null)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},kO=()=>{let e={string:{unit:"characters",verb:"to have"},file:{unit:"bytes",verb:"to have"},array:{unit:"items",verb:"to have"},set:{unit:"items",verb:"to have"}};function t(n){return e[n]??null}let r={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return(n)=>{switch(n.code){case"invalid_type":return`Invalid input: expected ${n.expected}, received ${wO(n.input)}`;case"invalid_value":if(n.values.length===1)return`Invalid input: expected ${gl(n.values[0])}`;return`Invalid option: expected one of ${fl(n.values,"|")}`;case"too_big":{let o=n.inclusive?"<=":"<",i=t(n.origin);if(i)return`Too big: expected ${n.origin??"value"} to have ${o}${n.maximum.toString()} ${i.unit??"elements"}`;return`Too big: expected ${n.origin??"value"} to be ${o}${n.maximum.toString()}`}case"too_small":{let o=n.inclusive?">=":">",i=t(n.origin);if(i)return`Too small: expected ${n.origin} to have ${o}${n.minimum.toString()} ${i.unit}`;return`Too small: expected ${n.origin} to be ${o}${n.minimum.toString()}`}case"invalid_format":{let o=n;if(o.format==="starts_with")return`Invalid string: must start with "${o.prefix}"`;if(o.format==="ends_with")return`Invalid string: must end with "${o.suffix}"`;if(o.format==="includes")return`Invalid string: must include "${o.includes}"`;if(o.format==="regex")return`Invalid string: must match pattern ${o.pattern}`;return`Invalid ${r[o.format]??n.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${n.divisor}`;case"unrecognized_keys":return`Unrecognized key${n.keys.length>1?"s":""}: ${fl(n.keys,", ")}`;case"invalid_key":return`Invalid key in ${n.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${n.origin}`;default:return"Invalid input"}}};function xp(){return{localeError:kO()}}var SO=Symbol("ZodOutput"),$O=Symbol("ZodInput");class aa{constructor(){this._map=new Map,this._idmap=new Map}add(e,...t){let r=t[0];if(this._map.set(e,r),r&&typeof r==="object"&&"id"in r){if(this._idmap.has(r.id))throw Error(`ID ${r.id} already exists in the registry`);this._idmap.set(r.id,e)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(e){let t=this._map.get(e);if(t&&typeof t==="object"&&"id"in t)this._idmap.delete(t.id);return this._map.delete(e),this}get(e){let t=e._zod.parent;if(t){let r={...this.get(t)??{}};return delete r.id,{...r,...this._map.get(e)}}return this._map.get(e)}has(e){return this._map.has(e)}}function Cy(){return new aa}var Ar=Cy();function vp(e,t){return new e({type:"string",...D(t)})}function yp(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...D(t)})}function ca(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...D(t)})}function bp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...D(t)})}function _p(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...D(t)})}function wp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...D(t)})}function kp(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...D(t)})}function Sp(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...D(t)})}function $p(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...D(t)})}function Tp(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...D(t)})}function Ep(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...D(t)})}function Rp(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...D(t)})}function Pp(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...D(t)})}function zp(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...D(t)})}function Op(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...D(t)})}function Ap(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...D(t)})}function Cp(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...D(t)})}function Ip(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...D(t)})}function jp(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...D(t)})}function Np(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...D(t)})}function Dp(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...D(t)})}function Mp(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...D(t)})}function Lp(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...D(t)})}function Iy(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...D(t)})}function jy(e,t){return new e({type:"string",format:"date",check:"string_format",...D(t)})}function Ny(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...D(t)})}function Dy(e,t){return new e({type:"string",format:"duration",check:"string_format",...D(t)})}function qp(e,t){return new e({type:"number",checks:[],...D(t)})}function Up(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...D(t)})}function Fp(e,t){return new e({type:"boolean",...D(t)})}function Zp(e,t){return new e({type:"null",...D(t)})}function Bp(e){return new e({type:"unknown"})}function Hp(e,t){return new e({type:"never",...D(t)})}function ua(e,t){return new El({check:"less_than",...D(t),value:e,inclusive:!1})}function bi(e,t){return new El({check:"less_than",...D(t),value:e,inclusive:!0})}function la(e,t){return new Rl({check:"greater_than",...D(t),value:e,inclusive:!1})}function _i(e,t){return new Rl({check:"greater_than",...D(t),value:e,inclusive:!0})}function pa(e,t){return new iy({check:"multiple_of",...D(t),value:e})}function da(e,t){return new ay({check:"max_length",...D(t),maximum:e})}function Xn(e,t){return new cy({check:"min_length",...D(t),minimum:e})}function ma(e,t){return new uy({check:"length_equals",...D(t),length:e})}function Vp(e,t){return new ly({check:"string_format",format:"regex",...D(t),pattern:e})}function Gp(e){return new py({check:"string_format",format:"lowercase",...D(e)})}function Jp(e){return new dy({check:"string_format",format:"uppercase",...D(e)})}function Wp(e,t){return new my({check:"string_format",format:"includes",...D(t),includes:e})}function Kp(e,t){return new fy({check:"string_format",format:"starts_with",...D(t),prefix:e})}function Yp(e,t){return new hy({check:"string_format",format:"ends_with",...D(t),suffix:e})}function fn(e){return new gy({check:"overwrite",tx:e})}function Xp(e){return fn((t)=>t.normalize(e))}function Qp(){return fn((e)=>e.trim())}function ed(){return fn((e)=>e.toLowerCase())}function td(){return fn((e)=>e.toUpperCase())}function My(e,t,r){return new e({type:"array",element:t,...D(r)})}function rd(e,t,r){let n=D(r);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}function nd(e,t,r){return new e({type:"custom",check:"custom",fn:t,...D(r)})}class od{constructor(e){this.counter=0,this.metadataRegistry=e?.metadata??Ar,this.target=e?.target??"draft-2020-12",this.unrepresentable=e?.unrepresentable??"throw",this.override=e?.override??(()=>{}),this.io=e?.io??"output",this.seen=new Map}process(e,t={path:[],schemaPath:[]}){var r;let n=e._zod.def,o={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},i=this.seen.get(e);if(i){if(i.count++,t.schemaPath.includes(e))i.cycle=t.path;return i.schema}let s={schema:{},count:1,cycle:void 0,path:t.path};this.seen.set(e,s);let a=e._zod.toJSONSchema?.();if(a)s.schema=a;else{let l={...t,schemaPath:[...t.schemaPath,e],path:t.path},p=e._zod.parent;if(p)s.ref=p,this.process(p,l),this.seen.get(p).isParent=!0;else{let m=s.schema;switch(n.type){case"string":{let d=m;d.type="string";let{minimum:h,maximum:x,format:v,patterns:g,contentEncoding:y}=e._zod.bag;if(typeof h==="number")d.minLength=h;if(typeof x==="number")d.maxLength=x;if(v){if(d.format=o[v]??v,d.format==="")delete d.format}if(y)d.contentEncoding=y;if(g&&g.size>0){let w=[...g];if(w.length===1)d.pattern=w[0].source;else if(w.length>1)s.schema.allOf=[...w.map((P)=>({...this.target==="draft-7"?{type:"string"}:{},pattern:P.source}))]}break}case"number":{let d=m,{minimum:h,maximum:x,format:v,multipleOf:g,exclusiveMaximum:y,exclusiveMinimum:w}=e._zod.bag;if(typeof v==="string"&&v.includes("int"))d.type="integer";else d.type="number";if(typeof w==="number")d.exclusiveMinimum=w;if(typeof h==="number"){if(d.minimum=h,typeof w==="number")if(w>=h)delete d.minimum;else delete d.exclusiveMinimum}if(typeof y==="number")d.exclusiveMaximum=y;if(typeof x==="number"){if(d.maximum=x,typeof y==="number")if(y<=x)delete d.maximum;else delete d.exclusiveMaximum}if(typeof g==="number")d.multipleOf=g;break}case"boolean":{let d=m;d.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw Error("Symbols cannot be represented in JSON Schema");break}case"null":{m.type="null";break}case"any":break;case"unknown":break;case"undefined":{if(this.unrepresentable==="throw")throw Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw Error("Void cannot be represented in JSON Schema");break}case"never":{m.not={};break}case"date":{if(this.unrepresentable==="throw")throw Error("Date cannot be represented in JSON Schema");break}case"array":{let d=m,{minimum:h,maximum:x}=e._zod.bag;if(typeof h==="number")d.minItems=h;if(typeof x==="number")d.maxItems=x;d.type="array",d.items=this.process(n.element,{...l,path:[...l.path,"items"]});break}case"object":{let d=m;d.type="object",d.properties={};let h=n.shape;for(let g in h)d.properties[g]=this.process(h[g],{...l,path:[...l.path,"properties",g]});let x=new Set(Object.keys(h)),v=new Set([...x].filter((g)=>{let y=n.shape[g]._zod;if(this.io==="input")return y.optin===void 0;else return y.optout===void 0}));if(v.size>0)d.required=Array.from(v);if(n.catchall?._zod.def.type==="never")d.additionalProperties=!1;else if(!n.catchall){if(this.io==="output")d.additionalProperties=!1}else if(n.catchall)d.additionalProperties=this.process(n.catchall,{...l,path:[...l.path,"additionalProperties"]});break}case"union":{let d=m;d.anyOf=n.options.map((h,x)=>this.process(h,{...l,path:[...l.path,"anyOf",x]}));break}case"intersection":{let d=m,h=this.process(n.left,{...l,path:[...l.path,"allOf",0]}),x=this.process(n.right,{...l,path:[...l.path,"allOf",1]}),v=(y)=>("allOf"in y)&&Object.keys(y).length===1,g=[...v(h)?h.allOf:[h],...v(x)?x.allOf:[x]];d.allOf=g;break}case"tuple":{let d=m;d.type="array";let h=n.items.map((g,y)=>this.process(g,{...l,path:[...l.path,"prefixItems",y]}));if(this.target==="draft-2020-12")d.prefixItems=h;else d.items=h;if(n.rest){let g=this.process(n.rest,{...l,path:[...l.path,"items"]});if(this.target==="draft-2020-12")d.items=g;else d.additionalItems=g}if(n.rest)d.items=this.process(n.rest,{...l,path:[...l.path,"items"]});let{minimum:x,maximum:v}=e._zod.bag;if(typeof x==="number")d.minItems=x;if(typeof v==="number")d.maxItems=v;break}case"record":{let d=m;d.type="object",d.propertyNames=this.process(n.keyType,{...l,path:[...l.path,"propertyNames"]}),d.additionalProperties=this.process(n.valueType,{...l,path:[...l.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw Error("Set cannot be represented in JSON Schema");break}case"enum":{let d=m,h=Ks(n.entries);if(h.every((x)=>typeof x==="number"))d.type="number";if(h.every((x)=>typeof x==="string"))d.type="string";d.enum=h;break}case"literal":{let d=m,h=[];for(let x of n.values)if(x===void 0){if(this.unrepresentable==="throw")throw Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof x==="bigint")if(this.unrepresentable==="throw")throw Error("BigInt literals cannot be represented in JSON Schema");else h.push(Number(x));else h.push(x);if(h.length===0);else if(h.length===1){let x=h[0];d.type=x===null?"null":typeof x,d.const=x}else{if(h.every((x)=>typeof x==="number"))d.type="number";if(h.every((x)=>typeof x==="string"))d.type="string";if(h.every((x)=>typeof x==="boolean"))d.type="string";if(h.every((x)=>x===null))d.type="null";d.enum=h}break}case"file":{let d=m,h={type:"string",format:"binary",contentEncoding:"binary"},{minimum:x,maximum:v,mime:g}=e._zod.bag;if(x!==void 0)h.minLength=x;if(v!==void 0)h.maxLength=v;if(g)if(g.length===1)h.contentMediaType=g[0],Object.assign(d,h);else d.anyOf=g.map((y)=>({...h,contentMediaType:y}));else Object.assign(d,h);break}case"transform":{if(this.unrepresentable==="throw")throw Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let d=this.process(n.innerType,l);m.anyOf=[d,{type:"null"}];break}case"nonoptional":{this.process(n.innerType,l),s.ref=n.innerType;break}case"success":{let d=m;d.type="boolean";break}case"default":{this.process(n.innerType,l),s.ref=n.innerType,m.default=JSON.parse(JSON.stringify(n.defaultValue));break}case"prefault":{if(this.process(n.innerType,l),s.ref=n.innerType,this.io==="input")m._prefault=JSON.parse(JSON.stringify(n.defaultValue));break}case"catch":{this.process(n.innerType,l),s.ref=n.innerType;let d;try{d=n.catchValue(void 0)}catch{throw Error("Dynamic catch values are not supported in JSON Schema")}m.default=d;break}case"nan":{if(this.unrepresentable==="throw")throw Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let d=m,h=e._zod.pattern;if(!h)throw Error("Pattern not found in template literal");d.type="string",d.pattern=h.source;break}case"pipe":{let d=this.io==="input"?n.in._zod.def.type==="transform"?n.out:n.in:n.out;this.process(d,l),s.ref=d;break}case"readonly":{this.process(n.innerType,l),s.ref=n.innerType,m.readOnly=!0;break}case"promise":{this.process(n.innerType,l),s.ref=n.innerType;break}case"optional":{this.process(n.innerType,l),s.ref=n.innerType;break}case"lazy":{let d=e._zod.innerType;this.process(d,l),s.ref=d;break}case"custom":{if(this.unrepresentable==="throw")throw Error("Custom types cannot be represented in JSON Schema");break}default:}}}let c=this.metadataRegistry.get(e);if(c)Object.assign(s.schema,c);if(this.io==="input"&&Ze(e))delete s.schema.examples,delete s.schema.default;if(this.io==="input"&&s.schema._prefault)(r=s.schema).default??(r.default=s.schema._prefault);return delete s.schema._prefault,this.seen.get(e).schema}emit(e,t){let r={cycles:t?.cycles??"ref",reused:t?.reused??"inline",external:t?.external??void 0},n=this.seen.get(e);if(!n)throw Error("Unprocessed schema. This is a bug in Zod.");let o=(u)=>{let l=this.target==="draft-2020-12"?"$defs":"definitions";if(r.external){let h=r.external.registry.get(u[0])?.id,x=r.external.uri??((g)=>g);if(h)return{ref:x(h)};let v=u[1].defId??u[1].schema.id??`schema${this.counter++}`;return u[1].defId=v,{defId:v,ref:`${x("__shared")}#/${l}/${v}`}}if(u[1]===n)return{ref:"#"};let m=`${"#"}/${l}/`,d=u[1].schema.id??`__schema${this.counter++}`;return{defId:d,ref:m+d}},i=(u)=>{if(u[1].schema.$ref)return;let l=u[1],{ref:p,defId:m}=o(u);if(l.def={...l.schema},m)l.defId=m;let d=l.schema;for(let h in d)delete d[h];d.$ref=p};if(r.cycles==="throw")for(let u of this.seen.entries()){let l=u[1];if(l.cycle)throw Error(`Cycle detected: #/${l.cycle?.join("/")}/<root>
|
|
61
61
|
|
|
62
|
-
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let u of this.seen.entries()){let l=u[1];if(e===u[0]){i(u);continue}if(r.external){let m=r.external.registry.get(u[0])?.id;if(e!==u[0]&&m){i(u);continue}}if(this.metadataRegistry.get(u[0])?.id){i(u);continue}if(l.cycle){i(u);continue}if(l.count>1){if(r.reused==="ref"){i(u);continue}}}let s=(u,l)=>{let p=this.seen.get(u),m=p.def??p.schema,d={...m};if(p.ref===null)return;let h=p.ref;if(p.ref=null,h){s(h,l);let x=this.seen.get(h).schema;if(x.$ref&&l.target==="draft-7")m.allOf=m.allOf??[],m.allOf.push(x);else Object.assign(m,x),Object.assign(m,d)}if(!p.isParent)this.override({zodSchema:u,jsonSchema:m,path:p.path??[]})};for(let u of[...this.seen.entries()].reverse())s(u[0],{target:this.target});let a={};if(this.target==="draft-2020-12")a.$schema="https://json-schema.org/draft/2020-12/schema";else if(this.target==="draft-7")a.$schema="http://json-schema.org/draft-07/schema#";else console.warn(`Invalid target: ${this.target}`);if(r.external?.uri){let u=r.external.registry.get(e)?.id;if(!u)throw Error("Schema is missing an `id` property");a.$id=r.external.uri(u)}Object.assign(a,n.def);let c=r.external?.defs??{};for(let u of this.seen.entries()){let l=u[1];if(l.def&&l.defId)c[l.defId]=l.def}if(r.external);else if(Object.keys(c).length>0)if(this.target==="draft-2020-12")a.$defs=c;else a.definitions=c;try{return JSON.parse(JSON.stringify(a))}catch(u){throw Error("Error converting schema to JSON.")}}}function pd(e,t){if(e instanceof pa){let n=new ld(t),o={};for(let a of e._idmap.entries()){let[c,u]=a;n.process(u)}let i={},s={registry:e,uri:t?.uri,defs:o};for(let a of e._idmap.entries()){let[c,u]=a;i[c]=n.emit(u,{...t,external:s})}if(Object.keys(o).length>0){let a=n.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[a]:o}}return{schemas:i}}let r=new ld(t);return r.process(e),r.emit(e,t)}function Ue(e,t){let r=t??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let o=e._zod.def;switch(o.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return Ue(o.element,r);case"object":{for(let i in o.shape)if(Ue(o.shape[i],r))return!0;return!1}case"union":{for(let i of o.options)if(Ue(i,r))return!0;return!1}case"intersection":return Ue(o.left,r)||Ue(o.right,r);case"tuple":{for(let i of o.items)if(Ue(i,r))return!0;if(o.rest&&Ue(o.rest,r))return!0;return!1}case"record":return Ue(o.keyType,r)||Ue(o.valueType,r);case"map":return Ue(o.keyType,r)||Ue(o.valueType,r);case"set":return Ue(o.valueType,r);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return Ue(o.innerType,r);case"lazy":return Ue(o.getter(),r);case"default":return Ue(o.innerType,r);case"prefault":return Ue(o.innerType,r);case"custom":return!1;case"transform":return!0;case"pipe":return Ue(o.in,r)||Ue(o.out,r);case"success":return!1;case"catch":return!1;default:}throw Error(`Unknown schema type: ${o.type}`)}var b1=S("ZodMiniType",(e,t)=>{if(!e._zod)throw Error("Uninitialized schema in ZodMiniType.");fe.init(e,t),e.def=t,e.parse=(r,n)=>Tl(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>xn(e,r,n),e.parseAsync=async(r,n)=>Rl(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>vn(e,r,n),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map((n)=>typeof n==="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]}),e.clone=(r,n)=>$t(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e)});var _1=S("ZodMiniObject",(e,t)=>{ua.init(e,t),b1.init(e,t),re.defineLazy(e,"shape",()=>t.shape)});function dd(e,t){let r={type:"object",get shape(){return re.assignProp(this,"shape",{...e}),this.shape},...re.normalizeParams(t)};return new _1(r)}function At(e){return!!e._zod}function _n(e){let t=Object.values(e);if(t.length===0)return dd({});let r=t.every(At),n=t.every((o)=>!At(o));if(r)return dd(e);if(n)return ml(e);throw Error("Mixed Zod versions detected in object shape.")}function jr(e,t){if(At(e))return xn(e,t);return e.safeParse(t)}async function va(e,t){if(At(e))return await vn(e,t);return await e.safeParseAsync(t)}function Nr(e){if(!e)return;let t;if(At(e))t=e._zod?.def?.shape;else t=e.shape;if(!t)return;if(typeof t==="function")try{return t()}catch{return}return t}function po(e){if(!e)return;if(typeof e==="object"){let t=e,r=e;if(!t._def&&!r._zod){let n=Object.values(e);if(n.length>0&&n.every((o)=>typeof o==="object"&&o!==null&&(o._def!==void 0||o._zod!==void 0||typeof o.parse==="function")))return _n(e)}}if(At(e)){let r=e._zod?.def;if(r&&(r.type==="object"||r.shape!==void 0))return e}else if(e.shape!==void 0)return e;return}function ya(e){if(e&&typeof e==="object"){if("message"in e&&typeof e.message==="string")return e.message;if("issues"in e&&Array.isArray(e.issues)&&e.issues.length>0){let t=e.issues[0];if(t&&typeof t==="object"&&"message"in t)return String(t.message)}try{return JSON.stringify(e)}catch{return String(e)}}return String(e)}function rb(e){return e.description}function nb(e){if(At(e))return e._zod?.def?.type==="optional";let t=e;if(typeof e.isOptional==="function")return e.isOptional();return t._def?.typeName==="ZodOptional"}function ba(e){if(At(e)){let i=e._zod?.def;if(i){if(i.value!==void 0)return i.value;if(Array.isArray(i.values)&&i.values.length>0)return i.values[0]}}let r=e._def;if(r){if(r.value!==void 0)return r.value;if(Array.isArray(r.values)&&r.values.length>0)return r.values[0]}let n=e.value;if(n!==void 0)return n;return}var Pi={};No(Pi,{ZodISODate:()=>ib,ZodISODateTime:()=>ob,ZodISODuration:()=>ab,ZodISOTime:()=>sb,date:()=>fd,datetime:()=>md,duration:()=>gd,time:()=>hd});var ob=S("ZodISODateTime",(e,t)=>{By.init(e,t),Te.init(e,t)});function md(e){return Ky(ob,e)}var ib=S("ZodISODate",(e,t)=>{Hy.init(e,t),Te.init(e,t)});function fd(e){return Yy(ib,e)}var sb=S("ZodISOTime",(e,t)=>{Vy.init(e,t),Te.init(e,t)});function hd(e){return Xy(sb,e)}var ab=S("ZodISODuration",(e,t)=>{Gy.init(e,t),Te.init(e,t)});function gd(e){return Qy(ab,e)}var cb=(e,t)=>{ia.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:(r)=>Sl(e,r)},flatten:{value:(r)=>kl(e,r)},addIssue:{value:(r)=>e.issues.push(r)},addIssues:{value:(r)=>e.issues.push(...r)},isEmpty:{get(){return e.issues.length===0}}})},C5=S("ZodError",cb),zi=S("ZodError",cb,{Parent:Error});var ub=$l(zi),lb=El(zi),pb=Pl(zi),db=zl(zi);var Oe=S("ZodType",(e,t)=>(fe.init(e,t),e.def=t,Object.defineProperty(e,"_def",{value:t}),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map((n)=>typeof n==="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]}),e.clone=(r,n)=>$t(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e),e.parse=(r,n)=>ub(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>pb(e,r,n),e.parseAsync=async(r,n)=>lb(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>db(e,r,n),e.spa=e.safeParseAsync,e.refine=(r,n)=>e.check(vI(r,n)),e.superRefine=(r)=>e.check(yI(r)),e.overwrite=(r)=>e.check(yn(r)),e.optional=()=>Re(e),e.nullable=()=>hb(e),e.nullish=()=>Re(hb(e)),e.nonoptional=(r)=>pI(e,r),e.array=()=>ne(e),e.or=(r)=>Se([e,r]),e.and=(r)=>wa(e,r),e.transform=(r)=>vd(e,_b(r)),e.default=(r)=>cI(e,r),e.prefault=(r)=>lI(e,r),e.catch=(r)=>mI(e,r),e.pipe=(r)=>vd(e,r),e.readonly=()=>gI(e),e.describe=(r)=>{let n=e.clone();return Ir.add(n,{description:r}),n},Object.defineProperty(e,"description",{get(){return Ir.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return Ir.get(e);let n=e.clone();return Ir.add(n,r[0]),n},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),gb=S("_ZodString",(e,t)=>{Ti.init(e,t),Oe.init(e,t);let r=e._zod.bag;e.format=r.format??null,e.minLength=r.minimum??null,e.maxLength=r.maximum??null,e.regex=(...n)=>e.check(Xp(...n)),e.includes=(...n)=>e.check(td(...n)),e.startsWith=(...n)=>e.check(rd(...n)),e.endsWith=(...n)=>e.check(nd(...n)),e.min=(...n)=>e.check(lo(...n)),e.max=(...n)=>e.check(ga(...n)),e.length=(...n)=>e.check(xa(...n)),e.nonempty=(...n)=>e.check(lo(1,...n)),e.lowercase=(n)=>e.check(Qp(n)),e.uppercase=(n)=>e.check(ed(n)),e.trim=()=>e.check(id()),e.normalize=(...n)=>e.check(od(...n)),e.toLowerCase=()=>e.check(sd()),e.toUpperCase=()=>e.check(ad())}),z1=S("ZodString",(e,t)=>{Ti.init(e,t),gb.init(e,t),e.email=(r)=>e.check($p(O1,r)),e.url=(r)=>e.check(zp(A1,r)),e.jwt=(r)=>e.check(Hp(G1,r)),e.emoji=(r)=>e.check(Op(C1,r)),e.guid=(r)=>e.check(da(mb,r)),e.uuid=(r)=>e.check(Tp(_a,r)),e.uuidv4=(r)=>e.check(Ep(_a,r)),e.uuidv6=(r)=>e.check(Rp(_a,r)),e.uuidv7=(r)=>e.check(Pp(_a,r)),e.nanoid=(r)=>e.check(Ap(I1,r)),e.guid=(r)=>e.check(da(mb,r)),e.cuid=(r)=>e.check(Cp(j1,r)),e.cuid2=(r)=>e.check(Ip(N1,r)),e.ulid=(r)=>e.check(jp(D1,r)),e.base64=(r)=>e.check(Fp(B1,r)),e.base64url=(r)=>e.check(Zp(H1,r)),e.xid=(r)=>e.check(Np(L1,r)),e.ksuid=(r)=>e.check(Dp(M1,r)),e.ipv4=(r)=>e.check(Lp(q1,r)),e.ipv6=(r)=>e.check(Mp(U1,r)),e.cidrv4=(r)=>e.check(qp(F1,r)),e.cidrv6=(r)=>e.check(Up(Z1,r)),e.e164=(r)=>e.check(Bp(V1,r)),e.datetime=(r)=>e.check(md(r)),e.date=(r)=>e.check(fd(r)),e.time=(r)=>e.check(hd(r)),e.duration=(r)=>e.check(gd(r))});function w(e){return Sp(z1,e)}var Te=S("ZodStringFormat",(e,t)=>{_e.init(e,t),gb.init(e,t)}),O1=S("ZodEmail",(e,t)=>{Ml.init(e,t),Te.init(e,t)});var mb=S("ZodGUID",(e,t)=>{Dl.init(e,t),Te.init(e,t)});var _a=S("ZodUUID",(e,t)=>{Ll.init(e,t),Te.init(e,t)});var A1=S("ZodURL",(e,t)=>{ql.init(e,t),Te.init(e,t)});var C1=S("ZodEmoji",(e,t)=>{Ul.init(e,t),Te.init(e,t)});var I1=S("ZodNanoID",(e,t)=>{Fl.init(e,t),Te.init(e,t)});var j1=S("ZodCUID",(e,t)=>{Zl.init(e,t),Te.init(e,t)});var N1=S("ZodCUID2",(e,t)=>{Bl.init(e,t),Te.init(e,t)});var D1=S("ZodULID",(e,t)=>{Hl.init(e,t),Te.init(e,t)});var L1=S("ZodXID",(e,t)=>{Vl.init(e,t),Te.init(e,t)});var M1=S("ZodKSUID",(e,t)=>{Gl.init(e,t),Te.init(e,t)});var q1=S("ZodIPv4",(e,t)=>{Jl.init(e,t),Te.init(e,t)});var U1=S("ZodIPv6",(e,t)=>{Wl.init(e,t),Te.init(e,t)});var F1=S("ZodCIDRv4",(e,t)=>{Kl.init(e,t),Te.init(e,t)});var Z1=S("ZodCIDRv6",(e,t)=>{Yl.init(e,t),Te.init(e,t)});var B1=S("ZodBase64",(e,t)=>{Xl.init(e,t),Te.init(e,t)});var H1=S("ZodBase64URL",(e,t)=>{Ql.init(e,t),Te.init(e,t)});var V1=S("ZodE164",(e,t)=>{ep.init(e,t),Te.init(e,t)});var G1=S("ZodJWT",(e,t)=>{tp.init(e,t),Te.init(e,t)});var xb=S("ZodNumber",(e,t)=>{ca.init(e,t),Oe.init(e,t),e.gt=(n,o)=>e.check(fa(n,o)),e.gte=(n,o)=>e.check(Ri(n,o)),e.min=(n,o)=>e.check(Ri(n,o)),e.lt=(n,o)=>e.check(ma(n,o)),e.lte=(n,o)=>e.check(Ei(n,o)),e.max=(n,o)=>e.check(Ei(n,o)),e.int=(n)=>e.check(fb(n)),e.safe=(n)=>e.check(fb(n)),e.positive=(n)=>e.check(fa(0,n)),e.nonnegative=(n)=>e.check(Ri(0,n)),e.negative=(n)=>e.check(ma(0,n)),e.nonpositive=(n)=>e.check(Ei(0,n)),e.multipleOf=(n,o)=>e.check(ha(n,o)),e.step=(n,o)=>e.check(ha(n,o)),e.finite=()=>e;let r=e._zod.bag;e.minValue=Math.max(r.minimum??Number.NEGATIVE_INFINITY,r.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(r.maximum??Number.POSITIVE_INFINITY,r.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(r.format??"").includes("int")||Number.isSafeInteger(r.multipleOf??0.5),e.isFinite=!0,e.format=r.format??null});function le(e){return Vp(xb,e)}var J1=S("ZodNumberFormat",(e,t)=>{rp.init(e,t),xb.init(e,t)});function fb(e){return Gp(J1,e)}var W1=S("ZodBoolean",(e,t)=>{np.init(e,t),Oe.init(e,t)});function Ge(e){return Jp(W1,e)}var K1=S("ZodNull",(e,t)=>{op.init(e,t),Oe.init(e,t)});function vb(e){return Wp(K1,e)}var Y1=S("ZodUnknown",(e,t)=>{ip.init(e,t),Oe.init(e,t)});function Ee(){return Kp(Y1)}var X1=S("ZodNever",(e,t)=>{sp.init(e,t),Oe.init(e,t)});function Q1(e){return Yp(X1,e)}var eI=S("ZodArray",(e,t)=>{ap.init(e,t),Oe.init(e,t),e.element=t.element,e.min=(r,n)=>e.check(lo(r,n)),e.nonempty=(r)=>e.check(lo(1,r)),e.max=(r,n)=>e.check(ga(r,n)),e.length=(r,n)=>e.check(xa(r,n)),e.unwrap=()=>e.element});function ne(e,t){return eb(eI,e,t)}var yb=S("ZodObject",(e,t)=>{ua.init(e,t),Oe.init(e,t),re.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>ht(Object.keys(e._zod.def.shape)),e.catchall=(r)=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:Ee()}),e.loose=()=>e.clone({...e._zod.def,catchall:Ee()}),e.strict=()=>e.clone({...e._zod.def,catchall:Q1()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=(r)=>re.extend(e,r),e.merge=(r)=>re.merge(e,r),e.pick=(r)=>re.pick(e,r),e.omit=(r)=>re.omit(e,r),e.partial=(...r)=>re.partial(wb,e,r[0]),e.required=(...r)=>re.required(kb,e,r[0])});function j(e,t){let r={type:"object",get shape(){return re.assignProp(this,"shape",{...e}),this.shape},...re.normalizeParams(t)};return new yb(r)}function st(e,t){return new yb({type:"object",get shape(){return re.assignProp(this,"shape",{...e}),this.shape},catchall:Ee(),...re.normalizeParams(t)})}var bb=S("ZodUnion",(e,t)=>{la.init(e,t),Oe.init(e,t),e.options=t.options});function Se(e,t){return new bb({type:"union",options:e,...re.normalizeParams(t)})}var tI=S("ZodDiscriminatedUnion",(e,t)=>{bb.init(e,t),cp.init(e,t)});function yd(e,t,r){return new tI({type:"union",options:t,discriminator:e,...re.normalizeParams(r)})}var rI=S("ZodIntersection",(e,t)=>{up.init(e,t),Oe.init(e,t)});function wa(e,t){return new rI({type:"intersection",left:e,right:t})}var nI=S("ZodRecord",(e,t)=>{lp.init(e,t),Oe.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function we(e,t,r){return new nI({type:"record",keyType:e,valueType:t,...re.normalizeParams(r)})}var xd=S("ZodEnum",(e,t)=>{pp.init(e,t),Oe.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let r=new Set(Object.keys(t.entries));e.extract=(n,o)=>{let i={};for(let s of n)if(r.has(s))i[s]=t.entries[s];else throw Error(`Key ${s} not found in enum`);return new xd({...t,checks:[],...re.normalizeParams(o),entries:i})},e.exclude=(n,o)=>{let i={...t.entries};for(let s of n)if(r.has(s))delete i[s];else throw Error(`Key ${s} not found in enum`);return new xd({...t,checks:[],...re.normalizeParams(o),entries:i})}});function ht(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map((n)=>[n,n])):e;return new xd({type:"enum",entries:r,...re.normalizeParams(t)})}var oI=S("ZodLiteral",(e,t)=>{dp.init(e,t),Oe.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function L(e,t){return new oI({type:"literal",values:Array.isArray(e)?e:[e],...re.normalizeParams(t)})}var iI=S("ZodTransform",(e,t)=>{mp.init(e,t),Oe.init(e,t),e._zod.parse=(r,n)=>{r.addIssue=(i)=>{if(typeof i==="string")r.issues.push(re.issue(i,r.value,t));else{let s=i;if(s.fatal)s.continue=!1;s.code??(s.code="custom"),s.input??(s.input=r.value),s.inst??(s.inst=e),s.continue??(s.continue=!0),r.issues.push(re.issue(s))}};let o=t.transform(r.value,r);if(o instanceof Promise)return o.then((i)=>(r.value=i,r));return r.value=o,r}});function _b(e){return new iI({type:"transform",transform:e})}var wb=S("ZodOptional",(e,t)=>{fp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Re(e){return new wb({type:"optional",innerType:e})}var sI=S("ZodNullable",(e,t)=>{hp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType});function hb(e){return new sI({type:"nullable",innerType:e})}var aI=S("ZodDefault",(e,t)=>{gp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function cI(e,t){return new aI({type:"default",innerType:e,get defaultValue(){return typeof t==="function"?t():t}})}var uI=S("ZodPrefault",(e,t)=>{xp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType});function lI(e,t){return new uI({type:"prefault",innerType:e,get defaultValue(){return typeof t==="function"?t():t}})}var kb=S("ZodNonOptional",(e,t)=>{vp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType});function pI(e,t){return new kb({type:"nonoptional",innerType:e,...re.normalizeParams(t)})}var dI=S("ZodCatch",(e,t)=>{yp.init(e,t),Oe.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function mI(e,t){return new dI({type:"catch",innerType:e,catchValue:typeof t==="function"?t:()=>t})}var fI=S("ZodPipe",(e,t)=>{bp.init(e,t),Oe.init(e,t),e.in=t.in,e.out=t.out});function vd(e,t){return new fI({type:"pipe",in:e,out:t})}var hI=S("ZodReadonly",(e,t)=>{_p.init(e,t),Oe.init(e,t)});function gI(e){return new hI({type:"readonly",innerType:e})}var Sb=S("ZodCustom",(e,t)=>{wp.init(e,t),Oe.init(e,t)});function xI(e){let t=new Ye({check:"custom"});return t._zod.check=e,t}function $b(e,t){return cd(Sb,e??(()=>!0),t)}function vI(e,t={}){return ud(Sb,e,t)}function yI(e){let t=xI((r)=>(r.addIssue=(n)=>{if(typeof n==="string")r.issues.push(re.issue(n,r.value,t._zod.def));else{let o=n;if(o.fatal)o.continue=!1;o.code??(o.code="custom"),o.input??(o.input=r.value),o.inst??(o.inst=t),o.continue??(o.continue=!t._zod.def.abort),r.issues.push(re.issue(o))}},e(r.value,r)));return t}function bd(e,t){return vd(_b(e),t)}St(kp());var _d="2025-11-25";var Tb=[_d,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],Dr="io.modelcontextprotocol/related-task",Sa="2.0",Fe=$b((e)=>e!==null&&(typeof e==="object"||typeof e==="function")),Eb=Se([w(),le().int()]),Rb=w(),G5=st({ttl:le().optional(),pollInterval:le().optional()}),bI=j({ttl:le().optional()}),_I=j({taskId:w()}),wd=st({progressToken:Eb.optional(),[Dr]:_I.optional()}),Tt=j({_meta:wd.optional()}),Oi=Tt.extend({task:bI.optional()}),Pb=(e)=>Oi.safeParse(e).success,Xe=j({method:w(),params:Tt.loose().optional()}),Ct=j({_meta:wd.optional()}),It=j({method:w(),params:Ct.loose().optional()}),Qe=st({_meta:wd.optional()}),$a=Se([w(),le().int()]),zb=j({jsonrpc:L(Sa),id:$a,...Xe.shape}).strict(),kd=(e)=>zb.safeParse(e).success,Ob=j({jsonrpc:L(Sa),...It.shape}).strict(),Ab=(e)=>Ob.safeParse(e).success,Sd=j({jsonrpc:L(Sa),id:$a,result:Qe}).strict(),Ai=(e)=>Sd.safeParse(e).success;var q;(function(e){e[e.ConnectionClosed=-32000]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(q||(q={}));var $d=j({jsonrpc:L(Sa),id:$a.optional(),error:j({code:le().int(),message:w(),data:Ee().optional()})}).strict();var Cb=(e)=>$d.safeParse(e).success;var Ib=Se([zb,Ob,Sd,$d]),J5=Se([Sd,$d]),Ta=Qe.strict(),wI=Ct.extend({requestId:$a.optional(),reason:w().optional()}),Ea=It.extend({method:L("notifications/cancelled"),params:wI}),kI=j({src:w(),mimeType:w().optional(),sizes:ne(w()).optional(),theme:ht(["light","dark"]).optional()}),Ci=j({icons:ne(kI).optional()}),mo=j({name:w(),title:w().optional()}),jb=mo.extend({...mo.shape,...Ci.shape,version:w(),websiteUrl:w().optional(),description:w().optional()}),SI=wa(j({applyDefaults:Ge().optional()}),we(w(),Ee())),$I=bd((e)=>{if(e&&typeof e==="object"&&!Array.isArray(e)){if(Object.keys(e).length===0)return{form:{}}}return e},wa(j({form:SI.optional(),url:Fe.optional()}),we(w(),Ee()).optional())),TI=st({list:Fe.optional(),cancel:Fe.optional(),requests:st({sampling:st({createMessage:Fe.optional()}).optional(),elicitation:st({create:Fe.optional()}).optional()}).optional()}),EI=st({list:Fe.optional(),cancel:Fe.optional(),requests:st({tools:st({call:Fe.optional()}).optional()}).optional()}),RI=j({experimental:we(w(),Fe).optional(),sampling:j({context:Fe.optional(),tools:Fe.optional()}).optional(),elicitation:$I.optional(),roots:j({listChanged:Ge().optional()}).optional(),tasks:TI.optional(),extensions:we(w(),Fe).optional()}),PI=Tt.extend({protocolVersion:w(),capabilities:RI,clientInfo:jb}),Td=Xe.extend({method:L("initialize"),params:PI});var zI=j({experimental:we(w(),Fe).optional(),logging:Fe.optional(),completions:Fe.optional(),prompts:j({listChanged:Ge().optional()}).optional(),resources:j({subscribe:Ge().optional(),listChanged:Ge().optional()}).optional(),tools:j({listChanged:Ge().optional()}).optional(),tasks:EI.optional(),extensions:we(w(),Fe).optional()}),OI=Qe.extend({protocolVersion:w(),capabilities:zI,serverInfo:jb,instructions:w().optional()}),Ed=It.extend({method:L("notifications/initialized"),params:Ct.optional()});var Ra=Xe.extend({method:L("ping"),params:Tt.optional()}),AI=j({progress:le(),total:Re(le()),message:Re(w())}),CI=j({...Ct.shape,...AI.shape,progressToken:Eb}),Pa=It.extend({method:L("notifications/progress"),params:CI}),II=Tt.extend({cursor:Rb.optional()}),Ii=Xe.extend({params:II.optional()}),ji=Qe.extend({nextCursor:Rb.optional()}),jI=ht(["working","input_required","completed","failed","cancelled"]),Ni=j({taskId:w(),status:jI,ttl:Se([le(),vb()]),createdAt:w(),lastUpdatedAt:w(),pollInterval:Re(le()),statusMessage:Re(w())}),fo=Qe.extend({task:Ni}),NI=Ct.merge(Ni),Di=It.extend({method:L("notifications/tasks/status"),params:NI}),za=Xe.extend({method:L("tasks/get"),params:Tt.extend({taskId:w()})}),Oa=Qe.merge(Ni),Aa=Xe.extend({method:L("tasks/result"),params:Tt.extend({taskId:w()})}),W5=Qe.loose(),Ca=Ii.extend({method:L("tasks/list")}),Ia=ji.extend({tasks:ne(Ni)}),ja=Xe.extend({method:L("tasks/cancel"),params:Tt.extend({taskId:w()})}),Nb=Qe.merge(Ni),Db=j({uri:w(),mimeType:Re(w()),_meta:we(w(),Ee()).optional()}),Lb=Db.extend({text:w()}),Rd=w().refine((e)=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),Mb=Db.extend({blob:Rd}),Li=ht(["user","assistant"]),ho=j({audience:ne(Li).optional(),priority:le().min(0).max(1).optional(),lastModified:Pi.datetime({offset:!0}).optional()}),qb=j({...mo.shape,...Ci.shape,uri:w(),description:Re(w()),mimeType:Re(w()),size:Re(le()),annotations:ho.optional(),_meta:Re(st({}))}),DI=j({...mo.shape,...Ci.shape,uriTemplate:w(),description:Re(w()),mimeType:Re(w()),annotations:ho.optional(),_meta:Re(st({}))}),Na=Ii.extend({method:L("resources/list")}),LI=ji.extend({resources:ne(qb)}),Da=Ii.extend({method:L("resources/templates/list")}),MI=ji.extend({resourceTemplates:ne(DI)}),Pd=Tt.extend({uri:w()}),qI=Pd,La=Xe.extend({method:L("resources/read"),params:qI}),UI=Qe.extend({contents:ne(Se([Lb,Mb]))}),FI=It.extend({method:L("notifications/resources/list_changed"),params:Ct.optional()}),ZI=Pd,BI=Xe.extend({method:L("resources/subscribe"),params:ZI}),HI=Pd,VI=Xe.extend({method:L("resources/unsubscribe"),params:HI}),GI=Ct.extend({uri:w()}),JI=It.extend({method:L("notifications/resources/updated"),params:GI}),WI=j({name:w(),description:Re(w()),required:Re(Ge())}),KI=j({...mo.shape,...Ci.shape,description:Re(w()),arguments:Re(ne(WI)),_meta:Re(st({}))}),Ma=Ii.extend({method:L("prompts/list")}),YI=ji.extend({prompts:ne(KI)}),XI=Tt.extend({name:w(),arguments:we(w(),w()).optional()}),qa=Xe.extend({method:L("prompts/get"),params:XI}),zd=j({type:L("text"),text:w(),annotations:ho.optional(),_meta:we(w(),Ee()).optional()}),Od=j({type:L("image"),data:Rd,mimeType:w(),annotations:ho.optional(),_meta:we(w(),Ee()).optional()}),Ad=j({type:L("audio"),data:Rd,mimeType:w(),annotations:ho.optional(),_meta:we(w(),Ee()).optional()}),QI=j({type:L("tool_use"),name:w(),id:w(),input:we(w(),Ee()),_meta:we(w(),Ee()).optional()}),ej=j({type:L("resource"),resource:Se([Lb,Mb]),annotations:ho.optional(),_meta:we(w(),Ee()).optional()}),tj=qb.extend({type:L("resource_link")}),Cd=Se([zd,Od,Ad,tj,ej]),rj=j({role:Li,content:Cd}),nj=Qe.extend({description:w().optional(),messages:ne(rj)}),oj=It.extend({method:L("notifications/prompts/list_changed"),params:Ct.optional()}),ij=j({title:w().optional(),readOnlyHint:Ge().optional(),destructiveHint:Ge().optional(),idempotentHint:Ge().optional(),openWorldHint:Ge().optional()}),sj=j({taskSupport:ht(["required","optional","forbidden"]).optional()}),Ub=j({...mo.shape,...Ci.shape,description:w().optional(),inputSchema:j({type:L("object"),properties:we(w(),Fe).optional(),required:ne(w()).optional()}).catchall(Ee()),outputSchema:j({type:L("object"),properties:we(w(),Fe).optional(),required:ne(w()).optional()}).catchall(Ee()).optional(),annotations:ij.optional(),execution:sj.optional(),_meta:we(w(),Ee()).optional()}),Ua=Ii.extend({method:L("tools/list")}),aj=ji.extend({tools:ne(Ub)}),Fa=Qe.extend({content:ne(Cd).default([]),structuredContent:we(w(),Ee()).optional(),isError:Ge().optional()}),K5=Fa.or(Qe.extend({toolResult:Ee()})),cj=Oi.extend({name:w(),arguments:we(w(),Ee()).optional()}),go=Xe.extend({method:L("tools/call"),params:cj}),uj=It.extend({method:L("notifications/tools/list_changed"),params:Ct.optional()}),Y5=j({autoRefresh:Ge().default(!0),debounceMs:le().int().nonnegative().default(300)}),Mi=ht(["debug","info","notice","warning","error","critical","alert","emergency"]),lj=Tt.extend({level:Mi}),Id=Xe.extend({method:L("logging/setLevel"),params:lj}),pj=Ct.extend({level:Mi,logger:w().optional(),data:Ee()}),dj=It.extend({method:L("notifications/message"),params:pj}),mj=j({name:w().optional()}),fj=j({hints:ne(mj).optional(),costPriority:le().min(0).max(1).optional(),speedPriority:le().min(0).max(1).optional(),intelligencePriority:le().min(0).max(1).optional()}),hj=j({mode:ht(["auto","required","none"]).optional()}),gj=j({type:L("tool_result"),toolUseId:w().describe("The unique identifier for the corresponding tool call."),content:ne(Cd).default([]),structuredContent:j({}).loose().optional(),isError:Ge().optional(),_meta:we(w(),Ee()).optional()}),xj=yd("type",[zd,Od,Ad]),ka=yd("type",[zd,Od,Ad,QI,gj]),vj=j({role:Li,content:Se([ka,ne(ka)]),_meta:we(w(),Ee()).optional()}),yj=Oi.extend({messages:ne(vj),modelPreferences:fj.optional(),systemPrompt:w().optional(),includeContext:ht(["none","thisServer","allServers"]).optional(),temperature:le().optional(),maxTokens:le().int(),stopSequences:ne(w()).optional(),metadata:Fe.optional(),tools:ne(Ub).optional(),toolChoice:hj.optional()}),bj=Xe.extend({method:L("sampling/createMessage"),params:yj}),qi=Qe.extend({model:w(),stopReason:Re(ht(["endTurn","stopSequence","maxTokens"]).or(w())),role:Li,content:xj}),jd=Qe.extend({model:w(),stopReason:Re(ht(["endTurn","stopSequence","maxTokens","toolUse"]).or(w())),role:Li,content:Se([ka,ne(ka)])}),_j=j({type:L("boolean"),title:w().optional(),description:w().optional(),default:Ge().optional()}),wj=j({type:L("string"),title:w().optional(),description:w().optional(),minLength:le().optional(),maxLength:le().optional(),format:ht(["email","uri","date","date-time"]).optional(),default:w().optional()}),kj=j({type:ht(["number","integer"]),title:w().optional(),description:w().optional(),minimum:le().optional(),maximum:le().optional(),default:le().optional()}),Sj=j({type:L("string"),title:w().optional(),description:w().optional(),enum:ne(w()),default:w().optional()}),$j=j({type:L("string"),title:w().optional(),description:w().optional(),oneOf:ne(j({const:w(),title:w()})),default:w().optional()}),Tj=j({type:L("string"),title:w().optional(),description:w().optional(),enum:ne(w()),enumNames:ne(w()).optional(),default:w().optional()}),Ej=Se([Sj,$j]),Rj=j({type:L("array"),title:w().optional(),description:w().optional(),minItems:le().optional(),maxItems:le().optional(),items:j({type:L("string"),enum:ne(w())}),default:ne(w()).optional()}),Pj=j({type:L("array"),title:w().optional(),description:w().optional(),minItems:le().optional(),maxItems:le().optional(),items:j({anyOf:ne(j({const:w(),title:w()}))}),default:ne(w()).optional()}),zj=Se([Rj,Pj]),Oj=Se([Tj,Ej,zj]),Aj=Se([Oj,_j,wj,kj]),Cj=Oi.extend({mode:L("form").optional(),message:w(),requestedSchema:j({type:L("object"),properties:we(w(),Aj),required:ne(w()).optional()})}),Ij=Oi.extend({mode:L("url"),message:w(),elicitationId:w(),url:w().url()}),jj=Se([Cj,Ij]),Nj=Xe.extend({method:L("elicitation/create"),params:jj}),Dj=Ct.extend({elicitationId:w()}),Lj=It.extend({method:L("notifications/elicitation/complete"),params:Dj}),xo=Qe.extend({action:ht(["accept","decline","cancel"]),content:bd((e)=>e===null?void 0:e,we(w(),Se([w(),le(),Ge(),ne(w())])).optional())}),Mj=j({type:L("ref/resource"),uri:w()});var qj=j({type:L("ref/prompt"),name:w()}),Uj=Tt.extend({ref:Se([qj,Mj]),argument:j({name:w(),value:w()}),context:j({arguments:we(w(),w()).optional()}).optional()}),Za=Xe.extend({method:L("completion/complete"),params:Uj});function Fb(e){if(e.params.ref.type!=="ref/prompt")throw TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function Zb(e){if(e.params.ref.type!=="ref/resource")throw TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var Fj=Qe.extend({completion:st({values:ne(w()).max(100),total:Re(le().int()),hasMore:Re(Ge())})}),Zj=j({uri:w().startsWith("file://"),name:w().optional(),_meta:we(w(),Ee()).optional()}),Bj=Xe.extend({method:L("roots/list"),params:Tt.optional()}),Nd=Qe.extend({roots:ne(Zj)}),Hj=It.extend({method:L("notifications/roots/list_changed"),params:Ct.optional()}),X5=Se([Ra,Td,Za,Id,qa,Ma,Na,Da,La,BI,VI,go,Ua,za,Aa,Ca,ja]),Q5=Se([Ea,Pa,Ed,Hj,Di]),e8=Se([Ta,qi,jd,xo,Nd,Oa,Ia,fo]),t8=Se([Ra,bj,Nj,Bj,za,Aa,Ca,ja]),r8=Se([Ea,Pa,dj,JI,FI,uj,oj,Di,Lj]),n8=Se([Ta,OI,Fj,nj,YI,LI,MI,UI,Fa,aj,Oa,Ia,fo]);class D extends Error{constructor(e,t,r){super(`MCP error ${e}: ${t}`);this.code=e,this.data=r,this.name="McpError"}static fromError(e,t,r){if(e===q.UrlElicitationRequired&&r){let n=r;if(n.elicitations)return new Bb(n.elicitations,t)}return new D(e,t,r)}}class Bb extends D{constructor(e,t=`URL elicitation${e.length>1?"s":""} required`){super(q.UrlElicitationRequired,t,{elicitations:e})}get elicitations(){return this.data?.elicitations??[]}}function Lr(e){return e==="completed"||e==="failed"||e==="cancelled"}var Vb=Symbol("Let zodToJsonSchema decide on which parser to use");var Hb={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},Gb=(e)=>typeof e==="string"?{...Hb,name:e}:{...Hb,...e};var Jb=(e)=>{let t=Gb(e),r=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:r,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([n,o])=>[o._def,{def:o._def,path:[...t.basePath,t.definitionPath,n],jsonSchema:void 0}]))}};function Dd(e,t,r,n){if(!n?.errorMessages)return;if(r)e.errorMessage={...e.errorMessage,[t]:r}}function oe(e,t,r,n,o){e[t]=r,Dd(e,t,n,o)}var Ba=(e,t)=>{let r=0;for(;r<e.length&&r<t.length;r++)if(e[r]!==t[r])break;return[(e.length-r).toString(),...t.slice(r)].join("/")};function Pe(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?Ba(t,e.currentPath):t.join("/")}}function Wb(e,t){let r={type:"array"};if(e.type?._def&&e.type?._def?.typeName!==P.ZodAny)r.items=Z(e.type._def,{...t,currentPath:[...t.currentPath,"items"]});if(e.minLength)oe(r,"minItems",e.minLength.value,e.minLength.message,t);if(e.maxLength)oe(r,"maxItems",e.maxLength.value,e.maxLength.message,t);if(e.exactLength)oe(r,"minItems",e.exactLength.value,e.exactLength.message,t),oe(r,"maxItems",e.exactLength.value,e.exactLength.message,t);return r}function Kb(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"min":if(t.target==="jsonSchema7")if(n.inclusive)oe(r,"minimum",n.value,n.message,t);else oe(r,"exclusiveMinimum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMinimum=!0;oe(r,"minimum",n.value,n.message,t)}break;case"max":if(t.target==="jsonSchema7")if(n.inclusive)oe(r,"maximum",n.value,n.message,t);else oe(r,"exclusiveMaximum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMaximum=!0;oe(r,"maximum",n.value,n.message,t)}break;case"multipleOf":oe(r,"multipleOf",n.value,n.message,t);break}return r}function Yb(){return{type:"boolean"}}function Ha(e,t){return Z(e.type._def,t)}var Xb=(e,t)=>Z(e.innerType._def,t);function Ld(e,t,r){let n=r??t.dateStrategy;if(Array.isArray(n))return{anyOf:n.map((o,i)=>Ld(e,t,o))};switch(n){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return Vj(e,t)}}var Vj=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let n of e.checks)switch(n.kind){case"min":oe(r,"minimum",n.value,n.message,t);break;case"max":oe(r,"maximum",n.value,n.message,t);break}return r};function Qb(e,t){return{...Z(e.innerType._def,t),default:e.defaultValue()}}function e_(e,t){return t.effectStrategy==="input"?Z(e.schema._def,t):Pe(t)}function t_(e){return{type:"string",enum:Array.from(e.values)}}var Gj=(e)=>{if("type"in e&&e.type==="string")return!1;return"allOf"in e};function r_(e,t){let r=[Z(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),Z(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter((i)=>!!i),n=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,o=[];return r.forEach((i)=>{if(Gj(i)){if(o.push(...i.allOf),i.unevaluatedProperties===void 0)n=void 0}else{let s=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:a,...c}=i;s=c}else n=void 0;o.push(s)}}),o.length?{allOf:o,...n}:void 0}function n_(e,t){let r=typeof e.value;if(r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string")return{type:Array.isArray(e.value)?"array":"object"};if(t.target==="openApi3")return{type:r==="bigint"?"integer":r,enum:[e.value]};return{type:r==="bigint"?"integer":r,const:e.value}}var Md=void 0,Gt={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>{if(Md===void 0)Md=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u");return Md},uuid:/^[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}$/,ipv4:/^(?:(?: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])$/,ipv4Cidr:/^(?:(?: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])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([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])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function Va(e,t){let r={type:"string"};if(e.checks)for(let n of e.checks)switch(n.kind){case"min":oe(r,"minLength",typeof r.minLength==="number"?Math.max(r.minLength,n.value):n.value,n.message,t);break;case"max":oe(r,"maxLength",typeof r.maxLength==="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Jt(r,"email",n.message,t);break;case"format:idn-email":Jt(r,"idn-email",n.message,t);break;case"pattern:zod":at(r,Gt.email,n.message,t);break}break;case"url":Jt(r,"uri",n.message,t);break;case"uuid":Jt(r,"uuid",n.message,t);break;case"regex":at(r,n.regex,n.message,t);break;case"cuid":at(r,Gt.cuid,n.message,t);break;case"cuid2":at(r,Gt.cuid2,n.message,t);break;case"startsWith":at(r,RegExp(`^${qd(n.value,t)}`),n.message,t);break;case"endsWith":at(r,RegExp(`${qd(n.value,t)}$`),n.message,t);break;case"datetime":Jt(r,"date-time",n.message,t);break;case"date":Jt(r,"date",n.message,t);break;case"time":Jt(r,"time",n.message,t);break;case"duration":Jt(r,"duration",n.message,t);break;case"length":oe(r,"minLength",typeof r.minLength==="number"?Math.max(r.minLength,n.value):n.value,n.message,t),oe(r,"maxLength",typeof r.maxLength==="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"includes":{at(r,RegExp(qd(n.value,t)),n.message,t);break}case"ip":{if(n.version!=="v6")Jt(r,"ipv4",n.message,t);if(n.version!=="v4")Jt(r,"ipv6",n.message,t);break}case"base64url":at(r,Gt.base64url,n.message,t);break;case"jwt":at(r,Gt.jwt,n.message,t);break;case"cidr":{if(n.version!=="v6")at(r,Gt.ipv4Cidr,n.message,t);if(n.version!=="v4")at(r,Gt.ipv6Cidr,n.message,t);break}case"emoji":at(r,Gt.emoji(),n.message,t);break;case"ulid":{at(r,Gt.ulid,n.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Jt(r,"binary",n.message,t);break}case"contentEncoding:base64":{oe(r,"contentEncoding","base64",n.message,t);break}case"pattern:zod":{at(r,Gt.base64,n.message,t);break}}break}case"nanoid":at(r,Gt.nanoid,n.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:((o)=>{})(n)}return r}function qd(e,t){return t.patternStrategy==="escape"?Wj(e):e}var Jj=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function Wj(e){let t="";for(let r=0;r<e.length;r++){if(!Jj.has(e[r]))t+="\\";t+=e[r]}return t}function Jt(e,t,r,n){if(e.format||e.anyOf?.some((o)=>o.format)){if(!e.anyOf)e.anyOf=[];if(e.format){if(e.anyOf.push({format:e.format,...e.errorMessage&&n.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage){if(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0)delete e.errorMessage}}e.anyOf.push({format:t,...r&&n.errorMessages&&{errorMessage:{format:r}}})}else oe(e,"format",t,r,n)}function at(e,t,r,n){if(e.pattern||e.allOf?.some((o)=>o.pattern)){if(!e.allOf)e.allOf=[];if(e.pattern){if(e.allOf.push({pattern:e.pattern,...e.errorMessage&&n.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage){if(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0)delete e.errorMessage}}e.allOf.push({pattern:o_(t,n),...r&&n.errorMessages&&{errorMessage:{pattern:r}}})}else oe(e,"pattern",o_(t,n),r,n)}function o_(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let r={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},n=r.i?e.source.toLowerCase():e.source,o="",i=!1,s=!1,a=!1;for(let c=0;c<n.length;c++){if(i){o+=n[c],i=!1;continue}if(r.i){if(s){if(n[c].match(/[a-z]/)){if(a)o+=n[c],o+=`${n[c-2]}-${n[c]}`.toUpperCase(),a=!1;else if(n[c+1]==="-"&&n[c+2]?.match(/[a-z]/))o+=n[c],a=!0;else o+=`${n[c]}${n[c].toUpperCase()}`;continue}}else if(n[c].match(/[a-z]/)){o+=`[${n[c]}${n[c].toUpperCase()}]`;continue}}if(r.m){if(n[c]==="^"){o+=`(^|(?<=[\r
|
|
62
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let u of this.seen.entries()){let l=u[1];if(e===u[0]){i(u);continue}if(r.external){let m=r.external.registry.get(u[0])?.id;if(e!==u[0]&&m){i(u);continue}}if(this.metadataRegistry.get(u[0])?.id){i(u);continue}if(l.cycle){i(u);continue}if(l.count>1){if(r.reused==="ref"){i(u);continue}}}let s=(u,l)=>{let p=this.seen.get(u),m=p.def??p.schema,d={...m};if(p.ref===null)return;let h=p.ref;if(p.ref=null,h){s(h,l);let x=this.seen.get(h).schema;if(x.$ref&&l.target==="draft-7")m.allOf=m.allOf??[],m.allOf.push(x);else Object.assign(m,x),Object.assign(m,d)}if(!p.isParent)this.override({zodSchema:u,jsonSchema:m,path:p.path??[]})};for(let u of[...this.seen.entries()].reverse())s(u[0],{target:this.target});let a={};if(this.target==="draft-2020-12")a.$schema="https://json-schema.org/draft/2020-12/schema";else if(this.target==="draft-7")a.$schema="http://json-schema.org/draft-07/schema#";else console.warn(`Invalid target: ${this.target}`);if(r.external?.uri){let u=r.external.registry.get(e)?.id;if(!u)throw Error("Schema is missing an `id` property");a.$id=r.external.uri(u)}Object.assign(a,n.def);let c=r.external?.defs??{};for(let u of this.seen.entries()){let l=u[1];if(l.def&&l.defId)c[l.defId]=l.def}if(r.external);else if(Object.keys(c).length>0)if(this.target==="draft-2020-12")a.$defs=c;else a.definitions=c;try{return JSON.parse(JSON.stringify(a))}catch(u){throw Error("Error converting schema to JSON.")}}}function id(e,t){if(e instanceof aa){let n=new od(t),o={};for(let a of e._idmap.entries()){let[c,u]=a;n.process(u)}let i={},s={registry:e,uri:t?.uri,defs:o};for(let a of e._idmap.entries()){let[c,u]=a;i[c]=n.emit(u,{...t,external:s})}if(Object.keys(o).length>0){let a=n.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[a]:o}}return{schemas:i}}let r=new od(t);return r.process(e),r.emit(e,t)}function Ze(e,t){let r=t??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let o=e._zod.def;switch(o.type){case"string":case"number":case"bigint":case"boolean":case"date":case"symbol":case"undefined":case"null":case"any":case"unknown":case"never":case"void":case"literal":case"enum":case"nan":case"file":case"template_literal":return!1;case"array":return Ze(o.element,r);case"object":{for(let i in o.shape)if(Ze(o.shape[i],r))return!0;return!1}case"union":{for(let i of o.options)if(Ze(i,r))return!0;return!1}case"intersection":return Ze(o.left,r)||Ze(o.right,r);case"tuple":{for(let i of o.items)if(Ze(i,r))return!0;if(o.rest&&Ze(o.rest,r))return!0;return!1}case"record":return Ze(o.keyType,r)||Ze(o.valueType,r);case"map":return Ze(o.keyType,r)||Ze(o.valueType,r);case"set":return Ze(o.valueType,r);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return Ze(o.innerType,r);case"lazy":return Ze(o.getter(),r);case"default":return Ze(o.innerType,r);case"prefault":return Ze(o.innerType,r);case"custom":return!1;case"transform":return!0;case"pipe":return Ze(o.in,r)||Ze(o.out,r);case"success":return!1;case"catch":return!1;default:}throw Error(`Unknown schema type: ${o.type}`)}var sA=k("ZodMiniType",(e,t)=>{if(!e._zod)throw Error("Uninitialized schema in ZodMiniType.");fe.init(e,t),e.def=t,e.parse=(r,n)=>bl(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>dn(e,r,n),e.parseAsync=async(r,n)=>wl(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>mn(e,r,n),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map((n)=>typeof n==="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]}),e.clone=(r,n)=>jt(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e)});var aA=k("ZodMiniObject",(e,t)=>{ia.init(e,t),sA.init(e,t),xe(e,"shape",()=>t.shape)});function sd(e,t){let r={type:"object",get shape(){return hi(this,"shape",{...e}),this.shape},...D(t)};return new aA(r)}function Nt(e){return!!e._zod}function gn(e){let t=Object.values(e);if(t.length===0)return sd({});let r=t.every(Nt),n=t.every((o)=>!Nt(o));if(r)return sd(e);if(n)return je(e);throw Error("Mixed Zod versions detected in object shape.")}function Cr(e,t){if(Nt(e))return dn(e,t);return e.safeParse(t)}async function fa(e,t){if(Nt(e))return await mn(e,t);return await e.safeParseAsync(t)}function Ir(e){if(!e)return;let t;if(Nt(e))t=e._zod?.def?.shape;else t=e.shape;if(!t)return;if(typeof t==="function")try{return t()}catch{return}return t}function Qn(e){if(!e)return;if(typeof e==="object"){let t=e,r=e;if(!t._def&&!r._zod){let n=Object.values(e);if(n.length>0&&n.every((o)=>typeof o==="object"&&o!==null&&(o._def!==void 0||o._zod!==void 0||typeof o.parse==="function")))return gn(e)}}if(Nt(e)){let r=e._zod?.def;if(r&&(r.type==="object"||r.shape!==void 0))return e}else if(e.shape!==void 0)return e;return}function ha(e){if(e&&typeof e==="object"){if("message"in e&&typeof e.message==="string")return e.message;if("issues"in e&&Array.isArray(e.issues)&&e.issues.length>0){let t=e.issues[0];if(t&&typeof t==="object"&&"message"in t)return String(t.message)}try{return JSON.stringify(e)}catch{return String(e)}}return String(e)}function qy(e){return e.description}function Uy(e){if(Nt(e))return e._zod?.def?.type==="optional";let t=e;if(typeof e.isOptional==="function")return e.isOptional();return t._def?.typeName==="ZodOptional"}function ga(e){if(Nt(e)){let i=e._zod?.def;if(i){if(i.value!==void 0)return i.value;if(Array.isArray(i.values)&&i.values.length>0)return i.values[0]}}let r=e._def;if(r){if(r.value!==void 0)return r.value;if(Array.isArray(r.values)&&r.values.length>0)return r.values[0]}let n=e.value;if(n!==void 0)return n;return}var fA=k("ZodISODateTime",(e,t)=>{Ry.init(e,t),Te.init(e,t)});function ad(e){return Iy(fA,e)}var hA=k("ZodISODate",(e,t)=>{Py.init(e,t),Te.init(e,t)});function Fy(e){return jy(hA,e)}var gA=k("ZodISOTime",(e,t)=>{zy.init(e,t),Te.init(e,t)});function Zy(e){return Ny(gA,e)}var xA=k("ZodISODuration",(e,t)=>{Oy.init(e,t),Te.init(e,t)});function By(e){return Dy(xA,e)}var Hy=(e,t)=>{ta.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:(r)=>vl(e,r)},flatten:{value:(r)=>xl(e,r)},addIssue:{value:(r)=>e.issues.push(r)},addIssues:{value:(r)=>e.issues.push(...r)},isEmpty:{get(){return e.issues.length===0}}})},m5=k("ZodError",Hy),wi=k("ZodError",Hy,{Parent:Error});var Vy=yl(wi),Gy=_l(wi),Jy=kl(wi),Wy=Sl(wi);var ze=k("ZodType",(e,t)=>(fe.init(e,t),e.def=t,Object.defineProperty(e,"_def",{value:t}),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map((n)=>typeof n==="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]}),e.clone=(r,n)=>jt(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e),e.parse=(r,n)=>Vy(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>Jy(e,r,n),e.parseAsync=async(r,n)=>Gy(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>Wy(e,r,n),e.spa=e.safeParseAsync,e.refine=(r,n)=>e.check(cC(r,n)),e.superRefine=(r)=>e.check(uC(r)),e.overwrite=(r)=>e.check(fn(r)),e.optional=()=>Re(e),e.nullable=()=>Xy(e),e.nullish=()=>Re(Xy(e)),e.nonoptional=(r)=>tC(e,r),e.array=()=>re(e),e.or=(r)=>Se([e,r]),e.and=(r)=>va(e,r),e.transform=(r)=>ld(e,ob(r)),e.default=(r)=>XA(e,r),e.prefault=(r)=>eC(e,r),e.catch=(r)=>nC(e,r),e.pipe=(r)=>ld(e,r),e.readonly=()=>sC(e),e.describe=(r)=>{let n=e.clone();return Ar.add(n,{description:r}),n},Object.defineProperty(e,"description",{get(){return Ar.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return Ar.get(e);let n=e.clone();return Ar.add(n,r[0]),n},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Qy=k("_ZodString",(e,t)=>{yi.init(e,t),ze.init(e,t);let r=e._zod.bag;e.format=r.format??null,e.minLength=r.minimum??null,e.maxLength=r.maximum??null,e.regex=(...n)=>e.check(Vp(...n)),e.includes=(...n)=>e.check(Wp(...n)),e.startsWith=(...n)=>e.check(Kp(...n)),e.endsWith=(...n)=>e.check(Yp(...n)),e.min=(...n)=>e.check(Xn(...n)),e.max=(...n)=>e.check(da(...n)),e.length=(...n)=>e.check(ma(...n)),e.nonempty=(...n)=>e.check(Xn(1,...n)),e.lowercase=(n)=>e.check(Gp(n)),e.uppercase=(n)=>e.check(Jp(n)),e.trim=()=>e.check(Qp()),e.normalize=(...n)=>e.check(Xp(...n)),e.toLowerCase=()=>e.check(ed()),e.toUpperCase=()=>e.check(td())}),bA=k("ZodString",(e,t)=>{yi.init(e,t),Qy.init(e,t),e.email=(r)=>e.check(yp(_A,r)),e.url=(r)=>e.check(Sp(wA,r)),e.jwt=(r)=>e.check(Lp(DA,r)),e.emoji=(r)=>e.check($p(kA,r)),e.guid=(r)=>e.check(ca(Ky,r)),e.uuid=(r)=>e.check(bp(xa,r)),e.uuidv4=(r)=>e.check(_p(xa,r)),e.uuidv6=(r)=>e.check(wp(xa,r)),e.uuidv7=(r)=>e.check(kp(xa,r)),e.nanoid=(r)=>e.check(Tp(SA,r)),e.guid=(r)=>e.check(ca(Ky,r)),e.cuid=(r)=>e.check(Ep($A,r)),e.cuid2=(r)=>e.check(Rp(TA,r)),e.ulid=(r)=>e.check(Pp(EA,r)),e.base64=(r)=>e.check(Np(IA,r)),e.base64url=(r)=>e.check(Dp(jA,r)),e.xid=(r)=>e.check(zp(RA,r)),e.ksuid=(r)=>e.check(Op(PA,r)),e.ipv4=(r)=>e.check(Ap(zA,r)),e.ipv6=(r)=>e.check(Cp(OA,r)),e.cidrv4=(r)=>e.check(Ip(AA,r)),e.cidrv6=(r)=>e.check(jp(CA,r)),e.e164=(r)=>e.check(Mp(NA,r)),e.datetime=(r)=>e.check(ad(r)),e.date=(r)=>e.check(Fy(r)),e.time=(r)=>e.check(Zy(r)),e.duration=(r)=>e.check(By(r))});function _(e){return vp(bA,e)}var Te=k("ZodStringFormat",(e,t)=>{_e.init(e,t),Qy.init(e,t)}),_A=k("ZodEmail",(e,t)=>{Cl.init(e,t),Te.init(e,t)});var Ky=k("ZodGUID",(e,t)=>{Ol.init(e,t),Te.init(e,t)});var xa=k("ZodUUID",(e,t)=>{Al.init(e,t),Te.init(e,t)});var wA=k("ZodURL",(e,t)=>{Il.init(e,t),Te.init(e,t)});var kA=k("ZodEmoji",(e,t)=>{jl.init(e,t),Te.init(e,t)});var SA=k("ZodNanoID",(e,t)=>{Nl.init(e,t),Te.init(e,t)});var $A=k("ZodCUID",(e,t)=>{Dl.init(e,t),Te.init(e,t)});var TA=k("ZodCUID2",(e,t)=>{Ml.init(e,t),Te.init(e,t)});var EA=k("ZodULID",(e,t)=>{Ll.init(e,t),Te.init(e,t)});var RA=k("ZodXID",(e,t)=>{ql.init(e,t),Te.init(e,t)});var PA=k("ZodKSUID",(e,t)=>{Ul.init(e,t),Te.init(e,t)});var zA=k("ZodIPv4",(e,t)=>{Fl.init(e,t),Te.init(e,t)});var OA=k("ZodIPv6",(e,t)=>{Zl.init(e,t),Te.init(e,t)});var AA=k("ZodCIDRv4",(e,t)=>{Bl.init(e,t),Te.init(e,t)});var CA=k("ZodCIDRv6",(e,t)=>{Hl.init(e,t),Te.init(e,t)});var IA=k("ZodBase64",(e,t)=>{Vl.init(e,t),Te.init(e,t)});var jA=k("ZodBase64URL",(e,t)=>{Gl.init(e,t),Te.init(e,t)});var NA=k("ZodE164",(e,t)=>{Jl.init(e,t),Te.init(e,t)});var DA=k("ZodJWT",(e,t)=>{Wl.init(e,t),Te.init(e,t)});var eb=k("ZodNumber",(e,t)=>{oa.init(e,t),ze.init(e,t),e.gt=(n,o)=>e.check(la(n,o)),e.gte=(n,o)=>e.check(_i(n,o)),e.min=(n,o)=>e.check(_i(n,o)),e.lt=(n,o)=>e.check(ua(n,o)),e.lte=(n,o)=>e.check(bi(n,o)),e.max=(n,o)=>e.check(bi(n,o)),e.int=(n)=>e.check(Yy(n)),e.safe=(n)=>e.check(Yy(n)),e.positive=(n)=>e.check(la(0,n)),e.nonnegative=(n)=>e.check(_i(0,n)),e.negative=(n)=>e.check(ua(0,n)),e.nonpositive=(n)=>e.check(bi(0,n)),e.multipleOf=(n,o)=>e.check(pa(n,o)),e.step=(n,o)=>e.check(pa(n,o)),e.finite=()=>e;let r=e._zod.bag;e.minValue=Math.max(r.minimum??Number.NEGATIVE_INFINITY,r.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(r.maximum??Number.POSITIVE_INFINITY,r.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(r.format??"").includes("int")||Number.isSafeInteger(r.multipleOf??0.5),e.isFinite=!0,e.format=r.format??null});function le(e){return qp(eb,e)}var MA=k("ZodNumberFormat",(e,t)=>{Kl.init(e,t),eb.init(e,t)});function Yy(e){return Up(MA,e)}var LA=k("ZodBoolean",(e,t)=>{Yl.init(e,t),ze.init(e,t)});function We(e){return Fp(LA,e)}var qA=k("ZodNull",(e,t)=>{Xl.init(e,t),ze.init(e,t)});function tb(e){return Zp(qA,e)}var UA=k("ZodUnknown",(e,t)=>{Ql.init(e,t),ze.init(e,t)});function Ee(){return Bp(UA)}var FA=k("ZodNever",(e,t)=>{ep.init(e,t),ze.init(e,t)});function ZA(e){return Hp(FA,e)}var BA=k("ZodArray",(e,t)=>{tp.init(e,t),ze.init(e,t),e.element=t.element,e.min=(r,n)=>e.check(Xn(r,n)),e.nonempty=(r)=>e.check(Xn(1,r)),e.max=(r,n)=>e.check(da(r,n)),e.length=(r,n)=>e.check(ma(r,n)),e.unwrap=()=>e.element});function re(e,t){return My(BA,e,t)}var rb=k("ZodObject",(e,t)=>{ia.init(e,t),ze.init(e,t),xe(e,"shape",()=>t.shape),e.keyof=()=>gt(Object.keys(e._zod.def.shape)),e.catchall=(r)=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:Ee()}),e.loose=()=>e.clone({...e._zod.def,catchall:Ee()}),e.strict=()=>e.clone({...e._zod.def,catchall:ZA()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=(r)=>hO(e,r),e.merge=(r)=>gO(e,r),e.pick=(r)=>mO(e,r),e.omit=(r)=>fO(e,r),e.partial=(...r)=>xO(ib,e,r[0]),e.required=(...r)=>vO(sb,e,r[0])});function j(e,t){let r={type:"object",get shape(){return hi(this,"shape",{...e}),this.shape},...D(t)};return new rb(r)}function ct(e,t){return new rb({type:"object",get shape(){return hi(this,"shape",{...e}),this.shape},catchall:Ee(),...D(t)})}var nb=k("ZodUnion",(e,t)=>{sa.init(e,t),ze.init(e,t),e.options=t.options});function Se(e,t){return new nb({type:"union",options:e,...D(t)})}var HA=k("ZodDiscriminatedUnion",(e,t)=>{nb.init(e,t),rp.init(e,t)});function pd(e,t,r){return new HA({type:"union",options:t,discriminator:e,...D(r)})}var VA=k("ZodIntersection",(e,t)=>{np.init(e,t),ze.init(e,t)});function va(e,t){return new VA({type:"intersection",left:e,right:t})}var GA=k("ZodRecord",(e,t)=>{op.init(e,t),ze.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function we(e,t,r){return new GA({type:"record",keyType:e,valueType:t,...D(r)})}var ud=k("ZodEnum",(e,t)=>{ip.init(e,t),ze.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let r=new Set(Object.keys(t.entries));e.extract=(n,o)=>{let i={};for(let s of n)if(r.has(s))i[s]=t.entries[s];else throw Error(`Key ${s} not found in enum`);return new ud({...t,checks:[],...D(o),entries:i})},e.exclude=(n,o)=>{let i={...t.entries};for(let s of n)if(r.has(s))delete i[s];else throw Error(`Key ${s} not found in enum`);return new ud({...t,checks:[],...D(o),entries:i})}});function gt(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map((n)=>[n,n])):e;return new ud({type:"enum",entries:r,...D(t)})}var JA=k("ZodLiteral",(e,t)=>{sp.init(e,t),ze.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function L(e,t){return new JA({type:"literal",values:Array.isArray(e)?e:[e],...D(t)})}var WA=k("ZodTransform",(e,t)=>{ap.init(e,t),ze.init(e,t),e._zod.parse=(r,n)=>{r.addIssue=(i)=>{if(typeof i==="string")r.issues.push(Yn(i,r.value,t));else{let s=i;if(s.fatal)s.continue=!1;s.code??(s.code="custom"),s.input??(s.input=r.value),s.inst??(s.inst=e),s.continue??(s.continue=!0),r.issues.push(Yn(s))}};let o=t.transform(r.value,r);if(o instanceof Promise)return o.then((i)=>(r.value=i,r));return r.value=o,r}});function ob(e){return new WA({type:"transform",transform:e})}var ib=k("ZodOptional",(e,t)=>{cp.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Re(e){return new ib({type:"optional",innerType:e})}var KA=k("ZodNullable",(e,t)=>{up.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Xy(e){return new KA({type:"nullable",innerType:e})}var YA=k("ZodDefault",(e,t)=>{lp.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function XA(e,t){return new YA({type:"default",innerType:e,get defaultValue(){return typeof t==="function"?t():t}})}var QA=k("ZodPrefault",(e,t)=>{pp.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType});function eC(e,t){return new QA({type:"prefault",innerType:e,get defaultValue(){return typeof t==="function"?t():t}})}var sb=k("ZodNonOptional",(e,t)=>{dp.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType});function tC(e,t){return new sb({type:"nonoptional",innerType:e,...D(t)})}var rC=k("ZodCatch",(e,t)=>{mp.init(e,t),ze.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function nC(e,t){return new rC({type:"catch",innerType:e,catchValue:typeof t==="function"?t:()=>t})}var oC=k("ZodPipe",(e,t)=>{fp.init(e,t),ze.init(e,t),e.in=t.in,e.out=t.out});function ld(e,t){return new oC({type:"pipe",in:e,out:t})}var iC=k("ZodReadonly",(e,t)=>{hp.init(e,t),ze.init(e,t)});function sC(e){return new iC({type:"readonly",innerType:e})}var ab=k("ZodCustom",(e,t)=>{gp.init(e,t),ze.init(e,t)});function aC(e){let t=new Xe({check:"custom"});return t._zod.check=e,t}function cb(e,t){return rd(ab,e??(()=>!0),t)}function cC(e,t={}){return nd(ab,e,t)}function uC(e){let t=aC((r)=>(r.addIssue=(n)=>{if(typeof n==="string")r.issues.push(Yn(n,r.value,t._zod.def));else{let o=n;if(o.fatal)o.continue=!1;o.code??(o.code="custom"),o.input??(o.input=r.value),o.inst??(o.inst=t),o.continue??(o.continue=!t._zod.def.abort),r.issues.push(Yn(o))}},e(r.value,r)));return t}function dd(e,t){return ld(ob(e),t)}Tt(xp());var md="2025-11-25";var ub=[md,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],jr="io.modelcontextprotocol/related-task",ba="2.0",Be=cb((e)=>e!==null&&(typeof e==="object"||typeof e==="function")),lb=Se([_(),le().int()]),pb=_(),E5=ct({ttl:le().optional(),pollInterval:le().optional()}),lC=j({ttl:le().optional()}),pC=j({taskId:_()}),fd=ct({progressToken:lb.optional(),[jr]:pC.optional()}),Et=j({_meta:fd.optional()}),ki=Et.extend({task:lC.optional()}),db=(e)=>ki.safeParse(e).success,Qe=j({method:_(),params:Et.loose().optional()}),Dt=j({_meta:fd.optional()}),Mt=j({method:_(),params:Dt.loose().optional()}),et=ct({_meta:fd.optional()}),_a=Se([_(),le().int()]),mb=j({jsonrpc:L(ba),id:_a,...Qe.shape}).strict(),hd=(e)=>mb.safeParse(e).success,fb=j({jsonrpc:L(ba),...Mt.shape}).strict(),hb=(e)=>fb.safeParse(e).success,gd=j({jsonrpc:L(ba),id:_a,result:et}).strict(),Si=(e)=>gd.safeParse(e).success;var U;(function(e){e[e.ConnectionClosed=-32000]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(U||(U={}));var xd=j({jsonrpc:L(ba),id:_a.optional(),error:j({code:le().int(),message:_(),data:Ee().optional()})}).strict();var gb=(e)=>xd.safeParse(e).success;var xb=Se([mb,fb,gd,xd]),R5=Se([gd,xd]),wa=et.strict(),dC=Dt.extend({requestId:_a.optional(),reason:_().optional()}),ka=Mt.extend({method:L("notifications/cancelled"),params:dC}),mC=j({src:_(),mimeType:_().optional(),sizes:re(_()).optional(),theme:gt(["light","dark"]).optional()}),$i=j({icons:re(mC).optional()}),eo=j({name:_(),title:_().optional()}),vb=eo.extend({...eo.shape,...$i.shape,version:_(),websiteUrl:_().optional(),description:_().optional()}),fC=va(j({applyDefaults:We().optional()}),we(_(),Ee())),hC=dd((e)=>{if(e&&typeof e==="object"&&!Array.isArray(e)){if(Object.keys(e).length===0)return{form:{}}}return e},va(j({form:fC.optional(),url:Be.optional()}),we(_(),Ee()).optional())),gC=ct({list:Be.optional(),cancel:Be.optional(),requests:ct({sampling:ct({createMessage:Be.optional()}).optional(),elicitation:ct({create:Be.optional()}).optional()}).optional()}),xC=ct({list:Be.optional(),cancel:Be.optional(),requests:ct({tools:ct({call:Be.optional()}).optional()}).optional()}),vC=j({experimental:we(_(),Be).optional(),sampling:j({context:Be.optional(),tools:Be.optional()}).optional(),elicitation:hC.optional(),roots:j({listChanged:We().optional()}).optional(),tasks:gC.optional(),extensions:we(_(),Be).optional()}),yC=Et.extend({protocolVersion:_(),capabilities:vC,clientInfo:vb}),vd=Qe.extend({method:L("initialize"),params:yC});var bC=j({experimental:we(_(),Be).optional(),logging:Be.optional(),completions:Be.optional(),prompts:j({listChanged:We().optional()}).optional(),resources:j({subscribe:We().optional(),listChanged:We().optional()}).optional(),tools:j({listChanged:We().optional()}).optional(),tasks:xC.optional(),extensions:we(_(),Be).optional()}),_C=et.extend({protocolVersion:_(),capabilities:bC,serverInfo:vb,instructions:_().optional()}),yd=Mt.extend({method:L("notifications/initialized"),params:Dt.optional()});var Sa=Qe.extend({method:L("ping"),params:Et.optional()}),wC=j({progress:le(),total:Re(le()),message:Re(_())}),kC=j({...Dt.shape,...wC.shape,progressToken:lb}),$a=Mt.extend({method:L("notifications/progress"),params:kC}),SC=Et.extend({cursor:pb.optional()}),Ti=Qe.extend({params:SC.optional()}),Ei=et.extend({nextCursor:pb.optional()}),$C=gt(["working","input_required","completed","failed","cancelled"]),Ri=j({taskId:_(),status:$C,ttl:Se([le(),tb()]),createdAt:_(),lastUpdatedAt:_(),pollInterval:Re(le()),statusMessage:Re(_())}),to=et.extend({task:Ri}),TC=Dt.merge(Ri),Pi=Mt.extend({method:L("notifications/tasks/status"),params:TC}),Ta=Qe.extend({method:L("tasks/get"),params:Et.extend({taskId:_()})}),Ea=et.merge(Ri),Ra=Qe.extend({method:L("tasks/result"),params:Et.extend({taskId:_()})}),P5=et.loose(),Pa=Ti.extend({method:L("tasks/list")}),za=Ei.extend({tasks:re(Ri)}),Oa=Qe.extend({method:L("tasks/cancel"),params:Et.extend({taskId:_()})}),yb=et.merge(Ri),bb=j({uri:_(),mimeType:Re(_()),_meta:we(_(),Ee()).optional()}),_b=bb.extend({text:_()}),bd=_().refine((e)=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),wb=bb.extend({blob:bd}),zi=gt(["user","assistant"]),ro=j({audience:re(zi).optional(),priority:le().min(0).max(1).optional(),lastModified:ad({offset:!0}).optional()}),kb=j({...eo.shape,...$i.shape,uri:_(),description:Re(_()),mimeType:Re(_()),size:Re(le()),annotations:ro.optional(),_meta:Re(ct({}))}),EC=j({...eo.shape,...$i.shape,uriTemplate:_(),description:Re(_()),mimeType:Re(_()),annotations:ro.optional(),_meta:Re(ct({}))}),Aa=Ti.extend({method:L("resources/list")}),RC=Ei.extend({resources:re(kb)}),Ca=Ti.extend({method:L("resources/templates/list")}),PC=Ei.extend({resourceTemplates:re(EC)}),_d=Et.extend({uri:_()}),zC=_d,Ia=Qe.extend({method:L("resources/read"),params:zC}),OC=et.extend({contents:re(Se([_b,wb]))}),AC=Mt.extend({method:L("notifications/resources/list_changed"),params:Dt.optional()}),CC=_d,IC=Qe.extend({method:L("resources/subscribe"),params:CC}),jC=_d,NC=Qe.extend({method:L("resources/unsubscribe"),params:jC}),DC=Dt.extend({uri:_()}),MC=Mt.extend({method:L("notifications/resources/updated"),params:DC}),LC=j({name:_(),description:Re(_()),required:Re(We())}),qC=j({...eo.shape,...$i.shape,description:Re(_()),arguments:Re(re(LC)),_meta:Re(ct({}))}),ja=Ti.extend({method:L("prompts/list")}),UC=Ei.extend({prompts:re(qC)}),FC=Et.extend({name:_(),arguments:we(_(),_()).optional()}),Na=Qe.extend({method:L("prompts/get"),params:FC}),wd=j({type:L("text"),text:_(),annotations:ro.optional(),_meta:we(_(),Ee()).optional()}),kd=j({type:L("image"),data:bd,mimeType:_(),annotations:ro.optional(),_meta:we(_(),Ee()).optional()}),Sd=j({type:L("audio"),data:bd,mimeType:_(),annotations:ro.optional(),_meta:we(_(),Ee()).optional()}),ZC=j({type:L("tool_use"),name:_(),id:_(),input:we(_(),Ee()),_meta:we(_(),Ee()).optional()}),BC=j({type:L("resource"),resource:Se([_b,wb]),annotations:ro.optional(),_meta:we(_(),Ee()).optional()}),HC=kb.extend({type:L("resource_link")}),$d=Se([wd,kd,Sd,HC,BC]),VC=j({role:zi,content:$d}),GC=et.extend({description:_().optional(),messages:re(VC)}),JC=Mt.extend({method:L("notifications/prompts/list_changed"),params:Dt.optional()}),WC=j({title:_().optional(),readOnlyHint:We().optional(),destructiveHint:We().optional(),idempotentHint:We().optional(),openWorldHint:We().optional()}),KC=j({taskSupport:gt(["required","optional","forbidden"]).optional()}),Sb=j({...eo.shape,...$i.shape,description:_().optional(),inputSchema:j({type:L("object"),properties:we(_(),Be).optional(),required:re(_()).optional()}).catchall(Ee()),outputSchema:j({type:L("object"),properties:we(_(),Be).optional(),required:re(_()).optional()}).catchall(Ee()).optional(),annotations:WC.optional(),execution:KC.optional(),_meta:we(_(),Ee()).optional()}),Da=Ti.extend({method:L("tools/list")}),YC=Ei.extend({tools:re(Sb)}),Ma=et.extend({content:re($d).default([]),structuredContent:we(_(),Ee()).optional(),isError:We().optional()}),z5=Ma.or(et.extend({toolResult:Ee()})),XC=ki.extend({name:_(),arguments:we(_(),Ee()).optional()}),no=Qe.extend({method:L("tools/call"),params:XC}),QC=Mt.extend({method:L("notifications/tools/list_changed"),params:Dt.optional()}),O5=j({autoRefresh:We().default(!0),debounceMs:le().int().nonnegative().default(300)}),Oi=gt(["debug","info","notice","warning","error","critical","alert","emergency"]),eI=Et.extend({level:Oi}),Td=Qe.extend({method:L("logging/setLevel"),params:eI}),tI=Dt.extend({level:Oi,logger:_().optional(),data:Ee()}),rI=Mt.extend({method:L("notifications/message"),params:tI}),nI=j({name:_().optional()}),oI=j({hints:re(nI).optional(),costPriority:le().min(0).max(1).optional(),speedPriority:le().min(0).max(1).optional(),intelligencePriority:le().min(0).max(1).optional()}),iI=j({mode:gt(["auto","required","none"]).optional()}),sI=j({type:L("tool_result"),toolUseId:_().describe("The unique identifier for the corresponding tool call."),content:re($d).default([]),structuredContent:j({}).loose().optional(),isError:We().optional(),_meta:we(_(),Ee()).optional()}),aI=pd("type",[wd,kd,Sd]),ya=pd("type",[wd,kd,Sd,ZC,sI]),cI=j({role:zi,content:Se([ya,re(ya)]),_meta:we(_(),Ee()).optional()}),uI=ki.extend({messages:re(cI),modelPreferences:oI.optional(),systemPrompt:_().optional(),includeContext:gt(["none","thisServer","allServers"]).optional(),temperature:le().optional(),maxTokens:le().int(),stopSequences:re(_()).optional(),metadata:Be.optional(),tools:re(Sb).optional(),toolChoice:iI.optional()}),lI=Qe.extend({method:L("sampling/createMessage"),params:uI}),Ai=et.extend({model:_(),stopReason:Re(gt(["endTurn","stopSequence","maxTokens"]).or(_())),role:zi,content:aI}),Ed=et.extend({model:_(),stopReason:Re(gt(["endTurn","stopSequence","maxTokens","toolUse"]).or(_())),role:zi,content:Se([ya,re(ya)])}),pI=j({type:L("boolean"),title:_().optional(),description:_().optional(),default:We().optional()}),dI=j({type:L("string"),title:_().optional(),description:_().optional(),minLength:le().optional(),maxLength:le().optional(),format:gt(["email","uri","date","date-time"]).optional(),default:_().optional()}),mI=j({type:gt(["number","integer"]),title:_().optional(),description:_().optional(),minimum:le().optional(),maximum:le().optional(),default:le().optional()}),fI=j({type:L("string"),title:_().optional(),description:_().optional(),enum:re(_()),default:_().optional()}),hI=j({type:L("string"),title:_().optional(),description:_().optional(),oneOf:re(j({const:_(),title:_()})),default:_().optional()}),gI=j({type:L("string"),title:_().optional(),description:_().optional(),enum:re(_()),enumNames:re(_()).optional(),default:_().optional()}),xI=Se([fI,hI]),vI=j({type:L("array"),title:_().optional(),description:_().optional(),minItems:le().optional(),maxItems:le().optional(),items:j({type:L("string"),enum:re(_())}),default:re(_()).optional()}),yI=j({type:L("array"),title:_().optional(),description:_().optional(),minItems:le().optional(),maxItems:le().optional(),items:j({anyOf:re(j({const:_(),title:_()}))}),default:re(_()).optional()}),bI=Se([vI,yI]),_I=Se([gI,xI,bI]),wI=Se([_I,pI,dI,mI]),kI=ki.extend({mode:L("form").optional(),message:_(),requestedSchema:j({type:L("object"),properties:we(_(),wI),required:re(_()).optional()})}),SI=ki.extend({mode:L("url"),message:_(),elicitationId:_(),url:_().url()}),$I=Se([kI,SI]),TI=Qe.extend({method:L("elicitation/create"),params:$I}),EI=Dt.extend({elicitationId:_()}),RI=Mt.extend({method:L("notifications/elicitation/complete"),params:EI}),oo=et.extend({action:gt(["accept","decline","cancel"]),content:dd((e)=>e===null?void 0:e,we(_(),Se([_(),le(),We(),re(_())])).optional())}),PI=j({type:L("ref/resource"),uri:_()});var zI=j({type:L("ref/prompt"),name:_()}),OI=Et.extend({ref:Se([zI,PI]),argument:j({name:_(),value:_()}),context:j({arguments:we(_(),_()).optional()}).optional()}),La=Qe.extend({method:L("completion/complete"),params:OI});function $b(e){if(e.params.ref.type!=="ref/prompt")throw TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function Tb(e){if(e.params.ref.type!=="ref/resource")throw TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var AI=et.extend({completion:ct({values:re(_()).max(100),total:Re(le().int()),hasMore:Re(We())})}),CI=j({uri:_().startsWith("file://"),name:_().optional(),_meta:we(_(),Ee()).optional()}),II=Qe.extend({method:L("roots/list"),params:Et.optional()}),Rd=et.extend({roots:re(CI)}),jI=Mt.extend({method:L("notifications/roots/list_changed"),params:Dt.optional()}),A5=Se([Sa,vd,La,Td,Na,ja,Aa,Ca,Ia,IC,NC,no,Da,Ta,Ra,Pa,Oa]),C5=Se([ka,$a,yd,jI,Pi]),I5=Se([wa,Ai,Ed,oo,Rd,Ea,za,to]),j5=Se([Sa,lI,TI,II,Ta,Ra,Pa,Oa]),N5=Se([ka,$a,rI,MC,AC,QC,JC,Pi,RI]),D5=Se([wa,_C,AI,GC,UC,RC,PC,OC,Ma,YC,Ea,za,to]);class M extends Error{constructor(e,t,r){super(`MCP error ${e}: ${t}`);this.code=e,this.data=r,this.name="McpError"}static fromError(e,t,r){if(e===U.UrlElicitationRequired&&r){let n=r;if(n.elicitations)return new Eb(n.elicitations,t)}return new M(e,t,r)}}class Eb extends M{constructor(e,t=`URL elicitation${e.length>1?"s":""} required`){super(U.UrlElicitationRequired,t,{elicitations:e})}get elicitations(){return this.data?.elicitations??[]}}function Nr(e){return e==="completed"||e==="failed"||e==="cancelled"}var Pb=Symbol("Let zodToJsonSchema decide on which parser to use");var Rb={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},zb=(e)=>typeof e==="string"?{...Rb,name:e}:{...Rb,...e};var Ob=(e)=>{let t=zb(e),r=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:r,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([n,o])=>[o._def,{def:o._def,path:[...t.basePath,t.definitionPath,n],jsonSchema:void 0}]))}};function Pd(e,t,r,n){if(!n?.errorMessages)return;if(r)e.errorMessage={...e.errorMessage,[t]:r}}function ne(e,t,r,n,o){e[t]=r,Pd(e,t,n,o)}var qa=(e,t)=>{let r=0;for(;r<e.length&&r<t.length;r++)if(e[r]!==t[r])break;return[(e.length-r).toString(),...t.slice(r)].join("/")};function Pe(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?qa(t,e.currentPath):t.join("/")}}function Ab(e,t){let r={type:"array"};if(e.type?._def&&e.type?._def?.typeName!==z.ZodAny)r.items=Z(e.type._def,{...t,currentPath:[...t.currentPath,"items"]});if(e.minLength)ne(r,"minItems",e.minLength.value,e.minLength.message,t);if(e.maxLength)ne(r,"maxItems",e.maxLength.value,e.maxLength.message,t);if(e.exactLength)ne(r,"minItems",e.exactLength.value,e.exactLength.message,t),ne(r,"maxItems",e.exactLength.value,e.exactLength.message,t);return r}function Cb(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"min":if(t.target==="jsonSchema7")if(n.inclusive)ne(r,"minimum",n.value,n.message,t);else ne(r,"exclusiveMinimum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMinimum=!0;ne(r,"minimum",n.value,n.message,t)}break;case"max":if(t.target==="jsonSchema7")if(n.inclusive)ne(r,"maximum",n.value,n.message,t);else ne(r,"exclusiveMaximum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMaximum=!0;ne(r,"maximum",n.value,n.message,t)}break;case"multipleOf":ne(r,"multipleOf",n.value,n.message,t);break}return r}function Ib(){return{type:"boolean"}}function Ua(e,t){return Z(e.type._def,t)}var jb=(e,t)=>Z(e.innerType._def,t);function zd(e,t,r){let n=r??t.dateStrategy;if(Array.isArray(n))return{anyOf:n.map((o,i)=>zd(e,t,o))};switch(n){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return NI(e,t)}}var NI=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let n of e.checks)switch(n.kind){case"min":ne(r,"minimum",n.value,n.message,t);break;case"max":ne(r,"maximum",n.value,n.message,t);break}return r};function Nb(e,t){return{...Z(e.innerType._def,t),default:e.defaultValue()}}function Db(e,t){return t.effectStrategy==="input"?Z(e.schema._def,t):Pe(t)}function Mb(e){return{type:"string",enum:Array.from(e.values)}}var DI=(e)=>{if("type"in e&&e.type==="string")return!1;return"allOf"in e};function Lb(e,t){let r=[Z(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),Z(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter((i)=>!!i),n=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,o=[];return r.forEach((i)=>{if(DI(i)){if(o.push(...i.allOf),i.unevaluatedProperties===void 0)n=void 0}else{let s=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:a,...c}=i;s=c}else n=void 0;o.push(s)}}),o.length?{allOf:o,...n}:void 0}function qb(e,t){let r=typeof e.value;if(r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string")return{type:Array.isArray(e.value)?"array":"object"};if(t.target==="openApi3")return{type:r==="bigint"?"integer":r,enum:[e.value]};return{type:r==="bigint"?"integer":r,const:e.value}}var Od=void 0,Gt={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>{if(Od===void 0)Od=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u");return Od},uuid:/^[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}$/,ipv4:/^(?:(?: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])$/,ipv4Cidr:/^(?:(?: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])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([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])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function Fa(e,t){let r={type:"string"};if(e.checks)for(let n of e.checks)switch(n.kind){case"min":ne(r,"minLength",typeof r.minLength==="number"?Math.max(r.minLength,n.value):n.value,n.message,t);break;case"max":ne(r,"maxLength",typeof r.maxLength==="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Jt(r,"email",n.message,t);break;case"format:idn-email":Jt(r,"idn-email",n.message,t);break;case"pattern:zod":ut(r,Gt.email,n.message,t);break}break;case"url":Jt(r,"uri",n.message,t);break;case"uuid":Jt(r,"uuid",n.message,t);break;case"regex":ut(r,n.regex,n.message,t);break;case"cuid":ut(r,Gt.cuid,n.message,t);break;case"cuid2":ut(r,Gt.cuid2,n.message,t);break;case"startsWith":ut(r,RegExp(`^${Ad(n.value,t)}`),n.message,t);break;case"endsWith":ut(r,RegExp(`${Ad(n.value,t)}$`),n.message,t);break;case"datetime":Jt(r,"date-time",n.message,t);break;case"date":Jt(r,"date",n.message,t);break;case"time":Jt(r,"time",n.message,t);break;case"duration":Jt(r,"duration",n.message,t);break;case"length":ne(r,"minLength",typeof r.minLength==="number"?Math.max(r.minLength,n.value):n.value,n.message,t),ne(r,"maxLength",typeof r.maxLength==="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"includes":{ut(r,RegExp(Ad(n.value,t)),n.message,t);break}case"ip":{if(n.version!=="v6")Jt(r,"ipv4",n.message,t);if(n.version!=="v4")Jt(r,"ipv6",n.message,t);break}case"base64url":ut(r,Gt.base64url,n.message,t);break;case"jwt":ut(r,Gt.jwt,n.message,t);break;case"cidr":{if(n.version!=="v6")ut(r,Gt.ipv4Cidr,n.message,t);if(n.version!=="v4")ut(r,Gt.ipv6Cidr,n.message,t);break}case"emoji":ut(r,Gt.emoji(),n.message,t);break;case"ulid":{ut(r,Gt.ulid,n.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Jt(r,"binary",n.message,t);break}case"contentEncoding:base64":{ne(r,"contentEncoding","base64",n.message,t);break}case"pattern:zod":{ut(r,Gt.base64,n.message,t);break}}break}case"nanoid":ut(r,Gt.nanoid,n.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:((o)=>{})(n)}return r}function Ad(e,t){return t.patternStrategy==="escape"?LI(e):e}var MI=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function LI(e){let t="";for(let r=0;r<e.length;r++){if(!MI.has(e[r]))t+="\\";t+=e[r]}return t}function Jt(e,t,r,n){if(e.format||e.anyOf?.some((o)=>o.format)){if(!e.anyOf)e.anyOf=[];if(e.format){if(e.anyOf.push({format:e.format,...e.errorMessage&&n.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage){if(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0)delete e.errorMessage}}e.anyOf.push({format:t,...r&&n.errorMessages&&{errorMessage:{format:r}}})}else ne(e,"format",t,r,n)}function ut(e,t,r,n){if(e.pattern||e.allOf?.some((o)=>o.pattern)){if(!e.allOf)e.allOf=[];if(e.pattern){if(e.allOf.push({pattern:e.pattern,...e.errorMessage&&n.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage){if(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0)delete e.errorMessage}}e.allOf.push({pattern:Ub(t,n),...r&&n.errorMessages&&{errorMessage:{pattern:r}}})}else ne(e,"pattern",Ub(t,n),r,n)}function Ub(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let r={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},n=r.i?e.source.toLowerCase():e.source,o="",i=!1,s=!1,a=!1;for(let c=0;c<n.length;c++){if(i){o+=n[c],i=!1;continue}if(r.i){if(s){if(n[c].match(/[a-z]/)){if(a)o+=n[c],o+=`${n[c-2]}-${n[c]}`.toUpperCase(),a=!1;else if(n[c+1]==="-"&&n[c+2]?.match(/[a-z]/))o+=n[c],a=!0;else o+=`${n[c]}${n[c].toUpperCase()}`;continue}}else if(n[c].match(/[a-z]/)){o+=`[${n[c]}${n[c].toUpperCase()}]`;continue}}if(r.m){if(n[c]==="^"){o+=`(^|(?<=[\r
|
|
63
63
|
]))`;continue}else if(n[c]==="$"){o+=`($|(?=[\r
|
|
64
64
|
]))`;continue}}if(r.s&&n[c]==="."){o+=s?`${n[c]}\r
|
|
65
65
|
`:`[${n[c]}\r
|
|
66
|
-
]`;continue}if(o+=n[c],n[c]==="\\")i=!0;else if(s&&n[c]==="]")s=!1;else if(!s&&n[c]==="[")s=!0}try{new RegExp(o)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return o}function Ga(e,t){if(t.target==="openAi")console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead.");if(t.target==="openApi3"&&e.keyType?._def.typeName===P.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((n,o)=>({...n,[o]:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",o]})??Pe(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let r={type:"object",additionalProperties:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return r;if(e.keyType?._def.typeName===P.ZodString&&e.keyType._def.checks?.length){let{type:n,...o}=Va(e.keyType._def,t);return{...r,propertyNames:o}}else if(e.keyType?._def.typeName===P.ZodEnum)return{...r,propertyNames:{enum:e.keyType._def.values}};else if(e.keyType?._def.typeName===P.ZodBranded&&e.keyType._def.type._def.typeName===P.ZodString&&e.keyType._def.type._def.checks?.length){let{type:n,...o}=Ha(e.keyType._def,t);return{...r,propertyNames:o}}return r}function i_(e,t){if(t.mapStrategy==="record")return Ga(e,t);let r=Z(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||Pe(t),n=Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||Pe(t);return{type:"array",maxItems:125,items:{type:"array",items:[r,n],minItems:2,maxItems:2}}}function s_(e){let t=e.values,n=Object.keys(e.values).filter((i)=>typeof t[t[i]]!=="number").map((i)=>t[i]),o=Array.from(new Set(n.map((i)=>typeof i)));return{type:o.length===1?o[0]==="string"?"string":"number":["string","number"],enum:n}}function a_(e){return e.target==="openAi"?void 0:{not:Pe({...e,currentPath:[...e.currentPath,"not"]})}}function c_(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var Ui={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function l_(e,t){if(t.target==="openApi3")return u_(e,t);let r=e.options instanceof Map?Array.from(e.options.values()):e.options;if(r.every((n)=>(n._def.typeName in Ui)&&(!n._def.checks||!n._def.checks.length))){let n=r.reduce((o,i)=>{let s=Ui[i._def.typeName];return s&&!o.includes(s)?[...o,s]:o},[]);return{type:n.length>1?n:n[0]}}else if(r.every((n)=>n._def.typeName==="ZodLiteral"&&!n.description)){let n=r.reduce((o,i)=>{let s=typeof i._def.value;switch(s){case"string":case"number":case"boolean":return[...o,s];case"bigint":return[...o,"integer"];case"object":if(i._def.value===null)return[...o,"null"];case"symbol":case"undefined":case"function":default:return o}},[]);if(n.length===r.length){let o=n.filter((i,s,a)=>a.indexOf(i)===s);return{type:o.length>1?o:o[0],enum:r.reduce((i,s)=>i.includes(s._def.value)?i:[...i,s._def.value],[])}}}else if(r.every((n)=>n._def.typeName==="ZodEnum"))return{type:"string",enum:r.reduce((n,o)=>[...n,...o._def.values.filter((i)=>!n.includes(i))],[])};return u_(e,t)}var u_=(e,t)=>{let r=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((n,o)=>Z(n._def,{...t,currentPath:[...t.currentPath,"anyOf",`${o}`]})).filter((n)=>!!n&&(!t.strictUnions||typeof n==="object"&&Object.keys(n).length>0));return r.length?{anyOf:r}:void 0};function p_(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length)){if(t.target==="openApi3")return{type:Ui[e.innerType._def.typeName],nullable:!0};return{type:[Ui[e.innerType._def.typeName],"null"]}}if(t.target==="openApi3"){let n=Z(e.innerType._def,{...t,currentPath:[...t.currentPath]});if(n&&"$ref"in n)return{allOf:[n],nullable:!0};return n&&{...n,nullable:!0}}let r=Z(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return r&&{anyOf:[r,{type:"null"}]}}function d_(e,t){let r={type:"number"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"int":r.type="integer",Dd(r,"type",n.message,t);break;case"min":if(t.target==="jsonSchema7")if(n.inclusive)oe(r,"minimum",n.value,n.message,t);else oe(r,"exclusiveMinimum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMinimum=!0;oe(r,"minimum",n.value,n.message,t)}break;case"max":if(t.target==="jsonSchema7")if(n.inclusive)oe(r,"maximum",n.value,n.message,t);else oe(r,"exclusiveMaximum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMaximum=!0;oe(r,"maximum",n.value,n.message,t)}break;case"multipleOf":oe(r,"multipleOf",n.value,n.message,t);break}return r}function m_(e,t){let r=t.target==="openAi",n={type:"object",properties:{}},o=[],i=e.shape();for(let a in i){let c=i[a];if(c===void 0||c._def===void 0)continue;let u=Yj(c);if(u&&r){if(c._def.typeName==="ZodOptional")c=c._def.innerType;if(!c.isNullable())c=c.nullable();u=!1}let l=Z(c._def,{...t,currentPath:[...t.currentPath,"properties",a],propertyPath:[...t.currentPath,"properties",a]});if(l===void 0)continue;if(n.properties[a]=l,!u)o.push(a)}if(o.length)n.required=o;let s=Kj(e,t);if(s!==void 0)n.additionalProperties=s;return n}function Kj(e,t){if(e.catchall._def.typeName!=="ZodNever")return Z(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function Yj(e){try{return e.isOptional()}catch{return!0}}var f_=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return Z(e.innerType._def,t);let r=Z(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return r?{anyOf:[{not:Pe(t)},r]}:Pe(t)};var h_=(e,t)=>{if(t.pipeStrategy==="input")return Z(e.in._def,t);else if(t.pipeStrategy==="output")return Z(e.out._def,t);let r=Z(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),n=Z(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",r?"1":"0"]});return{allOf:[r,n].filter((o)=>o!==void 0)}};function g_(e,t){return Z(e.type._def,t)}function x_(e,t){let n={type:"array",uniqueItems:!0,items:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};if(e.minSize)oe(n,"minItems",e.minSize.value,e.minSize.message,t);if(e.maxSize)oe(n,"maxItems",e.maxSize.value,e.maxSize.message,t);return n}function v_(e,t){if(e.rest)return{type:"array",minItems:e.items.length,items:e.items.map((r,n)=>Z(r._def,{...t,currentPath:[...t.currentPath,"items",`${n}`]})).reduce((r,n)=>n===void 0?r:[...r,n],[]),additionalItems:Z(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})};else return{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((r,n)=>Z(r._def,{...t,currentPath:[...t.currentPath,"items",`${n}`]})).reduce((r,n)=>n===void 0?r:[...r,n],[])}}function y_(e){return{not:Pe(e)}}function b_(e){return Pe(e)}var __=(e,t)=>Z(e.innerType._def,t);var w_=(e,t,r)=>{switch(t){case P.ZodString:return Va(e,r);case P.ZodNumber:return d_(e,r);case P.ZodObject:return m_(e,r);case P.ZodBigInt:return Kb(e,r);case P.ZodBoolean:return Yb();case P.ZodDate:return Ld(e,r);case P.ZodUndefined:return y_(r);case P.ZodNull:return c_(r);case P.ZodArray:return Wb(e,r);case P.ZodUnion:case P.ZodDiscriminatedUnion:return l_(e,r);case P.ZodIntersection:return r_(e,r);case P.ZodTuple:return v_(e,r);case P.ZodRecord:return Ga(e,r);case P.ZodLiteral:return n_(e,r);case P.ZodEnum:return t_(e);case P.ZodNativeEnum:return s_(e);case P.ZodNullable:return p_(e,r);case P.ZodOptional:return f_(e,r);case P.ZodMap:return i_(e,r);case P.ZodSet:return x_(e,r);case P.ZodLazy:return()=>e.getter()._def;case P.ZodPromise:return g_(e,r);case P.ZodNaN:case P.ZodNever:return a_(r);case P.ZodEffects:return e_(e,r);case P.ZodAny:return Pe(r);case P.ZodUnknown:return b_(r);case P.ZodDefault:return Qb(e,r);case P.ZodBranded:return Ha(e,r);case P.ZodReadonly:return __(e,r);case P.ZodCatch:return Xb(e,r);case P.ZodPipeline:return h_(e,r);case P.ZodFunction:case P.ZodVoid:case P.ZodSymbol:return;default:return((n)=>{return})(t)}};function Z(e,t,r=!1){let n=t.seen.get(e);if(t.override){let a=t.override?.(e,t,n,r);if(a!==Vb)return a}if(n&&!r){let a=Xj(n,t);if(a!==void 0)return a}let o={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,o);let i=w_(e,e.typeName,t),s=typeof i==="function"?Z(i(),t):i;if(s)Qj(e,t,s);if(t.postProcess){let a=t.postProcess(s,e,t);return o.jsonSchema=s,a}return o.jsonSchema=s,s}var Xj=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:Ba(t.currentPath,e.path)};case"none":case"seen":{if(e.path.length<t.currentPath.length&&e.path.every((r,n)=>t.currentPath[n]===r))return console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),Pe(t);return t.$refStrategy==="seen"?Pe(t):void 0}}},Qj=(e,t,r)=>{if(e.description){if(r.description=e.description,t.markdownDescription)r.markdownDescription=e.description}return r};var Ud=(e,t)=>{let r=Jb(t),n=typeof t==="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[u,l])=>({...c,[u]:Z(l._def,{...r,currentPath:[...r.basePath,r.definitionPath,u]},!0)??Pe(r)}),{}):void 0,o=typeof t==="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=Z(e._def,o===void 0?r:{...r,currentPath:[...r.basePath,r.definitionPath,o]},!1)??Pe(r),s=typeof t==="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;if(s!==void 0)i.title=s;if(r.flags.hasReferencedOpenAiAnyType){if(!n)n={};if(!n[r.openAiAnyTypeName])n[r.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:r.$refStrategy==="relative"?"1":[...r.basePath,r.definitionPath,r.openAiAnyTypeName].join("/")}}}let a=o===void 0?n?{...i,[r.definitionPath]:n}:i:{$ref:[...r.$refStrategy==="relative"?[]:r.basePath,r.definitionPath,o].join("/"),[r.definitionPath]:{...n,[o]:i}};if(r.target==="jsonSchema7")a.$schema="http://json-schema.org/draft-07/schema#";else if(r.target==="jsonSchema2019-09"||r.target==="openAi")a.$schema="https://json-schema.org/draft/2019-09/schema#";if(r.target==="openAi"&&(("anyOf"in a)||("oneOf"in a)||("allOf"in a)||("type"in a)&&Array.isArray(a.type)))console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property.");return a};function eN(e){if(!e)return"draft-7";if(e==="jsonSchema7"||e==="draft-7")return"draft-7";if(e==="jsonSchema2019-09"||e==="draft-2020-12")return"draft-2020-12";return"draft-7"}function Fd(e,t){if(At(e))return pd(e,{target:eN(t?.target),io:t?.pipeStrategy??"input"});return Ud(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function Zd(e){let r=Nr(e)?.method;if(!r)throw Error("Schema is missing a method literal");let n=ba(r);if(typeof n!=="string")throw Error("Schema method literal must be a string");return n}function Bd(e,t){let r=jr(e,t);if(!r.success)throw r.error;return r.data}var tN=60000;class Hd{constructor(e){if(this._options=e,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(Ea,(t)=>{this._oncancel(t)}),this.setNotificationHandler(Pa,(t)=>{this._onprogress(t)}),this.setRequestHandler(Ra,(t)=>({})),this._taskStore=e?.taskStore,this._taskMessageQueue=e?.taskMessageQueue,this._taskStore)this.setRequestHandler(za,async(t,r)=>{let n=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!n)throw new D(q.InvalidParams,"Failed to retrieve task: Task not found");return{...n}}),this.setRequestHandler(Aa,async(t,r)=>{let n=async()=>{let o=t.params.taskId;if(this._taskMessageQueue){let s;while(s=await this._taskMessageQueue.dequeue(o,r.sessionId)){if(s.type==="response"||s.type==="error"){let a=s.message,c=a.id,u=this._requestResolvers.get(c);if(u)if(this._requestResolvers.delete(c),s.type==="response")u(a);else{let l=a,p=new D(l.error.code,l.error.message,l.error.data);u(p)}else{let l=s.type==="response"?"Response":"Error";this._onerror(Error(`${l} handler missing for request ${c}`))}continue}await this._transport?.send(s.message,{relatedRequestId:r.requestId})}}let i=await this._taskStore.getTask(o,r.sessionId);if(!i)throw new D(q.InvalidParams,`Task not found: ${o}`);if(!Lr(i.status))return await this._waitForTaskUpdate(o,r.signal),await n();if(Lr(i.status)){let s=await this._taskStore.getTaskResult(o,r.sessionId);return this._clearTaskQueue(o),{...s,_meta:{...s._meta,[Dr]:{taskId:o}}}}return await n()};return await n()}),this.setRequestHandler(Ca,async(t,r)=>{try{let{tasks:n,nextCursor:o}=await this._taskStore.listTasks(t.params?.cursor,r.sessionId);return{tasks:n,nextCursor:o,_meta:{}}}catch(n){throw new D(q.InvalidParams,`Failed to list tasks: ${n instanceof Error?n.message:String(n)}`)}}),this.setRequestHandler(ja,async(t,r)=>{try{let n=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!n)throw new D(q.InvalidParams,`Task not found: ${t.params.taskId}`);if(Lr(n.status))throw new D(q.InvalidParams,`Cannot cancel task in terminal status: ${n.status}`);await this._taskStore.updateTaskStatus(t.params.taskId,"cancelled","Client cancelled task execution.",r.sessionId),this._clearTaskQueue(t.params.taskId);let o=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!o)throw new D(q.InvalidParams,`Task not found after cancellation: ${t.params.taskId}`);return{_meta:{},...o}}catch(n){if(n instanceof D)throw n;throw new D(q.InvalidRequest,`Failed to cancel task: ${n instanceof Error?n.message:String(n)}`)}})}async _oncancel(e){if(!e.params.requestId)return;this._requestHandlerAbortControllers.get(e.params.requestId)?.abort(e.params.reason)}_setupTimeout(e,t,r,n,o=!1){this._timeoutInfo.set(e,{timeoutId:setTimeout(n,t),startTime:Date.now(),timeout:t,maxTotalTimeout:r,resetTimeoutOnProgress:o,onTimeout:n})}_resetTimeout(e){let t=this._timeoutInfo.get(e);if(!t)return!1;let r=Date.now()-t.startTime;if(t.maxTotalTimeout&&r>=t.maxTotalTimeout)throw this._timeoutInfo.delete(e),D.fromError(q.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:t.maxTotalTimeout,totalElapsed:r});return clearTimeout(t.timeoutId),t.timeoutId=setTimeout(t.onTimeout,t.timeout),!0}_cleanupTimeout(e){let t=this._timeoutInfo.get(e);if(t)clearTimeout(t.timeoutId),this._timeoutInfo.delete(e)}async connect(e){if(this._transport)throw Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=e;let t=this.transport?.onclose;this._transport.onclose=()=>{t?.(),this._onclose()};let r=this.transport?.onerror;this._transport.onerror=(o)=>{r?.(o),this._onerror(o)};let n=this._transport?.onmessage;this._transport.onmessage=(o,i)=>{if(n?.(o,i),Ai(o)||Cb(o))this._onresponse(o);else if(kd(o))this._onrequest(o,i);else if(Ab(o))this._onnotification(o);else this._onerror(Error(`Unknown message type: ${JSON.stringify(o)}`))},await this._transport.start()}_onclose(){let e=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let r of this._timeoutInfo.values())clearTimeout(r.timeoutId);this._timeoutInfo.clear();for(let r of this._requestHandlerAbortControllers.values())r.abort();this._requestHandlerAbortControllers.clear();let t=D.fromError(q.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let r of e.values())r(t)}_onerror(e){this.onerror?.(e)}_onnotification(e){let t=this._notificationHandlers.get(e.method)??this.fallbackNotificationHandler;if(t===void 0)return;Promise.resolve().then(()=>t(e)).catch((r)=>this._onerror(Error(`Uncaught error in notification handler: ${r}`)))}_onrequest(e,t){let r=this._requestHandlers.get(e.method)??this.fallbackRequestHandler,n=this._transport,o=e.params?._meta?.[Dr]?.taskId;if(r===void 0){let u={jsonrpc:"2.0",id:e.id,error:{code:q.MethodNotFound,message:"Method not found"}};if(o&&this._taskMessageQueue)this._enqueueTaskMessage(o,{type:"error",message:u,timestamp:Date.now()},n?.sessionId).catch((l)=>this._onerror(Error(`Failed to enqueue error response: ${l}`)));else n?.send(u).catch((l)=>this._onerror(Error(`Failed to send an error response: ${l}`)));return}let i=new AbortController;this._requestHandlerAbortControllers.set(e.id,i);let s=Pb(e.params)?e.params.task:void 0,a=this._taskStore?this.requestTaskStore(e,n?.sessionId):void 0,c={signal:i.signal,sessionId:n?.sessionId,_meta:e.params?._meta,sendNotification:async(u)=>{if(i.signal.aborted)return;let l={relatedRequestId:e.id};if(o)l.relatedTask={taskId:o};await this.notification(u,l)},sendRequest:async(u,l,p)=>{if(i.signal.aborted)throw new D(q.ConnectionClosed,"Request was cancelled");let m={...p,relatedRequestId:e.id};if(o&&!m.relatedTask)m.relatedTask={taskId:o};let d=m.relatedTask?.taskId??o;if(d&&a)await a.updateTaskStatus(d,"input_required");return await this.request(u,l,m)},authInfo:t?.authInfo,requestId:e.id,requestInfo:t?.requestInfo,taskId:o,taskStore:a,taskRequestedTtl:s?.ttl,closeSSEStream:t?.closeSSEStream,closeStandaloneSSEStream:t?.closeStandaloneSSEStream};Promise.resolve().then(()=>{if(s)this.assertTaskHandlerCapability(e.method)}).then(()=>r(e,c)).then(async(u)=>{if(i.signal.aborted)return;let l={result:u,jsonrpc:"2.0",id:e.id};if(o&&this._taskMessageQueue)await this._enqueueTaskMessage(o,{type:"response",message:l,timestamp:Date.now()},n?.sessionId);else await n?.send(l)},async(u)=>{if(i.signal.aborted)return;let l={jsonrpc:"2.0",id:e.id,error:{code:Number.isSafeInteger(u.code)?u.code:q.InternalError,message:u.message??"Internal error",...u.data!==void 0&&{data:u.data}}};if(o&&this._taskMessageQueue)await this._enqueueTaskMessage(o,{type:"error",message:l,timestamp:Date.now()},n?.sessionId);else await n?.send(l)}).catch((u)=>this._onerror(Error(`Failed to send response: ${u}`))).finally(()=>{if(this._requestHandlerAbortControllers.get(e.id)===i)this._requestHandlerAbortControllers.delete(e.id)})}_onprogress(e){let{progressToken:t,...r}=e.params,n=Number(t),o=this._progressHandlers.get(n);if(!o){this._onerror(Error(`Received a progress notification for an unknown token: ${JSON.stringify(e)}`));return}let i=this._responseHandlers.get(n),s=this._timeoutInfo.get(n);if(s&&i&&s.resetTimeoutOnProgress)try{this._resetTimeout(n)}catch(a){this._responseHandlers.delete(n),this._progressHandlers.delete(n),this._cleanupTimeout(n),i(a);return}o(r)}_onresponse(e){let t=Number(e.id),r=this._requestResolvers.get(t);if(r){if(this._requestResolvers.delete(t),Ai(e))r(e);else{let i=new D(e.error.code,e.error.message,e.error.data);r(i)}return}let n=this._responseHandlers.get(t);if(n===void 0){this._onerror(Error(`Received a response for an unknown message ID: ${JSON.stringify(e)}`));return}this._responseHandlers.delete(t),this._cleanupTimeout(t);let o=!1;if(Ai(e)&&e.result&&typeof e.result==="object"){let i=e.result;if(i.task&&typeof i.task==="object"){let s=i.task;if(typeof s.taskId==="string")o=!0,this._taskProgressTokens.set(s.taskId,t)}}if(!o)this._progressHandlers.delete(t);if(Ai(e))n(e);else{let i=D.fromError(e.error.code,e.error.message,e.error.data);n(i)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(e,t,r){let{task:n}=r??{};if(!n){try{yield{type:"result",result:await this.request(e,t,r)}}catch(i){yield{type:"error",error:i instanceof D?i:new D(q.InternalError,String(i))}}return}let o;try{let i=await this.request(e,fo,r);if(i.task)o=i.task.taskId,yield{type:"taskCreated",task:i.task};else throw new D(q.InternalError,"Task creation did not return a task");while(!0){let s=await this.getTask({taskId:o},r);if(yield{type:"taskStatus",task:s},Lr(s.status)){if(s.status==="completed")yield{type:"result",result:await this.getTaskResult({taskId:o},t,r)};else if(s.status==="failed")yield{type:"error",error:new D(q.InternalError,`Task ${o} failed`)};else if(s.status==="cancelled")yield{type:"error",error:new D(q.InternalError,`Task ${o} was cancelled`)};return}if(s.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:o},t,r)};return}let a=s.pollInterval??this._options?.defaultTaskPollInterval??1000;await new Promise((c)=>setTimeout(c,a)),r?.signal?.throwIfAborted()}}catch(i){yield{type:"error",error:i instanceof D?i:new D(q.InternalError,String(i))}}}request(e,t,r){let{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i,task:s,relatedTask:a}=r??{};return new Promise((c,u)=>{let l=(g)=>{u(g)};if(!this._transport){l(Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{if(this.assertCapabilityForMethod(e.method),s)this.assertTaskCapability(e.method)}catch(g){l(g);return}r?.signal?.throwIfAborted();let p=this._requestMessageId++,m={...e,jsonrpc:"2.0",id:p};if(r?.onprogress)this._progressHandlers.set(p,r.onprogress),m.params={...e.params,_meta:{...e.params?._meta||{},progressToken:p}};if(s)m.params={...m.params,task:s};if(a)m.params={...m.params,_meta:{...m.params?._meta||{},[Dr]:a}};let d=(g)=>{this._responseHandlers.delete(p),this._progressHandlers.delete(p),this._cleanupTimeout(p),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:p,reason:String(g)}},{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i}).catch((k)=>this._onerror(Error(`Failed to send cancellation: ${k}`)));let b=g instanceof D?g:new D(q.RequestTimeout,String(g));u(b)};this._responseHandlers.set(p,(g)=>{if(r?.signal?.aborted)return;if(g instanceof Error)return u(g);try{let b=jr(t,g.result);if(!b.success)u(b.error);else c(b.data)}catch(b){u(b)}}),r?.signal?.addEventListener("abort",()=>{d(r?.signal?.reason)});let h=r?.timeout??tN,x=()=>d(D.fromError(q.RequestTimeout,"Request timed out",{timeout:h}));this._setupTimeout(p,h,r?.maxTotalTimeout,x,r?.resetTimeoutOnProgress??!1);let y=a?.taskId;if(y){let g=(b)=>{let k=this._responseHandlers.get(p);if(k)k(b);else this._onerror(Error(`Response handler missing for side-channeled request ${p}`))};this._requestResolvers.set(p,g),this._enqueueTaskMessage(y,{type:"request",message:m,timestamp:Date.now()}).catch((b)=>{this._cleanupTimeout(p),u(b)})}else this._transport.send(m,{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i}).catch((g)=>{this._cleanupTimeout(p),u(g)})})}async getTask(e,t){return this.request({method:"tasks/get",params:e},Oa,t)}async getTaskResult(e,t,r){return this.request({method:"tasks/result",params:e},t,r)}async listTasks(e,t){return this.request({method:"tasks/list",params:e},Ia,t)}async cancelTask(e,t){return this.request({method:"tasks/cancel",params:e},Nb,t)}async notification(e,t){if(!this._transport)throw Error("Not connected");this.assertNotificationCapability(e.method);let r=t?.relatedTask?.taskId;if(r){let s={...e,jsonrpc:"2.0",params:{...e.params,_meta:{...e.params?._meta||{},[Dr]:t.relatedTask}}};await this._enqueueTaskMessage(r,{type:"notification",message:s,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(e.method)&&!e.params&&!t?.relatedRequestId&&!t?.relatedTask){if(this._pendingDebouncedNotifications.has(e.method))return;this._pendingDebouncedNotifications.add(e.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(e.method),!this._transport)return;let s={...e,jsonrpc:"2.0"};if(t?.relatedTask)s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[Dr]:t.relatedTask}}};this._transport?.send(s,t).catch((a)=>this._onerror(a))});return}let i={...e,jsonrpc:"2.0"};if(t?.relatedTask)i={...i,params:{...i.params,_meta:{...i.params?._meta||{},[Dr]:t.relatedTask}}};await this._transport.send(i,t)}setRequestHandler(e,t){let r=Zd(e);this.assertRequestHandlerCapability(r),this._requestHandlers.set(r,(n,o)=>{let i=Bd(e,n);return Promise.resolve(t(i,o))})}removeRequestHandler(e){this._requestHandlers.delete(e)}assertCanSetRequestHandler(e){if(this._requestHandlers.has(e))throw Error(`A request handler for ${e} already exists, which would be overridden`)}setNotificationHandler(e,t){let r=Zd(e);this._notificationHandlers.set(r,(n)=>{let o=Bd(e,n);return Promise.resolve(t(o))})}removeNotificationHandler(e){this._notificationHandlers.delete(e)}_cleanupTaskProgressHandler(e){let t=this._taskProgressTokens.get(e);if(t!==void 0)this._progressHandlers.delete(t),this._taskProgressTokens.delete(e)}async _enqueueTaskMessage(e,t,r){if(!this._taskStore||!this._taskMessageQueue)throw Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let n=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(e,t,r,n)}async _clearTaskQueue(e,t){if(this._taskMessageQueue){let r=await this._taskMessageQueue.dequeueAll(e,t);for(let n of r)if(n.type==="request"&&kd(n.message)){let o=n.message.id,i=this._requestResolvers.get(o);if(i)i(new D(q.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(o);else this._onerror(Error(`Resolver missing for request ${o} during task ${e} cleanup`))}}}async _waitForTaskUpdate(e,t){let r=this._options?.defaultTaskPollInterval??1000;try{let n=await this._taskStore?.getTask(e);if(n?.pollInterval)r=n.pollInterval}catch{}return new Promise((n,o)=>{if(t.aborted){o(new D(q.InvalidRequest,"Request cancelled"));return}let i=setTimeout(n,r);t.addEventListener("abort",()=>{clearTimeout(i),o(new D(q.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(e,t){let r=this._taskStore;if(!r)throw Error("No task store configured");return{createTask:async(n)=>{if(!e)throw Error("No request provided");return await r.createTask(n,e.id,{method:e.method,params:e.params},t)},getTask:async(n)=>{let o=await r.getTask(n,t);if(!o)throw new D(q.InvalidParams,"Failed to retrieve task: Task not found");return o},storeTaskResult:async(n,o,i)=>{await r.storeTaskResult(n,o,i,t);let s=await r.getTask(n,t);if(s){let a=Di.parse({method:"notifications/tasks/status",params:s});if(await this.notification(a),Lr(s.status))this._cleanupTaskProgressHandler(n)}},getTaskResult:(n)=>r.getTaskResult(n,t),updateTaskStatus:async(n,o,i)=>{let s=await r.getTask(n,t);if(!s)throw new D(q.InvalidParams,`Task "${n}" not found - it may have been cleaned up`);if(Lr(s.status))throw new D(q.InvalidParams,`Cannot update task "${n}" from terminal status "${s.status}" to "${o}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await r.updateTaskStatus(n,o,i,t);let a=await r.getTask(n,t);if(a){let c=Di.parse({method:"notifications/tasks/status",params:a});if(await this.notification(c),Lr(a.status))this._cleanupTaskProgressHandler(n)}},listTasks:(n)=>r.listTasks(n,t)}}}function k_(e){return e!==null&&typeof e==="object"&&!Array.isArray(e)}function S_(e,t){let r={...e};for(let n in t){let o=n,i=t[o];if(i===void 0)continue;let s=r[o];if(k_(s)&&k_(i))r[o]={...s,...i};else r[o]=i}return r}var s$=jo(qm(),1),a$=jo(i$(),1);function k4(){let e=new s$.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return a$.default(e),e}class Km{constructor(e){this._ajv=e??k4()}getValidator(e){let t="$id"in e&&typeof e.$id==="string"?this._ajv.getSchema(e.$id)??this._ajv.compile(e):this._ajv.compile(e);return(r)=>{if(t(r))return{valid:!0,data:r,errorMessage:void 0};else return{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(t.errors)}}}}class Ym{constructor(e){this._server=e}requestStream(e,t,r){return this._server.requestStream(e,t,r)}createMessageStream(e,t){let r=this._server.getClientCapabilities();if((e.tools||e.toolChoice)&&!r?.sampling?.tools)throw Error("Client does not support sampling tools capability.");if(e.messages.length>0){let n=e.messages[e.messages.length-1],o=Array.isArray(n.content)?n.content:[n.content],i=o.some((u)=>u.type==="tool_result"),s=e.messages.length>1?e.messages[e.messages.length-2]:void 0,a=s?Array.isArray(s.content)?s.content:[s.content]:[],c=a.some((u)=>u.type==="tool_use");if(i){if(o.some((u)=>u.type!=="tool_result"))throw Error("The last message must contain only tool_result content if any is present");if(!c)throw Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let u=new Set(a.filter((p)=>p.type==="tool_use").map((p)=>p.id)),l=new Set(o.filter((p)=>p.type==="tool_result").map((p)=>p.toolUseId));if(u.size!==l.size||![...u].every((p)=>l.has(p)))throw Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return this.requestStream({method:"sampling/createMessage",params:e},qi,t)}elicitInputStream(e,t){let r=this._server.getClientCapabilities(),n=e.mode??"form";switch(n){case"url":{if(!r?.elicitation?.url)throw Error("Client does not support url elicitation.");break}case"form":{if(!r?.elicitation?.form)throw Error("Client does not support form elicitation.");break}}let o=n==="form"&&e.mode===void 0?{...e,mode:"form"}:e;return this.requestStream({method:"elicitation/create",params:o},xo,t)}async getTask(e,t){return this._server.getTask({taskId:e},t)}async getTaskResult(e,t,r){return this._server.getTaskResult({taskId:e},t,r)}async listTasks(e,t){return this._server.listTasks(e?{cursor:e}:void 0,t)}async cancelTask(e,t){return this._server.cancelTask({taskId:e},t)}}function c$(e,t,r){if(!e)throw Error(`${r} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw Error(`${r} does not support task creation for tools/call (required for ${t})`);break;default:break}}function u$(e,t,r){if(!e)throw Error(`${r} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw Error(`${r} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw Error(`${r} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}class Xm extends Hd{constructor(e,t){super(t);if(this._serverInfo=e,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(Mi.options.map((r,n)=>[r,n])),this.isMessageIgnored=(r,n)=>{let o=this._loggingLevels.get(n);return o?this.LOG_LEVEL_SEVERITY.get(r)<this.LOG_LEVEL_SEVERITY.get(o):!1},this._capabilities=t?.capabilities??{},this._instructions=t?.instructions,this._jsonSchemaValidator=t?.jsonSchemaValidator??new Km,this.setRequestHandler(Td,(r)=>this._oninitialize(r)),this.setNotificationHandler(Ed,()=>this.oninitialized?.()),this._capabilities.logging)this.setRequestHandler(Id,async(r,n)=>{let o=n.sessionId||n.requestInfo?.headers["mcp-session-id"]||void 0,{level:i}=r.params,s=Mi.safeParse(i);if(s.success)this._loggingLevels.set(o,s.data);return{}})}get experimental(){if(!this._experimental)this._experimental={tasks:new Ym(this)};return this._experimental}registerCapabilities(e){if(this.transport)throw Error("Cannot register capabilities after connecting to transport");this._capabilities=S_(this._capabilities,e)}setRequestHandler(e,t){let n=Nr(e)?.method;if(!n)throw Error("Schema is missing a method literal");let o;if(At(n)){let s=n;o=s._zod?.def?.value??s.value}else{let s=n;o=s._def?.value??s.value}if(typeof o!=="string")throw Error("Schema method literal must be a string");if(o==="tools/call"){let s=async(a,c)=>{let u=jr(go,a);if(!u.success){let d=u.error instanceof Error?u.error.message:String(u.error);throw new D(q.InvalidParams,`Invalid tools/call request: ${d}`)}let{params:l}=u.data,p=await Promise.resolve(t(a,c));if(l.task){let d=jr(fo,p);if(!d.success){let h=d.error instanceof Error?d.error.message:String(d.error);throw new D(q.InvalidParams,`Invalid task creation result: ${h}`)}return d.data}let m=jr(Fa,p);if(!m.success){let d=m.error instanceof Error?m.error.message:String(m.error);throw new D(q.InvalidParams,`Invalid tools/call result: ${d}`)}return m.data};return super.setRequestHandler(e,s)}return super.setRequestHandler(e,t)}assertCapabilityForMethod(e){switch(e){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw Error(`Client does not support sampling (required for ${e})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw Error(`Client does not support elicitation (required for ${e})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw Error(`Client does not support listing roots (required for ${e})`);break;case"ping":break}}assertNotificationCapability(e){switch(e){case"notifications/message":if(!this._capabilities.logging)throw Error(`Server does not support logging (required for ${e})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw Error(`Server does not support notifying about resources (required for ${e})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw Error(`Server does not support notifying of tool list changes (required for ${e})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw Error(`Server does not support notifying of prompt list changes (required for ${e})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw Error(`Client does not support URL elicitation (required for ${e})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(e){if(!this._capabilities)return;switch(e){case"completion/complete":if(!this._capabilities.completions)throw Error(`Server does not support completions (required for ${e})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw Error(`Server does not support logging (required for ${e})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw Error(`Server does not support prompts (required for ${e})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw Error(`Server does not support resources (required for ${e})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw Error(`Server does not support tools (required for ${e})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw Error(`Server does not support tasks capability (required for ${e})`);break;case"ping":case"initialize":break}}assertTaskCapability(e){u$(this._clientCapabilities?.tasks?.requests,e,"Client")}assertTaskHandlerCapability(e){if(!this._capabilities)return;c$(this._capabilities.tasks?.requests,e,"Server")}async _oninitialize(e){let t=e.params.protocolVersion;return this._clientCapabilities=e.params.capabilities,this._clientVersion=e.params.clientInfo,{protocolVersion:Tb.includes(t)?t:_d,capabilities:this.getCapabilities(),serverInfo:this._serverInfo,...this._instructions&&{instructions:this._instructions}}}getClientCapabilities(){return this._clientCapabilities}getClientVersion(){return this._clientVersion}getCapabilities(){return this._capabilities}async ping(){return this.request({method:"ping"},Ta)}async createMessage(e,t){if(e.tools||e.toolChoice){if(!this._clientCapabilities?.sampling?.tools)throw Error("Client does not support sampling tools capability.")}if(e.messages.length>0){let r=e.messages[e.messages.length-1],n=Array.isArray(r.content)?r.content:[r.content],o=n.some((c)=>c.type==="tool_result"),i=e.messages.length>1?e.messages[e.messages.length-2]:void 0,s=i?Array.isArray(i.content)?i.content:[i.content]:[],a=s.some((c)=>c.type==="tool_use");if(o){if(n.some((c)=>c.type!=="tool_result"))throw Error("The last message must contain only tool_result content if any is present");if(!a)throw Error("tool_result blocks are not matching any tool_use from the previous message")}if(a){let c=new Set(s.filter((l)=>l.type==="tool_use").map((l)=>l.id)),u=new Set(n.filter((l)=>l.type==="tool_result").map((l)=>l.toolUseId));if(c.size!==u.size||![...c].every((l)=>u.has(l)))throw Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}if(e.tools)return this.request({method:"sampling/createMessage",params:e},jd,t);return this.request({method:"sampling/createMessage",params:e},qi,t)}async elicitInput(e,t){switch(e.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw Error("Client does not support url elicitation.");let n=e;return this.request({method:"elicitation/create",params:n},xo,t)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw Error("Client does not support form elicitation.");let n=e.mode==="form"?e:{...e,mode:"form"},o=await this.request({method:"elicitation/create",params:n},xo,t);if(o.action==="accept"&&o.content&&n.requestedSchema)try{let s=this._jsonSchemaValidator.getValidator(n.requestedSchema)(o.content);if(!s.valid)throw new D(q.InvalidParams,`Elicitation response content does not match requested schema: ${s.errorMessage}`)}catch(i){if(i instanceof D)throw i;throw new D(q.InternalError,`Error validating elicitation response: ${i instanceof Error?i.message:String(i)}`)}return o}}}createElicitationCompletionNotifier(e,t){if(!this._clientCapabilities?.elicitation?.url)throw Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:e}},t)}async listRoots(e,t){return this.request({method:"roots/list",params:e},Nd,t)}async sendLoggingMessage(e,t){if(this._capabilities.logging){if(!this.isMessageIgnored(e.level,t))return this.notification({method:"notifications/message",params:e})}}async sendResourceUpdated(e){return this.notification({method:"notifications/resources/updated",params:e})}async sendResourceListChanged(){return this.notification({method:"notifications/resources/list_changed"})}async sendToolListChanged(){return this.notification({method:"notifications/tools/list_changed"})}async sendPromptListChanged(){return this.notification({method:"notifications/prompts/list_changed"})}}var p$=Symbol.for("mcp.completable");function Qm(e){return!!e&&typeof e==="object"&&p$ in e}function d$(e){return e[p$]?.complete}var l$;(function(e){e.Completable="McpCompletable"})(l$||(l$={}));var S4=/^[A-Za-z0-9._-]{1,128}$/;function $4(e){let t=[];if(e.length===0)return{isValid:!1,warnings:["Tool name cannot be empty"]};if(e.length>128)return{isValid:!1,warnings:[`Tool name exceeds maximum length of 128 characters (current: ${e.length})`]};if(e.includes(" "))t.push("Tool name contains spaces, which may cause parsing issues");if(e.includes(","))t.push("Tool name contains commas, which may cause parsing issues");if(e.startsWith("-")||e.endsWith("-"))t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts");if(e.startsWith(".")||e.endsWith("."))t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts");if(!S4.test(e)){let r=e.split("").filter((n)=>!/[A-Za-z0-9._-]/.test(n)).filter((n,o,i)=>i.indexOf(n)===o);return t.push(`Tool name contains invalid characters: ${r.map((n)=>`"${n}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function T4(e,t){if(t.length>0){console.warn(`Tool name validation warning for "${e}":`);for(let r of t)console.warn(` - ${r}`);console.warn("Tool registration will proceed, but this may cause compatibility issues."),console.warn("Consider updating the tool name to conform to the MCP tool naming standard."),console.warn("See SEP: Specify Format for Tool Names (https://github.com/modelcontextprotocol/modelcontextprotocol/issues/986) for more details.")}}function ef(e){let t=$4(e);return T4(e,t.warnings),t.isValid}class tf{constructor(e){this._mcpServer=e}registerToolTask(e,t,r){let n={taskSupport:"required",...t.execution};if(n.taskSupport==="forbidden")throw Error(`Cannot register task-based tool '${e}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(e,t.title,t.description,t.inputSchema,t.outputSchema,t.annotations,n,t._meta,r)}}class nf{constructor(e,t){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new Xm(e,t)}get experimental(){if(!this._experimental)this._experimental={tasks:new tf(this)};return this._experimental}async connect(e){return await this.server.connect(e)}async close(){await this.server.close()}setToolRequestHandlers(){if(this._toolHandlersInitialized)return;this.server.assertCanSetRequestHandler(Vr(Ua)),this.server.assertCanSetRequestHandler(Vr(go)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(Ua,()=>({tools:Object.entries(this._registeredTools).filter(([,e])=>e.enabled).map(([e,t])=>{let r={name:e,title:t.title,description:t.description,inputSchema:(()=>{let n=po(t.inputSchema);return n?Fd(n,{strictUnions:!0,pipeStrategy:"input"}):E4})(),annotations:t.annotations,execution:t.execution,_meta:t._meta};if(t.outputSchema){let n=po(t.outputSchema);if(n)r.outputSchema=Fd(n,{strictUnions:!0,pipeStrategy:"output"})}return r})})),this.server.setRequestHandler(go,async(e,t)=>{try{let r=this._registeredTools[e.params.name];if(!r)throw new D(q.InvalidParams,`Tool ${e.params.name} not found`);if(!r.enabled)throw new D(q.InvalidParams,`Tool ${e.params.name} disabled`);let n=!!e.params.task,o=r.execution?.taskSupport,i="createTask"in r.handler;if((o==="required"||o==="optional")&&!i)throw new D(q.InternalError,`Tool ${e.params.name} has taskSupport '${o}' but was not registered with registerToolTask`);if(o==="required"&&!n)throw new D(q.MethodNotFound,`Tool ${e.params.name} requires task augmentation (taskSupport: 'required')`);if(o==="optional"&&!n&&i)return await this.handleAutomaticTaskPolling(r,e,t);let s=await this.validateToolInput(r,e.params.arguments,e.params.name),a=await this.executeToolHandler(r,s,t);if(n)return a;return await this.validateToolOutput(r,a,e.params.name),a}catch(r){if(r instanceof D){if(r.code===q.UrlElicitationRequired)throw r}return this.createToolError(r instanceof Error?r.message:String(r))}}),this._toolHandlersInitialized=!0}createToolError(e){return{content:[{type:"text",text:e}],isError:!0}}async validateToolInput(e,t,r){if(!e.inputSchema)return;let o=po(e.inputSchema)??e.inputSchema,i=await va(o,t);if(!i.success){let s="error"in i?i.error:"Unknown error",a=ya(s);throw new D(q.InvalidParams,`Input validation error: Invalid arguments for tool ${r}: ${a}`)}return i.data}async validateToolOutput(e,t,r){if(!e.outputSchema)return;if(!("content"in t))return;if(t.isError)return;if(!t.structuredContent)throw new D(q.InvalidParams,`Output validation error: Tool ${r} has an output schema but no structured content was provided`);let n=po(e.outputSchema),o=await va(n,t.structuredContent);if(!o.success){let i="error"in o?o.error:"Unknown error",s=ya(i);throw new D(q.InvalidParams,`Output validation error: Invalid structured content for tool ${r}: ${s}`)}}async executeToolHandler(e,t,r){let n=e.handler;if("createTask"in n){if(!r.taskStore)throw Error("No task store provided.");let i={...r,taskStore:r.taskStore};if(e.inputSchema)return await Promise.resolve(n.createTask(t,i));else return await Promise.resolve(n.createTask(i))}if(e.inputSchema)return await Promise.resolve(n(t,r));else return await Promise.resolve(n(r))}async handleAutomaticTaskPolling(e,t,r){if(!r.taskStore)throw Error("No task store provided for task-capable tool.");let n=await this.validateToolInput(e,t.params.arguments,t.params.name),o=e.handler,i={...r,taskStore:r.taskStore},s=n?await Promise.resolve(o.createTask(n,i)):await Promise.resolve(o.createTask(i)),a=s.task.taskId,c=s.task,u=c.pollInterval??5000;while(c.status!=="completed"&&c.status!=="failed"&&c.status!=="cancelled"){await new Promise((p)=>setTimeout(p,u));let l=await r.taskStore.getTask(a);if(!l)throw new D(q.InternalError,`Task ${a} not found during polling`);c=l}return await r.taskStore.getTaskResult(a)}setCompletionRequestHandler(){if(this._completionHandlerInitialized)return;this.server.assertCanSetRequestHandler(Vr(Za)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(Za,async(e)=>{switch(e.params.ref.type){case"ref/prompt":return Fb(e),this.handlePromptCompletion(e,e.params.ref);case"ref/resource":return Zb(e),this.handleResourceCompletion(e,e.params.ref);default:throw new D(q.InvalidParams,`Invalid completion reference: ${e.params.ref}`)}}),this._completionHandlerInitialized=!0}async handlePromptCompletion(e,t){let r=this._registeredPrompts[t.name];if(!r)throw new D(q.InvalidParams,`Prompt ${t.name} not found`);if(!r.enabled)throw new D(q.InvalidParams,`Prompt ${t.name} disabled`);if(!r.argsSchema)return ps;let o=Nr(r.argsSchema)?.[e.params.argument.name];if(!Qm(o))return ps;let i=d$(o);if(!i)return ps;let s=await i(e.params.argument.value,e.params.context);return f$(s)}async handleResourceCompletion(e,t){let r=Object.values(this._registeredResourceTemplates).find((i)=>i.resourceTemplate.uriTemplate.toString()===t.uri);if(!r){if(this._registeredResources[t.uri])return ps;throw new D(q.InvalidParams,`Resource template ${e.params.ref.uri} not found`)}let n=r.resourceTemplate.completeCallback(e.params.argument.name);if(!n)return ps;let o=await n(e.params.argument.value,e.params.context);return f$(o)}setResourceRequestHandlers(){if(this._resourceHandlersInitialized)return;this.server.assertCanSetRequestHandler(Vr(Na)),this.server.assertCanSetRequestHandler(Vr(Da)),this.server.assertCanSetRequestHandler(Vr(La)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(Na,async(e,t)=>{let r=Object.entries(this._registeredResources).filter(([o,i])=>i.enabled).map(([o,i])=>({uri:o,name:i.name,...i.metadata})),n=[];for(let o of Object.values(this._registeredResourceTemplates)){if(!o.resourceTemplate.listCallback)continue;let i=await o.resourceTemplate.listCallback(t);for(let s of i.resources)n.push({...o.metadata,...s})}return{resources:[...r,...n]}}),this.server.setRequestHandler(Da,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([t,r])=>({name:t,uriTemplate:r.resourceTemplate.uriTemplate.toString(),...r.metadata}))})),this.server.setRequestHandler(La,async(e,t)=>{let r=new URL(e.params.uri),n=this._registeredResources[r.toString()];if(n){if(!n.enabled)throw new D(q.InvalidParams,`Resource ${r} disabled`);return n.readCallback(r,t)}for(let o of Object.values(this._registeredResourceTemplates)){let i=o.resourceTemplate.uriTemplate.match(r.toString());if(i)return o.readCallback(r,i,t)}throw new D(q.InvalidParams,`Resource ${r} not found`)}),this._resourceHandlersInitialized=!0}setPromptRequestHandlers(){if(this._promptHandlersInitialized)return;this.server.assertCanSetRequestHandler(Vr(Ma)),this.server.assertCanSetRequestHandler(Vr(qa)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(Ma,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,e])=>e.enabled).map(([e,t])=>({name:e,title:t.title,description:t.description,arguments:t.argsSchema?R4(t.argsSchema):void 0}))})),this.server.setRequestHandler(qa,async(e,t)=>{let r=this._registeredPrompts[e.params.name];if(!r)throw new D(q.InvalidParams,`Prompt ${e.params.name} not found`);if(!r.enabled)throw new D(q.InvalidParams,`Prompt ${e.params.name} disabled`);if(r.argsSchema){let n=po(r.argsSchema),o=await va(n,e.params.arguments);if(!o.success){let a="error"in o?o.error:"Unknown error",c=ya(a);throw new D(q.InvalidParams,`Invalid arguments for prompt ${e.params.name}: ${c}`)}let i=o.data,s=r.callback;return await Promise.resolve(s(i,t))}else{let n=r.callback;return await Promise.resolve(n(t))}}),this._promptHandlersInitialized=!0}resource(e,t,...r){let n;if(typeof r[0]==="object")n=r.shift();let o=r[0];if(typeof t==="string"){if(this._registeredResources[t])throw Error(`Resource ${t} is already registered`);let i=this._createRegisteredResource(e,void 0,t,n,o);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[e])throw Error(`Resource template ${e} is already registered`);let i=this._createRegisteredResourceTemplate(e,void 0,t,n,o);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}registerResource(e,t,r,n){if(typeof t==="string"){if(this._registeredResources[t])throw Error(`Resource ${t} is already registered`);let o=this._createRegisteredResource(e,r.title,t,r,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),o}else{if(this._registeredResourceTemplates[e])throw Error(`Resource template ${e} is already registered`);let o=this._createRegisteredResourceTemplate(e,r.title,t,r,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),o}}_createRegisteredResource(e,t,r,n,o){let i={name:e,title:t,metadata:n,readCallback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({uri:null}),update:(s)=>{if(typeof s.uri<"u"&&s.uri!==r){if(delete this._registeredResources[r],s.uri)this._registeredResources[s.uri]=i}if(typeof s.name<"u")i.name=s.name;if(typeof s.title<"u")i.title=s.title;if(typeof s.metadata<"u")i.metadata=s.metadata;if(typeof s.callback<"u")i.readCallback=s.callback;if(typeof s.enabled<"u")i.enabled=s.enabled;this.sendResourceListChanged()}};return this._registeredResources[r]=i,i}_createRegisteredResourceTemplate(e,t,r,n,o){let i={resourceTemplate:r,title:t,metadata:n,readCallback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({name:null}),update:(c)=>{if(typeof c.name<"u"&&c.name!==e){if(delete this._registeredResourceTemplates[e],c.name)this._registeredResourceTemplates[c.name]=i}if(typeof c.title<"u")i.title=c.title;if(typeof c.template<"u")i.resourceTemplate=c.template;if(typeof c.metadata<"u")i.metadata=c.metadata;if(typeof c.callback<"u")i.readCallback=c.callback;if(typeof c.enabled<"u")i.enabled=c.enabled;this.sendResourceListChanged()}};this._registeredResourceTemplates[e]=i;let s=r.uriTemplate.variableNames;if(Array.isArray(s)&&s.some((c)=>!!r.completeCallback(c)))this.setCompletionRequestHandler();return i}_createRegisteredPrompt(e,t,r,n,o){let i={title:t,description:r,argsSchema:n===void 0?void 0:_n(n),callback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({name:null}),update:(s)=>{if(typeof s.name<"u"&&s.name!==e){if(delete this._registeredPrompts[e],s.name)this._registeredPrompts[s.name]=i}if(typeof s.title<"u")i.title=s.title;if(typeof s.description<"u")i.description=s.description;if(typeof s.argsSchema<"u")i.argsSchema=_n(s.argsSchema);if(typeof s.callback<"u")i.callback=s.callback;if(typeof s.enabled<"u")i.enabled=s.enabled;this.sendPromptListChanged()}};if(this._registeredPrompts[e]=i,n){if(Object.values(n).some((a)=>{let c=a instanceof kt?a._def?.innerType:a;return Qm(c)}))this.setCompletionRequestHandler()}return i}_createRegisteredTool(e,t,r,n,o,i,s,a,c){ef(e);let u={title:t,description:r,inputSchema:m$(n),outputSchema:m$(o),annotations:i,execution:s,_meta:a,handler:c,enabled:!0,disable:()=>u.update({enabled:!1}),enable:()=>u.update({enabled:!0}),remove:()=>u.update({name:null}),update:(l)=>{if(typeof l.name<"u"&&l.name!==e){if(typeof l.name==="string")ef(l.name);if(delete this._registeredTools[e],l.name)this._registeredTools[l.name]=u}if(typeof l.title<"u")u.title=l.title;if(typeof l.description<"u")u.description=l.description;if(typeof l.paramsSchema<"u")u.inputSchema=_n(l.paramsSchema);if(typeof l.outputSchema<"u")u.outputSchema=_n(l.outputSchema);if(typeof l.callback<"u")u.handler=l.callback;if(typeof l.annotations<"u")u.annotations=l.annotations;if(typeof l._meta<"u")u._meta=l._meta;if(typeof l.enabled<"u")u.enabled=l.enabled;this.sendToolListChanged()}};return this._registeredTools[e]=u,this.setToolRequestHandlers(),this.sendToolListChanged(),u}tool(e,...t){if(this._registeredTools[e])throw Error(`Tool ${e} is already registered`);let r,n,o,i;if(typeof t[0]==="string")r=t.shift();if(t.length>1){let a=t[0];if(rf(a)){if(n=t.shift(),t.length>1&&typeof t[0]==="object"&&t[0]!==null&&!rf(t[0]))i=t.shift()}else if(typeof a==="object"&&a!==null){if(Object.values(a).some((c)=>typeof c==="object"&&c!==null))throw Error(`Tool ${e} expected a Zod schema or ToolAnnotations, but received an unrecognized object`);i=t.shift()}}let s=t[0];return this._createRegisteredTool(e,void 0,r,n,o,i,{taskSupport:"forbidden"},void 0,s)}registerTool(e,t,r){if(this._registeredTools[e])throw Error(`Tool ${e} is already registered`);let{title:n,description:o,inputSchema:i,outputSchema:s,annotations:a,_meta:c}=t;return this._createRegisteredTool(e,n,o,i,s,a,{taskSupport:"forbidden"},c,r)}prompt(e,...t){if(this._registeredPrompts[e])throw Error(`Prompt ${e} is already registered`);let r;if(typeof t[0]==="string")r=t.shift();let n;if(t.length>1)n=t.shift();let o=t[0],i=this._createRegisteredPrompt(e,void 0,r,n,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),i}registerPrompt(e,t,r){if(this._registeredPrompts[e])throw Error(`Prompt ${e} is already registered`);let{title:n,description:o,argsSchema:i}=t,s=this._createRegisteredPrompt(e,n,o,i,r);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(e,t){return this.server.sendLoggingMessage(e,t)}sendResourceListChanged(){if(this.isConnected())this.server.sendResourceListChanged()}sendToolListChanged(){if(this.isConnected())this.server.sendToolListChanged()}sendPromptListChanged(){if(this.isConnected())this.server.sendPromptListChanged()}}var E4={type:"object",properties:{}};function h$(e){return e!==null&&typeof e==="object"&&"parse"in e&&typeof e.parse==="function"&&"safeParse"in e&&typeof e.safeParse==="function"}function g$(e){return"_def"in e||"_zod"in e||h$(e)}function rf(e){if(typeof e!=="object"||e===null)return!1;if(g$(e))return!1;if(Object.keys(e).length===0)return!0;return Object.values(e).some(h$)}function m$(e){if(!e)return;if(rf(e))return _n(e);if(!g$(e))throw Error("inputSchema must be a Zod schema or raw shape, received an unrecognized object");return e}function R4(e){let t=Nr(e);if(!t)return[];return Object.entries(t).map(([r,n])=>{let o=rb(n),i=nb(n);return{name:r,description:o,required:!i}})}function Vr(e){let r=Nr(e)?.method;if(!r)throw Error("Schema is missing a method literal");let n=ba(r);if(typeof n==="string")return n;throw Error("Schema method literal must be a string")}function f$(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var ps={completion:{values:[],hasMore:!1}};import v$ from"node:process";class of{append(e){this._buffer=this._buffer?Buffer.concat([this._buffer,e]):e}readMessage(){if(!this._buffer)return null;let e=this._buffer.indexOf(`
|
|
67
|
-
`);if(e===-1)return null;let t=this._buffer.toString("utf8",0,e).replace(/\r$/,"");return this._buffer=this._buffer.subarray(e+1),
|
|
68
|
-
`}class
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
`)}}catch{}}var yZ=v.object({name:v.string(),hex:v.string().describe("3/4/6/8-digit hex, e.g. #1FB6A6 or #1FB6A6FF. The LIGHT-scheme value."),hexDark:v.string().optional().describe("This color's DARK-scheme value (same hex format). Send it only when the brand really defines one — a brand where no color carries hexDark has no dark scheme and figs render one scheme."),role:v.string().optional(),meaning:v.string().optional()}).passthrough(),kf=v.object({hex:v.string(),hexDark:v.string().optional()}).passthrough(),Nc=v.object({base:kf,on:kf.describe("Ink drawn ON the base fill."),container:kf.optional().describe("Soft/tinted surface for this state.")}).passthrough(),bZ=v.object({success:Nc.optional(),warning:Nc.optional(),error:Nc.optional(),info:Nc.optional()}).passthrough().describe("Semantic state colors. They are ADDITIONAL to the palette — figs never drop a state to meet the color cap. Omit a role the brand doesn't define; Figura's neutral tint fills it."),_Z=v.object({id:v.string().optional(),rule:v.string()}).passthrough(),wZ=v.object({colors:v.array(yZ).optional(),gradient:v.string().optional(),signature:v.object({kind:v.enum(["solid","gradient","iridescent"]),stops:v.array(v.string()).optional()}).passthrough().optional(),type:v.object({families:v.record(v.string()).optional(),ramp:v.array(v.number()).optional(),rules:v.string().optional()}).passthrough().optional(),spacing:v.array(v.number()).optional(),radius:v.array(v.number()).optional(),voice:v.object({nouns:v.array(v.string()).optional(),promise:v.string().optional(),lines:v.array(v.string()).optional(),tone:v.string().optional()}).passthrough().optional(),locales:v.array(v.object({tag:v.string().describe('BCP-47 language tag, e.g. "en", "ar", "ckb".'),script:v.string().describe('ISO 15924 script code, e.g. "Latn", "Arab".'),direction:v.enum(["ltr","rtl"]),fonts:v.object({display:v.string().optional(),body:v.string().optional(),mono:v.string().optional()}).passthrough().optional()}).passthrough()).optional().describe("Languages the brand ships in — FIRST entry is the default. Per-locale fonts override the shared type families for that script."),forbidden:v.array(_Z).optional(),icons:v.object({set:v.enum(["material-symbols","sf-symbols","lucide","custom"]),style:v.enum(["outlined","filled","rounded","sharp"]),weight:v.number().optional(),strokeWidth:v.number().optional()}).passthrough().optional(),accessibility:v.object({minTouchTarget:v.number().optional(),minTextSize:v.number().optional(),contrastTarget:v.enum(["AA","AAA"]).optional(),reducedMotion:v.enum(["respect","ignore"]).optional()}).passthrough().optional(),status:bZ.optional()}).passthrough(),Sf=v.object({components:v.array(v.object({name:v.string(),spec:v.string()}).passthrough()).optional(),icons:v.string().optional(),layout:v.string().optional(),surfaces:v.array(v.string()).optional(),bans:v.array(v.string()).optional(),tokensBlock:v.string().optional()}).passthrough(),kZ=v.object({mobile:Sf.optional(),web:Sf.optional(),desktop:Sf.optional()}).passthrough(),SZ="https://api.figura.so",$Z="mcp";async function qc(){let e=await _$(),t=e?await cf(e):{},r=await cf(af),n={...r,...t},o=process.env.FIGURA_TOKEN||n.token||void 0,i=process.env.FIGURA_TOKEN?"env":t.token?"project":r.token?"global":"none",s=(process.env.FIGURA_API_URL||n.apiUrl||SZ).replace(/\/+$/,"");return{token:o,apiUrl:s,team:n.team,source:i,configPath:i==="project"?e:i==="global"?af:null}}async function de(e,t={}){let r=await qc(),n=r.token;if(!n)throw Error("No Figura token. Run `figura link` in this repo (or `figura login`, or set FIGURA_TOKEN).");let o=(t.method??"GET").toUpperCase();if(uf(o,r.source,process.env.FIGURA_ALLOW_GLOBAL==="1"))throw Error(`this project isn't linked to a Figura team — the global credential${r.team?` (team '${r.team}')`:""} would receive this write. Ask the user to run \`figura link\` in this repo (or set FIGURA_ALLOW_GLOBAL=1 to use the global team deliberately).`);let i=`${r.apiUrl}${e.startsWith("/")?"":"/"}${e}`,s={Accept:"application/json",Authorization:`Bearer ${n}`,"X-Figura-Source":$Z},a;if(t.body!==void 0)s["Content-Type"]="application/json",a=JSON.stringify(t.body);let c=await Ks.request({url:i,method:t.method??"GET",headers:s,data:a,...t.timeoutMs?{timeout:t.timeoutMs}:{},validateStatus:()=>!0,transformRequest:[(p)=>p],transformResponse:[(p)=>p]});{let p=c.headers,m=(d)=>{let h=p?.[d];return typeof h==="string"?h:void 0};Q$(Mc,jc(r.apiUrl),X$(Mc,m))}let u=typeof c.data==="string"?c.data:"",l=void 0;if(u)try{l=JSON.parse(u)}catch{l=u}if(c.status<200||c.status>=300){let p=l&&typeof l==="object"&&l!==null&&"error"in l?String(l.error):typeof l==="string"&&l?l:c.statusText||`HTTP ${c.status}`;throw Error(`${p} (HTTP ${c.status})`)}return l}var tT=2500,TZ=600000,EZ=60000;async function RZ(e){let t=Math.ceil(TZ/tT);try{return await S$({intervalMs:tT,maxPolls:t,errorToleranceMs:EZ,fetchJob:()=>de(`/v1/jobs/${encodeURIComponent(e)}`)})}catch(r){let n=r instanceof Error?r.message:String(r);if(n.startsWith("Job poll failed:"))throw Error(`Lost contact with the Figura API while waiting for job ${e} (${n.slice(17)}). `+`The job may still complete — resume by checking GET /v1/jobs/${e} instead of regenerating.`);if(n.startsWith("Timed out"))throw Error(`Timed out waiting for job ${e} — it may still complete; `+`check GET /v1/jobs/${e} instead of regenerating.`);throw r}}function ve(e){return{content:[{type:"text",text:JSON.stringify(e,null,2)}]}}function he(e){return{content:[{type:"text",text:e instanceof Error?e.message:String(e)}],isError:!0}}var PZ=3000,zZ=250,OZ=600000,Dc=null,Tf=null;function oT(){if(!Dc||Date.now()-Dc.at>OZ)Dc={at:Date.now(),value:A$(()=>de("/v1/skills/fig/latest",{timeoutMs:PZ})).then((e)=>{if(e.hash!=null)Tf=e;return e})};return Dc.value}async function Ef(){try{let e,t=()=>Tf??Ac(),r=new Promise((n)=>{e=setTimeout(()=>n(t()),zZ),e.unref?.()});return await Promise.race([oT(),r]).finally(()=>clearTimeout(e))}catch{return Tf??Ac()}}var rT=!1;async function xs(e){try{if(rT)return e;if(!e||typeof e!=="object"||Array.isArray(e))return e;let{apiUrl:t}=await qc(),r=await Y$({stream:Mc,current:Ao,origin:jc(t)});if(!r)return e;return rT=!0,{...e,notice:r}}catch{return e}}function Lc(e,t){if(!e||typeof e!=="object"||Array.isArray(e))return e;let r=C$(t);if(!r)return e;return{...e,skillWarning:r}}var Oo=()=>v.string().optional().describe("Product area / surface the fig belongs to, e.g. 'dashboard', 'settings', 'onboarding'. Free text — but REUSE one of the team's existing areas EXACTLY when the fig belongs to that surface; a synonym fragments the library. The team's areas with counts come back from figura_whoami, figura_fig_scaffold and every create as `areas`."),Uc=()=>v.string().optional().describe(`The fig's BRIEF — rendered as the Brief panel beside the fig, and the first thing the reviewer you assign reads. Not a caption. Four beats, in order: (1) the OBJECTIVE in the user's own words, quoted verbatim, restated in every later round; (2) the ARC — one line per prior round: what it tried and what it settled or killed, INCLUDING any direction that was explored and abandoned, with the reason ("withdrawn"/"superseded" on its own deletes the most useful thing a reviewer can know); (3) what is STILL OPEN — the question this round does not close; (4) the PICK and the decision you want back. Writing a later round? Read the prior figs' briefs first (figura_list_figs then figura_get_fig) and carry the objective + arc forward — never restate them from session memory. Max 2000 chars (the fig editor's cap).`),vs=["portrait","landscape","both"],Fc=["single","compare","variations"],iT=["fig","child"],{version:Ao,name:AZ}=(()=>{try{let e=JSON.parse(vZ(new URL("../package.json",import.meta.url),"utf8"));return{version:typeof e.version==="string"?e.version:"0.0.0",name:typeof e.name==="string"?e.name:void 0}}catch{return{version:"0.0.0"}}})(),Mc=W$(AZ),ke=new nf({name:"figura",version:Ao});ke.registerTool("figura_whoami",{title:"Figura: whoami",description:"Return the identity (team, actor, scopes) for the configured Figura token, plus `binding` — which config tier supplied it (env | project | global) — and `areas`, the team's existing fig areas with counts (most-used first). A `global` binding means this project is not linked to a team and writes will be refused; ask the user to run `figura link` in the repo. Use `areas` to pick an existing `area` when creating a fig instead of coining a synonym.",inputSchema:{}},async()=>{try{let e=await de("/v1/whoami"),{source:t,configPath:r}=await qc();return ve(await xs({...e,binding:{source:t,configPath:r}}))}catch(e){return he(e)}});ke.registerTool("figura_set_brand",{title:"Figura: set brand profile",description:'Set (upsert) the team brand profile that the fig generator renders against. Use this to "introduce a repo to Figura": scan the codebase for its design system, synthesize the brand, then push it here. `name` is required. PREFERRED — send a STRUCTURED brand: `identity` (shared colors/gradient/type/spacing/radius/voice/forbidden/icons/accessibility) + `platforms` (per-platform surfaces, keys mobile|web|desktop) — this makes the brand structured + addressable (is_structured=true). LEGACY/fallback — send prose: `tokensBlock` (freeform design-token reference) + `surfaces` (the product\'s own key areas). `appDescription` is a one-clause product summary. This is a partial merge — fields you omit keep their saved value; a structured write clears the dormant prose columns and a prose write downgrades to legacy. Editing the team brand — confirm with the user before calling.',inputSchema:{name:v.string().describe("Brand / app name (required)."),appDescription:v.string().optional().describe("One clause on what the product is + who it is for."),identity:wZ.optional().describe("STRUCTURED shared identity (platform-agnostic): { colors:[{name,hex,hexDark?,role?,meaning?}], gradient?, signature?:{kind:solid|gradient|iridescent,stops?:hex[]}, type?:{families?:{slot:font},ramp?:number[],rules?}, spacing?:number[], radius?:number[], voice?:{nouns?,promise?,lines?,tone?}, locales?:[{tag,script,direction,fonts?}] (first = default), forbidden?:[{id?,rule}], icons?:{set:material-symbols|sf-symbols|lucide|custom, style:outlined|filled|rounded|sharp, weight?, strokeWidth?}, accessibility?:{minTouchTarget?, minTextSize?, contrastTarget?:AA|AAA, reducedMotion?:respect|ignore}, status?:{success?,warning?,error?,info? — each {base:{hex,hexDark?}, on?:{hex,hexDark?}, container?:{hex,hexDark?}}} }. hex is 3/4/6/8 digits; hexDark is that color's dark-scheme value (omit unless the brand defines one). `signature` is the brand-page hero treatment: solid unless the repo's tokens define a gradient identity; gradient/iridescent require 2–5 stops. `icons` is what the fig prompt icon rule asserts (a filled set stops it drawing thin strokes); `accessibility` floors default to 44/11/AA/respect when omitted. Status colors are semantic states, additional to the palette and outside the fig color cap. Sending this makes the brand STRUCTURED (is_structured=true). Validated server-side."),platforms:kZ.optional().describe('STRUCTURED per-platform surfaces — a map keyed by mobile|web|desktop; include ONLY the platforms the product targets: { <platform>: { components?:[{name,spec}], icons?, layout?, surfaces?:string[], bans?:string[], tokensBlock? } }. `mobile` ALSO takes os?: "ios"|"android" (unset = iOS) — it drives every fig\'s device frame, system-bar heights, back affordance, and corner radii; `os` on web/desktop is rejected. `tokensBlock` here is a per-platform escape hatch for guidance that does not fit a structured field.'),proseSource:v.string().optional().describe(`The human-readable freeform description this structured brand was authored from — stored as the editable source shown in the web brand editor; NOT used by generation. Send it alongside a structured write so a skill/CLI/MCP-authored brand still seeds the web editor's "Author from a description" textarea (a repo scan should pass the prose it synthesized the brand from; a prose→structured upgrade should pass the original prose).`),tokensBlock:v.string().optional().describe("LEGACY prose fallback: freeform plain-text design-token reference (colors + hex + role, type scale + faces, spacing, gradient, voice/conventions). Prefer `identity`/`platforms`. Injected verbatim into the fig-generation prompt."),surfaces:v.array(v.string()).optional().describe(`LEGACY prose fallback: the product's own key areas/sections (e.g. ["Feed", "Settings", "Checkout"]) — read from the repo's real navigation/routes. For a structured brand put surfaces under each platform instead. Pass [] to clear.`)}},async(e)=>{try{return ve(await de("/brand",{method:"PUT",body:$$(e)}))}catch(t){return he(t)}});ke.registerTool("figura_brand_schema",{title:"Figura: brand schema",description:"Return the JSON Schema for the STRUCTURED brand — the ONE authority (derived server-side from the zod schema PUT /brand validates). Fetch this BEFORE synthesizing a brand for figura_set_brand's `identity`/`platforms`, and author against it so the brand validates first try (strict keys; hex 3/4/6/8 digits; platform keys mobile|web|desktop; no blank array entries). Read-only. Returns { schema }.",inputSchema:{}},async()=>{try{return ve(await de("/v1/brand/schema"))}catch(e){return he(e)}});var CZ={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",webp:"image/webp",avif:"image/avif",svg:"image/svg+xml"},$f=5242880;function nT(e){let t=e.split(/[?#]/)[0].split(".").pop()?.toLowerCase()??"";return CZ[t]}async function sT(e,t){let r,n=t;if(/^https?:\/\//i.test(e)){let o=await Ks.get(e,{responseType:"arraybuffer",maxContentLength:$f,timeout:30000});if(r=Buffer.from(o.data).toString("base64"),!n){let i=String(o.headers["content-type"]??"").split(";")[0].trim().toLowerCase();n=i.startsWith("image/")?i:nT(e)}}else{let{size:o}=await wf.stat(e);if(o>$f)throw Error(`'${e}' is ${(o/1048576).toFixed(1)}MB — over the ${$f/1048576}MB asset limit.`);if(r=(await wf.readFile(e)).toString("base64"),!n)n=nT(e)}if(!n)throw Error(`Could not determine an image content-type for '${e}' — pass contentType (e.g. image/png).`);return{data:r,contentType:n}}async function IZ(e,t){let{data:r,contentType:n}=await sT(e,t),o=await de("/v1/assets",{method:"POST",body:{data:r,contentType:n}});if(!o||typeof o.url!=="string")throw Error("Asset upload did not return a URL.");return o.url}var aT=()=>v.array(v.object({source:v.string().describe("The image — a local file path or an http(s) URL (e.g. a screenshot)."),match:v.string().optional().describe('Exact string in the HTML to replace with the hosted URL (defaults to `source` — i.e. write <img src="<source>"> in the HTML).')})).optional().describe("Images to attach: each is uploaded to durable figura hosting (stable non-expiring URL, allowed by the fig CSP) and substituted into the HTML in place of `match`/`source`. Use for real screenshots/photos/logos instead of base64 data-URIs (HTML size cap) or external URLs (expire/CSP-blocked).");async function cT(e,t){if(!t?.length)return{parts:e,uploaded:[]};let r=[...e],n=[];for(let o of t){let i=o.match??o.source;if(!r.some((a)=>a?.includes(i)))throw Error(`images: '${i}' does not occur in the fig's markup — reference it (e.g. <img src="${i}">) so it can be swapped for the hosted URL, or set 'match'.`);let s=await IZ(o.source);r=r.map((a)=>a===void 0?a:a.split(i).join(s)),n.push({source:o.source,url:s})}return{parts:r,uploaded:n}}async function jZ(e,t){let{parts:r,uploaded:n}=await cT([e],t);return{html:r[0],uploaded:n}}function uT(e,t){if(!t.length)return e;if(e&&typeof e==="object"&&!Array.isArray(e))return{...e,assets:t};return{result:e,assets:t}}ke.registerTool("figura_create_fig",{title:"Figura: create fig",description:"Create a new visualization from an HTML document — this HOSTS it (the create IS the hosting; there is no separate \"land it in Figura\" step). Every create returns `viewUrl`: ALWAYS a link you can open for approval, whether or not the fig is published — the public share url once published, else a team-scoped viewer link only signed-in teammates can open. The fig lands as a workspace DRAFT (`status: 'draft'`): hosted and viewable, visible to its author, but NOT in the team library and silent for teammates — iterate freely without claiming the team's attention, then COMMIT only the session's final recommendation (`commit: true` on that final create/revise, or figura_commit_fig). Do NOT pass publish:true just to get something viewable — omit it (default false) so the fig lands team-private, open `viewUrl` for review, and only publish when the human wants a link they can share outside the team (figura_publish_fig, once approved). The response also carries `brandWarnings` — a deterministic (no-LLM) colors/fonts/radii/spacing diff against the team's brand tokens, WARN-only (never blocks the create). If it comes back non-empty, read it and consider a figura_revise_fig call that binds the missing tokens before telling the user you're done. To include REAL images (screenshots/photos/logos), pass them via `images` — they are uploaded to durable figura hosting and their stable URLs substituted into the HTML. TIP — injected components: if your HTML shows phone frames (a compare/multi-screen mock), wrap each state in <div class=\"fig-device portrait|landscape\"><div class=\"fig-screen\">…</div><div class=\"fig-di\"></div><div class=\"fig-homebar\"></div></div> — Figura injects accurate iPhone frame CSS at save, BEFORE your <style>, so you normally leave those classes alone; if you do style them your rule wins by cascade (the frame still works), but to shrink frames for an overview grid wrap each frame in the injected `.fig-mini` wrapper (e.g. <div class=\"fig-mini\" style=\"--fig-scale:.34\"> … the .fig-device block … </div>) — it scales the device with transform and reserves the scaled layout box — rather than re-declaring .fig-device width/height or adding transform: scale() yourself (which fights the injected geometry), and never CSS zoom (it leaks unzoomed width into horizontal overflow). Same injection applies to an iOS status bar (<div class=\"fig-statusbar\" data-time=\"9:41\"></div>), a compare control bar (.fig-controls/.fig-seg), and the .frame-web browser window.",inputSchema:{html:v.string().describe("The full HTML document for the visualization."),images:aT(),title:v.string().optional().describe("Title (otherwise derived from the HTML)."),description:Uc(),area:Oo(),tags:v.array(v.string()).optional(),orientation:v.enum(vs).optional(),mode:v.enum(Fc).optional(),model:v.string().optional().describe("Model attribution."),device:v.string().optional().describe("Catalog device id the fig targets (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9') — keys the injected frame/safe-area geometry."),os:v.enum(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),issue:v.number().optional().describe("Linked issue number."),locale:v.string().optional().describe("BCP-47 tag of the brand locale this fig renders in (must be one of the brand's identity.locales) — Figura stamps <html lang dir> and loads the per-script font."),publish:v.boolean().optional().describe("Publish to a shareable public URL on create (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately, so only set this when the human explicitly wants a link they can share outside the team. Share link ONLY — does not commit the fig to the team library (that's `commit`)."),commit:v.boolean().optional().describe("Commit to the team library on create (sends status: 'published'). Default false — the fig lands as a workspace DRAFT: hosted + viewable via `viewUrl`, visible to its author, but not in the team library and silent for teammates. Set true ONLY when this write is the session's final recommendation (the fig the user asked for / signed off on); explorations and intermediate iterations stay drafts. Committing later: figura_commit_fig."),prompt:v.string().optional().describe("OPTIONAL: the brief that produced this HTML, if there was one — you wrote the HTML yourself, so Figura never sees a prompt unless you pass it here. Stored on the fig (DB-only, never stamped into the HTML), and returned by figura_get_fig — lets teammates see 'why' this fig exists."),new:v.boolean().optional().describe("Start a SEPARATE chain even though the team already has a near-identical one. Figura REFUSES a fresh chain when this fig looks like the next round of an open question, and names the chain to revise instead (figura_revise_fig) — so an exercise stays one walkable history with one discussion. Pass true ONLY when this genuinely is a different question; forking because revising felt like more work is what leaves a reviewer reading round 4 with no sight of rounds 1-3."),kind:v.enum(iT).optional().describe("'child' creates the fig as frameless screen CONTENT that another fig embeds — it stays out of the team library and its own listing. Default 'fig' (a normal, standalone fig). Nothing composes children yet; do not pass this unless you are building a composition.")}},async(e)=>{try{let{html:t,uploaded:r}=await jZ(e.html,e.images),n={html:t};for(let i of["title","description","area","tags","orientation","mode","model","device","os","locale","issue","publish","prompt","kind","new"])if(e[i]!==void 0)n[i]=e[i];if(e.commit)n.status="published";let o=Cc(Ao,await Ef());return n.toolchain=o,ve(Lc(await xs(uT(await de("/v1/figs",{method:"POST",body:n}),r)),o.skill.drift))}catch(t){return he(t)}});var lT=["single","compare","variations","overview-focus","document"],pT=v.object({html:v.string().optional().describe("SCREEN CONTENT markup only — no frame, no bezel, no safe padding. Omit when passing `childFig`."),childFig:v.string().optional().describe("Compose this frame BY REFERENCE: the id of an existing CHILD fig (one composed with kind:'child') which Figura embeds in its own iframe instead of inlining. Only for `single` and `compare`. Its CSS cannot reach the frame or the other screen, so two children with conflicting body{} rules both render correctly. PINNED to this exact version. Mutually exclusive with `html`/`css`/`safeZone` — the child opts into the safe area itself. This screen's `device` and `orientation` must be the ones the child was composed with — the frame draws that phone's cutout and home bar around the child's own safe-area guides, so a mismatch is refused (422)."),css:v.string().optional().describe("Optional per-screen content styles (appended unscoped)."),device:v.string().optional().describe("Catalog device id (e.g. 'iphone-16'). REQUIRED for device layouts."),orientation:v.enum(["portrait","landscape"]).optional().describe("REQUIRED for device layouts."),safeZone:v.enum(["respect","ignore"]).optional().describe("REQUIRED for device layouts, REFUSED with `childFig`. 'respect' pads to the real catalog safe insets; 'ignore' is edge-to-edge. A referenced screen pads itself inside the child fig, with the `--fig-safe-*` vars or the `.fig-safe` helper the frame sets on it."),label:v.string().optional().describe("Chrome label (compare/variations chip, focus pill)."),notes:v.array(v.object({text:v.string().describe("The point being made. Plain text."),kind:v.enum(["broken","improved","tradeoff","detail"]).optional().describe("What this note argues — colors the rail accent and its matching pin. Default 'detail'."),at:v.object({x:v.number(),y:v.number()}).optional().describe("Percent coordinates (0-100, from the top-left of the SCREEN) to pin this note to. Omit for a point about the whole state — it still gets a number in the rail, just no pin.")})).optional().describe("This screen's annotations. NEVER write annotation chips into `html`: they land inside the phone screen, on top of the design the fig exists to let someone judge. Passed here, Figura puts each note in a rail BESIDE the frame and leaves only a small numbered pin on the artboard. `compare` and `overview-focus` only (the other layouts have no rail and will reject them); max 8. Works the same on a screen composed by reference (`childFig`) — the rail and pins are the parent's.")});ke.registerTool("figura_compose_fig",{title:"Figura: compose fig",description:"PREFERRED way to build a device fig. You write ONLY each screen's CONTENT (the markup inside the phone) + typed params; Figura owns the STRUCTURE — the iPhone frame, the Dynamic Island/notch/home bar, the exact catalog artboard geometry, the REAL safe-area insets, and the composition (grid/diptych/overview). This means the parts that used to drift every few figs — hand-rolled artboards, guessed `--fig-safe-top:59px`, a forgotten `data-device` so no safe machinery stamped — are correct-by-construction: you never write them. Pass `layout` + an ARRAY of `screens`. For every DEVICE layout (single/compare/variations/overview-focus) each screen REQUIRES `device` (a catalog id like 'iphone-16' — fetch figura_fig_devices), `orientation` ('portrait'|'landscape'), and `safeZone` ('respect' = Figura pads your content to the device's real safe insets; 'ignore' = edge-to-edge splash/hero) — except a `childFig` screen, which takes NO `safeZone` (the child pads itself). Each screen's `html` is CONTENT ONLY — do NOT draw a frame, a bezel, a status bar, or safe padding; do NOT set `--fig-safe-*`; do NOT wrap in `.fig-device`; and do NOT write annotation chips into it — pass them as `notes` and Figura rails them BESIDE the frame with numbered pins, instead of covering the design you are asking someone to judge. Style your content with brand tokens via `sharedCss` (ONE stylesheet all screens share) + optional per-screen `css`. Layouts: `single` (one frame), `compare` (as-is → proposed diptych — pass label per screen), `overview-focus` (**use for ANY redesign argument or set of candidate directions** — a CSS toggle that OPENS on the full-frame Focus view with state pills; the Overview grid is the alternative behind the second tab), `variations` (a scan-only grid at the kit's ~0.34 device scale with NO toggle — every frame renders ~134px wide, so body copy and annotations are unreadable; use ONLY for a pure catalogue, NEVER to argue a change), `document` (NO device framing — brand/overview figs; screens need no device/orientation/safeZone). Lands EXACTLY like figura_create_fig (workspace DRAFT, returns `viewUrl` + `brandWarnings` + `warnings`; commit the session's final pick). For a `document`/exotic hand-authored fig where you need full control of the HTML, use figura_create_fig instead.",inputSchema:{layout:v.enum(lT).describe("The composition Figura emits."),title:v.string().optional().describe("Fig title (else derived from the HTML)."),description:Uc(),area:Oo(),tags:v.array(v.string()).optional(),orientation:v.enum(vs).optional().describe('Fig-level orientation for the persisted row (may be "both").'),device:v.string().optional().describe("Fig-level default catalog device (per-screen `device` still keys each frame)."),locale:v.string().optional().describe("BCP-47 tag of the brand locale this fig renders in (must be one of the brand's identity.locales) — Figura stamps <html lang dir> and loads the per-script font."),sharedCss:v.string().optional().describe("ONE stylesheet ALL screens share — put brand tokens + shared classes here."),screens:v.array(pT).describe("The screens to compose. One for `single`; two for a `compare` diptych; N for variations/overview-focus/document."),model:v.string().optional().describe("Model attribution."),issue:v.number().optional().describe("Linked issue number."),publish:v.boolean().optional().describe("Publish to a shareable public URL on compose (requires a paid plan). Default false."),commit:v.boolean().optional().describe("Commit to the team library (sends status: 'published'). Default false — lands a workspace draft."),prompt:v.string().optional().describe("OPTIONAL brief that produced this fig (DB-only)."),new:v.boolean().optional().describe("Start a SEPARATE chain even though the team already has a near-identical one. Figura REFUSES a fresh chain when this fig looks like the next round of an open question, and names the chain to revise instead (figura_revise_fig) — so an exercise stays one walkable history with one discussion. Pass true ONLY when this genuinely is a different question; forking because revising felt like more work is what leaves a reviewer reading round 4 with no sight of rounds 1-3."),kind:v.enum(iT).optional().describe("'child' composes the fig as frameless screen CONTENT another fig embeds — it stays out of the team library and the fig listing. Default 'fig'. Compose the children first, then pass their ids as `screens[].childFig` on a `single` or `compare` parent.")}},async(e)=>{try{let t={layout:e.layout,screens:e.screens};for(let n of["title","description","area","tags","orientation","device","locale","sharedCss","model","issue","publish","prompt","kind","new"])if(e[n]!==void 0)t[n]=e[n];if(e.commit)t.status="published";let r=Cc(Ao,await Ef());return t.toolchain=r,ve(Lc(await xs(await de("/v1/figs/compose",{method:"POST",body:t})),r.skill.drift))}catch(t){return he(t)}});ke.registerTool("figura_upload_asset",{title:"Figura: upload asset",description:"Upload a durable image asset and get back a STABLE, figura-hosted URL that never expires — use it in a fig's <img src> instead of a base64 data-URI (bloats the HTML past the publish size) or an external URL that expires (Instagram/CDN signed links). The fig CSP allows figura-hosted images. Provide `path` (a local image file), `url` (an http(s) image to fetch and re-host), or `data` (base64 bytes) + `contentType`. Accepts png/jpeg/gif/webp/avif/svg, up to 5MB. Returns `{ url }`.",inputSchema:{path:v.string().optional().describe("Local path to an image file to upload (content-type inferred from the extension)."),url:v.string().optional().describe("http(s) URL of an image to fetch and re-host (alternative to `path`) — use for expiring/signed source URLs so the fig keeps rendering after they die."),data:v.string().optional().describe("Base64-encoded image bytes (alternative to `path`/`url`). Requires `contentType`."),contentType:v.string().optional().describe("MIME type, e.g. image/png. Required with `data`; inferred from the extension/response for `path`/`url`.")}},async(e)=>{try{let t=e.path??e.url;if(t){let{data:r,contentType:n}=await sT(t,e.contentType);return ve(await de("/v1/assets",{method:"POST",body:{data:r,contentType:n}}))}if(!e.data)throw Error("Provide `path` (a local image file), `url` (an http(s) image), or `data` (base64 bytes).");if(!e.contentType)throw Error("`contentType` is required with `data` — e.g. image/png.");return ve(await de("/v1/assets",{method:"POST",body:{data:e.data,contentType:e.contentType}}))}catch(t){return he(t)}});ke.registerTool("figura_generate_fig",{title:"Figura: generate fig",description:"Generate a new fig server-side from a natural-language brief, then persist it — this HOSTS it (the create IS the hosting). The engine runs Figura's on-brand generation — you do NOT write the HTML; just describe the screen. SPENDS TEAM CREDITS: only use when the user explicitly opts for a server render; otherwise default to writing the HTML yourself and landing it with figura_create_fig (free, uses the calling model). Runs as an async server job; this call polls until the fig lands (typically 30–90s). Returns the created fig (id, slug) and `viewUrl` — ALWAYS a link you can open for approval (a team-scoped viewer when unpublished, the public share url once published). Like figura_create_fig, the generated fig lands as a workspace DRAFT — not in the team library, silent for teammates — commit the session's final pick with figura_commit_fig. Requires an active paid subscription.",inputSchema:{prompt:v.string().describe("A natural-language brief describing the screen/UI to generate."),area:Oo(),orientation:v.enum(vs).optional(),mode:v.enum(Fc).optional(),platform:v.enum(["mobile","web"]).optional().describe("Output platform: 'mobile' (iPhone frame) or 'web' (browser frame). When omitted, the engine INFERS it from the brief — a desktop/web/browser/landing-page/dashboard brief renders web, an iPhone/mobile/app-screen brief renders mobile — falling back to mobile only when neither is signalled. Pass this to force a platform regardless of the wording."),device:v.string().optional().describe("Catalog device id to target (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9'). Mobile only; default iphone-16 (pixel-9 when os is 'android')."),os:v.enum(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),title:v.string().optional().describe("Title (otherwise derived from the generated HTML)."),fidelity:v.enum(["fast","high"]).optional().describe("Generation fidelity (default fast)."),publish:v.boolean().optional().describe("Publish to a shareable public URL on create (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately, so only set this when the human explicitly wants a link they can share outside the team.")}},async(e)=>{try{let t={prompt:e.prompt};for(let o of["area","orientation","mode","platform","device","os","title","publish"])if(e[o]!==void 0)t[o]=e[o];if(e.fidelity!==void 0)t.model=e.fidelity;let r=Cc(Ao,await Ef());t.toolchain=r,t.async=!0;let n=await de("/v1/figs/generate",{method:"POST",body:t});if(n&&typeof n==="object"&&typeof n.jobId==="string"){let o=await RZ(n.jobId),i=o.result??{};return ve(Lc(await xs(i.fig??o.result),r.skill.drift))}return ve(Lc(await xs(n),r.skill.drift))}catch(t){return he(t)}});ke.registerTool("figura_fig_scaffold",{title:"Figura: fig scaffold",description:"Return the CANONICAL fig authoring scaffold — the exact system prompt Figura injects when it renders a fig server-side (design rules + exemplars + accent hints + your team's composed brand + the component/device kit context), composed for a target (platform/device/area/mode/orientation). USE THIS on the hand-build path (before writing a fig's HTML with figura_create_fig): author against this scaffold instead of a hand-maintained copy of the guidance, so your fig follows the SAME rules + brand the server would. Read-only — no fig is created, no credits are spent. Returns { scaffold, platform, mode, orientation, area, areas, device, brand } — `areas` is your team's existing areas with fig counts, most-used first; pick `area` from it rather than inventing one.",inputSchema:{platform:v.enum(["mobile","web"]).optional().describe("Target platform: 'mobile' (iPhone frame, default) or 'web' (browser frame)."),device:v.string().optional().describe("Catalog device id (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9'). Mobile only; default iphone-16 (pixel-9 when os is 'android')."),os:v.enum(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),area:Oo(),orientation:v.enum(vs).optional(),mode:v.enum(Fc).optional()}},async(e)=>{try{let t=new URLSearchParams;for(let n of["platform","device","os","area","orientation","mode"])if(e[n]!==void 0)t.set(n,String(e[n]));let r=t.toString();return ve(await de(`/v1/fig/scaffold${r?`?${r}`:""}`))}catch(t){return he(t)}});ke.registerTool("figura_fig_devices",{title:"Figura: fig devices",description:"Return the CANONICAL framed-device catalog — every valid `data-device` id plus its per-device geometry (os ios|android, logical dims portrait/landscape, safe-area insets, cutout island|notch|punch|none, corner radius). USE THIS when authoring a CANVAS COMPOSITION fig that frames a specific phone in-fig (a `.fig-device` element with `data-device` set): pick a real id from here instead of guessing, since an unknown data-device silently gets NO frame. Pass `os` to narrow the catalog to one platform's phones (an Android fig must NOT be framed in an iPhone). Read-only — no fig is created, no credits are spent. Returns { devices, default }.",inputSchema:{os:v.enum(["ios","android"]).optional().describe("Only return this OS's devices, and its default frame ('pixel-9' for android).")}},async(e)=>{try{let t=e.os?`?os=${e.os}`:"";return ve(await de(`/v1/fig/devices${t}`))}catch(t){return he(t)}});ke.registerTool("figura_revise_fig",{title:"Figura: revise fig",description:"Create a new revision (version) of an existing fig — from updated HTML, or from TYPED SCREENS. Two shapes, and which one you use is decided by the fig: a fig composed BY REFERENCE (screens that are `childFig` references — figura_get_fig reports `composesByReference` and returns its `children`) can ONLY be revised by typed screens; passing `html` for one is refused 422, because a text revise would leave its typed references, pinned versions and labels behind on the old version. TYPED REVISE: pass `layout` + `screens`, the same shape figura_compose_fig takes, and Figura re-composes. Every child reference is carried into the new revision with the same pin, label, notes and position; leave a screen `{}` (empty) to keep a REFERENCED slot untouched (an INLINE slot must have its `html` re-sent), or give it `html`/`childFig` to change it. The previous revision keeps its own children resolving at their pins. Returns the new fig (id, slug, version) and `viewUrl` — ALWAYS a link to open and re-review. The revision lands as a workspace DRAFT regardless of the parent's status — not in the team library, silent for teammates — so iterate freely; when a revision is the session's final agreed version, commit it (`commit: true` on that call, or figura_commit_fig). Publishing is NOT inherited from the fig being revised: the new revision defaults to unpublished (a team-scoped viewer `viewUrl`) even if the fig it revises is currently live — the existing public link keeps serving the OLD version until you pass `publish: true` on THIS call, which republishes at the SAME stable link (same publicId across the chain). The new version joins the original fig's chain — it does not replace it in place. Use list_revisions for the chain (rootFig + every version). The response also carries `brandWarnings` — a deterministic (no-LLM) colors/fonts/radii/spacing diff against the team's brand tokens, WARN-only. If it comes back non-empty, consider one more revision that binds the missing tokens. To include REAL images (screenshots/photos/logos), pass them via `images` — uploaded to durable figura hosting, stable URLs substituted into the HTML.",inputSchema:{id:v.string().describe("The fig to revise — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),html:v.string().optional().describe("The full updated HTML document. Use this OR `layout` + `screens`, never both."),layout:v.enum(lT).optional().describe("TYPED REVISE: the composition to re-emit. Required with `screens`, and not inherited — the stored fig records a lossy `mode`, not the layout."),screens:v.array(pT).optional().describe("TYPED REVISE: the screens, positionally. An EMPTY object `{}` keeps a REFERENCED slot exactly as the previous revision had it — same child fig, same pinned version, same label, same notes, same device. Send `notes: []` to clear that slot's annotations. It works only over a slot that was a `childFig`: a slot that held INLINE `html` must have its html sent again (Figura does not read it back out of the composed document), and a blank one is refused 422. Give a slot `childFig` (a different child, or the same one with a new `label`) or `html` to change it."),sharedCss:v.string().optional().describe("TYPED REVISE: the ONE stylesheet all screens share."),images:aT(),title:v.string().optional().describe("Title (otherwise derived from the HTML)."),description:Uc(),area:v.string().optional().describe("Product area / surface; free text. Inherited from the parent if omitted."),tags:v.array(v.string()).optional(),orientation:v.enum(vs).optional().describe("Inherited from the parent if omitted."),mode:v.enum(Fc).optional(),model:v.string().optional().describe("Model attribution."),issue:v.number().optional().describe("Linked issue number."),locale:v.string().optional().describe("BCP-47 tag of the brand locale this revision renders in (must be one of the brand's identity.locales) — stamps <html lang dir> and loads the per-script font."),publish:v.boolean().optional().describe("Publish the new revision to a shareable public URL (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately. If the fig being revised is ALREADY published, pass true here too or its public link keeps serving the prior version. Share link ONLY — does not commit the revision to the team library (that's `commit`)."),commit:v.boolean().optional().describe("Commit this revision to the team library (sends status: 'published'). Default false — the revision lands as a workspace DRAFT even when the fig it revises is committed. Set true ONLY when this revision is the session's final agreed version; intermediate iterations stay drafts. Committing later: figura_commit_fig."),prompt:v.string().optional().describe("OPTIONAL: the brief/ask that produced this revision, if there was one. Stored on the fig (DB-only, never stamped into the HTML), and returned by figura_get_fig.")}},async(e)=>{try{if(!e.html&&!e.screens)return he(Error("revise needs `html`, or `layout` + `screens` for a typed revise."));if(e.html&&e.screens)return he(Error("revise takes `html` OR `layout` + `screens`, never both."));let t=e.screens,{parts:r,uploaded:n}=await cT(e.html?[e.html]:[...(t??[]).flatMap((i)=>[i.html,i.css]),e.sharedCss],e.images),o=e.html?{html:r[0]}:{};for(let i of["title","description","area","tags","orientation","mode","model","issue","locale","publish","prompt","layout"])if(e[i]!==void 0)o[i]=e[i];if(t){if(o.screens=t.map((i,s)=>({...i,...i.html!==void 0?{html:r[s*2]}:{},...i.css!==void 0?{css:r[s*2+1]}:{}})),e.sharedCss!==void 0)o.sharedCss=r[r.length-1]}if(e.commit)o.status="published";return ve(uT(await de(`/v1/figs/${encodeURIComponent(e.id)}/revise`,{method:"POST",body:o}),n))}catch(t){return he(t)}});ke.registerTool("figura_list_revisions",{title:"Figura: list revisions",description:"List the full revision chain for a fig (all versions sharing a root), oldest to newest.",inputSchema:{id:v.string().describe("Any fig in the chain — its id (`fig_…`), a UUID, share link/URL, or publicId.")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}/revisions`))}catch(t){return he(t)}});ke.registerTool("figura_merge_figs",{title:"Figura: merge fig chains",description:"Fold one fig's chain INTO another's, so a question that was explored as separate sibling figs becomes ONE chain whose versions read in order. Use it when you (or an earlier session) landed a fresh fig for what is really the next round of an existing exercise — the library shows one card per question instead of N near-duplicates, and the whole decision trail is walkable. The source chain's versions are appended after the destination's head, oldest first; share links keep resolving, and verdicts/decisions follow the chain. Pass `dry_run` first to see the plan. Prefer NOT creating the fork in the first place: revise the existing fig (figura_revise_fig) rather than minting a sibling.",inputSchema:{id:v.string().describe("The fig whose chain MOVES — any version of it (`fig_…`, a UUID, a share link/URL, or its publicId)."),into:v.string().describe("The fig whose chain it joins — any version of the destination. Its root stays the chain root."),dry_run:v.boolean().optional().describe("Return the plan (which versions land at which numbers) without writing. Default false.")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}/merge`,{method:"POST",body:{into:e.into,dryRun:e.dry_run===!0}}))}catch(t){return he(t)}});ke.registerTool("figura_commit_fig",{title:"Figura: commit fig",description:"Commit a fig to the team library (status draft → published). Machine-created figs land as workspace DRAFTS — hosted, viewable via `viewUrl`, visible to their author, but NOT in the team library and silent for teammates. Committing is the explicit act that puts one in the team library and notifies the team (digest-batched) — so commit ONLY the session's final recommendation (the fig the user asked for / signed off on), never every exploration or intermediate iteration. If the final fig is one you're about to create/revise anyway, prefer `commit: true` on that call over a separate commit here. Orthogonal to figura_publish_fig (the public share link): a shared draft's URL resolves fine, and committing creates no link. Idempotent. Pass `uncommit: true` to reverse it (published → draft; the share link is untouched). Returns { id, status, committed, alreadyCommitted, viewUrl }.",inputSchema:{id:v.string().describe("The fig to commit — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),uncommit:v.boolean().optional().describe("Set true to uncommit: the fig leaves the team library back to an author-visible workspace draft. Defaults to false (commit).")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}/${e.uncommit?"uncommit":"commit"}`,{method:"POST",body:{}}))}catch(t){return he(t)}});ke.registerTool("figura_publish_fig",{title:"Figura: publish fig",description:"Publish (or unpublish) an existing fig to its shareable public URL. The fig is ALREADY hosted and viewable team-privately without this (figura_create_fig/figura_revise_fig's `viewUrl`) — only call this once the human wants a link they can share outside the team. Share link ONLY — it does not put the fig in the team library (that's figura_commit_fig; a shared draft's URL resolves fine). Requires a paid plan. Returns { isPublic, url, publicId, viewUrl }. Publishing a fig that composes other figs (`childFig` screens) makes its CHILDREN reachable at that public link too — they are served with the parent that references them. A CHILD fig has no share link of its own and publishing one is refused: publish the parent.",inputSchema:{id:v.string().describe("The fig to publish — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),isPublic:v.boolean().optional().describe("Set false to unpublish (make private). Defaults to true (publish).")}},async(e)=>{try{let t={};if(e.isPublic!==void 0)t.isPublic=e.isPublic;return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}/publish`,{method:"POST",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_list_figs",{title:"Figura: list figs",description:"List visualizations for the team, optionally filtered by area or tag.",inputSchema:{area:Oo(),tag:v.string().optional(),limit:v.number().optional(),cursor:v.string().optional()}},async(e)=>{try{let t=new URLSearchParams;if(e.area)t.set("area",e.area);if(e.tag)t.set("tag",e.tag);if(e.limit!==void 0)t.set("limit",String(e.limit));if(e.cursor)t.set("cursor",e.cursor);let r=t.toString();return ve(await de(`/v1/figs${r?`?${r}`:""}`))}catch(t){return he(t)}});ke.registerTool("figura_get_fig",{title:"Figura: get fig",description:"Fetch a single visualization by id. The response carries `viewUrl` — ALWAYS a link you can open for approval (a team-scoped viewer when unpublished, the public share url once published). For a fig composed BY REFERENCE (`composesByReference: true`) it also returns `children` — each screen’s child fig id, pinned version, position and label. That is what you edit: send them back as `screens` on figura_revise_fig to change the composition, or as `screens` on figura_compose_fig to build a copy.",inputSchema:{id:v.string().describe("The fig — its id (`fig_…`), a UUID, a share link/URL, or its publicId.")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}`))}catch(t){return he(t)}});ke.registerTool("figura_comment",{title:"Figura: comment",description:"Add a comment to a visualization.",inputSchema:{fig_id:v.string().describe("The fig to comment on — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),body:v.string().describe("Comment text.")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.fig_id)}/comments`,{method:"POST",body:{body:e.body}}))}catch(t){return he(t)}});ke.registerTool("figura_request_feedback",{title:"Figura: request feedback",description:"Ask a teammate to review a fig. Resolve `from` to a team member (by name or email); they get a notification (in-app, push, email) and the discussion happens in the fig's comment thread. Use this when the user says they want a specific person's feedback/eyes/review on a fig. Returns { ok, request: { to, status }, figUrl }.",inputSchema:{id:v.string().describe("The fig to request feedback on — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),from:v.string().describe("The teammate to ask, by name or email (resolved within the team)."),note:v.string().optional().describe("Optional message for them (e.g. what to look at).")}},async(e)=>{try{let t={from:e.from};if(e.note!==void 0)t.note=e.note;return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}/request-feedback`,{method:"POST",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_list_sources",{title:"Figura: list sources",description:"List the company-brain source-spine connectors for the team, with event counts and last-synced times.",inputSchema:{}},async()=>{try{return ve(await de("/v1/sources"))}catch(e){return he(e)}});ke.registerTool("figura_sync_source",{title:"Figura: sync source",description:"Ingest new events from a connected source into the spine. Returns { ingested, fetched, nextCursor }.",inputSchema:{id:v.string().describe("The source id to sync (from figura_list_sources).")}},async(e)=>{try{return ve(await de(`/v1/sources/${encodeURIComponent(e.id)}/sync`,{method:"POST"}))}catch(t){return he(t)}});ke.registerTool("figura_add_signal",{title:"Figura: add signal",description:"Put an external moment (a link, a news item, a discourse thread) on the company brain's radar. It skips the holding pen and becomes a `signal` event the story miner joins against the team's theses on the next sync. Give a url, a title, or both.",inputSchema:{url:v.string().url().optional().describe("Link to the moment."),title:v.string().max(300).optional().describe("One line on what the moment is; defaults to the link host + path."),excerpt:v.string().max(2000).optional().describe("Optional context the miner can quote.")}},async(e)=>{try{if(!e.url&&!e.title)return he(Error("Give a url or a title."));return ve(await de("/v1/signals",{method:"POST",body:{url:e.url??null,title:e.title??"",excerpt:e.excerpt??"",source:"mcp"}}))}catch(t){return he(t)}});ke.registerTool("figura_mine_screens",{title:"Figura: mine screens",description:"Build the app's screen catalog from a connected git source's CURRENT file tree (framework-aware, convention-based — no file bodies, no fig generation, no credits). Returns { screens: [{slug,name,path,framework}], framework, count, commitSha, truncated }.",inputSchema:{id:v.string().describe("The git source id to mine (from figura_list_sources).")}},async(e)=>{try{return ve(await de(`/v1/sources/${encodeURIComponent(e.id)}/mine-screens`,{method:"POST"}))}catch(t){return he(t)}});ke.registerTool("figura_list_screens",{title:"Figura: list screens",description:"Read the team's mined screen catalog — the app's current screens ({slug,name,path,framework}) plus when it was last mined. Free, read-only. Run figura_mine_screens first to populate it.",inputSchema:{}},async()=>{try{return ve(await de("/v1/sources/screens"))}catch(e){return he(e)}});ke.registerTool("figura_update_fig",{title:"Figura: update fig",description:"Update a fig's METADATA only (title/description/area/tags/status). Set status='archived' to soft-delete. For library membership (draft ⇄ published) prefer figura_commit_fig — a status PATCH here is a silent metadata setter that never notifies the team. To change the fig's HTML, use figura_revise_fig — it saves a new version and never destroys the old one. update cannot touch the HTML.",inputSchema:{id:v.string().describe("The fig to update — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),title:v.string().optional(),description:Uc(),area:Oo(),tags:v.array(v.string()).optional().describe("Replaces the existing tags."),status:v.enum(["draft","published","archived"]).optional(),outcome:v.string().optional().describe(`ONE line on how THIS round ended, for the chain's shortlist: what it won, and why it lost. Write it when a round is superseded or a chain lands — the chain page derives every other field it shows (versions, verdict tallies, the decision, who was asked) from rows, and this is the single judgement no event can hold. Terse and concrete ("widest-reading plate of the set; spent the cinematic signature"), max 400 chars. Send an empty string to clear it.`)}},async(e)=>{try{let t={};if(e.title!==void 0)t.title=e.title;if(e.outcome!==void 0)t.outcome=e.outcome;if(e.description!==void 0)t.description=e.description;if(e.area!==void 0)t.area=e.area;if(e.tags!==void 0)t.tags=e.tags;if(e.status!==void 0)t.status=e.status;return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}`,{method:"PATCH",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_delete_fig",{title:"Figura: archive fig",description:"Archive a fig — the only deletion available here. It leaves the library and its public link stops resolving, but the fig, its comments and its feedback requests are kept and can be restored. There is NO permanent delete on this surface: use this for superseded drafts and cleanup. A genuine erasure request is a human action in the web app, by the fig author or a team admin. Archiving a CHILD fig does NOT blank the figs embedding it — every pinned reference keeps rendering the exact version it names — but the child can no longer be referenced by a new composition; the response reports `embeddedBy`, how many figs hold a reference to it.",inputSchema:{id:v.string().describe("The fig to archive — its id (`fig_…`), a UUID, a share link/URL, or its publicId.")}},async(e)=>{try{return ve(await de(`/v1/figs/${encodeURIComponent(e.id)}`,{method:"DELETE"}))}catch(t){return he(t)}});(async()=>{let{apiUrl:e}=await qc();await eT(Ao,Mc,jc(e))})();oT();await ke.connect(new sf);
|
|
66
|
+
]`;continue}if(o+=n[c],n[c]==="\\")i=!0;else if(s&&n[c]==="]")s=!1;else if(!s&&n[c]==="[")s=!0}try{new RegExp(o)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return o}function Za(e,t){if(t.target==="openAi")console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead.");if(t.target==="openApi3"&&e.keyType?._def.typeName===z.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((n,o)=>({...n,[o]:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",o]})??Pe(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let r={type:"object",additionalProperties:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return r;if(e.keyType?._def.typeName===z.ZodString&&e.keyType._def.checks?.length){let{type:n,...o}=Fa(e.keyType._def,t);return{...r,propertyNames:o}}else if(e.keyType?._def.typeName===z.ZodEnum)return{...r,propertyNames:{enum:e.keyType._def.values}};else if(e.keyType?._def.typeName===z.ZodBranded&&e.keyType._def.type._def.typeName===z.ZodString&&e.keyType._def.type._def.checks?.length){let{type:n,...o}=Ua(e.keyType._def,t);return{...r,propertyNames:o}}return r}function Fb(e,t){if(t.mapStrategy==="record")return Za(e,t);let r=Z(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||Pe(t),n=Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||Pe(t);return{type:"array",maxItems:125,items:{type:"array",items:[r,n],minItems:2,maxItems:2}}}function Zb(e){let t=e.values,n=Object.keys(e.values).filter((i)=>typeof t[t[i]]!=="number").map((i)=>t[i]),o=Array.from(new Set(n.map((i)=>typeof i)));return{type:o.length===1?o[0]==="string"?"string":"number":["string","number"],enum:n}}function Bb(e){return e.target==="openAi"?void 0:{not:Pe({...e,currentPath:[...e.currentPath,"not"]})}}function Hb(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var Ci={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function Gb(e,t){if(t.target==="openApi3")return Vb(e,t);let r=e.options instanceof Map?Array.from(e.options.values()):e.options;if(r.every((n)=>(n._def.typeName in Ci)&&(!n._def.checks||!n._def.checks.length))){let n=r.reduce((o,i)=>{let s=Ci[i._def.typeName];return s&&!o.includes(s)?[...o,s]:o},[]);return{type:n.length>1?n:n[0]}}else if(r.every((n)=>n._def.typeName==="ZodLiteral"&&!n.description)){let n=r.reduce((o,i)=>{let s=typeof i._def.value;switch(s){case"string":case"number":case"boolean":return[...o,s];case"bigint":return[...o,"integer"];case"object":if(i._def.value===null)return[...o,"null"];case"symbol":case"undefined":case"function":default:return o}},[]);if(n.length===r.length){let o=n.filter((i,s,a)=>a.indexOf(i)===s);return{type:o.length>1?o:o[0],enum:r.reduce((i,s)=>i.includes(s._def.value)?i:[...i,s._def.value],[])}}}else if(r.every((n)=>n._def.typeName==="ZodEnum"))return{type:"string",enum:r.reduce((n,o)=>[...n,...o._def.values.filter((i)=>!n.includes(i))],[])};return Vb(e,t)}var Vb=(e,t)=>{let r=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((n,o)=>Z(n._def,{...t,currentPath:[...t.currentPath,"anyOf",`${o}`]})).filter((n)=>!!n&&(!t.strictUnions||typeof n==="object"&&Object.keys(n).length>0));return r.length?{anyOf:r}:void 0};function Jb(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length)){if(t.target==="openApi3")return{type:Ci[e.innerType._def.typeName],nullable:!0};return{type:[Ci[e.innerType._def.typeName],"null"]}}if(t.target==="openApi3"){let n=Z(e.innerType._def,{...t,currentPath:[...t.currentPath]});if(n&&"$ref"in n)return{allOf:[n],nullable:!0};return n&&{...n,nullable:!0}}let r=Z(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return r&&{anyOf:[r,{type:"null"}]}}function Wb(e,t){let r={type:"number"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"int":r.type="integer",Pd(r,"type",n.message,t);break;case"min":if(t.target==="jsonSchema7")if(n.inclusive)ne(r,"minimum",n.value,n.message,t);else ne(r,"exclusiveMinimum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMinimum=!0;ne(r,"minimum",n.value,n.message,t)}break;case"max":if(t.target==="jsonSchema7")if(n.inclusive)ne(r,"maximum",n.value,n.message,t);else ne(r,"exclusiveMaximum",n.value,n.message,t);else{if(!n.inclusive)r.exclusiveMaximum=!0;ne(r,"maximum",n.value,n.message,t)}break;case"multipleOf":ne(r,"multipleOf",n.value,n.message,t);break}return r}function Kb(e,t){let r=t.target==="openAi",n={type:"object",properties:{}},o=[],i=e.shape();for(let a in i){let c=i[a];if(c===void 0||c._def===void 0)continue;let u=UI(c);if(u&&r){if(c._def.typeName==="ZodOptional")c=c._def.innerType;if(!c.isNullable())c=c.nullable();u=!1}let l=Z(c._def,{...t,currentPath:[...t.currentPath,"properties",a],propertyPath:[...t.currentPath,"properties",a]});if(l===void 0)continue;if(n.properties[a]=l,!u)o.push(a)}if(o.length)n.required=o;let s=qI(e,t);if(s!==void 0)n.additionalProperties=s;return n}function qI(e,t){if(e.catchall._def.typeName!=="ZodNever")return Z(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function UI(e){try{return e.isOptional()}catch{return!0}}var Yb=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return Z(e.innerType._def,t);let r=Z(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return r?{anyOf:[{not:Pe(t)},r]}:Pe(t)};var Xb=(e,t)=>{if(t.pipeStrategy==="input")return Z(e.in._def,t);else if(t.pipeStrategy==="output")return Z(e.out._def,t);let r=Z(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),n=Z(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",r?"1":"0"]});return{allOf:[r,n].filter((o)=>o!==void 0)}};function Qb(e,t){return Z(e.type._def,t)}function e_(e,t){let n={type:"array",uniqueItems:!0,items:Z(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};if(e.minSize)ne(n,"minItems",e.minSize.value,e.minSize.message,t);if(e.maxSize)ne(n,"maxItems",e.maxSize.value,e.maxSize.message,t);return n}function t_(e,t){if(e.rest)return{type:"array",minItems:e.items.length,items:e.items.map((r,n)=>Z(r._def,{...t,currentPath:[...t.currentPath,"items",`${n}`]})).reduce((r,n)=>n===void 0?r:[...r,n],[]),additionalItems:Z(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})};else return{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((r,n)=>Z(r._def,{...t,currentPath:[...t.currentPath,"items",`${n}`]})).reduce((r,n)=>n===void 0?r:[...r,n],[])}}function r_(e){return{not:Pe(e)}}function n_(e){return Pe(e)}var o_=(e,t)=>Z(e.innerType._def,t);var i_=(e,t,r)=>{switch(t){case z.ZodString:return Fa(e,r);case z.ZodNumber:return Wb(e,r);case z.ZodObject:return Kb(e,r);case z.ZodBigInt:return Cb(e,r);case z.ZodBoolean:return Ib();case z.ZodDate:return zd(e,r);case z.ZodUndefined:return r_(r);case z.ZodNull:return Hb(r);case z.ZodArray:return Ab(e,r);case z.ZodUnion:case z.ZodDiscriminatedUnion:return Gb(e,r);case z.ZodIntersection:return Lb(e,r);case z.ZodTuple:return t_(e,r);case z.ZodRecord:return Za(e,r);case z.ZodLiteral:return qb(e,r);case z.ZodEnum:return Mb(e);case z.ZodNativeEnum:return Zb(e);case z.ZodNullable:return Jb(e,r);case z.ZodOptional:return Yb(e,r);case z.ZodMap:return Fb(e,r);case z.ZodSet:return e_(e,r);case z.ZodLazy:return()=>e.getter()._def;case z.ZodPromise:return Qb(e,r);case z.ZodNaN:case z.ZodNever:return Bb(r);case z.ZodEffects:return Db(e,r);case z.ZodAny:return Pe(r);case z.ZodUnknown:return n_(r);case z.ZodDefault:return Nb(e,r);case z.ZodBranded:return Ua(e,r);case z.ZodReadonly:return o_(e,r);case z.ZodCatch:return jb(e,r);case z.ZodPipeline:return Xb(e,r);case z.ZodFunction:case z.ZodVoid:case z.ZodSymbol:return;default:return((n)=>{return})(t)}};function Z(e,t,r=!1){let n=t.seen.get(e);if(t.override){let a=t.override?.(e,t,n,r);if(a!==Pb)return a}if(n&&!r){let a=FI(n,t);if(a!==void 0)return a}let o={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,o);let i=i_(e,e.typeName,t),s=typeof i==="function"?Z(i(),t):i;if(s)ZI(e,t,s);if(t.postProcess){let a=t.postProcess(s,e,t);return o.jsonSchema=s,a}return o.jsonSchema=s,s}var FI=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:qa(t.currentPath,e.path)};case"none":case"seen":{if(e.path.length<t.currentPath.length&&e.path.every((r,n)=>t.currentPath[n]===r))return console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),Pe(t);return t.$refStrategy==="seen"?Pe(t):void 0}}},ZI=(e,t,r)=>{if(e.description){if(r.description=e.description,t.markdownDescription)r.markdownDescription=e.description}return r};var Cd=(e,t)=>{let r=Ob(t),n=typeof t==="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[u,l])=>({...c,[u]:Z(l._def,{...r,currentPath:[...r.basePath,r.definitionPath,u]},!0)??Pe(r)}),{}):void 0,o=typeof t==="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=Z(e._def,o===void 0?r:{...r,currentPath:[...r.basePath,r.definitionPath,o]},!1)??Pe(r),s=typeof t==="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;if(s!==void 0)i.title=s;if(r.flags.hasReferencedOpenAiAnyType){if(!n)n={};if(!n[r.openAiAnyTypeName])n[r.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:r.$refStrategy==="relative"?"1":[...r.basePath,r.definitionPath,r.openAiAnyTypeName].join("/")}}}let a=o===void 0?n?{...i,[r.definitionPath]:n}:i:{$ref:[...r.$refStrategy==="relative"?[]:r.basePath,r.definitionPath,o].join("/"),[r.definitionPath]:{...n,[o]:i}};if(r.target==="jsonSchema7")a.$schema="http://json-schema.org/draft-07/schema#";else if(r.target==="jsonSchema2019-09"||r.target==="openAi")a.$schema="https://json-schema.org/draft/2019-09/schema#";if(r.target==="openAi"&&(("anyOf"in a)||("oneOf"in a)||("allOf"in a)||("type"in a)&&Array.isArray(a.type)))console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property.");return a};function BI(e){if(!e)return"draft-7";if(e==="jsonSchema7"||e==="draft-7")return"draft-7";if(e==="jsonSchema2019-09"||e==="draft-2020-12")return"draft-2020-12";return"draft-7"}function Id(e,t){if(Nt(e))return id(e,{target:BI(t?.target),io:t?.pipeStrategy??"input"});return Cd(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function jd(e){let r=Ir(e)?.method;if(!r)throw Error("Schema is missing a method literal");let n=ga(r);if(typeof n!=="string")throw Error("Schema method literal must be a string");return n}function Nd(e,t){let r=Cr(e,t);if(!r.success)throw r.error;return r.data}var HI=60000;class Dd{constructor(e){if(this._options=e,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(ka,(t)=>{this._oncancel(t)}),this.setNotificationHandler($a,(t)=>{this._onprogress(t)}),this.setRequestHandler(Sa,(t)=>({})),this._taskStore=e?.taskStore,this._taskMessageQueue=e?.taskMessageQueue,this._taskStore)this.setRequestHandler(Ta,async(t,r)=>{let n=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!n)throw new M(U.InvalidParams,"Failed to retrieve task: Task not found");return{...n}}),this.setRequestHandler(Ra,async(t,r)=>{let n=async()=>{let o=t.params.taskId;if(this._taskMessageQueue){let s;while(s=await this._taskMessageQueue.dequeue(o,r.sessionId)){if(s.type==="response"||s.type==="error"){let a=s.message,c=a.id,u=this._requestResolvers.get(c);if(u)if(this._requestResolvers.delete(c),s.type==="response")u(a);else{let l=a,p=new M(l.error.code,l.error.message,l.error.data);u(p)}else{let l=s.type==="response"?"Response":"Error";this._onerror(Error(`${l} handler missing for request ${c}`))}continue}await this._transport?.send(s.message,{relatedRequestId:r.requestId})}}let i=await this._taskStore.getTask(o,r.sessionId);if(!i)throw new M(U.InvalidParams,`Task not found: ${o}`);if(!Nr(i.status))return await this._waitForTaskUpdate(o,r.signal),await n();if(Nr(i.status)){let s=await this._taskStore.getTaskResult(o,r.sessionId);return this._clearTaskQueue(o),{...s,_meta:{...s._meta,[jr]:{taskId:o}}}}return await n()};return await n()}),this.setRequestHandler(Pa,async(t,r)=>{try{let{tasks:n,nextCursor:o}=await this._taskStore.listTasks(t.params?.cursor,r.sessionId);return{tasks:n,nextCursor:o,_meta:{}}}catch(n){throw new M(U.InvalidParams,`Failed to list tasks: ${n instanceof Error?n.message:String(n)}`)}}),this.setRequestHandler(Oa,async(t,r)=>{try{let n=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!n)throw new M(U.InvalidParams,`Task not found: ${t.params.taskId}`);if(Nr(n.status))throw new M(U.InvalidParams,`Cannot cancel task in terminal status: ${n.status}`);await this._taskStore.updateTaskStatus(t.params.taskId,"cancelled","Client cancelled task execution.",r.sessionId),this._clearTaskQueue(t.params.taskId);let o=await this._taskStore.getTask(t.params.taskId,r.sessionId);if(!o)throw new M(U.InvalidParams,`Task not found after cancellation: ${t.params.taskId}`);return{_meta:{},...o}}catch(n){if(n instanceof M)throw n;throw new M(U.InvalidRequest,`Failed to cancel task: ${n instanceof Error?n.message:String(n)}`)}})}async _oncancel(e){if(!e.params.requestId)return;this._requestHandlerAbortControllers.get(e.params.requestId)?.abort(e.params.reason)}_setupTimeout(e,t,r,n,o=!1){this._timeoutInfo.set(e,{timeoutId:setTimeout(n,t),startTime:Date.now(),timeout:t,maxTotalTimeout:r,resetTimeoutOnProgress:o,onTimeout:n})}_resetTimeout(e){let t=this._timeoutInfo.get(e);if(!t)return!1;let r=Date.now()-t.startTime;if(t.maxTotalTimeout&&r>=t.maxTotalTimeout)throw this._timeoutInfo.delete(e),M.fromError(U.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:t.maxTotalTimeout,totalElapsed:r});return clearTimeout(t.timeoutId),t.timeoutId=setTimeout(t.onTimeout,t.timeout),!0}_cleanupTimeout(e){let t=this._timeoutInfo.get(e);if(t)clearTimeout(t.timeoutId),this._timeoutInfo.delete(e)}async connect(e){if(this._transport)throw Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=e;let t=this.transport?.onclose;this._transport.onclose=()=>{t?.(),this._onclose()};let r=this.transport?.onerror;this._transport.onerror=(o)=>{r?.(o),this._onerror(o)};let n=this._transport?.onmessage;this._transport.onmessage=(o,i)=>{if(n?.(o,i),Si(o)||gb(o))this._onresponse(o);else if(hd(o))this._onrequest(o,i);else if(hb(o))this._onnotification(o);else this._onerror(Error(`Unknown message type: ${JSON.stringify(o)}`))},await this._transport.start()}_onclose(){let e=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let r of this._timeoutInfo.values())clearTimeout(r.timeoutId);this._timeoutInfo.clear();for(let r of this._requestHandlerAbortControllers.values())r.abort();this._requestHandlerAbortControllers.clear();let t=M.fromError(U.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let r of e.values())r(t)}_onerror(e){this.onerror?.(e)}_onnotification(e){let t=this._notificationHandlers.get(e.method)??this.fallbackNotificationHandler;if(t===void 0)return;Promise.resolve().then(()=>t(e)).catch((r)=>this._onerror(Error(`Uncaught error in notification handler: ${r}`)))}_onrequest(e,t){let r=this._requestHandlers.get(e.method)??this.fallbackRequestHandler,n=this._transport,o=e.params?._meta?.[jr]?.taskId;if(r===void 0){let u={jsonrpc:"2.0",id:e.id,error:{code:U.MethodNotFound,message:"Method not found"}};if(o&&this._taskMessageQueue)this._enqueueTaskMessage(o,{type:"error",message:u,timestamp:Date.now()},n?.sessionId).catch((l)=>this._onerror(Error(`Failed to enqueue error response: ${l}`)));else n?.send(u).catch((l)=>this._onerror(Error(`Failed to send an error response: ${l}`)));return}let i=new AbortController;this._requestHandlerAbortControllers.set(e.id,i);let s=db(e.params)?e.params.task:void 0,a=this._taskStore?this.requestTaskStore(e,n?.sessionId):void 0,c={signal:i.signal,sessionId:n?.sessionId,_meta:e.params?._meta,sendNotification:async(u)=>{if(i.signal.aborted)return;let l={relatedRequestId:e.id};if(o)l.relatedTask={taskId:o};await this.notification(u,l)},sendRequest:async(u,l,p)=>{if(i.signal.aborted)throw new M(U.ConnectionClosed,"Request was cancelled");let m={...p,relatedRequestId:e.id};if(o&&!m.relatedTask)m.relatedTask={taskId:o};let d=m.relatedTask?.taskId??o;if(d&&a)await a.updateTaskStatus(d,"input_required");return await this.request(u,l,m)},authInfo:t?.authInfo,requestId:e.id,requestInfo:t?.requestInfo,taskId:o,taskStore:a,taskRequestedTtl:s?.ttl,closeSSEStream:t?.closeSSEStream,closeStandaloneSSEStream:t?.closeStandaloneSSEStream};Promise.resolve().then(()=>{if(s)this.assertTaskHandlerCapability(e.method)}).then(()=>r(e,c)).then(async(u)=>{if(i.signal.aborted)return;let l={result:u,jsonrpc:"2.0",id:e.id};if(o&&this._taskMessageQueue)await this._enqueueTaskMessage(o,{type:"response",message:l,timestamp:Date.now()},n?.sessionId);else await n?.send(l)},async(u)=>{if(i.signal.aborted)return;let l={jsonrpc:"2.0",id:e.id,error:{code:Number.isSafeInteger(u.code)?u.code:U.InternalError,message:u.message??"Internal error",...u.data!==void 0&&{data:u.data}}};if(o&&this._taskMessageQueue)await this._enqueueTaskMessage(o,{type:"error",message:l,timestamp:Date.now()},n?.sessionId);else await n?.send(l)}).catch((u)=>this._onerror(Error(`Failed to send response: ${u}`))).finally(()=>{if(this._requestHandlerAbortControllers.get(e.id)===i)this._requestHandlerAbortControllers.delete(e.id)})}_onprogress(e){let{progressToken:t,...r}=e.params,n=Number(t),o=this._progressHandlers.get(n);if(!o){this._onerror(Error(`Received a progress notification for an unknown token: ${JSON.stringify(e)}`));return}let i=this._responseHandlers.get(n),s=this._timeoutInfo.get(n);if(s&&i&&s.resetTimeoutOnProgress)try{this._resetTimeout(n)}catch(a){this._responseHandlers.delete(n),this._progressHandlers.delete(n),this._cleanupTimeout(n),i(a);return}o(r)}_onresponse(e){let t=Number(e.id),r=this._requestResolvers.get(t);if(r){if(this._requestResolvers.delete(t),Si(e))r(e);else{let i=new M(e.error.code,e.error.message,e.error.data);r(i)}return}let n=this._responseHandlers.get(t);if(n===void 0){this._onerror(Error(`Received a response for an unknown message ID: ${JSON.stringify(e)}`));return}this._responseHandlers.delete(t),this._cleanupTimeout(t);let o=!1;if(Si(e)&&e.result&&typeof e.result==="object"){let i=e.result;if(i.task&&typeof i.task==="object"){let s=i.task;if(typeof s.taskId==="string")o=!0,this._taskProgressTokens.set(s.taskId,t)}}if(!o)this._progressHandlers.delete(t);if(Si(e))n(e);else{let i=M.fromError(e.error.code,e.error.message,e.error.data);n(i)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(e,t,r){let{task:n}=r??{};if(!n){try{yield{type:"result",result:await this.request(e,t,r)}}catch(i){yield{type:"error",error:i instanceof M?i:new M(U.InternalError,String(i))}}return}let o;try{let i=await this.request(e,to,r);if(i.task)o=i.task.taskId,yield{type:"taskCreated",task:i.task};else throw new M(U.InternalError,"Task creation did not return a task");while(!0){let s=await this.getTask({taskId:o},r);if(yield{type:"taskStatus",task:s},Nr(s.status)){if(s.status==="completed")yield{type:"result",result:await this.getTaskResult({taskId:o},t,r)};else if(s.status==="failed")yield{type:"error",error:new M(U.InternalError,`Task ${o} failed`)};else if(s.status==="cancelled")yield{type:"error",error:new M(U.InternalError,`Task ${o} was cancelled`)};return}if(s.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:o},t,r)};return}let a=s.pollInterval??this._options?.defaultTaskPollInterval??1000;await new Promise((c)=>setTimeout(c,a)),r?.signal?.throwIfAborted()}}catch(i){yield{type:"error",error:i instanceof M?i:new M(U.InternalError,String(i))}}}request(e,t,r){let{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i,task:s,relatedTask:a}=r??{};return new Promise((c,u)=>{let l=(g)=>{u(g)};if(!this._transport){l(Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{if(this.assertCapabilityForMethod(e.method),s)this.assertTaskCapability(e.method)}catch(g){l(g);return}r?.signal?.throwIfAborted();let p=this._requestMessageId++,m={...e,jsonrpc:"2.0",id:p};if(r?.onprogress)this._progressHandlers.set(p,r.onprogress),m.params={...e.params,_meta:{...e.params?._meta||{},progressToken:p}};if(s)m.params={...m.params,task:s};if(a)m.params={...m.params,_meta:{...m.params?._meta||{},[jr]:a}};let d=(g)=>{this._responseHandlers.delete(p),this._progressHandlers.delete(p),this._cleanupTimeout(p),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:p,reason:String(g)}},{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i}).catch((w)=>this._onerror(Error(`Failed to send cancellation: ${w}`)));let y=g instanceof M?g:new M(U.RequestTimeout,String(g));u(y)};this._responseHandlers.set(p,(g)=>{if(r?.signal?.aborted)return;if(g instanceof Error)return u(g);try{let y=Cr(t,g.result);if(!y.success)u(y.error);else c(y.data)}catch(y){u(y)}}),r?.signal?.addEventListener("abort",()=>{d(r?.signal?.reason)});let h=r?.timeout??HI,x=()=>d(M.fromError(U.RequestTimeout,"Request timed out",{timeout:h}));this._setupTimeout(p,h,r?.maxTotalTimeout,x,r?.resetTimeoutOnProgress??!1);let v=a?.taskId;if(v){let g=(y)=>{let w=this._responseHandlers.get(p);if(w)w(y);else this._onerror(Error(`Response handler missing for side-channeled request ${p}`))};this._requestResolvers.set(p,g),this._enqueueTaskMessage(v,{type:"request",message:m,timestamp:Date.now()}).catch((y)=>{this._cleanupTimeout(p),u(y)})}else this._transport.send(m,{relatedRequestId:n,resumptionToken:o,onresumptiontoken:i}).catch((g)=>{this._cleanupTimeout(p),u(g)})})}async getTask(e,t){return this.request({method:"tasks/get",params:e},Ea,t)}async getTaskResult(e,t,r){return this.request({method:"tasks/result",params:e},t,r)}async listTasks(e,t){return this.request({method:"tasks/list",params:e},za,t)}async cancelTask(e,t){return this.request({method:"tasks/cancel",params:e},yb,t)}async notification(e,t){if(!this._transport)throw Error("Not connected");this.assertNotificationCapability(e.method);let r=t?.relatedTask?.taskId;if(r){let s={...e,jsonrpc:"2.0",params:{...e.params,_meta:{...e.params?._meta||{},[jr]:t.relatedTask}}};await this._enqueueTaskMessage(r,{type:"notification",message:s,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(e.method)&&!e.params&&!t?.relatedRequestId&&!t?.relatedTask){if(this._pendingDebouncedNotifications.has(e.method))return;this._pendingDebouncedNotifications.add(e.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(e.method),!this._transport)return;let s={...e,jsonrpc:"2.0"};if(t?.relatedTask)s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[jr]:t.relatedTask}}};this._transport?.send(s,t).catch((a)=>this._onerror(a))});return}let i={...e,jsonrpc:"2.0"};if(t?.relatedTask)i={...i,params:{...i.params,_meta:{...i.params?._meta||{},[jr]:t.relatedTask}}};await this._transport.send(i,t)}setRequestHandler(e,t){let r=jd(e);this.assertRequestHandlerCapability(r),this._requestHandlers.set(r,(n,o)=>{let i=Nd(e,n);return Promise.resolve(t(i,o))})}removeRequestHandler(e){this._requestHandlers.delete(e)}assertCanSetRequestHandler(e){if(this._requestHandlers.has(e))throw Error(`A request handler for ${e} already exists, which would be overridden`)}setNotificationHandler(e,t){let r=jd(e);this._notificationHandlers.set(r,(n)=>{let o=Nd(e,n);return Promise.resolve(t(o))})}removeNotificationHandler(e){this._notificationHandlers.delete(e)}_cleanupTaskProgressHandler(e){let t=this._taskProgressTokens.get(e);if(t!==void 0)this._progressHandlers.delete(t),this._taskProgressTokens.delete(e)}async _enqueueTaskMessage(e,t,r){if(!this._taskStore||!this._taskMessageQueue)throw Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let n=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(e,t,r,n)}async _clearTaskQueue(e,t){if(this._taskMessageQueue){let r=await this._taskMessageQueue.dequeueAll(e,t);for(let n of r)if(n.type==="request"&&hd(n.message)){let o=n.message.id,i=this._requestResolvers.get(o);if(i)i(new M(U.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(o);else this._onerror(Error(`Resolver missing for request ${o} during task ${e} cleanup`))}}}async _waitForTaskUpdate(e,t){let r=this._options?.defaultTaskPollInterval??1000;try{let n=await this._taskStore?.getTask(e);if(n?.pollInterval)r=n.pollInterval}catch{}return new Promise((n,o)=>{if(t.aborted){o(new M(U.InvalidRequest,"Request cancelled"));return}let i=setTimeout(n,r);t.addEventListener("abort",()=>{clearTimeout(i),o(new M(U.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(e,t){let r=this._taskStore;if(!r)throw Error("No task store configured");return{createTask:async(n)=>{if(!e)throw Error("No request provided");return await r.createTask(n,e.id,{method:e.method,params:e.params},t)},getTask:async(n)=>{let o=await r.getTask(n,t);if(!o)throw new M(U.InvalidParams,"Failed to retrieve task: Task not found");return o},storeTaskResult:async(n,o,i)=>{await r.storeTaskResult(n,o,i,t);let s=await r.getTask(n,t);if(s){let a=Pi.parse({method:"notifications/tasks/status",params:s});if(await this.notification(a),Nr(s.status))this._cleanupTaskProgressHandler(n)}},getTaskResult:(n)=>r.getTaskResult(n,t),updateTaskStatus:async(n,o,i)=>{let s=await r.getTask(n,t);if(!s)throw new M(U.InvalidParams,`Task "${n}" not found - it may have been cleaned up`);if(Nr(s.status))throw new M(U.InvalidParams,`Cannot update task "${n}" from terminal status "${s.status}" to "${o}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await r.updateTaskStatus(n,o,i,t);let a=await r.getTask(n,t);if(a){let c=Pi.parse({method:"notifications/tasks/status",params:a});if(await this.notification(c),Nr(a.status))this._cleanupTaskProgressHandler(n)}},listTasks:(n)=>r.listTasks(n,t)}}}function s_(e){return e!==null&&typeof e==="object"&&!Array.isArray(e)}function a_(e,t){let r={...e};for(let n in t){let o=n,i=t[o];if(i===void 0)continue;let s=r[o];if(s_(s)&&s_(i))r[o]={...s,...i};else r[o]=i}return r}var ZS=So(Am(),1),BS=So(FS(),1);function mF(){let e=new ZS.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return BS.default(e),e}class Fm{constructor(e){this._ajv=e??mF()}getValidator(e){let t="$id"in e&&typeof e.$id==="string"?this._ajv.getSchema(e.$id)??this._ajv.compile(e):this._ajv.compile(e);return(r)=>{if(t(r))return{valid:!0,data:r,errorMessage:void 0};else return{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(t.errors)}}}}class Zm{constructor(e){this._server=e}requestStream(e,t,r){return this._server.requestStream(e,t,r)}createMessageStream(e,t){let r=this._server.getClientCapabilities();if((e.tools||e.toolChoice)&&!r?.sampling?.tools)throw Error("Client does not support sampling tools capability.");if(e.messages.length>0){let n=e.messages[e.messages.length-1],o=Array.isArray(n.content)?n.content:[n.content],i=o.some((u)=>u.type==="tool_result"),s=e.messages.length>1?e.messages[e.messages.length-2]:void 0,a=s?Array.isArray(s.content)?s.content:[s.content]:[],c=a.some((u)=>u.type==="tool_use");if(i){if(o.some((u)=>u.type!=="tool_result"))throw Error("The last message must contain only tool_result content if any is present");if(!c)throw Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let u=new Set(a.filter((p)=>p.type==="tool_use").map((p)=>p.id)),l=new Set(o.filter((p)=>p.type==="tool_result").map((p)=>p.toolUseId));if(u.size!==l.size||![...u].every((p)=>l.has(p)))throw Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return this.requestStream({method:"sampling/createMessage",params:e},Ai,t)}elicitInputStream(e,t){let r=this._server.getClientCapabilities(),n=e.mode??"form";switch(n){case"url":{if(!r?.elicitation?.url)throw Error("Client does not support url elicitation.");break}case"form":{if(!r?.elicitation?.form)throw Error("Client does not support form elicitation.");break}}let o=n==="form"&&e.mode===void 0?{...e,mode:"form"}:e;return this.requestStream({method:"elicitation/create",params:o},oo,t)}async getTask(e,t){return this._server.getTask({taskId:e},t)}async getTaskResult(e,t,r){return this._server.getTaskResult({taskId:e},t,r)}async listTasks(e,t){return this._server.listTasks(e?{cursor:e}:void 0,t)}async cancelTask(e,t){return this._server.cancelTask({taskId:e},t)}}function HS(e,t,r){if(!e)throw Error(`${r} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw Error(`${r} does not support task creation for tools/call (required for ${t})`);break;default:break}}function VS(e,t,r){if(!e)throw Error(`${r} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw Error(`${r} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw Error(`${r} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}class Bm extends Dd{constructor(e,t){super(t);if(this._serverInfo=e,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(Oi.options.map((r,n)=>[r,n])),this.isMessageIgnored=(r,n)=>{let o=this._loggingLevels.get(n);return o?this.LOG_LEVEL_SEVERITY.get(r)<this.LOG_LEVEL_SEVERITY.get(o):!1},this._capabilities=t?.capabilities??{},this._instructions=t?.instructions,this._jsonSchemaValidator=t?.jsonSchemaValidator??new Fm,this.setRequestHandler(vd,(r)=>this._oninitialize(r)),this.setNotificationHandler(yd,()=>this.oninitialized?.()),this._capabilities.logging)this.setRequestHandler(Td,async(r,n)=>{let o=n.sessionId||n.requestInfo?.headers["mcp-session-id"]||void 0,{level:i}=r.params,s=Oi.safeParse(i);if(s.success)this._loggingLevels.set(o,s.data);return{}})}get experimental(){if(!this._experimental)this._experimental={tasks:new Zm(this)};return this._experimental}registerCapabilities(e){if(this.transport)throw Error("Cannot register capabilities after connecting to transport");this._capabilities=a_(this._capabilities,e)}setRequestHandler(e,t){let n=Ir(e)?.method;if(!n)throw Error("Schema is missing a method literal");let o;if(Nt(n)){let s=n;o=s._zod?.def?.value??s.value}else{let s=n;o=s._def?.value??s.value}if(typeof o!=="string")throw Error("Schema method literal must be a string");if(o==="tools/call"){let s=async(a,c)=>{let u=Cr(no,a);if(!u.success){let d=u.error instanceof Error?u.error.message:String(u.error);throw new M(U.InvalidParams,`Invalid tools/call request: ${d}`)}let{params:l}=u.data,p=await Promise.resolve(t(a,c));if(l.task){let d=Cr(to,p);if(!d.success){let h=d.error instanceof Error?d.error.message:String(d.error);throw new M(U.InvalidParams,`Invalid task creation result: ${h}`)}return d.data}let m=Cr(Ma,p);if(!m.success){let d=m.error instanceof Error?m.error.message:String(m.error);throw new M(U.InvalidParams,`Invalid tools/call result: ${d}`)}return m.data};return super.setRequestHandler(e,s)}return super.setRequestHandler(e,t)}assertCapabilityForMethod(e){switch(e){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw Error(`Client does not support sampling (required for ${e})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw Error(`Client does not support elicitation (required for ${e})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw Error(`Client does not support listing roots (required for ${e})`);break;case"ping":break}}assertNotificationCapability(e){switch(e){case"notifications/message":if(!this._capabilities.logging)throw Error(`Server does not support logging (required for ${e})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw Error(`Server does not support notifying about resources (required for ${e})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw Error(`Server does not support notifying of tool list changes (required for ${e})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw Error(`Server does not support notifying of prompt list changes (required for ${e})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw Error(`Client does not support URL elicitation (required for ${e})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(e){if(!this._capabilities)return;switch(e){case"completion/complete":if(!this._capabilities.completions)throw Error(`Server does not support completions (required for ${e})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw Error(`Server does not support logging (required for ${e})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw Error(`Server does not support prompts (required for ${e})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw Error(`Server does not support resources (required for ${e})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw Error(`Server does not support tools (required for ${e})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw Error(`Server does not support tasks capability (required for ${e})`);break;case"ping":case"initialize":break}}assertTaskCapability(e){VS(this._clientCapabilities?.tasks?.requests,e,"Client")}assertTaskHandlerCapability(e){if(!this._capabilities)return;HS(this._capabilities.tasks?.requests,e,"Server")}async _oninitialize(e){let t=e.params.protocolVersion;return this._clientCapabilities=e.params.capabilities,this._clientVersion=e.params.clientInfo,{protocolVersion:ub.includes(t)?t:md,capabilities:this.getCapabilities(),serverInfo:this._serverInfo,...this._instructions&&{instructions:this._instructions}}}getClientCapabilities(){return this._clientCapabilities}getClientVersion(){return this._clientVersion}getCapabilities(){return this._capabilities}async ping(){return this.request({method:"ping"},wa)}async createMessage(e,t){if(e.tools||e.toolChoice){if(!this._clientCapabilities?.sampling?.tools)throw Error("Client does not support sampling tools capability.")}if(e.messages.length>0){let r=e.messages[e.messages.length-1],n=Array.isArray(r.content)?r.content:[r.content],o=n.some((c)=>c.type==="tool_result"),i=e.messages.length>1?e.messages[e.messages.length-2]:void 0,s=i?Array.isArray(i.content)?i.content:[i.content]:[],a=s.some((c)=>c.type==="tool_use");if(o){if(n.some((c)=>c.type!=="tool_result"))throw Error("The last message must contain only tool_result content if any is present");if(!a)throw Error("tool_result blocks are not matching any tool_use from the previous message")}if(a){let c=new Set(s.filter((l)=>l.type==="tool_use").map((l)=>l.id)),u=new Set(n.filter((l)=>l.type==="tool_result").map((l)=>l.toolUseId));if(c.size!==u.size||![...c].every((l)=>u.has(l)))throw Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}if(e.tools)return this.request({method:"sampling/createMessage",params:e},Ed,t);return this.request({method:"sampling/createMessage",params:e},Ai,t)}async elicitInput(e,t){switch(e.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw Error("Client does not support url elicitation.");let n=e;return this.request({method:"elicitation/create",params:n},oo,t)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw Error("Client does not support form elicitation.");let n=e.mode==="form"?e:{...e,mode:"form"},o=await this.request({method:"elicitation/create",params:n},oo,t);if(o.action==="accept"&&o.content&&n.requestedSchema)try{let s=this._jsonSchemaValidator.getValidator(n.requestedSchema)(o.content);if(!s.valid)throw new M(U.InvalidParams,`Elicitation response content does not match requested schema: ${s.errorMessage}`)}catch(i){if(i instanceof M)throw i;throw new M(U.InternalError,`Error validating elicitation response: ${i instanceof Error?i.message:String(i)}`)}return o}}}createElicitationCompletionNotifier(e,t){if(!this._clientCapabilities?.elicitation?.url)throw Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:e}},t)}async listRoots(e,t){return this.request({method:"roots/list",params:e},Rd,t)}async sendLoggingMessage(e,t){if(this._capabilities.logging){if(!this.isMessageIgnored(e.level,t))return this.notification({method:"notifications/message",params:e})}}async sendResourceUpdated(e){return this.notification({method:"notifications/resources/updated",params:e})}async sendResourceListChanged(){return this.notification({method:"notifications/resources/list_changed"})}async sendToolListChanged(){return this.notification({method:"notifications/tools/list_changed"})}async sendPromptListChanged(){return this.notification({method:"notifications/prompts/list_changed"})}}var JS=Symbol.for("mcp.completable");function Hm(e){return!!e&&typeof e==="object"&&JS in e}function WS(e){return e[JS]?.complete}var GS;(function(e){e.Completable="McpCompletable"})(GS||(GS={}));var fF=/^[A-Za-z0-9._-]{1,128}$/;function hF(e){let t=[];if(e.length===0)return{isValid:!1,warnings:["Tool name cannot be empty"]};if(e.length>128)return{isValid:!1,warnings:[`Tool name exceeds maximum length of 128 characters (current: ${e.length})`]};if(e.includes(" "))t.push("Tool name contains spaces, which may cause parsing issues");if(e.includes(","))t.push("Tool name contains commas, which may cause parsing issues");if(e.startsWith("-")||e.endsWith("-"))t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts");if(e.startsWith(".")||e.endsWith("."))t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts");if(!fF.test(e)){let r=e.split("").filter((n)=>!/[A-Za-z0-9._-]/.test(n)).filter((n,o,i)=>i.indexOf(n)===o);return t.push(`Tool name contains invalid characters: ${r.map((n)=>`"${n}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function gF(e,t){if(t.length>0){console.warn(`Tool name validation warning for "${e}":`);for(let r of t)console.warn(` - ${r}`);console.warn("Tool registration will proceed, but this may cause compatibility issues."),console.warn("Consider updating the tool name to conform to the MCP tool naming standard."),console.warn("See SEP: Specify Format for Tool Names (https://github.com/modelcontextprotocol/modelcontextprotocol/issues/986) for more details.")}}function Vm(e){let t=hF(e);return gF(e,t.warnings),t.isValid}class Gm{constructor(e){this._mcpServer=e}registerToolTask(e,t,r){let n={taskSupport:"required",...t.execution};if(n.taskSupport==="forbidden")throw Error(`Cannot register task-based tool '${e}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(e,t.title,t.description,t.inputSchema,t.outputSchema,t.annotations,n,t._meta,r)}}class Wm{constructor(e,t){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new Bm(e,t)}get experimental(){if(!this._experimental)this._experimental={tasks:new Gm(this)};return this._experimental}async connect(e){return await this.server.connect(e)}async close(){await this.server.close()}setToolRequestHandlers(){if(this._toolHandlersInitialized)return;this.server.assertCanSetRequestHandler(Br(Da)),this.server.assertCanSetRequestHandler(Br(no)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(Da,()=>({tools:Object.entries(this._registeredTools).filter(([,e])=>e.enabled).map(([e,t])=>{let r={name:e,title:t.title,description:t.description,inputSchema:(()=>{let n=Qn(t.inputSchema);return n?Id(n,{strictUnions:!0,pipeStrategy:"input"}):vF})(),annotations:t.annotations,execution:t.execution,_meta:t._meta};if(t.outputSchema){let n=Qn(t.outputSchema);if(n)r.outputSchema=Id(n,{strictUnions:!0,pipeStrategy:"output"})}return r})})),this.server.setRequestHandler(no,async(e,t)=>{try{let r=this._registeredTools[e.params.name];if(!r)throw new M(U.InvalidParams,`Tool ${e.params.name} not found`);if(!r.enabled)throw new M(U.InvalidParams,`Tool ${e.params.name} disabled`);let n=!!e.params.task,o=r.execution?.taskSupport,i="createTask"in r.handler;if((o==="required"||o==="optional")&&!i)throw new M(U.InternalError,`Tool ${e.params.name} has taskSupport '${o}' but was not registered with registerToolTask`);if(o==="required"&&!n)throw new M(U.MethodNotFound,`Tool ${e.params.name} requires task augmentation (taskSupport: 'required')`);if(o==="optional"&&!n&&i)return await this.handleAutomaticTaskPolling(r,e,t);let s=await this.validateToolInput(r,e.params.arguments,e.params.name),a=await this.executeToolHandler(r,s,t);if(n)return a;return await this.validateToolOutput(r,a,e.params.name),a}catch(r){if(r instanceof M){if(r.code===U.UrlElicitationRequired)throw r}return this.createToolError(r instanceof Error?r.message:String(r))}}),this._toolHandlersInitialized=!0}createToolError(e){return{content:[{type:"text",text:e}],isError:!0}}async validateToolInput(e,t,r){if(!e.inputSchema)return;let o=Qn(e.inputSchema)??e.inputSchema,i=await fa(o,t);if(!i.success){let s="error"in i?i.error:"Unknown error",a=ha(s);throw new M(U.InvalidParams,`Input validation error: Invalid arguments for tool ${r}: ${a}`)}return i.data}async validateToolOutput(e,t,r){if(!e.outputSchema)return;if(!("content"in t))return;if(t.isError)return;if(!t.structuredContent)throw new M(U.InvalidParams,`Output validation error: Tool ${r} has an output schema but no structured content was provided`);let n=Qn(e.outputSchema),o=await fa(n,t.structuredContent);if(!o.success){let i="error"in o?o.error:"Unknown error",s=ha(i);throw new M(U.InvalidParams,`Output validation error: Invalid structured content for tool ${r}: ${s}`)}}async executeToolHandler(e,t,r){let n=e.handler;if("createTask"in n){if(!r.taskStore)throw Error("No task store provided.");let i={...r,taskStore:r.taskStore};if(e.inputSchema)return await Promise.resolve(n.createTask(t,i));else return await Promise.resolve(n.createTask(i))}if(e.inputSchema)return await Promise.resolve(n(t,r));else return await Promise.resolve(n(r))}async handleAutomaticTaskPolling(e,t,r){if(!r.taskStore)throw Error("No task store provided for task-capable tool.");let n=await this.validateToolInput(e,t.params.arguments,t.params.name),o=e.handler,i={...r,taskStore:r.taskStore},s=n?await Promise.resolve(o.createTask(n,i)):await Promise.resolve(o.createTask(i)),a=s.task.taskId,c=s.task,u=c.pollInterval??5000;while(c.status!=="completed"&&c.status!=="failed"&&c.status!=="cancelled"){await new Promise((p)=>setTimeout(p,u));let l=await r.taskStore.getTask(a);if(!l)throw new M(U.InternalError,`Task ${a} not found during polling`);c=l}return await r.taskStore.getTaskResult(a)}setCompletionRequestHandler(){if(this._completionHandlerInitialized)return;this.server.assertCanSetRequestHandler(Br(La)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(La,async(e)=>{switch(e.params.ref.type){case"ref/prompt":return $b(e),this.handlePromptCompletion(e,e.params.ref);case"ref/resource":return Tb(e),this.handleResourceCompletion(e,e.params.ref);default:throw new M(U.InvalidParams,`Invalid completion reference: ${e.params.ref}`)}}),this._completionHandlerInitialized=!0}async handlePromptCompletion(e,t){let r=this._registeredPrompts[t.name];if(!r)throw new M(U.InvalidParams,`Prompt ${t.name} not found`);if(!r.enabled)throw new M(U.InvalidParams,`Prompt ${t.name} disabled`);if(!r.argsSchema)return ns;let o=Ir(r.argsSchema)?.[e.params.argument.name];if(!Hm(o))return ns;let i=WS(o);if(!i)return ns;let s=await i(e.params.argument.value,e.params.context);return YS(s)}async handleResourceCompletion(e,t){let r=Object.values(this._registeredResourceTemplates).find((i)=>i.resourceTemplate.uriTemplate.toString()===t.uri);if(!r){if(this._registeredResources[t.uri])return ns;throw new M(U.InvalidParams,`Resource template ${e.params.ref.uri} not found`)}let n=r.resourceTemplate.completeCallback(e.params.argument.name);if(!n)return ns;let o=await n(e.params.argument.value,e.params.context);return YS(o)}setResourceRequestHandlers(){if(this._resourceHandlersInitialized)return;this.server.assertCanSetRequestHandler(Br(Aa)),this.server.assertCanSetRequestHandler(Br(Ca)),this.server.assertCanSetRequestHandler(Br(Ia)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(Aa,async(e,t)=>{let r=Object.entries(this._registeredResources).filter(([o,i])=>i.enabled).map(([o,i])=>({uri:o,name:i.name,...i.metadata})),n=[];for(let o of Object.values(this._registeredResourceTemplates)){if(!o.resourceTemplate.listCallback)continue;let i=await o.resourceTemplate.listCallback(t);for(let s of i.resources)n.push({...o.metadata,...s})}return{resources:[...r,...n]}}),this.server.setRequestHandler(Ca,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([t,r])=>({name:t,uriTemplate:r.resourceTemplate.uriTemplate.toString(),...r.metadata}))})),this.server.setRequestHandler(Ia,async(e,t)=>{let r=new URL(e.params.uri),n=this._registeredResources[r.toString()];if(n){if(!n.enabled)throw new M(U.InvalidParams,`Resource ${r} disabled`);return n.readCallback(r,t)}for(let o of Object.values(this._registeredResourceTemplates)){let i=o.resourceTemplate.uriTemplate.match(r.toString());if(i)return o.readCallback(r,i,t)}throw new M(U.InvalidParams,`Resource ${r} not found`)}),this._resourceHandlersInitialized=!0}setPromptRequestHandlers(){if(this._promptHandlersInitialized)return;this.server.assertCanSetRequestHandler(Br(ja)),this.server.assertCanSetRequestHandler(Br(Na)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(ja,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,e])=>e.enabled).map(([e,t])=>({name:e,title:t.title,description:t.description,arguments:t.argsSchema?yF(t.argsSchema):void 0}))})),this.server.setRequestHandler(Na,async(e,t)=>{let r=this._registeredPrompts[e.params.name];if(!r)throw new M(U.InvalidParams,`Prompt ${e.params.name} not found`);if(!r.enabled)throw new M(U.InvalidParams,`Prompt ${e.params.name} disabled`);if(r.argsSchema){let n=Qn(r.argsSchema),o=await fa(n,e.params.arguments);if(!o.success){let a="error"in o?o.error:"Unknown error",c=ha(a);throw new M(U.InvalidParams,`Invalid arguments for prompt ${e.params.name}: ${c}`)}let i=o.data,s=r.callback;return await Promise.resolve(s(i,t))}else{let n=r.callback;return await Promise.resolve(n(t))}}),this._promptHandlersInitialized=!0}resource(e,t,...r){let n;if(typeof r[0]==="object")n=r.shift();let o=r[0];if(typeof t==="string"){if(this._registeredResources[t])throw Error(`Resource ${t} is already registered`);let i=this._createRegisteredResource(e,void 0,t,n,o);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[e])throw Error(`Resource template ${e} is already registered`);let i=this._createRegisteredResourceTemplate(e,void 0,t,n,o);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}registerResource(e,t,r,n){if(typeof t==="string"){if(this._registeredResources[t])throw Error(`Resource ${t} is already registered`);let o=this._createRegisteredResource(e,r.title,t,r,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),o}else{if(this._registeredResourceTemplates[e])throw Error(`Resource template ${e} is already registered`);let o=this._createRegisteredResourceTemplate(e,r.title,t,r,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),o}}_createRegisteredResource(e,t,r,n,o){let i={name:e,title:t,metadata:n,readCallback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({uri:null}),update:(s)=>{if(typeof s.uri<"u"&&s.uri!==r){if(delete this._registeredResources[r],s.uri)this._registeredResources[s.uri]=i}if(typeof s.name<"u")i.name=s.name;if(typeof s.title<"u")i.title=s.title;if(typeof s.metadata<"u")i.metadata=s.metadata;if(typeof s.callback<"u")i.readCallback=s.callback;if(typeof s.enabled<"u")i.enabled=s.enabled;this.sendResourceListChanged()}};return this._registeredResources[r]=i,i}_createRegisteredResourceTemplate(e,t,r,n,o){let i={resourceTemplate:r,title:t,metadata:n,readCallback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({name:null}),update:(c)=>{if(typeof c.name<"u"&&c.name!==e){if(delete this._registeredResourceTemplates[e],c.name)this._registeredResourceTemplates[c.name]=i}if(typeof c.title<"u")i.title=c.title;if(typeof c.template<"u")i.resourceTemplate=c.template;if(typeof c.metadata<"u")i.metadata=c.metadata;if(typeof c.callback<"u")i.readCallback=c.callback;if(typeof c.enabled<"u")i.enabled=c.enabled;this.sendResourceListChanged()}};this._registeredResourceTemplates[e]=i;let s=r.uriTemplate.variableNames;if(Array.isArray(s)&&s.some((c)=>!!r.completeCallback(c)))this.setCompletionRequestHandler();return i}_createRegisteredPrompt(e,t,r,n,o){let i={title:t,description:r,argsSchema:n===void 0?void 0:gn(n),callback:o,enabled:!0,disable:()=>i.update({enabled:!1}),enable:()=>i.update({enabled:!0}),remove:()=>i.update({name:null}),update:(s)=>{if(typeof s.name<"u"&&s.name!==e){if(delete this._registeredPrompts[e],s.name)this._registeredPrompts[s.name]=i}if(typeof s.title<"u")i.title=s.title;if(typeof s.description<"u")i.description=s.description;if(typeof s.argsSchema<"u")i.argsSchema=gn(s.argsSchema);if(typeof s.callback<"u")i.callback=s.callback;if(typeof s.enabled<"u")i.enabled=s.enabled;this.sendPromptListChanged()}};if(this._registeredPrompts[e]=i,n){if(Object.values(n).some((a)=>{let c=a instanceof Ct?a._def?.innerType:a;return Hm(c)}))this.setCompletionRequestHandler()}return i}_createRegisteredTool(e,t,r,n,o,i,s,a,c){Vm(e);let u={title:t,description:r,inputSchema:KS(n),outputSchema:KS(o),annotations:i,execution:s,_meta:a,handler:c,enabled:!0,disable:()=>u.update({enabled:!1}),enable:()=>u.update({enabled:!0}),remove:()=>u.update({name:null}),update:(l)=>{if(typeof l.name<"u"&&l.name!==e){if(typeof l.name==="string")Vm(l.name);if(delete this._registeredTools[e],l.name)this._registeredTools[l.name]=u}if(typeof l.title<"u")u.title=l.title;if(typeof l.description<"u")u.description=l.description;if(typeof l.paramsSchema<"u")u.inputSchema=gn(l.paramsSchema);if(typeof l.outputSchema<"u")u.outputSchema=gn(l.outputSchema);if(typeof l.callback<"u")u.handler=l.callback;if(typeof l.annotations<"u")u.annotations=l.annotations;if(typeof l._meta<"u")u._meta=l._meta;if(typeof l.enabled<"u")u.enabled=l.enabled;this.sendToolListChanged()}};return this._registeredTools[e]=u,this.setToolRequestHandlers(),this.sendToolListChanged(),u}tool(e,...t){if(this._registeredTools[e])throw Error(`Tool ${e} is already registered`);let r,n,o,i;if(typeof t[0]==="string")r=t.shift();if(t.length>1){let a=t[0];if(Jm(a)){if(n=t.shift(),t.length>1&&typeof t[0]==="object"&&t[0]!==null&&!Jm(t[0]))i=t.shift()}else if(typeof a==="object"&&a!==null){if(Object.values(a).some((c)=>typeof c==="object"&&c!==null))throw Error(`Tool ${e} expected a Zod schema or ToolAnnotations, but received an unrecognized object`);i=t.shift()}}let s=t[0];return this._createRegisteredTool(e,void 0,r,n,o,i,{taskSupport:"forbidden"},void 0,s)}registerTool(e,t,r){if(this._registeredTools[e])throw Error(`Tool ${e} is already registered`);let{title:n,description:o,inputSchema:i,outputSchema:s,annotations:a,_meta:c}=t;return this._createRegisteredTool(e,n,o,i,s,a,{taskSupport:"forbidden"},c,r)}prompt(e,...t){if(this._registeredPrompts[e])throw Error(`Prompt ${e} is already registered`);let r;if(typeof t[0]==="string")r=t.shift();let n;if(t.length>1)n=t.shift();let o=t[0],i=this._createRegisteredPrompt(e,void 0,r,n,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),i}registerPrompt(e,t,r){if(this._registeredPrompts[e])throw Error(`Prompt ${e} is already registered`);let{title:n,description:o,argsSchema:i}=t,s=this._createRegisteredPrompt(e,n,o,i,r);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(e,t){return this.server.sendLoggingMessage(e,t)}sendResourceListChanged(){if(this.isConnected())this.server.sendResourceListChanged()}sendToolListChanged(){if(this.isConnected())this.server.sendToolListChanged()}sendPromptListChanged(){if(this.isConnected())this.server.sendPromptListChanged()}}var vF={type:"object",properties:{}};function XS(e){return e!==null&&typeof e==="object"&&"parse"in e&&typeof e.parse==="function"&&"safeParse"in e&&typeof e.safeParse==="function"}function QS(e){return"_def"in e||"_zod"in e||XS(e)}function Jm(e){if(typeof e!=="object"||e===null)return!1;if(QS(e))return!1;if(Object.keys(e).length===0)return!0;return Object.values(e).some(XS)}function KS(e){if(!e)return;if(Jm(e))return gn(e);if(!QS(e))throw Error("inputSchema must be a Zod schema or raw shape, received an unrecognized object");return e}function yF(e){let t=Ir(e);if(!t)return[];return Object.entries(t).map(([r,n])=>{let o=qy(n),i=Uy(n);return{name:r,description:o,required:!i}})}function Br(e){let r=Ir(e)?.method;if(!r)throw Error("Schema is missing a method literal");let n=ga(r);if(typeof n==="string")return n;throw Error("Schema method literal must be a string")}function YS(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var ns={completion:{values:[],hasMore:!1}};import t$ from"node:process";class Km{append(e){this._buffer=this._buffer?Buffer.concat([this._buffer,e]):e}readMessage(){if(!this._buffer)return null;let e=this._buffer.indexOf(`
|
|
67
|
+
`);if(e===-1)return null;let t=this._buffer.toString("utf8",0,e).replace(/\r$/,"");return this._buffer=this._buffer.subarray(e+1),bF(t)}clear(){this._buffer=void 0}}function bF(e){return xb.parse(JSON.parse(e))}function e$(e){return JSON.stringify(e)+`
|
|
68
|
+
`}class Ym{constructor(e=t$.stdin,t=t$.stdout){this._stdin=e,this._stdout=t,this._readBuffer=new Km,this._started=!1,this._ondata=(r)=>{this._readBuffer.append(r),this.processReadBuffer()},this._onerror=(r)=>{this.onerror?.(r)}}async start(){if(this._started)throw Error("StdioServerTransport already started! If using Server class, note that connect() calls start() automatically.");this._started=!0,this._stdin.on("data",this._ondata),this._stdin.on("error",this._onerror)}processReadBuffer(){while(!0)try{let e=this._readBuffer.readMessage();if(e===null)break;this.onmessage?.(e)}catch(e){this.onerror?.(e)}}async close(){if(this._stdin.off("data",this._ondata),this._stdin.off("error",this._onerror),this._stdin.listenerCount("data")===0)this._stdin.pause();this._readBuffer.clear(),this.onclose?.()}send(e){return new Promise((t)=>{let r=e$(e);if(this._stdout.write(r))t();else this._stdout.once("drain",t)})}}import{execFile as _F}from"node:child_process";import{promises as yo}from"node:fs";import{homedir as Xm}from"node:os";import{basename as wF,dirname as Tc,join as Sn,resolve as r$}from"node:path";import{promisify as kF}from"node:util";var SF=Sn(Xm(),".figura"),Qm=Sn(SF,"config.json"),n$=Sn(".figura","config.json");async function ef(e){try{let t=await yo.readFile(e,"utf8"),r=JSON.parse(t);if(r&&typeof r==="object")return r;return{}}catch{return{}}}async function o$(e=process.cwd()){let t=Xm(),r=e;for(;;){if(r!==t){let o=Sn(r,n$);try{return await yo.access(o),o}catch{}}let n=Tc(r);if(n===r)return TF(e);r=n}}var $F=kF(_F);async function TF(e){try{let t={...process.env};delete t.GIT_DIR,delete t.GIT_WORK_TREE,delete t.GIT_COMMON_DIR;let{stdout:r}=await $F("git",["rev-parse","--path-format=absolute","--git-common-dir","--git-dir","--show-toplevel"],{cwd:e,env:t,timeout:5000,windowsHide:!0}),n=r.split(`
|
|
69
|
+
`).filter((m)=>m&&m!=="--path-format=absolute");if(n.length!==3)return null;let[o,i,s]=n.map((m)=>r$(e,m));if(wF(o)!==".git"||Tc(i)!==Sn(o,"worktrees"))return null;let a=(await yo.readFile(Sn(i,"gitdir"),"utf8")).trim(),[c,u]=await Promise.all([yo.realpath(Tc(r$(i,a))),yo.realpath(s)]);if(c!==u)return null;let l=Tc(o);if(l===Xm())return null;let p=Sn(l,n$);return await yo.access(p),p}catch{return null}}function i$(e,t){if(e!=="global")return"ok";if(t.mutate&&!t.allowGlobal)return"refuse";return"warn"}function tf(e,t,r){return i$(t,{mutate:e.toUpperCase()!=="GET",allowGlobal:r})==="refuse"}var EF=2000,RF=150,s$=(e)=>new Promise((t)=>setTimeout(t,e));async function a$(e){let t=e.intervalMs??EF,r=e.maxPolls??RF,n=e.errorToleranceMs??0,o=null;for(let i=0;i<r;i++){let s;try{s=await e.fetchJob(),o=null}catch(a){if(n<=0)throw a;if(o??=Date.now(),Date.now()-o>=n){let c=a instanceof Error?a.message:String(a);throw Error(`Job poll failed: ${c}`)}await s$(t);continue}if(s.status==="done")return s;if(s.status==="error")throw Error(s.error||"The job failed. Try again.");await s$(t)}throw Error("Timed out waiting for the job. It may still finish — refresh shortly.")}function c$(e){let t={name:e.name};if(e.appDescription!==void 0)t.appDescription=e.appDescription;if(e.tokensBlock!==void 0)t.tokensBlock=e.tokensBlock;if(e.surfaces!==void 0)t.surfaces=e.surfaces;if(e.identity!==void 0)t.identity=e.identity;if(e.platforms!==void 0)t.platforms=e.platforms;if(e.proseSource!==void 0)t.proseSource=e.proseSource;return t}import{createHash as PF}from"node:crypto";import{existsSync as zF,readdirSync as rf,readFileSync as Ec}from"node:fs";import{homedir as OF}from"node:os";import{fileURLToPath as u$}from"node:url";import{dirname as AF,join as Hr,relative as CF,sep as IF}from"node:path";var jF=".figura-skills.json",NF=".figura-version",DF=".figura-skills-hash";var os="fig";function d$(e){let t=[],r=(o)=>{for(let i of rf(o,{withFileTypes:!0})){let s=Hr(o,i.name);if(i.isDirectory())r(s);else if(i.isFile())t.push(s)}};try{for(let o of rf(e,{withFileTypes:!0}))if(o.isDirectory()&&o.name===os)r(Hr(e,o.name))}catch{return null}if(t.length===0)return null;let n=PF("sha256");for(let o of t.sort()){let i=CF(e,o).split(IF).join("/");n.update(i),n.update("\x00"),n.update(Ec(o)),n.update("\x00")}return n.digest("hex").slice(0,16)}function l$(e){try{return rf(e,{withFileTypes:!0}).some((t)=>t.isDirectory()&&zF(Hr(e,t.name,"SKILL.md")))}catch{return!1}}function m$(){let e=[new URL("../skills/",import.meta.url),new URL("../../skills/",import.meta.url)].map((r)=>u$(r));for(let r of e)if(l$(r))return r;let t=u$(new URL("./",import.meta.url));for(let r=0;r<8;r++){let n=Hr(t,".claude","skills");if(l$(n))return n;let o=AF(t);if(o===t)break;t=o}return null}function MF(){let e=m$();return e?d$(e):null}function LF(){let e=m$();if(!e)return null;try{return JSON.parse(Ec(Hr(e,"skills.json"),"utf8")).skills?.[os]?.version??null}catch{return null}}function p$(e,t){try{return Ec(Hr(e,t),"utf8").trim()||null}catch{return null}}function f$(e){try{let n=JSON.parse(Ec(Hr(e,jF),"utf8"));if(n&&typeof n==="object"&&!Array.isArray(n))return n}catch{}let t=p$(e,NF),r=p$(e,DF);if(t==null&&r==null)return null;return{[os]:{version:t,hash:r}}}function qF(e){return f$(e)?.[os]?.version??null}function UF(e){return f$(e)?.[os]?.hash??null}function FF(e){let{stamp:t,stampedHash:r,installedHash:n,referenceHash:o,referenceIsCanonical:i}=e;if(n==null)return"absent";if(o!=null&&n===o)return"pristine";if(r!=null&&n!==r)return"diverged";if(t==null&&r==null)return"unstamped";if(o==null||!i)return"unknown";if(r!=null)return"behind";return"diverged"}function ZF(e){switch(e){case"pristine":return"pristine";case"behind":return"stale";case"diverged":case"unstamped":return"modified";case"absent":return"absent";case"unknown":return}}function Rc(){return{version:LF(),hash:MF(),canonical:!1}}async function h$(e){try{let t=await e();if(t?.hash)return{version:t.version??null,hash:t.hash,canonical:!0}}catch{}return Rc()}function BF(e,t=Hr(OF(),".claude","skills")){try{let r=qF(t),n=d$(t),o=FF({stamp:r,stampedHash:UF(t),installedHash:n,referenceHash:e.hash,referenceIsCanonical:e.canonical});return{version:r,hash:n,status:ZF(o),drift:o}}catch{return{version:null,hash:null,status:"absent",drift:"absent"}}}function Pc(e,t){return{channel:"mcp",mcpVersion:e,skill:BF(t)}}function g$(e){switch(e){case"behind":return"⚠ your fig skill is behind the canonical version — run `figura install` to update it";case"diverged":return"⚠ your fig skill has DIVERGED from the canonical version (same version line, different bytes) — run `figura skill diff` to see what differs before deciding.";case"unstamped":return"⚠ your fig skill carries no version stamp — figura did not install this copy. Run `figura skill diff` before `figura skill install` replaces it.";default:return null}}import{promises as of}from"node:fs";import{homedir as sf}from"node:os";import{join as af}from"node:path";var e4=604800000,t4=21600000;function zc(e){try{let t=new URL(e);return`${t.protocol}//${t.host}`.toLowerCase()}catch{return e.trim().toLowerCase().replace(/\/+$/,"")}}async function cf(e,t="latest",r){let n=await Promise.resolve().then(() => (R$(),{})),o=r!==void 0?r:T$()??null;if(o){let i=_$(o,"global",[`${e}@${t}`]);if(i)return{command:`${i.command} ${i.args.join(" ")}`,generic:!1}}return{command:`npm i -g ${e}@${t}`,generic:!0}}function uf(e){return e.generic?`Update with your package manager's global install, e.g. ${e.command}`:`Run: ${e.command}`}function z$(e){if(e==="figura-cli")return{pkg:"figura-cli",cacheFile:af(sf(),".figura","update-check.json"),minHeader:"x-figura-min-cli",latestHeader:"x-figura-latest-cli",label:"figura",installPkg:"figura-cli"};return{pkg:"figura-mcp",cacheFile:af(sf(),".figura","update-check-mcp.json"),minHeader:"x-figura-min-mcp",latestHeader:"x-figura-latest-mcp",label:"figura-mcp",installPkg:"figura-mcp"}}function r4(e,t,r){if(!t.min&&!t.latest)return null;let n={...e},o=!1,i=(s)=>typeof s!=="number"||r-s>=t4;if(t.min&&(e.min!==t.min||i(e.minAt)))n.min=t.min,n.minAt=r,o=!0;if(t.latest&&(e.latest!==t.latest||i(e.latestAt)))n.latest=t.latest,n.latestAt=r,o=!0;return o?n:null}function P$(e,t){return typeof e==="number"&&t-e<e4}function lf(e,t,r){let n=e.serverAdvice?.[t];if(!n)return{};return{min:P$(n.minAt,r)?n.min:void 0,latest:P$(n.latestAt,r)?n.latest:void 0}}function is(e,t){let r=(i)=>{let s=/^\D*(\d+)\.(\d+)\.(\d+)/.exec(i.trim());return s?[Number(s[1]),Number(s[2]),Number(s[3])]:null},n=r(e),o=r(t);if(!n||!o)return!1;for(let i=0;i<3;i++){if(n[i]>o[i])return!0;if(n[i]<o[i])return!1}return!1}function n4(e){if(e.CI)return"ci";if(e.FIGURA_NO_UPDATE_NOTIFIER==="1"||e.NO_UPDATE_NOTIFIER==="1")return"opt-out";return null}function o4(e,t,r,n){return`⚠ ${e.label} ${t} → ${r} available. ${n}`}function i4(e,t,r,n){return`⚠ ${e.label} ${t} is below the minimum supported ${r} — `+`some tools may fail. ${n}`}function O$(e,t,r){let n=e.latest,o=lf(e,t,r).latest;if(n&&o)return is(o,n)?o:n;return n??o}function s4(e,t,r,n,o=Date.now()){let i=lf(r,n,o).min;if(i&&is(i,t))return{level:"firm",target:i};let s=O$(r,n,o);if(s&&is(s,t))return{level:"stale",target:s};return null}function a4(e,t,r,n){return t.level==="firm"?`Your ${e.label} ${r} is below the minimum supported ${t.target} — `+`some Figura tools may fail. Ask the user to update: ${n}`:`${e.label} ${r} → ${t.target} available. Ask the user to update: ${n}`}async function A$(e){try{let t=e.cache??await pf(e.stream),r=s4(e.stream,e.current,t,e.origin,e.now);if(!r)return null;let n=uf(await cf(e.stream.installPkg,"latest",e.agent));return a4(e.stream,r,e.current,n)}catch{return null}}function C$(e,t){let r=t(e.minHeader)?.trim(),n=t(e.latestHeader)?.trim();return{min:r||void 0,latest:n||void 0}}async function I$(e,t,r,n=Date.now()){try{if(!r.min&&!r.latest)return;let o=await pf(e),i={...o.serverAdvice??{}},s=r4(i[t]??{},r,n);if(!s)return;i[t]=s,await c4(e,{...o,serverAdvice:i})}catch{}}async function pf(e){try{let t=JSON.parse(await of.readFile(e.cacheFile,"utf8"));return t&&typeof t==="object"?t:{}}catch{return{}}}async function c4(e,t){await of.mkdir(af(sf(),".figura"),{recursive:!0,mode:448}),await of.writeFile(e.cacheFile,JSON.stringify(t,null,2)+`
|
|
70
|
+
`,{mode:384})}async function j$(e,t,r,n=process.env,o=Date.now()){try{if(n4(n))return;let i=await pf(t),s=lf(i,r,o).min;if(s&&is(s,e)){let c=uf(await cf(t.installPkg));process.stderr.write(i4(t,e,s,c)+`
|
|
71
|
+
`);return}let a=O$(i,r,o);if(a&&is(a,e)){let c=uf(await cf(t.installPkg));process.stderr.write(o4(t,e,a,c)+`
|
|
72
|
+
`)}}catch{}}var l4=je({name:E(),hex:E().describe("3/4/6/8-digit hex, e.g. #1FB6A6 or #1FB6A6FF. The LIGHT-scheme value."),hexDark:E().optional().describe("This color's DARK-scheme value (same hex format). Send it only when the brand really defines one — a brand where no color carries hexDark has no dark scheme and figs render one scheme."),role:E().optional(),meaning:E().optional()}).passthrough(),df=je({hex:E(),hexDark:E().optional()}).passthrough(),Oc=je({base:df,on:df.describe("Ink drawn ON the base fill."),container:df.optional().describe("Soft/tinted surface for this state.")}).passthrough(),p4=je({success:Oc.optional(),warning:Oc.optional(),error:Oc.optional(),info:Oc.optional()}).passthrough().describe("Semantic state colors. They are ADDITIONAL to the palette — figs never drop a state to meet the color cap. Omit a role the brand doesn't define; Figura's neutral tint fills it."),d4=je({id:E().optional(),rule:E()}).passthrough(),m4=je({colors:Me(l4).optional(),gradient:E().optional(),signature:je({kind:ue(["solid","gradient","iridescent"]),stops:Me(E()).optional()}).passthrough().optional(),type:je({families:lO(E()).optional(),ramp:Me($t()).optional(),rules:E().optional()}).passthrough().optional(),spacing:Me($t()).optional(),radius:Me($t()).optional(),voice:je({nouns:Me(E()).optional(),promise:E().optional(),lines:Me(E()).optional(),tone:E().optional()}).passthrough().optional(),locales:Me(je({tag:E().describe('BCP-47 language tag, e.g. "en", "ar", "ckb".'),script:E().describe('ISO 15924 script code, e.g. "Latn", "Arab".'),direction:ue(["ltr","rtl"]),fonts:je({display:E().optional(),body:E().optional(),mono:E().optional()}).passthrough().optional()}).passthrough()).optional().describe("Languages the brand ships in — FIRST entry is the default. Per-locale fonts override the shared type families for that script."),forbidden:Me(d4).optional(),icons:je({set:ue(["material-symbols","sf-symbols","lucide","custom"]),style:ue(["outlined","filled","rounded","sharp"]),weight:$t().optional(),strokeWidth:$t().optional()}).passthrough().optional(),accessibility:je({minTouchTarget:$t().optional(),minTextSize:$t().optional(),contrastTarget:ue(["AA","AAA"]).optional(),reducedMotion:ue(["respect","ignore"]).optional()}).passthrough().optional(),status:p4.optional()}).passthrough(),mf=je({components:Me(je({name:E(),spec:E()}).passthrough()).optional(),icons:E().optional(),layout:E().optional(),surfaces:Me(E()).optional(),bans:Me(E()).optional(),tokensBlock:E().optional()}).passthrough(),f4=je({mobile:mf.optional(),web:mf.optional(),desktop:mf.optional()}).passthrough(),h4="https://api.figura.so",g4="mcp";async function jc(){let e=await o$(),t=e?await ef(e):{},r=await ef(Qm),n={...r,...t},o=process.env.FIGURA_TOKEN||n.token||void 0,i=process.env.FIGURA_TOKEN?"env":t.token?"project":r.token?"global":"none",s=(process.env.FIGURA_API_URL||n.apiUrl||h4).replace(/\/+$/,"");return{token:o,apiUrl:s,team:n.team,source:i,configPath:i==="project"?e:i==="global"?Qm:null}}async function de(e,t={}){let r=await jc(),n=r.token;if(!n)throw Error("No Figura token. Run `figura link` in this repo (or `figura login`, or set FIGURA_TOKEN).");let o=(t.method??"GET").toUpperCase();if(tf(o,r.source,process.env.FIGURA_ALLOW_GLOBAL==="1"))throw Error(`this project isn't linked to a Figura team — the global credential${r.team?` (team '${r.team}')`:""} would receive this write. Ask the user to run \`figura link\` in this repo (or set FIGURA_ALLOW_GLOBAL=1 to use the global team deliberately).`);let i=`${r.apiUrl}${e.startsWith("/")?"":"/"}${e}`,s={Accept:"application/json",Authorization:`Bearer ${n}`,"X-Figura-Source":g4},a;if(t.body!==void 0)s["Content-Type"]="application/json",a=JSON.stringify(t.body);let c=await Qo.request({url:i,method:t.method??"GET",headers:s,data:a,...t.timeoutMs?{timeout:t.timeoutMs}:{},validateStatus:()=>!0,transformRequest:[(p)=>p],transformResponse:[(p)=>p]});{let p=c.headers,m=(d)=>{let h=p?.[d];return typeof h==="string"?h:void 0};I$(Ic,zc(r.apiUrl),C$(Ic,m))}let u=typeof c.data==="string"?c.data:"",l=void 0;if(u)try{l=JSON.parse(u)}catch{l=u}if(c.status<200||c.status>=300){let p=l&&typeof l==="object"&&l!==null&&"error"in l?String(l.error):typeof l==="string"&&l?l:c.statusText||`HTTP ${c.status}`;throw Error(`${p} (HTTP ${c.status})`)}return l}var D$=2500,x4=600000,v4=60000;async function y4(e){let t=Math.ceil(x4/D$);try{return await a$({intervalMs:D$,maxPolls:t,errorToleranceMs:v4,fetchJob:()=>de(`/v1/jobs/${encodeURIComponent(e)}`)})}catch(r){let n=r instanceof Error?r.message:String(r);if(n.startsWith("Job poll failed:"))throw Error(`Lost contact with the Figura API while waiting for job ${e} (${n.slice(17)}). `+`The job may still complete — resume by checking GET /v1/jobs/${e} instead of regenerating.`);if(n.startsWith("Timed out"))throw Error(`Timed out waiting for job ${e} — it may still complete; `+`check GET /v1/jobs/${e} instead of regenerating.`);throw r}}function ye(e){return{content:[{type:"text",text:JSON.stringify(e,null,2)}]}}function he(e){return{content:[{type:"text",text:e instanceof Error?e.message:String(e)}],isError:!0}}var b4=3000,_4=250,w4=600000,Ac=null,hf=null;function q$(){if(!Ac||Date.now()-Ac.at>w4)Ac={at:Date.now(),value:h$(()=>de("/v1/skills/fig/latest",{timeoutMs:b4})).then((e)=>{if(e.hash!=null)hf=e;return e})};return Ac.value}async function gf(){try{let e,t=()=>hf??Rc(),r=new Promise((n)=>{e=setTimeout(()=>n(t()),_4),e.unref?.()});return await Promise.race([q$(),r]).finally(()=>clearTimeout(e))}catch{return hf??Rc()}}var M$=!1;async function ss(e){try{if(M$)return e;if(!e||typeof e!=="object"||Array.isArray(e))return e;let{apiUrl:t}=await jc(),r=await A$({stream:Ic,current:_o,origin:zc(t)});if(!r)return e;return M$=!0,{...e,notice:r}}catch{return e}}function Cc(e,t){if(!e||typeof e!=="object"||Array.isArray(e))return e;let r=g$(t);if(!r)return e;return{...e,skillWarning:r}}var bo=()=>E().optional().describe("Product area / surface the fig belongs to, e.g. 'dashboard', 'settings', 'onboarding'. Free text — but REUSE one of the team's existing areas EXACTLY when the fig belongs to that surface; a synonym fragments the library. The team's areas with counts come back from figura_whoami, figura_fig_scaffold and every create as `areas`."),Nc=()=>E().optional().describe(`The fig's BRIEF — rendered as the Brief panel beside the fig, and the first thing the reviewer you assign reads. Not a caption. Four beats, in order: (1) the OBJECTIVE in the user's own words, quoted verbatim, restated in every later round; (2) the ARC — one line per prior round: what it tried and what it settled or killed, INCLUDING any direction that was explored and abandoned, with the reason ("withdrawn"/"superseded" on its own deletes the most useful thing a reviewer can know); (3) what is STILL OPEN — the question this round does not close; (4) the PICK and the decision you want back. Writing a later round? Read the prior figs' briefs first (figura_list_figs then figura_get_fig) and carry the objective + arc forward — never restate them from session memory. Max 2000 chars (the fig editor's cap).`),as=["portrait","landscape","both"],Dc=["single","compare","variations"],U$=["fig","child"],{version:_o,name:k4}=(()=>{try{let e=JSON.parse(u4(new URL("../package.json",import.meta.url),"utf8"));return{version:typeof e.version==="string"?e.version:"0.0.0",name:typeof e.name==="string"?e.name:void 0}}catch{return{version:"0.0.0"}}})(),Ic=z$(k4),ke=new Wm({name:"figura",version:_o});ke.registerTool("figura_whoami",{title:"Figura: whoami",description:"Return the identity (team, actor, scopes) for the configured Figura token, plus `binding` — which config tier supplied it (env | project | global) — and `areas`, the team's existing fig areas with counts (most-used first). A `global` binding means this project is not linked to a team and writes will be refused; ask the user to run `figura link` in the repo. Use `areas` to pick an existing `area` when creating a fig instead of coining a synonym.",inputSchema:{}},async()=>{try{let e=await de("/v1/whoami"),{source:t,configPath:r}=await jc();return ye(await ss({...e,binding:{source:t,configPath:r}}))}catch(e){return he(e)}});ke.registerTool("figura_set_brand",{title:"Figura: set brand profile",description:'Set (upsert) the team brand profile that the fig generator renders against. Use this to "introduce a repo to Figura": scan the codebase for its design system, synthesize the brand, then push it here. `name` is required. PREFERRED — send a STRUCTURED brand: `identity` (shared colors/gradient/type/spacing/radius/voice/forbidden/icons/accessibility) + `platforms` (per-platform surfaces, keys mobile|web|desktop) — this makes the brand structured + addressable (is_structured=true). LEGACY/fallback — send prose: `tokensBlock` (freeform design-token reference) + `surfaces` (the product\'s own key areas). `appDescription` is a one-clause product summary. This is a partial merge — fields you omit keep their saved value; a structured write clears the dormant prose columns and a prose write downgrades to legacy. Editing the team brand — confirm with the user before calling.',inputSchema:{name:E().describe("Brand / app name (required)."),appDescription:E().optional().describe("One clause on what the product is + who it is for."),identity:m4.optional().describe("STRUCTURED shared identity (platform-agnostic): { colors:[{name,hex,hexDark?,role?,meaning?}], gradient?, signature?:{kind:solid|gradient|iridescent,stops?:hex[]}, type?:{families?:{slot:font},ramp?:number[],rules?}, spacing?:number[], radius?:number[], voice?:{nouns?,promise?,lines?,tone?}, locales?:[{tag,script,direction,fonts?}] (first = default), forbidden?:[{id?,rule}], icons?:{set:material-symbols|sf-symbols|lucide|custom, style:outlined|filled|rounded|sharp, weight?, strokeWidth?}, accessibility?:{minTouchTarget?, minTextSize?, contrastTarget?:AA|AAA, reducedMotion?:respect|ignore}, status?:{success?,warning?,error?,info? — each {base:{hex,hexDark?}, on?:{hex,hexDark?}, container?:{hex,hexDark?}}} }. hex is 3/4/6/8 digits; hexDark is that color's dark-scheme value (omit unless the brand defines one). `signature` is the brand-page hero treatment: solid unless the repo's tokens define a gradient identity; gradient/iridescent require 2–5 stops. `icons` is what the fig prompt icon rule asserts (a filled set stops it drawing thin strokes); `accessibility` floors default to 44/11/AA/respect when omitted. Status colors are semantic states, additional to the palette and outside the fig color cap. Sending this makes the brand STRUCTURED (is_structured=true). Validated server-side."),platforms:f4.optional().describe('STRUCTURED per-platform surfaces — a map keyed by mobile|web|desktop; include ONLY the platforms the product targets: { <platform>: { components?:[{name,spec}], icons?, layout?, surfaces?:string[], bans?:string[], tokensBlock? } }. `mobile` ALSO takes os?: "ios"|"android" (unset = iOS) — it drives every fig\'s device frame, system-bar heights, back affordance, and corner radii; `os` on web/desktop is rejected. `tokensBlock` here is a per-platform escape hatch for guidance that does not fit a structured field.'),proseSource:E().optional().describe(`The human-readable freeform description this structured brand was authored from — stored as the editable source shown in the web brand editor; NOT used by generation. Send it alongside a structured write so a skill/CLI/MCP-authored brand still seeds the web editor's "Author from a description" textarea (a repo scan should pass the prose it synthesized the brand from; a prose→structured upgrade should pass the original prose).`),tokensBlock:E().optional().describe("LEGACY prose fallback: freeform plain-text design-token reference (colors + hex + role, type scale + faces, spacing, gradient, voice/conventions). Prefer `identity`/`platforms`. Injected verbatim into the fig-generation prompt."),surfaces:Me(E()).optional().describe(`LEGACY prose fallback: the product's own key areas/sections (e.g. ["Feed", "Settings", "Checkout"]) — read from the repo's real navigation/routes. For a structured brand put surfaces under each platform instead. Pass [] to clear.`)}},async(e)=>{try{return ye(await de("/brand",{method:"PUT",body:c$(e)}))}catch(t){return he(t)}});ke.registerTool("figura_brand_schema",{title:"Figura: brand schema",description:"Return the JSON Schema for the STRUCTURED brand — the ONE authority (derived server-side from the zod schema PUT /brand validates). Fetch this BEFORE synthesizing a brand for figura_set_brand's `identity`/`platforms`, and author against it so the brand validates first try (strict keys; hex 3/4/6/8 digits; platform keys mobile|web|desktop; no blank array entries). Read-only. Returns { schema }.",inputSchema:{}},async()=>{try{return ye(await de("/v1/brand/schema"))}catch(e){return he(e)}});var S4={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",webp:"image/webp",avif:"image/avif",svg:"image/svg+xml"},ff=5242880;function L$(e){let t=e.split(/[?#]/)[0].split(".").pop()?.toLowerCase()??"";return S4[t]}async function F$(e,t){let r,n=t;if(/^https?:\/\//i.test(e)){let o=await Qo.get(e,{responseType:"arraybuffer",maxContentLength:ff,timeout:30000});if(r=Buffer.from(o.data).toString("base64"),!n){let i=String(o.headers["content-type"]??"").split(";")[0].trim().toLowerCase();n=i.startsWith("image/")?i:L$(e)}}else{let{size:o}=await N$.stat(e);if(o>ff)throw Error(`'${e}' is ${(o/1048576).toFixed(1)}MB — over the ${ff/1048576}MB asset limit.`);if(r=(await N$.readFile(e)).toString("base64"),!n)n=L$(e)}if(!n)throw Error(`Could not determine an image content-type for '${e}' — pass contentType (e.g. image/png).`);return{data:r,contentType:n}}async function $4(e,t){let{data:r,contentType:n}=await F$(e,t),o=await de("/v1/assets",{method:"POST",body:{data:r,contentType:n}});if(!o||typeof o.url!=="string")throw Error("Asset upload did not return a URL.");return o.url}var Z$=()=>Me(je({source:E().describe("The image — a local file path or an http(s) URL (e.g. a screenshot)."),match:E().optional().describe('Exact string in the HTML to replace with the hosted URL (defaults to `source` — i.e. write <img src="<source>"> in the HTML).')})).optional().describe("Images to attach: each is uploaded to durable figura hosting (stable non-expiring URL, allowed by the fig CSP) and substituted into the HTML in place of `match`/`source`. Use for real screenshots/photos/logos instead of base64 data-URIs (HTML size cap) or external URLs (expire/CSP-blocked).");async function B$(e,t){if(!t?.length)return{parts:e,uploaded:[]};let r=[...e],n=[];for(let o of t){let i=o.match??o.source;if(!r.some((a)=>a?.includes(i)))throw Error(`images: '${i}' does not occur in the fig's markup — reference it (e.g. <img src="${i}">) so it can be swapped for the hosted URL, or set 'match'.`);let s=await $4(o.source);r=r.map((a)=>a===void 0?a:a.split(i).join(s)),n.push({source:o.source,url:s})}return{parts:r,uploaded:n}}async function T4(e,t){let{parts:r,uploaded:n}=await B$([e],t);return{html:r[0],uploaded:n}}function H$(e,t){if(!t.length)return e;if(e&&typeof e==="object"&&!Array.isArray(e))return{...e,assets:t};return{result:e,assets:t}}ke.registerTool("figura_create_fig",{title:"Figura: create fig",description:"Create a new visualization from an HTML document — this HOSTS it (the create IS the hosting; there is no separate \"land it in Figura\" step). Every create returns `viewUrl`: ALWAYS a link you can open for approval, whether or not the fig is published — the public share url once published, else a team-scoped viewer link only signed-in teammates can open. The fig lands as a workspace DRAFT (`status: 'draft'`): hosted and viewable, visible to its author, but NOT in the team library and silent for teammates — iterate freely without claiming the team's attention, then COMMIT only the session's final recommendation (`commit: true` on that final create/revise, or figura_commit_fig). Do NOT pass publish:true just to get something viewable — omit it (default false) so the fig lands team-private, open `viewUrl` for review, and only publish when the human wants a link they can share outside the team (figura_publish_fig, once approved). The response also carries `brandWarnings` — a deterministic (no-LLM) colors/fonts/radii/spacing diff against the team's brand tokens, WARN-only (never blocks the create). If it comes back non-empty, read it and consider a figura_revise_fig call that binds the missing tokens before telling the user you're done. To include REAL images (screenshots/photos/logos), pass them via `images` — they are uploaded to durable figura hosting and their stable URLs substituted into the HTML. TIP — injected components: if your HTML shows phone frames (a compare/multi-screen mock), wrap each state in <div class=\"fig-device portrait|landscape\"><div class=\"fig-screen\">…</div><div class=\"fig-di\"></div><div class=\"fig-homebar\"></div></div> — Figura injects accurate iPhone frame CSS at save, BEFORE your <style>, so you normally leave those classes alone; if you do style them your rule wins by cascade (the frame still works), but to shrink frames for an overview grid wrap each frame in the injected `.fig-mini` wrapper (e.g. <div class=\"fig-mini\" style=\"--fig-scale:.34\"> … the .fig-device block … </div>) — it scales the device with transform and reserves the scaled layout box — rather than re-declaring .fig-device width/height or adding transform: scale() yourself (which fights the injected geometry), and never CSS zoom (it leaks unzoomed width into horizontal overflow). Same injection applies to an iOS status bar (<div class=\"fig-statusbar\" data-time=\"9:41\"></div>), a compare control bar (.fig-controls/.fig-seg), and the .frame-web browser window.",inputSchema:{html:E().describe("The full HTML document for the visualization."),images:Z$(),title:E().optional().describe("Title (otherwise derived from the HTML)."),description:Nc(),area:bo(),tags:Me(E()).optional(),orientation:ue(as).optional(),mode:ue(Dc).optional(),model:E().optional().describe("Model attribution."),device:E().optional().describe("Catalog device id the fig targets (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9') — keys the injected frame/safe-area geometry."),os:ue(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),issue:$t().optional().describe("Linked issue number."),locale:E().optional().describe("BCP-47 tag of the brand locale this fig renders in (must be one of the brand's identity.locales) — Figura stamps <html lang dir> and loads the per-script font."),publish:It().optional().describe("Publish to a shareable public URL on create (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately, so only set this when the human explicitly wants a link they can share outside the team. Share link ONLY — does not commit the fig to the team library (that's `commit`)."),commit:It().optional().describe("Commit to the team library on create (sends status: 'published'). Default false — the fig lands as a workspace DRAFT: hosted + viewable via `viewUrl`, visible to its author, but not in the team library and silent for teammates. Set true ONLY when this write is the session's final recommendation (the fig the user asked for / signed off on); explorations and intermediate iterations stay drafts. Committing later: figura_commit_fig."),prompt:E().optional().describe("OPTIONAL: the brief that produced this HTML, if there was one — you wrote the HTML yourself, so Figura never sees a prompt unless you pass it here. Stored on the fig (DB-only, never stamped into the HTML), and returned by figura_get_fig — lets teammates see 'why' this fig exists."),new:It().optional().describe("Start a SEPARATE chain even though the team already has a near-identical one. Figura REFUSES a fresh chain when this fig looks like the next round of an open question, and names the chain to revise instead (figura_revise_fig) — so an exercise stays one walkable history with one discussion. Pass true ONLY when this genuinely is a different question; forking because revising felt like more work is what leaves a reviewer reading round 4 with no sight of rounds 1-3."),kind:ue(U$).optional().describe("'child' creates the fig as frameless screen CONTENT that another fig embeds — it stays out of the team library and its own listing. Default 'fig' (a normal, standalone fig). Nothing composes children yet; do not pass this unless you are building a composition.")}},async(e)=>{try{let{html:t,uploaded:r}=await T4(e.html,e.images),n={html:t};for(let i of["title","description","area","tags","orientation","mode","model","device","os","locale","issue","publish","prompt","kind","new"])if(e[i]!==void 0)n[i]=e[i];if(e.commit)n.status="published";let o=Pc(_o,await gf());return n.toolchain=o,ye(Cc(await ss(H$(await de("/v1/figs",{method:"POST",body:n}),r)),o.skill.drift))}catch(t){return he(t)}});var V$=["single","compare","variations","overview-focus","document"],G$=je({html:E().optional().describe("SCREEN CONTENT markup only — no frame, no bezel, no safe padding. Omit when passing `childFig`."),childFig:E().optional().describe("Compose this frame BY REFERENCE: the id of an existing CHILD fig (one composed with kind:'child') which Figura embeds in its own iframe instead of inlining. Only for `single` and `compare`. Its CSS cannot reach the frame or the other screen, so two children with conflicting body{} rules both render correctly. PINNED to this exact version. Mutually exclusive with `html`/`css`/`safeZone` — the child opts into the safe area itself. This screen's `device` and `orientation` must be the ones the child was composed with — the frame draws that phone's cutout and home bar around the child's own safe-area guides, so a mismatch is refused (422)."),css:E().optional().describe("Optional per-screen content styles (appended unscoped)."),device:E().optional().describe("Catalog device id (e.g. 'iphone-16'). REQUIRED for device layouts."),orientation:ue(["portrait","landscape"]).optional().describe("REQUIRED for device layouts."),safeZone:ue(["respect","ignore"]).optional().describe("REQUIRED for device layouts, REFUSED with `childFig`. 'respect' pads to the real catalog safe insets; 'ignore' is edge-to-edge. A referenced screen pads itself inside the child fig, with the `--fig-safe-*` vars or the `.fig-safe` helper the frame sets on it."),label:E().optional().describe("Chrome label (compare/variations chip, focus pill)."),notes:Me(je({text:E().describe("The point being made. Plain text."),kind:ue(["broken","improved","tradeoff","detail"]).optional().describe("What this note argues — colors the rail accent and its matching pin. Default 'detail'."),at:je({x:$t(),y:$t()}).optional().describe("Percent coordinates (0-100, from the top-left of the SCREEN) to pin this note to. Omit for a point about the whole state — it still gets a number in the rail, just no pin.")})).optional().describe("This screen's annotations. NEVER write annotation chips into `html`: they land inside the phone screen, on top of the design the fig exists to let someone judge. Passed here, Figura puts each note in a rail BESIDE the frame and leaves only a small numbered pin on the artboard. `compare` and `overview-focus` only (the other layouts have no rail and will reject them); max 8. Works the same on a screen composed by reference (`childFig`) — the rail and pins are the parent's.")});ke.registerTool("figura_compose_fig",{title:"Figura: compose fig",description:"PREFERRED way to build a device fig. You write ONLY each screen's CONTENT (the markup inside the phone) + typed params; Figura owns the STRUCTURE — the iPhone frame, the Dynamic Island/notch/home bar, the exact catalog artboard geometry, the REAL safe-area insets, and the composition (grid/diptych/overview). This means the parts that used to drift every few figs — hand-rolled artboards, guessed `--fig-safe-top:59px`, a forgotten `data-device` so no safe machinery stamped — are correct-by-construction: you never write them. Pass `layout` + an ARRAY of `screens`. For every DEVICE layout (single/compare/variations/overview-focus) each screen REQUIRES `device` (a catalog id like 'iphone-16' — fetch figura_fig_devices), `orientation` ('portrait'|'landscape'), and `safeZone` ('respect' = Figura pads your content to the device's real safe insets; 'ignore' = edge-to-edge splash/hero) — except a `childFig` screen, which takes NO `safeZone` (the child pads itself). Each screen's `html` is CONTENT ONLY — do NOT draw a frame, a bezel, a status bar, or safe padding; do NOT set `--fig-safe-*`; do NOT wrap in `.fig-device`; and do NOT write annotation chips into it — pass them as `notes` and Figura rails them BESIDE the frame with numbered pins, instead of covering the design you are asking someone to judge. Style your content with brand tokens via `sharedCss` (ONE stylesheet all screens share) + optional per-screen `css`. Layouts: `single` (one frame), `compare` (as-is → proposed diptych — pass label per screen), `overview-focus` (**use for ANY redesign argument or set of candidate directions** — a CSS toggle that OPENS on the full-frame Focus view with state pills; the Overview grid is the alternative behind the second tab), `variations` (a scan-only grid at the kit's ~0.34 device scale with NO toggle — every frame renders ~134px wide, so body copy and annotations are unreadable; use ONLY for a pure catalogue, NEVER to argue a change), `document` (NO device framing — brand/overview figs; screens need no device/orientation/safeZone). Lands EXACTLY like figura_create_fig (workspace DRAFT, returns `viewUrl` + `brandWarnings` + `warnings`; commit the session's final pick). For a `document`/exotic hand-authored fig where you need full control of the HTML, use figura_create_fig instead.",inputSchema:{layout:ue(V$).describe("The composition Figura emits."),title:E().optional().describe("Fig title (else derived from the HTML)."),description:Nc(),area:bo(),tags:Me(E()).optional(),orientation:ue(as).optional().describe('Fig-level orientation for the persisted row (may be "both").'),device:E().optional().describe("Fig-level default catalog device (per-screen `device` still keys each frame)."),locale:E().optional().describe("BCP-47 tag of the brand locale this fig renders in (must be one of the brand's identity.locales) — Figura stamps <html lang dir> and loads the per-script font."),sharedCss:E().optional().describe("ONE stylesheet ALL screens share — put brand tokens + shared classes here."),screens:Me(G$).describe("The screens to compose. One for `single`; two for a `compare` diptych; N for variations/overview-focus/document."),model:E().optional().describe("Model attribution."),issue:$t().optional().describe("Linked issue number."),publish:It().optional().describe("Publish to a shareable public URL on compose (requires a paid plan). Default false."),commit:It().optional().describe("Commit to the team library (sends status: 'published'). Default false — lands a workspace draft."),prompt:E().optional().describe("OPTIONAL brief that produced this fig (DB-only)."),new:It().optional().describe("Start a SEPARATE chain even though the team already has a near-identical one. Figura REFUSES a fresh chain when this fig looks like the next round of an open question, and names the chain to revise instead (figura_revise_fig) — so an exercise stays one walkable history with one discussion. Pass true ONLY when this genuinely is a different question; forking because revising felt like more work is what leaves a reviewer reading round 4 with no sight of rounds 1-3."),kind:ue(U$).optional().describe("'child' composes the fig as frameless screen CONTENT another fig embeds — it stays out of the team library and the fig listing. Default 'fig'. Compose the children first, then pass their ids as `screens[].childFig` on a `single` or `compare` parent.")}},async(e)=>{try{let t={layout:e.layout,screens:e.screens};for(let n of["title","description","area","tags","orientation","device","locale","sharedCss","model","issue","publish","prompt","kind","new"])if(e[n]!==void 0)t[n]=e[n];if(e.commit)t.status="published";let r=Pc(_o,await gf());return t.toolchain=r,ye(Cc(await ss(await de("/v1/figs/compose",{method:"POST",body:t})),r.skill.drift))}catch(t){return he(t)}});ke.registerTool("figura_upload_asset",{title:"Figura: upload asset",description:"Upload a durable image asset and get back a STABLE, figura-hosted URL that never expires — use it in a fig's <img src> instead of a base64 data-URI (bloats the HTML past the publish size) or an external URL that expires (Instagram/CDN signed links). The fig CSP allows figura-hosted images. Provide `path` (a local image file), `url` (an http(s) image to fetch and re-host), or `data` (base64 bytes) + `contentType`. Accepts png/jpeg/gif/webp/avif/svg, up to 5MB. Returns `{ url }`.",inputSchema:{path:E().optional().describe("Local path to an image file to upload (content-type inferred from the extension)."),url:E().optional().describe("http(s) URL of an image to fetch and re-host (alternative to `path`) — use for expiring/signed source URLs so the fig keeps rendering after they die."),data:E().optional().describe("Base64-encoded image bytes (alternative to `path`/`url`). Requires `contentType`."),contentType:E().optional().describe("MIME type, e.g. image/png. Required with `data`; inferred from the extension/response for `path`/`url`.")}},async(e)=>{try{let t=e.path??e.url;if(t){let{data:r,contentType:n}=await F$(t,e.contentType);return ye(await de("/v1/assets",{method:"POST",body:{data:r,contentType:n}}))}if(!e.data)throw Error("Provide `path` (a local image file), `url` (an http(s) image), or `data` (base64 bytes).");if(!e.contentType)throw Error("`contentType` is required with `data` — e.g. image/png.");return ye(await de("/v1/assets",{method:"POST",body:{data:e.data,contentType:e.contentType}}))}catch(t){return he(t)}});ke.registerTool("figura_generate_fig",{title:"Figura: generate fig",description:"Generate a new fig server-side from a natural-language brief, then persist it — this HOSTS it (the create IS the hosting). The engine runs Figura's on-brand generation — you do NOT write the HTML; just describe the screen. SPENDS TEAM CREDITS: only use when the user explicitly opts for a server render; otherwise default to writing the HTML yourself and landing it with figura_create_fig (free, uses the calling model). Runs as an async server job; this call polls until the fig lands (typically 30–90s). Returns the created fig (id, slug) and `viewUrl` — ALWAYS a link you can open for approval (a team-scoped viewer when unpublished, the public share url once published). Like figura_create_fig, the generated fig lands as a workspace DRAFT — not in the team library, silent for teammates — commit the session's final pick with figura_commit_fig. Requires an active paid subscription.",inputSchema:{prompt:E().describe("A natural-language brief describing the screen/UI to generate."),area:bo(),orientation:ue(as).optional(),mode:ue(Dc).optional(),platform:ue(["mobile","web"]).optional().describe("Output platform: 'mobile' (iPhone frame) or 'web' (browser frame). When omitted, the engine INFERS it from the brief — a desktop/web/browser/landing-page/dashboard brief renders web, an iPhone/mobile/app-screen brief renders mobile — falling back to mobile only when neither is signalled. Pass this to force a platform regardless of the wording."),device:E().optional().describe("Catalog device id to target (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9'). Mobile only; default iphone-16 (pixel-9 when os is 'android')."),os:ue(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),title:E().optional().describe("Title (otherwise derived from the generated HTML)."),fidelity:ue(["fast","high"]).optional().describe("Generation fidelity (default fast)."),publish:It().optional().describe("Publish to a shareable public URL on create (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately, so only set this when the human explicitly wants a link they can share outside the team.")}},async(e)=>{try{let t={prompt:e.prompt};for(let o of["area","orientation","mode","platform","device","os","title","publish"])if(e[o]!==void 0)t[o]=e[o];if(e.fidelity!==void 0)t.model=e.fidelity;let r=Pc(_o,await gf());t.toolchain=r,t.async=!0;let n=await de("/v1/figs/generate",{method:"POST",body:t});if(n&&typeof n==="object"&&typeof n.jobId==="string"){let o=await y4(n.jobId),i=o.result??{};return ye(Cc(await ss(i.fig??o.result),r.skill.drift))}return ye(Cc(await ss(n),r.skill.drift))}catch(t){return he(t)}});ke.registerTool("figura_fig_scaffold",{title:"Figura: fig scaffold",description:"Return the CANONICAL fig authoring scaffold — the exact system prompt Figura injects when it renders a fig server-side (design rules + exemplars + accent hints + your team's composed brand + the component/device kit context), composed for a target (platform/device/area/mode/orientation). USE THIS on the hand-build path (before writing a fig's HTML with figura_create_fig): author against this scaffold instead of a hand-maintained copy of the guidance, so your fig follows the SAME rules + brand the server would. Read-only — no fig is created, no credits are spent. Returns { scaffold, platform, mode, orientation, area, areas, device, brand } — `areas` is your team's existing areas with fig counts, most-used first; pick `area` from it rather than inventing one.",inputSchema:{platform:ue(["mobile","web"]).optional().describe("Target platform: 'mobile' (iPhone frame, default) or 'web' (browser frame)."),device:E().optional().describe("Catalog device id (e.g. 'iphone-16', 'iphone-17-pro', 'pixel-9'). Mobile only; default iphone-16 (pixel-9 when os is 'android')."),os:ue(["ios","android"]).optional().describe("Mobile OS the fig targets: 'ios' (default) or 'android'. Drives the device frame, system-bar heights, back affordance, sheet-vs-dialog, app-bar-vs-bottom-nav, and corner radii. Omit to use the team brand's mobile `os`. An explicit `device` wins over it."),area:bo(),orientation:ue(as).optional(),mode:ue(Dc).optional()}},async(e)=>{try{let t=new URLSearchParams;for(let n of["platform","device","os","area","orientation","mode"])if(e[n]!==void 0)t.set(n,String(e[n]));let r=t.toString();return ye(await de(`/v1/fig/scaffold${r?`?${r}`:""}`))}catch(t){return he(t)}});ke.registerTool("figura_fig_devices",{title:"Figura: fig devices",description:"Return the CANONICAL framed-device catalog — every valid `data-device` id plus its per-device geometry (os ios|android, logical dims portrait/landscape, safe-area insets, cutout island|notch|punch|none, corner radius). USE THIS when authoring a CANVAS COMPOSITION fig that frames a specific phone in-fig (a `.fig-device` element with `data-device` set): pick a real id from here instead of guessing, since an unknown data-device silently gets NO frame. Pass `os` to narrow the catalog to one platform's phones (an Android fig must NOT be framed in an iPhone). Read-only — no fig is created, no credits are spent. Returns { devices, default }.",inputSchema:{os:ue(["ios","android"]).optional().describe("Only return this OS's devices, and its default frame ('pixel-9' for android).")}},async(e)=>{try{let t=e.os?`?os=${e.os}`:"";return ye(await de(`/v1/fig/devices${t}`))}catch(t){return he(t)}});ke.registerTool("figura_revise_fig",{title:"Figura: revise fig",description:"Create a new revision (version) of an existing fig — from updated HTML, or from TYPED SCREENS. Two shapes, and which one you use is decided by the fig: a fig composed BY REFERENCE (screens that are `childFig` references — figura_get_fig reports `composesByReference` and returns its `children`) can ONLY be revised by typed screens; passing `html` for one is refused 422, because a text revise would leave its typed references, pinned versions and labels behind on the old version. TYPED REVISE: pass `layout` + `screens`, the same shape figura_compose_fig takes, and Figura re-composes. Every child reference is carried into the new revision with the same pin, label, notes and position; leave a screen `{}` (empty) to keep a REFERENCED slot untouched (an INLINE slot must have its `html` re-sent), or give it `html`/`childFig` to change it. The previous revision keeps its own children resolving at their pins. Returns the new fig (id, slug, version) and `viewUrl` — ALWAYS a link to open and re-review. The revision lands as a workspace DRAFT regardless of the parent's status — not in the team library, silent for teammates — so iterate freely; when a revision is the session's final agreed version, commit it (`commit: true` on that call, or figura_commit_fig). Publishing is NOT inherited from the fig being revised: the new revision defaults to unpublished (a team-scoped viewer `viewUrl`) even if the fig it revises is currently live — the existing public link keeps serving the OLD version until you pass `publish: true` on THIS call, which republishes at the SAME stable link (same publicId across the chain). The new version joins the original fig's chain — it does not replace it in place. Use list_revisions for the chain (rootFig + every version). The response also carries `brandWarnings` — a deterministic (no-LLM) colors/fonts/radii/spacing diff against the team's brand tokens, WARN-only. If it comes back non-empty, consider one more revision that binds the missing tokens. To include REAL images (screenshots/photos/logos), pass them via `images` — uploaded to durable figura hosting, stable URLs substituted into the HTML.",inputSchema:{id:E().describe("The fig to revise — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),html:E().optional().describe("The full updated HTML document. Use this OR `layout` + `screens`, never both."),layout:ue(V$).optional().describe("TYPED REVISE: the composition to re-emit. Required with `screens`, and not inherited — the stored fig records a lossy `mode`, not the layout."),screens:Me(G$).optional().describe("TYPED REVISE: the screens, positionally. An EMPTY object `{}` keeps a REFERENCED slot exactly as the previous revision had it — same child fig, same pinned version, same label, same notes, same device. Send `notes: []` to clear that slot's annotations. It works only over a slot that was a `childFig`: a slot that held INLINE `html` must have its html sent again (Figura does not read it back out of the composed document), and a blank one is refused 422. Give a slot `childFig` (a different child, or the same one with a new `label`) or `html` to change it."),sharedCss:E().optional().describe("TYPED REVISE: the ONE stylesheet all screens share."),images:Z$(),title:E().optional().describe("Title (otherwise derived from the HTML)."),description:Nc(),area:E().optional().describe("Product area / surface; free text. Inherited from the parent if omitted."),tags:Me(E()).optional(),orientation:ue(as).optional().describe("Inherited from the parent if omitted."),mode:ue(Dc).optional(),model:E().optional().describe("Model attribution."),issue:$t().optional().describe("Linked issue number."),locale:E().optional().describe("BCP-47 tag of the brand locale this revision renders in (must be one of the brand's identity.locales) — stamps <html lang dir> and loads the per-script font."),publish:It().optional().describe("Publish the new revision to a shareable public URL (requires a paid plan). Default false — the response's `viewUrl` is already open-able team-privately. If the fig being revised is ALREADY published, pass true here too or its public link keeps serving the prior version. Share link ONLY — does not commit the revision to the team library (that's `commit`)."),commit:It().optional().describe("Commit this revision to the team library (sends status: 'published'). Default false — the revision lands as a workspace DRAFT even when the fig it revises is committed. Set true ONLY when this revision is the session's final agreed version; intermediate iterations stay drafts. Committing later: figura_commit_fig."),prompt:E().optional().describe("OPTIONAL: the brief/ask that produced this revision, if there was one. Stored on the fig (DB-only, never stamped into the HTML), and returned by figura_get_fig.")}},async(e)=>{try{if(!e.html&&!e.screens)return he(Error("revise needs `html`, or `layout` + `screens` for a typed revise."));if(e.html&&e.screens)return he(Error("revise takes `html` OR `layout` + `screens`, never both."));let t=e.screens,{parts:r,uploaded:n}=await B$(e.html?[e.html]:[...(t??[]).flatMap((i)=>[i.html,i.css]),e.sharedCss],e.images),o=e.html?{html:r[0]}:{};for(let i of["title","description","area","tags","orientation","mode","model","issue","locale","publish","prompt","layout"])if(e[i]!==void 0)o[i]=e[i];if(t){if(o.screens=t.map((i,s)=>({...i,...i.html!==void 0?{html:r[s*2]}:{},...i.css!==void 0?{css:r[s*2+1]}:{}})),e.sharedCss!==void 0)o.sharedCss=r[r.length-1]}if(e.commit)o.status="published";return ye(H$(await de(`/v1/figs/${encodeURIComponent(e.id)}/revise`,{method:"POST",body:o}),n))}catch(t){return he(t)}});ke.registerTool("figura_list_revisions",{title:"Figura: list revisions",description:"List the full revision chain for a fig (all versions sharing a root), oldest to newest.",inputSchema:{id:E().describe("Any fig in the chain — its id (`fig_…`), a UUID, share link/URL, or publicId.")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}/revisions`))}catch(t){return he(t)}});ke.registerTool("figura_merge_figs",{title:"Figura: merge fig chains",description:"Fold one fig's chain INTO another's, so a question that was explored as separate sibling figs becomes ONE chain whose versions read in order. Use it when you (or an earlier session) landed a fresh fig for what is really the next round of an existing exercise — the library shows one card per question instead of N near-duplicates, and the whole decision trail is walkable. The source chain's versions are appended after the destination's head, oldest first; share links keep resolving, and verdicts/decisions follow the chain. Pass `dry_run` first to see the plan. Prefer NOT creating the fork in the first place: revise the existing fig (figura_revise_fig) rather than minting a sibling.",inputSchema:{id:E().describe("The fig whose chain MOVES — any version of it (`fig_…`, a UUID, a share link/URL, or its publicId)."),into:E().describe("The fig whose chain it joins — any version of the destination. Its root stays the chain root."),dry_run:It().optional().describe("Return the plan (which versions land at which numbers) without writing. Default false.")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}/merge`,{method:"POST",body:{into:e.into,dryRun:e.dry_run===!0}}))}catch(t){return he(t)}});ke.registerTool("figura_commit_fig",{title:"Figura: commit fig",description:"Commit a fig to the team library (status draft → published). Machine-created figs land as workspace DRAFTS — hosted, viewable via `viewUrl`, visible to their author, but NOT in the team library and silent for teammates. Committing is the explicit act that puts one in the team library and notifies the team (digest-batched) — so commit ONLY the session's final recommendation (the fig the user asked for / signed off on), never every exploration or intermediate iteration. If the final fig is one you're about to create/revise anyway, prefer `commit: true` on that call over a separate commit here. Orthogonal to figura_publish_fig (the public share link): a shared draft's URL resolves fine, and committing creates no link. Idempotent. Pass `uncommit: true` to reverse it (published → draft; the share link is untouched). Returns { id, status, committed, alreadyCommitted, viewUrl }.",inputSchema:{id:E().describe("The fig to commit — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),uncommit:It().optional().describe("Set true to uncommit: the fig leaves the team library back to an author-visible workspace draft. Defaults to false (commit).")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}/${e.uncommit?"uncommit":"commit"}`,{method:"POST",body:{}}))}catch(t){return he(t)}});ke.registerTool("figura_publish_fig",{title:"Figura: publish fig",description:"Publish (or unpublish) an existing fig to its shareable public URL. The fig is ALREADY hosted and viewable team-privately without this (figura_create_fig/figura_revise_fig's `viewUrl`) — only call this once the human wants a link they can share outside the team. Share link ONLY — it does not put the fig in the team library (that's figura_commit_fig; a shared draft's URL resolves fine). Requires a paid plan. Returns { isPublic, url, publicId, viewUrl }. Publishing a fig that composes other figs (`childFig` screens) makes its CHILDREN reachable at that public link too — they are served with the parent that references them. A CHILD fig has no share link of its own and publishing one is refused: publish the parent.",inputSchema:{id:E().describe("The fig to publish — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),isPublic:It().optional().describe("Set false to unpublish (make private). Defaults to true (publish).")}},async(e)=>{try{let t={};if(e.isPublic!==void 0)t.isPublic=e.isPublic;return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}/publish`,{method:"POST",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_list_figs",{title:"Figura: list figs",description:"List visualizations for the team, optionally filtered by area or tag.",inputSchema:{area:bo(),tag:E().optional(),limit:$t().optional(),cursor:E().optional()}},async(e)=>{try{let t=new URLSearchParams;if(e.area)t.set("area",e.area);if(e.tag)t.set("tag",e.tag);if(e.limit!==void 0)t.set("limit",String(e.limit));if(e.cursor)t.set("cursor",e.cursor);let r=t.toString();return ye(await de(`/v1/figs${r?`?${r}`:""}`))}catch(t){return he(t)}});ke.registerTool("figura_get_fig",{title:"Figura: get fig",description:"Fetch a single visualization by id. The response carries `viewUrl` — ALWAYS a link you can open for approval (a team-scoped viewer when unpublished, the public share url once published). For a fig composed BY REFERENCE (`composesByReference: true`) it also returns `children` — each screen’s child fig id, pinned version, position and label. That is what you edit: send them back as `screens` on figura_revise_fig to change the composition, or as `screens` on figura_compose_fig to build a copy.",inputSchema:{id:E().describe("The fig — its id (`fig_…`), a UUID, a share link/URL, or its publicId.")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}`))}catch(t){return he(t)}});ke.registerTool("figura_comment",{title:"Figura: comment",description:"Add a comment to a visualization.",inputSchema:{fig_id:E().describe("The fig to comment on — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),body:E().describe("Comment text.")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.fig_id)}/comments`,{method:"POST",body:{body:e.body}}))}catch(t){return he(t)}});ke.registerTool("figura_request_feedback",{title:"Figura: request feedback",description:"Ask a teammate to review a fig. Resolve `from` to a team member (by name or email); they get a notification (in-app, push, email) and the discussion happens in the fig's comment thread. Use this when the user says they want a specific person's feedback/eyes/review on a fig. Returns { ok, request: { to, status }, figUrl }.",inputSchema:{id:E().describe("The fig to request feedback on — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),from:E().describe("The teammate to ask, by name or email (resolved within the team)."),note:E().optional().describe("Optional message for them (e.g. what to look at).")}},async(e)=>{try{let t={from:e.from};if(e.note!==void 0)t.note=e.note;return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}/request-feedback`,{method:"POST",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_list_sources",{title:"Figura: list sources",description:"List the company-brain source-spine connectors for the team, with event counts and last-synced times.",inputSchema:{}},async()=>{try{return ye(await de("/v1/sources"))}catch(e){return he(e)}});ke.registerTool("figura_sync_source",{title:"Figura: sync source",description:"Ingest new events from a connected source into the spine. Returns { ingested, fetched, nextCursor }.",inputSchema:{id:E().describe("The source id to sync (from figura_list_sources).")}},async(e)=>{try{return ye(await de(`/v1/sources/${encodeURIComponent(e.id)}/sync`,{method:"POST"}))}catch(t){return he(t)}});ke.registerTool("figura_add_signal",{title:"Figura: add signal",description:"Put an external moment (a link, a news item, a discourse thread) on the company brain's radar. It skips the holding pen and becomes a `signal` event the story miner joins against the team's theses on the next sync. Give a url, a title, or both.",inputSchema:{url:E().url().optional().describe("Link to the moment."),title:E().max(300).optional().describe("One line on what the moment is; defaults to the link host + path."),excerpt:E().max(2000).optional().describe("Optional context the miner can quote.")}},async(e)=>{try{if(!e.url&&!e.title)return he(Error("Give a url or a title."));return ye(await de("/v1/signals",{method:"POST",body:{url:e.url??null,title:e.title??"",excerpt:e.excerpt??"",source:"mcp"}}))}catch(t){return he(t)}});ke.registerTool("figura_mine_screens",{title:"Figura: mine screens",description:"Build the app's screen catalog from a connected git source's CURRENT file tree (framework-aware, convention-based — no file bodies, no fig generation, no credits). Returns { screens: [{slug,name,path,framework}], framework, count, commitSha, truncated }.",inputSchema:{id:E().describe("The git source id to mine (from figura_list_sources).")}},async(e)=>{try{return ye(await de(`/v1/sources/${encodeURIComponent(e.id)}/mine-screens`,{method:"POST"}))}catch(t){return he(t)}});ke.registerTool("figura_list_screens",{title:"Figura: list screens",description:"Read the team's mined screen catalog — the app's current screens ({slug,name,path,framework}) plus when it was last mined. Free, read-only. Run figura_mine_screens first to populate it.",inputSchema:{}},async()=>{try{return ye(await de("/v1/sources/screens"))}catch(e){return he(e)}});ke.registerTool("figura_update_fig",{title:"Figura: update fig",description:"Update a fig's METADATA only (title/description/area/tags/status). Set status='archived' to soft-delete. For library membership (draft ⇄ published) prefer figura_commit_fig — a status PATCH here is a silent metadata setter that never notifies the team. To change the fig's HTML, use figura_revise_fig — it saves a new version and never destroys the old one. update cannot touch the HTML.",inputSchema:{id:E().describe("The fig to update — its id (`fig_…`), a UUID, a share link/URL, or its publicId."),title:E().optional(),description:Nc(),area:bo(),tags:Me(E()).optional().describe("Replaces the existing tags."),status:ue(["draft","published","archived"]).optional(),outcome:E().optional().describe(`ONE line on how THIS round ended, for the chain's shortlist: what it won, and why it lost. Write it when a round is superseded or a chain lands — the chain page derives every other field it shows (versions, verdict tallies, the decision, who was asked) from rows, and this is the single judgement no event can hold. Terse and concrete ("widest-reading plate of the set; spent the cinematic signature"), max 400 chars. Send an empty string to clear it.`)}},async(e)=>{try{let t={};if(e.title!==void 0)t.title=e.title;if(e.outcome!==void 0)t.outcome=e.outcome;if(e.description!==void 0)t.description=e.description;if(e.area!==void 0)t.area=e.area;if(e.tags!==void 0)t.tags=e.tags;if(e.status!==void 0)t.status=e.status;return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}`,{method:"PATCH",body:t}))}catch(t){return he(t)}});ke.registerTool("figura_delete_fig",{title:"Figura: archive fig",description:"Archive a fig — the only deletion available here. It leaves the library and its public link stops resolving, but the fig, its comments and its feedback requests are kept and can be restored. There is NO permanent delete on this surface: use this for superseded drafts and cleanup. A genuine erasure request is a human action in the web app, by the fig author or a team admin. Archiving a CHILD fig does NOT blank the figs embedding it — every pinned reference keeps rendering the exact version it names — but the child can no longer be referenced by a new composition; the response reports `embeddedBy`, how many figs hold a reference to it.",inputSchema:{id:E().describe("The fig to archive — its id (`fig_…`), a UUID, a share link/URL, or its publicId.")}},async(e)=>{try{return ye(await de(`/v1/figs/${encodeURIComponent(e.id)}`,{method:"DELETE"}))}catch(t){return he(t)}});(async()=>{let{apiUrl:e}=await jc();await j$(_o,Ic,zc(e))})();q$();await ke.connect(new Ym);
|