vantage-mcp-server 2.4.0 → 2.6.0

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.
Files changed (3) hide show
  1. package/index.js +66 -51
  2. package/index.js.map +4 -4
  3. package/package.json +1 -1
package/index.js CHANGED
@@ -1,22 +1,22 @@
1
1
  #!/usr/bin/env node
2
- "use strict";var NS=Object.create;var Zd=Object.defineProperty;var RS=Object.getOwnPropertyDescriptor;var CS=Object.getOwnPropertyNames;var AS=Object.getPrototypeOf,DS=Object.prototype.hasOwnProperty;var b=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),mn=(e,t)=>{for(var r in t)Zd(e,r,{get:t[r],enumerable:!0})},qS=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of CS(t))!DS.call(e,n)&&n!==r&&Zd(e,n,{get:()=>t[n],enumerable:!(o=RS(t,n))||o.enumerable});return e};var Vt=(e,t,r)=>(r=e!=null?NS(AS(e)):{},qS(t||!e||!e.__esModule?Zd(r,"default",{value:e,enumerable:!0}):r,e));var qs=b(me=>{"use strict";Object.defineProperty(me,"__esModule",{value:!0});me.regexpCode=me.getEsmExportName=me.getProperty=me.safeStringify=me.stringify=me.strConcat=me.addCodeArg=me.str=me._=me.nil=me._Code=me.Name=me.IDENTIFIER=me._CodeOrName=void 0;var As=class{};me._CodeOrName=As;me.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Pn=class extends As{constructor(t){if(super(),!me.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};me.Name=Pn;var Rt=class extends As{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,o)=>`${r}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,o)=>(o instanceof Pn&&(r[o.str]=(r[o.str]||0)+1),r),{})}};me._Code=Rt;me.nil=new Rt("");function lb(e,...t){let r=[e[0]],o=0;for(;o<t.length;)Rm(r,t[o]),r.push(e[++o]);return new Rt(r)}me._=lb;var Nm=new Rt("+");function db(e,...t){let r=[Ds(e[0])],o=0;for(;o<t.length;)r.push(Nm),Rm(r,t[o]),r.push(Nm,Ds(e[++o]));return ZI(r),new Rt(r)}me.str=db;function Rm(e,t){t instanceof Rt?e.push(...t._items):t instanceof Pn?e.push(t):e.push(FI(t))}me.addCodeArg=Rm;function ZI(e){let t=1;for(;t<e.length-1;){if(e[t]===Nm){let r=LI(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function LI(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof Pn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof Pn))return`"${e}${t.slice(1)}`}function VI(e,t){return t.emptyStr()?e:e.emptyStr()?t:db`${e}${t}`}me.strConcat=VI;function FI(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:Ds(Array.isArray(e)?e.join(","):e)}function GI(e){return new Rt(Ds(e))}me.stringify=GI;function Ds(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}me.safeStringify=Ds;function WI(e){return typeof e=="string"&&me.IDENTIFIER.test(e)?new Rt(`.${e}`):lb`[${e}]`}me.getProperty=WI;function KI(e){if(typeof e=="string"&&me.IDENTIFIER.test(e))return new Rt(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}me.getEsmExportName=KI;function HI(e){return new Rt(e.toString())}me.regexpCode=HI});var Dm=b(vt=>{"use strict";Object.defineProperty(vt,"__esModule",{value:!0});vt.ValueScope=vt.ValueScopeName=vt.Scope=vt.varKinds=vt.UsedValueState=void 0;var gt=qs(),Cm=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},yl;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(yl||(vt.UsedValueState=yl={}));vt.varKinds={const:new gt.Name("const"),let:new gt.Name("let"),var:new gt.Name("var")};var $l=class{constructor({prefixes:t,parent:r}={}){this._names={},this._prefixes=t,this._parent=r}toName(t){return t instanceof gt.Name?t:this.name(t)}name(t){return new gt.Name(this._newName(t))}_newName(t){let r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,o;if(!((o=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};vt.Scope=$l;var bl=class extends gt.Name{constructor(t,r){super(r),this.prefix=t}setValue(t,{property:r,itemIndex:o}){this.value=t,this.scopePath=(0,gt._)`.${new gt.Name(r)}[${o}]`}};vt.ValueScopeName=bl;var JI=(0,gt._)`\n`,Am=class extends $l{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?JI:gt.nil}}get(){return this._scope}name(t){return new bl(t,this._newName(t))}value(t,r){var o;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(t),{prefix:i}=n,s=(o=r.key)!==null&&o!==void 0?o:r.ref,a=this._values[i];if(a){let l=a.get(s);if(l)return l}else a=this._values[i]=new Map;a.set(s,n);let c=this._scope[i]||(this._scope[i]=[]),u=c.length;return c[u]=r.ref,n.setValue(r,{property:i,itemIndex:u}),n}getValue(t,r){let o=this._values[t];if(o)return o.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,gt._)`${t}${o.scopePath}`})}scopeCode(t=this._values,r,o){return this._reduceValues(t,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},r,o)}_reduceValues(t,r,o={},n){let i=gt.nil;for(let s in t){let a=t[s];if(!a)continue;let c=o[s]=o[s]||new Map;a.forEach(u=>{if(c.has(u))return;c.set(u,yl.Started);let l=r(u);if(l){let d=this.opts.es5?vt.varKinds.var:vt.varKinds.const;i=(0,gt._)`${i}${d} ${u} = ${l};${this.opts._n}`}else if(l=n?.(u))i=(0,gt._)`${i}${l}${this.opts._n}`;else throw new Cm(u);c.set(u,yl.Completed)})}return i}};vt.ValueScope=Am});var oe=b(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.or=re.and=re.not=re.CodeGen=re.operators=re.varKinds=re.ValueScopeName=re.ValueScope=re.Scope=re.Name=re.regexpCode=re.stringify=re.getProperty=re.nil=re.strConcat=re.str=re._=void 0;var le=qs(),Jt=Dm(),Jr=qs();Object.defineProperty(re,"_",{enumerable:!0,get:function(){return Jr._}});Object.defineProperty(re,"str",{enumerable:!0,get:function(){return Jr.str}});Object.defineProperty(re,"strConcat",{enumerable:!0,get:function(){return Jr.strConcat}});Object.defineProperty(re,"nil",{enumerable:!0,get:function(){return Jr.nil}});Object.defineProperty(re,"getProperty",{enumerable:!0,get:function(){return Jr.getProperty}});Object.defineProperty(re,"stringify",{enumerable:!0,get:function(){return Jr.stringify}});Object.defineProperty(re,"regexpCode",{enumerable:!0,get:function(){return Jr.regexpCode}});Object.defineProperty(re,"Name",{enumerable:!0,get:function(){return Jr.Name}});var Sl=Dm();Object.defineProperty(re,"Scope",{enumerable:!0,get:function(){return Sl.Scope}});Object.defineProperty(re,"ValueScope",{enumerable:!0,get:function(){return Sl.ValueScope}});Object.defineProperty(re,"ValueScopeName",{enumerable:!0,get:function(){return Sl.ValueScopeName}});Object.defineProperty(re,"varKinds",{enumerable:!0,get:function(){return Sl.varKinds}});re.operators={GT:new le._Code(">"),GTE:new le._Code(">="),LT:new le._Code("<"),LTE:new le._Code("<="),EQ:new le._Code("==="),NEQ:new le._Code("!=="),NOT:new le._Code("!"),OR:new le._Code("||"),AND:new le._Code("&&"),ADD:new le._Code("+")};var Sr=class{optimizeNodes(){return this}optimizeNames(t,r){return this}},qm=class extends Sr{constructor(t,r,o){super(),this.varKind=t,this.name=r,this.rhs=o}render({es5:t,_n:r}){let o=t?Jt.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${n};`+r}optimizeNames(t,r){if(t[this.name.str])return this.rhs&&(this.rhs=Ro(this.rhs,t,r)),this}get names(){return this.rhs instanceof le._CodeOrName?this.rhs.names:{}}},wl=class extends Sr{constructor(t,r,o){super(),this.lhs=t,this.rhs=r,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(!(this.lhs instanceof le.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=Ro(this.rhs,t,r),this}get names(){let t=this.lhs instanceof le.Name?{}:{...this.lhs.names};return xl(t,this.rhs)}},Mm=class extends wl{constructor(t,r,o,n){super(t,o,n),this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},Um=class extends Sr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},Zm=class extends Sr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},Lm=class extends Sr{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},Vm=class extends Sr{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){return this.code=Ro(this.code,t,r),this}get names(){return this.code instanceof le._CodeOrName?this.code.names:{}}},Ms=class extends Sr{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((r,o)=>r+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,r=t.length;for(;r--;){let o=t[r].optimizeNodes();Array.isArray(o)?t.splice(r,1,...o):o?t[r]=o:t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){let{nodes:o}=this,n=o.length;for(;n--;){let i=o[n];i.optimizeNames(t,r)||(BI(t,i.names),o.splice(n,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>In(t,r.names),{})}},Tr=class extends Ms{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},Fm=class extends Ms{},No=class extends Tr{};No.kind="else";var zn=class e extends Tr{constructor(t,r){super(r),this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);return this.else&&(r+="else "+this.else.render(t)),r}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let r=this.else;if(r){let o=r.optimizeNodes();r=this.else=Array.isArray(o)?new No(o):o}if(r)return t===!1?r instanceof e?r:r.nodes:this.nodes.length?this:new e(pb(t),r instanceof e?[r]:r.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,r){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,r),!!(super.optimizeNames(t,r)||this.else))return this.condition=Ro(this.condition,t,r),this}get names(){let t=super.names;return xl(t,this.condition),this.else&&In(t,this.else.names),t}};zn.kind="if";var En=class extends Tr{};En.kind="for";var Gm=class extends En{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iteration=Ro(this.iteration,t,r),this}get names(){return In(super.names,this.iteration.names)}},Wm=class extends En{constructor(t,r,o,n){super(),this.varKind=t,this.name=r,this.from=o,this.to=n}render(t){let r=t.es5?Jt.varKinds.var:this.varKind,{name:o,from:n,to:i}=this;return`for(${r} ${o}=${n}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=xl(super.names,this.from);return xl(t,this.to)}},kl=class extends En{constructor(t,r,o,n){super(),this.loop=t,this.varKind=r,this.name=o,this.iterable=n}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iterable=Ro(this.iterable,t,r),this}get names(){return In(super.names,this.iterable.names)}},Us=class extends Tr{constructor(t,r,o){super(),this.name=t,this.args=r,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};Us.kind="func";var Zs=class extends Ms{render(t){return"return "+super.render(t)}};Zs.kind="return";var Km=class extends Tr{render(t){let r="try"+super.render(t);return this.catch&&(r+=this.catch.render(t)),this.finally&&(r+=this.finally.render(t)),r}optimizeNodes(){var t,r;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(t,r){var o,n;return super.optimizeNames(t,r),(o=this.catch)===null||o===void 0||o.optimizeNames(t,r),(n=this.finally)===null||n===void 0||n.optimizeNames(t,r),this}get names(){let t=super.names;return this.catch&&In(t,this.catch.names),this.finally&&In(t,this.finally.names),t}},Ls=class extends Tr{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};Ls.kind="catch";var Vs=class extends Tr{render(t){return"finally"+super.render(t)}};Vs.kind="finally";var Hm=class{constructor(t,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
3
- `:""},this._extScope=t,this._scope=new Jt.Scope({parent:t}),this._nodes=[new Fm]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){let o=this._extScope.value(t,r);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,o,n){let i=this._scope.toName(r);return o!==void 0&&n&&(this._constants[i.str]=o),this._leafNode(new qm(t,i,o)),i}const(t,r,o){return this._def(Jt.varKinds.const,t,r,o)}let(t,r,o){return this._def(Jt.varKinds.let,t,r,o)}var(t,r,o){return this._def(Jt.varKinds.var,t,r,o)}assign(t,r,o){return this._leafNode(new wl(t,r,o))}add(t,r){return this._leafNode(new Mm(t,re.operators.ADD,r))}code(t){return typeof t=="function"?t():t!==le.nil&&this._leafNode(new Vm(t)),this}object(...t){let r=["{"];for(let[o,n]of t)r.length>1&&r.push(","),r.push(o),(o!==n||this.opts.es5)&&(r.push(":"),(0,le.addCodeArg)(r,n));return r.push("}"),new le._Code(r)}if(t,r,o){if(this._blockNode(new zn(t)),r&&o)this.code(r).else().code(o).endIf();else if(r)this.code(r).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new zn(t))}else(){return this._elseNode(new No)}endIf(){return this._endBlockNode(zn,No)}_for(t,r){return this._blockNode(t),r&&this.code(r).endFor(),this}for(t,r){return this._for(new Gm(t),r)}forRange(t,r,o,n,i=this.opts.es5?Jt.varKinds.var:Jt.varKinds.let){let s=this._scope.toName(t);return this._for(new Wm(i,s,r,o),()=>n(s))}forOf(t,r,o,n=Jt.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let s=r instanceof le.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,le._)`${s}.length`,a=>{this.var(i,(0,le._)`${s}[${a}]`),o(i)})}return this._for(new kl("of",n,i,r),()=>o(i))}forIn(t,r,o,n=this.opts.es5?Jt.varKinds.var:Jt.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,le._)`Object.keys(${r})`,o);let i=this._scope.toName(t);return this._for(new kl("in",n,i,r),()=>o(i))}endFor(){return this._endBlockNode(En)}label(t){return this._leafNode(new Um(t))}break(t){return this._leafNode(new Zm(t))}return(t){let r=new Zs;if(this._blockNode(r),this.code(t),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(Zs)}try(t,r,o){if(!r&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new Km;if(this._blockNode(n),this.code(t),r){let i=this.name("e");this._currNode=n.catch=new Ls(i),r(i)}return o&&(this._currNode=n.finally=new Vs,this.code(o)),this._endBlockNode(Ls,Vs)}throw(t){return this._leafNode(new Lm(t))}block(t,r){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(r),this}endBlock(t){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-r;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=r,this}func(t,r=le.nil,o,n){return this._blockNode(new Us(t,r,o)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(Us)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,r){let o=this._currNode;if(o instanceof t||r&&o instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){let r=this._currNode;if(!(r instanceof zn))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let r=this._nodes;r[r.length-1]=t}};re.CodeGen=Hm;function In(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function xl(e,t){return t instanceof le._CodeOrName?In(e,t.names):e}function Ro(e,t,r){if(e instanceof le.Name)return o(e);if(!n(e))return e;return new le._Code(e._items.reduce((i,s)=>(s instanceof le.Name&&(s=o(s)),s instanceof le._Code?i.push(...s._items):i.push(s),i),[]));function o(i){let s=r[i.str];return s===void 0||t[i.str]!==1?i:(delete t[i.str],s)}function n(i){return i instanceof le._Code&&i._items.some(s=>s instanceof le.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function BI(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function pb(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,le._)`!${Jm(e)}`}re.not=pb;var YI=fb(re.operators.AND);function XI(...e){return e.reduce(YI)}re.and=XI;var QI=fb(re.operators.OR);function ej(...e){return e.reduce(QI)}re.or=ej;function fb(e){return(t,r)=>t===le.nil?r:r===le.nil?t:(0,le._)`${Jm(t)} ${e} ${Jm(r)}`}function Jm(e){return e instanceof le.Name?e:(0,le._)`(${e})`}});var he=b(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.checkStrictMode=ie.getErrorPath=ie.Type=ie.useFunc=ie.setEvaluated=ie.evaluatedPropsToName=ie.mergeEvaluated=ie.eachItem=ie.unescapeJsonPointer=ie.escapeJsonPointer=ie.escapeFragment=ie.unescapeFragment=ie.schemaRefOrVal=ie.schemaHasRulesButRef=ie.schemaHasRules=ie.checkUnknownRules=ie.alwaysValidSchema=ie.toHash=void 0;var Te=oe(),tj=qs();function rj(e){let t={};for(let r of e)t[r]=!0;return t}ie.toHash=rj;function nj(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(gb(e,t),!vb(t,e.self.RULES.all))}ie.alwaysValidSchema=nj;function gb(e,t=e.schema){let{opts:r,self:o}=e;if(!r.strictSchema||typeof t=="boolean")return;let n=o.RULES.keywords;for(let i in t)n[i]||$b(e,`unknown keyword: "${i}"`)}ie.checkUnknownRules=gb;function vb(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}ie.schemaHasRules=vb;function oj(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}ie.schemaHasRulesButRef=oj;function ij({topSchemaRef:e,schemaPath:t},r,o,n){if(!n){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Te._)`${r}`}return(0,Te._)`${e}${t}${(0,Te.getProperty)(o)}`}ie.schemaRefOrVal=ij;function sj(e){return _b(decodeURIComponent(e))}ie.unescapeFragment=sj;function aj(e){return encodeURIComponent(Ym(e))}ie.escapeFragment=aj;function Ym(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}ie.escapeJsonPointer=Ym;function _b(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}ie.unescapeJsonPointer=_b;function cj(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}ie.eachItem=cj;function mb({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:o}){return(n,i,s,a)=>{let c=s===void 0?i:s instanceof Te.Name?(i instanceof Te.Name?e(n,i,s):t(n,i,s),s):i instanceof Te.Name?(t(n,s,i),i):r(i,s);return a===Te.Name&&!(c instanceof Te.Name)?o(n,c):c}}ie.mergeEvaluated={props:mb({mergeNames:(e,t,r)=>e.if((0,Te._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Te._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,Te._)`${r} || {}`).code((0,Te._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Te._)`${r} !== true`,()=>{t===!0?e.assign(r,!0):(e.assign(r,(0,Te._)`${r} || {}`),Xm(e,r,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:yb}),items:mb({mergeNames:(e,t,r)=>e.if((0,Te._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Te._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Te._)`${r} !== true`,()=>e.assign(r,t===!0?!0:(0,Te._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function yb(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",(0,Te._)`{}`);return t!==void 0&&Xm(e,r,t),r}ie.evaluatedPropsToName=yb;function Xm(e,t,r){Object.keys(r).forEach(o=>e.assign((0,Te._)`${t}${(0,Te.getProperty)(o)}`,!0))}ie.setEvaluated=Xm;var hb={};function uj(e,t){return e.scopeValue("func",{ref:t,code:hb[t.code]||(hb[t.code]=new tj._Code(t.code))})}ie.useFunc=uj;var Bm;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Bm||(ie.Type=Bm={}));function lj(e,t,r){if(e instanceof Te.Name){let o=t===Bm.Num;return r?o?(0,Te._)`"[" + ${e} + "]"`:(0,Te._)`"['" + ${e} + "']"`:o?(0,Te._)`"/" + ${e}`:(0,Te._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Te.getProperty)(e).toString():"/"+Ym(e)}ie.getErrorPath=lj;function $b(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,r===!0)throw new Error(t);e.self.logger.warn(t)}}ie.checkStrictMode=$b});var Pr=b(Qm=>{"use strict";Object.defineProperty(Qm,"__esModule",{value:!0});var tt=oe(),dj={data:new tt.Name("data"),valCxt:new tt.Name("valCxt"),instancePath:new tt.Name("instancePath"),parentData:new tt.Name("parentData"),parentDataProperty:new tt.Name("parentDataProperty"),rootData:new tt.Name("rootData"),dynamicAnchors:new tt.Name("dynamicAnchors"),vErrors:new tt.Name("vErrors"),errors:new tt.Name("errors"),this:new tt.Name("this"),self:new tt.Name("self"),scope:new tt.Name("scope"),json:new tt.Name("json"),jsonPos:new tt.Name("jsonPos"),jsonLen:new tt.Name("jsonLen"),jsonPart:new tt.Name("jsonPart")};Qm.default=dj});var Fs=b(rt=>{"use strict";Object.defineProperty(rt,"__esModule",{value:!0});rt.extendErrors=rt.resetErrorsCount=rt.reportExtraError=rt.reportError=rt.keyword$DataError=rt.keywordError=void 0;var pe=oe(),Tl=he(),lt=Pr();rt.keywordError={message:({keyword:e})=>(0,pe.str)`must pass "${e}" keyword validation`};rt.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,pe.str)`"${e}" keyword must be ${t} ($data)`:(0,pe.str)`"${e}" keyword is invalid ($data)`};function pj(e,t=rt.keywordError,r,o){let{it:n}=e,{gen:i,compositeRule:s,allErrors:a}=n,c=kb(e,t,r);o??(s||a)?bb(i,c):wb(n,(0,pe._)`[${c}]`)}rt.reportError=pj;function fj(e,t=rt.keywordError,r){let{it:o}=e,{gen:n,compositeRule:i,allErrors:s}=o,a=kb(e,t,r);bb(n,a),i||s||wb(o,lt.default.vErrors)}rt.reportExtraError=fj;function mj(e,t){e.assign(lt.default.errors,t),e.if((0,pe._)`${lt.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,pe._)`${lt.default.vErrors}.length`,t),()=>e.assign(lt.default.vErrors,null)))}rt.resetErrorsCount=mj;function hj({gen:e,keyword:t,schemaValue:r,data:o,errsCount:n,it:i}){if(n===void 0)throw new Error("ajv implementation error");let s=e.name("err");e.forRange("i",n,lt.default.errors,a=>{e.const(s,(0,pe._)`${lt.default.vErrors}[${a}]`),e.if((0,pe._)`${s}.instancePath === undefined`,()=>e.assign((0,pe._)`${s}.instancePath`,(0,pe.strConcat)(lt.default.instancePath,i.errorPath))),e.assign((0,pe._)`${s}.schemaPath`,(0,pe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,pe._)`${s}.schema`,r),e.assign((0,pe._)`${s}.data`,o))})}rt.extendErrors=hj;function bb(e,t){let r=e.const("err",t);e.if((0,pe._)`${lt.default.vErrors} === null`,()=>e.assign(lt.default.vErrors,(0,pe._)`[${r}]`),(0,pe._)`${lt.default.vErrors}.push(${r})`),e.code((0,pe._)`${lt.default.errors}++`)}function wb(e,t){let{gen:r,validateName:o,schemaEnv:n}=e;n.$async?r.throw((0,pe._)`new ${e.ValidationError}(${t})`):(r.assign((0,pe._)`${o}.errors`,t),r.return(!1))}var jn={keyword:new pe.Name("keyword"),schemaPath:new pe.Name("schemaPath"),params:new pe.Name("params"),propertyName:new pe.Name("propertyName"),message:new pe.Name("message"),schema:new pe.Name("schema"),parentSchema:new pe.Name("parentSchema")};function kb(e,t,r){let{createErrors:o}=e.it;return o===!1?(0,pe._)`{}`:gj(e,t,r)}function gj(e,t,r={}){let{gen:o,it:n}=e,i=[vj(n,r),_j(e,r)];return yj(e,t,i),o.object(...i)}function vj({errorPath:e},{instancePath:t}){let r=t?(0,pe.str)`${e}${(0,Tl.getErrorPath)(t,Tl.Type.Str)}`:e;return[lt.default.instancePath,(0,pe.strConcat)(lt.default.instancePath,r)]}function _j({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:(0,pe.str)`${t}/${e}`;return r&&(n=(0,pe.str)`${n}${(0,Tl.getErrorPath)(r,Tl.Type.Str)}`),[jn.schemaPath,n]}function yj(e,{params:t,message:r},o){let{keyword:n,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:d}=a;o.push([jn.keyword,n],[jn.params,typeof t=="function"?t(e):t||(0,pe._)`{}`]),c.messages&&o.push([jn.message,typeof r=="function"?r(e):r]),c.verbose&&o.push([jn.schema,s],[jn.parentSchema,(0,pe._)`${l}${d}`],[lt.default.data,i]),u&&o.push([jn.propertyName,u])}});var Sb=b(Co=>{"use strict";Object.defineProperty(Co,"__esModule",{value:!0});Co.boolOrEmptySchema=Co.topBoolOrEmptySchema=void 0;var $j=Fs(),bj=oe(),wj=Pr(),kj={message:"boolean schema is false"};function xj(e){let{gen:t,schema:r,validateName:o}=e;r===!1?xb(e,!1):typeof r=="object"&&r.$async===!0?t.return(wj.default.data):(t.assign((0,bj._)`${o}.errors`,null),t.return(!0))}Co.topBoolOrEmptySchema=xj;function Sj(e,t){let{gen:r,schema:o}=e;o===!1?(r.var(t,!1),xb(e)):r.var(t,!0)}Co.boolOrEmptySchema=Sj;function xb(e,t){let{gen:r,data:o}=e,n={gen:r,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,$j.reportError)(n,kj,void 0,t)}});var eh=b(Ao=>{"use strict";Object.defineProperty(Ao,"__esModule",{value:!0});Ao.getRules=Ao.isJSONType=void 0;var Tj=["string","number","integer","boolean","null","object","array"],Pj=new Set(Tj);function zj(e){return typeof e=="string"&&Pj.has(e)}Ao.isJSONType=zj;function Ej(){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:{}}}Ao.getRules=Ej});var th=b(Br=>{"use strict";Object.defineProperty(Br,"__esModule",{value:!0});Br.shouldUseRule=Br.shouldUseGroup=Br.schemaHasRulesForType=void 0;function Ij({schema:e,self:t},r){let o=t.RULES.types[r];return o&&o!==!0&&Tb(e,o)}Br.schemaHasRulesForType=Ij;function Tb(e,t){return t.rules.some(r=>Pb(e,r))}Br.shouldUseGroup=Tb;function Pb(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(o=>e[o]!==void 0))}Br.shouldUseRule=Pb});var Gs=b(nt=>{"use strict";Object.defineProperty(nt,"__esModule",{value:!0});nt.reportTypeError=nt.checkDataTypes=nt.checkDataType=nt.coerceAndCheckDataType=nt.getJSONTypes=nt.getSchemaTypes=nt.DataType=void 0;var jj=eh(),Oj=th(),Nj=Fs(),B=oe(),zb=he(),Do;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(Do||(nt.DataType=Do={}));function Rj(e){let t=Eb(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}nt.getSchemaTypes=Rj;function Eb(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(jj.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}nt.getJSONTypes=Eb;function Cj(e,t){let{gen:r,data:o,opts:n}=e,i=Aj(t,n.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&(0,Oj.schemaHasRulesForType)(e,t[0]));if(s){let a=nh(t,o,n.strictNumbers,Do.Wrong);r.if(a,()=>{i.length?Dj(e,t,i):oh(e)})}return s}nt.coerceAndCheckDataType=Cj;var Ib=new Set(["string","number","integer","boolean","null"]);function Aj(e,t){return t?e.filter(r=>Ib.has(r)||t==="array"&&r==="array"):[]}function Dj(e,t,r){let{gen:o,data:n,opts:i}=e,s=o.let("dataType",(0,B._)`typeof ${n}`),a=o.let("coerced",(0,B._)`undefined`);i.coerceTypes==="array"&&o.if((0,B._)`${s} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>o.assign(n,(0,B._)`${n}[0]`).assign(s,(0,B._)`typeof ${n}`).if(nh(t,n,i.strictNumbers),()=>o.assign(a,n))),o.if((0,B._)`${a} !== undefined`);for(let u of r)(Ib.has(u)||u==="array"&&i.coerceTypes==="array")&&c(u);o.else(),oh(e),o.endIf(),o.if((0,B._)`${a} !== undefined`,()=>{o.assign(n,a),qj(e,a)});function c(u){switch(u){case"string":o.elseIf((0,B._)`${s} == "number" || ${s} == "boolean"`).assign(a,(0,B._)`"" + ${n}`).elseIf((0,B._)`${n} === null`).assign(a,(0,B._)`""`);return;case"number":o.elseIf((0,B._)`${s} == "boolean" || ${n} === null
2
+ "use strict";var ZS=Object.create;var Ld=Object.defineProperty;var VS=Object.getOwnPropertyDescriptor;var LS=Object.getOwnPropertyNames;var FS=Object.getPrototypeOf,GS=Object.prototype.hasOwnProperty;var $=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),mn=(e,t)=>{for(var r in t)Ld(e,r,{get:t[r],enumerable:!0})},WS=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of LS(t))!GS.call(e,n)&&n!==r&&Ld(e,n,{get:()=>t[n],enumerable:!(o=VS(t,n))||o.enumerable});return e};var Ge=(e,t,r)=>(r=e!=null?ZS(FS(e)):{},WS(t||!e||!e.__esModule?Ld(r,"default",{value:e,enumerable:!0}):r,e));var Us=$(me=>{"use strict";Object.defineProperty(me,"__esModule",{value:!0});me.regexpCode=me.getEsmExportName=me.getProperty=me.safeStringify=me.stringify=me.strConcat=me.addCodeArg=me.str=me._=me.nil=me._Code=me.Name=me.IDENTIFIER=me._CodeOrName=void 0;var qs=class{};me._CodeOrName=qs;me.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Pn=class extends qs{constructor(t){if(super(),!me.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};me.Name=Pn;var At=class extends qs{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,o)=>`${r}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,o)=>(o instanceof Pn&&(r[o.str]=(r[o.str]||0)+1),r),{})}};me._Code=At;me.nil=new At("");function d$(e,...t){let r=[e[0]],o=0;for(;o<t.length;)Cm(r,t[o]),r.push(e[++o]);return new At(r)}me._=d$;var Rm=new At("+");function p$(e,...t){let r=[Ms(e[0])],o=0;for(;o<t.length;)r.push(Rm),Cm(r,t[o]),r.push(Rm,Ms(e[++o]));return JI(r),new At(r)}me.str=p$;function Cm(e,t){t instanceof At?e.push(...t._items):t instanceof Pn?e.push(t):e.push(XI(t))}me.addCodeArg=Cm;function JI(e){let t=1;for(;t<e.length-1;){if(e[t]===Rm){let r=BI(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function BI(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof Pn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof Pn))return`"${e}${t.slice(1)}`}function YI(e,t){return t.emptyStr()?e:e.emptyStr()?t:p$`${e}${t}`}me.strConcat=YI;function XI(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:Ms(Array.isArray(e)?e.join(","):e)}function QI(e){return new At(Ms(e))}me.stringify=QI;function Ms(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}me.safeStringify=Ms;function eO(e){return typeof e=="string"&&me.IDENTIFIER.test(e)?new At(`.${e}`):d$`[${e}]`}me.getProperty=eO;function tO(e){if(typeof e=="string"&&me.IDENTIFIER.test(e))return new At(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}me.getEsmExportName=tO;function rO(e){return new At(e.toString())}me.regexpCode=rO});var qm=$(yt=>{"use strict";Object.defineProperty(yt,"__esModule",{value:!0});yt.ValueScope=yt.ValueScopeName=yt.Scope=yt.varKinds=yt.UsedValueState=void 0;var _t=Us(),Am=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},$l;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})($l||(yt.UsedValueState=$l={}));yt.varKinds={const:new _t.Name("const"),let:new _t.Name("let"),var:new _t.Name("var")};var wl=class{constructor({prefixes:t,parent:r}={}){this._names={},this._prefixes=t,this._parent=r}toName(t){return t instanceof _t.Name?t:this.name(t)}name(t){return new _t.Name(this._newName(t))}_newName(t){let r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,o;if(!((o=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};yt.Scope=wl;var kl=class extends _t.Name{constructor(t,r){super(r),this.prefix=t}setValue(t,{property:r,itemIndex:o}){this.value=t,this.scopePath=(0,_t._)`.${new _t.Name(r)}[${o}]`}};yt.ValueScopeName=kl;var nO=(0,_t._)`\n`,Dm=class extends wl{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?nO:_t.nil}}get(){return this._scope}name(t){return new kl(t,this._newName(t))}value(t,r){var o;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(t),{prefix:i}=n,s=(o=r.key)!==null&&o!==void 0?o:r.ref,a=this._values[i];if(a){let l=a.get(s);if(l)return l}else a=this._values[i]=new Map;a.set(s,n);let c=this._scope[i]||(this._scope[i]=[]),u=c.length;return c[u]=r.ref,n.setValue(r,{property:i,itemIndex:u}),n}getValue(t,r){let o=this._values[t];if(o)return o.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,_t._)`${t}${o.scopePath}`})}scopeCode(t=this._values,r,o){return this._reduceValues(t,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},r,o)}_reduceValues(t,r,o={},n){let i=_t.nil;for(let s in t){let a=t[s];if(!a)continue;let c=o[s]=o[s]||new Map;a.forEach(u=>{if(c.has(u))return;c.set(u,$l.Started);let l=r(u);if(l){let d=this.opts.es5?yt.varKinds.var:yt.varKinds.const;i=(0,_t._)`${i}${d} ${u} = ${l};${this.opts._n}`}else if(l=n?.(u))i=(0,_t._)`${i}${l}${this.opts._n}`;else throw new Am(u);c.set(u,$l.Completed)})}return i}};yt.ValueScope=Dm});var oe=$(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.or=re.and=re.not=re.CodeGen=re.operators=re.varKinds=re.ValueScopeName=re.ValueScope=re.Scope=re.Name=re.regexpCode=re.stringify=re.getProperty=re.nil=re.strConcat=re.str=re._=void 0;var le=Us(),Bt=qm(),Jr=Us();Object.defineProperty(re,"_",{enumerable:!0,get:function(){return Jr._}});Object.defineProperty(re,"str",{enumerable:!0,get:function(){return Jr.str}});Object.defineProperty(re,"strConcat",{enumerable:!0,get:function(){return Jr.strConcat}});Object.defineProperty(re,"nil",{enumerable:!0,get:function(){return Jr.nil}});Object.defineProperty(re,"getProperty",{enumerable:!0,get:function(){return Jr.getProperty}});Object.defineProperty(re,"stringify",{enumerable:!0,get:function(){return Jr.stringify}});Object.defineProperty(re,"regexpCode",{enumerable:!0,get:function(){return Jr.regexpCode}});Object.defineProperty(re,"Name",{enumerable:!0,get:function(){return Jr.Name}});var Pl=qm();Object.defineProperty(re,"Scope",{enumerable:!0,get:function(){return Pl.Scope}});Object.defineProperty(re,"ValueScope",{enumerable:!0,get:function(){return Pl.ValueScope}});Object.defineProperty(re,"ValueScopeName",{enumerable:!0,get:function(){return Pl.ValueScopeName}});Object.defineProperty(re,"varKinds",{enumerable:!0,get:function(){return Pl.varKinds}});re.operators={GT:new le._Code(">"),GTE:new le._Code(">="),LT:new le._Code("<"),LTE:new le._Code("<="),EQ:new le._Code("==="),NEQ:new le._Code("!=="),NOT:new le._Code("!"),OR:new le._Code("||"),AND:new le._Code("&&"),ADD:new le._Code("+")};var Tr=class{optimizeNodes(){return this}optimizeNames(t,r){return this}},Mm=class extends Tr{constructor(t,r,o){super(),this.varKind=t,this.name=r,this.rhs=o}render({es5:t,_n:r}){let o=t?Bt.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${n};`+r}optimizeNames(t,r){if(t[this.name.str])return this.rhs&&(this.rhs=Co(this.rhs,t,r)),this}get names(){return this.rhs instanceof le._CodeOrName?this.rhs.names:{}}},xl=class extends Tr{constructor(t,r,o){super(),this.lhs=t,this.rhs=r,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(!(this.lhs instanceof le.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=Co(this.rhs,t,r),this}get names(){let t=this.lhs instanceof le.Name?{}:{...this.lhs.names};return Tl(t,this.rhs)}},Um=class extends xl{constructor(t,r,o,n){super(t,o,n),this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},Zm=class extends Tr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},Vm=class extends Tr{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},Lm=class extends Tr{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},Fm=class extends Tr{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){return this.code=Co(this.code,t,r),this}get names(){return this.code instanceof le._CodeOrName?this.code.names:{}}},Zs=class extends Tr{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((r,o)=>r+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,r=t.length;for(;r--;){let o=t[r].optimizeNodes();Array.isArray(o)?t.splice(r,1,...o):o?t[r]=o:t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){let{nodes:o}=this,n=o.length;for(;n--;){let i=o[n];i.optimizeNames(t,r)||(oO(t,i.names),o.splice(n,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>In(t,r.names),{})}},Pr=class extends Zs{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},Gm=class extends Zs{},Ro=class extends Pr{};Ro.kind="else";var zn=class e extends Pr{constructor(t,r){super(r),this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);return this.else&&(r+="else "+this.else.render(t)),r}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let r=this.else;if(r){let o=r.optimizeNodes();r=this.else=Array.isArray(o)?new Ro(o):o}if(r)return t===!1?r instanceof e?r:r.nodes:this.nodes.length?this:new e(f$(t),r instanceof e?[r]:r.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,r){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,r),!!(super.optimizeNames(t,r)||this.else))return this.condition=Co(this.condition,t,r),this}get names(){let t=super.names;return Tl(t,this.condition),this.else&&In(t,this.else.names),t}};zn.kind="if";var En=class extends Pr{};En.kind="for";var Wm=class extends En{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iteration=Co(this.iteration,t,r),this}get names(){return In(super.names,this.iteration.names)}},Km=class extends En{constructor(t,r,o,n){super(),this.varKind=t,this.name=r,this.from=o,this.to=n}render(t){let r=t.es5?Bt.varKinds.var:this.varKind,{name:o,from:n,to:i}=this;return`for(${r} ${o}=${n}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=Tl(super.names,this.from);return Tl(t,this.to)}},Sl=class extends En{constructor(t,r,o,n){super(),this.loop=t,this.varKind=r,this.name=o,this.iterable=n}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iterable=Co(this.iterable,t,r),this}get names(){return In(super.names,this.iterable.names)}},Vs=class extends Pr{constructor(t,r,o){super(),this.name=t,this.args=r,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};Vs.kind="func";var Ls=class extends Zs{render(t){return"return "+super.render(t)}};Ls.kind="return";var Hm=class extends Pr{render(t){let r="try"+super.render(t);return this.catch&&(r+=this.catch.render(t)),this.finally&&(r+=this.finally.render(t)),r}optimizeNodes(){var t,r;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(t,r){var o,n;return super.optimizeNames(t,r),(o=this.catch)===null||o===void 0||o.optimizeNames(t,r),(n=this.finally)===null||n===void 0||n.optimizeNames(t,r),this}get names(){let t=super.names;return this.catch&&In(t,this.catch.names),this.finally&&In(t,this.finally.names),t}},Fs=class extends Pr{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};Fs.kind="catch";var Gs=class extends Pr{render(t){return"finally"+super.render(t)}};Gs.kind="finally";var Jm=class{constructor(t,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
3
+ `:""},this._extScope=t,this._scope=new Bt.Scope({parent:t}),this._nodes=[new Gm]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){let o=this._extScope.value(t,r);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,o,n){let i=this._scope.toName(r);return o!==void 0&&n&&(this._constants[i.str]=o),this._leafNode(new Mm(t,i,o)),i}const(t,r,o){return this._def(Bt.varKinds.const,t,r,o)}let(t,r,o){return this._def(Bt.varKinds.let,t,r,o)}var(t,r,o){return this._def(Bt.varKinds.var,t,r,o)}assign(t,r,o){return this._leafNode(new xl(t,r,o))}add(t,r){return this._leafNode(new Um(t,re.operators.ADD,r))}code(t){return typeof t=="function"?t():t!==le.nil&&this._leafNode(new Fm(t)),this}object(...t){let r=["{"];for(let[o,n]of t)r.length>1&&r.push(","),r.push(o),(o!==n||this.opts.es5)&&(r.push(":"),(0,le.addCodeArg)(r,n));return r.push("}"),new le._Code(r)}if(t,r,o){if(this._blockNode(new zn(t)),r&&o)this.code(r).else().code(o).endIf();else if(r)this.code(r).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new zn(t))}else(){return this._elseNode(new Ro)}endIf(){return this._endBlockNode(zn,Ro)}_for(t,r){return this._blockNode(t),r&&this.code(r).endFor(),this}for(t,r){return this._for(new Wm(t),r)}forRange(t,r,o,n,i=this.opts.es5?Bt.varKinds.var:Bt.varKinds.let){let s=this._scope.toName(t);return this._for(new Km(i,s,r,o),()=>n(s))}forOf(t,r,o,n=Bt.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let s=r instanceof le.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,le._)`${s}.length`,a=>{this.var(i,(0,le._)`${s}[${a}]`),o(i)})}return this._for(new Sl("of",n,i,r),()=>o(i))}forIn(t,r,o,n=this.opts.es5?Bt.varKinds.var:Bt.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,le._)`Object.keys(${r})`,o);let i=this._scope.toName(t);return this._for(new Sl("in",n,i,r),()=>o(i))}endFor(){return this._endBlockNode(En)}label(t){return this._leafNode(new Zm(t))}break(t){return this._leafNode(new Vm(t))}return(t){let r=new Ls;if(this._blockNode(r),this.code(t),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(Ls)}try(t,r,o){if(!r&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new Hm;if(this._blockNode(n),this.code(t),r){let i=this.name("e");this._currNode=n.catch=new Fs(i),r(i)}return o&&(this._currNode=n.finally=new Gs,this.code(o)),this._endBlockNode(Fs,Gs)}throw(t){return this._leafNode(new Lm(t))}block(t,r){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(r),this}endBlock(t){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-r;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=r,this}func(t,r=le.nil,o,n){return this._blockNode(new Vs(t,r,o)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(Vs)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,r){let o=this._currNode;if(o instanceof t||r&&o instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){let r=this._currNode;if(!(r instanceof zn))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let r=this._nodes;r[r.length-1]=t}};re.CodeGen=Jm;function In(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function Tl(e,t){return t instanceof le._CodeOrName?In(e,t.names):e}function Co(e,t,r){if(e instanceof le.Name)return o(e);if(!n(e))return e;return new le._Code(e._items.reduce((i,s)=>(s instanceof le.Name&&(s=o(s)),s instanceof le._Code?i.push(...s._items):i.push(s),i),[]));function o(i){let s=r[i.str];return s===void 0||t[i.str]!==1?i:(delete t[i.str],s)}function n(i){return i instanceof le._Code&&i._items.some(s=>s instanceof le.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function oO(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function f$(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,le._)`!${Bm(e)}`}re.not=f$;var iO=m$(re.operators.AND);function sO(...e){return e.reduce(iO)}re.and=sO;var aO=m$(re.operators.OR);function cO(...e){return e.reduce(aO)}re.or=cO;function m$(e){return(t,r)=>t===le.nil?r:r===le.nil?t:(0,le._)`${Bm(t)} ${e} ${Bm(r)}`}function Bm(e){return e instanceof le.Name?e:(0,le._)`(${e})`}});var he=$(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.checkStrictMode=ie.getErrorPath=ie.Type=ie.useFunc=ie.setEvaluated=ie.evaluatedPropsToName=ie.mergeEvaluated=ie.eachItem=ie.unescapeJsonPointer=ie.escapeJsonPointer=ie.escapeFragment=ie.unescapeFragment=ie.schemaRefOrVal=ie.schemaHasRulesButRef=ie.schemaHasRules=ie.checkUnknownRules=ie.alwaysValidSchema=ie.toHash=void 0;var Te=oe(),uO=Us();function lO(e){let t={};for(let r of e)t[r]=!0;return t}ie.toHash=lO;function dO(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(v$(e,t),!_$(t,e.self.RULES.all))}ie.alwaysValidSchema=dO;function v$(e,t=e.schema){let{opts:r,self:o}=e;if(!r.strictSchema||typeof t=="boolean")return;let n=o.RULES.keywords;for(let i in t)n[i]||$$(e,`unknown keyword: "${i}"`)}ie.checkUnknownRules=v$;function _$(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}ie.schemaHasRules=_$;function pO(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}ie.schemaHasRulesButRef=pO;function fO({topSchemaRef:e,schemaPath:t},r,o,n){if(!n){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Te._)`${r}`}return(0,Te._)`${e}${t}${(0,Te.getProperty)(o)}`}ie.schemaRefOrVal=fO;function mO(e){return y$(decodeURIComponent(e))}ie.unescapeFragment=mO;function hO(e){return encodeURIComponent(Xm(e))}ie.escapeFragment=hO;function Xm(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}ie.escapeJsonPointer=Xm;function y$(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}ie.unescapeJsonPointer=y$;function gO(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}ie.eachItem=gO;function h$({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:o}){return(n,i,s,a)=>{let c=s===void 0?i:s instanceof Te.Name?(i instanceof Te.Name?e(n,i,s):t(n,i,s),s):i instanceof Te.Name?(t(n,s,i),i):r(i,s);return a===Te.Name&&!(c instanceof Te.Name)?o(n,c):c}}ie.mergeEvaluated={props:h$({mergeNames:(e,t,r)=>e.if((0,Te._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Te._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,Te._)`${r} || {}`).code((0,Te._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Te._)`${r} !== true`,()=>{t===!0?e.assign(r,!0):(e.assign(r,(0,Te._)`${r} || {}`),Qm(e,r,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:b$}),items:h$({mergeNames:(e,t,r)=>e.if((0,Te._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Te._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Te._)`${r} !== true`,()=>e.assign(r,t===!0?!0:(0,Te._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function b$(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",(0,Te._)`{}`);return t!==void 0&&Qm(e,r,t),r}ie.evaluatedPropsToName=b$;function Qm(e,t,r){Object.keys(r).forEach(o=>e.assign((0,Te._)`${t}${(0,Te.getProperty)(o)}`,!0))}ie.setEvaluated=Qm;var g$={};function vO(e,t){return e.scopeValue("func",{ref:t,code:g$[t.code]||(g$[t.code]=new uO._Code(t.code))})}ie.useFunc=vO;var Ym;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Ym||(ie.Type=Ym={}));function _O(e,t,r){if(e instanceof Te.Name){let o=t===Ym.Num;return r?o?(0,Te._)`"[" + ${e} + "]"`:(0,Te._)`"['" + ${e} + "']"`:o?(0,Te._)`"/" + ${e}`:(0,Te._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Te.getProperty)(e).toString():"/"+Xm(e)}ie.getErrorPath=_O;function $$(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,r===!0)throw new Error(t);e.self.logger.warn(t)}}ie.checkStrictMode=$$});var zr=$(eh=>{"use strict";Object.defineProperty(eh,"__esModule",{value:!0});var rt=oe(),yO={data:new rt.Name("data"),valCxt:new rt.Name("valCxt"),instancePath:new rt.Name("instancePath"),parentData:new rt.Name("parentData"),parentDataProperty:new rt.Name("parentDataProperty"),rootData:new rt.Name("rootData"),dynamicAnchors:new rt.Name("dynamicAnchors"),vErrors:new rt.Name("vErrors"),errors:new rt.Name("errors"),this:new rt.Name("this"),self:new rt.Name("self"),scope:new rt.Name("scope"),json:new rt.Name("json"),jsonPos:new rt.Name("jsonPos"),jsonLen:new rt.Name("jsonLen"),jsonPart:new rt.Name("jsonPart")};eh.default=yO});var Ws=$(nt=>{"use strict";Object.defineProperty(nt,"__esModule",{value:!0});nt.extendErrors=nt.resetErrorsCount=nt.reportExtraError=nt.reportError=nt.keyword$DataError=nt.keywordError=void 0;var pe=oe(),zl=he(),pt=zr();nt.keywordError={message:({keyword:e})=>(0,pe.str)`must pass "${e}" keyword validation`};nt.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,pe.str)`"${e}" keyword must be ${t} ($data)`:(0,pe.str)`"${e}" keyword is invalid ($data)`};function bO(e,t=nt.keywordError,r,o){let{it:n}=e,{gen:i,compositeRule:s,allErrors:a}=n,c=x$(e,t,r);o??(s||a)?w$(i,c):k$(n,(0,pe._)`[${c}]`)}nt.reportError=bO;function $O(e,t=nt.keywordError,r){let{it:o}=e,{gen:n,compositeRule:i,allErrors:s}=o,a=x$(e,t,r);w$(n,a),i||s||k$(o,pt.default.vErrors)}nt.reportExtraError=$O;function wO(e,t){e.assign(pt.default.errors,t),e.if((0,pe._)`${pt.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,pe._)`${pt.default.vErrors}.length`,t),()=>e.assign(pt.default.vErrors,null)))}nt.resetErrorsCount=wO;function kO({gen:e,keyword:t,schemaValue:r,data:o,errsCount:n,it:i}){if(n===void 0)throw new Error("ajv implementation error");let s=e.name("err");e.forRange("i",n,pt.default.errors,a=>{e.const(s,(0,pe._)`${pt.default.vErrors}[${a}]`),e.if((0,pe._)`${s}.instancePath === undefined`,()=>e.assign((0,pe._)`${s}.instancePath`,(0,pe.strConcat)(pt.default.instancePath,i.errorPath))),e.assign((0,pe._)`${s}.schemaPath`,(0,pe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,pe._)`${s}.schema`,r),e.assign((0,pe._)`${s}.data`,o))})}nt.extendErrors=kO;function w$(e,t){let r=e.const("err",t);e.if((0,pe._)`${pt.default.vErrors} === null`,()=>e.assign(pt.default.vErrors,(0,pe._)`[${r}]`),(0,pe._)`${pt.default.vErrors}.push(${r})`),e.code((0,pe._)`${pt.default.errors}++`)}function k$(e,t){let{gen:r,validateName:o,schemaEnv:n}=e;n.$async?r.throw((0,pe._)`new ${e.ValidationError}(${t})`):(r.assign((0,pe._)`${o}.errors`,t),r.return(!1))}var On={keyword:new pe.Name("keyword"),schemaPath:new pe.Name("schemaPath"),params:new pe.Name("params"),propertyName:new pe.Name("propertyName"),message:new pe.Name("message"),schema:new pe.Name("schema"),parentSchema:new pe.Name("parentSchema")};function x$(e,t,r){let{createErrors:o}=e.it;return o===!1?(0,pe._)`{}`:xO(e,t,r)}function xO(e,t,r={}){let{gen:o,it:n}=e,i=[SO(n,r),TO(e,r)];return PO(e,t,i),o.object(...i)}function SO({errorPath:e},{instancePath:t}){let r=t?(0,pe.str)`${e}${(0,zl.getErrorPath)(t,zl.Type.Str)}`:e;return[pt.default.instancePath,(0,pe.strConcat)(pt.default.instancePath,r)]}function TO({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:(0,pe.str)`${t}/${e}`;return r&&(n=(0,pe.str)`${n}${(0,zl.getErrorPath)(r,zl.Type.Str)}`),[On.schemaPath,n]}function PO(e,{params:t,message:r},o){let{keyword:n,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:d}=a;o.push([On.keyword,n],[On.params,typeof t=="function"?t(e):t||(0,pe._)`{}`]),c.messages&&o.push([On.message,typeof r=="function"?r(e):r]),c.verbose&&o.push([On.schema,s],[On.parentSchema,(0,pe._)`${l}${d}`],[pt.default.data,i]),u&&o.push([On.propertyName,u])}});var T$=$(Ao=>{"use strict";Object.defineProperty(Ao,"__esModule",{value:!0});Ao.boolOrEmptySchema=Ao.topBoolOrEmptySchema=void 0;var zO=Ws(),EO=oe(),IO=zr(),OO={message:"boolean schema is false"};function jO(e){let{gen:t,schema:r,validateName:o}=e;r===!1?S$(e,!1):typeof r=="object"&&r.$async===!0?t.return(IO.default.data):(t.assign((0,EO._)`${o}.errors`,null),t.return(!0))}Ao.topBoolOrEmptySchema=jO;function NO(e,t){let{gen:r,schema:o}=e;o===!1?(r.var(t,!1),S$(e)):r.var(t,!0)}Ao.boolOrEmptySchema=NO;function S$(e,t){let{gen:r,data:o}=e,n={gen:r,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,zO.reportError)(n,OO,void 0,t)}});var th=$(Do=>{"use strict";Object.defineProperty(Do,"__esModule",{value:!0});Do.getRules=Do.isJSONType=void 0;var RO=["string","number","integer","boolean","null","object","array"],CO=new Set(RO);function AO(e){return typeof e=="string"&&CO.has(e)}Do.isJSONType=AO;function DO(){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:{}}}Do.getRules=DO});var rh=$(Br=>{"use strict";Object.defineProperty(Br,"__esModule",{value:!0});Br.shouldUseRule=Br.shouldUseGroup=Br.schemaHasRulesForType=void 0;function qO({schema:e,self:t},r){let o=t.RULES.types[r];return o&&o!==!0&&P$(e,o)}Br.schemaHasRulesForType=qO;function P$(e,t){return t.rules.some(r=>z$(e,r))}Br.shouldUseGroup=P$;function z$(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(o=>e[o]!==void 0))}Br.shouldUseRule=z$});var Ks=$(ot=>{"use strict";Object.defineProperty(ot,"__esModule",{value:!0});ot.reportTypeError=ot.checkDataTypes=ot.checkDataType=ot.coerceAndCheckDataType=ot.getJSONTypes=ot.getSchemaTypes=ot.DataType=void 0;var MO=th(),UO=rh(),ZO=Ws(),B=oe(),E$=he(),qo;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(qo||(ot.DataType=qo={}));function VO(e){let t=I$(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}ot.getSchemaTypes=VO;function I$(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(MO.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}ot.getJSONTypes=I$;function LO(e,t){let{gen:r,data:o,opts:n}=e,i=FO(t,n.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&(0,UO.schemaHasRulesForType)(e,t[0]));if(s){let a=oh(t,o,n.strictNumbers,qo.Wrong);r.if(a,()=>{i.length?GO(e,t,i):ih(e)})}return s}ot.coerceAndCheckDataType=LO;var O$=new Set(["string","number","integer","boolean","null"]);function FO(e,t){return t?e.filter(r=>O$.has(r)||t==="array"&&r==="array"):[]}function GO(e,t,r){let{gen:o,data:n,opts:i}=e,s=o.let("dataType",(0,B._)`typeof ${n}`),a=o.let("coerced",(0,B._)`undefined`);i.coerceTypes==="array"&&o.if((0,B._)`${s} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>o.assign(n,(0,B._)`${n}[0]`).assign(s,(0,B._)`typeof ${n}`).if(oh(t,n,i.strictNumbers),()=>o.assign(a,n))),o.if((0,B._)`${a} !== undefined`);for(let u of r)(O$.has(u)||u==="array"&&i.coerceTypes==="array")&&c(u);o.else(),ih(e),o.endIf(),o.if((0,B._)`${a} !== undefined`,()=>{o.assign(n,a),WO(e,a)});function c(u){switch(u){case"string":o.elseIf((0,B._)`${s} == "number" || ${s} == "boolean"`).assign(a,(0,B._)`"" + ${n}`).elseIf((0,B._)`${n} === null`).assign(a,(0,B._)`""`);return;case"number":o.elseIf((0,B._)`${s} == "boolean" || ${n} === null
4
4
  || (${s} == "string" && ${n} && ${n} == +${n})`).assign(a,(0,B._)`+${n}`);return;case"integer":o.elseIf((0,B._)`${s} === "boolean" || ${n} === null
5
5
  || (${s} === "string" && ${n} && ${n} == +${n} && !(${n} % 1))`).assign(a,(0,B._)`+${n}`);return;case"boolean":o.elseIf((0,B._)`${n} === "false" || ${n} === 0 || ${n} === null`).assign(a,!1).elseIf((0,B._)`${n} === "true" || ${n} === 1`).assign(a,!0);return;case"null":o.elseIf((0,B._)`${n} === "" || ${n} === 0 || ${n} === false`),o.assign(a,null);return;case"array":o.elseIf((0,B._)`${s} === "string" || ${s} === "number"
6
- || ${s} === "boolean" || ${n} === null`).assign(a,(0,B._)`[${n}]`)}}}function qj({gen:e,parentData:t,parentDataProperty:r},o){e.if((0,B._)`${t} !== undefined`,()=>e.assign((0,B._)`${t}[${r}]`,o))}function rh(e,t,r,o=Do.Correct){let n=o===Do.Correct?B.operators.EQ:B.operators.NEQ,i;switch(e){case"null":return(0,B._)`${t} ${n} null`;case"array":i=(0,B._)`Array.isArray(${t})`;break;case"object":i=(0,B._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s((0,B._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return(0,B._)`typeof ${t} ${n} ${e}`}return o===Do.Correct?i:(0,B.not)(i);function s(a=B.nil){return(0,B.and)((0,B._)`typeof ${t} == "number"`,a,r?(0,B._)`isFinite(${t})`:B.nil)}}nt.checkDataType=rh;function nh(e,t,r,o){if(e.length===1)return rh(e[0],t,r,o);let n,i=(0,zb.toHash)(e);if(i.array&&i.object){let s=(0,B._)`typeof ${t} != "object"`;n=i.null?s:(0,B._)`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else n=B.nil;i.number&&delete i.integer;for(let s in i)n=(0,B.and)(n,rh(s,t,r,o));return n}nt.checkDataTypes=nh;var Mj={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,B._)`{type: ${e}}`:(0,B._)`{type: ${t}}`};function oh(e){let t=Uj(e);(0,Nj.reportError)(t,Mj)}nt.reportTypeError=oh;function Uj(e){let{gen:t,data:r,schema:o}=e,n=(0,zb.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:r,schema:o.type,schemaCode:n,schemaValue:n,parentSchema:o,params:{},it:e}}});var Ob=b(Pl=>{"use strict";Object.defineProperty(Pl,"__esModule",{value:!0});Pl.assignDefaults=void 0;var qo=oe(),Zj=he();function Lj(e,t){let{properties:r,items:o}=e.schema;if(t==="object"&&r)for(let n in r)jb(e,n,r[n].default);else t==="array"&&Array.isArray(o)&&o.forEach((n,i)=>jb(e,i,n.default))}Pl.assignDefaults=Lj;function jb(e,t,r){let{gen:o,compositeRule:n,data:i,opts:s}=e;if(r===void 0)return;let a=(0,qo._)`${i}${(0,qo.getProperty)(t)}`;if(n){(0,Zj.checkStrictMode)(e,`default is ignored for: ${a}`);return}let c=(0,qo._)`${a} === undefined`;s.useDefaults==="empty"&&(c=(0,qo._)`${c} || ${a} === null || ${a} === ""`),o.if(c,(0,qo._)`${a} = ${(0,qo.stringify)(r)}`)}});var Ct=b(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.validateUnion=xe.validateArray=xe.usePattern=xe.callValidateCode=xe.schemaProperties=xe.allSchemaProperties=xe.noPropertyInData=xe.propertyInData=xe.isOwnProperty=xe.hasPropFunc=xe.reportMissingProp=xe.checkMissingProp=xe.checkReportMissingProp=void 0;var Ne=oe(),ih=he(),Yr=Pr(),Vj=he();function Fj(e,t){let{gen:r,data:o,it:n}=e;r.if(ah(r,o,t,n.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Ne._)`${t}`},!0),e.error()})}xe.checkReportMissingProp=Fj;function Gj({gen:e,data:t,it:{opts:r}},o,n){return(0,Ne.or)(...o.map(i=>(0,Ne.and)(ah(e,t,i,r.ownProperties),(0,Ne._)`${n} = ${i}`)))}xe.checkMissingProp=Gj;function Wj(e,t){e.setParams({missingProperty:t},!0),e.error()}xe.reportMissingProp=Wj;function Nb(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Ne._)`Object.prototype.hasOwnProperty`})}xe.hasPropFunc=Nb;function sh(e,t,r){return(0,Ne._)`${Nb(e)}.call(${t}, ${r})`}xe.isOwnProperty=sh;function Kj(e,t,r,o){let n=(0,Ne._)`${t}${(0,Ne.getProperty)(r)} !== undefined`;return o?(0,Ne._)`${n} && ${sh(e,t,r)}`:n}xe.propertyInData=Kj;function ah(e,t,r,o){let n=(0,Ne._)`${t}${(0,Ne.getProperty)(r)} === undefined`;return o?(0,Ne.or)(n,(0,Ne.not)(sh(e,t,r))):n}xe.noPropertyInData=ah;function Rb(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}xe.allSchemaProperties=Rb;function Hj(e,t){return Rb(t).filter(r=>!(0,ih.alwaysValidSchema)(e,t[r]))}xe.schemaProperties=Hj;function Jj({schemaCode:e,data:t,it:{gen:r,topSchemaRef:o,schemaPath:n,errorPath:i},it:s},a,c,u){let l=u?(0,Ne._)`${e}, ${t}, ${o}${n}`:t,d=[[Yr.default.instancePath,(0,Ne.strConcat)(Yr.default.instancePath,i)],[Yr.default.parentData,s.parentData],[Yr.default.parentDataProperty,s.parentDataProperty],[Yr.default.rootData,Yr.default.rootData]];s.opts.dynamicRef&&d.push([Yr.default.dynamicAnchors,Yr.default.dynamicAnchors]);let h=(0,Ne._)`${l}, ${r.object(...d)}`;return c!==Ne.nil?(0,Ne._)`${a}.call(${c}, ${h})`:(0,Ne._)`${a}(${h})`}xe.callValidateCode=Jj;var Bj=(0,Ne._)`new RegExp`;function Yj({gen:e,it:{opts:t}},r){let o=t.unicodeRegExp?"u":"",{regExp:n}=t.code,i=n(r,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Ne._)`${n.code==="new RegExp"?Bj:(0,Vj.useFunc)(e,n)}(${r}, ${o})`})}xe.usePattern=Yj;function Xj(e){let{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.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",(0,Ne._)`${r}.length`);t.forRange("i",0,c,u=>{e.subschema({keyword:o,dataProp:u,dataPropType:ih.Type.Num},i),t.if((0,Ne.not)(i),a)})}}xe.validateArray=Xj;function Qj(e){let{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(c=>(0,ih.alwaysValidSchema)(n,c))&&!n.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:o,schemaProp:u,compositeRule:!0},a);t.assign(s,(0,Ne._)`${s} || ${a}`),e.mergeValidEvaluated(l,a)||t.if((0,Ne.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}xe.validateUnion=Qj});var Db=b(ar=>{"use strict";Object.defineProperty(ar,"__esModule",{value:!0});ar.validateKeywordUsage=ar.validSchemaType=ar.funcKeywordCode=ar.macroKeywordCode=void 0;var dt=oe(),On=Pr(),eO=Ct(),tO=Fs();function rO(e,t){let{gen:r,keyword:o,schema:n,parentSchema:i,it:s}=e,a=t.macro.call(s.self,n,i,s),c=Ab(r,o,a);s.opts.validateSchema!==!1&&s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:dt.nil,errSchemaPath:`${s.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}ar.macroKeywordCode=rO;function nO(e,t){var r;let{gen:o,keyword:n,schema:i,parentSchema:s,$data:a,it:c}=e;iO(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=Ab(o,n,u),d=o.let("valid");e.block$data(d,h),e.ok((r=t.valid)!==null&&r!==void 0?r:d);function h(){if(t.errors===!1)f(),t.modifying&&Cb(e),g(()=>e.error());else{let y=t.async?m():p();t.modifying&&Cb(e),g(()=>oO(e,y))}}function m(){let y=o.let("ruleErrs",null);return o.try(()=>f((0,dt._)`await `),w=>o.assign(d,!1).if((0,dt._)`${w} instanceof ${c.ValidationError}`,()=>o.assign(y,(0,dt._)`${w}.errors`),()=>o.throw(w))),y}function p(){let y=(0,dt._)`${l}.errors`;return o.assign(y,null),f(dt.nil),y}function f(y=t.async?(0,dt._)`await `:dt.nil){let w=c.opts.passContext?On.default.this:On.default.self,k=!("compile"in t&&!a||t.schema===!1);o.assign(d,(0,dt._)`${y}${(0,eO.callValidateCode)(e,l,w,k)}`,t.modifying)}function g(y){var w;o.if((0,dt.not)((w=t.valid)!==null&&w!==void 0?w:d),y)}}ar.funcKeywordCode=nO;function Cb(e){let{gen:t,data:r,it:o}=e;t.if(o.parentData,()=>t.assign(r,(0,dt._)`${o.parentData}[${o.parentDataProperty}]`))}function oO(e,t){let{gen:r}=e;r.if((0,dt._)`Array.isArray(${t})`,()=>{r.assign(On.default.vErrors,(0,dt._)`${On.default.vErrors} === null ? ${t} : ${On.default.vErrors}.concat(${t})`).assign(On.default.errors,(0,dt._)`${On.default.vErrors}.length`),(0,tO.extendErrors)(e)},()=>e.error())}function iO({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function Ab(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,dt.stringify)(r)})}function sO(e,t,r=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||r&&typeof e>"u")}ar.validSchemaType=sO;function aO({schema:e,opts:t,self:r,errSchemaPath:o},n,i){if(Array.isArray(n.keyword)?!n.keyword.includes(i):n.keyword!==i)throw new Error("ajv implementation error");let s=n.dependencies;if(s?.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(n.validateSchema&&!n.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+r.errorsText(n.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw new Error(c)}}ar.validateKeywordUsage=aO});var Mb=b(Xr=>{"use strict";Object.defineProperty(Xr,"__esModule",{value:!0});Xr.extendSubschemaMode=Xr.extendSubschemaData=Xr.getSubschema=void 0;var cr=oe(),qb=he();function cO(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&o!==void 0)throw new 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:(0,cr._)`${e.schemaPath}${(0,cr.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:(0,cr._)`${e.schemaPath}${(0,cr.getProperty)(t)}${(0,cr.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,qb.escapeFragment)(r)}`}}if(o!==void 0){if(n===void 0||i===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:s,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}Xr.getSubschema=cO;function uO(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:s}){if(n!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:d}=t,h=a.let("data",(0,cr._)`${t.data}${(0,cr.getProperty)(r)}`,!0);c(h),e.errorPath=(0,cr.str)`${u}${(0,qb.getErrorPath)(r,o,d.jsPropertySyntax)}`,e.parentDataProperty=(0,cr._)`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(n!==void 0){let u=n instanceof cr.Name?n:a.let("data",n,!0);c(u),s!==void 0&&(e.propertyName=s)}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]}}Xr.extendSubschemaData=uO;function lO(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:o,createErrors:n,allErrors:i}){o!==void 0&&(e.compositeRule=o),n!==void 0&&(e.createErrors=n),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}Xr.extendSubschemaMode=lO});var Ws=b((tW,Ub)=>{"use strict";Ub.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 o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))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),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var Lb=b((rW,Zb)=>{"use strict";var Qr=Zb.exports=function(e,t,r){typeof t=="function"&&(r=t,t={}),r=t.cb||r;var o=typeof r=="function"?r:r.pre||function(){},n=r.post||function(){};zl(t,o,n,e,"",e)};Qr.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Qr.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Qr.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Qr.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 zl(e,t,r,o,n,i,s,a,c,u){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,n,i,s,a,c,u);for(var l in o){var d=o[l];if(Array.isArray(d)){if(l in Qr.arrayKeywords)for(var h=0;h<d.length;h++)zl(e,t,r,d[h],n+"/"+l+"/"+h,i,n,l,o,h)}else if(l in Qr.propsKeywords){if(d&&typeof d=="object")for(var m in d)zl(e,t,r,d[m],n+"/"+l+"/"+dO(m),i,n,l,o,m)}else(l in Qr.keywords||e.allKeys&&!(l in Qr.skipKeywords))&&zl(e,t,r,d,n+"/"+l,i,n,l,o)}r(o,n,i,s,a,c,u)}}function dO(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var Ks=b(_t=>{"use strict";Object.defineProperty(_t,"__esModule",{value:!0});_t.getSchemaRefs=_t.resolveUrl=_t.normalizeId=_t._getFullPath=_t.getFullPath=_t.inlineRef=void 0;var pO=he(),fO=Ws(),mO=Lb(),hO=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function gO(e,t=!0){return typeof e=="boolean"?!0:t===!0?!ch(e):t?Vb(e)<=t:!1}_t.inlineRef=gO;var vO=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function ch(e){for(let t in e){if(vO.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(ch)||typeof r=="object"&&ch(r))return!0}return!1}function Vb(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,!hO.has(r)&&(typeof e[r]=="object"&&(0,pO.eachItem)(e[r],o=>t+=Vb(o)),t===1/0))return 1/0}return t}function Fb(e,t="",r){r!==!1&&(t=Mo(t));let o=e.parse(t);return Gb(e,o)}_t.getFullPath=Fb;function Gb(e,t){return e.serialize(t).split("#")[0]+"#"}_t._getFullPath=Gb;var _O=/#\/?$/;function Mo(e){return e?e.replace(_O,""):""}_t.normalizeId=Mo;function yO(e,t,r){return r=Mo(r),e.resolve(t,r)}_t.resolveUrl=yO;var $O=/^[a-z_][-a-z0-9._]*$/i;function bO(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:o}=this.opts,n=Mo(e[r]||t),i={"":n},s=Fb(o,n,!1),a={},c=new Set;return mO(e,{allKeys:!0},(d,h,m,p)=>{if(p===void 0)return;let f=s+h,g=i[p];typeof d[r]=="string"&&(g=y.call(this,d[r])),w.call(this,d.$anchor),w.call(this,d.$dynamicAnchor),i[h]=g;function y(k){let E=this.opts.uriResolver.resolve;if(k=Mo(g?E(g,k):k),c.has(k))throw l(k);c.add(k);let P=this.refs[k];return typeof P=="string"&&(P=this.refs[P]),typeof P=="object"?u(d,P.schema,k):k!==Mo(f)&&(k[0]==="#"?(u(d,a[k],k),a[k]=d):this.refs[k]=f),k}function w(k){if(typeof k=="string"){if(!$O.test(k))throw new Error(`invalid anchor "${k}"`);y.call(this,`#${k}`)}}}),a;function u(d,h,m){if(h!==void 0&&!fO(d,h))throw l(m)}function l(d){return new Error(`reference "${d}" resolves to more than one schema`)}}_t.getSchemaRefs=bO});var Bs=b(en=>{"use strict";Object.defineProperty(en,"__esModule",{value:!0});en.getData=en.KeywordCxt=en.validateFunctionCode=void 0;var Bb=Sb(),Wb=Gs(),lh=th(),El=Gs(),wO=Ob(),Js=Db(),uh=Mb(),Z=oe(),K=Pr(),kO=Ks(),zr=he(),Hs=Fs();function xO(e){if(Qb(e)&&(ew(e),Xb(e))){PO(e);return}Yb(e,()=>(0,Bb.topBoolOrEmptySchema)(e))}en.validateFunctionCode=xO;function Yb({gen:e,validateName:t,schema:r,schemaEnv:o,opts:n},i){n.code.es5?e.func(t,(0,Z._)`${K.default.data}, ${K.default.valCxt}`,o.$async,()=>{e.code((0,Z._)`"use strict"; ${Kb(r,n)}`),TO(e,n),e.code(i)}):e.func(t,(0,Z._)`${K.default.data}, ${SO(n)}`,o.$async,()=>e.code(Kb(r,n)).code(i))}function SO(e){return(0,Z._)`{${K.default.instancePath}="", ${K.default.parentData}, ${K.default.parentDataProperty}, ${K.default.rootData}=${K.default.data}${e.dynamicRef?(0,Z._)`, ${K.default.dynamicAnchors}={}`:Z.nil}}={}`}function TO(e,t){e.if(K.default.valCxt,()=>{e.var(K.default.instancePath,(0,Z._)`${K.default.valCxt}.${K.default.instancePath}`),e.var(K.default.parentData,(0,Z._)`${K.default.valCxt}.${K.default.parentData}`),e.var(K.default.parentDataProperty,(0,Z._)`${K.default.valCxt}.${K.default.parentDataProperty}`),e.var(K.default.rootData,(0,Z._)`${K.default.valCxt}.${K.default.rootData}`),t.dynamicRef&&e.var(K.default.dynamicAnchors,(0,Z._)`${K.default.valCxt}.${K.default.dynamicAnchors}`)},()=>{e.var(K.default.instancePath,(0,Z._)`""`),e.var(K.default.parentData,(0,Z._)`undefined`),e.var(K.default.parentDataProperty,(0,Z._)`undefined`),e.var(K.default.rootData,K.default.data),t.dynamicRef&&e.var(K.default.dynamicAnchors,(0,Z._)`{}`)})}function PO(e){let{schema:t,opts:r,gen:o}=e;Yb(e,()=>{r.$comment&&t.$comment&&rw(e),OO(e),o.let(K.default.vErrors,null),o.let(K.default.errors,0),r.unevaluated&&zO(e),tw(e),CO(e)})}function zO(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,Z._)`${r}.evaluated`),t.if((0,Z._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,Z._)`${e.evaluated}.props`,(0,Z._)`undefined`)),t.if((0,Z._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,Z._)`${e.evaluated}.items`,(0,Z._)`undefined`))}function Kb(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,Z._)`/*# sourceURL=${r} */`:Z.nil}function EO(e,t){if(Qb(e)&&(ew(e),Xb(e))){IO(e,t);return}(0,Bb.boolOrEmptySchema)(e,t)}function Xb({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 Qb(e){return typeof e.schema!="boolean"}function IO(e,t){let{schema:r,gen:o,opts:n}=e;n.$comment&&r.$comment&&rw(e),NO(e),RO(e);let i=o.const("_errs",K.default.errors);tw(e,i),o.var(t,(0,Z._)`${i} === ${K.default.errors}`)}function ew(e){(0,zr.checkUnknownRules)(e),jO(e)}function tw(e,t){if(e.opts.jtd)return Hb(e,[],!1,t);let r=(0,Wb.getSchemaTypes)(e.schema),o=(0,Wb.coerceAndCheckDataType)(e,r);Hb(e,r,!o,t)}function jO(e){let{schema:t,errSchemaPath:r,opts:o,self:n}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,zr.schemaHasRulesButRef)(t,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function OO(e){let{schema:t,opts:r}=e;t.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,zr.checkStrictMode)(e,"default is ignored in the schema root")}function NO(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,kO.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function RO(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function rw({gen:e,schemaEnv:t,schema:r,errSchemaPath:o,opts:n}){let i=r.$comment;if(n.$comment===!0)e.code((0,Z._)`${K.default.self}.logger.log(${i})`);else if(typeof n.$comment=="function"){let s=(0,Z.str)`${o}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,Z._)`${K.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function CO(e){let{gen:t,schemaEnv:r,validateName:o,ValidationError:n,opts:i}=e;r.$async?t.if((0,Z._)`${K.default.errors} === 0`,()=>t.return(K.default.data),()=>t.throw((0,Z._)`new ${n}(${K.default.vErrors})`)):(t.assign((0,Z._)`${o}.errors`,K.default.vErrors),i.unevaluated&&AO(e),t.return((0,Z._)`${K.default.errors} === 0`))}function AO({gen:e,evaluated:t,props:r,items:o}){r instanceof Z.Name&&e.assign((0,Z._)`${t}.props`,r),o instanceof Z.Name&&e.assign((0,Z._)`${t}.items`,o)}function Hb(e,t,r,o){let{gen:n,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,zr.schemaHasRulesButRef)(i,l))){n.block(()=>ow(e,"$ref",l.all.$ref.definition));return}c.jtd||DO(e,t),n.block(()=>{for(let h of l.rules)d(h);d(l.post)});function d(h){(0,lh.shouldUseGroup)(i,h)&&(h.type?(n.if((0,El.checkDataType)(h.type,s,c.strictNumbers)),Jb(e,h),t.length===1&&t[0]===h.type&&r&&(n.else(),(0,El.reportTypeError)(e)),n.endIf()):Jb(e,h),a||n.if((0,Z._)`${K.default.errors} === ${o||0}`))}}function Jb(e,t){let{gen:r,schema:o,opts:{useDefaults:n}}=e;n&&(0,wO.assignDefaults)(e,t.type),r.block(()=>{for(let i of t.rules)(0,lh.shouldUseRule)(o,i)&&ow(e,i.keyword,i.definition,t.type)})}function DO(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(qO(e,t),e.opts.allowUnionTypes||MO(e,t),UO(e,e.dataTypes))}function qO(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{nw(e.dataTypes,r)||dh(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),LO(e,t)}}function MO(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&dh(e,"use allowUnionTypes to allow union type keyword")}function UO(e,t){let r=e.self.RULES.all;for(let o in r){let n=r[o];if(typeof n=="object"&&(0,lh.shouldUseRule)(e.schema,n)){let{type:i}=n.definition;i.length&&!i.some(s=>ZO(t,s))&&dh(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function ZO(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function nw(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function LO(e,t){let r=[];for(let o of e.dataTypes)nw(t,o)?r.push(o):t.includes("integer")&&o==="number"&&r.push("integer");e.dataTypes=r}function dh(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,zr.checkStrictMode)(e,t,e.opts.strictTypes)}var Il=class{constructor(t,r,o){if((0,Js.validateKeywordUsage)(t,r,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,zr.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=r.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=r,this.$data)this.schemaCode=t.gen.const("vSchema",iw(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Js.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=t.gen.const("_errs",K.default.errors))}result(t,r,o){this.failResult((0,Z.not)(t),r,o)}failResult(t,r,o){this.gen.if(t),o?o():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,r){this.failResult((0,Z.not)(t),void 0,r)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:r}=this;this.fail((0,Z._)`${r} !== undefined && (${(0,Z.or)(this.invalid$data(),t)})`)}error(t,r,o){if(r){this.setParams(r),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,r){(t?Hs.reportExtraError:Hs.reportError)(this,this.def.error,r)}$dataError(){(0,Hs.reportError)(this,this.def.$dataError||Hs.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Hs.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,r){r?Object.assign(this.params,t):this.params=t}block$data(t,r,o=Z.nil){this.gen.block(()=>{this.check$data(t,o),r()})}check$data(t=Z.nil,r=Z.nil){if(!this.$data)return;let{gen:o,schemaCode:n,schemaType:i,def:s}=this;o.if((0,Z.or)((0,Z._)`${n} === undefined`,r)),t!==Z.nil&&o.assign(t,!0),(i.length||s.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==Z.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:r,schemaType:o,def:n,it:i}=this;return(0,Z.or)(s(),a());function s(){if(o.length){if(!(r instanceof Z.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,Z._)`${(0,El.checkDataTypes)(c,r,i.opts.strictNumbers,El.DataType.Wrong)}`}return Z.nil}function a(){if(n.validateSchema){let c=t.scopeValue("validate$data",{ref:n.validateSchema});return(0,Z._)`!${c}(${r})`}return Z.nil}}subschema(t,r){let o=(0,uh.getSubschema)(this.it,t);(0,uh.extendSubschemaData)(o,this.it,t),(0,uh.extendSubschemaMode)(o,t);let n={...this.it,...o,items:void 0,props:void 0};return EO(n,r),n}mergeEvaluated(t,r){let{it:o,gen:n}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=zr.mergeEvaluated.props(n,t.props,o.props,r)),o.items!==!0&&t.items!==void 0&&(o.items=zr.mergeEvaluated.items(n,t.items,o.items,r)))}mergeValidEvaluated(t,r){let{it:o,gen:n}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return n.if(r,()=>this.mergeEvaluated(t,Z.Name)),!0}};en.KeywordCxt=Il;function ow(e,t,r,o){let n=new Il(e,r,t);"code"in r?r.code(n,o):n.$data&&r.validate?(0,Js.funcKeywordCode)(n,r):"macro"in r?(0,Js.macroKeywordCode)(n,r):(r.compile||r.validate)&&(0,Js.funcKeywordCode)(n,r)}var VO=/^\/(?:[^~]|~0|~1)*$/,FO=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function iw(e,{dataLevel:t,dataNames:r,dataPathArr:o}){let n,i;if(e==="")return K.default.rootData;if(e[0]==="/"){if(!VO.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,i=K.default.rootData}else{let u=FO.exec(e);if(!u)throw new Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(n=u[2],n==="#"){if(l>=t)throw new Error(c("property/index",l));return o[t-l]}if(l>t)throw new Error(c("data",l));if(i=r[t-l],!n)return i}let s=i,a=n.split("/");for(let u of a)u&&(i=(0,Z._)`${i}${(0,Z.getProperty)((0,zr.unescapeJsonPointer)(u))}`,s=(0,Z._)`${s} && ${i}`);return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}en.getData=iw});var jl=b(fh=>{"use strict";Object.defineProperty(fh,"__esModule",{value:!0});var ph=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};fh.default=ph});var Ys=b(gh=>{"use strict";Object.defineProperty(gh,"__esModule",{value:!0});var mh=Ks(),hh=class extends Error{constructor(t,r,o,n){super(n||`can't resolve reference ${o} from id ${r}`),this.missingRef=(0,mh.resolveUrl)(t,r,o),this.missingSchema=(0,mh.normalizeId)((0,mh.getFullPath)(t,this.missingRef))}};gh.default=hh});var Nl=b(At=>{"use strict";Object.defineProperty(At,"__esModule",{value:!0});At.resolveSchema=At.getCompilingSchema=At.resolveRef=At.compileSchema=At.SchemaEnv=void 0;var Bt=oe(),GO=jl(),Nn=Pr(),Yt=Ks(),sw=he(),WO=Bs(),Uo=class{constructor(t){var r;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,Yt.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};At.SchemaEnv=Uo;function _h(e){let t=aw.call(this,e);if(t)return t;let r=(0,Yt.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:n}=this.opts.code,{ownProperties:i}=this.opts,s=new Bt.CodeGen(this.scope,{es5:o,lines:n,ownProperties:i}),a;e.$async&&(a=s.scopeValue("Error",{ref:GO.default,code:(0,Bt._)`require("ajv/dist/runtime/validation_error").default`}));let c=s.scopeName("validate");e.validateName=c;let u={gen:s,allErrors:this.opts.allErrors,data:Nn.default.data,parentData:Nn.default.parentData,parentDataProperty:Nn.default.parentDataProperty,dataNames:[Nn.default.data],dataPathArr:[Bt.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,Bt.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:Bt.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,Bt._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),(0,WO.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let d=s.toString();l=`${s.scopeRefs(Nn.default.scope)}return ${d}`,this.opts.code.process&&(l=this.opts.code.process(l,e));let m=new Function(`${Nn.default.self}`,`${Nn.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:m}),m.errors=null,m.schema=e.schema,m.schemaEnv=e,e.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:c,validateCode:d,scopeValues:s._values}),this.opts.unevaluated){let{props:p,items:f}=u;m.evaluated={props:p instanceof Bt.Name?void 0:p,items:f instanceof Bt.Name?void 0:f,dynamicProps:p instanceof Bt.Name,dynamicItems:f instanceof Bt.Name},m.source&&(m.source.evaluated=(0,Bt.stringify)(m.evaluated))}return e.validate=m,e}catch(d){throw delete e.validate,delete e.validateName,l&&this.logger.error("Error compiling schema, function code:",l),d}finally{this._compilations.delete(e)}}At.compileSchema=_h;function KO(e,t,r){var o;r=(0,Yt.resolveUrl)(this.opts.uriResolver,t,r);let n=e.refs[r];if(n)return n;let i=BO.call(this,e,r);if(i===void 0){let s=(o=e.localRefs)===null||o===void 0?void 0:o[r],{schemaId:a}=this.opts;s&&(i=new Uo({schema:s,schemaId:a,root:e,baseId:t}))}if(i!==void 0)return e.refs[r]=HO.call(this,i)}At.resolveRef=KO;function HO(e){return(0,Yt.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:_h.call(this,e)}function aw(e){for(let t of this._compilations)if(JO(t,e))return t}At.getCompilingSchema=aw;function JO(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function BO(e,t){let r;for(;typeof(r=this.refs[t])=="string";)t=r;return r||this.schemas[t]||Ol.call(this,e,t)}function Ol(e,t){let r=this.opts.uriResolver.parse(t),o=(0,Yt._getFullPath)(this.opts.uriResolver,r),n=(0,Yt.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===n)return vh.call(this,r,e);let i=(0,Yt.normalizeId)(o),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=Ol.call(this,e,s);return typeof a?.schema!="object"?void 0:vh.call(this,r,a)}if(typeof s?.schema=="object"){if(s.validate||_h.call(this,s),i===(0,Yt.normalizeId)(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];return u&&(n=(0,Yt.resolveUrl)(this.opts.uriResolver,n,u)),new Uo({schema:a,schemaId:c,root:e,baseId:n})}return vh.call(this,r,s)}}At.resolveSchema=Ol;var YO=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function vh(e,{baseId:t,schema:r,root:o}){var n;if(((n=e.fragment)===null||n===void 0?void 0:n[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let c=r[(0,sw.unescapeFragment)(a)];if(c===void 0)return;r=c;let u=typeof r=="object"&&r[this.opts.schemaId];!YO.has(a)&&u&&(t=(0,Yt.resolveUrl)(this.opts.uriResolver,t,u))}let i;if(typeof r!="boolean"&&r.$ref&&!(0,sw.schemaHasRulesButRef)(r,this.RULES)){let a=(0,Yt.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=Ol.call(this,o,a)}let{schemaId:s}=this.opts;if(i=i||new Uo({schema:r,schemaId:s,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var cw=b((cW,XO)=>{XO.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 $h=b((uW,pw)=>{"use strict";var QO=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),lw=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);function yh(e){let t="",r=0,o=0;for(o=0;o<e.length;o++)if(r=e[o].charCodeAt(0),r!==48){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[o];break}for(o+=1;o<e.length;o++){if(r=e[o].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[o]}return t}var eN=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function uw(e){return e.length=0,!0}function tN(e,t,r){if(e.length){let o=yh(e);if(o!=="")t.push(o);else return r.error=!0,!1;e.length=0}return!0}function rN(e){let t=0,r={error:!1,address:"",zone:""},o=[],n=[],i=!1,s=!1,a=tN;for(let c=0;c<e.length;c++){let u=e[c];if(!(u==="["||u==="]"))if(u===":"){if(i===!0&&(s=!0),!a(n,o,r))break;if(++t>7){r.error=!0;break}c>0&&e[c-1]===":"&&(i=!0),o.push(":");continue}else if(u==="%"){if(!a(n,o,r))break;a=uw}else{n.push(u);continue}}return n.length&&(a===uw?r.zone=n.join(""):s?o.push(n.join("")):o.push(yh(n))),r.address=o.join(""),r}function dw(e){if(nN(e,":")<2)return{host:e,isIPV6:!1};let t=rN(e);if(t.error)return{host:e,isIPV6:!1};{let r=t.address,o=t.address;return t.zone&&(r+="%"+t.zone,o+="%25"+t.zone),{host:r,isIPV6:!0,escapedHost:o}}}function nN(e,t){let r=0;for(let o=0;o<e.length;o++)e[o]===t&&r++;return r}function oN(e){let t=e,r=[],o=-1,n=0;for(;n=t.length;){if(n===1){if(t===".")break;if(t==="/"){r.push("/");break}else{r.push(t);break}}else if(n===2){if(t[0]==="."){if(t[1]===".")break;if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"&&(t[1]==="."||t[1]==="/")){r.push("/");break}}else if(n===3&&t==="/.."){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]==="/"&&t[1]==="."){if(t[2]==="/"){t=t.slice(2);continue}else if(t[2]==="."&&t[3]==="/"){t=t.slice(3),r.length!==0&&r.pop();continue}}if((o=t.indexOf("/",1))===-1){r.push(t);break}else r.push(t.slice(0,o)),t=t.slice(o)}return r.join("")}function iN(e,t){let r=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=r(e.scheme)),e.userinfo!==void 0&&(e.userinfo=r(e.userinfo)),e.host!==void 0&&(e.host=r(e.host)),e.path!==void 0&&(e.path=r(e.path)),e.query!==void 0&&(e.query=r(e.query)),e.fragment!==void 0&&(e.fragment=r(e.fragment)),e}function sN(e){let t=[];if(e.userinfo!==void 0&&(t.push(e.userinfo),t.push("@")),e.host!==void 0){let r=unescape(e.host);if(!lw(r)){let o=dw(r);o.isIPV6===!0?r=`[${o.escapedHost}]`:r=e.host}t.push(r)}return(typeof e.port=="number"||typeof e.port=="string")&&(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0}pw.exports={nonSimpleDomain:eN,recomposeAuthority:sN,normalizeComponentEncoding:iN,removeDotSegments:oN,isIPv4:lw,isUUID:QO,normalizeIPv6:dw,stringArrayToHexStripped:yh}});var vw=b((lW,gw)=>{"use strict";var{isUUID:aN}=$h(),cN=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,uN=["http","https","ws","wss","urn","urn:uuid"];function lN(e){return uN.indexOf(e)!==-1}function bh(e){return e.secure===!0?!0:e.secure===!1?!1:e.scheme?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"):!1}function fw(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function mw(e){let t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function dN(e){return e.secure=bh(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function pN(e){if((e.port===(bh(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),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 fN(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(cN);if(r){let o=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let n=`${o}:${t.nid||e.nid}`,i=wh(n);e.path=void 0,i&&(e=i.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function mN(e,t){if(e.nid===void 0)throw new Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",o=e.nid.toLowerCase(),n=`${r}:${t.nid||o}`,i=wh(n);i&&(e=i.serialize(e,t));let s=e,a=e.nss;return s.path=`${o||t.nid}:${a}`,t.skipEscape=!0,s}function hN(e,t){let r=e;return r.uuid=r.nss,r.nss=void 0,!t.tolerant&&(!r.uuid||!aN(r.uuid))&&(r.error=r.error||"UUID is not valid."),r}function gN(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var hw={scheme:"http",domainHost:!0,parse:fw,serialize:mw},vN={scheme:"https",domainHost:hw.domainHost,parse:fw,serialize:mw},Rl={scheme:"ws",domainHost:!0,parse:dN,serialize:pN},_N={scheme:"wss",domainHost:Rl.domainHost,parse:Rl.parse,serialize:Rl.serialize},yN={scheme:"urn",parse:fN,serialize:mN,skipNormalize:!0},$N={scheme:"urn:uuid",parse:hN,serialize:gN,skipNormalize:!0},Cl={http:hw,https:vN,ws:Rl,wss:_N,urn:yN,"urn:uuid":$N};Object.setPrototypeOf(Cl,null);function wh(e){return e&&(Cl[e]||Cl[e.toLowerCase()])||void 0}gw.exports={wsIsSecure:bh,SCHEMES:Cl,isValidSchemeName:lN,getSchemeHandler:wh}});var xh=b((dW,Dl)=>{"use strict";var{normalizeIPv6:bN,removeDotSegments:Xs,recomposeAuthority:wN,normalizeComponentEncoding:Al,isIPv4:kN,nonSimpleDomain:xN}=$h(),{SCHEMES:SN,getSchemeHandler:_w}=vw();function TN(e,t){return typeof e=="string"?e=ur(Er(e,t),t):typeof e=="object"&&(e=Er(ur(e,t),t)),e}function PN(e,t,r){let o=r?Object.assign({scheme:"null"},r):{scheme:"null"},n=yw(Er(e,o),Er(t,o),o,!0);return o.skipEscape=!0,ur(n,o)}function yw(e,t,r,o){let n={};return o||(e=Er(ur(e,r),r),t=Er(ur(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(n.scheme=t.scheme,n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=Xs(t.path||""),n.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=Xs(t.path||""),n.query=t.query):(t.path?(t.path[0]==="/"?n.path=Xs(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?n.path="/"+t.path:e.path?n.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:n.path=t.path,n.path=Xs(n.path)),n.query=t.query):(n.path=e.path,t.query!==void 0?n.query=t.query:n.query=e.query),n.userinfo=e.userinfo,n.host=e.host,n.port=e.port),n.scheme=e.scheme),n.fragment=t.fragment,n}function zN(e,t,r){return typeof e=="string"?(e=unescape(e),e=ur(Al(Er(e,r),!0),{...r,skipEscape:!0})):typeof e=="object"&&(e=ur(Al(e,!0),{...r,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=ur(Al(Er(t,r),!0),{...r,skipEscape:!0})):typeof t=="object"&&(t=ur(Al(t,!0),{...r,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function ur(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:""},o=Object.assign({},t),n=[],i=_w(o.scheme||r.scheme);i&&i.serialize&&i.serialize(r,o),r.path!==void 0&&(o.skipEscape?r.path=unescape(r.path):(r.path=escape(r.path),r.scheme!==void 0&&(r.path=r.path.split("%3A").join(":")))),o.reference!=="suffix"&&r.scheme&&n.push(r.scheme,":");let s=wN(r);if(s!==void 0&&(o.reference!=="suffix"&&n.push("//"),n.push(s),r.path&&r.path[0]!=="/"&&n.push("/")),r.path!==void 0){let a=r.path;!o.absolutePath&&(!i||!i.absolutePath)&&(a=Xs(a)),s===void 0&&a[0]==="/"&&a[1]==="/"&&(a="/%2F"+a.slice(2)),n.push(a)}return r.query!==void 0&&n.push("?",r.query),r.fragment!==void 0&&n.push("#",r.fragment),n.join("")}var EN=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function Er(e,t){let r=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},n=!1;r.reference==="suffix"&&(r.scheme?e=r.scheme+":"+e:e="//"+e);let i=e.match(EN);if(i){if(o.scheme=i[1],o.userinfo=i[3],o.host=i[4],o.port=parseInt(i[5],10),o.path=i[6]||"",o.query=i[7],o.fragment=i[8],isNaN(o.port)&&(o.port=i[5]),o.host)if(kN(o.host)===!1){let c=bN(o.host);o.host=c.host.toLowerCase(),n=c.isIPV6}else n=!0;o.scheme===void 0&&o.userinfo===void 0&&o.host===void 0&&o.port===void 0&&o.query===void 0&&!o.path?o.reference="same-document":o.scheme===void 0?o.reference="relative":o.fragment===void 0?o.reference="absolute":o.reference="uri",r.reference&&r.reference!=="suffix"&&r.reference!==o.reference&&(o.error=o.error||"URI is not a "+r.reference+" reference.");let s=_w(r.scheme||o.scheme);if(!r.unicodeSupport&&(!s||!s.unicodeSupport)&&o.host&&(r.domainHost||s&&s.domainHost)&&n===!1&&xN(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(a){o.error=o.error||"Host's domain name can not be converted to ASCII: "+a}(!s||s&&!s.skipNormalize)&&(e.indexOf("%")!==-1&&(o.scheme!==void 0&&(o.scheme=unescape(o.scheme)),o.host!==void 0&&(o.host=unescape(o.host))),o.path&&(o.path=escape(unescape(o.path))),o.fragment&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),s&&s.parse&&s.parse(o,r)}else o.error=o.error||"URI can not be parsed.";return o}var kh={SCHEMES:SN,normalize:TN,resolve:PN,resolveComponent:yw,equal:zN,serialize:ur,parse:Er};Dl.exports=kh;Dl.exports.default=kh;Dl.exports.fastUri=kh});var bw=b(Sh=>{"use strict";Object.defineProperty(Sh,"__esModule",{value:!0});var $w=xh();$w.code='require("ajv/dist/runtime/uri").default';Sh.default=$w});var Ew=b(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.CodeGen=He.Name=He.nil=He.stringify=He.str=He._=He.KeywordCxt=void 0;var IN=Bs();Object.defineProperty(He,"KeywordCxt",{enumerable:!0,get:function(){return IN.KeywordCxt}});var Zo=oe();Object.defineProperty(He,"_",{enumerable:!0,get:function(){return Zo._}});Object.defineProperty(He,"str",{enumerable:!0,get:function(){return Zo.str}});Object.defineProperty(He,"stringify",{enumerable:!0,get:function(){return Zo.stringify}});Object.defineProperty(He,"nil",{enumerable:!0,get:function(){return Zo.nil}});Object.defineProperty(He,"Name",{enumerable:!0,get:function(){return Zo.Name}});Object.defineProperty(He,"CodeGen",{enumerable:!0,get:function(){return Zo.CodeGen}});var jN=jl(),Tw=Ys(),ON=eh(),Qs=Nl(),NN=oe(),ea=Ks(),ql=Gs(),Ph=he(),ww=cw(),RN=bw(),Pw=(e,t)=>new RegExp(e,t);Pw.code="new RegExp";var CN=["removeAdditional","useDefaults","coerceTypes"],AN=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),DN={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."},qN={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},kw=200;function MN(e){var t,r,o,n,i,s,a,c,u,l,d,h,m,p,f,g,y,w,k,E,P,ze,Me,or,pn;let Lt=e.strict,fn=(t=e.code)===null||t===void 0?void 0:t.optimize,ui=fn===!0||fn===void 0?1:fn||0,li=(o=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&o!==void 0?o:Pw,Ud=(n=e.uriResolver)!==null&&n!==void 0?n:RN.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:Lt)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:Lt)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:Lt)!==null&&l!==void 0?l:"log",strictTuples:(h=(d=e.strictTuples)!==null&&d!==void 0?d:Lt)!==null&&h!==void 0?h:"log",strictRequired:(p=(m=e.strictRequired)!==null&&m!==void 0?m:Lt)!==null&&p!==void 0?p:!1,code:e.code?{...e.code,optimize:ui,regExp:li}:{optimize:ui,regExp:li},loopRequired:(f=e.loopRequired)!==null&&f!==void 0?f:kw,loopEnum:(g=e.loopEnum)!==null&&g!==void 0?g:kw,meta:(y=e.meta)!==null&&y!==void 0?y:!0,messages:(w=e.messages)!==null&&w!==void 0?w:!0,inlineRefs:(k=e.inlineRefs)!==null&&k!==void 0?k:!0,schemaId:(E=e.schemaId)!==null&&E!==void 0?E:"$id",addUsedSchema:(P=e.addUsedSchema)!==null&&P!==void 0?P:!0,validateSchema:(ze=e.validateSchema)!==null&&ze!==void 0?ze:!0,validateFormats:(Me=e.validateFormats)!==null&&Me!==void 0?Me:!0,unicodeRegExp:(or=e.unicodeRegExp)!==null&&or!==void 0?or:!0,int32range:(pn=e.int32range)!==null&&pn!==void 0?pn:!0,uriResolver:Ud}}var ta=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...MN(t)};let{es5:r,lines:o}=this.opts.code;this.scope=new NN.ValueScope({scope:{},prefixes:AN,es5:r,lines:o}),this.logger=GN(t.logger);let n=t.validateFormats;t.validateFormats=!1,this.RULES=(0,ON.getRules)(),xw.call(this,DN,t,"NOT SUPPORTED"),xw.call(this,qN,t,"DEPRECATED","warn"),this._metaOpts=VN.call(this),t.formats&&ZN.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&LN.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),UN.call(this),t.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:r,schemaId:o}=this.opts,n=ww;o==="id"&&(n={...ww},n.id=n.$id,delete n.$id),r&&t&&this.addMetaSchema(n,n[o],!1)}defaultMeta(){let{meta:t,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[r]||t:void 0}validate(t,r){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let n=o(r);return"$async"in o||(this.errors=o.errors),n}compile(t,r){let o=this._addSchema(t,r);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return n.call(this,t,r);async function n(l,d){await i.call(this,l.$schema);let h=this._addSchema(l,d);return h.validate||s.call(this,h)}async function i(l){l&&!this.getSchema(l)&&await n.call(this,{$ref:l},!0)}async function s(l){try{return this._compileSchemaEnv(l)}catch(d){if(!(d instanceof Tw.default))throw d;return a.call(this,d),await c.call(this,d.missingSchema),s.call(this,l)}}function a({missingSchema:l,missingRef:d}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${d} cannot be resolved`)}async function c(l){let d=await u.call(this,l);this.refs[l]||await i.call(this,d.$schema),this.refs[l]||this.addSchema(d,l,r)}async function u(l){let d=this._loading[l];if(d)return d;try{return await(this._loading[l]=o(l))}finally{delete this._loading[l]}}}addSchema(t,r,o,n=this.opts.validateSchema){if(Array.isArray(t)){for(let s of t)this.addSchema(s,void 0,o,n);return this}let i;if(typeof t=="object"){let{schemaId:s}=this.opts;if(i=t[s],i!==void 0&&typeof i!="string")throw new Error(`schema ${s} must be string`)}return r=(0,ea.normalizeId)(r||i),this._checkUnique(r),this.schemas[r]=this._addSchema(t,o,r,n,!0),this}addMetaSchema(t,r,o=this.opts.validateSchema){return this.addSchema(t,r,!0,o),this}validateSchema(t,r){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(o,t);if(!n&&r){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return n}getSchema(t){let r;for(;typeof(r=Sw.call(this,t))=="string";)t=r;if(r===void 0){let{schemaId:o}=this.opts,n=new Qs.SchemaEnv({schema:{},schemaId:o});if(r=Qs.resolveSchema.call(this,n,t),!r)return;this.refs[t]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=Sw.call(this,t);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let r=t;this._cache.delete(r);let o=t[this.opts.schemaId];return o&&(o=(0,ea.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let r of t)this.addKeyword(r);return this}addKeyword(t,r){let o;if(typeof t=="string")o=t,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=o);else if(typeof t=="object"&&r===void 0){if(r=t,o=r.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(KN.call(this,o,r),!r)return(0,Ph.eachItem)(o,i=>Th.call(this,i)),this;JN.call(this,r);let n={...r,type:(0,ql.getJSONTypes)(r.type),schemaType:(0,ql.getJSONTypes)(r.schemaType)};return(0,Ph.eachItem)(o,n.type.length===0?i=>Th.call(this,i,n):i=>n.type.forEach(s=>Th.call(this,i,n,s))),this}getKeyword(t){let r=this.RULES.all[t];return typeof r=="object"?r.definition:!!r}removeKeyword(t){let{RULES:r}=this;delete r.keywords[t],delete r.all[t];for(let o of r.rules){let n=o.rules.findIndex(i=>i.keyword===t);n>=0&&o.rules.splice(n,1)}return this}addFormat(t,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[t]=r,this}errorsText(t=this.errors,{separator:r=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(n=>`${o}${n.instancePath} ${n.message}`).reduce((n,i)=>n+r+i)}$dataMetaSchema(t,r){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let n of r){let i=n.split("/").slice(1),s=t;for(let a of i)s=s[a];for(let a in o){let c=o[a];if(typeof c!="object")continue;let{$data:u}=c.definition,l=s[a];u&&l&&(s[a]=zw(l))}}return t}_removeAllSchemas(t,r){for(let o in t){let n=t[o];(!r||r.test(o))&&(typeof n=="string"?delete t[o]:n&&!n.meta&&(this._cache.delete(n.schema),delete t[o]))}}_addSchema(t,r,o,n=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:a}=this.opts;if(typeof t=="object")s=t[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,ea.normalizeId)(s||o);let u=ea.getSchemaRefs.call(this,t,o);return c=new Qs.SchemaEnv({schema:t,schemaId:a,meta:r,baseId:o,localRefs:u}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),n&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):Qs.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let r=this.opts;this.opts=this._metaOpts;try{Qs.compileSchema.call(this,t)}finally{this.opts=r}}};ta.ValidationError=jN.default;ta.MissingRefError=Tw.default;He.default=ta;function xw(e,t,r,o="error"){for(let n in e){let i=n;i in t&&this.logger[o](`${r}: option ${n}. ${e[i]}`)}}function Sw(e){return e=(0,ea.normalizeId)(e),this.schemas[e]||this.refs[e]}function UN(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function ZN(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function LN(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];r.keyword||(r.keyword=t),this.addKeyword(r)}}function VN(){let e={...this.opts};for(let t of CN)delete e[t];return e}var FN={log(){},warn(){},error(){}};function GN(e){if(e===!1)return FN;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var WN=/^[a-z_$][a-z0-9_$:-]*$/i;function KN(e,t){let{RULES:r}=this;if((0,Ph.eachItem)(e,o=>{if(r.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!WN.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function Th(e,t,r){var o;let n=t?.post;if(r&&n)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=n?i.post:i.rules.find(({type:c})=>c===r);if(s||(s={type:r,rules:[]},i.rules.push(s)),i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:(0,ql.getJSONTypes)(t.type),schemaType:(0,ql.getJSONTypes)(t.schemaType)}};t.before?HN.call(this,s,a,t.before):s.rules.push(a),i.all[e]=a,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function HN(e,t,r){let o=e.rules.findIndex(n=>n.keyword===r);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function JN(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=zw(t)),e.validateSchema=this.compile(t,!0))}var BN={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function zw(e){return{anyOf:[e,BN]}}});var Iw=b(zh=>{"use strict";Object.defineProperty(zh,"__esModule",{value:!0});var YN={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};zh.default=YN});var Rw=b(Rn=>{"use strict";Object.defineProperty(Rn,"__esModule",{value:!0});Rn.callRef=Rn.getValidate=void 0;var XN=Ys(),jw=Ct(),yt=oe(),Lo=Pr(),Ow=Nl(),Ml=he(),QN={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:o}=e,{baseId:n,schemaEnv:i,validateName:s,opts:a,self:c}=o,{root:u}=i;if((r==="#"||r==="#/")&&n===u.baseId)return d();let l=Ow.resolveRef.call(c,u,n,r);if(l===void 0)throw new XN.default(o.opts.uriResolver,n,r);if(l instanceof Ow.SchemaEnv)return h(l);return m(l);function d(){if(i===u)return Ul(e,s,i,i.$async);let p=t.scopeValue("root",{ref:u});return Ul(e,(0,yt._)`${p}.validate`,u,u.$async)}function h(p){let f=Nw(e,p);Ul(e,f,p,p.$async)}function m(p){let f=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,yt.stringify)(p)}:{ref:p}),g=t.name("valid"),y=e.subschema({schema:p,dataTypes:[],schemaPath:yt.nil,topSchemaRef:f,errSchemaPath:r},g);e.mergeEvaluated(y),e.ok(g)}}};function Nw(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,yt._)`${r.scopeValue("wrapper",{ref:t})}.validate`}Rn.getValidate=Nw;function Ul(e,t,r,o){let{gen:n,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?Lo.default.this:yt.nil;o?l():d();function l(){if(!a.$async)throw new Error("async schema referenced by sync schema");let p=n.let("valid");n.try(()=>{n.code((0,yt._)`await ${(0,jw.callValidateCode)(e,t,u)}`),m(t),s||n.assign(p,!0)},f=>{n.if((0,yt._)`!(${f} instanceof ${i.ValidationError})`,()=>n.throw(f)),h(f),s||n.assign(p,!1)}),e.ok(p)}function d(){e.result((0,jw.callValidateCode)(e,t,u),()=>m(t),()=>h(t))}function h(p){let f=(0,yt._)`${p}.errors`;n.assign(Lo.default.vErrors,(0,yt._)`${Lo.default.vErrors} === null ? ${f} : ${Lo.default.vErrors}.concat(${f})`),n.assign(Lo.default.errors,(0,yt._)`${Lo.default.vErrors}.length`)}function m(p){var f;if(!i.opts.unevaluated)return;let g=(f=r?.validate)===null||f===void 0?void 0:f.evaluated;if(i.props!==!0)if(g&&!g.dynamicProps)g.props!==void 0&&(i.props=Ml.mergeEvaluated.props(n,g.props,i.props));else{let y=n.var("props",(0,yt._)`${p}.evaluated.props`);i.props=Ml.mergeEvaluated.props(n,y,i.props,yt.Name)}if(i.items!==!0)if(g&&!g.dynamicItems)g.items!==void 0&&(i.items=Ml.mergeEvaluated.items(n,g.items,i.items));else{let y=n.var("items",(0,yt._)`${p}.evaluated.items`);i.items=Ml.mergeEvaluated.items(n,y,i.items,yt.Name)}}}Rn.callRef=Ul;Rn.default=QN});var Cw=b(Eh=>{"use strict";Object.defineProperty(Eh,"__esModule",{value:!0});var eR=Iw(),tR=Rw(),rR=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",eR.default,tR.default];Eh.default=rR});var Aw=b(Ih=>{"use strict";Object.defineProperty(Ih,"__esModule",{value:!0});var Zl=oe(),tn=Zl.operators,Ll={maximum:{okStr:"<=",ok:tn.LTE,fail:tn.GT},minimum:{okStr:">=",ok:tn.GTE,fail:tn.LT},exclusiveMaximum:{okStr:"<",ok:tn.LT,fail:tn.GTE},exclusiveMinimum:{okStr:">",ok:tn.GT,fail:tn.LTE}},nR={message:({keyword:e,schemaCode:t})=>(0,Zl.str)`must be ${Ll[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Zl._)`{comparison: ${Ll[e].okStr}, limit: ${t}}`},oR={keyword:Object.keys(Ll),type:"number",schemaType:"number",$data:!0,error:nR,code(e){let{keyword:t,data:r,schemaCode:o}=e;e.fail$data((0,Zl._)`${r} ${Ll[t].fail} ${o} || isNaN(${r})`)}};Ih.default=oR});var Dw=b(jh=>{"use strict";Object.defineProperty(jh,"__esModule",{value:!0});var ra=oe(),iR={message:({schemaCode:e})=>(0,ra.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,ra._)`{multipleOf: ${e}}`},sR={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:iR,code(e){let{gen:t,data:r,schemaCode:o,it:n}=e,i=n.opts.multipleOfPrecision,s=t.let("res"),a=i?(0,ra._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:(0,ra._)`${s} !== parseInt(${s})`;e.fail$data((0,ra._)`(${o} === 0 || (${s} = ${r}/${o}, ${a}))`)}};jh.default=sR});var Mw=b(Oh=>{"use strict";Object.defineProperty(Oh,"__esModule",{value:!0});function qw(e){let t=e.length,r=0,o=0,n;for(;o<t;)r++,n=e.charCodeAt(o++),n>=55296&&n<=56319&&o<t&&(n=e.charCodeAt(o),(n&64512)===56320&&o++);return r}Oh.default=qw;qw.code='require("ajv/dist/runtime/ucs2length").default'});var Uw=b(Nh=>{"use strict";Object.defineProperty(Nh,"__esModule",{value:!0});var Cn=oe(),aR=he(),cR=Mw(),uR={message({keyword:e,schemaCode:t}){let r=e==="maxLength"?"more":"fewer";return(0,Cn.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,Cn._)`{limit: ${e}}`},lR={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:uR,code(e){let{keyword:t,data:r,schemaCode:o,it:n}=e,i=t==="maxLength"?Cn.operators.GT:Cn.operators.LT,s=n.opts.unicode===!1?(0,Cn._)`${r}.length`:(0,Cn._)`${(0,aR.useFunc)(e.gen,cR.default)}(${r})`;e.fail$data((0,Cn._)`${s} ${i} ${o}`)}};Nh.default=lR});var Zw=b(Rh=>{"use strict";Object.defineProperty(Rh,"__esModule",{value:!0});var dR=Ct(),Vl=oe(),pR={message:({schemaCode:e})=>(0,Vl.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,Vl._)`{pattern: ${e}}`},fR={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:pR,code(e){let{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,s=i.opts.unicodeRegExp?"u":"",a=r?(0,Vl._)`(new RegExp(${n}, ${s}))`:(0,dR.usePattern)(e,o);e.fail$data((0,Vl._)`!${a}.test(${t})`)}};Rh.default=fR});var Lw=b(Ch=>{"use strict";Object.defineProperty(Ch,"__esModule",{value:!0});var na=oe(),mR={message({keyword:e,schemaCode:t}){let r=e==="maxProperties"?"more":"fewer";return(0,na.str)`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>(0,na._)`{limit: ${e}}`},hR={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:mR,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxProperties"?na.operators.GT:na.operators.LT;e.fail$data((0,na._)`Object.keys(${r}).length ${n} ${o}`)}};Ch.default=hR});var Vw=b(Ah=>{"use strict";Object.defineProperty(Ah,"__esModule",{value:!0});var oa=Ct(),ia=oe(),gR=he(),vR={message:({params:{missingProperty:e}})=>(0,ia.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,ia._)`{missingProperty: ${e}}`},_R={keyword:"required",type:"object",schemaType:"array",$data:!0,error:vR,code(e){let{gen:t,schema:r,schemaCode:o,data:n,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors?u():l(),a.strictRequired){let m=e.parentSchema.properties,{definedProperties:p}=e.it;for(let f of r)if(m?.[f]===void 0&&!p.has(f)){let g=s.schemaEnv.baseId+s.errSchemaPath,y=`required property "${f}" is not defined at "${g}" (strictRequired)`;(0,gR.checkStrictMode)(s,y,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(ia.nil,d);else for(let m of r)(0,oa.checkReportMissingProp)(e,m)}function l(){let m=t.let("missing");if(c||i){let p=t.let("valid",!0);e.block$data(p,()=>h(m,p)),e.ok(p)}else t.if((0,oa.checkMissingProp)(e,r,m)),(0,oa.reportMissingProp)(e,m),t.else()}function d(){t.forOf("prop",o,m=>{e.setParams({missingProperty:m}),t.if((0,oa.noPropertyInData)(t,n,m,a.ownProperties),()=>e.error())})}function h(m,p){e.setParams({missingProperty:m}),t.forOf(m,o,()=>{t.assign(p,(0,oa.propertyInData)(t,n,m,a.ownProperties)),t.if((0,ia.not)(p),()=>{e.error(),t.break()})},ia.nil)}}};Ah.default=_R});var Fw=b(Dh=>{"use strict";Object.defineProperty(Dh,"__esModule",{value:!0});var sa=oe(),yR={message({keyword:e,schemaCode:t}){let r=e==="maxItems"?"more":"fewer";return(0,sa.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,sa._)`{limit: ${e}}`},$R={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:yR,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxItems"?sa.operators.GT:sa.operators.LT;e.fail$data((0,sa._)`${r}.length ${n} ${o}`)}};Dh.default=$R});var Fl=b(qh=>{"use strict";Object.defineProperty(qh,"__esModule",{value:!0});var Gw=Ws();Gw.code='require("ajv/dist/runtime/equal").default';qh.default=Gw});var Ww=b(Uh=>{"use strict";Object.defineProperty(Uh,"__esModule",{value:!0});var Mh=Gs(),Je=oe(),bR=he(),wR=Fl(),kR={message:({params:{i:e,j:t}})=>(0,Je.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Je._)`{i: ${e}, j: ${t}}`},xR={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:kR,code(e){let{gen:t,data:r,$data:o,schema:n,parentSchema:i,schemaCode:s,it:a}=e;if(!o&&!n)return;let c=t.let("valid"),u=i.items?(0,Mh.getSchemaTypes)(i.items):[];e.block$data(c,l,(0,Je._)`${s} === false`),e.ok(c);function l(){let p=t.let("i",(0,Je._)`${r}.length`),f=t.let("j");e.setParams({i:p,j:f}),t.assign(c,!0),t.if((0,Je._)`${p} > 1`,()=>(d()?h:m)(p,f))}function d(){return u.length>0&&!u.some(p=>p==="object"||p==="array")}function h(p,f){let g=t.name("item"),y=(0,Mh.checkDataTypes)(u,g,a.opts.strictNumbers,Mh.DataType.Wrong),w=t.const("indices",(0,Je._)`{}`);t.for((0,Je._)`;${p}--;`,()=>{t.let(g,(0,Je._)`${r}[${p}]`),t.if(y,(0,Je._)`continue`),u.length>1&&t.if((0,Je._)`typeof ${g} == "string"`,(0,Je._)`${g} += "_"`),t.if((0,Je._)`typeof ${w}[${g}] == "number"`,()=>{t.assign(f,(0,Je._)`${w}[${g}]`),e.error(),t.assign(c,!1).break()}).code((0,Je._)`${w}[${g}] = ${p}`)})}function m(p,f){let g=(0,bR.useFunc)(t,wR.default),y=t.name("outer");t.label(y).for((0,Je._)`;${p}--;`,()=>t.for((0,Je._)`${f} = ${p}; ${f}--;`,()=>t.if((0,Je._)`${g}(${r}[${p}], ${r}[${f}])`,()=>{e.error(),t.assign(c,!1).break(y)})))}}};Uh.default=xR});var Kw=b(Lh=>{"use strict";Object.defineProperty(Lh,"__esModule",{value:!0});var Zh=oe(),SR=he(),TR=Fl(),PR={message:"must be equal to constant",params:({schemaCode:e})=>(0,Zh._)`{allowedValue: ${e}}`},zR={keyword:"const",$data:!0,error:PR,code(e){let{gen:t,data:r,$data:o,schemaCode:n,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,Zh._)`!${(0,SR.useFunc)(t,TR.default)}(${r}, ${n})`):e.fail((0,Zh._)`${i} !== ${r}`)}};Lh.default=zR});var Hw=b(Vh=>{"use strict";Object.defineProperty(Vh,"__esModule",{value:!0});var aa=oe(),ER=he(),IR=Fl(),jR={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,aa._)`{allowedValues: ${e}}`},OR={keyword:"enum",schemaType:"array",$data:!0,error:jR,code(e){let{gen:t,data:r,$data:o,schema:n,schemaCode:i,it:s}=e;if(!o&&n.length===0)throw new Error("enum must have non-empty array");let a=n.length>=s.opts.loopEnum,c,u=()=>c??(c=(0,ER.useFunc)(t,IR.default)),l;if(a||o)l=t.let("valid"),e.block$data(l,d);else{if(!Array.isArray(n))throw new Error("ajv implementation error");let m=t.const("vSchema",i);l=(0,aa.or)(...n.map((p,f)=>h(m,f)))}e.pass(l);function d(){t.assign(l,!1),t.forOf("v",i,m=>t.if((0,aa._)`${u()}(${r}, ${m})`,()=>t.assign(l,!0).break()))}function h(m,p){let f=n[p];return typeof f=="object"&&f!==null?(0,aa._)`${u()}(${r}, ${m}[${p}])`:(0,aa._)`${r} === ${f}`}}};Vh.default=OR});var Jw=b(Fh=>{"use strict";Object.defineProperty(Fh,"__esModule",{value:!0});var NR=Aw(),RR=Dw(),CR=Uw(),AR=Zw(),DR=Lw(),qR=Vw(),MR=Fw(),UR=Ww(),ZR=Kw(),LR=Hw(),VR=[NR.default,RR.default,CR.default,AR.default,DR.default,qR.default,MR.default,UR.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},ZR.default,LR.default];Fh.default=VR});var Wh=b(ca=>{"use strict";Object.defineProperty(ca,"__esModule",{value:!0});ca.validateAdditionalItems=void 0;var An=oe(),Gh=he(),FR={message:({params:{len:e}})=>(0,An.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,An._)`{limit: ${e}}`},GR={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:FR,code(e){let{parentSchema:t,it:r}=e,{items:o}=t;if(!Array.isArray(o)){(0,Gh.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}Bw(e,o)}};function Bw(e,t){let{gen:r,schema:o,data:n,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",(0,An._)`${n}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,An._)`${a} <= ${t.length}`);else if(typeof o=="object"&&!(0,Gh.alwaysValidSchema)(s,o)){let u=r.var("valid",(0,An._)`${a} <= ${t.length}`);r.if((0,An.not)(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,l=>{e.subschema({keyword:i,dataProp:l,dataPropType:Gh.Type.Num},u),s.allErrors||r.if((0,An.not)(u),()=>r.break())})}}ca.validateAdditionalItems=Bw;ca.default=GR});var Kh=b(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});ua.validateTuple=void 0;var Yw=oe(),Gl=he(),WR=Ct(),KR={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return Xw(e,"additionalItems",t);r.items=!0,!(0,Gl.alwaysValidSchema)(r,t)&&e.ok((0,WR.validateArray)(e))}};function Xw(e,t,r=e.schema){let{gen:o,parentSchema:n,data:i,keyword:s,it:a}=e;l(n),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=Gl.mergeEvaluated.items(o,r.length,a.items));let c=o.name("valid"),u=o.const("len",(0,Yw._)`${i}.length`);r.forEach((d,h)=>{(0,Gl.alwaysValidSchema)(a,d)||(o.if((0,Yw._)`${u} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},c)),e.ok(c))});function l(d){let{opts:h,errSchemaPath:m}=a,p=r.length,f=p===d.minItems&&(p===d.maxItems||d[t]===!1);if(h.strictTuples&&!f){let g=`"${s}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${m}"`;(0,Gl.checkStrictMode)(a,g,h.strictTuples)}}}ua.validateTuple=Xw;ua.default=KR});var Qw=b(Hh=>{"use strict";Object.defineProperty(Hh,"__esModule",{value:!0});var HR=Kh(),JR={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,HR.validateTuple)(e,"items")};Hh.default=JR});var tk=b(Jh=>{"use strict";Object.defineProperty(Jh,"__esModule",{value:!0});var ek=oe(),BR=he(),YR=Ct(),XR=Wh(),QR={message:({params:{len:e}})=>(0,ek.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,ek._)`{limit: ${e}}`},e1={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:QR,code(e){let{schema:t,parentSchema:r,it:o}=e,{prefixItems:n}=r;o.items=!0,!(0,BR.alwaysValidSchema)(o,t)&&(n?(0,XR.validateAdditionalItems)(e,n):e.ok((0,YR.validateArray)(e)))}};Jh.default=e1});var rk=b(Bh=>{"use strict";Object.defineProperty(Bh,"__esModule",{value:!0});var Dt=oe(),Wl=he(),t1={message:({params:{min:e,max:t}})=>t===void 0?(0,Dt.str)`must contain at least ${e} valid item(s)`:(0,Dt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,Dt._)`{minContains: ${e}}`:(0,Dt._)`{minContains: ${e}, maxContains: ${t}}`},r1={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:t1,code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e,s,a,{minContains:c,maxContains:u}=o;i.opts.next?(s=c===void 0?1:c,a=u):s=1;let l=t.const("len",(0,Dt._)`${n}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){(0,Wl.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,Wl.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Wl.alwaysValidSchema)(i,r)){let f=(0,Dt._)`${l} >= ${s}`;a!==void 0&&(f=(0,Dt._)`${f} && ${l} <= ${a}`),e.pass(f);return}i.items=!0;let d=t.name("valid");a===void 0&&s===1?m(d,()=>t.if(d,()=>t.break())):s===0?(t.let(d,!0),a!==void 0&&t.if((0,Dt._)`${n}.length > 0`,h)):(t.let(d,!1),h()),e.result(d,()=>e.reset());function h(){let f=t.name("_valid"),g=t.let("count",0);m(f,()=>t.if(f,()=>p(g)))}function m(f,g){t.forRange("i",0,l,y=>{e.subschema({keyword:"contains",dataProp:y,dataPropType:Wl.Type.Num,compositeRule:!0},f),g()})}function p(f){t.code((0,Dt._)`${f}++`),a===void 0?t.if((0,Dt._)`${f} >= ${s}`,()=>t.assign(d,!0).break()):(t.if((0,Dt._)`${f} > ${a}`,()=>t.assign(d,!1).break()),s===1?t.assign(d,!0):t.if((0,Dt._)`${f} >= ${s}`,()=>t.assign(d,!0)))}}};Bh.default=r1});var ik=b(lr=>{"use strict";Object.defineProperty(lr,"__esModule",{value:!0});lr.validateSchemaDeps=lr.validatePropertyDeps=lr.error=void 0;var Yh=oe(),n1=he(),la=Ct();lr.error={message:({params:{property:e,depsCount:t,deps:r}})=>{let o=t===1?"property":"properties";return(0,Yh.str)`must have ${o} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:o}})=>(0,Yh._)`{property: ${e},
6
+ || ${s} === "boolean" || ${n} === null`).assign(a,(0,B._)`[${n}]`)}}}function WO({gen:e,parentData:t,parentDataProperty:r},o){e.if((0,B._)`${t} !== undefined`,()=>e.assign((0,B._)`${t}[${r}]`,o))}function nh(e,t,r,o=qo.Correct){let n=o===qo.Correct?B.operators.EQ:B.operators.NEQ,i;switch(e){case"null":return(0,B._)`${t} ${n} null`;case"array":i=(0,B._)`Array.isArray(${t})`;break;case"object":i=(0,B._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s((0,B._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return(0,B._)`typeof ${t} ${n} ${e}`}return o===qo.Correct?i:(0,B.not)(i);function s(a=B.nil){return(0,B.and)((0,B._)`typeof ${t} == "number"`,a,r?(0,B._)`isFinite(${t})`:B.nil)}}ot.checkDataType=nh;function oh(e,t,r,o){if(e.length===1)return nh(e[0],t,r,o);let n,i=(0,E$.toHash)(e);if(i.array&&i.object){let s=(0,B._)`typeof ${t} != "object"`;n=i.null?s:(0,B._)`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else n=B.nil;i.number&&delete i.integer;for(let s in i)n=(0,B.and)(n,nh(s,t,r,o));return n}ot.checkDataTypes=oh;var KO={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,B._)`{type: ${e}}`:(0,B._)`{type: ${t}}`};function ih(e){let t=HO(e);(0,ZO.reportError)(t,KO)}ot.reportTypeError=ih;function HO(e){let{gen:t,data:r,schema:o}=e,n=(0,E$.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:r,schema:o.type,schemaCode:n,schemaValue:n,parentSchema:o,params:{},it:e}}});var N$=$(El=>{"use strict";Object.defineProperty(El,"__esModule",{value:!0});El.assignDefaults=void 0;var Mo=oe(),JO=he();function BO(e,t){let{properties:r,items:o}=e.schema;if(t==="object"&&r)for(let n in r)j$(e,n,r[n].default);else t==="array"&&Array.isArray(o)&&o.forEach((n,i)=>j$(e,i,n.default))}El.assignDefaults=BO;function j$(e,t,r){let{gen:o,compositeRule:n,data:i,opts:s}=e;if(r===void 0)return;let a=(0,Mo._)`${i}${(0,Mo.getProperty)(t)}`;if(n){(0,JO.checkStrictMode)(e,`default is ignored for: ${a}`);return}let c=(0,Mo._)`${a} === undefined`;s.useDefaults==="empty"&&(c=(0,Mo._)`${c} || ${a} === null || ${a} === ""`),o.if(c,(0,Mo._)`${a} = ${(0,Mo.stringify)(r)}`)}});var Dt=$(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.validateUnion=xe.validateArray=xe.usePattern=xe.callValidateCode=xe.schemaProperties=xe.allSchemaProperties=xe.noPropertyInData=xe.propertyInData=xe.isOwnProperty=xe.hasPropFunc=xe.reportMissingProp=xe.checkMissingProp=xe.checkReportMissingProp=void 0;var Ne=oe(),sh=he(),Yr=zr(),YO=he();function XO(e,t){let{gen:r,data:o,it:n}=e;r.if(ch(r,o,t,n.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Ne._)`${t}`},!0),e.error()})}xe.checkReportMissingProp=XO;function QO({gen:e,data:t,it:{opts:r}},o,n){return(0,Ne.or)(...o.map(i=>(0,Ne.and)(ch(e,t,i,r.ownProperties),(0,Ne._)`${n} = ${i}`)))}xe.checkMissingProp=QO;function ej(e,t){e.setParams({missingProperty:t},!0),e.error()}xe.reportMissingProp=ej;function R$(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Ne._)`Object.prototype.hasOwnProperty`})}xe.hasPropFunc=R$;function ah(e,t,r){return(0,Ne._)`${R$(e)}.call(${t}, ${r})`}xe.isOwnProperty=ah;function tj(e,t,r,o){let n=(0,Ne._)`${t}${(0,Ne.getProperty)(r)} !== undefined`;return o?(0,Ne._)`${n} && ${ah(e,t,r)}`:n}xe.propertyInData=tj;function ch(e,t,r,o){let n=(0,Ne._)`${t}${(0,Ne.getProperty)(r)} === undefined`;return o?(0,Ne.or)(n,(0,Ne.not)(ah(e,t,r))):n}xe.noPropertyInData=ch;function C$(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}xe.allSchemaProperties=C$;function rj(e,t){return C$(t).filter(r=>!(0,sh.alwaysValidSchema)(e,t[r]))}xe.schemaProperties=rj;function nj({schemaCode:e,data:t,it:{gen:r,topSchemaRef:o,schemaPath:n,errorPath:i},it:s},a,c,u){let l=u?(0,Ne._)`${e}, ${t}, ${o}${n}`:t,d=[[Yr.default.instancePath,(0,Ne.strConcat)(Yr.default.instancePath,i)],[Yr.default.parentData,s.parentData],[Yr.default.parentDataProperty,s.parentDataProperty],[Yr.default.rootData,Yr.default.rootData]];s.opts.dynamicRef&&d.push([Yr.default.dynamicAnchors,Yr.default.dynamicAnchors]);let h=(0,Ne._)`${l}, ${r.object(...d)}`;return c!==Ne.nil?(0,Ne._)`${a}.call(${c}, ${h})`:(0,Ne._)`${a}(${h})`}xe.callValidateCode=nj;var oj=(0,Ne._)`new RegExp`;function ij({gen:e,it:{opts:t}},r){let o=t.unicodeRegExp?"u":"",{regExp:n}=t.code,i=n(r,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Ne._)`${n.code==="new RegExp"?oj:(0,YO.useFunc)(e,n)}(${r}, ${o})`})}xe.usePattern=ij;function sj(e){let{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.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",(0,Ne._)`${r}.length`);t.forRange("i",0,c,u=>{e.subschema({keyword:o,dataProp:u,dataPropType:sh.Type.Num},i),t.if((0,Ne.not)(i),a)})}}xe.validateArray=sj;function aj(e){let{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(c=>(0,sh.alwaysValidSchema)(n,c))&&!n.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:o,schemaProp:u,compositeRule:!0},a);t.assign(s,(0,Ne._)`${s} || ${a}`),e.mergeValidEvaluated(l,a)||t.if((0,Ne.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}xe.validateUnion=aj});var q$=$(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.validateKeywordUsage=cr.validSchemaType=cr.funcKeywordCode=cr.macroKeywordCode=void 0;var ft=oe(),jn=zr(),cj=Dt(),uj=Ws();function lj(e,t){let{gen:r,keyword:o,schema:n,parentSchema:i,it:s}=e,a=t.macro.call(s.self,n,i,s),c=D$(r,o,a);s.opts.validateSchema!==!1&&s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:ft.nil,errSchemaPath:`${s.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}cr.macroKeywordCode=lj;function dj(e,t){var r;let{gen:o,keyword:n,schema:i,parentSchema:s,$data:a,it:c}=e;fj(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=D$(o,n,u),d=o.let("valid");e.block$data(d,h),e.ok((r=t.valid)!==null&&r!==void 0?r:d);function h(){if(t.errors===!1)f(),t.modifying&&A$(e),v(()=>e.error());else{let y=t.async?m():p();t.modifying&&A$(e),v(()=>pj(e,y))}}function m(){let y=o.let("ruleErrs",null);return o.try(()=>f((0,ft._)`await `),w=>o.assign(d,!1).if((0,ft._)`${w} instanceof ${c.ValidationError}`,()=>o.assign(y,(0,ft._)`${w}.errors`),()=>o.throw(w))),y}function p(){let y=(0,ft._)`${l}.errors`;return o.assign(y,null),f(ft.nil),y}function f(y=t.async?(0,ft._)`await `:ft.nil){let w=c.opts.passContext?jn.default.this:jn.default.self,k=!("compile"in t&&!a||t.schema===!1);o.assign(d,(0,ft._)`${y}${(0,cj.callValidateCode)(e,l,w,k)}`,t.modifying)}function v(y){var w;o.if((0,ft.not)((w=t.valid)!==null&&w!==void 0?w:d),y)}}cr.funcKeywordCode=dj;function A$(e){let{gen:t,data:r,it:o}=e;t.if(o.parentData,()=>t.assign(r,(0,ft._)`${o.parentData}[${o.parentDataProperty}]`))}function pj(e,t){let{gen:r}=e;r.if((0,ft._)`Array.isArray(${t})`,()=>{r.assign(jn.default.vErrors,(0,ft._)`${jn.default.vErrors} === null ? ${t} : ${jn.default.vErrors}.concat(${t})`).assign(jn.default.errors,(0,ft._)`${jn.default.vErrors}.length`),(0,uj.extendErrors)(e)},()=>e.error())}function fj({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function D$(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,ft.stringify)(r)})}function mj(e,t,r=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||r&&typeof e>"u")}cr.validSchemaType=mj;function hj({schema:e,opts:t,self:r,errSchemaPath:o},n,i){if(Array.isArray(n.keyword)?!n.keyword.includes(i):n.keyword!==i)throw new Error("ajv implementation error");let s=n.dependencies;if(s?.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(n.validateSchema&&!n.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+r.errorsText(n.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw new Error(c)}}cr.validateKeywordUsage=hj});var U$=$(Xr=>{"use strict";Object.defineProperty(Xr,"__esModule",{value:!0});Xr.extendSubschemaMode=Xr.extendSubschemaData=Xr.getSubschema=void 0;var ur=oe(),M$=he();function gj(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&o!==void 0)throw new 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:(0,ur._)`${e.schemaPath}${(0,ur.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:(0,ur._)`${e.schemaPath}${(0,ur.getProperty)(t)}${(0,ur.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,M$.escapeFragment)(r)}`}}if(o!==void 0){if(n===void 0||i===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:s,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}Xr.getSubschema=gj;function vj(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:s}){if(n!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:d}=t,h=a.let("data",(0,ur._)`${t.data}${(0,ur.getProperty)(r)}`,!0);c(h),e.errorPath=(0,ur.str)`${u}${(0,M$.getErrorPath)(r,o,d.jsPropertySyntax)}`,e.parentDataProperty=(0,ur._)`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(n!==void 0){let u=n instanceof ur.Name?n:a.let("data",n,!0);c(u),s!==void 0&&(e.propertyName=s)}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]}}Xr.extendSubschemaData=vj;function _j(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:o,createErrors:n,allErrors:i}){o!==void 0&&(e.compositeRule=o),n!==void 0&&(e.createErrors=n),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}Xr.extendSubschemaMode=_j});var Hs=$((xW,Z$)=>{"use strict";Z$.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 o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))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),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var L$=$((SW,V$)=>{"use strict";var Qr=V$.exports=function(e,t,r){typeof t=="function"&&(r=t,t={}),r=t.cb||r;var o=typeof r=="function"?r:r.pre||function(){},n=r.post||function(){};Il(t,o,n,e,"",e)};Qr.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};Qr.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};Qr.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};Qr.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 Il(e,t,r,o,n,i,s,a,c,u){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,n,i,s,a,c,u);for(var l in o){var d=o[l];if(Array.isArray(d)){if(l in Qr.arrayKeywords)for(var h=0;h<d.length;h++)Il(e,t,r,d[h],n+"/"+l+"/"+h,i,n,l,o,h)}else if(l in Qr.propsKeywords){if(d&&typeof d=="object")for(var m in d)Il(e,t,r,d[m],n+"/"+l+"/"+yj(m),i,n,l,o,m)}else(l in Qr.keywords||e.allKeys&&!(l in Qr.skipKeywords))&&Il(e,t,r,d,n+"/"+l,i,n,l,o)}r(o,n,i,s,a,c,u)}}function yj(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var Js=$(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.getSchemaRefs=bt.resolveUrl=bt.normalizeId=bt._getFullPath=bt.getFullPath=bt.inlineRef=void 0;var bj=he(),$j=Hs(),wj=L$(),kj=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function xj(e,t=!0){return typeof e=="boolean"?!0:t===!0?!uh(e):t?F$(e)<=t:!1}bt.inlineRef=xj;var Sj=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function uh(e){for(let t in e){if(Sj.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(uh)||typeof r=="object"&&uh(r))return!0}return!1}function F$(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,!kj.has(r)&&(typeof e[r]=="object"&&(0,bj.eachItem)(e[r],o=>t+=F$(o)),t===1/0))return 1/0}return t}function G$(e,t="",r){r!==!1&&(t=Uo(t));let o=e.parse(t);return W$(e,o)}bt.getFullPath=G$;function W$(e,t){return e.serialize(t).split("#")[0]+"#"}bt._getFullPath=W$;var Tj=/#\/?$/;function Uo(e){return e?e.replace(Tj,""):""}bt.normalizeId=Uo;function Pj(e,t,r){return r=Uo(r),e.resolve(t,r)}bt.resolveUrl=Pj;var zj=/^[a-z_][-a-z0-9._]*$/i;function Ej(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:o}=this.opts,n=Uo(e[r]||t),i={"":n},s=G$(o,n,!1),a={},c=new Set;return wj(e,{allKeys:!0},(d,h,m,p)=>{if(p===void 0)return;let f=s+h,v=i[p];typeof d[r]=="string"&&(v=y.call(this,d[r])),w.call(this,d.$anchor),w.call(this,d.$dynamicAnchor),i[h]=v;function y(k){let E=this.opts.uriResolver.resolve;if(k=Uo(v?E(v,k):k),c.has(k))throw l(k);c.add(k);let P=this.refs[k];return typeof P=="string"&&(P=this.refs[P]),typeof P=="object"?u(d,P.schema,k):k!==Uo(f)&&(k[0]==="#"?(u(d,a[k],k),a[k]=d):this.refs[k]=f),k}function w(k){if(typeof k=="string"){if(!zj.test(k))throw new Error(`invalid anchor "${k}"`);y.call(this,`#${k}`)}}}),a;function u(d,h,m){if(h!==void 0&&!$j(d,h))throw l(m)}function l(d){return new Error(`reference "${d}" resolves to more than one schema`)}}bt.getSchemaRefs=Ej});var Xs=$(en=>{"use strict";Object.defineProperty(en,"__esModule",{value:!0});en.getData=en.KeywordCxt=en.validateFunctionCode=void 0;var Y$=T$(),K$=Ks(),dh=rh(),Ol=Ks(),Ij=N$(),Ys=q$(),lh=U$(),Z=oe(),K=zr(),Oj=Js(),Er=he(),Bs=Ws();function jj(e){if(ew(e)&&(tw(e),Q$(e))){Cj(e);return}X$(e,()=>(0,Y$.topBoolOrEmptySchema)(e))}en.validateFunctionCode=jj;function X$({gen:e,validateName:t,schema:r,schemaEnv:o,opts:n},i){n.code.es5?e.func(t,(0,Z._)`${K.default.data}, ${K.default.valCxt}`,o.$async,()=>{e.code((0,Z._)`"use strict"; ${H$(r,n)}`),Rj(e,n),e.code(i)}):e.func(t,(0,Z._)`${K.default.data}, ${Nj(n)}`,o.$async,()=>e.code(H$(r,n)).code(i))}function Nj(e){return(0,Z._)`{${K.default.instancePath}="", ${K.default.parentData}, ${K.default.parentDataProperty}, ${K.default.rootData}=${K.default.data}${e.dynamicRef?(0,Z._)`, ${K.default.dynamicAnchors}={}`:Z.nil}}={}`}function Rj(e,t){e.if(K.default.valCxt,()=>{e.var(K.default.instancePath,(0,Z._)`${K.default.valCxt}.${K.default.instancePath}`),e.var(K.default.parentData,(0,Z._)`${K.default.valCxt}.${K.default.parentData}`),e.var(K.default.parentDataProperty,(0,Z._)`${K.default.valCxt}.${K.default.parentDataProperty}`),e.var(K.default.rootData,(0,Z._)`${K.default.valCxt}.${K.default.rootData}`),t.dynamicRef&&e.var(K.default.dynamicAnchors,(0,Z._)`${K.default.valCxt}.${K.default.dynamicAnchors}`)},()=>{e.var(K.default.instancePath,(0,Z._)`""`),e.var(K.default.parentData,(0,Z._)`undefined`),e.var(K.default.parentDataProperty,(0,Z._)`undefined`),e.var(K.default.rootData,K.default.data),t.dynamicRef&&e.var(K.default.dynamicAnchors,(0,Z._)`{}`)})}function Cj(e){let{schema:t,opts:r,gen:o}=e;X$(e,()=>{r.$comment&&t.$comment&&nw(e),Uj(e),o.let(K.default.vErrors,null),o.let(K.default.errors,0),r.unevaluated&&Aj(e),rw(e),Lj(e)})}function Aj(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,Z._)`${r}.evaluated`),t.if((0,Z._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,Z._)`${e.evaluated}.props`,(0,Z._)`undefined`)),t.if((0,Z._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,Z._)`${e.evaluated}.items`,(0,Z._)`undefined`))}function H$(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,Z._)`/*# sourceURL=${r} */`:Z.nil}function Dj(e,t){if(ew(e)&&(tw(e),Q$(e))){qj(e,t);return}(0,Y$.boolOrEmptySchema)(e,t)}function Q$({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 ew(e){return typeof e.schema!="boolean"}function qj(e,t){let{schema:r,gen:o,opts:n}=e;n.$comment&&r.$comment&&nw(e),Zj(e),Vj(e);let i=o.const("_errs",K.default.errors);rw(e,i),o.var(t,(0,Z._)`${i} === ${K.default.errors}`)}function tw(e){(0,Er.checkUnknownRules)(e),Mj(e)}function rw(e,t){if(e.opts.jtd)return J$(e,[],!1,t);let r=(0,K$.getSchemaTypes)(e.schema),o=(0,K$.coerceAndCheckDataType)(e,r);J$(e,r,!o,t)}function Mj(e){let{schema:t,errSchemaPath:r,opts:o,self:n}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,Er.schemaHasRulesButRef)(t,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function Uj(e){let{schema:t,opts:r}=e;t.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Er.checkStrictMode)(e,"default is ignored in the schema root")}function Zj(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,Oj.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function Vj(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function nw({gen:e,schemaEnv:t,schema:r,errSchemaPath:o,opts:n}){let i=r.$comment;if(n.$comment===!0)e.code((0,Z._)`${K.default.self}.logger.log(${i})`);else if(typeof n.$comment=="function"){let s=(0,Z.str)`${o}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,Z._)`${K.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function Lj(e){let{gen:t,schemaEnv:r,validateName:o,ValidationError:n,opts:i}=e;r.$async?t.if((0,Z._)`${K.default.errors} === 0`,()=>t.return(K.default.data),()=>t.throw((0,Z._)`new ${n}(${K.default.vErrors})`)):(t.assign((0,Z._)`${o}.errors`,K.default.vErrors),i.unevaluated&&Fj(e),t.return((0,Z._)`${K.default.errors} === 0`))}function Fj({gen:e,evaluated:t,props:r,items:o}){r instanceof Z.Name&&e.assign((0,Z._)`${t}.props`,r),o instanceof Z.Name&&e.assign((0,Z._)`${t}.items`,o)}function J$(e,t,r,o){let{gen:n,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,Er.schemaHasRulesButRef)(i,l))){n.block(()=>iw(e,"$ref",l.all.$ref.definition));return}c.jtd||Gj(e,t),n.block(()=>{for(let h of l.rules)d(h);d(l.post)});function d(h){(0,dh.shouldUseGroup)(i,h)&&(h.type?(n.if((0,Ol.checkDataType)(h.type,s,c.strictNumbers)),B$(e,h),t.length===1&&t[0]===h.type&&r&&(n.else(),(0,Ol.reportTypeError)(e)),n.endIf()):B$(e,h),a||n.if((0,Z._)`${K.default.errors} === ${o||0}`))}}function B$(e,t){let{gen:r,schema:o,opts:{useDefaults:n}}=e;n&&(0,Ij.assignDefaults)(e,t.type),r.block(()=>{for(let i of t.rules)(0,dh.shouldUseRule)(o,i)&&iw(e,i.keyword,i.definition,t.type)})}function Gj(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(Wj(e,t),e.opts.allowUnionTypes||Kj(e,t),Hj(e,e.dataTypes))}function Wj(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{ow(e.dataTypes,r)||ph(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),Bj(e,t)}}function Kj(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&ph(e,"use allowUnionTypes to allow union type keyword")}function Hj(e,t){let r=e.self.RULES.all;for(let o in r){let n=r[o];if(typeof n=="object"&&(0,dh.shouldUseRule)(e.schema,n)){let{type:i}=n.definition;i.length&&!i.some(s=>Jj(t,s))&&ph(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function Jj(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function ow(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function Bj(e,t){let r=[];for(let o of e.dataTypes)ow(t,o)?r.push(o):t.includes("integer")&&o==="number"&&r.push("integer");e.dataTypes=r}function ph(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,Er.checkStrictMode)(e,t,e.opts.strictTypes)}var jl=class{constructor(t,r,o){if((0,Ys.validateKeywordUsage)(t,r,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Er.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=r.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=r,this.$data)this.schemaCode=t.gen.const("vSchema",sw(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Ys.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=t.gen.const("_errs",K.default.errors))}result(t,r,o){this.failResult((0,Z.not)(t),r,o)}failResult(t,r,o){this.gen.if(t),o?o():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,r){this.failResult((0,Z.not)(t),void 0,r)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:r}=this;this.fail((0,Z._)`${r} !== undefined && (${(0,Z.or)(this.invalid$data(),t)})`)}error(t,r,o){if(r){this.setParams(r),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,r){(t?Bs.reportExtraError:Bs.reportError)(this,this.def.error,r)}$dataError(){(0,Bs.reportError)(this,this.def.$dataError||Bs.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Bs.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,r){r?Object.assign(this.params,t):this.params=t}block$data(t,r,o=Z.nil){this.gen.block(()=>{this.check$data(t,o),r()})}check$data(t=Z.nil,r=Z.nil){if(!this.$data)return;let{gen:o,schemaCode:n,schemaType:i,def:s}=this;o.if((0,Z.or)((0,Z._)`${n} === undefined`,r)),t!==Z.nil&&o.assign(t,!0),(i.length||s.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==Z.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:r,schemaType:o,def:n,it:i}=this;return(0,Z.or)(s(),a());function s(){if(o.length){if(!(r instanceof Z.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,Z._)`${(0,Ol.checkDataTypes)(c,r,i.opts.strictNumbers,Ol.DataType.Wrong)}`}return Z.nil}function a(){if(n.validateSchema){let c=t.scopeValue("validate$data",{ref:n.validateSchema});return(0,Z._)`!${c}(${r})`}return Z.nil}}subschema(t,r){let o=(0,lh.getSubschema)(this.it,t);(0,lh.extendSubschemaData)(o,this.it,t),(0,lh.extendSubschemaMode)(o,t);let n={...this.it,...o,items:void 0,props:void 0};return Dj(n,r),n}mergeEvaluated(t,r){let{it:o,gen:n}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=Er.mergeEvaluated.props(n,t.props,o.props,r)),o.items!==!0&&t.items!==void 0&&(o.items=Er.mergeEvaluated.items(n,t.items,o.items,r)))}mergeValidEvaluated(t,r){let{it:o,gen:n}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return n.if(r,()=>this.mergeEvaluated(t,Z.Name)),!0}};en.KeywordCxt=jl;function iw(e,t,r,o){let n=new jl(e,r,t);"code"in r?r.code(n,o):n.$data&&r.validate?(0,Ys.funcKeywordCode)(n,r):"macro"in r?(0,Ys.macroKeywordCode)(n,r):(r.compile||r.validate)&&(0,Ys.funcKeywordCode)(n,r)}var Yj=/^\/(?:[^~]|~0|~1)*$/,Xj=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function sw(e,{dataLevel:t,dataNames:r,dataPathArr:o}){let n,i;if(e==="")return K.default.rootData;if(e[0]==="/"){if(!Yj.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,i=K.default.rootData}else{let u=Xj.exec(e);if(!u)throw new Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(n=u[2],n==="#"){if(l>=t)throw new Error(c("property/index",l));return o[t-l]}if(l>t)throw new Error(c("data",l));if(i=r[t-l],!n)return i}let s=i,a=n.split("/");for(let u of a)u&&(i=(0,Z._)`${i}${(0,Z.getProperty)((0,Er.unescapeJsonPointer)(u))}`,s=(0,Z._)`${s} && ${i}`);return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}en.getData=sw});var Nl=$(mh=>{"use strict";Object.defineProperty(mh,"__esModule",{value:!0});var fh=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};mh.default=fh});var Qs=$(vh=>{"use strict";Object.defineProperty(vh,"__esModule",{value:!0});var hh=Js(),gh=class extends Error{constructor(t,r,o,n){super(n||`can't resolve reference ${o} from id ${r}`),this.missingRef=(0,hh.resolveUrl)(t,r,o),this.missingSchema=(0,hh.normalizeId)((0,hh.getFullPath)(t,this.missingRef))}};vh.default=gh});var Cl=$(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.resolveSchema=qt.getCompilingSchema=qt.resolveRef=qt.compileSchema=qt.SchemaEnv=void 0;var Yt=oe(),Qj=Nl(),Nn=zr(),Xt=Js(),aw=he(),eN=Xs(),Zo=class{constructor(t){var r;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,Xt.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};qt.SchemaEnv=Zo;function yh(e){let t=cw.call(this,e);if(t)return t;let r=(0,Xt.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:n}=this.opts.code,{ownProperties:i}=this.opts,s=new Yt.CodeGen(this.scope,{es5:o,lines:n,ownProperties:i}),a;e.$async&&(a=s.scopeValue("Error",{ref:Qj.default,code:(0,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:Nn.default.data,parentData:Nn.default.parentData,parentDataProperty:Nn.default.parentDataProperty,dataNames:[Nn.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:(0,Yt._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),(0,eN.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let d=s.toString();l=`${s.scopeRefs(Nn.default.scope)}return ${d}`,this.opts.code.process&&(l=this.opts.code.process(l,e));let m=new Function(`${Nn.default.self}`,`${Nn.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:m}),m.errors=null,m.schema=e.schema,m.schemaEnv=e,e.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:c,validateCode:d,scopeValues:s._values}),this.opts.unevaluated){let{props:p,items:f}=u;m.evaluated={props:p instanceof Yt.Name?void 0:p,items:f instanceof Yt.Name?void 0:f,dynamicProps:p instanceof Yt.Name,dynamicItems:f instanceof Yt.Name},m.source&&(m.source.evaluated=(0,Yt.stringify)(m.evaluated))}return e.validate=m,e}catch(d){throw delete e.validate,delete e.validateName,l&&this.logger.error("Error compiling schema, function code:",l),d}finally{this._compilations.delete(e)}}qt.compileSchema=yh;function tN(e,t,r){var o;r=(0,Xt.resolveUrl)(this.opts.uriResolver,t,r);let n=e.refs[r];if(n)return n;let i=oN.call(this,e,r);if(i===void 0){let s=(o=e.localRefs)===null||o===void 0?void 0:o[r],{schemaId:a}=this.opts;s&&(i=new Zo({schema:s,schemaId:a,root:e,baseId:t}))}if(i!==void 0)return e.refs[r]=rN.call(this,i)}qt.resolveRef=tN;function rN(e){return(0,Xt.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:yh.call(this,e)}function cw(e){for(let t of this._compilations)if(nN(t,e))return t}qt.getCompilingSchema=cw;function nN(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function oN(e,t){let r;for(;typeof(r=this.refs[t])=="string";)t=r;return r||this.schemas[t]||Rl.call(this,e,t)}function Rl(e,t){let r=this.opts.uriResolver.parse(t),o=(0,Xt._getFullPath)(this.opts.uriResolver,r),n=(0,Xt.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===n)return _h.call(this,r,e);let i=(0,Xt.normalizeId)(o),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=Rl.call(this,e,s);return typeof a?.schema!="object"?void 0:_h.call(this,r,a)}if(typeof s?.schema=="object"){if(s.validate||yh.call(this,s),i===(0,Xt.normalizeId)(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];return u&&(n=(0,Xt.resolveUrl)(this.opts.uriResolver,n,u)),new Zo({schema:a,schemaId:c,root:e,baseId:n})}return _h.call(this,r,s)}}qt.resolveSchema=Rl;var iN=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function _h(e,{baseId:t,schema:r,root:o}){var n;if(((n=e.fragment)===null||n===void 0?void 0:n[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let c=r[(0,aw.unescapeFragment)(a)];if(c===void 0)return;r=c;let u=typeof r=="object"&&r[this.opts.schemaId];!iN.has(a)&&u&&(t=(0,Xt.resolveUrl)(this.opts.uriResolver,t,u))}let i;if(typeof r!="boolean"&&r.$ref&&!(0,aw.schemaHasRulesButRef)(r,this.RULES)){let a=(0,Xt.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=Rl.call(this,o,a)}let{schemaId:s}=this.opts;if(i=i||new Zo({schema:r,schemaId:s,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var uw=$((OW,sN)=>{sN.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 $h=$((jW,fw)=>{"use strict";var aN=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),dw=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);function bh(e){let t="",r=0,o=0;for(o=0;o<e.length;o++)if(r=e[o].charCodeAt(0),r!==48){if(!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[o];break}for(o+=1;o<e.length;o++){if(r=e[o].charCodeAt(0),!(r>=48&&r<=57||r>=65&&r<=70||r>=97&&r<=102))return"";t+=e[o]}return t}var cN=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function lw(e){return e.length=0,!0}function uN(e,t,r){if(e.length){let o=bh(e);if(o!=="")t.push(o);else return r.error=!0,!1;e.length=0}return!0}function lN(e){let t=0,r={error:!1,address:"",zone:""},o=[],n=[],i=!1,s=!1,a=uN;for(let c=0;c<e.length;c++){let u=e[c];if(!(u==="["||u==="]"))if(u===":"){if(i===!0&&(s=!0),!a(n,o,r))break;if(++t>7){r.error=!0;break}c>0&&e[c-1]===":"&&(i=!0),o.push(":");continue}else if(u==="%"){if(!a(n,o,r))break;a=lw}else{n.push(u);continue}}return n.length&&(a===lw?r.zone=n.join(""):s?o.push(n.join("")):o.push(bh(n))),r.address=o.join(""),r}function pw(e){if(dN(e,":")<2)return{host:e,isIPV6:!1};let t=lN(e);if(t.error)return{host:e,isIPV6:!1};{let r=t.address,o=t.address;return t.zone&&(r+="%"+t.zone,o+="%25"+t.zone),{host:r,isIPV6:!0,escapedHost:o}}}function dN(e,t){let r=0;for(let o=0;o<e.length;o++)e[o]===t&&r++;return r}function pN(e){let t=e,r=[],o=-1,n=0;for(;n=t.length;){if(n===1){if(t===".")break;if(t==="/"){r.push("/");break}else{r.push(t);break}}else if(n===2){if(t[0]==="."){if(t[1]===".")break;if(t[1]==="/"){t=t.slice(2);continue}}else if(t[0]==="/"&&(t[1]==="."||t[1]==="/")){r.push("/");break}}else if(n===3&&t==="/.."){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]==="/"&&t[1]==="."){if(t[2]==="/"){t=t.slice(2);continue}else if(t[2]==="."&&t[3]==="/"){t=t.slice(3),r.length!==0&&r.pop();continue}}if((o=t.indexOf("/",1))===-1){r.push(t);break}else r.push(t.slice(0,o)),t=t.slice(o)}return r.join("")}function fN(e,t){let r=t!==!0?escape:unescape;return e.scheme!==void 0&&(e.scheme=r(e.scheme)),e.userinfo!==void 0&&(e.userinfo=r(e.userinfo)),e.host!==void 0&&(e.host=r(e.host)),e.path!==void 0&&(e.path=r(e.path)),e.query!==void 0&&(e.query=r(e.query)),e.fragment!==void 0&&(e.fragment=r(e.fragment)),e}function mN(e){let t=[];if(e.userinfo!==void 0&&(t.push(e.userinfo),t.push("@")),e.host!==void 0){let r=unescape(e.host);if(!dw(r)){let o=pw(r);o.isIPV6===!0?r=`[${o.escapedHost}]`:r=e.host}t.push(r)}return(typeof e.port=="number"||typeof e.port=="string")&&(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0}fw.exports={nonSimpleDomain:cN,recomposeAuthority:mN,normalizeComponentEncoding:fN,removeDotSegments:pN,isIPv4:dw,isUUID:aN,normalizeIPv6:pw,stringArrayToHexStripped:bh}});var _w=$((NW,vw)=>{"use strict";var{isUUID:hN}=$h(),gN=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,vN=["http","https","ws","wss","urn","urn:uuid"];function _N(e){return vN.indexOf(e)!==-1}function wh(e){return e.secure===!0?!0:e.secure===!1?!1:e.scheme?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"):!1}function mw(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function hw(e){let t=String(e.scheme).toLowerCase()==="https";return(e.port===(t?443:80)||e.port==="")&&(e.port=void 0),e.path||(e.path="/"),e}function yN(e){return e.secure=wh(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e}function bN(e){if((e.port===(wh(e)?443:80)||e.port==="")&&(e.port=void 0),typeof e.secure=="boolean"&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),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 $N(e,t){if(!e.path)return e.error="URN can not be parsed",e;let r=e.path.match(gN);if(r){let o=t.scheme||e.scheme||"urn";e.nid=r[1].toLowerCase(),e.nss=r[2];let n=`${o}:${t.nid||e.nid}`,i=kh(n);e.path=void 0,i&&(e=i.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e}function wN(e,t){if(e.nid===void 0)throw new Error("URN without nid cannot be serialized");let r=t.scheme||e.scheme||"urn",o=e.nid.toLowerCase(),n=`${r}:${t.nid||o}`,i=kh(n);i&&(e=i.serialize(e,t));let s=e,a=e.nss;return s.path=`${o||t.nid}:${a}`,t.skipEscape=!0,s}function kN(e,t){let r=e;return r.uuid=r.nss,r.nss=void 0,!t.tolerant&&(!r.uuid||!hN(r.uuid))&&(r.error=r.error||"UUID is not valid."),r}function xN(e){let t=e;return t.nss=(e.uuid||"").toLowerCase(),t}var gw={scheme:"http",domainHost:!0,parse:mw,serialize:hw},SN={scheme:"https",domainHost:gw.domainHost,parse:mw,serialize:hw},Al={scheme:"ws",domainHost:!0,parse:yN,serialize:bN},TN={scheme:"wss",domainHost:Al.domainHost,parse:Al.parse,serialize:Al.serialize},PN={scheme:"urn",parse:$N,serialize:wN,skipNormalize:!0},zN={scheme:"urn:uuid",parse:kN,serialize:xN,skipNormalize:!0},Dl={http:gw,https:SN,ws:Al,wss:TN,urn:PN,"urn:uuid":zN};Object.setPrototypeOf(Dl,null);function kh(e){return e&&(Dl[e]||Dl[e.toLowerCase()])||void 0}vw.exports={wsIsSecure:wh,SCHEMES:Dl,isValidSchemeName:_N,getSchemeHandler:kh}});var Sh=$((RW,Ml)=>{"use strict";var{normalizeIPv6:EN,removeDotSegments:ea,recomposeAuthority:IN,normalizeComponentEncoding:ql,isIPv4:ON,nonSimpleDomain:jN}=$h(),{SCHEMES:NN,getSchemeHandler:yw}=_w();function RN(e,t){return typeof e=="string"?e=lr(Ir(e,t),t):typeof e=="object"&&(e=Ir(lr(e,t),t)),e}function CN(e,t,r){let o=r?Object.assign({scheme:"null"},r):{scheme:"null"},n=bw(Ir(e,o),Ir(t,o),o,!0);return o.skipEscape=!0,lr(n,o)}function bw(e,t,r,o){let n={};return o||(e=Ir(lr(e,r),r),t=Ir(lr(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(n.scheme=t.scheme,n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=ea(t.path||""),n.query=t.query):(t.userinfo!==void 0||t.host!==void 0||t.port!==void 0?(n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=ea(t.path||""),n.query=t.query):(t.path?(t.path[0]==="/"?n.path=ea(t.path):((e.userinfo!==void 0||e.host!==void 0||e.port!==void 0)&&!e.path?n.path="/"+t.path:e.path?n.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:n.path=t.path,n.path=ea(n.path)),n.query=t.query):(n.path=e.path,t.query!==void 0?n.query=t.query:n.query=e.query),n.userinfo=e.userinfo,n.host=e.host,n.port=e.port),n.scheme=e.scheme),n.fragment=t.fragment,n}function AN(e,t,r){return typeof e=="string"?(e=unescape(e),e=lr(ql(Ir(e,r),!0),{...r,skipEscape:!0})):typeof e=="object"&&(e=lr(ql(e,!0),{...r,skipEscape:!0})),typeof t=="string"?(t=unescape(t),t=lr(ql(Ir(t,r),!0),{...r,skipEscape:!0})):typeof t=="object"&&(t=lr(ql(t,!0),{...r,skipEscape:!0})),e.toLowerCase()===t.toLowerCase()}function lr(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:""},o=Object.assign({},t),n=[],i=yw(o.scheme||r.scheme);i&&i.serialize&&i.serialize(r,o),r.path!==void 0&&(o.skipEscape?r.path=unescape(r.path):(r.path=escape(r.path),r.scheme!==void 0&&(r.path=r.path.split("%3A").join(":")))),o.reference!=="suffix"&&r.scheme&&n.push(r.scheme,":");let s=IN(r);if(s!==void 0&&(o.reference!=="suffix"&&n.push("//"),n.push(s),r.path&&r.path[0]!=="/"&&n.push("/")),r.path!==void 0){let a=r.path;!o.absolutePath&&(!i||!i.absolutePath)&&(a=ea(a)),s===void 0&&a[0]==="/"&&a[1]==="/"&&(a="/%2F"+a.slice(2)),n.push(a)}return r.query!==void 0&&n.push("?",r.query),r.fragment!==void 0&&n.push("#",r.fragment),n.join("")}var DN=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function Ir(e,t){let r=Object.assign({},t),o={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},n=!1;r.reference==="suffix"&&(r.scheme?e=r.scheme+":"+e:e="//"+e);let i=e.match(DN);if(i){if(o.scheme=i[1],o.userinfo=i[3],o.host=i[4],o.port=parseInt(i[5],10),o.path=i[6]||"",o.query=i[7],o.fragment=i[8],isNaN(o.port)&&(o.port=i[5]),o.host)if(ON(o.host)===!1){let c=EN(o.host);o.host=c.host.toLowerCase(),n=c.isIPV6}else n=!0;o.scheme===void 0&&o.userinfo===void 0&&o.host===void 0&&o.port===void 0&&o.query===void 0&&!o.path?o.reference="same-document":o.scheme===void 0?o.reference="relative":o.fragment===void 0?o.reference="absolute":o.reference="uri",r.reference&&r.reference!=="suffix"&&r.reference!==o.reference&&(o.error=o.error||"URI is not a "+r.reference+" reference.");let s=yw(r.scheme||o.scheme);if(!r.unicodeSupport&&(!s||!s.unicodeSupport)&&o.host&&(r.domainHost||s&&s.domainHost)&&n===!1&&jN(o.host))try{o.host=URL.domainToASCII(o.host.toLowerCase())}catch(a){o.error=o.error||"Host's domain name can not be converted to ASCII: "+a}(!s||s&&!s.skipNormalize)&&(e.indexOf("%")!==-1&&(o.scheme!==void 0&&(o.scheme=unescape(o.scheme)),o.host!==void 0&&(o.host=unescape(o.host))),o.path&&(o.path=escape(unescape(o.path))),o.fragment&&(o.fragment=encodeURI(decodeURIComponent(o.fragment)))),s&&s.parse&&s.parse(o,r)}else o.error=o.error||"URI can not be parsed.";return o}var xh={SCHEMES:NN,normalize:RN,resolve:CN,resolveComponent:bw,equal:AN,serialize:lr,parse:Ir};Ml.exports=xh;Ml.exports.default=xh;Ml.exports.fastUri=xh});var ww=$(Th=>{"use strict";Object.defineProperty(Th,"__esModule",{value:!0});var $w=Sh();$w.code='require("ajv/dist/runtime/uri").default';Th.default=$w});var Iw=$(Je=>{"use strict";Object.defineProperty(Je,"__esModule",{value:!0});Je.CodeGen=Je.Name=Je.nil=Je.stringify=Je.str=Je._=Je.KeywordCxt=void 0;var qN=Xs();Object.defineProperty(Je,"KeywordCxt",{enumerable:!0,get:function(){return qN.KeywordCxt}});var Vo=oe();Object.defineProperty(Je,"_",{enumerable:!0,get:function(){return Vo._}});Object.defineProperty(Je,"str",{enumerable:!0,get:function(){return Vo.str}});Object.defineProperty(Je,"stringify",{enumerable:!0,get:function(){return Vo.stringify}});Object.defineProperty(Je,"nil",{enumerable:!0,get:function(){return Vo.nil}});Object.defineProperty(Je,"Name",{enumerable:!0,get:function(){return Vo.Name}});Object.defineProperty(Je,"CodeGen",{enumerable:!0,get:function(){return Vo.CodeGen}});var MN=Nl(),Pw=Qs(),UN=th(),ta=Cl(),ZN=oe(),ra=Js(),Ul=Ks(),zh=he(),kw=uw(),VN=ww(),zw=(e,t)=>new RegExp(e,t);zw.code="new RegExp";var LN=["removeAdditional","useDefaults","coerceTypes"],FN=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),GN={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."},WN={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},xw=200;function KN(e){var t,r,o,n,i,s,a,c,u,l,d,h,m,p,f,v,y,w,k,E,P,ze,Me,ir,pn;let Ft=e.strict,fn=(t=e.code)===null||t===void 0?void 0:t.optimize,li=fn===!0||fn===void 0?1:fn||0,di=(o=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&o!==void 0?o:zw,Vd=(n=e.uriResolver)!==null&&n!==void 0?n:VN.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:Ft)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:Ft)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:Ft)!==null&&l!==void 0?l:"log",strictTuples:(h=(d=e.strictTuples)!==null&&d!==void 0?d:Ft)!==null&&h!==void 0?h:"log",strictRequired:(p=(m=e.strictRequired)!==null&&m!==void 0?m:Ft)!==null&&p!==void 0?p:!1,code:e.code?{...e.code,optimize:li,regExp:di}:{optimize:li,regExp:di},loopRequired:(f=e.loopRequired)!==null&&f!==void 0?f:xw,loopEnum:(v=e.loopEnum)!==null&&v!==void 0?v:xw,meta:(y=e.meta)!==null&&y!==void 0?y:!0,messages:(w=e.messages)!==null&&w!==void 0?w:!0,inlineRefs:(k=e.inlineRefs)!==null&&k!==void 0?k:!0,schemaId:(E=e.schemaId)!==null&&E!==void 0?E:"$id",addUsedSchema:(P=e.addUsedSchema)!==null&&P!==void 0?P:!0,validateSchema:(ze=e.validateSchema)!==null&&ze!==void 0?ze:!0,validateFormats:(Me=e.validateFormats)!==null&&Me!==void 0?Me:!0,unicodeRegExp:(ir=e.unicodeRegExp)!==null&&ir!==void 0?ir:!0,int32range:(pn=e.int32range)!==null&&pn!==void 0?pn:!0,uriResolver:Vd}}var na=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...KN(t)};let{es5:r,lines:o}=this.opts.code;this.scope=new ZN.ValueScope({scope:{},prefixes:FN,es5:r,lines:o}),this.logger=QN(t.logger);let n=t.validateFormats;t.validateFormats=!1,this.RULES=(0,UN.getRules)(),Sw.call(this,GN,t,"NOT SUPPORTED"),Sw.call(this,WN,t,"DEPRECATED","warn"),this._metaOpts=YN.call(this),t.formats&&JN.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&BN.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),HN.call(this),t.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:r,schemaId:o}=this.opts,n=kw;o==="id"&&(n={...kw},n.id=n.$id,delete n.$id),r&&t&&this.addMetaSchema(n,n[o],!1)}defaultMeta(){let{meta:t,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[r]||t:void 0}validate(t,r){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let n=o(r);return"$async"in o||(this.errors=o.errors),n}compile(t,r){let o=this._addSchema(t,r);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return n.call(this,t,r);async function n(l,d){await i.call(this,l.$schema);let h=this._addSchema(l,d);return h.validate||s.call(this,h)}async function i(l){l&&!this.getSchema(l)&&await n.call(this,{$ref:l},!0)}async function s(l){try{return this._compileSchemaEnv(l)}catch(d){if(!(d instanceof Pw.default))throw d;return a.call(this,d),await c.call(this,d.missingSchema),s.call(this,l)}}function a({missingSchema:l,missingRef:d}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${d} cannot be resolved`)}async function c(l){let d=await u.call(this,l);this.refs[l]||await i.call(this,d.$schema),this.refs[l]||this.addSchema(d,l,r)}async function u(l){let d=this._loading[l];if(d)return d;try{return await(this._loading[l]=o(l))}finally{delete this._loading[l]}}}addSchema(t,r,o,n=this.opts.validateSchema){if(Array.isArray(t)){for(let s of t)this.addSchema(s,void 0,o,n);return this}let i;if(typeof t=="object"){let{schemaId:s}=this.opts;if(i=t[s],i!==void 0&&typeof i!="string")throw new Error(`schema ${s} must be string`)}return r=(0,ra.normalizeId)(r||i),this._checkUnique(r),this.schemas[r]=this._addSchema(t,o,r,n,!0),this}addMetaSchema(t,r,o=this.opts.validateSchema){return this.addSchema(t,r,!0,o),this}validateSchema(t,r){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(o,t);if(!n&&r){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return n}getSchema(t){let r;for(;typeof(r=Tw.call(this,t))=="string";)t=r;if(r===void 0){let{schemaId:o}=this.opts,n=new ta.SchemaEnv({schema:{},schemaId:o});if(r=ta.resolveSchema.call(this,n,t),!r)return;this.refs[t]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=Tw.call(this,t);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let r=t;this._cache.delete(r);let o=t[this.opts.schemaId];return o&&(o=(0,ra.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let r of t)this.addKeyword(r);return this}addKeyword(t,r){let o;if(typeof t=="string")o=t,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=o);else if(typeof t=="object"&&r===void 0){if(r=t,o=r.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(tR.call(this,o,r),!r)return(0,zh.eachItem)(o,i=>Ph.call(this,i)),this;nR.call(this,r);let n={...r,type:(0,Ul.getJSONTypes)(r.type),schemaType:(0,Ul.getJSONTypes)(r.schemaType)};return(0,zh.eachItem)(o,n.type.length===0?i=>Ph.call(this,i,n):i=>n.type.forEach(s=>Ph.call(this,i,n,s))),this}getKeyword(t){let r=this.RULES.all[t];return typeof r=="object"?r.definition:!!r}removeKeyword(t){let{RULES:r}=this;delete r.keywords[t],delete r.all[t];for(let o of r.rules){let n=o.rules.findIndex(i=>i.keyword===t);n>=0&&o.rules.splice(n,1)}return this}addFormat(t,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[t]=r,this}errorsText(t=this.errors,{separator:r=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(n=>`${o}${n.instancePath} ${n.message}`).reduce((n,i)=>n+r+i)}$dataMetaSchema(t,r){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let n of r){let i=n.split("/").slice(1),s=t;for(let a of i)s=s[a];for(let a in o){let c=o[a];if(typeof c!="object")continue;let{$data:u}=c.definition,l=s[a];u&&l&&(s[a]=Ew(l))}}return t}_removeAllSchemas(t,r){for(let o in t){let n=t[o];(!r||r.test(o))&&(typeof n=="string"?delete t[o]:n&&!n.meta&&(this._cache.delete(n.schema),delete t[o]))}}_addSchema(t,r,o,n=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:a}=this.opts;if(typeof t=="object")s=t[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,ra.normalizeId)(s||o);let u=ra.getSchemaRefs.call(this,t,o);return c=new ta.SchemaEnv({schema:t,schemaId:a,meta:r,baseId:o,localRefs:u}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),n&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):ta.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let r=this.opts;this.opts=this._metaOpts;try{ta.compileSchema.call(this,t)}finally{this.opts=r}}};na.ValidationError=MN.default;na.MissingRefError=Pw.default;Je.default=na;function Sw(e,t,r,o="error"){for(let n in e){let i=n;i in t&&this.logger[o](`${r}: option ${n}. ${e[i]}`)}}function Tw(e){return e=(0,ra.normalizeId)(e),this.schemas[e]||this.refs[e]}function HN(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function JN(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function BN(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];r.keyword||(r.keyword=t),this.addKeyword(r)}}function YN(){let e={...this.opts};for(let t of LN)delete e[t];return e}var XN={log(){},warn(){},error(){}};function QN(e){if(e===!1)return XN;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var eR=/^[a-z_$][a-z0-9_$:-]*$/i;function tR(e,t){let{RULES:r}=this;if((0,zh.eachItem)(e,o=>{if(r.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!eR.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function Ph(e,t,r){var o;let n=t?.post;if(r&&n)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=n?i.post:i.rules.find(({type:c})=>c===r);if(s||(s={type:r,rules:[]},i.rules.push(s)),i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:(0,Ul.getJSONTypes)(t.type),schemaType:(0,Ul.getJSONTypes)(t.schemaType)}};t.before?rR.call(this,s,a,t.before):s.rules.push(a),i.all[e]=a,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function rR(e,t,r){let o=e.rules.findIndex(n=>n.keyword===r);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function nR(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=Ew(t)),e.validateSchema=this.compile(t,!0))}var oR={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Ew(e){return{anyOf:[e,oR]}}});var Ow=$(Eh=>{"use strict";Object.defineProperty(Eh,"__esModule",{value:!0});var iR={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};Eh.default=iR});var Cw=$(Rn=>{"use strict";Object.defineProperty(Rn,"__esModule",{value:!0});Rn.callRef=Rn.getValidate=void 0;var sR=Qs(),jw=Dt(),$t=oe(),Lo=zr(),Nw=Cl(),Zl=he(),aR={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:o}=e,{baseId:n,schemaEnv:i,validateName:s,opts:a,self:c}=o,{root:u}=i;if((r==="#"||r==="#/")&&n===u.baseId)return d();let l=Nw.resolveRef.call(c,u,n,r);if(l===void 0)throw new sR.default(o.opts.uriResolver,n,r);if(l instanceof Nw.SchemaEnv)return h(l);return m(l);function d(){if(i===u)return Vl(e,s,i,i.$async);let p=t.scopeValue("root",{ref:u});return Vl(e,(0,$t._)`${p}.validate`,u,u.$async)}function h(p){let f=Rw(e,p);Vl(e,f,p,p.$async)}function m(p){let f=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,$t.stringify)(p)}:{ref:p}),v=t.name("valid"),y=e.subschema({schema:p,dataTypes:[],schemaPath:$t.nil,topSchemaRef:f,errSchemaPath:r},v);e.mergeEvaluated(y),e.ok(v)}}};function Rw(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,$t._)`${r.scopeValue("wrapper",{ref:t})}.validate`}Rn.getValidate=Rw;function Vl(e,t,r,o){let{gen:n,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?Lo.default.this:$t.nil;o?l():d();function l(){if(!a.$async)throw new Error("async schema referenced by sync schema");let p=n.let("valid");n.try(()=>{n.code((0,$t._)`await ${(0,jw.callValidateCode)(e,t,u)}`),m(t),s||n.assign(p,!0)},f=>{n.if((0,$t._)`!(${f} instanceof ${i.ValidationError})`,()=>n.throw(f)),h(f),s||n.assign(p,!1)}),e.ok(p)}function d(){e.result((0,jw.callValidateCode)(e,t,u),()=>m(t),()=>h(t))}function h(p){let f=(0,$t._)`${p}.errors`;n.assign(Lo.default.vErrors,(0,$t._)`${Lo.default.vErrors} === null ? ${f} : ${Lo.default.vErrors}.concat(${f})`),n.assign(Lo.default.errors,(0,$t._)`${Lo.default.vErrors}.length`)}function m(p){var f;if(!i.opts.unevaluated)return;let v=(f=r?.validate)===null||f===void 0?void 0:f.evaluated;if(i.props!==!0)if(v&&!v.dynamicProps)v.props!==void 0&&(i.props=Zl.mergeEvaluated.props(n,v.props,i.props));else{let y=n.var("props",(0,$t._)`${p}.evaluated.props`);i.props=Zl.mergeEvaluated.props(n,y,i.props,$t.Name)}if(i.items!==!0)if(v&&!v.dynamicItems)v.items!==void 0&&(i.items=Zl.mergeEvaluated.items(n,v.items,i.items));else{let y=n.var("items",(0,$t._)`${p}.evaluated.items`);i.items=Zl.mergeEvaluated.items(n,y,i.items,$t.Name)}}}Rn.callRef=Vl;Rn.default=aR});var Aw=$(Ih=>{"use strict";Object.defineProperty(Ih,"__esModule",{value:!0});var cR=Ow(),uR=Cw(),lR=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",cR.default,uR.default];Ih.default=lR});var Dw=$(Oh=>{"use strict";Object.defineProperty(Oh,"__esModule",{value:!0});var Ll=oe(),tn=Ll.operators,Fl={maximum:{okStr:"<=",ok:tn.LTE,fail:tn.GT},minimum:{okStr:">=",ok:tn.GTE,fail:tn.LT},exclusiveMaximum:{okStr:"<",ok:tn.LT,fail:tn.GTE},exclusiveMinimum:{okStr:">",ok:tn.GT,fail:tn.LTE}},dR={message:({keyword:e,schemaCode:t})=>(0,Ll.str)`must be ${Fl[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,Ll._)`{comparison: ${Fl[e].okStr}, limit: ${t}}`},pR={keyword:Object.keys(Fl),type:"number",schemaType:"number",$data:!0,error:dR,code(e){let{keyword:t,data:r,schemaCode:o}=e;e.fail$data((0,Ll._)`${r} ${Fl[t].fail} ${o} || isNaN(${r})`)}};Oh.default=pR});var qw=$(jh=>{"use strict";Object.defineProperty(jh,"__esModule",{value:!0});var oa=oe(),fR={message:({schemaCode:e})=>(0,oa.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,oa._)`{multipleOf: ${e}}`},mR={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:fR,code(e){let{gen:t,data:r,schemaCode:o,it:n}=e,i=n.opts.multipleOfPrecision,s=t.let("res"),a=i?(0,oa._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:(0,oa._)`${s} !== parseInt(${s})`;e.fail$data((0,oa._)`(${o} === 0 || (${s} = ${r}/${o}, ${a}))`)}};jh.default=mR});var Uw=$(Nh=>{"use strict";Object.defineProperty(Nh,"__esModule",{value:!0});function Mw(e){let t=e.length,r=0,o=0,n;for(;o<t;)r++,n=e.charCodeAt(o++),n>=55296&&n<=56319&&o<t&&(n=e.charCodeAt(o),(n&64512)===56320&&o++);return r}Nh.default=Mw;Mw.code='require("ajv/dist/runtime/ucs2length").default'});var Zw=$(Rh=>{"use strict";Object.defineProperty(Rh,"__esModule",{value:!0});var Cn=oe(),hR=he(),gR=Uw(),vR={message({keyword:e,schemaCode:t}){let r=e==="maxLength"?"more":"fewer";return(0,Cn.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,Cn._)`{limit: ${e}}`},_R={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:vR,code(e){let{keyword:t,data:r,schemaCode:o,it:n}=e,i=t==="maxLength"?Cn.operators.GT:Cn.operators.LT,s=n.opts.unicode===!1?(0,Cn._)`${r}.length`:(0,Cn._)`${(0,hR.useFunc)(e.gen,gR.default)}(${r})`;e.fail$data((0,Cn._)`${s} ${i} ${o}`)}};Rh.default=_R});var Vw=$(Ch=>{"use strict";Object.defineProperty(Ch,"__esModule",{value:!0});var yR=Dt(),Gl=oe(),bR={message:({schemaCode:e})=>(0,Gl.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,Gl._)`{pattern: ${e}}`},$R={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:bR,code(e){let{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,s=i.opts.unicodeRegExp?"u":"",a=r?(0,Gl._)`(new RegExp(${n}, ${s}))`:(0,yR.usePattern)(e,o);e.fail$data((0,Gl._)`!${a}.test(${t})`)}};Ch.default=$R});var Lw=$(Ah=>{"use strict";Object.defineProperty(Ah,"__esModule",{value:!0});var ia=oe(),wR={message({keyword:e,schemaCode:t}){let r=e==="maxProperties"?"more":"fewer";return(0,ia.str)`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>(0,ia._)`{limit: ${e}}`},kR={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:wR,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxProperties"?ia.operators.GT:ia.operators.LT;e.fail$data((0,ia._)`Object.keys(${r}).length ${n} ${o}`)}};Ah.default=kR});var Fw=$(Dh=>{"use strict";Object.defineProperty(Dh,"__esModule",{value:!0});var sa=Dt(),aa=oe(),xR=he(),SR={message:({params:{missingProperty:e}})=>(0,aa.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,aa._)`{missingProperty: ${e}}`},TR={keyword:"required",type:"object",schemaType:"array",$data:!0,error:SR,code(e){let{gen:t,schema:r,schemaCode:o,data:n,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors?u():l(),a.strictRequired){let m=e.parentSchema.properties,{definedProperties:p}=e.it;for(let f of r)if(m?.[f]===void 0&&!p.has(f)){let v=s.schemaEnv.baseId+s.errSchemaPath,y=`required property "${f}" is not defined at "${v}" (strictRequired)`;(0,xR.checkStrictMode)(s,y,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(aa.nil,d);else for(let m of r)(0,sa.checkReportMissingProp)(e,m)}function l(){let m=t.let("missing");if(c||i){let p=t.let("valid",!0);e.block$data(p,()=>h(m,p)),e.ok(p)}else t.if((0,sa.checkMissingProp)(e,r,m)),(0,sa.reportMissingProp)(e,m),t.else()}function d(){t.forOf("prop",o,m=>{e.setParams({missingProperty:m}),t.if((0,sa.noPropertyInData)(t,n,m,a.ownProperties),()=>e.error())})}function h(m,p){e.setParams({missingProperty:m}),t.forOf(m,o,()=>{t.assign(p,(0,sa.propertyInData)(t,n,m,a.ownProperties)),t.if((0,aa.not)(p),()=>{e.error(),t.break()})},aa.nil)}}};Dh.default=TR});var Gw=$(qh=>{"use strict";Object.defineProperty(qh,"__esModule",{value:!0});var ca=oe(),PR={message({keyword:e,schemaCode:t}){let r=e==="maxItems"?"more":"fewer";return(0,ca.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,ca._)`{limit: ${e}}`},zR={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:PR,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxItems"?ca.operators.GT:ca.operators.LT;e.fail$data((0,ca._)`${r}.length ${n} ${o}`)}};qh.default=zR});var Wl=$(Mh=>{"use strict";Object.defineProperty(Mh,"__esModule",{value:!0});var Ww=Hs();Ww.code='require("ajv/dist/runtime/equal").default';Mh.default=Ww});var Kw=$(Zh=>{"use strict";Object.defineProperty(Zh,"__esModule",{value:!0});var Uh=Ks(),Be=oe(),ER=he(),IR=Wl(),OR={message:({params:{i:e,j:t}})=>(0,Be.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Be._)`{i: ${e}, j: ${t}}`},jR={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:OR,code(e){let{gen:t,data:r,$data:o,schema:n,parentSchema:i,schemaCode:s,it:a}=e;if(!o&&!n)return;let c=t.let("valid"),u=i.items?(0,Uh.getSchemaTypes)(i.items):[];e.block$data(c,l,(0,Be._)`${s} === false`),e.ok(c);function l(){let p=t.let("i",(0,Be._)`${r}.length`),f=t.let("j");e.setParams({i:p,j:f}),t.assign(c,!0),t.if((0,Be._)`${p} > 1`,()=>(d()?h:m)(p,f))}function d(){return u.length>0&&!u.some(p=>p==="object"||p==="array")}function h(p,f){let v=t.name("item"),y=(0,Uh.checkDataTypes)(u,v,a.opts.strictNumbers,Uh.DataType.Wrong),w=t.const("indices",(0,Be._)`{}`);t.for((0,Be._)`;${p}--;`,()=>{t.let(v,(0,Be._)`${r}[${p}]`),t.if(y,(0,Be._)`continue`),u.length>1&&t.if((0,Be._)`typeof ${v} == "string"`,(0,Be._)`${v} += "_"`),t.if((0,Be._)`typeof ${w}[${v}] == "number"`,()=>{t.assign(f,(0,Be._)`${w}[${v}]`),e.error(),t.assign(c,!1).break()}).code((0,Be._)`${w}[${v}] = ${p}`)})}function m(p,f){let v=(0,ER.useFunc)(t,IR.default),y=t.name("outer");t.label(y).for((0,Be._)`;${p}--;`,()=>t.for((0,Be._)`${f} = ${p}; ${f}--;`,()=>t.if((0,Be._)`${v}(${r}[${p}], ${r}[${f}])`,()=>{e.error(),t.assign(c,!1).break(y)})))}}};Zh.default=jR});var Hw=$(Lh=>{"use strict";Object.defineProperty(Lh,"__esModule",{value:!0});var Vh=oe(),NR=he(),RR=Wl(),CR={message:"must be equal to constant",params:({schemaCode:e})=>(0,Vh._)`{allowedValue: ${e}}`},AR={keyword:"const",$data:!0,error:CR,code(e){let{gen:t,data:r,$data:o,schemaCode:n,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,Vh._)`!${(0,NR.useFunc)(t,RR.default)}(${r}, ${n})`):e.fail((0,Vh._)`${i} !== ${r}`)}};Lh.default=AR});var Jw=$(Fh=>{"use strict";Object.defineProperty(Fh,"__esModule",{value:!0});var ua=oe(),DR=he(),qR=Wl(),MR={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,ua._)`{allowedValues: ${e}}`},UR={keyword:"enum",schemaType:"array",$data:!0,error:MR,code(e){let{gen:t,data:r,$data:o,schema:n,schemaCode:i,it:s}=e;if(!o&&n.length===0)throw new Error("enum must have non-empty array");let a=n.length>=s.opts.loopEnum,c,u=()=>c??(c=(0,DR.useFunc)(t,qR.default)),l;if(a||o)l=t.let("valid"),e.block$data(l,d);else{if(!Array.isArray(n))throw new Error("ajv implementation error");let m=t.const("vSchema",i);l=(0,ua.or)(...n.map((p,f)=>h(m,f)))}e.pass(l);function d(){t.assign(l,!1),t.forOf("v",i,m=>t.if((0,ua._)`${u()}(${r}, ${m})`,()=>t.assign(l,!0).break()))}function h(m,p){let f=n[p];return typeof f=="object"&&f!==null?(0,ua._)`${u()}(${r}, ${m}[${p}])`:(0,ua._)`${r} === ${f}`}}};Fh.default=UR});var Bw=$(Gh=>{"use strict";Object.defineProperty(Gh,"__esModule",{value:!0});var ZR=Dw(),VR=qw(),LR=Zw(),FR=Vw(),GR=Lw(),WR=Fw(),KR=Gw(),HR=Kw(),JR=Hw(),BR=Jw(),YR=[ZR.default,VR.default,LR.default,FR.default,GR.default,WR.default,KR.default,HR.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},JR.default,BR.default];Gh.default=YR});var Kh=$(la=>{"use strict";Object.defineProperty(la,"__esModule",{value:!0});la.validateAdditionalItems=void 0;var An=oe(),Wh=he(),XR={message:({params:{len:e}})=>(0,An.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,An._)`{limit: ${e}}`},QR={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:XR,code(e){let{parentSchema:t,it:r}=e,{items:o}=t;if(!Array.isArray(o)){(0,Wh.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}Yw(e,o)}};function Yw(e,t){let{gen:r,schema:o,data:n,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",(0,An._)`${n}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,An._)`${a} <= ${t.length}`);else if(typeof o=="object"&&!(0,Wh.alwaysValidSchema)(s,o)){let u=r.var("valid",(0,An._)`${a} <= ${t.length}`);r.if((0,An.not)(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,l=>{e.subschema({keyword:i,dataProp:l,dataPropType:Wh.Type.Num},u),s.allErrors||r.if((0,An.not)(u),()=>r.break())})}}la.validateAdditionalItems=Yw;la.default=QR});var Hh=$(da=>{"use strict";Object.defineProperty(da,"__esModule",{value:!0});da.validateTuple=void 0;var Xw=oe(),Kl=he(),e1=Dt(),t1={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return Qw(e,"additionalItems",t);r.items=!0,!(0,Kl.alwaysValidSchema)(r,t)&&e.ok((0,e1.validateArray)(e))}};function Qw(e,t,r=e.schema){let{gen:o,parentSchema:n,data:i,keyword:s,it:a}=e;l(n),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=Kl.mergeEvaluated.items(o,r.length,a.items));let c=o.name("valid"),u=o.const("len",(0,Xw._)`${i}.length`);r.forEach((d,h)=>{(0,Kl.alwaysValidSchema)(a,d)||(o.if((0,Xw._)`${u} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},c)),e.ok(c))});function l(d){let{opts:h,errSchemaPath:m}=a,p=r.length,f=p===d.minItems&&(p===d.maxItems||d[t]===!1);if(h.strictTuples&&!f){let v=`"${s}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${m}"`;(0,Kl.checkStrictMode)(a,v,h.strictTuples)}}}da.validateTuple=Qw;da.default=t1});var ek=$(Jh=>{"use strict";Object.defineProperty(Jh,"__esModule",{value:!0});var r1=Hh(),n1={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,r1.validateTuple)(e,"items")};Jh.default=n1});var rk=$(Bh=>{"use strict";Object.defineProperty(Bh,"__esModule",{value:!0});var tk=oe(),o1=he(),i1=Dt(),s1=Kh(),a1={message:({params:{len:e}})=>(0,tk.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,tk._)`{limit: ${e}}`},c1={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:a1,code(e){let{schema:t,parentSchema:r,it:o}=e,{prefixItems:n}=r;o.items=!0,!(0,o1.alwaysValidSchema)(o,t)&&(n?(0,s1.validateAdditionalItems)(e,n):e.ok((0,i1.validateArray)(e)))}};Bh.default=c1});var nk=$(Yh=>{"use strict";Object.defineProperty(Yh,"__esModule",{value:!0});var Mt=oe(),Hl=he(),u1={message:({params:{min:e,max:t}})=>t===void 0?(0,Mt.str)`must contain at least ${e} valid item(s)`:(0,Mt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,Mt._)`{minContains: ${e}}`:(0,Mt._)`{minContains: ${e}, maxContains: ${t}}`},l1={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:u1,code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e,s,a,{minContains:c,maxContains:u}=o;i.opts.next?(s=c===void 0?1:c,a=u):s=1;let l=t.const("len",(0,Mt._)`${n}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){(0,Hl.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,Hl.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Hl.alwaysValidSchema)(i,r)){let f=(0,Mt._)`${l} >= ${s}`;a!==void 0&&(f=(0,Mt._)`${f} && ${l} <= ${a}`),e.pass(f);return}i.items=!0;let d=t.name("valid");a===void 0&&s===1?m(d,()=>t.if(d,()=>t.break())):s===0?(t.let(d,!0),a!==void 0&&t.if((0,Mt._)`${n}.length > 0`,h)):(t.let(d,!1),h()),e.result(d,()=>e.reset());function h(){let f=t.name("_valid"),v=t.let("count",0);m(f,()=>t.if(f,()=>p(v)))}function m(f,v){t.forRange("i",0,l,y=>{e.subschema({keyword:"contains",dataProp:y,dataPropType:Hl.Type.Num,compositeRule:!0},f),v()})}function p(f){t.code((0,Mt._)`${f}++`),a===void 0?t.if((0,Mt._)`${f} >= ${s}`,()=>t.assign(d,!0).break()):(t.if((0,Mt._)`${f} > ${a}`,()=>t.assign(d,!1).break()),s===1?t.assign(d,!0):t.if((0,Mt._)`${f} >= ${s}`,()=>t.assign(d,!0)))}}};Yh.default=l1});var sk=$(dr=>{"use strict";Object.defineProperty(dr,"__esModule",{value:!0});dr.validateSchemaDeps=dr.validatePropertyDeps=dr.error=void 0;var Xh=oe(),d1=he(),pa=Dt();dr.error={message:({params:{property:e,depsCount:t,deps:r}})=>{let o=t===1?"property":"properties";return(0,Xh.str)`must have ${o} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:o}})=>(0,Xh._)`{property: ${e},
7
7
  missingProperty: ${o},
8
8
  depsCount: ${t},
9
- deps: ${r}}`};var o1={keyword:"dependencies",type:"object",schemaType:"object",error:lr.error,code(e){let[t,r]=i1(e);nk(e,t),ok(e,r)}};function i1({schema:e}){let t={},r={};for(let o in e){if(o==="__proto__")continue;let n=Array.isArray(e[o])?t:r;n[o]=e[o]}return[t,r]}function nk(e,t=e.schema){let{gen:r,data:o,it:n}=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,la.propertyInData)(r,o,s,n.opts.ownProperties);e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),n.allErrors?r.if(c,()=>{for(let u of a)(0,la.checkReportMissingProp)(e,u)}):(r.if((0,Yh._)`${c} && (${(0,la.checkMissingProp)(e,a,i)})`),(0,la.reportMissingProp)(e,i),r.else())}}lr.validatePropertyDeps=nk;function ok(e,t=e.schema){let{gen:r,data:o,keyword:n,it:i}=e,s=r.name("valid");for(let a in t)(0,n1.alwaysValidSchema)(i,t[a])||(r.if((0,la.propertyInData)(r,o,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:n,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s))}lr.validateSchemaDeps=ok;lr.default=o1});var ak=b(Xh=>{"use strict";Object.defineProperty(Xh,"__esModule",{value:!0});var sk=oe(),s1=he(),a1={message:"property name must be valid",params:({params:e})=>(0,sk._)`{propertyName: ${e.propertyName}}`},c1={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:a1,code(e){let{gen:t,schema:r,data:o,it:n}=e;if((0,s1.alwaysValidSchema)(n,r))return;let i=t.name("valid");t.forIn("key",o,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if((0,sk.not)(i),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(i)}};Xh.default=c1});var eg=b(Qh=>{"use strict";Object.defineProperty(Qh,"__esModule",{value:!0});var Kl=Ct(),Xt=oe(),u1=Pr(),Hl=he(),l1={message:"must NOT have additional properties",params:({params:e})=>(0,Xt._)`{additionalProperty: ${e.additionalProperty}}`},d1={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:l1,code(e){let{gen:t,schema:r,parentSchema:o,data:n,errsCount:i,it:s}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&(0,Hl.alwaysValidSchema)(s,r))return;let u=(0,Kl.allSchemaProperties)(o.properties),l=(0,Kl.allSchemaProperties)(o.patternProperties);d(),e.ok((0,Xt._)`${i} === ${u1.default.errors}`);function d(){t.forIn("key",n,g=>{!u.length&&!l.length?p(g):t.if(h(g),()=>p(g))})}function h(g){let y;if(u.length>8){let w=(0,Hl.schemaRefOrVal)(s,o.properties,"properties");y=(0,Kl.isOwnProperty)(t,w,g)}else u.length?y=(0,Xt.or)(...u.map(w=>(0,Xt._)`${g} === ${w}`)):y=Xt.nil;return l.length&&(y=(0,Xt.or)(y,...l.map(w=>(0,Xt._)`${(0,Kl.usePattern)(e,w)}.test(${g})`))),(0,Xt.not)(y)}function m(g){t.code((0,Xt._)`delete ${n}[${g}]`)}function p(g){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){m(g);return}if(r===!1){e.setParams({additionalProperty:g}),e.error(),a||t.break();return}if(typeof r=="object"&&!(0,Hl.alwaysValidSchema)(s,r)){let y=t.name("valid");c.removeAdditional==="failing"?(f(g,y,!1),t.if((0,Xt.not)(y),()=>{e.reset(),m(g)})):(f(g,y),a||t.if((0,Xt.not)(y),()=>t.break()))}}function f(g,y,w){let k={keyword:"additionalProperties",dataProp:g,dataPropType:Hl.Type.Str};w===!1&&Object.assign(k,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(k,y)}}};Qh.default=d1});var lk=b(rg=>{"use strict";Object.defineProperty(rg,"__esModule",{value:!0});var p1=Bs(),ck=Ct(),tg=he(),uk=eg(),f1={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&uk.default.code(new p1.KeywordCxt(i,uk.default,"additionalProperties"));let s=(0,ck.allSchemaProperties)(r);for(let d of s)i.definedProperties.add(d);i.opts.unevaluated&&s.length&&i.props!==!0&&(i.props=tg.mergeEvaluated.props(t,(0,tg.toHash)(s),i.props));let a=s.filter(d=>!(0,tg.alwaysValidSchema)(i,r[d]));if(a.length===0)return;let c=t.name("valid");for(let d of a)u(d)?l(d):(t.if((0,ck.propertyInData)(t,n,d,i.opts.ownProperties)),l(d),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(d),e.ok(c);function u(d){return i.opts.useDefaults&&!i.compositeRule&&r[d].default!==void 0}function l(d){e.subschema({keyword:"properties",schemaProp:d,dataProp:d},c)}}};rg.default=f1});var mk=b(ng=>{"use strict";Object.defineProperty(ng,"__esModule",{value:!0});var dk=Ct(),Jl=oe(),pk=he(),fk=he(),m1={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:n,it:i}=e,{opts:s}=i,a=(0,dk.allSchemaProperties)(r),c=a.filter(f=>(0,pk.alwaysValidSchema)(i,r[f]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&n.properties,l=t.name("valid");i.props!==!0&&!(i.props instanceof Jl.Name)&&(i.props=(0,fk.evaluatedPropsToName)(t,i.props));let{props:d}=i;h();function h(){for(let f of a)u&&m(f),i.allErrors?p(f):(t.var(l,!0),p(f),t.if(l))}function m(f){for(let g in u)new RegExp(f).test(g)&&(0,pk.checkStrictMode)(i,`property ${g} matches pattern ${f} (use allowMatchingProperties)`)}function p(f){t.forIn("key",o,g=>{t.if((0,Jl._)`${(0,dk.usePattern)(e,f)}.test(${g})`,()=>{let y=c.includes(f);y||e.subschema({keyword:"patternProperties",schemaProp:f,dataProp:g,dataPropType:fk.Type.Str},l),i.opts.unevaluated&&d!==!0?t.assign((0,Jl._)`${d}[${g}]`,!0):!y&&!i.allErrors&&t.if((0,Jl.not)(l),()=>t.break())})})}}};ng.default=m1});var hk=b(og=>{"use strict";Object.defineProperty(og,"__esModule",{value:!0});var h1=he(),g1={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:o}=e;if((0,h1.alwaysValidSchema)(o,r)){e.fail();return}let n=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},n),e.failResult(n,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};og.default=g1});var gk=b(ig=>{"use strict";Object.defineProperty(ig,"__esModule",{value:!0});var v1=Ct(),_1={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:v1.validateUnion,error:{message:"must match a schema in anyOf"}};ig.default=_1});var vk=b(sg=>{"use strict";Object.defineProperty(sg,"__esModule",{value:!0});var Bl=oe(),y1=he(),$1={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Bl._)`{passingSchemas: ${e.passing}}`},b1={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:$1,code(e){let{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.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,d)=>{let h;(0,y1.alwaysValidSchema)(n,l)?t.var(c,!0):h=e.subschema({keyword:"oneOf",schemaProp:d,compositeRule:!0},c),d>0&&t.if((0,Bl._)`${c} && ${s}`).assign(s,!1).assign(a,(0,Bl._)`[${a}, ${d}]`).else(),t.if(c,()=>{t.assign(s,!0),t.assign(a,d),h&&e.mergeEvaluated(h,Bl.Name)})})}}};sg.default=b1});var _k=b(ag=>{"use strict";Object.defineProperty(ag,"__esModule",{value:!0});var w1=he(),k1={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:o}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");let n=t.name("valid");r.forEach((i,s)=>{if((0,w1.alwaysValidSchema)(o,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},n);e.ok(n),e.mergeEvaluated(a)})}};ag.default=k1});var bk=b(cg=>{"use strict";Object.defineProperty(cg,"__esModule",{value:!0});var Yl=oe(),$k=he(),x1={message:({params:e})=>(0,Yl.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Yl._)`{failingKeyword: ${e.ifClause}}`},S1={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:x1,code(e){let{gen:t,parentSchema:r,it:o}=e;r.then===void 0&&r.else===void 0&&(0,$k.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let n=yk(o,"then"),i=yk(o,"else");if(!n&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),n&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else n?t.if(a,u("then")):t.if((0,Yl.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,d){return()=>{let h=e.subschema({keyword:l},a);t.assign(s,a),e.mergeValidEvaluated(h,s),d?t.assign(d,(0,Yl._)`${l}`):e.setParams({ifClause:l})}}}};function yk(e,t){let r=e.schema[t];return r!==void 0&&!(0,$k.alwaysValidSchema)(e,r)}cg.default=S1});var wk=b(ug=>{"use strict";Object.defineProperty(ug,"__esModule",{value:!0});var T1=he(),P1={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){t.if===void 0&&(0,T1.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};ug.default=P1});var kk=b(lg=>{"use strict";Object.defineProperty(lg,"__esModule",{value:!0});var z1=Wh(),E1=Qw(),I1=Kh(),j1=tk(),O1=rk(),N1=ik(),R1=ak(),C1=eg(),A1=lk(),D1=mk(),q1=hk(),M1=gk(),U1=vk(),Z1=_k(),L1=bk(),V1=wk();function F1(e=!1){let t=[q1.default,M1.default,U1.default,Z1.default,L1.default,V1.default,R1.default,C1.default,N1.default,A1.default,D1.default];return e?t.push(E1.default,j1.default):t.push(z1.default,I1.default),t.push(O1.default),t}lg.default=F1});var xk=b(dg=>{"use strict";Object.defineProperty(dg,"__esModule",{value:!0});var Ze=oe(),G1={message:({schemaCode:e})=>(0,Ze.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Ze._)`{format: ${e}}`},W1={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:G1,code(e,t){let{gen:r,data:o,$data:n,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:d}=a;if(!c.validateFormats)return;n?h():m();function h(){let p=r.scopeValue("formats",{ref:d.formats,code:c.code.formats}),f=r.const("fDef",(0,Ze._)`${p}[${s}]`),g=r.let("fType"),y=r.let("format");r.if((0,Ze._)`typeof ${f} == "object" && !(${f} instanceof RegExp)`,()=>r.assign(g,(0,Ze._)`${f}.type || "string"`).assign(y,(0,Ze._)`${f}.validate`),()=>r.assign(g,(0,Ze._)`"string"`).assign(y,f)),e.fail$data((0,Ze.or)(w(),k()));function w(){return c.strictSchema===!1?Ze.nil:(0,Ze._)`${s} && !${y}`}function k(){let E=l.$async?(0,Ze._)`(${f}.async ? await ${y}(${o}) : ${y}(${o}))`:(0,Ze._)`${y}(${o})`,P=(0,Ze._)`(typeof ${y} == "function" ? ${E} : ${y}.test(${o}))`;return(0,Ze._)`${y} && ${y} !== true && ${g} === ${t} && !${P}`}}function m(){let p=d.formats[i];if(!p){w();return}if(p===!0)return;let[f,g,y]=k(p);f===t&&e.pass(E());function w(){if(c.strictSchema===!1){d.logger.warn(P());return}throw new Error(P());function P(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function k(P){let ze=P instanceof RegExp?(0,Ze.regexpCode)(P):c.code.formats?(0,Ze._)`${c.code.formats}${(0,Ze.getProperty)(i)}`:void 0,Me=r.scopeValue("formats",{key:i,ref:P,code:ze});return typeof P=="object"&&!(P instanceof RegExp)?[P.type||"string",P.validate,(0,Ze._)`${Me}.validate`]:["string",P,Me]}function E(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!l.$async)throw new Error("async format in sync schema");return(0,Ze._)`await ${y}(${o})`}return typeof g=="function"?(0,Ze._)`${y}(${o})`:(0,Ze._)`${y}.test(${o})`}}}};dg.default=W1});var Sk=b(pg=>{"use strict";Object.defineProperty(pg,"__esModule",{value:!0});var K1=xk(),H1=[K1.default];pg.default=H1});var Tk=b(Vo=>{"use strict";Object.defineProperty(Vo,"__esModule",{value:!0});Vo.contentVocabulary=Vo.metadataVocabulary=void 0;Vo.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Vo.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var zk=b(fg=>{"use strict";Object.defineProperty(fg,"__esModule",{value:!0});var J1=Cw(),B1=Jw(),Y1=kk(),X1=Sk(),Pk=Tk(),Q1=[J1.default,B1.default,(0,Y1.default)(),X1.default,Pk.metadataVocabulary,Pk.contentVocabulary];fg.default=Q1});var Ik=b(Xl=>{"use strict";Object.defineProperty(Xl,"__esModule",{value:!0});Xl.DiscrError=void 0;var Ek;(function(e){e.Tag="tag",e.Mapping="mapping"})(Ek||(Xl.DiscrError=Ek={}))});var Ok=b(hg=>{"use strict";Object.defineProperty(hg,"__esModule",{value:!0});var Fo=oe(),mg=Ik(),jk=Nl(),eC=Ys(),tC=he(),rC={message:({params:{discrError:e,tagName:t}})=>e===mg.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,Fo._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},nC={keyword:"discriminator",type:"object",schemaType:"object",error:rC,code(e){let{gen:t,data:r,schema:o,parentSchema:n,it:i}=e,{oneOf:s}=n;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=o.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",(0,Fo._)`${r}${(0,Fo.getProperty)(a)}`);t.if((0,Fo._)`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:mg.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let m=h();t.if(!1);for(let p in m)t.elseIf((0,Fo._)`${u} === ${p}`),t.assign(c,d(m[p]));t.else(),e.error(!1,{discrError:mg.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function d(m){let p=t.name("valid"),f=e.subschema({keyword:"oneOf",schemaProp:m},p);return e.mergeEvaluated(f,Fo.Name),p}function h(){var m;let p={},f=y(n),g=!0;for(let E=0;E<s.length;E++){let P=s[E];if(P?.$ref&&!(0,tC.schemaHasRulesButRef)(P,i.self.RULES)){let Me=P.$ref;if(P=jk.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,Me),P instanceof jk.SchemaEnv&&(P=P.schema),P===void 0)throw new eC.default(i.opts.uriResolver,i.baseId,Me)}let ze=(m=P?.properties)===null||m===void 0?void 0:m[a];if(typeof ze!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);g=g&&(f||y(P)),w(ze,E)}if(!g)throw new Error(`discriminator: "${a}" must be required`);return p;function y({required:E}){return Array.isArray(E)&&E.includes(a)}function w(E,P){if(E.const)k(E.const,P);else if(E.enum)for(let ze of E.enum)k(ze,P);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function k(E,P){if(typeof E!="string"||E in p)throw new Error(`discriminator: "${a}" values must be unique strings`);p[E]=P}}}};hg.default=nC});var Nk=b((QW,oC)=>{oC.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 Ck=b((Re,gg)=>{"use strict";Object.defineProperty(Re,"__esModule",{value:!0});Re.MissingRefError=Re.ValidationError=Re.CodeGen=Re.Name=Re.nil=Re.stringify=Re.str=Re._=Re.KeywordCxt=Re.Ajv=void 0;var iC=Ew(),sC=zk(),aC=Ok(),Rk=Nk(),cC=["/properties"],Ql="http://json-schema.org/draft-07/schema",Go=class extends iC.default{_addVocabularies(){super._addVocabularies(),sC.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(aC.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(Rk,cC):Rk;this.addMetaSchema(t,Ql,!1),this.refs["http://json-schema.org/schema"]=Ql}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Ql)?Ql:void 0)}};Re.Ajv=Go;gg.exports=Re=Go;gg.exports.Ajv=Go;Object.defineProperty(Re,"__esModule",{value:!0});Re.default=Go;var uC=Bs();Object.defineProperty(Re,"KeywordCxt",{enumerable:!0,get:function(){return uC.KeywordCxt}});var Wo=oe();Object.defineProperty(Re,"_",{enumerable:!0,get:function(){return Wo._}});Object.defineProperty(Re,"str",{enumerable:!0,get:function(){return Wo.str}});Object.defineProperty(Re,"stringify",{enumerable:!0,get:function(){return Wo.stringify}});Object.defineProperty(Re,"nil",{enumerable:!0,get:function(){return Wo.nil}});Object.defineProperty(Re,"Name",{enumerable:!0,get:function(){return Wo.Name}});Object.defineProperty(Re,"CodeGen",{enumerable:!0,get:function(){return Wo.CodeGen}});var lC=jl();Object.defineProperty(Re,"ValidationError",{enumerable:!0,get:function(){return lC.default}});var dC=Ys();Object.defineProperty(Re,"MissingRefError",{enumerable:!0,get:function(){return dC.default}})});var Vk=b(pr=>{"use strict";Object.defineProperty(pr,"__esModule",{value:!0});pr.formatNames=pr.fastFormats=pr.fullFormats=void 0;function dr(e,t){return{validate:e,compare:t}}pr.fullFormats={date:dr(Mk,$g),time:dr(_g(!0),bg),"date-time":dr(Ak(!0),Zk),"iso-time":dr(_g(),Uk),"iso-date-time":dr(Ak(),Lk),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:vC,"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:xC,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:_C,int32:{type:"number",validate:bC},int64:{type:"number",validate:wC},float:{type:"number",validate:qk},double:{type:"number",validate:qk},password:!0,binary:!0};pr.fastFormats={...pr.fullFormats,date:dr(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,$g),time:dr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,bg),"date-time":dr(/^\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,Zk),"iso-time":dr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Uk),"iso-date-time":dr(/^\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,Lk),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};pr.formatNames=Object.keys(pr.fullFormats);function pC(e){return e%4===0&&(e%100!==0||e%400===0)}var fC=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,mC=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Mk(e){let t=fC.exec(e);if(!t)return!1;let r=+t[1],o=+t[2],n=+t[3];return o>=1&&o<=12&&n>=1&&n<=(o===2&&pC(r)?29:mC[o])}function $g(e,t){if(e&&t)return e>t?1:e<t?-1:0}var vg=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function _g(e){return function(r){let o=vg.exec(r);if(!o)return!1;let n=+o[1],i=+o[2],s=+o[3],a=o[4],c=o[5]==="-"?-1:1,u=+(o[6]||0),l=+(o[7]||0);if(u>23||l>59||e&&!a)return!1;if(n<=23&&i<=59&&s<60)return!0;let d=i-l*c,h=n-u*c-(d<0?1:0);return(h===23||h===-1)&&(d===59||d===-1)&&s<61}}function bg(e,t){if(!(e&&t))return;let r=new Date("2020-01-01T"+e).valueOf(),o=new Date("2020-01-01T"+t).valueOf();if(r&&o)return r-o}function Uk(e,t){if(!(e&&t))return;let r=vg.exec(e),o=vg.exec(t);if(r&&o)return e=r[1]+r[2]+r[3],t=o[1]+o[2]+o[3],e>t?1:e<t?-1:0}var yg=/t|\s/i;function Ak(e){let t=_g(e);return function(o){let n=o.split(yg);return n.length===2&&Mk(n[0])&&t(n[1])}}function Zk(e,t){if(!(e&&t))return;let r=new Date(e).valueOf(),o=new Date(t).valueOf();if(r&&o)return r-o}function Lk(e,t){if(!(e&&t))return;let[r,o]=e.split(yg),[n,i]=t.split(yg),s=$g(r,n);if(s!==void 0)return s||bg(o,i)}var hC=/\/|:/,gC=/^(?:[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 vC(e){return hC.test(e)&&gC.test(e)}var Dk=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function _C(e){return Dk.lastIndex=0,Dk.test(e)}var yC=-(2**31),$C=2**31-1;function bC(e){return Number.isInteger(e)&&e<=$C&&e>=yC}function wC(e){return Number.isInteger(e)}function qk(){return!0}var kC=/[^\\]\\Z/;function xC(e){if(kC.test(e))return!1;try{return new RegExp(e),!0}catch{return!1}}});var fa=b(ge=>{"use strict";Object.defineProperty(ge,"__esModule",{value:!0});ge.regexpCode=ge.getEsmExportName=ge.getProperty=ge.safeStringify=ge.stringify=ge.strConcat=ge.addCodeArg=ge.str=ge._=ge.nil=ge._Code=ge.Name=ge.IDENTIFIER=ge._CodeOrName=void 0;var da=class{};ge._CodeOrName=da;ge.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Dn=class extends da{constructor(t){if(super(),!ge.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};ge.Name=Dn;var qt=class extends da{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,o)=>`${r}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,o)=>(o instanceof Dn&&(r[o.str]=(r[o.str]||0)+1),r),{})}};ge._Code=qt;ge.nil=new qt("");function Fk(e,...t){let r=[e[0]],o=0;for(;o<t.length;)kg(r,t[o]),r.push(e[++o]);return new qt(r)}ge._=Fk;var wg=new qt("+");function Gk(e,...t){let r=[pa(e[0])],o=0;for(;o<t.length;)r.push(wg),kg(r,t[o]),r.push(wg,pa(e[++o]));return SC(r),new qt(r)}ge.str=Gk;function kg(e,t){t instanceof qt?e.push(...t._items):t instanceof Dn?e.push(t):e.push(zC(t))}ge.addCodeArg=kg;function SC(e){let t=1;for(;t<e.length-1;){if(e[t]===wg){let r=TC(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function TC(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof Dn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof Dn))return`"${e}${t.slice(1)}`}function PC(e,t){return t.emptyStr()?e:e.emptyStr()?t:Gk`${e}${t}`}ge.strConcat=PC;function zC(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:pa(Array.isArray(e)?e.join(","):e)}function EC(e){return new qt(pa(e))}ge.stringify=EC;function pa(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}ge.safeStringify=pa;function IC(e){return typeof e=="string"&&ge.IDENTIFIER.test(e)?new qt(`.${e}`):Fk`[${e}]`}ge.getProperty=IC;function jC(e){if(typeof e=="string"&&ge.IDENTIFIER.test(e))return new qt(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}ge.getEsmExportName=jC;function OC(e){return new qt(e.toString())}ge.regexpCode=OC});var Tg=b(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.ValueScope=bt.ValueScopeName=bt.Scope=bt.varKinds=bt.UsedValueState=void 0;var $t=fa(),xg=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},ed;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(ed||(bt.UsedValueState=ed={}));bt.varKinds={const:new $t.Name("const"),let:new $t.Name("let"),var:new $t.Name("var")};var td=class{constructor({prefixes:t,parent:r}={}){this._names={},this._prefixes=t,this._parent=r}toName(t){return t instanceof $t.Name?t:this.name(t)}name(t){return new $t.Name(this._newName(t))}_newName(t){let r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,o;if(!((o=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};bt.Scope=td;var rd=class extends $t.Name{constructor(t,r){super(r),this.prefix=t}setValue(t,{property:r,itemIndex:o}){this.value=t,this.scopePath=(0,$t._)`.${new $t.Name(r)}[${o}]`}};bt.ValueScopeName=rd;var NC=(0,$t._)`\n`,Sg=class extends td{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?NC:$t.nil}}get(){return this._scope}name(t){return new rd(t,this._newName(t))}value(t,r){var o;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(t),{prefix:i}=n,s=(o=r.key)!==null&&o!==void 0?o:r.ref,a=this._values[i];if(a){let l=a.get(s);if(l)return l}else a=this._values[i]=new Map;a.set(s,n);let c=this._scope[i]||(this._scope[i]=[]),u=c.length;return c[u]=r.ref,n.setValue(r,{property:i,itemIndex:u}),n}getValue(t,r){let o=this._values[t];if(o)return o.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,$t._)`${t}${o.scopePath}`})}scopeCode(t=this._values,r,o){return this._reduceValues(t,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},r,o)}_reduceValues(t,r,o={},n){let i=$t.nil;for(let s in t){let a=t[s];if(!a)continue;let c=o[s]=o[s]||new Map;a.forEach(u=>{if(c.has(u))return;c.set(u,ed.Started);let l=r(u);if(l){let d=this.opts.es5?bt.varKinds.var:bt.varKinds.const;i=(0,$t._)`${i}${d} ${u} = ${l};${this.opts._n}`}else if(l=n?.(u))i=(0,$t._)`${i}${l}${this.opts._n}`;else throw new xg(u);c.set(u,ed.Completed)})}return i}};bt.ValueScope=Sg});var Q=b(ne=>{"use strict";Object.defineProperty(ne,"__esModule",{value:!0});ne.or=ne.and=ne.not=ne.CodeGen=ne.operators=ne.varKinds=ne.ValueScopeName=ne.ValueScope=ne.Scope=ne.Name=ne.regexpCode=ne.stringify=ne.getProperty=ne.nil=ne.strConcat=ne.str=ne._=void 0;var de=fa(),Qt=Tg(),rn=fa();Object.defineProperty(ne,"_",{enumerable:!0,get:function(){return rn._}});Object.defineProperty(ne,"str",{enumerable:!0,get:function(){return rn.str}});Object.defineProperty(ne,"strConcat",{enumerable:!0,get:function(){return rn.strConcat}});Object.defineProperty(ne,"nil",{enumerable:!0,get:function(){return rn.nil}});Object.defineProperty(ne,"getProperty",{enumerable:!0,get:function(){return rn.getProperty}});Object.defineProperty(ne,"stringify",{enumerable:!0,get:function(){return rn.stringify}});Object.defineProperty(ne,"regexpCode",{enumerable:!0,get:function(){return rn.regexpCode}});Object.defineProperty(ne,"Name",{enumerable:!0,get:function(){return rn.Name}});var sd=Tg();Object.defineProperty(ne,"Scope",{enumerable:!0,get:function(){return sd.Scope}});Object.defineProperty(ne,"ValueScope",{enumerable:!0,get:function(){return sd.ValueScope}});Object.defineProperty(ne,"ValueScopeName",{enumerable:!0,get:function(){return sd.ValueScopeName}});Object.defineProperty(ne,"varKinds",{enumerable:!0,get:function(){return sd.varKinds}});ne.operators={GT:new de._Code(">"),GTE:new de._Code(">="),LT:new de._Code("<"),LTE:new de._Code("<="),EQ:new de._Code("==="),NEQ:new de._Code("!=="),NOT:new de._Code("!"),OR:new de._Code("||"),AND:new de._Code("&&"),ADD:new de._Code("+")};var Ir=class{optimizeNodes(){return this}optimizeNames(t,r){return this}},Pg=class extends Ir{constructor(t,r,o){super(),this.varKind=t,this.name=r,this.rhs=o}render({es5:t,_n:r}){let o=t?Qt.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${n};`+r}optimizeNames(t,r){if(t[this.name.str])return this.rhs&&(this.rhs=Ho(this.rhs,t,r)),this}get names(){return this.rhs instanceof de._CodeOrName?this.rhs.names:{}}},nd=class extends Ir{constructor(t,r,o){super(),this.lhs=t,this.rhs=r,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(!(this.lhs instanceof de.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=Ho(this.rhs,t,r),this}get names(){let t=this.lhs instanceof de.Name?{}:{...this.lhs.names};return id(t,this.rhs)}},zg=class extends nd{constructor(t,r,o,n){super(t,o,n),this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},Eg=class extends Ir{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},Ig=class extends Ir{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},jg=class extends Ir{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},Og=class extends Ir{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){return this.code=Ho(this.code,t,r),this}get names(){return this.code instanceof de._CodeOrName?this.code.names:{}}},ma=class extends Ir{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((r,o)=>r+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,r=t.length;for(;r--;){let o=t[r].optimizeNodes();Array.isArray(o)?t.splice(r,1,...o):o?t[r]=o:t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){let{nodes:o}=this,n=o.length;for(;n--;){let i=o[n];i.optimizeNames(t,r)||(RC(t,i.names),o.splice(n,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>Un(t,r.names),{})}},jr=class extends ma{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},Ng=class extends ma{},Ko=class extends jr{};Ko.kind="else";var qn=class e extends jr{constructor(t,r){super(r),this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);return this.else&&(r+="else "+this.else.render(t)),r}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let r=this.else;if(r){let o=r.optimizeNodes();r=this.else=Array.isArray(o)?new Ko(o):o}if(r)return t===!1?r instanceof e?r:r.nodes:this.nodes.length?this:new e(Wk(t),r instanceof e?[r]:r.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,r){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,r),!!(super.optimizeNames(t,r)||this.else))return this.condition=Ho(this.condition,t,r),this}get names(){let t=super.names;return id(t,this.condition),this.else&&Un(t,this.else.names),t}};qn.kind="if";var Mn=class extends jr{};Mn.kind="for";var Rg=class extends Mn{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iteration=Ho(this.iteration,t,r),this}get names(){return Un(super.names,this.iteration.names)}},Cg=class extends Mn{constructor(t,r,o,n){super(),this.varKind=t,this.name=r,this.from=o,this.to=n}render(t){let r=t.es5?Qt.varKinds.var:this.varKind,{name:o,from:n,to:i}=this;return`for(${r} ${o}=${n}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=id(super.names,this.from);return id(t,this.to)}},od=class extends Mn{constructor(t,r,o,n){super(),this.loop=t,this.varKind=r,this.name=o,this.iterable=n}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iterable=Ho(this.iterable,t,r),this}get names(){return Un(super.names,this.iterable.names)}},ha=class extends jr{constructor(t,r,o){super(),this.name=t,this.args=r,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};ha.kind="func";var ga=class extends ma{render(t){return"return "+super.render(t)}};ga.kind="return";var Ag=class extends jr{render(t){let r="try"+super.render(t);return this.catch&&(r+=this.catch.render(t)),this.finally&&(r+=this.finally.render(t)),r}optimizeNodes(){var t,r;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(t,r){var o,n;return super.optimizeNames(t,r),(o=this.catch)===null||o===void 0||o.optimizeNames(t,r),(n=this.finally)===null||n===void 0||n.optimizeNames(t,r),this}get names(){let t=super.names;return this.catch&&Un(t,this.catch.names),this.finally&&Un(t,this.finally.names),t}},va=class extends jr{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};va.kind="catch";var _a=class extends jr{render(t){return"finally"+super.render(t)}};_a.kind="finally";var Dg=class{constructor(t,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
10
- `:""},this._extScope=t,this._scope=new Qt.Scope({parent:t}),this._nodes=[new Ng]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){let o=this._extScope.value(t,r);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,o,n){let i=this._scope.toName(r);return o!==void 0&&n&&(this._constants[i.str]=o),this._leafNode(new Pg(t,i,o)),i}const(t,r,o){return this._def(Qt.varKinds.const,t,r,o)}let(t,r,o){return this._def(Qt.varKinds.let,t,r,o)}var(t,r,o){return this._def(Qt.varKinds.var,t,r,o)}assign(t,r,o){return this._leafNode(new nd(t,r,o))}add(t,r){return this._leafNode(new zg(t,ne.operators.ADD,r))}code(t){return typeof t=="function"?t():t!==de.nil&&this._leafNode(new Og(t)),this}object(...t){let r=["{"];for(let[o,n]of t)r.length>1&&r.push(","),r.push(o),(o!==n||this.opts.es5)&&(r.push(":"),(0,de.addCodeArg)(r,n));return r.push("}"),new de._Code(r)}if(t,r,o){if(this._blockNode(new qn(t)),r&&o)this.code(r).else().code(o).endIf();else if(r)this.code(r).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new qn(t))}else(){return this._elseNode(new Ko)}endIf(){return this._endBlockNode(qn,Ko)}_for(t,r){return this._blockNode(t),r&&this.code(r).endFor(),this}for(t,r){return this._for(new Rg(t),r)}forRange(t,r,o,n,i=this.opts.es5?Qt.varKinds.var:Qt.varKinds.let){let s=this._scope.toName(t);return this._for(new Cg(i,s,r,o),()=>n(s))}forOf(t,r,o,n=Qt.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let s=r instanceof de.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,de._)`${s}.length`,a=>{this.var(i,(0,de._)`${s}[${a}]`),o(i)})}return this._for(new od("of",n,i,r),()=>o(i))}forIn(t,r,o,n=this.opts.es5?Qt.varKinds.var:Qt.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,de._)`Object.keys(${r})`,o);let i=this._scope.toName(t);return this._for(new od("in",n,i,r),()=>o(i))}endFor(){return this._endBlockNode(Mn)}label(t){return this._leafNode(new Eg(t))}break(t){return this._leafNode(new Ig(t))}return(t){let r=new ga;if(this._blockNode(r),this.code(t),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(ga)}try(t,r,o){if(!r&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new Ag;if(this._blockNode(n),this.code(t),r){let i=this.name("e");this._currNode=n.catch=new va(i),r(i)}return o&&(this._currNode=n.finally=new _a,this.code(o)),this._endBlockNode(va,_a)}throw(t){return this._leafNode(new jg(t))}block(t,r){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(r),this}endBlock(t){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-r;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=r,this}func(t,r=de.nil,o,n){return this._blockNode(new ha(t,r,o)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(ha)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,r){let o=this._currNode;if(o instanceof t||r&&o instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){let r=this._currNode;if(!(r instanceof qn))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let r=this._nodes;r[r.length-1]=t}};ne.CodeGen=Dg;function Un(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function id(e,t){return t instanceof de._CodeOrName?Un(e,t.names):e}function Ho(e,t,r){if(e instanceof de.Name)return o(e);if(!n(e))return e;return new de._Code(e._items.reduce((i,s)=>(s instanceof de.Name&&(s=o(s)),s instanceof de._Code?i.push(...s._items):i.push(s),i),[]));function o(i){let s=r[i.str];return s===void 0||t[i.str]!==1?i:(delete t[i.str],s)}function n(i){return i instanceof de._Code&&i._items.some(s=>s instanceof de.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function RC(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function Wk(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,de._)`!${qg(e)}`}ne.not=Wk;var CC=Kk(ne.operators.AND);function AC(...e){return e.reduce(CC)}ne.and=AC;var DC=Kk(ne.operators.OR);function qC(...e){return e.reduce(DC)}ne.or=qC;function Kk(e){return(t,r)=>t===de.nil?r:r===de.nil?t:(0,de._)`${qg(t)} ${e} ${qg(r)}`}function qg(e){return e instanceof de.Name?e:(0,de._)`(${e})`}});var ve=b(se=>{"use strict";Object.defineProperty(se,"__esModule",{value:!0});se.checkStrictMode=se.getErrorPath=se.Type=se.useFunc=se.setEvaluated=se.evaluatedPropsToName=se.mergeEvaluated=se.eachItem=se.unescapeJsonPointer=se.escapeJsonPointer=se.escapeFragment=se.unescapeFragment=se.schemaRefOrVal=se.schemaHasRulesButRef=se.schemaHasRules=se.checkUnknownRules=se.alwaysValidSchema=se.toHash=void 0;var Pe=Q(),MC=fa();function UC(e){let t={};for(let r of e)t[r]=!0;return t}se.toHash=UC;function ZC(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(Bk(e,t),!Yk(t,e.self.RULES.all))}se.alwaysValidSchema=ZC;function Bk(e,t=e.schema){let{opts:r,self:o}=e;if(!r.strictSchema||typeof t=="boolean")return;let n=o.RULES.keywords;for(let i in t)n[i]||ex(e,`unknown keyword: "${i}"`)}se.checkUnknownRules=Bk;function Yk(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}se.schemaHasRules=Yk;function LC(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}se.schemaHasRulesButRef=LC;function VC({topSchemaRef:e,schemaPath:t},r,o,n){if(!n){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Pe._)`${r}`}return(0,Pe._)`${e}${t}${(0,Pe.getProperty)(o)}`}se.schemaRefOrVal=VC;function FC(e){return Xk(decodeURIComponent(e))}se.unescapeFragment=FC;function GC(e){return encodeURIComponent(Ug(e))}se.escapeFragment=GC;function Ug(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}se.escapeJsonPointer=Ug;function Xk(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}se.unescapeJsonPointer=Xk;function WC(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}se.eachItem=WC;function Hk({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:o}){return(n,i,s,a)=>{let c=s===void 0?i:s instanceof Pe.Name?(i instanceof Pe.Name?e(n,i,s):t(n,i,s),s):i instanceof Pe.Name?(t(n,s,i),i):r(i,s);return a===Pe.Name&&!(c instanceof Pe.Name)?o(n,c):c}}se.mergeEvaluated={props:Hk({mergeNames:(e,t,r)=>e.if((0,Pe._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Pe._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,Pe._)`${r} || {}`).code((0,Pe._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Pe._)`${r} !== true`,()=>{t===!0?e.assign(r,!0):(e.assign(r,(0,Pe._)`${r} || {}`),Zg(e,r,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:Qk}),items:Hk({mergeNames:(e,t,r)=>e.if((0,Pe._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Pe._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Pe._)`${r} !== true`,()=>e.assign(r,t===!0?!0:(0,Pe._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function Qk(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",(0,Pe._)`{}`);return t!==void 0&&Zg(e,r,t),r}se.evaluatedPropsToName=Qk;function Zg(e,t,r){Object.keys(r).forEach(o=>e.assign((0,Pe._)`${t}${(0,Pe.getProperty)(o)}`,!0))}se.setEvaluated=Zg;var Jk={};function KC(e,t){return e.scopeValue("func",{ref:t,code:Jk[t.code]||(Jk[t.code]=new MC._Code(t.code))})}se.useFunc=KC;var Mg;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Mg||(se.Type=Mg={}));function HC(e,t,r){if(e instanceof Pe.Name){let o=t===Mg.Num;return r?o?(0,Pe._)`"[" + ${e} + "]"`:(0,Pe._)`"['" + ${e} + "']"`:o?(0,Pe._)`"/" + ${e}`:(0,Pe._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Pe.getProperty)(e).toString():"/"+Ug(e)}se.getErrorPath=HC;function ex(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,r===!0)throw new Error(t);e.self.logger.warn(t)}}se.checkStrictMode=ex});var Or=b(Lg=>{"use strict";Object.defineProperty(Lg,"__esModule",{value:!0});var ot=Q(),JC={data:new ot.Name("data"),valCxt:new ot.Name("valCxt"),instancePath:new ot.Name("instancePath"),parentData:new ot.Name("parentData"),parentDataProperty:new ot.Name("parentDataProperty"),rootData:new ot.Name("rootData"),dynamicAnchors:new ot.Name("dynamicAnchors"),vErrors:new ot.Name("vErrors"),errors:new ot.Name("errors"),this:new ot.Name("this"),self:new ot.Name("self"),scope:new ot.Name("scope"),json:new ot.Name("json"),jsonPos:new ot.Name("jsonPos"),jsonLen:new ot.Name("jsonLen"),jsonPart:new ot.Name("jsonPart")};Lg.default=JC});var ya=b(it=>{"use strict";Object.defineProperty(it,"__esModule",{value:!0});it.extendErrors=it.resetErrorsCount=it.reportExtraError=it.reportError=it.keyword$DataError=it.keywordError=void 0;var fe=Q(),ad=ve(),pt=Or();it.keywordError={message:({keyword:e})=>(0,fe.str)`must pass "${e}" keyword validation`};it.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,fe.str)`"${e}" keyword must be ${t} ($data)`:(0,fe.str)`"${e}" keyword is invalid ($data)`};function BC(e,t=it.keywordError,r,o){let{it:n}=e,{gen:i,compositeRule:s,allErrors:a}=n,c=nx(e,t,r);o??(s||a)?tx(i,c):rx(n,(0,fe._)`[${c}]`)}it.reportError=BC;function YC(e,t=it.keywordError,r){let{it:o}=e,{gen:n,compositeRule:i,allErrors:s}=o,a=nx(e,t,r);tx(n,a),i||s||rx(o,pt.default.vErrors)}it.reportExtraError=YC;function XC(e,t){e.assign(pt.default.errors,t),e.if((0,fe._)`${pt.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,fe._)`${pt.default.vErrors}.length`,t),()=>e.assign(pt.default.vErrors,null)))}it.resetErrorsCount=XC;function QC({gen:e,keyword:t,schemaValue:r,data:o,errsCount:n,it:i}){if(n===void 0)throw new Error("ajv implementation error");let s=e.name("err");e.forRange("i",n,pt.default.errors,a=>{e.const(s,(0,fe._)`${pt.default.vErrors}[${a}]`),e.if((0,fe._)`${s}.instancePath === undefined`,()=>e.assign((0,fe._)`${s}.instancePath`,(0,fe.strConcat)(pt.default.instancePath,i.errorPath))),e.assign((0,fe._)`${s}.schemaPath`,(0,fe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,fe._)`${s}.schema`,r),e.assign((0,fe._)`${s}.data`,o))})}it.extendErrors=QC;function tx(e,t){let r=e.const("err",t);e.if((0,fe._)`${pt.default.vErrors} === null`,()=>e.assign(pt.default.vErrors,(0,fe._)`[${r}]`),(0,fe._)`${pt.default.vErrors}.push(${r})`),e.code((0,fe._)`${pt.default.errors}++`)}function rx(e,t){let{gen:r,validateName:o,schemaEnv:n}=e;n.$async?r.throw((0,fe._)`new ${e.ValidationError}(${t})`):(r.assign((0,fe._)`${o}.errors`,t),r.return(!1))}var Zn={keyword:new fe.Name("keyword"),schemaPath:new fe.Name("schemaPath"),params:new fe.Name("params"),propertyName:new fe.Name("propertyName"),message:new fe.Name("message"),schema:new fe.Name("schema"),parentSchema:new fe.Name("parentSchema")};function nx(e,t,r){let{createErrors:o}=e.it;return o===!1?(0,fe._)`{}`:eA(e,t,r)}function eA(e,t,r={}){let{gen:o,it:n}=e,i=[tA(n,r),rA(e,r)];return nA(e,t,i),o.object(...i)}function tA({errorPath:e},{instancePath:t}){let r=t?(0,fe.str)`${e}${(0,ad.getErrorPath)(t,ad.Type.Str)}`:e;return[pt.default.instancePath,(0,fe.strConcat)(pt.default.instancePath,r)]}function rA({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:(0,fe.str)`${t}/${e}`;return r&&(n=(0,fe.str)`${n}${(0,ad.getErrorPath)(r,ad.Type.Str)}`),[Zn.schemaPath,n]}function nA(e,{params:t,message:r},o){let{keyword:n,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:d}=a;o.push([Zn.keyword,n],[Zn.params,typeof t=="function"?t(e):t||(0,fe._)`{}`]),c.messages&&o.push([Zn.message,typeof r=="function"?r(e):r]),c.verbose&&o.push([Zn.schema,s],[Zn.parentSchema,(0,fe._)`${l}${d}`],[pt.default.data,i]),u&&o.push([Zn.propertyName,u])}});var ix=b(Jo=>{"use strict";Object.defineProperty(Jo,"__esModule",{value:!0});Jo.boolOrEmptySchema=Jo.topBoolOrEmptySchema=void 0;var oA=ya(),iA=Q(),sA=Or(),aA={message:"boolean schema is false"};function cA(e){let{gen:t,schema:r,validateName:o}=e;r===!1?ox(e,!1):typeof r=="object"&&r.$async===!0?t.return(sA.default.data):(t.assign((0,iA._)`${o}.errors`,null),t.return(!0))}Jo.topBoolOrEmptySchema=cA;function uA(e,t){let{gen:r,schema:o}=e;o===!1?(r.var(t,!1),ox(e)):r.var(t,!0)}Jo.boolOrEmptySchema=uA;function ox(e,t){let{gen:r,data:o}=e,n={gen:r,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,oA.reportError)(n,aA,void 0,t)}});var Vg=b(Bo=>{"use strict";Object.defineProperty(Bo,"__esModule",{value:!0});Bo.getRules=Bo.isJSONType=void 0;var lA=["string","number","integer","boolean","null","object","array"],dA=new Set(lA);function pA(e){return typeof e=="string"&&dA.has(e)}Bo.isJSONType=pA;function fA(){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:{}}}Bo.getRules=fA});var Fg=b(nn=>{"use strict";Object.defineProperty(nn,"__esModule",{value:!0});nn.shouldUseRule=nn.shouldUseGroup=nn.schemaHasRulesForType=void 0;function mA({schema:e,self:t},r){let o=t.RULES.types[r];return o&&o!==!0&&sx(e,o)}nn.schemaHasRulesForType=mA;function sx(e,t){return t.rules.some(r=>ax(e,r))}nn.shouldUseGroup=sx;function ax(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(o=>e[o]!==void 0))}nn.shouldUseRule=ax});var $a=b(st=>{"use strict";Object.defineProperty(st,"__esModule",{value:!0});st.reportTypeError=st.checkDataTypes=st.checkDataType=st.coerceAndCheckDataType=st.getJSONTypes=st.getSchemaTypes=st.DataType=void 0;var hA=Vg(),gA=Fg(),vA=ya(),Y=Q(),cx=ve(),Yo;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(Yo||(st.DataType=Yo={}));function _A(e){let t=ux(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}st.getSchemaTypes=_A;function ux(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(hA.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}st.getJSONTypes=ux;function yA(e,t){let{gen:r,data:o,opts:n}=e,i=$A(t,n.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&(0,gA.schemaHasRulesForType)(e,t[0]));if(s){let a=Wg(t,o,n.strictNumbers,Yo.Wrong);r.if(a,()=>{i.length?bA(e,t,i):Kg(e)})}return s}st.coerceAndCheckDataType=yA;var lx=new Set(["string","number","integer","boolean","null"]);function $A(e,t){return t?e.filter(r=>lx.has(r)||t==="array"&&r==="array"):[]}function bA(e,t,r){let{gen:o,data:n,opts:i}=e,s=o.let("dataType",(0,Y._)`typeof ${n}`),a=o.let("coerced",(0,Y._)`undefined`);i.coerceTypes==="array"&&o.if((0,Y._)`${s} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>o.assign(n,(0,Y._)`${n}[0]`).assign(s,(0,Y._)`typeof ${n}`).if(Wg(t,n,i.strictNumbers),()=>o.assign(a,n))),o.if((0,Y._)`${a} !== undefined`);for(let u of r)(lx.has(u)||u==="array"&&i.coerceTypes==="array")&&c(u);o.else(),Kg(e),o.endIf(),o.if((0,Y._)`${a} !== undefined`,()=>{o.assign(n,a),wA(e,a)});function c(u){switch(u){case"string":o.elseIf((0,Y._)`${s} == "number" || ${s} == "boolean"`).assign(a,(0,Y._)`"" + ${n}`).elseIf((0,Y._)`${n} === null`).assign(a,(0,Y._)`""`);return;case"number":o.elseIf((0,Y._)`${s} == "boolean" || ${n} === null
9
+ deps: ${r}}`};var p1={keyword:"dependencies",type:"object",schemaType:"object",error:dr.error,code(e){let[t,r]=f1(e);ok(e,t),ik(e,r)}};function f1({schema:e}){let t={},r={};for(let o in e){if(o==="__proto__")continue;let n=Array.isArray(e[o])?t:r;n[o]=e[o]}return[t,r]}function ok(e,t=e.schema){let{gen:r,data:o,it:n}=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,pa.propertyInData)(r,o,s,n.opts.ownProperties);e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),n.allErrors?r.if(c,()=>{for(let u of a)(0,pa.checkReportMissingProp)(e,u)}):(r.if((0,Xh._)`${c} && (${(0,pa.checkMissingProp)(e,a,i)})`),(0,pa.reportMissingProp)(e,i),r.else())}}dr.validatePropertyDeps=ok;function ik(e,t=e.schema){let{gen:r,data:o,keyword:n,it:i}=e,s=r.name("valid");for(let a in t)(0,d1.alwaysValidSchema)(i,t[a])||(r.if((0,pa.propertyInData)(r,o,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:n,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s))}dr.validateSchemaDeps=ik;dr.default=p1});var ck=$(Qh=>{"use strict";Object.defineProperty(Qh,"__esModule",{value:!0});var ak=oe(),m1=he(),h1={message:"property name must be valid",params:({params:e})=>(0,ak._)`{propertyName: ${e.propertyName}}`},g1={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:h1,code(e){let{gen:t,schema:r,data:o,it:n}=e;if((0,m1.alwaysValidSchema)(n,r))return;let i=t.name("valid");t.forIn("key",o,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if((0,ak.not)(i),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(i)}};Qh.default=g1});var tg=$(eg=>{"use strict";Object.defineProperty(eg,"__esModule",{value:!0});var Jl=Dt(),Qt=oe(),v1=zr(),Bl=he(),_1={message:"must NOT have additional properties",params:({params:e})=>(0,Qt._)`{additionalProperty: ${e.additionalProperty}}`},y1={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:_1,code(e){let{gen:t,schema:r,parentSchema:o,data:n,errsCount:i,it:s}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&(0,Bl.alwaysValidSchema)(s,r))return;let u=(0,Jl.allSchemaProperties)(o.properties),l=(0,Jl.allSchemaProperties)(o.patternProperties);d(),e.ok((0,Qt._)`${i} === ${v1.default.errors}`);function d(){t.forIn("key",n,v=>{!u.length&&!l.length?p(v):t.if(h(v),()=>p(v))})}function h(v){let y;if(u.length>8){let w=(0,Bl.schemaRefOrVal)(s,o.properties,"properties");y=(0,Jl.isOwnProperty)(t,w,v)}else u.length?y=(0,Qt.or)(...u.map(w=>(0,Qt._)`${v} === ${w}`)):y=Qt.nil;return l.length&&(y=(0,Qt.or)(y,...l.map(w=>(0,Qt._)`${(0,Jl.usePattern)(e,w)}.test(${v})`))),(0,Qt.not)(y)}function m(v){t.code((0,Qt._)`delete ${n}[${v}]`)}function p(v){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){m(v);return}if(r===!1){e.setParams({additionalProperty:v}),e.error(),a||t.break();return}if(typeof r=="object"&&!(0,Bl.alwaysValidSchema)(s,r)){let y=t.name("valid");c.removeAdditional==="failing"?(f(v,y,!1),t.if((0,Qt.not)(y),()=>{e.reset(),m(v)})):(f(v,y),a||t.if((0,Qt.not)(y),()=>t.break()))}}function f(v,y,w){let k={keyword:"additionalProperties",dataProp:v,dataPropType:Bl.Type.Str};w===!1&&Object.assign(k,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(k,y)}}};eg.default=y1});var dk=$(ng=>{"use strict";Object.defineProperty(ng,"__esModule",{value:!0});var b1=Xs(),uk=Dt(),rg=he(),lk=tg(),$1={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&lk.default.code(new b1.KeywordCxt(i,lk.default,"additionalProperties"));let s=(0,uk.allSchemaProperties)(r);for(let d of s)i.definedProperties.add(d);i.opts.unevaluated&&s.length&&i.props!==!0&&(i.props=rg.mergeEvaluated.props(t,(0,rg.toHash)(s),i.props));let a=s.filter(d=>!(0,rg.alwaysValidSchema)(i,r[d]));if(a.length===0)return;let c=t.name("valid");for(let d of a)u(d)?l(d):(t.if((0,uk.propertyInData)(t,n,d,i.opts.ownProperties)),l(d),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(d),e.ok(c);function u(d){return i.opts.useDefaults&&!i.compositeRule&&r[d].default!==void 0}function l(d){e.subschema({keyword:"properties",schemaProp:d,dataProp:d},c)}}};ng.default=$1});var hk=$(og=>{"use strict";Object.defineProperty(og,"__esModule",{value:!0});var pk=Dt(),Yl=oe(),fk=he(),mk=he(),w1={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:n,it:i}=e,{opts:s}=i,a=(0,pk.allSchemaProperties)(r),c=a.filter(f=>(0,fk.alwaysValidSchema)(i,r[f]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&n.properties,l=t.name("valid");i.props!==!0&&!(i.props instanceof Yl.Name)&&(i.props=(0,mk.evaluatedPropsToName)(t,i.props));let{props:d}=i;h();function h(){for(let f of a)u&&m(f),i.allErrors?p(f):(t.var(l,!0),p(f),t.if(l))}function m(f){for(let v in u)new RegExp(f).test(v)&&(0,fk.checkStrictMode)(i,`property ${v} matches pattern ${f} (use allowMatchingProperties)`)}function p(f){t.forIn("key",o,v=>{t.if((0,Yl._)`${(0,pk.usePattern)(e,f)}.test(${v})`,()=>{let y=c.includes(f);y||e.subschema({keyword:"patternProperties",schemaProp:f,dataProp:v,dataPropType:mk.Type.Str},l),i.opts.unevaluated&&d!==!0?t.assign((0,Yl._)`${d}[${v}]`,!0):!y&&!i.allErrors&&t.if((0,Yl.not)(l),()=>t.break())})})}}};og.default=w1});var gk=$(ig=>{"use strict";Object.defineProperty(ig,"__esModule",{value:!0});var k1=he(),x1={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:o}=e;if((0,k1.alwaysValidSchema)(o,r)){e.fail();return}let n=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},n),e.failResult(n,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};ig.default=x1});var vk=$(sg=>{"use strict";Object.defineProperty(sg,"__esModule",{value:!0});var S1=Dt(),T1={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:S1.validateUnion,error:{message:"must match a schema in anyOf"}};sg.default=T1});var _k=$(ag=>{"use strict";Object.defineProperty(ag,"__esModule",{value:!0});var Xl=oe(),P1=he(),z1={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Xl._)`{passingSchemas: ${e.passing}}`},E1={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:z1,code(e){let{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.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,d)=>{let h;(0,P1.alwaysValidSchema)(n,l)?t.var(c,!0):h=e.subschema({keyword:"oneOf",schemaProp:d,compositeRule:!0},c),d>0&&t.if((0,Xl._)`${c} && ${s}`).assign(s,!1).assign(a,(0,Xl._)`[${a}, ${d}]`).else(),t.if(c,()=>{t.assign(s,!0),t.assign(a,d),h&&e.mergeEvaluated(h,Xl.Name)})})}}};ag.default=E1});var yk=$(cg=>{"use strict";Object.defineProperty(cg,"__esModule",{value:!0});var I1=he(),O1={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:o}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");let n=t.name("valid");r.forEach((i,s)=>{if((0,I1.alwaysValidSchema)(o,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},n);e.ok(n),e.mergeEvaluated(a)})}};cg.default=O1});var wk=$(ug=>{"use strict";Object.defineProperty(ug,"__esModule",{value:!0});var Ql=oe(),$k=he(),j1={message:({params:e})=>(0,Ql.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Ql._)`{failingKeyword: ${e.ifClause}}`},N1={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:j1,code(e){let{gen:t,parentSchema:r,it:o}=e;r.then===void 0&&r.else===void 0&&(0,$k.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let n=bk(o,"then"),i=bk(o,"else");if(!n&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),n&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else n?t.if(a,u("then")):t.if((0,Ql.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,d){return()=>{let h=e.subschema({keyword:l},a);t.assign(s,a),e.mergeValidEvaluated(h,s),d?t.assign(d,(0,Ql._)`${l}`):e.setParams({ifClause:l})}}}};function bk(e,t){let r=e.schema[t];return r!==void 0&&!(0,$k.alwaysValidSchema)(e,r)}ug.default=N1});var kk=$(lg=>{"use strict";Object.defineProperty(lg,"__esModule",{value:!0});var R1=he(),C1={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){t.if===void 0&&(0,R1.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};lg.default=C1});var xk=$(dg=>{"use strict";Object.defineProperty(dg,"__esModule",{value:!0});var A1=Kh(),D1=ek(),q1=Hh(),M1=rk(),U1=nk(),Z1=sk(),V1=ck(),L1=tg(),F1=dk(),G1=hk(),W1=gk(),K1=vk(),H1=_k(),J1=yk(),B1=wk(),Y1=kk();function X1(e=!1){let t=[W1.default,K1.default,H1.default,J1.default,B1.default,Y1.default,V1.default,L1.default,Z1.default,F1.default,G1.default];return e?t.push(D1.default,M1.default):t.push(A1.default,q1.default),t.push(U1.default),t}dg.default=X1});var Sk=$(pg=>{"use strict";Object.defineProperty(pg,"__esModule",{value:!0});var Ze=oe(),Q1={message:({schemaCode:e})=>(0,Ze.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Ze._)`{format: ${e}}`},eC={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:Q1,code(e,t){let{gen:r,data:o,$data:n,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:d}=a;if(!c.validateFormats)return;n?h():m();function h(){let p=r.scopeValue("formats",{ref:d.formats,code:c.code.formats}),f=r.const("fDef",(0,Ze._)`${p}[${s}]`),v=r.let("fType"),y=r.let("format");r.if((0,Ze._)`typeof ${f} == "object" && !(${f} instanceof RegExp)`,()=>r.assign(v,(0,Ze._)`${f}.type || "string"`).assign(y,(0,Ze._)`${f}.validate`),()=>r.assign(v,(0,Ze._)`"string"`).assign(y,f)),e.fail$data((0,Ze.or)(w(),k()));function w(){return c.strictSchema===!1?Ze.nil:(0,Ze._)`${s} && !${y}`}function k(){let E=l.$async?(0,Ze._)`(${f}.async ? await ${y}(${o}) : ${y}(${o}))`:(0,Ze._)`${y}(${o})`,P=(0,Ze._)`(typeof ${y} == "function" ? ${E} : ${y}.test(${o}))`;return(0,Ze._)`${y} && ${y} !== true && ${v} === ${t} && !${P}`}}function m(){let p=d.formats[i];if(!p){w();return}if(p===!0)return;let[f,v,y]=k(p);f===t&&e.pass(E());function w(){if(c.strictSchema===!1){d.logger.warn(P());return}throw new Error(P());function P(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function k(P){let ze=P instanceof RegExp?(0,Ze.regexpCode)(P):c.code.formats?(0,Ze._)`${c.code.formats}${(0,Ze.getProperty)(i)}`:void 0,Me=r.scopeValue("formats",{key:i,ref:P,code:ze});return typeof P=="object"&&!(P instanceof RegExp)?[P.type||"string",P.validate,(0,Ze._)`${Me}.validate`]:["string",P,Me]}function E(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!l.$async)throw new Error("async format in sync schema");return(0,Ze._)`await ${y}(${o})`}return typeof v=="function"?(0,Ze._)`${y}(${o})`:(0,Ze._)`${y}.test(${o})`}}}};pg.default=eC});var Tk=$(fg=>{"use strict";Object.defineProperty(fg,"__esModule",{value:!0});var tC=Sk(),rC=[tC.default];fg.default=rC});var Pk=$(Fo=>{"use strict";Object.defineProperty(Fo,"__esModule",{value:!0});Fo.contentVocabulary=Fo.metadataVocabulary=void 0;Fo.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];Fo.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Ek=$(mg=>{"use strict";Object.defineProperty(mg,"__esModule",{value:!0});var nC=Aw(),oC=Bw(),iC=xk(),sC=Tk(),zk=Pk(),aC=[nC.default,oC.default,(0,iC.default)(),sC.default,zk.metadataVocabulary,zk.contentVocabulary];mg.default=aC});var Ok=$(ed=>{"use strict";Object.defineProperty(ed,"__esModule",{value:!0});ed.DiscrError=void 0;var Ik;(function(e){e.Tag="tag",e.Mapping="mapping"})(Ik||(ed.DiscrError=Ik={}))});var Nk=$(gg=>{"use strict";Object.defineProperty(gg,"__esModule",{value:!0});var Go=oe(),hg=Ok(),jk=Cl(),cC=Qs(),uC=he(),lC={message:({params:{discrError:e,tagName:t}})=>e===hg.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,Go._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},dC={keyword:"discriminator",type:"object",schemaType:"object",error:lC,code(e){let{gen:t,data:r,schema:o,parentSchema:n,it:i}=e,{oneOf:s}=n;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=o.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",(0,Go._)`${r}${(0,Go.getProperty)(a)}`);t.if((0,Go._)`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:hg.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let m=h();t.if(!1);for(let p in m)t.elseIf((0,Go._)`${u} === ${p}`),t.assign(c,d(m[p]));t.else(),e.error(!1,{discrError:hg.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function d(m){let p=t.name("valid"),f=e.subschema({keyword:"oneOf",schemaProp:m},p);return e.mergeEvaluated(f,Go.Name),p}function h(){var m;let p={},f=y(n),v=!0;for(let E=0;E<s.length;E++){let P=s[E];if(P?.$ref&&!(0,uC.schemaHasRulesButRef)(P,i.self.RULES)){let Me=P.$ref;if(P=jk.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,Me),P instanceof jk.SchemaEnv&&(P=P.schema),P===void 0)throw new cC.default(i.opts.uriResolver,i.baseId,Me)}let ze=(m=P?.properties)===null||m===void 0?void 0:m[a];if(typeof ze!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);v=v&&(f||y(P)),w(ze,E)}if(!v)throw new Error(`discriminator: "${a}" must be required`);return p;function y({required:E}){return Array.isArray(E)&&E.includes(a)}function w(E,P){if(E.const)k(E.const,P);else if(E.enum)for(let ze of E.enum)k(ze,P);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function k(E,P){if(typeof E!="string"||E in p)throw new Error(`discriminator: "${a}" values must be unique strings`);p[E]=P}}}};gg.default=dC});var Rk=$((wK,pC)=>{pC.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 Ak=$((Re,vg)=>{"use strict";Object.defineProperty(Re,"__esModule",{value:!0});Re.MissingRefError=Re.ValidationError=Re.CodeGen=Re.Name=Re.nil=Re.stringify=Re.str=Re._=Re.KeywordCxt=Re.Ajv=void 0;var fC=Iw(),mC=Ek(),hC=Nk(),Ck=Rk(),gC=["/properties"],td="http://json-schema.org/draft-07/schema",Wo=class extends fC.default{_addVocabularies(){super._addVocabularies(),mC.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(hC.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(Ck,gC):Ck;this.addMetaSchema(t,td,!1),this.refs["http://json-schema.org/schema"]=td}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(td)?td:void 0)}};Re.Ajv=Wo;vg.exports=Re=Wo;vg.exports.Ajv=Wo;Object.defineProperty(Re,"__esModule",{value:!0});Re.default=Wo;var vC=Xs();Object.defineProperty(Re,"KeywordCxt",{enumerable:!0,get:function(){return vC.KeywordCxt}});var Ko=oe();Object.defineProperty(Re,"_",{enumerable:!0,get:function(){return Ko._}});Object.defineProperty(Re,"str",{enumerable:!0,get:function(){return Ko.str}});Object.defineProperty(Re,"stringify",{enumerable:!0,get:function(){return Ko.stringify}});Object.defineProperty(Re,"nil",{enumerable:!0,get:function(){return Ko.nil}});Object.defineProperty(Re,"Name",{enumerable:!0,get:function(){return Ko.Name}});Object.defineProperty(Re,"CodeGen",{enumerable:!0,get:function(){return Ko.CodeGen}});var _C=Nl();Object.defineProperty(Re,"ValidationError",{enumerable:!0,get:function(){return _C.default}});var yC=Qs();Object.defineProperty(Re,"MissingRefError",{enumerable:!0,get:function(){return yC.default}})});var Fk=$(fr=>{"use strict";Object.defineProperty(fr,"__esModule",{value:!0});fr.formatNames=fr.fastFormats=fr.fullFormats=void 0;function pr(e,t){return{validate:e,compare:t}}fr.fullFormats={date:pr(Uk,$g),time:pr(yg(!0),wg),"date-time":pr(Dk(!0),Vk),"iso-time":pr(yg(),Zk),"iso-date-time":pr(Dk(),Lk),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:SC,"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:jC,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:TC,int32:{type:"number",validate:EC},int64:{type:"number",validate:IC},float:{type:"number",validate:Mk},double:{type:"number",validate:Mk},password:!0,binary:!0};fr.fastFormats={...fr.fullFormats,date:pr(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,$g),time:pr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,wg),"date-time":pr(/^\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,Vk),"iso-time":pr(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,Zk),"iso-date-time":pr(/^\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,Lk),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};fr.formatNames=Object.keys(fr.fullFormats);function bC(e){return e%4===0&&(e%100!==0||e%400===0)}var $C=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,wC=[0,31,28,31,30,31,30,31,31,30,31,30,31];function Uk(e){let t=$C.exec(e);if(!t)return!1;let r=+t[1],o=+t[2],n=+t[3];return o>=1&&o<=12&&n>=1&&n<=(o===2&&bC(r)?29:wC[o])}function $g(e,t){if(e&&t)return e>t?1:e<t?-1:0}var _g=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function yg(e){return function(r){let o=_g.exec(r);if(!o)return!1;let n=+o[1],i=+o[2],s=+o[3],a=o[4],c=o[5]==="-"?-1:1,u=+(o[6]||0),l=+(o[7]||0);if(u>23||l>59||e&&!a)return!1;if(n<=23&&i<=59&&s<60)return!0;let d=i-l*c,h=n-u*c-(d<0?1:0);return(h===23||h===-1)&&(d===59||d===-1)&&s<61}}function wg(e,t){if(!(e&&t))return;let r=new Date("2020-01-01T"+e).valueOf(),o=new Date("2020-01-01T"+t).valueOf();if(r&&o)return r-o}function Zk(e,t){if(!(e&&t))return;let r=_g.exec(e),o=_g.exec(t);if(r&&o)return e=r[1]+r[2]+r[3],t=o[1]+o[2]+o[3],e>t?1:e<t?-1:0}var bg=/t|\s/i;function Dk(e){let t=yg(e);return function(o){let n=o.split(bg);return n.length===2&&Uk(n[0])&&t(n[1])}}function Vk(e,t){if(!(e&&t))return;let r=new Date(e).valueOf(),o=new Date(t).valueOf();if(r&&o)return r-o}function Lk(e,t){if(!(e&&t))return;let[r,o]=e.split(bg),[n,i]=t.split(bg),s=$g(r,n);if(s!==void 0)return s||wg(o,i)}var kC=/\/|:/,xC=/^(?:[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 SC(e){return kC.test(e)&&xC.test(e)}var qk=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function TC(e){return qk.lastIndex=0,qk.test(e)}var PC=-(2**31),zC=2**31-1;function EC(e){return Number.isInteger(e)&&e<=zC&&e>=PC}function IC(e){return Number.isInteger(e)}function Mk(){return!0}var OC=/[^\\]\\Z/;function jC(e){if(OC.test(e))return!1;try{return new RegExp(e),!0}catch{return!1}}});var ha=$(ge=>{"use strict";Object.defineProperty(ge,"__esModule",{value:!0});ge.regexpCode=ge.getEsmExportName=ge.getProperty=ge.safeStringify=ge.stringify=ge.strConcat=ge.addCodeArg=ge.str=ge._=ge.nil=ge._Code=ge.Name=ge.IDENTIFIER=ge._CodeOrName=void 0;var fa=class{};ge._CodeOrName=fa;ge.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var Dn=class extends fa{constructor(t){if(super(),!ge.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};ge.Name=Dn;var Ut=class extends fa{constructor(t){super(),this._items=typeof t=="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,o)=>`${r}${o}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,o)=>(o instanceof Dn&&(r[o.str]=(r[o.str]||0)+1),r),{})}};ge._Code=Ut;ge.nil=new Ut("");function Gk(e,...t){let r=[e[0]],o=0;for(;o<t.length;)xg(r,t[o]),r.push(e[++o]);return new Ut(r)}ge._=Gk;var kg=new Ut("+");function Wk(e,...t){let r=[ma(e[0])],o=0;for(;o<t.length;)r.push(kg),xg(r,t[o]),r.push(kg,ma(e[++o]));return NC(r),new Ut(r)}ge.str=Wk;function xg(e,t){t instanceof Ut?e.push(...t._items):t instanceof Dn?e.push(t):e.push(AC(t))}ge.addCodeArg=xg;function NC(e){let t=1;for(;t<e.length-1;){if(e[t]===kg){let r=RC(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}function RC(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string")return t instanceof Dn||e[e.length-1]!=='"'?void 0:typeof t!="string"?`${e.slice(0,-1)}${t}"`:t[0]==='"'?e.slice(0,-1)+t.slice(1):void 0;if(typeof t=="string"&&t[0]==='"'&&!(e instanceof Dn))return`"${e}${t.slice(1)}`}function CC(e,t){return t.emptyStr()?e:e.emptyStr()?t:Wk`${e}${t}`}ge.strConcat=CC;function AC(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:ma(Array.isArray(e)?e.join(","):e)}function DC(e){return new Ut(ma(e))}ge.stringify=DC;function ma(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}ge.safeStringify=ma;function qC(e){return typeof e=="string"&&ge.IDENTIFIER.test(e)?new Ut(`.${e}`):Gk`[${e}]`}ge.getProperty=qC;function MC(e){if(typeof e=="string"&&ge.IDENTIFIER.test(e))return new Ut(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}ge.getEsmExportName=MC;function UC(e){return new Ut(e.toString())}ge.regexpCode=UC});var Pg=$(kt=>{"use strict";Object.defineProperty(kt,"__esModule",{value:!0});kt.ValueScope=kt.ValueScopeName=kt.Scope=kt.varKinds=kt.UsedValueState=void 0;var wt=ha(),Sg=class extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}},rd;(function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"})(rd||(kt.UsedValueState=rd={}));kt.varKinds={const:new wt.Name("const"),let:new wt.Name("let"),var:new wt.Name("var")};var nd=class{constructor({prefixes:t,parent:r}={}){this._names={},this._prefixes=t,this._parent=r}toName(t){return t instanceof wt.Name?t:this.name(t)}name(t){return new wt.Name(this._newName(t))}_newName(t){let r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,o;if(!((o=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||o===void 0)&&o.has(t)||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}};kt.Scope=nd;var od=class extends wt.Name{constructor(t,r){super(r),this.prefix=t}setValue(t,{property:r,itemIndex:o}){this.value=t,this.scopePath=(0,wt._)`.${new wt.Name(r)}[${o}]`}};kt.ValueScopeName=od;var ZC=(0,wt._)`\n`,Tg=class extends nd{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?ZC:wt.nil}}get(){return this._scope}name(t){return new od(t,this._newName(t))}value(t,r){var o;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(t),{prefix:i}=n,s=(o=r.key)!==null&&o!==void 0?o:r.ref,a=this._values[i];if(a){let l=a.get(s);if(l)return l}else a=this._values[i]=new Map;a.set(s,n);let c=this._scope[i]||(this._scope[i]=[]),u=c.length;return c[u]=r.ref,n.setValue(r,{property:i,itemIndex:u}),n}getValue(t,r){let o=this._values[t];if(o)return o.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,o=>{if(o.scopePath===void 0)throw new Error(`CodeGen: name "${o}" has no value`);return(0,wt._)`${t}${o.scopePath}`})}scopeCode(t=this._values,r,o){return this._reduceValues(t,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},r,o)}_reduceValues(t,r,o={},n){let i=wt.nil;for(let s in t){let a=t[s];if(!a)continue;let c=o[s]=o[s]||new Map;a.forEach(u=>{if(c.has(u))return;c.set(u,rd.Started);let l=r(u);if(l){let d=this.opts.es5?kt.varKinds.var:kt.varKinds.const;i=(0,wt._)`${i}${d} ${u} = ${l};${this.opts._n}`}else if(l=n?.(u))i=(0,wt._)`${i}${l}${this.opts._n}`;else throw new Sg(u);c.set(u,rd.Completed)})}return i}};kt.ValueScope=Tg});var Q=$(ne=>{"use strict";Object.defineProperty(ne,"__esModule",{value:!0});ne.or=ne.and=ne.not=ne.CodeGen=ne.operators=ne.varKinds=ne.ValueScopeName=ne.ValueScope=ne.Scope=ne.Name=ne.regexpCode=ne.stringify=ne.getProperty=ne.nil=ne.strConcat=ne.str=ne._=void 0;var de=ha(),er=Pg(),rn=ha();Object.defineProperty(ne,"_",{enumerable:!0,get:function(){return rn._}});Object.defineProperty(ne,"str",{enumerable:!0,get:function(){return rn.str}});Object.defineProperty(ne,"strConcat",{enumerable:!0,get:function(){return rn.strConcat}});Object.defineProperty(ne,"nil",{enumerable:!0,get:function(){return rn.nil}});Object.defineProperty(ne,"getProperty",{enumerable:!0,get:function(){return rn.getProperty}});Object.defineProperty(ne,"stringify",{enumerable:!0,get:function(){return rn.stringify}});Object.defineProperty(ne,"regexpCode",{enumerable:!0,get:function(){return rn.regexpCode}});Object.defineProperty(ne,"Name",{enumerable:!0,get:function(){return rn.Name}});var cd=Pg();Object.defineProperty(ne,"Scope",{enumerable:!0,get:function(){return cd.Scope}});Object.defineProperty(ne,"ValueScope",{enumerable:!0,get:function(){return cd.ValueScope}});Object.defineProperty(ne,"ValueScopeName",{enumerable:!0,get:function(){return cd.ValueScopeName}});Object.defineProperty(ne,"varKinds",{enumerable:!0,get:function(){return cd.varKinds}});ne.operators={GT:new de._Code(">"),GTE:new de._Code(">="),LT:new de._Code("<"),LTE:new de._Code("<="),EQ:new de._Code("==="),NEQ:new de._Code("!=="),NOT:new de._Code("!"),OR:new de._Code("||"),AND:new de._Code("&&"),ADD:new de._Code("+")};var Or=class{optimizeNodes(){return this}optimizeNames(t,r){return this}},zg=class extends Or{constructor(t,r,o){super(),this.varKind=t,this.name=r,this.rhs=o}render({es5:t,_n:r}){let o=t?er.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${o} ${this.name}${n};`+r}optimizeNames(t,r){if(t[this.name.str])return this.rhs&&(this.rhs=Jo(this.rhs,t,r)),this}get names(){return this.rhs instanceof de._CodeOrName?this.rhs.names:{}}},id=class extends Or{constructor(t,r,o){super(),this.lhs=t,this.rhs=r,this.sideEffects=o}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(!(this.lhs instanceof de.Name&&!t[this.lhs.str]&&!this.sideEffects))return this.rhs=Jo(this.rhs,t,r),this}get names(){let t=this.lhs instanceof de.Name?{}:{...this.lhs.names};return ad(t,this.rhs)}},Eg=class extends id{constructor(t,r,o,n){super(t,o,n),this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}},Ig=class extends Or{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}},Og=class extends Or{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}},jg=class extends Or{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}},Ng=class extends Or{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){return this.code=Jo(this.code,t,r),this}get names(){return this.code instanceof de._CodeOrName?this.code.names:{}}},ga=class extends Or{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce((r,o)=>r+o.render(t),"")}optimizeNodes(){let{nodes:t}=this,r=t.length;for(;r--;){let o=t[r].optimizeNodes();Array.isArray(o)?t.splice(r,1,...o):o?t[r]=o:t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){let{nodes:o}=this,n=o.length;for(;n--;){let i=o[n];i.optimizeNames(t,r)||(VC(t,i.names),o.splice(n,1))}return o.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>Un(t,r.names),{})}},jr=class extends ga{render(t){return"{"+t._n+super.render(t)+"}"+t._n}},Rg=class extends ga{},Ho=class extends jr{};Ho.kind="else";var qn=class e extends jr{constructor(t,r){super(r),this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);return this.else&&(r+="else "+this.else.render(t)),r}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let r=this.else;if(r){let o=r.optimizeNodes();r=this.else=Array.isArray(o)?new Ho(o):o}if(r)return t===!1?r instanceof e?r:r.nodes:this.nodes.length?this:new e(Kk(t),r instanceof e?[r]:r.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,r){var o;if(this.else=(o=this.else)===null||o===void 0?void 0:o.optimizeNames(t,r),!!(super.optimizeNames(t,r)||this.else))return this.condition=Jo(this.condition,t,r),this}get names(){let t=super.names;return ad(t,this.condition),this.else&&Un(t,this.else.names),t}};qn.kind="if";var Mn=class extends jr{};Mn.kind="for";var Cg=class extends Mn{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iteration=Jo(this.iteration,t,r),this}get names(){return Un(super.names,this.iteration.names)}},Ag=class extends Mn{constructor(t,r,o,n){super(),this.varKind=t,this.name=r,this.from=o,this.to=n}render(t){let r=t.es5?er.varKinds.var:this.varKind,{name:o,from:n,to:i}=this;return`for(${r} ${o}=${n}; ${o}<${i}; ${o}++)`+super.render(t)}get names(){let t=ad(super.names,this.from);return ad(t,this.to)}},sd=class extends Mn{constructor(t,r,o,n){super(),this.loop=t,this.varKind=r,this.name=o,this.iterable=n}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(super.optimizeNames(t,r))return this.iterable=Jo(this.iterable,t,r),this}get names(){return Un(super.names,this.iterable.names)}},va=class extends jr{constructor(t,r,o){super(),this.name=t,this.args=r,this.async=o}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}};va.kind="func";var _a=class extends ga{render(t){return"return "+super.render(t)}};_a.kind="return";var Dg=class extends jr{render(t){let r="try"+super.render(t);return this.catch&&(r+=this.catch.render(t)),this.finally&&(r+=this.finally.render(t)),r}optimizeNodes(){var t,r;return super.optimizeNodes(),(t=this.catch)===null||t===void 0||t.optimizeNodes(),(r=this.finally)===null||r===void 0||r.optimizeNodes(),this}optimizeNames(t,r){var o,n;return super.optimizeNames(t,r),(o=this.catch)===null||o===void 0||o.optimizeNames(t,r),(n=this.finally)===null||n===void 0||n.optimizeNames(t,r),this}get names(){let t=super.names;return this.catch&&Un(t,this.catch.names),this.finally&&Un(t,this.finally.names),t}},ya=class extends jr{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};ya.kind="catch";var ba=class extends jr{render(t){return"finally"+super.render(t)}};ba.kind="finally";var qg=class{constructor(t,r={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...r,_n:r.lines?`
10
+ `:""},this._extScope=t,this._scope=new er.Scope({parent:t}),this._nodes=[new Rg]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){let o=this._extScope.value(t,r);return(this._values[o.prefix]||(this._values[o.prefix]=new Set)).add(o),o}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,o,n){let i=this._scope.toName(r);return o!==void 0&&n&&(this._constants[i.str]=o),this._leafNode(new zg(t,i,o)),i}const(t,r,o){return this._def(er.varKinds.const,t,r,o)}let(t,r,o){return this._def(er.varKinds.let,t,r,o)}var(t,r,o){return this._def(er.varKinds.var,t,r,o)}assign(t,r,o){return this._leafNode(new id(t,r,o))}add(t,r){return this._leafNode(new Eg(t,ne.operators.ADD,r))}code(t){return typeof t=="function"?t():t!==de.nil&&this._leafNode(new Ng(t)),this}object(...t){let r=["{"];for(let[o,n]of t)r.length>1&&r.push(","),r.push(o),(o!==n||this.opts.es5)&&(r.push(":"),(0,de.addCodeArg)(r,n));return r.push("}"),new de._Code(r)}if(t,r,o){if(this._blockNode(new qn(t)),r&&o)this.code(r).else().code(o).endIf();else if(r)this.code(r).endIf();else if(o)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new qn(t))}else(){return this._elseNode(new Ho)}endIf(){return this._endBlockNode(qn,Ho)}_for(t,r){return this._blockNode(t),r&&this.code(r).endFor(),this}for(t,r){return this._for(new Cg(t),r)}forRange(t,r,o,n,i=this.opts.es5?er.varKinds.var:er.varKinds.let){let s=this._scope.toName(t);return this._for(new Ag(i,s,r,o),()=>n(s))}forOf(t,r,o,n=er.varKinds.const){let i=this._scope.toName(t);if(this.opts.es5){let s=r instanceof de.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,de._)`${s}.length`,a=>{this.var(i,(0,de._)`${s}[${a}]`),o(i)})}return this._for(new sd("of",n,i,r),()=>o(i))}forIn(t,r,o,n=this.opts.es5?er.varKinds.var:er.varKinds.const){if(this.opts.ownProperties)return this.forOf(t,(0,de._)`Object.keys(${r})`,o);let i=this._scope.toName(t);return this._for(new sd("in",n,i,r),()=>o(i))}endFor(){return this._endBlockNode(Mn)}label(t){return this._leafNode(new Ig(t))}break(t){return this._leafNode(new Og(t))}return(t){let r=new _a;if(this._blockNode(r),this.code(t),r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(_a)}try(t,r,o){if(!r&&!o)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new Dg;if(this._blockNode(n),this.code(t),r){let i=this.name("e");this._currNode=n.catch=new ya(i),r(i)}return o&&(this._currNode=n.finally=new ba,this.code(o)),this._endBlockNode(ya,ba)}throw(t){return this._leafNode(new jg(t))}block(t,r){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(r),this}endBlock(t){let r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");let o=this._nodes.length-r;if(o<0||t!==void 0&&o!==t)throw new Error(`CodeGen: wrong number of nodes: ${o} vs ${t} expected`);return this._nodes.length=r,this}func(t,r=de.nil,o,n){return this._blockNode(new va(t,r,o)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(va)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,r){let o=this._currNode;if(o instanceof t||r&&o instanceof r)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){let r=this._currNode;if(!(r instanceof qn))throw new Error('CodeGen: "else" without "if"');return this._currNode=r.else=t,this}get _root(){return this._nodes[0]}get _currNode(){let t=this._nodes;return t[t.length-1]}set _currNode(t){let r=this._nodes;r[r.length-1]=t}};ne.CodeGen=qg;function Un(e,t){for(let r in t)e[r]=(e[r]||0)+(t[r]||0);return e}function ad(e,t){return t instanceof de._CodeOrName?Un(e,t.names):e}function Jo(e,t,r){if(e instanceof de.Name)return o(e);if(!n(e))return e;return new de._Code(e._items.reduce((i,s)=>(s instanceof de.Name&&(s=o(s)),s instanceof de._Code?i.push(...s._items):i.push(s),i),[]));function o(i){let s=r[i.str];return s===void 0||t[i.str]!==1?i:(delete t[i.str],s)}function n(i){return i instanceof de._Code&&i._items.some(s=>s instanceof de.Name&&t[s.str]===1&&r[s.str]!==void 0)}}function VC(e,t){for(let r in t)e[r]=(e[r]||0)-(t[r]||0)}function Kk(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,de._)`!${Mg(e)}`}ne.not=Kk;var LC=Hk(ne.operators.AND);function FC(...e){return e.reduce(LC)}ne.and=FC;var GC=Hk(ne.operators.OR);function WC(...e){return e.reduce(GC)}ne.or=WC;function Hk(e){return(t,r)=>t===de.nil?r:r===de.nil?t:(0,de._)`${Mg(t)} ${e} ${Mg(r)}`}function Mg(e){return e instanceof de.Name?e:(0,de._)`(${e})`}});var ve=$(se=>{"use strict";Object.defineProperty(se,"__esModule",{value:!0});se.checkStrictMode=se.getErrorPath=se.Type=se.useFunc=se.setEvaluated=se.evaluatedPropsToName=se.mergeEvaluated=se.eachItem=se.unescapeJsonPointer=se.escapeJsonPointer=se.escapeFragment=se.unescapeFragment=se.schemaRefOrVal=se.schemaHasRulesButRef=se.schemaHasRules=se.checkUnknownRules=se.alwaysValidSchema=se.toHash=void 0;var Pe=Q(),KC=ha();function HC(e){let t={};for(let r of e)t[r]=!0;return t}se.toHash=HC;function JC(e,t){return typeof t=="boolean"?t:Object.keys(t).length===0?!0:(Yk(e,t),!Xk(t,e.self.RULES.all))}se.alwaysValidSchema=JC;function Yk(e,t=e.schema){let{opts:r,self:o}=e;if(!r.strictSchema||typeof t=="boolean")return;let n=o.RULES.keywords;for(let i in t)n[i]||tx(e,`unknown keyword: "${i}"`)}se.checkUnknownRules=Yk;function Xk(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(t[r])return!0;return!1}se.schemaHasRules=Xk;function BC(e,t){if(typeof e=="boolean")return!e;for(let r in e)if(r!=="$ref"&&t.all[r])return!0;return!1}se.schemaHasRulesButRef=BC;function YC({topSchemaRef:e,schemaPath:t},r,o,n){if(!n){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Pe._)`${r}`}return(0,Pe._)`${e}${t}${(0,Pe.getProperty)(o)}`}se.schemaRefOrVal=YC;function XC(e){return Qk(decodeURIComponent(e))}se.unescapeFragment=XC;function QC(e){return encodeURIComponent(Zg(e))}se.escapeFragment=QC;function Zg(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}se.escapeJsonPointer=Zg;function Qk(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}se.unescapeJsonPointer=Qk;function eA(e,t){if(Array.isArray(e))for(let r of e)t(r);else t(e)}se.eachItem=eA;function Jk({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:o}){return(n,i,s,a)=>{let c=s===void 0?i:s instanceof Pe.Name?(i instanceof Pe.Name?e(n,i,s):t(n,i,s),s):i instanceof Pe.Name?(t(n,s,i),i):r(i,s);return a===Pe.Name&&!(c instanceof Pe.Name)?o(n,c):c}}se.mergeEvaluated={props:Jk({mergeNames:(e,t,r)=>e.if((0,Pe._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Pe._)`${t} === true`,()=>e.assign(r,!0),()=>e.assign(r,(0,Pe._)`${r} || {}`).code((0,Pe._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Pe._)`${r} !== true`,()=>{t===!0?e.assign(r,!0):(e.assign(r,(0,Pe._)`${r} || {}`),Vg(e,r,t))}),mergeValues:(e,t)=>e===!0?!0:{...e,...t},resultToName:ex}),items:Jk({mergeNames:(e,t,r)=>e.if((0,Pe._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Pe._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Pe._)`${r} !== true`,()=>e.assign(r,t===!0?!0:(0,Pe._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===!0?!0:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function ex(e,t){if(t===!0)return e.var("props",!0);let r=e.var("props",(0,Pe._)`{}`);return t!==void 0&&Vg(e,r,t),r}se.evaluatedPropsToName=ex;function Vg(e,t,r){Object.keys(r).forEach(o=>e.assign((0,Pe._)`${t}${(0,Pe.getProperty)(o)}`,!0))}se.setEvaluated=Vg;var Bk={};function tA(e,t){return e.scopeValue("func",{ref:t,code:Bk[t.code]||(Bk[t.code]=new KC._Code(t.code))})}se.useFunc=tA;var Ug;(function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"})(Ug||(se.Type=Ug={}));function rA(e,t,r){if(e instanceof Pe.Name){let o=t===Ug.Num;return r?o?(0,Pe._)`"[" + ${e} + "]"`:(0,Pe._)`"['" + ${e} + "']"`:o?(0,Pe._)`"/" + ${e}`:(0,Pe._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Pe.getProperty)(e).toString():"/"+Zg(e)}se.getErrorPath=rA;function tx(e,t,r=e.opts.strictSchema){if(r){if(t=`strict mode: ${t}`,r===!0)throw new Error(t);e.self.logger.warn(t)}}se.checkStrictMode=tx});var Nr=$(Lg=>{"use strict";Object.defineProperty(Lg,"__esModule",{value:!0});var it=Q(),nA={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")};Lg.default=nA});var $a=$(st=>{"use strict";Object.defineProperty(st,"__esModule",{value:!0});st.extendErrors=st.resetErrorsCount=st.reportExtraError=st.reportError=st.keyword$DataError=st.keywordError=void 0;var fe=Q(),ud=ve(),mt=Nr();st.keywordError={message:({keyword:e})=>(0,fe.str)`must pass "${e}" keyword validation`};st.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,fe.str)`"${e}" keyword must be ${t} ($data)`:(0,fe.str)`"${e}" keyword is invalid ($data)`};function oA(e,t=st.keywordError,r,o){let{it:n}=e,{gen:i,compositeRule:s,allErrors:a}=n,c=ox(e,t,r);o??(s||a)?rx(i,c):nx(n,(0,fe._)`[${c}]`)}st.reportError=oA;function iA(e,t=st.keywordError,r){let{it:o}=e,{gen:n,compositeRule:i,allErrors:s}=o,a=ox(e,t,r);rx(n,a),i||s||nx(o,mt.default.vErrors)}st.reportExtraError=iA;function sA(e,t){e.assign(mt.default.errors,t),e.if((0,fe._)`${mt.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,fe._)`${mt.default.vErrors}.length`,t),()=>e.assign(mt.default.vErrors,null)))}st.resetErrorsCount=sA;function aA({gen:e,keyword:t,schemaValue:r,data:o,errsCount:n,it:i}){if(n===void 0)throw new Error("ajv implementation error");let s=e.name("err");e.forRange("i",n,mt.default.errors,a=>{e.const(s,(0,fe._)`${mt.default.vErrors}[${a}]`),e.if((0,fe._)`${s}.instancePath === undefined`,()=>e.assign((0,fe._)`${s}.instancePath`,(0,fe.strConcat)(mt.default.instancePath,i.errorPath))),e.assign((0,fe._)`${s}.schemaPath`,(0,fe.str)`${i.errSchemaPath}/${t}`),i.opts.verbose&&(e.assign((0,fe._)`${s}.schema`,r),e.assign((0,fe._)`${s}.data`,o))})}st.extendErrors=aA;function rx(e,t){let r=e.const("err",t);e.if((0,fe._)`${mt.default.vErrors} === null`,()=>e.assign(mt.default.vErrors,(0,fe._)`[${r}]`),(0,fe._)`${mt.default.vErrors}.push(${r})`),e.code((0,fe._)`${mt.default.errors}++`)}function nx(e,t){let{gen:r,validateName:o,schemaEnv:n}=e;n.$async?r.throw((0,fe._)`new ${e.ValidationError}(${t})`):(r.assign((0,fe._)`${o}.errors`,t),r.return(!1))}var Zn={keyword:new fe.Name("keyword"),schemaPath:new fe.Name("schemaPath"),params:new fe.Name("params"),propertyName:new fe.Name("propertyName"),message:new fe.Name("message"),schema:new fe.Name("schema"),parentSchema:new fe.Name("parentSchema")};function ox(e,t,r){let{createErrors:o}=e.it;return o===!1?(0,fe._)`{}`:cA(e,t,r)}function cA(e,t,r={}){let{gen:o,it:n}=e,i=[uA(n,r),lA(e,r)];return dA(e,t,i),o.object(...i)}function uA({errorPath:e},{instancePath:t}){let r=t?(0,fe.str)`${e}${(0,ud.getErrorPath)(t,ud.Type.Str)}`:e;return[mt.default.instancePath,(0,fe.strConcat)(mt.default.instancePath,r)]}function lA({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:o}){let n=o?t:(0,fe.str)`${t}/${e}`;return r&&(n=(0,fe.str)`${n}${(0,ud.getErrorPath)(r,ud.Type.Str)}`),[Zn.schemaPath,n]}function dA(e,{params:t,message:r},o){let{keyword:n,data:i,schemaValue:s,it:a}=e,{opts:c,propertyName:u,topSchemaRef:l,schemaPath:d}=a;o.push([Zn.keyword,n],[Zn.params,typeof t=="function"?t(e):t||(0,fe._)`{}`]),c.messages&&o.push([Zn.message,typeof r=="function"?r(e):r]),c.verbose&&o.push([Zn.schema,s],[Zn.parentSchema,(0,fe._)`${l}${d}`],[mt.default.data,i]),u&&o.push([Zn.propertyName,u])}});var sx=$(Bo=>{"use strict";Object.defineProperty(Bo,"__esModule",{value:!0});Bo.boolOrEmptySchema=Bo.topBoolOrEmptySchema=void 0;var pA=$a(),fA=Q(),mA=Nr(),hA={message:"boolean schema is false"};function gA(e){let{gen:t,schema:r,validateName:o}=e;r===!1?ix(e,!1):typeof r=="object"&&r.$async===!0?t.return(mA.default.data):(t.assign((0,fA._)`${o}.errors`,null),t.return(!0))}Bo.topBoolOrEmptySchema=gA;function vA(e,t){let{gen:r,schema:o}=e;o===!1?(r.var(t,!1),ix(e)):r.var(t,!0)}Bo.boolOrEmptySchema=vA;function ix(e,t){let{gen:r,data:o}=e,n={gen:r,keyword:"false schema",data:o,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,pA.reportError)(n,hA,void 0,t)}});var Fg=$(Yo=>{"use strict";Object.defineProperty(Yo,"__esModule",{value:!0});Yo.getRules=Yo.isJSONType=void 0;var _A=["string","number","integer","boolean","null","object","array"],yA=new Set(_A);function bA(e){return typeof e=="string"&&yA.has(e)}Yo.isJSONType=bA;function $A(){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:{}}}Yo.getRules=$A});var Gg=$(nn=>{"use strict";Object.defineProperty(nn,"__esModule",{value:!0});nn.shouldUseRule=nn.shouldUseGroup=nn.schemaHasRulesForType=void 0;function wA({schema:e,self:t},r){let o=t.RULES.types[r];return o&&o!==!0&&ax(e,o)}nn.schemaHasRulesForType=wA;function ax(e,t){return t.rules.some(r=>cx(e,r))}nn.shouldUseGroup=ax;function cx(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(o=>e[o]!==void 0))}nn.shouldUseRule=cx});var wa=$(at=>{"use strict";Object.defineProperty(at,"__esModule",{value:!0});at.reportTypeError=at.checkDataTypes=at.checkDataType=at.coerceAndCheckDataType=at.getJSONTypes=at.getSchemaTypes=at.DataType=void 0;var kA=Fg(),xA=Gg(),SA=$a(),Y=Q(),ux=ve(),Xo;(function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"})(Xo||(at.DataType=Xo={}));function TA(e){let t=lx(e.type);if(t.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&t.push("null")}return t}at.getSchemaTypes=TA;function lx(e){let t=Array.isArray(e)?e:e?[e]:[];if(t.every(kA.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}at.getJSONTypes=lx;function PA(e,t){let{gen:r,data:o,opts:n}=e,i=zA(t,n.coerceTypes),s=t.length>0&&!(i.length===0&&t.length===1&&(0,xA.schemaHasRulesForType)(e,t[0]));if(s){let a=Kg(t,o,n.strictNumbers,Xo.Wrong);r.if(a,()=>{i.length?EA(e,t,i):Hg(e)})}return s}at.coerceAndCheckDataType=PA;var dx=new Set(["string","number","integer","boolean","null"]);function zA(e,t){return t?e.filter(r=>dx.has(r)||t==="array"&&r==="array"):[]}function EA(e,t,r){let{gen:o,data:n,opts:i}=e,s=o.let("dataType",(0,Y._)`typeof ${n}`),a=o.let("coerced",(0,Y._)`undefined`);i.coerceTypes==="array"&&o.if((0,Y._)`${s} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>o.assign(n,(0,Y._)`${n}[0]`).assign(s,(0,Y._)`typeof ${n}`).if(Kg(t,n,i.strictNumbers),()=>o.assign(a,n))),o.if((0,Y._)`${a} !== undefined`);for(let u of r)(dx.has(u)||u==="array"&&i.coerceTypes==="array")&&c(u);o.else(),Hg(e),o.endIf(),o.if((0,Y._)`${a} !== undefined`,()=>{o.assign(n,a),IA(e,a)});function c(u){switch(u){case"string":o.elseIf((0,Y._)`${s} == "number" || ${s} == "boolean"`).assign(a,(0,Y._)`"" + ${n}`).elseIf((0,Y._)`${n} === null`).assign(a,(0,Y._)`""`);return;case"number":o.elseIf((0,Y._)`${s} == "boolean" || ${n} === null
11
11
  || (${s} == "string" && ${n} && ${n} == +${n})`).assign(a,(0,Y._)`+${n}`);return;case"integer":o.elseIf((0,Y._)`${s} === "boolean" || ${n} === null
12
12
  || (${s} === "string" && ${n} && ${n} == +${n} && !(${n} % 1))`).assign(a,(0,Y._)`+${n}`);return;case"boolean":o.elseIf((0,Y._)`${n} === "false" || ${n} === 0 || ${n} === null`).assign(a,!1).elseIf((0,Y._)`${n} === "true" || ${n} === 1`).assign(a,!0);return;case"null":o.elseIf((0,Y._)`${n} === "" || ${n} === 0 || ${n} === false`),o.assign(a,null);return;case"array":o.elseIf((0,Y._)`${s} === "string" || ${s} === "number"
13
- || ${s} === "boolean" || ${n} === null`).assign(a,(0,Y._)`[${n}]`)}}}function wA({gen:e,parentData:t,parentDataProperty:r},o){e.if((0,Y._)`${t} !== undefined`,()=>e.assign((0,Y._)`${t}[${r}]`,o))}function Gg(e,t,r,o=Yo.Correct){let n=o===Yo.Correct?Y.operators.EQ:Y.operators.NEQ,i;switch(e){case"null":return(0,Y._)`${t} ${n} null`;case"array":i=(0,Y._)`Array.isArray(${t})`;break;case"object":i=(0,Y._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s((0,Y._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return(0,Y._)`typeof ${t} ${n} ${e}`}return o===Yo.Correct?i:(0,Y.not)(i);function s(a=Y.nil){return(0,Y.and)((0,Y._)`typeof ${t} == "number"`,a,r?(0,Y._)`isFinite(${t})`:Y.nil)}}st.checkDataType=Gg;function Wg(e,t,r,o){if(e.length===1)return Gg(e[0],t,r,o);let n,i=(0,cx.toHash)(e);if(i.array&&i.object){let s=(0,Y._)`typeof ${t} != "object"`;n=i.null?s:(0,Y._)`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else n=Y.nil;i.number&&delete i.integer;for(let s in i)n=(0,Y.and)(n,Gg(s,t,r,o));return n}st.checkDataTypes=Wg;var kA={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,Y._)`{type: ${e}}`:(0,Y._)`{type: ${t}}`};function Kg(e){let t=xA(e);(0,vA.reportError)(t,kA)}st.reportTypeError=Kg;function xA(e){let{gen:t,data:r,schema:o}=e,n=(0,cx.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:r,schema:o.type,schemaCode:n,schemaValue:n,parentSchema:o,params:{},it:e}}});var px=b(cd=>{"use strict";Object.defineProperty(cd,"__esModule",{value:!0});cd.assignDefaults=void 0;var Xo=Q(),SA=ve();function TA(e,t){let{properties:r,items:o}=e.schema;if(t==="object"&&r)for(let n in r)dx(e,n,r[n].default);else t==="array"&&Array.isArray(o)&&o.forEach((n,i)=>dx(e,i,n.default))}cd.assignDefaults=TA;function dx(e,t,r){let{gen:o,compositeRule:n,data:i,opts:s}=e;if(r===void 0)return;let a=(0,Xo._)`${i}${(0,Xo.getProperty)(t)}`;if(n){(0,SA.checkStrictMode)(e,`default is ignored for: ${a}`);return}let c=(0,Xo._)`${a} === undefined`;s.useDefaults==="empty"&&(c=(0,Xo._)`${c} || ${a} === null || ${a} === ""`),o.if(c,(0,Xo._)`${a} = ${(0,Xo.stringify)(r)}`)}});var Mt=b(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.validateUnion=Se.validateArray=Se.usePattern=Se.callValidateCode=Se.schemaProperties=Se.allSchemaProperties=Se.noPropertyInData=Se.propertyInData=Se.isOwnProperty=Se.hasPropFunc=Se.reportMissingProp=Se.checkMissingProp=Se.checkReportMissingProp=void 0;var Ce=Q(),Hg=ve(),on=Or(),PA=ve();function zA(e,t){let{gen:r,data:o,it:n}=e;r.if(Bg(r,o,t,n.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Ce._)`${t}`},!0),e.error()})}Se.checkReportMissingProp=zA;function EA({gen:e,data:t,it:{opts:r}},o,n){return(0,Ce.or)(...o.map(i=>(0,Ce.and)(Bg(e,t,i,r.ownProperties),(0,Ce._)`${n} = ${i}`)))}Se.checkMissingProp=EA;function IA(e,t){e.setParams({missingProperty:t},!0),e.error()}Se.reportMissingProp=IA;function fx(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Ce._)`Object.prototype.hasOwnProperty`})}Se.hasPropFunc=fx;function Jg(e,t,r){return(0,Ce._)`${fx(e)}.call(${t}, ${r})`}Se.isOwnProperty=Jg;function jA(e,t,r,o){let n=(0,Ce._)`${t}${(0,Ce.getProperty)(r)} !== undefined`;return o?(0,Ce._)`${n} && ${Jg(e,t,r)}`:n}Se.propertyInData=jA;function Bg(e,t,r,o){let n=(0,Ce._)`${t}${(0,Ce.getProperty)(r)} === undefined`;return o?(0,Ce.or)(n,(0,Ce.not)(Jg(e,t,r))):n}Se.noPropertyInData=Bg;function mx(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Se.allSchemaProperties=mx;function OA(e,t){return mx(t).filter(r=>!(0,Hg.alwaysValidSchema)(e,t[r]))}Se.schemaProperties=OA;function NA({schemaCode:e,data:t,it:{gen:r,topSchemaRef:o,schemaPath:n,errorPath:i},it:s},a,c,u){let l=u?(0,Ce._)`${e}, ${t}, ${o}${n}`:t,d=[[on.default.instancePath,(0,Ce.strConcat)(on.default.instancePath,i)],[on.default.parentData,s.parentData],[on.default.parentDataProperty,s.parentDataProperty],[on.default.rootData,on.default.rootData]];s.opts.dynamicRef&&d.push([on.default.dynamicAnchors,on.default.dynamicAnchors]);let h=(0,Ce._)`${l}, ${r.object(...d)}`;return c!==Ce.nil?(0,Ce._)`${a}.call(${c}, ${h})`:(0,Ce._)`${a}(${h})`}Se.callValidateCode=NA;var RA=(0,Ce._)`new RegExp`;function CA({gen:e,it:{opts:t}},r){let o=t.unicodeRegExp?"u":"",{regExp:n}=t.code,i=n(r,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Ce._)`${n.code==="new RegExp"?RA:(0,PA.useFunc)(e,n)}(${r}, ${o})`})}Se.usePattern=CA;function AA(e){let{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.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",(0,Ce._)`${r}.length`);t.forRange("i",0,c,u=>{e.subschema({keyword:o,dataProp:u,dataPropType:Hg.Type.Num},i),t.if((0,Ce.not)(i),a)})}}Se.validateArray=AA;function DA(e){let{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(c=>(0,Hg.alwaysValidSchema)(n,c))&&!n.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:o,schemaProp:u,compositeRule:!0},a);t.assign(s,(0,Ce._)`${s} || ${a}`),e.mergeValidEvaluated(l,a)||t.if((0,Ce.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}Se.validateUnion=DA});var vx=b(fr=>{"use strict";Object.defineProperty(fr,"__esModule",{value:!0});fr.validateKeywordUsage=fr.validSchemaType=fr.funcKeywordCode=fr.macroKeywordCode=void 0;var ft=Q(),Ln=Or(),qA=Mt(),MA=ya();function UA(e,t){let{gen:r,keyword:o,schema:n,parentSchema:i,it:s}=e,a=t.macro.call(s.self,n,i,s),c=gx(r,o,a);s.opts.validateSchema!==!1&&s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:ft.nil,errSchemaPath:`${s.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}fr.macroKeywordCode=UA;function ZA(e,t){var r;let{gen:o,keyword:n,schema:i,parentSchema:s,$data:a,it:c}=e;VA(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=gx(o,n,u),d=o.let("valid");e.block$data(d,h),e.ok((r=t.valid)!==null&&r!==void 0?r:d);function h(){if(t.errors===!1)f(),t.modifying&&hx(e),g(()=>e.error());else{let y=t.async?m():p();t.modifying&&hx(e),g(()=>LA(e,y))}}function m(){let y=o.let("ruleErrs",null);return o.try(()=>f((0,ft._)`await `),w=>o.assign(d,!1).if((0,ft._)`${w} instanceof ${c.ValidationError}`,()=>o.assign(y,(0,ft._)`${w}.errors`),()=>o.throw(w))),y}function p(){let y=(0,ft._)`${l}.errors`;return o.assign(y,null),f(ft.nil),y}function f(y=t.async?(0,ft._)`await `:ft.nil){let w=c.opts.passContext?Ln.default.this:Ln.default.self,k=!("compile"in t&&!a||t.schema===!1);o.assign(d,(0,ft._)`${y}${(0,qA.callValidateCode)(e,l,w,k)}`,t.modifying)}function g(y){var w;o.if((0,ft.not)((w=t.valid)!==null&&w!==void 0?w:d),y)}}fr.funcKeywordCode=ZA;function hx(e){let{gen:t,data:r,it:o}=e;t.if(o.parentData,()=>t.assign(r,(0,ft._)`${o.parentData}[${o.parentDataProperty}]`))}function LA(e,t){let{gen:r}=e;r.if((0,ft._)`Array.isArray(${t})`,()=>{r.assign(Ln.default.vErrors,(0,ft._)`${Ln.default.vErrors} === null ? ${t} : ${Ln.default.vErrors}.concat(${t})`).assign(Ln.default.errors,(0,ft._)`${Ln.default.vErrors}.length`),(0,MA.extendErrors)(e)},()=>e.error())}function VA({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function gx(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,ft.stringify)(r)})}function FA(e,t,r=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||r&&typeof e>"u")}fr.validSchemaType=FA;function GA({schema:e,opts:t,self:r,errSchemaPath:o},n,i){if(Array.isArray(n.keyword)?!n.keyword.includes(i):n.keyword!==i)throw new Error("ajv implementation error");let s=n.dependencies;if(s?.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(n.validateSchema&&!n.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+r.errorsText(n.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw new Error(c)}}fr.validateKeywordUsage=GA});var yx=b(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.extendSubschemaMode=sn.extendSubschemaData=sn.getSubschema=void 0;var mr=Q(),_x=ve();function WA(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&o!==void 0)throw new 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:(0,mr._)`${e.schemaPath}${(0,mr.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:(0,mr._)`${e.schemaPath}${(0,mr.getProperty)(t)}${(0,mr.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,_x.escapeFragment)(r)}`}}if(o!==void 0){if(n===void 0||i===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:s,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}sn.getSubschema=WA;function KA(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:s}){if(n!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:d}=t,h=a.let("data",(0,mr._)`${t.data}${(0,mr.getProperty)(r)}`,!0);c(h),e.errorPath=(0,mr.str)`${u}${(0,_x.getErrorPath)(r,o,d.jsPropertySyntax)}`,e.parentDataProperty=(0,mr._)`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(n!==void 0){let u=n instanceof mr.Name?n:a.let("data",n,!0);c(u),s!==void 0&&(e.propertyName=s)}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]}}sn.extendSubschemaData=KA;function HA(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:o,createErrors:n,allErrors:i}){o!==void 0&&(e.compositeRule=o),n!==void 0&&(e.createErrors=n),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}sn.extendSubschemaMode=HA});var bx=b((hK,$x)=>{"use strict";var an=$x.exports=function(e,t,r){typeof t=="function"&&(r=t,t={}),r=t.cb||r;var o=typeof r=="function"?r:r.pre||function(){},n=r.post||function(){};ud(t,o,n,e,"",e)};an.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};an.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};an.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};an.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 ud(e,t,r,o,n,i,s,a,c,u){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,n,i,s,a,c,u);for(var l in o){var d=o[l];if(Array.isArray(d)){if(l in an.arrayKeywords)for(var h=0;h<d.length;h++)ud(e,t,r,d[h],n+"/"+l+"/"+h,i,n,l,o,h)}else if(l in an.propsKeywords){if(d&&typeof d=="object")for(var m in d)ud(e,t,r,d[m],n+"/"+l+"/"+JA(m),i,n,l,o,m)}else(l in an.keywords||e.allKeys&&!(l in an.skipKeywords))&&ud(e,t,r,d,n+"/"+l,i,n,l,o)}r(o,n,i,s,a,c,u)}}function JA(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var ba=b(wt=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.getSchemaRefs=wt.resolveUrl=wt.normalizeId=wt._getFullPath=wt.getFullPath=wt.inlineRef=void 0;var BA=ve(),YA=Ws(),XA=bx(),QA=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function eD(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Yg(e):t?wx(e)<=t:!1}wt.inlineRef=eD;var tD=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Yg(e){for(let t in e){if(tD.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(Yg)||typeof r=="object"&&Yg(r))return!0}return!1}function wx(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,!QA.has(r)&&(typeof e[r]=="object"&&(0,BA.eachItem)(e[r],o=>t+=wx(o)),t===1/0))return 1/0}return t}function kx(e,t="",r){r!==!1&&(t=Qo(t));let o=e.parse(t);return xx(e,o)}wt.getFullPath=kx;function xx(e,t){return e.serialize(t).split("#")[0]+"#"}wt._getFullPath=xx;var rD=/#\/?$/;function Qo(e){return e?e.replace(rD,""):""}wt.normalizeId=Qo;function nD(e,t,r){return r=Qo(r),e.resolve(t,r)}wt.resolveUrl=nD;var oD=/^[a-z_][-a-z0-9._]*$/i;function iD(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:o}=this.opts,n=Qo(e[r]||t),i={"":n},s=kx(o,n,!1),a={},c=new Set;return XA(e,{allKeys:!0},(d,h,m,p)=>{if(p===void 0)return;let f=s+h,g=i[p];typeof d[r]=="string"&&(g=y.call(this,d[r])),w.call(this,d.$anchor),w.call(this,d.$dynamicAnchor),i[h]=g;function y(k){let E=this.opts.uriResolver.resolve;if(k=Qo(g?E(g,k):k),c.has(k))throw l(k);c.add(k);let P=this.refs[k];return typeof P=="string"&&(P=this.refs[P]),typeof P=="object"?u(d,P.schema,k):k!==Qo(f)&&(k[0]==="#"?(u(d,a[k],k),a[k]=d):this.refs[k]=f),k}function w(k){if(typeof k=="string"){if(!oD.test(k))throw new Error(`invalid anchor "${k}"`);y.call(this,`#${k}`)}}}),a;function u(d,h,m){if(h!==void 0&&!YA(d,h))throw l(m)}function l(d){return new Error(`reference "${d}" resolves to more than one schema`)}}wt.getSchemaRefs=iD});var xa=b(cn=>{"use strict";Object.defineProperty(cn,"__esModule",{value:!0});cn.getData=cn.KeywordCxt=cn.validateFunctionCode=void 0;var Ex=ix(),Sx=$a(),Qg=Fg(),ld=$a(),sD=px(),ka=vx(),Xg=yx(),L=Q(),H=Or(),aD=ba(),Nr=ve(),wa=ya();function cD(e){if(Ox(e)&&(Nx(e),jx(e))){dD(e);return}Ix(e,()=>(0,Ex.topBoolOrEmptySchema)(e))}cn.validateFunctionCode=cD;function Ix({gen:e,validateName:t,schema:r,schemaEnv:o,opts:n},i){n.code.es5?e.func(t,(0,L._)`${H.default.data}, ${H.default.valCxt}`,o.$async,()=>{e.code((0,L._)`"use strict"; ${Tx(r,n)}`),lD(e,n),e.code(i)}):e.func(t,(0,L._)`${H.default.data}, ${uD(n)}`,o.$async,()=>e.code(Tx(r,n)).code(i))}function uD(e){return(0,L._)`{${H.default.instancePath}="", ${H.default.parentData}, ${H.default.parentDataProperty}, ${H.default.rootData}=${H.default.data}${e.dynamicRef?(0,L._)`, ${H.default.dynamicAnchors}={}`:L.nil}}={}`}function lD(e,t){e.if(H.default.valCxt,()=>{e.var(H.default.instancePath,(0,L._)`${H.default.valCxt}.${H.default.instancePath}`),e.var(H.default.parentData,(0,L._)`${H.default.valCxt}.${H.default.parentData}`),e.var(H.default.parentDataProperty,(0,L._)`${H.default.valCxt}.${H.default.parentDataProperty}`),e.var(H.default.rootData,(0,L._)`${H.default.valCxt}.${H.default.rootData}`),t.dynamicRef&&e.var(H.default.dynamicAnchors,(0,L._)`${H.default.valCxt}.${H.default.dynamicAnchors}`)},()=>{e.var(H.default.instancePath,(0,L._)`""`),e.var(H.default.parentData,(0,L._)`undefined`),e.var(H.default.parentDataProperty,(0,L._)`undefined`),e.var(H.default.rootData,H.default.data),t.dynamicRef&&e.var(H.default.dynamicAnchors,(0,L._)`{}`)})}function dD(e){let{schema:t,opts:r,gen:o}=e;Ix(e,()=>{r.$comment&&t.$comment&&Cx(e),gD(e),o.let(H.default.vErrors,null),o.let(H.default.errors,0),r.unevaluated&&pD(e),Rx(e),yD(e)})}function pD(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,L._)`${r}.evaluated`),t.if((0,L._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,L._)`${e.evaluated}.props`,(0,L._)`undefined`)),t.if((0,L._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,L._)`${e.evaluated}.items`,(0,L._)`undefined`))}function Tx(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,L._)`/*# sourceURL=${r} */`:L.nil}function fD(e,t){if(Ox(e)&&(Nx(e),jx(e))){mD(e,t);return}(0,Ex.boolOrEmptySchema)(e,t)}function jx({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 Ox(e){return typeof e.schema!="boolean"}function mD(e,t){let{schema:r,gen:o,opts:n}=e;n.$comment&&r.$comment&&Cx(e),vD(e),_D(e);let i=o.const("_errs",H.default.errors);Rx(e,i),o.var(t,(0,L._)`${i} === ${H.default.errors}`)}function Nx(e){(0,Nr.checkUnknownRules)(e),hD(e)}function Rx(e,t){if(e.opts.jtd)return Px(e,[],!1,t);let r=(0,Sx.getSchemaTypes)(e.schema),o=(0,Sx.coerceAndCheckDataType)(e,r);Px(e,r,!o,t)}function hD(e){let{schema:t,errSchemaPath:r,opts:o,self:n}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,Nr.schemaHasRulesButRef)(t,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function gD(e){let{schema:t,opts:r}=e;t.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Nr.checkStrictMode)(e,"default is ignored in the schema root")}function vD(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,aD.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function _D(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function Cx({gen:e,schemaEnv:t,schema:r,errSchemaPath:o,opts:n}){let i=r.$comment;if(n.$comment===!0)e.code((0,L._)`${H.default.self}.logger.log(${i})`);else if(typeof n.$comment=="function"){let s=(0,L.str)`${o}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,L._)`${H.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function yD(e){let{gen:t,schemaEnv:r,validateName:o,ValidationError:n,opts:i}=e;r.$async?t.if((0,L._)`${H.default.errors} === 0`,()=>t.return(H.default.data),()=>t.throw((0,L._)`new ${n}(${H.default.vErrors})`)):(t.assign((0,L._)`${o}.errors`,H.default.vErrors),i.unevaluated&&$D(e),t.return((0,L._)`${H.default.errors} === 0`))}function $D({gen:e,evaluated:t,props:r,items:o}){r instanceof L.Name&&e.assign((0,L._)`${t}.props`,r),o instanceof L.Name&&e.assign((0,L._)`${t}.items`,o)}function Px(e,t,r,o){let{gen:n,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,Nr.schemaHasRulesButRef)(i,l))){n.block(()=>Dx(e,"$ref",l.all.$ref.definition));return}c.jtd||bD(e,t),n.block(()=>{for(let h of l.rules)d(h);d(l.post)});function d(h){(0,Qg.shouldUseGroup)(i,h)&&(h.type?(n.if((0,ld.checkDataType)(h.type,s,c.strictNumbers)),zx(e,h),t.length===1&&t[0]===h.type&&r&&(n.else(),(0,ld.reportTypeError)(e)),n.endIf()):zx(e,h),a||n.if((0,L._)`${H.default.errors} === ${o||0}`))}}function zx(e,t){let{gen:r,schema:o,opts:{useDefaults:n}}=e;n&&(0,sD.assignDefaults)(e,t.type),r.block(()=>{for(let i of t.rules)(0,Qg.shouldUseRule)(o,i)&&Dx(e,i.keyword,i.definition,t.type)})}function bD(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(wD(e,t),e.opts.allowUnionTypes||kD(e,t),xD(e,e.dataTypes))}function wD(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{Ax(e.dataTypes,r)||ev(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),TD(e,t)}}function kD(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&ev(e,"use allowUnionTypes to allow union type keyword")}function xD(e,t){let r=e.self.RULES.all;for(let o in r){let n=r[o];if(typeof n=="object"&&(0,Qg.shouldUseRule)(e.schema,n)){let{type:i}=n.definition;i.length&&!i.some(s=>SD(t,s))&&ev(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function SD(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Ax(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function TD(e,t){let r=[];for(let o of e.dataTypes)Ax(t,o)?r.push(o):t.includes("integer")&&o==="number"&&r.push("integer");e.dataTypes=r}function ev(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,Nr.checkStrictMode)(e,t,e.opts.strictTypes)}var dd=class{constructor(t,r,o){if((0,ka.validateKeywordUsage)(t,r,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Nr.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=r.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=r,this.$data)this.schemaCode=t.gen.const("vSchema",qx(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,ka.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=t.gen.const("_errs",H.default.errors))}result(t,r,o){this.failResult((0,L.not)(t),r,o)}failResult(t,r,o){this.gen.if(t),o?o():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,r){this.failResult((0,L.not)(t),void 0,r)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:r}=this;this.fail((0,L._)`${r} !== undefined && (${(0,L.or)(this.invalid$data(),t)})`)}error(t,r,o){if(r){this.setParams(r),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,r){(t?wa.reportExtraError:wa.reportError)(this,this.def.error,r)}$dataError(){(0,wa.reportError)(this,this.def.$dataError||wa.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,wa.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,r){r?Object.assign(this.params,t):this.params=t}block$data(t,r,o=L.nil){this.gen.block(()=>{this.check$data(t,o),r()})}check$data(t=L.nil,r=L.nil){if(!this.$data)return;let{gen:o,schemaCode:n,schemaType:i,def:s}=this;o.if((0,L.or)((0,L._)`${n} === undefined`,r)),t!==L.nil&&o.assign(t,!0),(i.length||s.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==L.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:r,schemaType:o,def:n,it:i}=this;return(0,L.or)(s(),a());function s(){if(o.length){if(!(r instanceof L.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,L._)`${(0,ld.checkDataTypes)(c,r,i.opts.strictNumbers,ld.DataType.Wrong)}`}return L.nil}function a(){if(n.validateSchema){let c=t.scopeValue("validate$data",{ref:n.validateSchema});return(0,L._)`!${c}(${r})`}return L.nil}}subschema(t,r){let o=(0,Xg.getSubschema)(this.it,t);(0,Xg.extendSubschemaData)(o,this.it,t),(0,Xg.extendSubschemaMode)(o,t);let n={...this.it,...o,items:void 0,props:void 0};return fD(n,r),n}mergeEvaluated(t,r){let{it:o,gen:n}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=Nr.mergeEvaluated.props(n,t.props,o.props,r)),o.items!==!0&&t.items!==void 0&&(o.items=Nr.mergeEvaluated.items(n,t.items,o.items,r)))}mergeValidEvaluated(t,r){let{it:o,gen:n}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return n.if(r,()=>this.mergeEvaluated(t,L.Name)),!0}};cn.KeywordCxt=dd;function Dx(e,t,r,o){let n=new dd(e,r,t);"code"in r?r.code(n,o):n.$data&&r.validate?(0,ka.funcKeywordCode)(n,r):"macro"in r?(0,ka.macroKeywordCode)(n,r):(r.compile||r.validate)&&(0,ka.funcKeywordCode)(n,r)}var PD=/^\/(?:[^~]|~0|~1)*$/,zD=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function qx(e,{dataLevel:t,dataNames:r,dataPathArr:o}){let n,i;if(e==="")return H.default.rootData;if(e[0]==="/"){if(!PD.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,i=H.default.rootData}else{let u=zD.exec(e);if(!u)throw new Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(n=u[2],n==="#"){if(l>=t)throw new Error(c("property/index",l));return o[t-l]}if(l>t)throw new Error(c("data",l));if(i=r[t-l],!n)return i}let s=i,a=n.split("/");for(let u of a)u&&(i=(0,L._)`${i}${(0,L.getProperty)((0,Nr.unescapeJsonPointer)(u))}`,s=(0,L._)`${s} && ${i}`);return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}cn.getData=qx});var pd=b(rv=>{"use strict";Object.defineProperty(rv,"__esModule",{value:!0});var tv=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};rv.default=tv});var Sa=b(iv=>{"use strict";Object.defineProperty(iv,"__esModule",{value:!0});var nv=ba(),ov=class extends Error{constructor(t,r,o,n){super(n||`can't resolve reference ${o} from id ${r}`),this.missingRef=(0,nv.resolveUrl)(t,r,o),this.missingSchema=(0,nv.normalizeId)((0,nv.getFullPath)(t,this.missingRef))}};iv.default=ov});var md=b(Ut=>{"use strict";Object.defineProperty(Ut,"__esModule",{value:!0});Ut.resolveSchema=Ut.getCompilingSchema=Ut.resolveRef=Ut.compileSchema=Ut.SchemaEnv=void 0;var er=Q(),ED=pd(),Vn=Or(),tr=ba(),Mx=ve(),ID=xa(),ei=class{constructor(t){var r;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,tr.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};Ut.SchemaEnv=ei;function av(e){let t=Ux.call(this,e);if(t)return t;let r=(0,tr.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:n}=this.opts.code,{ownProperties:i}=this.opts,s=new er.CodeGen(this.scope,{es5:o,lines:n,ownProperties:i}),a;e.$async&&(a=s.scopeValue("Error",{ref:ED.default,code:(0,er._)`require("ajv/dist/runtime/validation_error").default`}));let c=s.scopeName("validate");e.validateName=c;let u={gen:s,allErrors:this.opts.allErrors,data:Vn.default.data,parentData:Vn.default.parentData,parentDataProperty:Vn.default.parentDataProperty,dataNames:[Vn.default.data],dataPathArr:[er.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,er.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:er.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,er._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),(0,ID.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let d=s.toString();l=`${s.scopeRefs(Vn.default.scope)}return ${d}`,this.opts.code.process&&(l=this.opts.code.process(l,e));let m=new Function(`${Vn.default.self}`,`${Vn.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:m}),m.errors=null,m.schema=e.schema,m.schemaEnv=e,e.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:c,validateCode:d,scopeValues:s._values}),this.opts.unevaluated){let{props:p,items:f}=u;m.evaluated={props:p instanceof er.Name?void 0:p,items:f instanceof er.Name?void 0:f,dynamicProps:p instanceof er.Name,dynamicItems:f instanceof er.Name},m.source&&(m.source.evaluated=(0,er.stringify)(m.evaluated))}return e.validate=m,e}catch(d){throw delete e.validate,delete e.validateName,l&&this.logger.error("Error compiling schema, function code:",l),d}finally{this._compilations.delete(e)}}Ut.compileSchema=av;function jD(e,t,r){var o;r=(0,tr.resolveUrl)(this.opts.uriResolver,t,r);let n=e.refs[r];if(n)return n;let i=RD.call(this,e,r);if(i===void 0){let s=(o=e.localRefs)===null||o===void 0?void 0:o[r],{schemaId:a}=this.opts;s&&(i=new ei({schema:s,schemaId:a,root:e,baseId:t}))}if(i!==void 0)return e.refs[r]=OD.call(this,i)}Ut.resolveRef=jD;function OD(e){return(0,tr.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:av.call(this,e)}function Ux(e){for(let t of this._compilations)if(ND(t,e))return t}Ut.getCompilingSchema=Ux;function ND(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function RD(e,t){let r;for(;typeof(r=this.refs[t])=="string";)t=r;return r||this.schemas[t]||fd.call(this,e,t)}function fd(e,t){let r=this.opts.uriResolver.parse(t),o=(0,tr._getFullPath)(this.opts.uriResolver,r),n=(0,tr.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===n)return sv.call(this,r,e);let i=(0,tr.normalizeId)(o),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=fd.call(this,e,s);return typeof a?.schema!="object"?void 0:sv.call(this,r,a)}if(typeof s?.schema=="object"){if(s.validate||av.call(this,s),i===(0,tr.normalizeId)(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];return u&&(n=(0,tr.resolveUrl)(this.opts.uriResolver,n,u)),new ei({schema:a,schemaId:c,root:e,baseId:n})}return sv.call(this,r,s)}}Ut.resolveSchema=fd;var CD=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function sv(e,{baseId:t,schema:r,root:o}){var n;if(((n=e.fragment)===null||n===void 0?void 0:n[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let c=r[(0,Mx.unescapeFragment)(a)];if(c===void 0)return;r=c;let u=typeof r=="object"&&r[this.opts.schemaId];!CD.has(a)&&u&&(t=(0,tr.resolveUrl)(this.opts.uriResolver,t,u))}let i;if(typeof r!="boolean"&&r.$ref&&!(0,Mx.schemaHasRulesButRef)(r,this.RULES)){let a=(0,tr.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=fd.call(this,o,a)}let{schemaId:s}=this.opts;if(i=i||new ei({schema:r,schemaId:s,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var Zx=b((bK,AD)=>{AD.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 Vx=b(cv=>{"use strict";Object.defineProperty(cv,"__esModule",{value:!0});var Lx=xh();Lx.code='require("ajv/dist/runtime/uri").default';cv.default=Lx});var Yx=b(Be=>{"use strict";Object.defineProperty(Be,"__esModule",{value:!0});Be.CodeGen=Be.Name=Be.nil=Be.stringify=Be.str=Be._=Be.KeywordCxt=void 0;var DD=xa();Object.defineProperty(Be,"KeywordCxt",{enumerable:!0,get:function(){return DD.KeywordCxt}});var ti=Q();Object.defineProperty(Be,"_",{enumerable:!0,get:function(){return ti._}});Object.defineProperty(Be,"str",{enumerable:!0,get:function(){return ti.str}});Object.defineProperty(Be,"stringify",{enumerable:!0,get:function(){return ti.stringify}});Object.defineProperty(Be,"nil",{enumerable:!0,get:function(){return ti.nil}});Object.defineProperty(Be,"Name",{enumerable:!0,get:function(){return ti.Name}});Object.defineProperty(Be,"CodeGen",{enumerable:!0,get:function(){return ti.CodeGen}});var qD=pd(),Hx=Sa(),MD=Vg(),Ta=md(),UD=Q(),Pa=ba(),hd=$a(),lv=ve(),Fx=Zx(),ZD=Vx(),Jx=(e,t)=>new RegExp(e,t);Jx.code="new RegExp";var LD=["removeAdditional","useDefaults","coerceTypes"],VD=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),FD={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."},GD={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},Gx=200;function WD(e){var t,r,o,n,i,s,a,c,u,l,d,h,m,p,f,g,y,w,k,E,P,ze,Me,or,pn;let Lt=e.strict,fn=(t=e.code)===null||t===void 0?void 0:t.optimize,ui=fn===!0||fn===void 0?1:fn||0,li=(o=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&o!==void 0?o:Jx,Ud=(n=e.uriResolver)!==null&&n!==void 0?n:ZD.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:Lt)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:Lt)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:Lt)!==null&&l!==void 0?l:"log",strictTuples:(h=(d=e.strictTuples)!==null&&d!==void 0?d:Lt)!==null&&h!==void 0?h:"log",strictRequired:(p=(m=e.strictRequired)!==null&&m!==void 0?m:Lt)!==null&&p!==void 0?p:!1,code:e.code?{...e.code,optimize:ui,regExp:li}:{optimize:ui,regExp:li},loopRequired:(f=e.loopRequired)!==null&&f!==void 0?f:Gx,loopEnum:(g=e.loopEnum)!==null&&g!==void 0?g:Gx,meta:(y=e.meta)!==null&&y!==void 0?y:!0,messages:(w=e.messages)!==null&&w!==void 0?w:!0,inlineRefs:(k=e.inlineRefs)!==null&&k!==void 0?k:!0,schemaId:(E=e.schemaId)!==null&&E!==void 0?E:"$id",addUsedSchema:(P=e.addUsedSchema)!==null&&P!==void 0?P:!0,validateSchema:(ze=e.validateSchema)!==null&&ze!==void 0?ze:!0,validateFormats:(Me=e.validateFormats)!==null&&Me!==void 0?Me:!0,unicodeRegExp:(or=e.unicodeRegExp)!==null&&or!==void 0?or:!0,int32range:(pn=e.int32range)!==null&&pn!==void 0?pn:!0,uriResolver:Ud}}var za=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...WD(t)};let{es5:r,lines:o}=this.opts.code;this.scope=new UD.ValueScope({scope:{},prefixes:VD,es5:r,lines:o}),this.logger=XD(t.logger);let n=t.validateFormats;t.validateFormats=!1,this.RULES=(0,MD.getRules)(),Wx.call(this,FD,t,"NOT SUPPORTED"),Wx.call(this,GD,t,"DEPRECATED","warn"),this._metaOpts=BD.call(this),t.formats&&HD.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&JD.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),KD.call(this),t.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:r,schemaId:o}=this.opts,n=Fx;o==="id"&&(n={...Fx},n.id=n.$id,delete n.$id),r&&t&&this.addMetaSchema(n,n[o],!1)}defaultMeta(){let{meta:t,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[r]||t:void 0}validate(t,r){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let n=o(r);return"$async"in o||(this.errors=o.errors),n}compile(t,r){let o=this._addSchema(t,r);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return n.call(this,t,r);async function n(l,d){await i.call(this,l.$schema);let h=this._addSchema(l,d);return h.validate||s.call(this,h)}async function i(l){l&&!this.getSchema(l)&&await n.call(this,{$ref:l},!0)}async function s(l){try{return this._compileSchemaEnv(l)}catch(d){if(!(d instanceof Hx.default))throw d;return a.call(this,d),await c.call(this,d.missingSchema),s.call(this,l)}}function a({missingSchema:l,missingRef:d}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${d} cannot be resolved`)}async function c(l){let d=await u.call(this,l);this.refs[l]||await i.call(this,d.$schema),this.refs[l]||this.addSchema(d,l,r)}async function u(l){let d=this._loading[l];if(d)return d;try{return await(this._loading[l]=o(l))}finally{delete this._loading[l]}}}addSchema(t,r,o,n=this.opts.validateSchema){if(Array.isArray(t)){for(let s of t)this.addSchema(s,void 0,o,n);return this}let i;if(typeof t=="object"){let{schemaId:s}=this.opts;if(i=t[s],i!==void 0&&typeof i!="string")throw new Error(`schema ${s} must be string`)}return r=(0,Pa.normalizeId)(r||i),this._checkUnique(r),this.schemas[r]=this._addSchema(t,o,r,n,!0),this}addMetaSchema(t,r,o=this.opts.validateSchema){return this.addSchema(t,r,!0,o),this}validateSchema(t,r){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(o,t);if(!n&&r){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return n}getSchema(t){let r;for(;typeof(r=Kx.call(this,t))=="string";)t=r;if(r===void 0){let{schemaId:o}=this.opts,n=new Ta.SchemaEnv({schema:{},schemaId:o});if(r=Ta.resolveSchema.call(this,n,t),!r)return;this.refs[t]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=Kx.call(this,t);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let r=t;this._cache.delete(r);let o=t[this.opts.schemaId];return o&&(o=(0,Pa.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let r of t)this.addKeyword(r);return this}addKeyword(t,r){let o;if(typeof t=="string")o=t,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=o);else if(typeof t=="object"&&r===void 0){if(r=t,o=r.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(eq.call(this,o,r),!r)return(0,lv.eachItem)(o,i=>uv.call(this,i)),this;rq.call(this,r);let n={...r,type:(0,hd.getJSONTypes)(r.type),schemaType:(0,hd.getJSONTypes)(r.schemaType)};return(0,lv.eachItem)(o,n.type.length===0?i=>uv.call(this,i,n):i=>n.type.forEach(s=>uv.call(this,i,n,s))),this}getKeyword(t){let r=this.RULES.all[t];return typeof r=="object"?r.definition:!!r}removeKeyword(t){let{RULES:r}=this;delete r.keywords[t],delete r.all[t];for(let o of r.rules){let n=o.rules.findIndex(i=>i.keyword===t);n>=0&&o.rules.splice(n,1)}return this}addFormat(t,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[t]=r,this}errorsText(t=this.errors,{separator:r=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(n=>`${o}${n.instancePath} ${n.message}`).reduce((n,i)=>n+r+i)}$dataMetaSchema(t,r){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let n of r){let i=n.split("/").slice(1),s=t;for(let a of i)s=s[a];for(let a in o){let c=o[a];if(typeof c!="object")continue;let{$data:u}=c.definition,l=s[a];u&&l&&(s[a]=Bx(l))}}return t}_removeAllSchemas(t,r){for(let o in t){let n=t[o];(!r||r.test(o))&&(typeof n=="string"?delete t[o]:n&&!n.meta&&(this._cache.delete(n.schema),delete t[o]))}}_addSchema(t,r,o,n=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:a}=this.opts;if(typeof t=="object")s=t[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,Pa.normalizeId)(s||o);let u=Pa.getSchemaRefs.call(this,t,o);return c=new Ta.SchemaEnv({schema:t,schemaId:a,meta:r,baseId:o,localRefs:u}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),n&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):Ta.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let r=this.opts;this.opts=this._metaOpts;try{Ta.compileSchema.call(this,t)}finally{this.opts=r}}};za.ValidationError=qD.default;za.MissingRefError=Hx.default;Be.default=za;function Wx(e,t,r,o="error"){for(let n in e){let i=n;i in t&&this.logger[o](`${r}: option ${n}. ${e[i]}`)}}function Kx(e){return e=(0,Pa.normalizeId)(e),this.schemas[e]||this.refs[e]}function KD(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function HD(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function JD(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];r.keyword||(r.keyword=t),this.addKeyword(r)}}function BD(){let e={...this.opts};for(let t of LD)delete e[t];return e}var YD={log(){},warn(){},error(){}};function XD(e){if(e===!1)return YD;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var QD=/^[a-z_$][a-z0-9_$:-]*$/i;function eq(e,t){let{RULES:r}=this;if((0,lv.eachItem)(e,o=>{if(r.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!QD.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function uv(e,t,r){var o;let n=t?.post;if(r&&n)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=n?i.post:i.rules.find(({type:c})=>c===r);if(s||(s={type:r,rules:[]},i.rules.push(s)),i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:(0,hd.getJSONTypes)(t.type),schemaType:(0,hd.getJSONTypes)(t.schemaType)}};t.before?tq.call(this,s,a,t.before):s.rules.push(a),i.all[e]=a,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function tq(e,t,r){let o=e.rules.findIndex(n=>n.keyword===r);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function rq(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=Bx(t)),e.validateSchema=this.compile(t,!0))}var nq={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Bx(e){return{anyOf:[e,nq]}}});var Xx=b(dv=>{"use strict";Object.defineProperty(dv,"__esModule",{value:!0});var oq={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};dv.default=oq});var r0=b(Fn=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.callRef=Fn.getValidate=void 0;var iq=Sa(),Qx=Mt(),kt=Q(),ri=Or(),e0=md(),gd=ve(),sq={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:o}=e,{baseId:n,schemaEnv:i,validateName:s,opts:a,self:c}=o,{root:u}=i;if((r==="#"||r==="#/")&&n===u.baseId)return d();let l=e0.resolveRef.call(c,u,n,r);if(l===void 0)throw new iq.default(o.opts.uriResolver,n,r);if(l instanceof e0.SchemaEnv)return h(l);return m(l);function d(){if(i===u)return vd(e,s,i,i.$async);let p=t.scopeValue("root",{ref:u});return vd(e,(0,kt._)`${p}.validate`,u,u.$async)}function h(p){let f=t0(e,p);vd(e,f,p,p.$async)}function m(p){let f=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,kt.stringify)(p)}:{ref:p}),g=t.name("valid"),y=e.subschema({schema:p,dataTypes:[],schemaPath:kt.nil,topSchemaRef:f,errSchemaPath:r},g);e.mergeEvaluated(y),e.ok(g)}}};function t0(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,kt._)`${r.scopeValue("wrapper",{ref:t})}.validate`}Fn.getValidate=t0;function vd(e,t,r,o){let{gen:n,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?ri.default.this:kt.nil;o?l():d();function l(){if(!a.$async)throw new Error("async schema referenced by sync schema");let p=n.let("valid");n.try(()=>{n.code((0,kt._)`await ${(0,Qx.callValidateCode)(e,t,u)}`),m(t),s||n.assign(p,!0)},f=>{n.if((0,kt._)`!(${f} instanceof ${i.ValidationError})`,()=>n.throw(f)),h(f),s||n.assign(p,!1)}),e.ok(p)}function d(){e.result((0,Qx.callValidateCode)(e,t,u),()=>m(t),()=>h(t))}function h(p){let f=(0,kt._)`${p}.errors`;n.assign(ri.default.vErrors,(0,kt._)`${ri.default.vErrors} === null ? ${f} : ${ri.default.vErrors}.concat(${f})`),n.assign(ri.default.errors,(0,kt._)`${ri.default.vErrors}.length`)}function m(p){var f;if(!i.opts.unevaluated)return;let g=(f=r?.validate)===null||f===void 0?void 0:f.evaluated;if(i.props!==!0)if(g&&!g.dynamicProps)g.props!==void 0&&(i.props=gd.mergeEvaluated.props(n,g.props,i.props));else{let y=n.var("props",(0,kt._)`${p}.evaluated.props`);i.props=gd.mergeEvaluated.props(n,y,i.props,kt.Name)}if(i.items!==!0)if(g&&!g.dynamicItems)g.items!==void 0&&(i.items=gd.mergeEvaluated.items(n,g.items,i.items));else{let y=n.var("items",(0,kt._)`${p}.evaluated.items`);i.items=gd.mergeEvaluated.items(n,y,i.items,kt.Name)}}}Fn.callRef=vd;Fn.default=sq});var n0=b(pv=>{"use strict";Object.defineProperty(pv,"__esModule",{value:!0});var aq=Xx(),cq=r0(),uq=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",aq.default,cq.default];pv.default=uq});var o0=b(fv=>{"use strict";Object.defineProperty(fv,"__esModule",{value:!0});var _d=Q(),un=_d.operators,yd={maximum:{okStr:"<=",ok:un.LTE,fail:un.GT},minimum:{okStr:">=",ok:un.GTE,fail:un.LT},exclusiveMaximum:{okStr:"<",ok:un.LT,fail:un.GTE},exclusiveMinimum:{okStr:">",ok:un.GT,fail:un.LTE}},lq={message:({keyword:e,schemaCode:t})=>(0,_d.str)`must be ${yd[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,_d._)`{comparison: ${yd[e].okStr}, limit: ${t}}`},dq={keyword:Object.keys(yd),type:"number",schemaType:"number",$data:!0,error:lq,code(e){let{keyword:t,data:r,schemaCode:o}=e;e.fail$data((0,_d._)`${r} ${yd[t].fail} ${o} || isNaN(${r})`)}};fv.default=dq});var i0=b(mv=>{"use strict";Object.defineProperty(mv,"__esModule",{value:!0});var Ea=Q(),pq={message:({schemaCode:e})=>(0,Ea.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,Ea._)`{multipleOf: ${e}}`},fq={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:pq,code(e){let{gen:t,data:r,schemaCode:o,it:n}=e,i=n.opts.multipleOfPrecision,s=t.let("res"),a=i?(0,Ea._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:(0,Ea._)`${s} !== parseInt(${s})`;e.fail$data((0,Ea._)`(${o} === 0 || (${s} = ${r}/${o}, ${a}))`)}};mv.default=fq});var a0=b(hv=>{"use strict";Object.defineProperty(hv,"__esModule",{value:!0});function s0(e){let t=e.length,r=0,o=0,n;for(;o<t;)r++,n=e.charCodeAt(o++),n>=55296&&n<=56319&&o<t&&(n=e.charCodeAt(o),(n&64512)===56320&&o++);return r}hv.default=s0;s0.code='require("ajv/dist/runtime/ucs2length").default'});var c0=b(gv=>{"use strict";Object.defineProperty(gv,"__esModule",{value:!0});var Gn=Q(),mq=ve(),hq=a0(),gq={message({keyword:e,schemaCode:t}){let r=e==="maxLength"?"more":"fewer";return(0,Gn.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,Gn._)`{limit: ${e}}`},vq={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:gq,code(e){let{keyword:t,data:r,schemaCode:o,it:n}=e,i=t==="maxLength"?Gn.operators.GT:Gn.operators.LT,s=n.opts.unicode===!1?(0,Gn._)`${r}.length`:(0,Gn._)`${(0,mq.useFunc)(e.gen,hq.default)}(${r})`;e.fail$data((0,Gn._)`${s} ${i} ${o}`)}};gv.default=vq});var u0=b(vv=>{"use strict";Object.defineProperty(vv,"__esModule",{value:!0});var _q=Mt(),$d=Q(),yq={message:({schemaCode:e})=>(0,$d.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,$d._)`{pattern: ${e}}`},$q={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:yq,code(e){let{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,s=i.opts.unicodeRegExp?"u":"",a=r?(0,$d._)`(new RegExp(${n}, ${s}))`:(0,_q.usePattern)(e,o);e.fail$data((0,$d._)`!${a}.test(${t})`)}};vv.default=$q});var l0=b(_v=>{"use strict";Object.defineProperty(_v,"__esModule",{value:!0});var Ia=Q(),bq={message({keyword:e,schemaCode:t}){let r=e==="maxProperties"?"more":"fewer";return(0,Ia.str)`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>(0,Ia._)`{limit: ${e}}`},wq={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:bq,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxProperties"?Ia.operators.GT:Ia.operators.LT;e.fail$data((0,Ia._)`Object.keys(${r}).length ${n} ${o}`)}};_v.default=wq});var d0=b(yv=>{"use strict";Object.defineProperty(yv,"__esModule",{value:!0});var ja=Mt(),Oa=Q(),kq=ve(),xq={message:({params:{missingProperty:e}})=>(0,Oa.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,Oa._)`{missingProperty: ${e}}`},Sq={keyword:"required",type:"object",schemaType:"array",$data:!0,error:xq,code(e){let{gen:t,schema:r,schemaCode:o,data:n,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors?u():l(),a.strictRequired){let m=e.parentSchema.properties,{definedProperties:p}=e.it;for(let f of r)if(m?.[f]===void 0&&!p.has(f)){let g=s.schemaEnv.baseId+s.errSchemaPath,y=`required property "${f}" is not defined at "${g}" (strictRequired)`;(0,kq.checkStrictMode)(s,y,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(Oa.nil,d);else for(let m of r)(0,ja.checkReportMissingProp)(e,m)}function l(){let m=t.let("missing");if(c||i){let p=t.let("valid",!0);e.block$data(p,()=>h(m,p)),e.ok(p)}else t.if((0,ja.checkMissingProp)(e,r,m)),(0,ja.reportMissingProp)(e,m),t.else()}function d(){t.forOf("prop",o,m=>{e.setParams({missingProperty:m}),t.if((0,ja.noPropertyInData)(t,n,m,a.ownProperties),()=>e.error())})}function h(m,p){e.setParams({missingProperty:m}),t.forOf(m,o,()=>{t.assign(p,(0,ja.propertyInData)(t,n,m,a.ownProperties)),t.if((0,Oa.not)(p),()=>{e.error(),t.break()})},Oa.nil)}}};yv.default=Sq});var p0=b($v=>{"use strict";Object.defineProperty($v,"__esModule",{value:!0});var Na=Q(),Tq={message({keyword:e,schemaCode:t}){let r=e==="maxItems"?"more":"fewer";return(0,Na.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,Na._)`{limit: ${e}}`},Pq={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:Tq,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxItems"?Na.operators.GT:Na.operators.LT;e.fail$data((0,Na._)`${r}.length ${n} ${o}`)}};$v.default=Pq});var bd=b(bv=>{"use strict";Object.defineProperty(bv,"__esModule",{value:!0});var f0=Ws();f0.code='require("ajv/dist/runtime/equal").default';bv.default=f0});var m0=b(kv=>{"use strict";Object.defineProperty(kv,"__esModule",{value:!0});var wv=$a(),Ye=Q(),zq=ve(),Eq=bd(),Iq={message:({params:{i:e,j:t}})=>(0,Ye.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Ye._)`{i: ${e}, j: ${t}}`},jq={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:Iq,code(e){let{gen:t,data:r,$data:o,schema:n,parentSchema:i,schemaCode:s,it:a}=e;if(!o&&!n)return;let c=t.let("valid"),u=i.items?(0,wv.getSchemaTypes)(i.items):[];e.block$data(c,l,(0,Ye._)`${s} === false`),e.ok(c);function l(){let p=t.let("i",(0,Ye._)`${r}.length`),f=t.let("j");e.setParams({i:p,j:f}),t.assign(c,!0),t.if((0,Ye._)`${p} > 1`,()=>(d()?h:m)(p,f))}function d(){return u.length>0&&!u.some(p=>p==="object"||p==="array")}function h(p,f){let g=t.name("item"),y=(0,wv.checkDataTypes)(u,g,a.opts.strictNumbers,wv.DataType.Wrong),w=t.const("indices",(0,Ye._)`{}`);t.for((0,Ye._)`;${p}--;`,()=>{t.let(g,(0,Ye._)`${r}[${p}]`),t.if(y,(0,Ye._)`continue`),u.length>1&&t.if((0,Ye._)`typeof ${g} == "string"`,(0,Ye._)`${g} += "_"`),t.if((0,Ye._)`typeof ${w}[${g}] == "number"`,()=>{t.assign(f,(0,Ye._)`${w}[${g}]`),e.error(),t.assign(c,!1).break()}).code((0,Ye._)`${w}[${g}] = ${p}`)})}function m(p,f){let g=(0,zq.useFunc)(t,Eq.default),y=t.name("outer");t.label(y).for((0,Ye._)`;${p}--;`,()=>t.for((0,Ye._)`${f} = ${p}; ${f}--;`,()=>t.if((0,Ye._)`${g}(${r}[${p}], ${r}[${f}])`,()=>{e.error(),t.assign(c,!1).break(y)})))}}};kv.default=jq});var h0=b(Sv=>{"use strict";Object.defineProperty(Sv,"__esModule",{value:!0});var xv=Q(),Oq=ve(),Nq=bd(),Rq={message:"must be equal to constant",params:({schemaCode:e})=>(0,xv._)`{allowedValue: ${e}}`},Cq={keyword:"const",$data:!0,error:Rq,code(e){let{gen:t,data:r,$data:o,schemaCode:n,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,xv._)`!${(0,Oq.useFunc)(t,Nq.default)}(${r}, ${n})`):e.fail((0,xv._)`${i} !== ${r}`)}};Sv.default=Cq});var g0=b(Tv=>{"use strict";Object.defineProperty(Tv,"__esModule",{value:!0});var Ra=Q(),Aq=ve(),Dq=bd(),qq={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,Ra._)`{allowedValues: ${e}}`},Mq={keyword:"enum",schemaType:"array",$data:!0,error:qq,code(e){let{gen:t,data:r,$data:o,schema:n,schemaCode:i,it:s}=e;if(!o&&n.length===0)throw new Error("enum must have non-empty array");let a=n.length>=s.opts.loopEnum,c,u=()=>c??(c=(0,Aq.useFunc)(t,Dq.default)),l;if(a||o)l=t.let("valid"),e.block$data(l,d);else{if(!Array.isArray(n))throw new Error("ajv implementation error");let m=t.const("vSchema",i);l=(0,Ra.or)(...n.map((p,f)=>h(m,f)))}e.pass(l);function d(){t.assign(l,!1),t.forOf("v",i,m=>t.if((0,Ra._)`${u()}(${r}, ${m})`,()=>t.assign(l,!0).break()))}function h(m,p){let f=n[p];return typeof f=="object"&&f!==null?(0,Ra._)`${u()}(${r}, ${m}[${p}])`:(0,Ra._)`${r} === ${f}`}}};Tv.default=Mq});var v0=b(Pv=>{"use strict";Object.defineProperty(Pv,"__esModule",{value:!0});var Uq=o0(),Zq=i0(),Lq=c0(),Vq=u0(),Fq=l0(),Gq=d0(),Wq=p0(),Kq=m0(),Hq=h0(),Jq=g0(),Bq=[Uq.default,Zq.default,Lq.default,Vq.default,Fq.default,Gq.default,Wq.default,Kq.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},Hq.default,Jq.default];Pv.default=Bq});var Ev=b(Ca=>{"use strict";Object.defineProperty(Ca,"__esModule",{value:!0});Ca.validateAdditionalItems=void 0;var Wn=Q(),zv=ve(),Yq={message:({params:{len:e}})=>(0,Wn.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,Wn._)`{limit: ${e}}`},Xq={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:Yq,code(e){let{parentSchema:t,it:r}=e,{items:o}=t;if(!Array.isArray(o)){(0,zv.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}_0(e,o)}};function _0(e,t){let{gen:r,schema:o,data:n,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",(0,Wn._)`${n}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,Wn._)`${a} <= ${t.length}`);else if(typeof o=="object"&&!(0,zv.alwaysValidSchema)(s,o)){let u=r.var("valid",(0,Wn._)`${a} <= ${t.length}`);r.if((0,Wn.not)(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,l=>{e.subschema({keyword:i,dataProp:l,dataPropType:zv.Type.Num},u),s.allErrors||r.if((0,Wn.not)(u),()=>r.break())})}}Ca.validateAdditionalItems=_0;Ca.default=Xq});var Iv=b(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});Aa.validateTuple=void 0;var y0=Q(),wd=ve(),Qq=Mt(),e4={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return $0(e,"additionalItems",t);r.items=!0,!(0,wd.alwaysValidSchema)(r,t)&&e.ok((0,Qq.validateArray)(e))}};function $0(e,t,r=e.schema){let{gen:o,parentSchema:n,data:i,keyword:s,it:a}=e;l(n),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=wd.mergeEvaluated.items(o,r.length,a.items));let c=o.name("valid"),u=o.const("len",(0,y0._)`${i}.length`);r.forEach((d,h)=>{(0,wd.alwaysValidSchema)(a,d)||(o.if((0,y0._)`${u} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},c)),e.ok(c))});function l(d){let{opts:h,errSchemaPath:m}=a,p=r.length,f=p===d.minItems&&(p===d.maxItems||d[t]===!1);if(h.strictTuples&&!f){let g=`"${s}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${m}"`;(0,wd.checkStrictMode)(a,g,h.strictTuples)}}}Aa.validateTuple=$0;Aa.default=e4});var b0=b(jv=>{"use strict";Object.defineProperty(jv,"__esModule",{value:!0});var t4=Iv(),r4={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,t4.validateTuple)(e,"items")};jv.default=r4});var k0=b(Ov=>{"use strict";Object.defineProperty(Ov,"__esModule",{value:!0});var w0=Q(),n4=ve(),o4=Mt(),i4=Ev(),s4={message:({params:{len:e}})=>(0,w0.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,w0._)`{limit: ${e}}`},a4={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:s4,code(e){let{schema:t,parentSchema:r,it:o}=e,{prefixItems:n}=r;o.items=!0,!(0,n4.alwaysValidSchema)(o,t)&&(n?(0,i4.validateAdditionalItems)(e,n):e.ok((0,o4.validateArray)(e)))}};Ov.default=a4});var x0=b(Nv=>{"use strict";Object.defineProperty(Nv,"__esModule",{value:!0});var Zt=Q(),kd=ve(),c4={message:({params:{min:e,max:t}})=>t===void 0?(0,Zt.str)`must contain at least ${e} valid item(s)`:(0,Zt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,Zt._)`{minContains: ${e}}`:(0,Zt._)`{minContains: ${e}, maxContains: ${t}}`},u4={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:c4,code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e,s,a,{minContains:c,maxContains:u}=o;i.opts.next?(s=c===void 0?1:c,a=u):s=1;let l=t.const("len",(0,Zt._)`${n}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){(0,kd.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,kd.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,kd.alwaysValidSchema)(i,r)){let f=(0,Zt._)`${l} >= ${s}`;a!==void 0&&(f=(0,Zt._)`${f} && ${l} <= ${a}`),e.pass(f);return}i.items=!0;let d=t.name("valid");a===void 0&&s===1?m(d,()=>t.if(d,()=>t.break())):s===0?(t.let(d,!0),a!==void 0&&t.if((0,Zt._)`${n}.length > 0`,h)):(t.let(d,!1),h()),e.result(d,()=>e.reset());function h(){let f=t.name("_valid"),g=t.let("count",0);m(f,()=>t.if(f,()=>p(g)))}function m(f,g){t.forRange("i",0,l,y=>{e.subschema({keyword:"contains",dataProp:y,dataPropType:kd.Type.Num,compositeRule:!0},f),g()})}function p(f){t.code((0,Zt._)`${f}++`),a===void 0?t.if((0,Zt._)`${f} >= ${s}`,()=>t.assign(d,!0).break()):(t.if((0,Zt._)`${f} > ${a}`,()=>t.assign(d,!1).break()),s===1?t.assign(d,!0):t.if((0,Zt._)`${f} >= ${s}`,()=>t.assign(d,!0)))}}};Nv.default=u4});var P0=b(hr=>{"use strict";Object.defineProperty(hr,"__esModule",{value:!0});hr.validateSchemaDeps=hr.validatePropertyDeps=hr.error=void 0;var Rv=Q(),l4=ve(),Da=Mt();hr.error={message:({params:{property:e,depsCount:t,deps:r}})=>{let o=t===1?"property":"properties";return(0,Rv.str)`must have ${o} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:o}})=>(0,Rv._)`{property: ${e},
13
+ || ${s} === "boolean" || ${n} === null`).assign(a,(0,Y._)`[${n}]`)}}}function IA({gen:e,parentData:t,parentDataProperty:r},o){e.if((0,Y._)`${t} !== undefined`,()=>e.assign((0,Y._)`${t}[${r}]`,o))}function Wg(e,t,r,o=Xo.Correct){let n=o===Xo.Correct?Y.operators.EQ:Y.operators.NEQ,i;switch(e){case"null":return(0,Y._)`${t} ${n} null`;case"array":i=(0,Y._)`Array.isArray(${t})`;break;case"object":i=(0,Y._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":i=s((0,Y._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":i=s();break;default:return(0,Y._)`typeof ${t} ${n} ${e}`}return o===Xo.Correct?i:(0,Y.not)(i);function s(a=Y.nil){return(0,Y.and)((0,Y._)`typeof ${t} == "number"`,a,r?(0,Y._)`isFinite(${t})`:Y.nil)}}at.checkDataType=Wg;function Kg(e,t,r,o){if(e.length===1)return Wg(e[0],t,r,o);let n,i=(0,ux.toHash)(e);if(i.array&&i.object){let s=(0,Y._)`typeof ${t} != "object"`;n=i.null?s:(0,Y._)`!${t} || ${s}`,delete i.null,delete i.array,delete i.object}else n=Y.nil;i.number&&delete i.integer;for(let s in i)n=(0,Y.and)(n,Wg(s,t,r,o));return n}at.checkDataTypes=Kg;var OA={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,Y._)`{type: ${e}}`:(0,Y._)`{type: ${t}}`};function Hg(e){let t=jA(e);(0,SA.reportError)(t,OA)}at.reportTypeError=Hg;function jA(e){let{gen:t,data:r,schema:o}=e,n=(0,ux.schemaRefOrVal)(e,o,"type");return{gen:t,keyword:"type",data:r,schema:o.type,schemaCode:n,schemaValue:n,parentSchema:o,params:{},it:e}}});var fx=$(ld=>{"use strict";Object.defineProperty(ld,"__esModule",{value:!0});ld.assignDefaults=void 0;var Qo=Q(),NA=ve();function RA(e,t){let{properties:r,items:o}=e.schema;if(t==="object"&&r)for(let n in r)px(e,n,r[n].default);else t==="array"&&Array.isArray(o)&&o.forEach((n,i)=>px(e,i,n.default))}ld.assignDefaults=RA;function px(e,t,r){let{gen:o,compositeRule:n,data:i,opts:s}=e;if(r===void 0)return;let a=(0,Qo._)`${i}${(0,Qo.getProperty)(t)}`;if(n){(0,NA.checkStrictMode)(e,`default is ignored for: ${a}`);return}let c=(0,Qo._)`${a} === undefined`;s.useDefaults==="empty"&&(c=(0,Qo._)`${c} || ${a} === null || ${a} === ""`),o.if(c,(0,Qo._)`${a} = ${(0,Qo.stringify)(r)}`)}});var Zt=$(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.validateUnion=Se.validateArray=Se.usePattern=Se.callValidateCode=Se.schemaProperties=Se.allSchemaProperties=Se.noPropertyInData=Se.propertyInData=Se.isOwnProperty=Se.hasPropFunc=Se.reportMissingProp=Se.checkMissingProp=Se.checkReportMissingProp=void 0;var Ce=Q(),Jg=ve(),on=Nr(),CA=ve();function AA(e,t){let{gen:r,data:o,it:n}=e;r.if(Yg(r,o,t,n.opts.ownProperties),()=>{e.setParams({missingProperty:(0,Ce._)`${t}`},!0),e.error()})}Se.checkReportMissingProp=AA;function DA({gen:e,data:t,it:{opts:r}},o,n){return(0,Ce.or)(...o.map(i=>(0,Ce.and)(Yg(e,t,i,r.ownProperties),(0,Ce._)`${n} = ${i}`)))}Se.checkMissingProp=DA;function qA(e,t){e.setParams({missingProperty:t},!0),e.error()}Se.reportMissingProp=qA;function mx(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,Ce._)`Object.prototype.hasOwnProperty`})}Se.hasPropFunc=mx;function Bg(e,t,r){return(0,Ce._)`${mx(e)}.call(${t}, ${r})`}Se.isOwnProperty=Bg;function MA(e,t,r,o){let n=(0,Ce._)`${t}${(0,Ce.getProperty)(r)} !== undefined`;return o?(0,Ce._)`${n} && ${Bg(e,t,r)}`:n}Se.propertyInData=MA;function Yg(e,t,r,o){let n=(0,Ce._)`${t}${(0,Ce.getProperty)(r)} === undefined`;return o?(0,Ce.or)(n,(0,Ce.not)(Bg(e,t,r))):n}Se.noPropertyInData=Yg;function hx(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}Se.allSchemaProperties=hx;function UA(e,t){return hx(t).filter(r=>!(0,Jg.alwaysValidSchema)(e,t[r]))}Se.schemaProperties=UA;function ZA({schemaCode:e,data:t,it:{gen:r,topSchemaRef:o,schemaPath:n,errorPath:i},it:s},a,c,u){let l=u?(0,Ce._)`${e}, ${t}, ${o}${n}`:t,d=[[on.default.instancePath,(0,Ce.strConcat)(on.default.instancePath,i)],[on.default.parentData,s.parentData],[on.default.parentDataProperty,s.parentDataProperty],[on.default.rootData,on.default.rootData]];s.opts.dynamicRef&&d.push([on.default.dynamicAnchors,on.default.dynamicAnchors]);let h=(0,Ce._)`${l}, ${r.object(...d)}`;return c!==Ce.nil?(0,Ce._)`${a}.call(${c}, ${h})`:(0,Ce._)`${a}(${h})`}Se.callValidateCode=ZA;var VA=(0,Ce._)`new RegExp`;function LA({gen:e,it:{opts:t}},r){let o=t.unicodeRegExp?"u":"",{regExp:n}=t.code,i=n(r,o);return e.scopeValue("pattern",{key:i.toString(),ref:i,code:(0,Ce._)`${n.code==="new RegExp"?VA:(0,CA.useFunc)(e,n)}(${r}, ${o})`})}Se.usePattern=LA;function FA(e){let{gen:t,data:r,keyword:o,it:n}=e,i=t.name("valid");if(n.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",(0,Ce._)`${r}.length`);t.forRange("i",0,c,u=>{e.subschema({keyword:o,dataProp:u,dataPropType:Jg.Type.Num},i),t.if((0,Ce.not)(i),a)})}}Se.validateArray=FA;function GA(e){let{gen:t,schema:r,keyword:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some(c=>(0,Jg.alwaysValidSchema)(n,c))&&!n.opts.unevaluated)return;let s=t.let("valid",!1),a=t.name("_valid");t.block(()=>r.forEach((c,u)=>{let l=e.subschema({keyword:o,schemaProp:u,compositeRule:!0},a);t.assign(s,(0,Ce._)`${s} || ${a}`),e.mergeValidEvaluated(l,a)||t.if((0,Ce.not)(s))})),e.result(s,()=>e.reset(),()=>e.error(!0))}Se.validateUnion=GA});var _x=$(mr=>{"use strict";Object.defineProperty(mr,"__esModule",{value:!0});mr.validateKeywordUsage=mr.validSchemaType=mr.funcKeywordCode=mr.macroKeywordCode=void 0;var ht=Q(),Vn=Nr(),WA=Zt(),KA=$a();function HA(e,t){let{gen:r,keyword:o,schema:n,parentSchema:i,it:s}=e,a=t.macro.call(s.self,n,i,s),c=vx(r,o,a);s.opts.validateSchema!==!1&&s.self.validateSchema(a,!0);let u=r.name("valid");e.subschema({schema:a,schemaPath:ht.nil,errSchemaPath:`${s.errSchemaPath}/${o}`,topSchemaRef:c,compositeRule:!0},u),e.pass(u,()=>e.error(!0))}mr.macroKeywordCode=HA;function JA(e,t){var r;let{gen:o,keyword:n,schema:i,parentSchema:s,$data:a,it:c}=e;YA(c,t);let u=!a&&t.compile?t.compile.call(c.self,i,s,c):t.validate,l=vx(o,n,u),d=o.let("valid");e.block$data(d,h),e.ok((r=t.valid)!==null&&r!==void 0?r:d);function h(){if(t.errors===!1)f(),t.modifying&&gx(e),v(()=>e.error());else{let y=t.async?m():p();t.modifying&&gx(e),v(()=>BA(e,y))}}function m(){let y=o.let("ruleErrs",null);return o.try(()=>f((0,ht._)`await `),w=>o.assign(d,!1).if((0,ht._)`${w} instanceof ${c.ValidationError}`,()=>o.assign(y,(0,ht._)`${w}.errors`),()=>o.throw(w))),y}function p(){let y=(0,ht._)`${l}.errors`;return o.assign(y,null),f(ht.nil),y}function f(y=t.async?(0,ht._)`await `:ht.nil){let w=c.opts.passContext?Vn.default.this:Vn.default.self,k=!("compile"in t&&!a||t.schema===!1);o.assign(d,(0,ht._)`${y}${(0,WA.callValidateCode)(e,l,w,k)}`,t.modifying)}function v(y){var w;o.if((0,ht.not)((w=t.valid)!==null&&w!==void 0?w:d),y)}}mr.funcKeywordCode=JA;function gx(e){let{gen:t,data:r,it:o}=e;t.if(o.parentData,()=>t.assign(r,(0,ht._)`${o.parentData}[${o.parentDataProperty}]`))}function BA(e,t){let{gen:r}=e;r.if((0,ht._)`Array.isArray(${t})`,()=>{r.assign(Vn.default.vErrors,(0,ht._)`${Vn.default.vErrors} === null ? ${t} : ${Vn.default.vErrors}.concat(${t})`).assign(Vn.default.errors,(0,ht._)`${Vn.default.vErrors}.length`),(0,KA.extendErrors)(e)},()=>e.error())}function YA({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}function vx(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,ht.stringify)(r)})}function XA(e,t,r=!1){return!t.length||t.some(o=>o==="array"?Array.isArray(e):o==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==o||r&&typeof e>"u")}mr.validSchemaType=XA;function QA({schema:e,opts:t,self:r,errSchemaPath:o},n,i){if(Array.isArray(n.keyword)?!n.keyword.includes(i):n.keyword!==i)throw new Error("ajv implementation error");let s=n.dependencies;if(s?.some(a=>!Object.prototype.hasOwnProperty.call(e,a)))throw new Error(`parent schema must have dependencies of ${i}: ${s.join(",")}`);if(n.validateSchema&&!n.validateSchema(e[i])){let c=`keyword "${i}" value is invalid at path "${o}": `+r.errorsText(n.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(c);else throw new Error(c)}}mr.validateKeywordUsage=QA});var bx=$(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.extendSubschemaMode=sn.extendSubschemaData=sn.getSubschema=void 0;var hr=Q(),yx=ve();function eD(e,{keyword:t,schemaProp:r,schema:o,schemaPath:n,errSchemaPath:i,topSchemaRef:s}){if(t!==void 0&&o!==void 0)throw new 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:(0,hr._)`${e.schemaPath}${(0,hr.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:a[r],schemaPath:(0,hr._)`${e.schemaPath}${(0,hr.getProperty)(t)}${(0,hr.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,yx.escapeFragment)(r)}`}}if(o!==void 0){if(n===void 0||i===void 0||s===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:o,schemaPath:n,topSchemaRef:s,errSchemaPath:i}}throw new Error('either "keyword" or "schema" must be passed')}sn.getSubschema=eD;function tD(e,t,{dataProp:r,dataPropType:o,data:n,dataTypes:i,propertyName:s}){if(n!==void 0&&r!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');let{gen:a}=t;if(r!==void 0){let{errorPath:u,dataPathArr:l,opts:d}=t,h=a.let("data",(0,hr._)`${t.data}${(0,hr.getProperty)(r)}`,!0);c(h),e.errorPath=(0,hr.str)`${u}${(0,yx.getErrorPath)(r,o,d.jsPropertySyntax)}`,e.parentDataProperty=(0,hr._)`${r}`,e.dataPathArr=[...l,e.parentDataProperty]}if(n!==void 0){let u=n instanceof hr.Name?n:a.let("data",n,!0);c(u),s!==void 0&&(e.propertyName=s)}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]}}sn.extendSubschemaData=tD;function rD(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:o,createErrors:n,allErrors:i}){o!==void 0&&(e.compositeRule=o),n!==void 0&&(e.createErrors=n),i!==void 0&&(e.allErrors=i),e.jtdDiscriminator=t,e.jtdMetadata=r}sn.extendSubschemaMode=rD});var wx=$((qK,$x)=>{"use strict";var an=$x.exports=function(e,t,r){typeof t=="function"&&(r=t,t={}),r=t.cb||r;var o=typeof r=="function"?r:r.pre||function(){},n=r.post||function(){};dd(t,o,n,e,"",e)};an.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0};an.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0};an.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0};an.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 dd(e,t,r,o,n,i,s,a,c,u){if(o&&typeof o=="object"&&!Array.isArray(o)){t(o,n,i,s,a,c,u);for(var l in o){var d=o[l];if(Array.isArray(d)){if(l in an.arrayKeywords)for(var h=0;h<d.length;h++)dd(e,t,r,d[h],n+"/"+l+"/"+h,i,n,l,o,h)}else if(l in an.propsKeywords){if(d&&typeof d=="object")for(var m in d)dd(e,t,r,d[m],n+"/"+l+"/"+nD(m),i,n,l,o,m)}else(l in an.keywords||e.allKeys&&!(l in an.skipKeywords))&&dd(e,t,r,d,n+"/"+l,i,n,l,o)}r(o,n,i,s,a,c,u)}}function nD(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}});var ka=$(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.getSchemaRefs=xt.resolveUrl=xt.normalizeId=xt._getFullPath=xt.getFullPath=xt.inlineRef=void 0;var oD=ve(),iD=Hs(),sD=wx(),aD=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function cD(e,t=!0){return typeof e=="boolean"?!0:t===!0?!Xg(e):t?kx(e)<=t:!1}xt.inlineRef=cD;var uD=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function Xg(e){for(let t in e){if(uD.has(t))return!0;let r=e[t];if(Array.isArray(r)&&r.some(Xg)||typeof r=="object"&&Xg(r))return!0}return!1}function kx(e){let t=0;for(let r in e){if(r==="$ref")return 1/0;if(t++,!aD.has(r)&&(typeof e[r]=="object"&&(0,oD.eachItem)(e[r],o=>t+=kx(o)),t===1/0))return 1/0}return t}function xx(e,t="",r){r!==!1&&(t=ei(t));let o=e.parse(t);return Sx(e,o)}xt.getFullPath=xx;function Sx(e,t){return e.serialize(t).split("#")[0]+"#"}xt._getFullPath=Sx;var lD=/#\/?$/;function ei(e){return e?e.replace(lD,""):""}xt.normalizeId=ei;function dD(e,t,r){return r=ei(r),e.resolve(t,r)}xt.resolveUrl=dD;var pD=/^[a-z_][-a-z0-9._]*$/i;function fD(e,t){if(typeof e=="boolean")return{};let{schemaId:r,uriResolver:o}=this.opts,n=ei(e[r]||t),i={"":n},s=xx(o,n,!1),a={},c=new Set;return sD(e,{allKeys:!0},(d,h,m,p)=>{if(p===void 0)return;let f=s+h,v=i[p];typeof d[r]=="string"&&(v=y.call(this,d[r])),w.call(this,d.$anchor),w.call(this,d.$dynamicAnchor),i[h]=v;function y(k){let E=this.opts.uriResolver.resolve;if(k=ei(v?E(v,k):k),c.has(k))throw l(k);c.add(k);let P=this.refs[k];return typeof P=="string"&&(P=this.refs[P]),typeof P=="object"?u(d,P.schema,k):k!==ei(f)&&(k[0]==="#"?(u(d,a[k],k),a[k]=d):this.refs[k]=f),k}function w(k){if(typeof k=="string"){if(!pD.test(k))throw new Error(`invalid anchor "${k}"`);y.call(this,`#${k}`)}}}),a;function u(d,h,m){if(h!==void 0&&!iD(d,h))throw l(m)}function l(d){return new Error(`reference "${d}" resolves to more than one schema`)}}xt.getSchemaRefs=fD});var Ta=$(cn=>{"use strict";Object.defineProperty(cn,"__esModule",{value:!0});cn.getData=cn.KeywordCxt=cn.validateFunctionCode=void 0;var Ix=sx(),Tx=wa(),ev=Gg(),pd=wa(),mD=fx(),Sa=_x(),Qg=bx(),V=Q(),H=Nr(),hD=ka(),Rr=ve(),xa=$a();function gD(e){if(Nx(e)&&(Rx(e),jx(e))){yD(e);return}Ox(e,()=>(0,Ix.topBoolOrEmptySchema)(e))}cn.validateFunctionCode=gD;function Ox({gen:e,validateName:t,schema:r,schemaEnv:o,opts:n},i){n.code.es5?e.func(t,(0,V._)`${H.default.data}, ${H.default.valCxt}`,o.$async,()=>{e.code((0,V._)`"use strict"; ${Px(r,n)}`),_D(e,n),e.code(i)}):e.func(t,(0,V._)`${H.default.data}, ${vD(n)}`,o.$async,()=>e.code(Px(r,n)).code(i))}function vD(e){return(0,V._)`{${H.default.instancePath}="", ${H.default.parentData}, ${H.default.parentDataProperty}, ${H.default.rootData}=${H.default.data}${e.dynamicRef?(0,V._)`, ${H.default.dynamicAnchors}={}`:V.nil}}={}`}function _D(e,t){e.if(H.default.valCxt,()=>{e.var(H.default.instancePath,(0,V._)`${H.default.valCxt}.${H.default.instancePath}`),e.var(H.default.parentData,(0,V._)`${H.default.valCxt}.${H.default.parentData}`),e.var(H.default.parentDataProperty,(0,V._)`${H.default.valCxt}.${H.default.parentDataProperty}`),e.var(H.default.rootData,(0,V._)`${H.default.valCxt}.${H.default.rootData}`),t.dynamicRef&&e.var(H.default.dynamicAnchors,(0,V._)`${H.default.valCxt}.${H.default.dynamicAnchors}`)},()=>{e.var(H.default.instancePath,(0,V._)`""`),e.var(H.default.parentData,(0,V._)`undefined`),e.var(H.default.parentDataProperty,(0,V._)`undefined`),e.var(H.default.rootData,H.default.data),t.dynamicRef&&e.var(H.default.dynamicAnchors,(0,V._)`{}`)})}function yD(e){let{schema:t,opts:r,gen:o}=e;Ox(e,()=>{r.$comment&&t.$comment&&Ax(e),xD(e),o.let(H.default.vErrors,null),o.let(H.default.errors,0),r.unevaluated&&bD(e),Cx(e),PD(e)})}function bD(e){let{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,V._)`${r}.evaluated`),t.if((0,V._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,V._)`${e.evaluated}.props`,(0,V._)`undefined`)),t.if((0,V._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,V._)`${e.evaluated}.items`,(0,V._)`undefined`))}function Px(e,t){let r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,V._)`/*# sourceURL=${r} */`:V.nil}function $D(e,t){if(Nx(e)&&(Rx(e),jx(e))){wD(e,t);return}(0,Ix.boolOrEmptySchema)(e,t)}function jx({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 Nx(e){return typeof e.schema!="boolean"}function wD(e,t){let{schema:r,gen:o,opts:n}=e;n.$comment&&r.$comment&&Ax(e),SD(e),TD(e);let i=o.const("_errs",H.default.errors);Cx(e,i),o.var(t,(0,V._)`${i} === ${H.default.errors}`)}function Rx(e){(0,Rr.checkUnknownRules)(e),kD(e)}function Cx(e,t){if(e.opts.jtd)return zx(e,[],!1,t);let r=(0,Tx.getSchemaTypes)(e.schema),o=(0,Tx.coerceAndCheckDataType)(e,r);zx(e,r,!o,t)}function kD(e){let{schema:t,errSchemaPath:r,opts:o,self:n}=e;t.$ref&&o.ignoreKeywordsWithRef&&(0,Rr.schemaHasRulesButRef)(t,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}function xD(e){let{schema:t,opts:r}=e;t.default!==void 0&&r.useDefaults&&r.strictSchema&&(0,Rr.checkStrictMode)(e,"default is ignored in the schema root")}function SD(e){let t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,hD.resolveUrl)(e.opts.uriResolver,e.baseId,t))}function TD(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}function Ax({gen:e,schemaEnv:t,schema:r,errSchemaPath:o,opts:n}){let i=r.$comment;if(n.$comment===!0)e.code((0,V._)`${H.default.self}.logger.log(${i})`);else if(typeof n.$comment=="function"){let s=(0,V.str)`${o}/$comment`,a=e.scopeValue("root",{ref:t.root});e.code((0,V._)`${H.default.self}.opts.$comment(${i}, ${s}, ${a}.schema)`)}}function PD(e){let{gen:t,schemaEnv:r,validateName:o,ValidationError:n,opts:i}=e;r.$async?t.if((0,V._)`${H.default.errors} === 0`,()=>t.return(H.default.data),()=>t.throw((0,V._)`new ${n}(${H.default.vErrors})`)):(t.assign((0,V._)`${o}.errors`,H.default.vErrors),i.unevaluated&&zD(e),t.return((0,V._)`${H.default.errors} === 0`))}function zD({gen:e,evaluated:t,props:r,items:o}){r instanceof V.Name&&e.assign((0,V._)`${t}.props`,r),o instanceof V.Name&&e.assign((0,V._)`${t}.items`,o)}function zx(e,t,r,o){let{gen:n,schema:i,data:s,allErrors:a,opts:c,self:u}=e,{RULES:l}=u;if(i.$ref&&(c.ignoreKeywordsWithRef||!(0,Rr.schemaHasRulesButRef)(i,l))){n.block(()=>qx(e,"$ref",l.all.$ref.definition));return}c.jtd||ED(e,t),n.block(()=>{for(let h of l.rules)d(h);d(l.post)});function d(h){(0,ev.shouldUseGroup)(i,h)&&(h.type?(n.if((0,pd.checkDataType)(h.type,s,c.strictNumbers)),Ex(e,h),t.length===1&&t[0]===h.type&&r&&(n.else(),(0,pd.reportTypeError)(e)),n.endIf()):Ex(e,h),a||n.if((0,V._)`${H.default.errors} === ${o||0}`))}}function Ex(e,t){let{gen:r,schema:o,opts:{useDefaults:n}}=e;n&&(0,mD.assignDefaults)(e,t.type),r.block(()=>{for(let i of t.rules)(0,ev.shouldUseRule)(o,i)&&qx(e,i.keyword,i.definition,t.type)})}function ED(e,t){e.schemaEnv.meta||!e.opts.strictTypes||(ID(e,t),e.opts.allowUnionTypes||OD(e,t),jD(e,e.dataTypes))}function ID(e,t){if(t.length){if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{Dx(e.dataTypes,r)||tv(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}),RD(e,t)}}function OD(e,t){t.length>1&&!(t.length===2&&t.includes("null"))&&tv(e,"use allowUnionTypes to allow union type keyword")}function jD(e,t){let r=e.self.RULES.all;for(let o in r){let n=r[o];if(typeof n=="object"&&(0,ev.shouldUseRule)(e.schema,n)){let{type:i}=n.definition;i.length&&!i.some(s=>ND(t,s))&&tv(e,`missing type "${i.join(",")}" for keyword "${o}"`)}}}function ND(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}function Dx(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}function RD(e,t){let r=[];for(let o of e.dataTypes)Dx(t,o)?r.push(o):t.includes("integer")&&o==="number"&&r.push("integer");e.dataTypes=r}function tv(e,t){let r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`,(0,Rr.checkStrictMode)(e,t,e.opts.strictTypes)}var fd=class{constructor(t,r,o){if((0,Sa.validateKeywordUsage)(t,r,o),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=o,this.data=t.data,this.schema=t.schema[o],this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,Rr.schemaRefOrVal)(t,this.schema,o,this.$data),this.schemaType=r.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=r,this.$data)this.schemaCode=t.gen.const("vSchema",Mx(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,Sa.validSchemaType)(this.schema,r.schemaType,r.allowUndefined))throw new Error(`${o} value must be ${JSON.stringify(r.schemaType)}`);("code"in r?r.trackErrors:r.errors!==!1)&&(this.errsCount=t.gen.const("_errs",H.default.errors))}result(t,r,o){this.failResult((0,V.not)(t),r,o)}failResult(t,r,o){this.gen.if(t),o?o():this.error(),r?(this.gen.else(),r(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,r){this.failResult((0,V.not)(t),void 0,r)}fail(t){if(t===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);let{schemaCode:r}=this;this.fail((0,V._)`${r} !== undefined && (${(0,V.or)(this.invalid$data(),t)})`)}error(t,r,o){if(r){this.setParams(r),this._error(t,o),this.setParams({});return}this._error(t,o)}_error(t,r){(t?xa.reportExtraError:xa.reportError)(this,this.def.error,r)}$dataError(){(0,xa.reportError)(this,this.def.$dataError||xa.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,xa.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,r){r?Object.assign(this.params,t):this.params=t}block$data(t,r,o=V.nil){this.gen.block(()=>{this.check$data(t,o),r()})}check$data(t=V.nil,r=V.nil){if(!this.$data)return;let{gen:o,schemaCode:n,schemaType:i,def:s}=this;o.if((0,V.or)((0,V._)`${n} === undefined`,r)),t!==V.nil&&o.assign(t,!0),(i.length||s.validateSchema)&&(o.elseIf(this.invalid$data()),this.$dataError(),t!==V.nil&&o.assign(t,!1)),o.else()}invalid$data(){let{gen:t,schemaCode:r,schemaType:o,def:n,it:i}=this;return(0,V.or)(s(),a());function s(){if(o.length){if(!(r instanceof V.Name))throw new Error("ajv implementation error");let c=Array.isArray(o)?o:[o];return(0,V._)`${(0,pd.checkDataTypes)(c,r,i.opts.strictNumbers,pd.DataType.Wrong)}`}return V.nil}function a(){if(n.validateSchema){let c=t.scopeValue("validate$data",{ref:n.validateSchema});return(0,V._)`!${c}(${r})`}return V.nil}}subschema(t,r){let o=(0,Qg.getSubschema)(this.it,t);(0,Qg.extendSubschemaData)(o,this.it,t),(0,Qg.extendSubschemaMode)(o,t);let n={...this.it,...o,items:void 0,props:void 0};return $D(n,r),n}mergeEvaluated(t,r){let{it:o,gen:n}=this;o.opts.unevaluated&&(o.props!==!0&&t.props!==void 0&&(o.props=Rr.mergeEvaluated.props(n,t.props,o.props,r)),o.items!==!0&&t.items!==void 0&&(o.items=Rr.mergeEvaluated.items(n,t.items,o.items,r)))}mergeValidEvaluated(t,r){let{it:o,gen:n}=this;if(o.opts.unevaluated&&(o.props!==!0||o.items!==!0))return n.if(r,()=>this.mergeEvaluated(t,V.Name)),!0}};cn.KeywordCxt=fd;function qx(e,t,r,o){let n=new fd(e,r,t);"code"in r?r.code(n,o):n.$data&&r.validate?(0,Sa.funcKeywordCode)(n,r):"macro"in r?(0,Sa.macroKeywordCode)(n,r):(r.compile||r.validate)&&(0,Sa.funcKeywordCode)(n,r)}var CD=/^\/(?:[^~]|~0|~1)*$/,AD=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Mx(e,{dataLevel:t,dataNames:r,dataPathArr:o}){let n,i;if(e==="")return H.default.rootData;if(e[0]==="/"){if(!CD.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,i=H.default.rootData}else{let u=AD.exec(e);if(!u)throw new Error(`Invalid JSON-pointer: ${e}`);let l=+u[1];if(n=u[2],n==="#"){if(l>=t)throw new Error(c("property/index",l));return o[t-l]}if(l>t)throw new Error(c("data",l));if(i=r[t-l],!n)return i}let s=i,a=n.split("/");for(let u of a)u&&(i=(0,V._)`${i}${(0,V.getProperty)((0,Rr.unescapeJsonPointer)(u))}`,s=(0,V._)`${s} && ${i}`);return s;function c(u,l){return`Cannot access ${u} ${l} levels up, current level is ${t}`}}cn.getData=Mx});var md=$(nv=>{"use strict";Object.defineProperty(nv,"__esModule",{value:!0});var rv=class extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}};nv.default=rv});var Pa=$(sv=>{"use strict";Object.defineProperty(sv,"__esModule",{value:!0});var ov=ka(),iv=class extends Error{constructor(t,r,o,n){super(n||`can't resolve reference ${o} from id ${r}`),this.missingRef=(0,ov.resolveUrl)(t,r,o),this.missingSchema=(0,ov.normalizeId)((0,ov.getFullPath)(t,this.missingRef))}};sv.default=iv});var gd=$(Vt=>{"use strict";Object.defineProperty(Vt,"__esModule",{value:!0});Vt.resolveSchema=Vt.getCompilingSchema=Vt.resolveRef=Vt.compileSchema=Vt.SchemaEnv=void 0;var tr=Q(),DD=md(),Ln=Nr(),rr=ka(),Ux=ve(),qD=Ta(),ti=class{constructor(t){var r;this.refs={},this.dynamicAnchors={};let o;typeof t.schema=="object"&&(o=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,rr.normalizeId)(o?.[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=o?.$async,this.refs={}}};Vt.SchemaEnv=ti;function cv(e){let t=Zx.call(this,e);if(t)return t;let r=(0,rr.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:o,lines:n}=this.opts.code,{ownProperties:i}=this.opts,s=new tr.CodeGen(this.scope,{es5:o,lines:n,ownProperties:i}),a;e.$async&&(a=s.scopeValue("Error",{ref:DD.default,code:(0,tr._)`require("ajv/dist/runtime/validation_error").default`}));let c=s.scopeName("validate");e.validateName=c;let u={gen:s,allErrors:this.opts.allErrors,data:Ln.default.data,parentData:Ln.default.parentData,parentDataProperty:Ln.default.parentDataProperty,dataNames:[Ln.default.data],dataPathArr:[tr.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:s.scopeValue("schema",this.opts.code.source===!0?{ref:e.schema,code:(0,tr.stringify)(e.schema)}:{ref:e.schema}),validateName:c,ValidationError:a,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:tr.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,tr._)`""`,opts:this.opts,self:this},l;try{this._compilations.add(e),(0,qD.validateFunctionCode)(u),s.optimize(this.opts.code.optimize);let d=s.toString();l=`${s.scopeRefs(Ln.default.scope)}return ${d}`,this.opts.code.process&&(l=this.opts.code.process(l,e));let m=new Function(`${Ln.default.self}`,`${Ln.default.scope}`,l)(this,this.scope.get());if(this.scope.value(c,{ref:m}),m.errors=null,m.schema=e.schema,m.schemaEnv=e,e.$async&&(m.$async=!0),this.opts.code.source===!0&&(m.source={validateName:c,validateCode:d,scopeValues:s._values}),this.opts.unevaluated){let{props:p,items:f}=u;m.evaluated={props:p instanceof tr.Name?void 0:p,items:f instanceof tr.Name?void 0:f,dynamicProps:p instanceof tr.Name,dynamicItems:f instanceof tr.Name},m.source&&(m.source.evaluated=(0,tr.stringify)(m.evaluated))}return e.validate=m,e}catch(d){throw delete e.validate,delete e.validateName,l&&this.logger.error("Error compiling schema, function code:",l),d}finally{this._compilations.delete(e)}}Vt.compileSchema=cv;function MD(e,t,r){var o;r=(0,rr.resolveUrl)(this.opts.uriResolver,t,r);let n=e.refs[r];if(n)return n;let i=VD.call(this,e,r);if(i===void 0){let s=(o=e.localRefs)===null||o===void 0?void 0:o[r],{schemaId:a}=this.opts;s&&(i=new ti({schema:s,schemaId:a,root:e,baseId:t}))}if(i!==void 0)return e.refs[r]=UD.call(this,i)}Vt.resolveRef=MD;function UD(e){return(0,rr.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:cv.call(this,e)}function Zx(e){for(let t of this._compilations)if(ZD(t,e))return t}Vt.getCompilingSchema=Zx;function ZD(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function VD(e,t){let r;for(;typeof(r=this.refs[t])=="string";)t=r;return r||this.schemas[t]||hd.call(this,e,t)}function hd(e,t){let r=this.opts.uriResolver.parse(t),o=(0,rr._getFullPath)(this.opts.uriResolver,r),n=(0,rr.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&o===n)return av.call(this,r,e);let i=(0,rr.normalizeId)(o),s=this.refs[i]||this.schemas[i];if(typeof s=="string"){let a=hd.call(this,e,s);return typeof a?.schema!="object"?void 0:av.call(this,r,a)}if(typeof s?.schema=="object"){if(s.validate||cv.call(this,s),i===(0,rr.normalizeId)(t)){let{schema:a}=s,{schemaId:c}=this.opts,u=a[c];return u&&(n=(0,rr.resolveUrl)(this.opts.uriResolver,n,u)),new ti({schema:a,schemaId:c,root:e,baseId:n})}return av.call(this,r,s)}}Vt.resolveSchema=hd;var LD=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function av(e,{baseId:t,schema:r,root:o}){var n;if(((n=e.fragment)===null||n===void 0?void 0:n[0])!=="/")return;for(let a of e.fragment.slice(1).split("/")){if(typeof r=="boolean")return;let c=r[(0,Ux.unescapeFragment)(a)];if(c===void 0)return;r=c;let u=typeof r=="object"&&r[this.opts.schemaId];!LD.has(a)&&u&&(t=(0,rr.resolveUrl)(this.opts.uriResolver,t,u))}let i;if(typeof r!="boolean"&&r.$ref&&!(0,Ux.schemaHasRulesButRef)(r,this.RULES)){let a=(0,rr.resolveUrl)(this.opts.uriResolver,t,r.$ref);i=hd.call(this,o,a)}let{schemaId:s}=this.opts;if(i=i||new ti({schema:r,schemaId:s,root:o,baseId:t}),i.schema!==i.root.schema)return i}});var Vx=$((FK,FD)=>{FD.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 Fx=$(uv=>{"use strict";Object.defineProperty(uv,"__esModule",{value:!0});var Lx=Sh();Lx.code='require("ajv/dist/runtime/uri").default';uv.default=Lx});var Xx=$(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.CodeGen=Ye.Name=Ye.nil=Ye.stringify=Ye.str=Ye._=Ye.KeywordCxt=void 0;var GD=Ta();Object.defineProperty(Ye,"KeywordCxt",{enumerable:!0,get:function(){return GD.KeywordCxt}});var ri=Q();Object.defineProperty(Ye,"_",{enumerable:!0,get:function(){return ri._}});Object.defineProperty(Ye,"str",{enumerable:!0,get:function(){return ri.str}});Object.defineProperty(Ye,"stringify",{enumerable:!0,get:function(){return ri.stringify}});Object.defineProperty(Ye,"nil",{enumerable:!0,get:function(){return ri.nil}});Object.defineProperty(Ye,"Name",{enumerable:!0,get:function(){return ri.Name}});Object.defineProperty(Ye,"CodeGen",{enumerable:!0,get:function(){return ri.CodeGen}});var WD=md(),Jx=Pa(),KD=Fg(),za=gd(),HD=Q(),Ea=ka(),vd=wa(),dv=ve(),Gx=Vx(),JD=Fx(),Bx=(e,t)=>new RegExp(e,t);Bx.code="new RegExp";var BD=["removeAdditional","useDefaults","coerceTypes"],YD=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),XD={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."},QD={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},Wx=200;function eq(e){var t,r,o,n,i,s,a,c,u,l,d,h,m,p,f,v,y,w,k,E,P,ze,Me,ir,pn;let Ft=e.strict,fn=(t=e.code)===null||t===void 0?void 0:t.optimize,li=fn===!0||fn===void 0?1:fn||0,di=(o=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&o!==void 0?o:Bx,Vd=(n=e.uriResolver)!==null&&n!==void 0?n:JD.default;return{strictSchema:(s=(i=e.strictSchema)!==null&&i!==void 0?i:Ft)!==null&&s!==void 0?s:!0,strictNumbers:(c=(a=e.strictNumbers)!==null&&a!==void 0?a:Ft)!==null&&c!==void 0?c:!0,strictTypes:(l=(u=e.strictTypes)!==null&&u!==void 0?u:Ft)!==null&&l!==void 0?l:"log",strictTuples:(h=(d=e.strictTuples)!==null&&d!==void 0?d:Ft)!==null&&h!==void 0?h:"log",strictRequired:(p=(m=e.strictRequired)!==null&&m!==void 0?m:Ft)!==null&&p!==void 0?p:!1,code:e.code?{...e.code,optimize:li,regExp:di}:{optimize:li,regExp:di},loopRequired:(f=e.loopRequired)!==null&&f!==void 0?f:Wx,loopEnum:(v=e.loopEnum)!==null&&v!==void 0?v:Wx,meta:(y=e.meta)!==null&&y!==void 0?y:!0,messages:(w=e.messages)!==null&&w!==void 0?w:!0,inlineRefs:(k=e.inlineRefs)!==null&&k!==void 0?k:!0,schemaId:(E=e.schemaId)!==null&&E!==void 0?E:"$id",addUsedSchema:(P=e.addUsedSchema)!==null&&P!==void 0?P:!0,validateSchema:(ze=e.validateSchema)!==null&&ze!==void 0?ze:!0,validateFormats:(Me=e.validateFormats)!==null&&Me!==void 0?Me:!0,unicodeRegExp:(ir=e.unicodeRegExp)!==null&&ir!==void 0?ir:!0,int32range:(pn=e.int32range)!==null&&pn!==void 0?pn:!0,uriResolver:Vd}}var Ia=class{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...eq(t)};let{es5:r,lines:o}=this.opts.code;this.scope=new HD.ValueScope({scope:{},prefixes:YD,es5:r,lines:o}),this.logger=sq(t.logger);let n=t.validateFormats;t.validateFormats=!1,this.RULES=(0,KD.getRules)(),Kx.call(this,XD,t,"NOT SUPPORTED"),Kx.call(this,QD,t,"DEPRECATED","warn"),this._metaOpts=oq.call(this),t.formats&&rq.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&nq.call(this,t.keywords),typeof t.meta=="object"&&this.addMetaSchema(t.meta),tq.call(this),t.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){let{$data:t,meta:r,schemaId:o}=this.opts,n=Gx;o==="id"&&(n={...Gx},n.id=n.$id,delete n.$id),r&&t&&this.addMetaSchema(n,n[o],!1)}defaultMeta(){let{meta:t,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[r]||t:void 0}validate(t,r){let o;if(typeof t=="string"){if(o=this.getSchema(t),!o)throw new Error(`no schema with key or ref "${t}"`)}else o=this.compile(t);let n=o(r);return"$async"in o||(this.errors=o.errors),n}compile(t,r){let o=this._addSchema(t,r);return o.validate||this._compileSchemaEnv(o)}compileAsync(t,r){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");let{loadSchema:o}=this.opts;return n.call(this,t,r);async function n(l,d){await i.call(this,l.$schema);let h=this._addSchema(l,d);return h.validate||s.call(this,h)}async function i(l){l&&!this.getSchema(l)&&await n.call(this,{$ref:l},!0)}async function s(l){try{return this._compileSchemaEnv(l)}catch(d){if(!(d instanceof Jx.default))throw d;return a.call(this,d),await c.call(this,d.missingSchema),s.call(this,l)}}function a({missingSchema:l,missingRef:d}){if(this.refs[l])throw new Error(`AnySchema ${l} is loaded but ${d} cannot be resolved`)}async function c(l){let d=await u.call(this,l);this.refs[l]||await i.call(this,d.$schema),this.refs[l]||this.addSchema(d,l,r)}async function u(l){let d=this._loading[l];if(d)return d;try{return await(this._loading[l]=o(l))}finally{delete this._loading[l]}}}addSchema(t,r,o,n=this.opts.validateSchema){if(Array.isArray(t)){for(let s of t)this.addSchema(s,void 0,o,n);return this}let i;if(typeof t=="object"){let{schemaId:s}=this.opts;if(i=t[s],i!==void 0&&typeof i!="string")throw new Error(`schema ${s} must be string`)}return r=(0,Ea.normalizeId)(r||i),this._checkUnique(r),this.schemas[r]=this._addSchema(t,o,r,n,!0),this}addMetaSchema(t,r,o=this.opts.validateSchema){return this.addSchema(t,r,!0,o),this}validateSchema(t,r){if(typeof t=="boolean")return!0;let o;if(o=t.$schema,o!==void 0&&typeof o!="string")throw new Error("$schema must be a string");if(o=o||this.opts.defaultMeta||this.defaultMeta(),!o)return this.logger.warn("meta-schema not available"),this.errors=null,!0;let n=this.validate(o,t);if(!n&&r){let i="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(i);else throw new Error(i)}return n}getSchema(t){let r;for(;typeof(r=Hx.call(this,t))=="string";)t=r;if(r===void 0){let{schemaId:o}=this.opts,n=new za.SchemaEnv({schema:{},schemaId:o});if(r=za.resolveSchema.call(this,n,t),!r)return;this.refs[t]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{let r=Hx.call(this,t);return typeof r=="object"&&this._cache.delete(r.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{let r=t;this._cache.delete(r);let o=t[this.opts.schemaId];return o&&(o=(0,Ea.normalizeId)(o),delete this.schemas[o],delete this.refs[o]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(let r of t)this.addKeyword(r);return this}addKeyword(t,r){let o;if(typeof t=="string")o=t,typeof r=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),r.keyword=o);else if(typeof t=="object"&&r===void 0){if(r=t,o=r.keyword,Array.isArray(o)&&!o.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(cq.call(this,o,r),!r)return(0,dv.eachItem)(o,i=>lv.call(this,i)),this;lq.call(this,r);let n={...r,type:(0,vd.getJSONTypes)(r.type),schemaType:(0,vd.getJSONTypes)(r.schemaType)};return(0,dv.eachItem)(o,n.type.length===0?i=>lv.call(this,i,n):i=>n.type.forEach(s=>lv.call(this,i,n,s))),this}getKeyword(t){let r=this.RULES.all[t];return typeof r=="object"?r.definition:!!r}removeKeyword(t){let{RULES:r}=this;delete r.keywords[t],delete r.all[t];for(let o of r.rules){let n=o.rules.findIndex(i=>i.keyword===t);n>=0&&o.rules.splice(n,1)}return this}addFormat(t,r){return typeof r=="string"&&(r=new RegExp(r)),this.formats[t]=r,this}errorsText(t=this.errors,{separator:r=", ",dataVar:o="data"}={}){return!t||t.length===0?"No errors":t.map(n=>`${o}${n.instancePath} ${n.message}`).reduce((n,i)=>n+r+i)}$dataMetaSchema(t,r){let o=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(let n of r){let i=n.split("/").slice(1),s=t;for(let a of i)s=s[a];for(let a in o){let c=o[a];if(typeof c!="object")continue;let{$data:u}=c.definition,l=s[a];u&&l&&(s[a]=Yx(l))}}return t}_removeAllSchemas(t,r){for(let o in t){let n=t[o];(!r||r.test(o))&&(typeof n=="string"?delete t[o]:n&&!n.meta&&(this._cache.delete(n.schema),delete t[o]))}}_addSchema(t,r,o,n=this.opts.validateSchema,i=this.opts.addUsedSchema){let s,{schemaId:a}=this.opts;if(typeof t=="object")s=t[a];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let c=this._cache.get(t);if(c!==void 0)return c;o=(0,Ea.normalizeId)(s||o);let u=Ea.getSchemaRefs.call(this,t,o);return c=new za.SchemaEnv({schema:t,schemaId:a,meta:r,baseId:o,localRefs:u}),this._cache.set(c.schema,c),i&&!o.startsWith("#")&&(o&&this._checkUnique(o),this.refs[o]=c),n&&this.validateSchema(t,!0),c}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):za.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){let r=this.opts;this.opts=this._metaOpts;try{za.compileSchema.call(this,t)}finally{this.opts=r}}};Ia.ValidationError=WD.default;Ia.MissingRefError=Jx.default;Ye.default=Ia;function Kx(e,t,r,o="error"){for(let n in e){let i=n;i in t&&this.logger[o](`${r}: option ${n}. ${e[i]}`)}}function Hx(e){return e=(0,Ea.normalizeId)(e),this.schemas[e]||this.refs[e]}function tq(){let e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(let t in e)this.addSchema(e[t],t)}function rq(){for(let e in this.opts.formats){let t=this.opts.formats[e];t&&this.addFormat(e,t)}}function nq(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];r.keyword||(r.keyword=t),this.addKeyword(r)}}function oq(){let e={...this.opts};for(let t of BD)delete e[t];return e}var iq={log(){},warn(){},error(){}};function sq(e){if(e===!1)return iq;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}var aq=/^[a-z_$][a-z0-9_$:-]*$/i;function cq(e,t){let{RULES:r}=this;if((0,dv.eachItem)(e,o=>{if(r.keywords[o])throw new Error(`Keyword ${o} is already defined`);if(!aq.test(o))throw new Error(`Keyword ${o} has invalid name`)}),!!t&&t.$data&&!("code"in t||"validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function lv(e,t,r){var o;let n=t?.post;if(r&&n)throw new Error('keyword with "post" flag cannot have "type"');let{RULES:i}=this,s=n?i.post:i.rules.find(({type:c})=>c===r);if(s||(s={type:r,rules:[]},i.rules.push(s)),i.keywords[e]=!0,!t)return;let a={keyword:e,definition:{...t,type:(0,vd.getJSONTypes)(t.type),schemaType:(0,vd.getJSONTypes)(t.schemaType)}};t.before?uq.call(this,s,a,t.before):s.rules.push(a),i.all[e]=a,(o=t.implements)===null||o===void 0||o.forEach(c=>this.addKeyword(c))}function uq(e,t,r){let o=e.rules.findIndex(n=>n.keyword===r);o>=0?e.rules.splice(o,0,t):(e.rules.push(t),this.logger.warn(`rule ${r} is not defined`))}function lq(e){let{metaSchema:t}=e;t!==void 0&&(e.$data&&this.opts.$data&&(t=Yx(t)),e.validateSchema=this.compile(t,!0))}var dq={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Yx(e){return{anyOf:[e,dq]}}});var Qx=$(pv=>{"use strict";Object.defineProperty(pv,"__esModule",{value:!0});var pq={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};pv.default=pq});var n0=$(Fn=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.callRef=Fn.getValidate=void 0;var fq=Pa(),e0=Zt(),St=Q(),ni=Nr(),t0=gd(),_d=ve(),mq={keyword:"$ref",schemaType:"string",code(e){let{gen:t,schema:r,it:o}=e,{baseId:n,schemaEnv:i,validateName:s,opts:a,self:c}=o,{root:u}=i;if((r==="#"||r==="#/")&&n===u.baseId)return d();let l=t0.resolveRef.call(c,u,n,r);if(l===void 0)throw new fq.default(o.opts.uriResolver,n,r);if(l instanceof t0.SchemaEnv)return h(l);return m(l);function d(){if(i===u)return yd(e,s,i,i.$async);let p=t.scopeValue("root",{ref:u});return yd(e,(0,St._)`${p}.validate`,u,u.$async)}function h(p){let f=r0(e,p);yd(e,f,p,p.$async)}function m(p){let f=t.scopeValue("schema",a.code.source===!0?{ref:p,code:(0,St.stringify)(p)}:{ref:p}),v=t.name("valid"),y=e.subschema({schema:p,dataTypes:[],schemaPath:St.nil,topSchemaRef:f,errSchemaPath:r},v);e.mergeEvaluated(y),e.ok(v)}}};function r0(e,t){let{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,St._)`${r.scopeValue("wrapper",{ref:t})}.validate`}Fn.getValidate=r0;function yd(e,t,r,o){let{gen:n,it:i}=e,{allErrors:s,schemaEnv:a,opts:c}=i,u=c.passContext?ni.default.this:St.nil;o?l():d();function l(){if(!a.$async)throw new Error("async schema referenced by sync schema");let p=n.let("valid");n.try(()=>{n.code((0,St._)`await ${(0,e0.callValidateCode)(e,t,u)}`),m(t),s||n.assign(p,!0)},f=>{n.if((0,St._)`!(${f} instanceof ${i.ValidationError})`,()=>n.throw(f)),h(f),s||n.assign(p,!1)}),e.ok(p)}function d(){e.result((0,e0.callValidateCode)(e,t,u),()=>m(t),()=>h(t))}function h(p){let f=(0,St._)`${p}.errors`;n.assign(ni.default.vErrors,(0,St._)`${ni.default.vErrors} === null ? ${f} : ${ni.default.vErrors}.concat(${f})`),n.assign(ni.default.errors,(0,St._)`${ni.default.vErrors}.length`)}function m(p){var f;if(!i.opts.unevaluated)return;let v=(f=r?.validate)===null||f===void 0?void 0:f.evaluated;if(i.props!==!0)if(v&&!v.dynamicProps)v.props!==void 0&&(i.props=_d.mergeEvaluated.props(n,v.props,i.props));else{let y=n.var("props",(0,St._)`${p}.evaluated.props`);i.props=_d.mergeEvaluated.props(n,y,i.props,St.Name)}if(i.items!==!0)if(v&&!v.dynamicItems)v.items!==void 0&&(i.items=_d.mergeEvaluated.items(n,v.items,i.items));else{let y=n.var("items",(0,St._)`${p}.evaluated.items`);i.items=_d.mergeEvaluated.items(n,y,i.items,St.Name)}}}Fn.callRef=yd;Fn.default=mq});var o0=$(fv=>{"use strict";Object.defineProperty(fv,"__esModule",{value:!0});var hq=Qx(),gq=n0(),vq=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",hq.default,gq.default];fv.default=vq});var i0=$(mv=>{"use strict";Object.defineProperty(mv,"__esModule",{value:!0});var bd=Q(),un=bd.operators,$d={maximum:{okStr:"<=",ok:un.LTE,fail:un.GT},minimum:{okStr:">=",ok:un.GTE,fail:un.LT},exclusiveMaximum:{okStr:"<",ok:un.LT,fail:un.GTE},exclusiveMinimum:{okStr:">",ok:un.GT,fail:un.LTE}},_q={message:({keyword:e,schemaCode:t})=>(0,bd.str)`must be ${$d[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,bd._)`{comparison: ${$d[e].okStr}, limit: ${t}}`},yq={keyword:Object.keys($d),type:"number",schemaType:"number",$data:!0,error:_q,code(e){let{keyword:t,data:r,schemaCode:o}=e;e.fail$data((0,bd._)`${r} ${$d[t].fail} ${o} || isNaN(${r})`)}};mv.default=yq});var s0=$(hv=>{"use strict";Object.defineProperty(hv,"__esModule",{value:!0});var Oa=Q(),bq={message:({schemaCode:e})=>(0,Oa.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,Oa._)`{multipleOf: ${e}}`},$q={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:bq,code(e){let{gen:t,data:r,schemaCode:o,it:n}=e,i=n.opts.multipleOfPrecision,s=t.let("res"),a=i?(0,Oa._)`Math.abs(Math.round(${s}) - ${s}) > 1e-${i}`:(0,Oa._)`${s} !== parseInt(${s})`;e.fail$data((0,Oa._)`(${o} === 0 || (${s} = ${r}/${o}, ${a}))`)}};hv.default=$q});var c0=$(gv=>{"use strict";Object.defineProperty(gv,"__esModule",{value:!0});function a0(e){let t=e.length,r=0,o=0,n;for(;o<t;)r++,n=e.charCodeAt(o++),n>=55296&&n<=56319&&o<t&&(n=e.charCodeAt(o),(n&64512)===56320&&o++);return r}gv.default=a0;a0.code='require("ajv/dist/runtime/ucs2length").default'});var u0=$(vv=>{"use strict";Object.defineProperty(vv,"__esModule",{value:!0});var Gn=Q(),wq=ve(),kq=c0(),xq={message({keyword:e,schemaCode:t}){let r=e==="maxLength"?"more":"fewer";return(0,Gn.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,Gn._)`{limit: ${e}}`},Sq={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:xq,code(e){let{keyword:t,data:r,schemaCode:o,it:n}=e,i=t==="maxLength"?Gn.operators.GT:Gn.operators.LT,s=n.opts.unicode===!1?(0,Gn._)`${r}.length`:(0,Gn._)`${(0,wq.useFunc)(e.gen,kq.default)}(${r})`;e.fail$data((0,Gn._)`${s} ${i} ${o}`)}};vv.default=Sq});var l0=$(_v=>{"use strict";Object.defineProperty(_v,"__esModule",{value:!0});var Tq=Zt(),wd=Q(),Pq={message:({schemaCode:e})=>(0,wd.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,wd._)`{pattern: ${e}}`},zq={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:Pq,code(e){let{data:t,$data:r,schema:o,schemaCode:n,it:i}=e,s=i.opts.unicodeRegExp?"u":"",a=r?(0,wd._)`(new RegExp(${n}, ${s}))`:(0,Tq.usePattern)(e,o);e.fail$data((0,wd._)`!${a}.test(${t})`)}};_v.default=zq});var d0=$(yv=>{"use strict";Object.defineProperty(yv,"__esModule",{value:!0});var ja=Q(),Eq={message({keyword:e,schemaCode:t}){let r=e==="maxProperties"?"more":"fewer";return(0,ja.str)`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>(0,ja._)`{limit: ${e}}`},Iq={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:Eq,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxProperties"?ja.operators.GT:ja.operators.LT;e.fail$data((0,ja._)`Object.keys(${r}).length ${n} ${o}`)}};yv.default=Iq});var p0=$(bv=>{"use strict";Object.defineProperty(bv,"__esModule",{value:!0});var Na=Zt(),Ra=Q(),Oq=ve(),jq={message:({params:{missingProperty:e}})=>(0,Ra.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,Ra._)`{missingProperty: ${e}}`},Nq={keyword:"required",type:"object",schemaType:"array",$data:!0,error:jq,code(e){let{gen:t,schema:r,schemaCode:o,data:n,$data:i,it:s}=e,{opts:a}=s;if(!i&&r.length===0)return;let c=r.length>=a.loopRequired;if(s.allErrors?u():l(),a.strictRequired){let m=e.parentSchema.properties,{definedProperties:p}=e.it;for(let f of r)if(m?.[f]===void 0&&!p.has(f)){let v=s.schemaEnv.baseId+s.errSchemaPath,y=`required property "${f}" is not defined at "${v}" (strictRequired)`;(0,Oq.checkStrictMode)(s,y,s.opts.strictRequired)}}function u(){if(c||i)e.block$data(Ra.nil,d);else for(let m of r)(0,Na.checkReportMissingProp)(e,m)}function l(){let m=t.let("missing");if(c||i){let p=t.let("valid",!0);e.block$data(p,()=>h(m,p)),e.ok(p)}else t.if((0,Na.checkMissingProp)(e,r,m)),(0,Na.reportMissingProp)(e,m),t.else()}function d(){t.forOf("prop",o,m=>{e.setParams({missingProperty:m}),t.if((0,Na.noPropertyInData)(t,n,m,a.ownProperties),()=>e.error())})}function h(m,p){e.setParams({missingProperty:m}),t.forOf(m,o,()=>{t.assign(p,(0,Na.propertyInData)(t,n,m,a.ownProperties)),t.if((0,Ra.not)(p),()=>{e.error(),t.break()})},Ra.nil)}}};bv.default=Nq});var f0=$($v=>{"use strict";Object.defineProperty($v,"__esModule",{value:!0});var Ca=Q(),Rq={message({keyword:e,schemaCode:t}){let r=e==="maxItems"?"more":"fewer";return(0,Ca.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,Ca._)`{limit: ${e}}`},Cq={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:Rq,code(e){let{keyword:t,data:r,schemaCode:o}=e,n=t==="maxItems"?Ca.operators.GT:Ca.operators.LT;e.fail$data((0,Ca._)`${r}.length ${n} ${o}`)}};$v.default=Cq});var kd=$(wv=>{"use strict";Object.defineProperty(wv,"__esModule",{value:!0});var m0=Hs();m0.code='require("ajv/dist/runtime/equal").default';wv.default=m0});var h0=$(xv=>{"use strict";Object.defineProperty(xv,"__esModule",{value:!0});var kv=wa(),Xe=Q(),Aq=ve(),Dq=kd(),qq={message:({params:{i:e,j:t}})=>(0,Xe.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,Xe._)`{i: ${e}, j: ${t}}`},Mq={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:qq,code(e){let{gen:t,data:r,$data:o,schema:n,parentSchema:i,schemaCode:s,it:a}=e;if(!o&&!n)return;let c=t.let("valid"),u=i.items?(0,kv.getSchemaTypes)(i.items):[];e.block$data(c,l,(0,Xe._)`${s} === false`),e.ok(c);function l(){let p=t.let("i",(0,Xe._)`${r}.length`),f=t.let("j");e.setParams({i:p,j:f}),t.assign(c,!0),t.if((0,Xe._)`${p} > 1`,()=>(d()?h:m)(p,f))}function d(){return u.length>0&&!u.some(p=>p==="object"||p==="array")}function h(p,f){let v=t.name("item"),y=(0,kv.checkDataTypes)(u,v,a.opts.strictNumbers,kv.DataType.Wrong),w=t.const("indices",(0,Xe._)`{}`);t.for((0,Xe._)`;${p}--;`,()=>{t.let(v,(0,Xe._)`${r}[${p}]`),t.if(y,(0,Xe._)`continue`),u.length>1&&t.if((0,Xe._)`typeof ${v} == "string"`,(0,Xe._)`${v} += "_"`),t.if((0,Xe._)`typeof ${w}[${v}] == "number"`,()=>{t.assign(f,(0,Xe._)`${w}[${v}]`),e.error(),t.assign(c,!1).break()}).code((0,Xe._)`${w}[${v}] = ${p}`)})}function m(p,f){let v=(0,Aq.useFunc)(t,Dq.default),y=t.name("outer");t.label(y).for((0,Xe._)`;${p}--;`,()=>t.for((0,Xe._)`${f} = ${p}; ${f}--;`,()=>t.if((0,Xe._)`${v}(${r}[${p}], ${r}[${f}])`,()=>{e.error(),t.assign(c,!1).break(y)})))}}};xv.default=Mq});var g0=$(Tv=>{"use strict";Object.defineProperty(Tv,"__esModule",{value:!0});var Sv=Q(),Uq=ve(),Zq=kd(),Vq={message:"must be equal to constant",params:({schemaCode:e})=>(0,Sv._)`{allowedValue: ${e}}`},Lq={keyword:"const",$data:!0,error:Vq,code(e){let{gen:t,data:r,$data:o,schemaCode:n,schema:i}=e;o||i&&typeof i=="object"?e.fail$data((0,Sv._)`!${(0,Uq.useFunc)(t,Zq.default)}(${r}, ${n})`):e.fail((0,Sv._)`${i} !== ${r}`)}};Tv.default=Lq});var v0=$(Pv=>{"use strict";Object.defineProperty(Pv,"__esModule",{value:!0});var Aa=Q(),Fq=ve(),Gq=kd(),Wq={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,Aa._)`{allowedValues: ${e}}`},Kq={keyword:"enum",schemaType:"array",$data:!0,error:Wq,code(e){let{gen:t,data:r,$data:o,schema:n,schemaCode:i,it:s}=e;if(!o&&n.length===0)throw new Error("enum must have non-empty array");let a=n.length>=s.opts.loopEnum,c,u=()=>c??(c=(0,Fq.useFunc)(t,Gq.default)),l;if(a||o)l=t.let("valid"),e.block$data(l,d);else{if(!Array.isArray(n))throw new Error("ajv implementation error");let m=t.const("vSchema",i);l=(0,Aa.or)(...n.map((p,f)=>h(m,f)))}e.pass(l);function d(){t.assign(l,!1),t.forOf("v",i,m=>t.if((0,Aa._)`${u()}(${r}, ${m})`,()=>t.assign(l,!0).break()))}function h(m,p){let f=n[p];return typeof f=="object"&&f!==null?(0,Aa._)`${u()}(${r}, ${m}[${p}])`:(0,Aa._)`${r} === ${f}`}}};Pv.default=Kq});var _0=$(zv=>{"use strict";Object.defineProperty(zv,"__esModule",{value:!0});var Hq=i0(),Jq=s0(),Bq=u0(),Yq=l0(),Xq=d0(),Qq=p0(),eM=f0(),tM=h0(),rM=g0(),nM=v0(),oM=[Hq.default,Jq.default,Bq.default,Yq.default,Xq.default,Qq.default,eM.default,tM.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},rM.default,nM.default];zv.default=oM});var Iv=$(Da=>{"use strict";Object.defineProperty(Da,"__esModule",{value:!0});Da.validateAdditionalItems=void 0;var Wn=Q(),Ev=ve(),iM={message:({params:{len:e}})=>(0,Wn.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,Wn._)`{limit: ${e}}`},sM={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:iM,code(e){let{parentSchema:t,it:r}=e,{items:o}=t;if(!Array.isArray(o)){(0,Ev.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}y0(e,o)}};function y0(e,t){let{gen:r,schema:o,data:n,keyword:i,it:s}=e;s.items=!0;let a=r.const("len",(0,Wn._)`${n}.length`);if(o===!1)e.setParams({len:t.length}),e.pass((0,Wn._)`${a} <= ${t.length}`);else if(typeof o=="object"&&!(0,Ev.alwaysValidSchema)(s,o)){let u=r.var("valid",(0,Wn._)`${a} <= ${t.length}`);r.if((0,Wn.not)(u),()=>c(u)),e.ok(u)}function c(u){r.forRange("i",t.length,a,l=>{e.subschema({keyword:i,dataProp:l,dataPropType:Ev.Type.Num},u),s.allErrors||r.if((0,Wn.not)(u),()=>r.break())})}}Da.validateAdditionalItems=y0;Da.default=sM});var Ov=$(qa=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});qa.validateTuple=void 0;var b0=Q(),xd=ve(),aM=Zt(),cM={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){let{schema:t,it:r}=e;if(Array.isArray(t))return $0(e,"additionalItems",t);r.items=!0,!(0,xd.alwaysValidSchema)(r,t)&&e.ok((0,aM.validateArray)(e))}};function $0(e,t,r=e.schema){let{gen:o,parentSchema:n,data:i,keyword:s,it:a}=e;l(n),a.opts.unevaluated&&r.length&&a.items!==!0&&(a.items=xd.mergeEvaluated.items(o,r.length,a.items));let c=o.name("valid"),u=o.const("len",(0,b0._)`${i}.length`);r.forEach((d,h)=>{(0,xd.alwaysValidSchema)(a,d)||(o.if((0,b0._)`${u} > ${h}`,()=>e.subschema({keyword:s,schemaProp:h,dataProp:h},c)),e.ok(c))});function l(d){let{opts:h,errSchemaPath:m}=a,p=r.length,f=p===d.minItems&&(p===d.maxItems||d[t]===!1);if(h.strictTuples&&!f){let v=`"${s}" is ${p}-tuple, but minItems or maxItems/${t} are not specified or different at path "${m}"`;(0,xd.checkStrictMode)(a,v,h.strictTuples)}}}qa.validateTuple=$0;qa.default=cM});var w0=$(jv=>{"use strict";Object.defineProperty(jv,"__esModule",{value:!0});var uM=Ov(),lM={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,uM.validateTuple)(e,"items")};jv.default=lM});var x0=$(Nv=>{"use strict";Object.defineProperty(Nv,"__esModule",{value:!0});var k0=Q(),dM=ve(),pM=Zt(),fM=Iv(),mM={message:({params:{len:e}})=>(0,k0.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,k0._)`{limit: ${e}}`},hM={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:mM,code(e){let{schema:t,parentSchema:r,it:o}=e,{prefixItems:n}=r;o.items=!0,!(0,dM.alwaysValidSchema)(o,t)&&(n?(0,fM.validateAdditionalItems)(e,n):e.ok((0,pM.validateArray)(e)))}};Nv.default=hM});var S0=$(Rv=>{"use strict";Object.defineProperty(Rv,"__esModule",{value:!0});var Lt=Q(),Sd=ve(),gM={message:({params:{min:e,max:t}})=>t===void 0?(0,Lt.str)`must contain at least ${e} valid item(s)`:(0,Lt.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,Lt._)`{minContains: ${e}}`:(0,Lt._)`{minContains: ${e}, maxContains: ${t}}`},vM={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:gM,code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e,s,a,{minContains:c,maxContains:u}=o;i.opts.next?(s=c===void 0?1:c,a=u):s=1;let l=t.const("len",(0,Lt._)`${n}.length`);if(e.setParams({min:s,max:a}),a===void 0&&s===0){(0,Sd.checkStrictMode)(i,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(a!==void 0&&s>a){(0,Sd.checkStrictMode)(i,'"minContains" > "maxContains" is always invalid'),e.fail();return}if((0,Sd.alwaysValidSchema)(i,r)){let f=(0,Lt._)`${l} >= ${s}`;a!==void 0&&(f=(0,Lt._)`${f} && ${l} <= ${a}`),e.pass(f);return}i.items=!0;let d=t.name("valid");a===void 0&&s===1?m(d,()=>t.if(d,()=>t.break())):s===0?(t.let(d,!0),a!==void 0&&t.if((0,Lt._)`${n}.length > 0`,h)):(t.let(d,!1),h()),e.result(d,()=>e.reset());function h(){let f=t.name("_valid"),v=t.let("count",0);m(f,()=>t.if(f,()=>p(v)))}function m(f,v){t.forRange("i",0,l,y=>{e.subschema({keyword:"contains",dataProp:y,dataPropType:Sd.Type.Num,compositeRule:!0},f),v()})}function p(f){t.code((0,Lt._)`${f}++`),a===void 0?t.if((0,Lt._)`${f} >= ${s}`,()=>t.assign(d,!0).break()):(t.if((0,Lt._)`${f} > ${a}`,()=>t.assign(d,!1).break()),s===1?t.assign(d,!0):t.if((0,Lt._)`${f} >= ${s}`,()=>t.assign(d,!0)))}}};Rv.default=vM});var z0=$(gr=>{"use strict";Object.defineProperty(gr,"__esModule",{value:!0});gr.validateSchemaDeps=gr.validatePropertyDeps=gr.error=void 0;var Cv=Q(),_M=ve(),Ma=Zt();gr.error={message:({params:{property:e,depsCount:t,deps:r}})=>{let o=t===1?"property":"properties";return(0,Cv.str)`must have ${o} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:o}})=>(0,Cv._)`{property: ${e},
14
14
  missingProperty: ${o},
15
15
  depsCount: ${t},
16
- deps: ${r}}`};var d4={keyword:"dependencies",type:"object",schemaType:"object",error:hr.error,code(e){let[t,r]=p4(e);S0(e,t),T0(e,r)}};function p4({schema:e}){let t={},r={};for(let o in e){if(o==="__proto__")continue;let n=Array.isArray(e[o])?t:r;n[o]=e[o]}return[t,r]}function S0(e,t=e.schema){let{gen:r,data:o,it:n}=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,Da.propertyInData)(r,o,s,n.opts.ownProperties);e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),n.allErrors?r.if(c,()=>{for(let u of a)(0,Da.checkReportMissingProp)(e,u)}):(r.if((0,Rv._)`${c} && (${(0,Da.checkMissingProp)(e,a,i)})`),(0,Da.reportMissingProp)(e,i),r.else())}}hr.validatePropertyDeps=S0;function T0(e,t=e.schema){let{gen:r,data:o,keyword:n,it:i}=e,s=r.name("valid");for(let a in t)(0,l4.alwaysValidSchema)(i,t[a])||(r.if((0,Da.propertyInData)(r,o,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:n,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s))}hr.validateSchemaDeps=T0;hr.default=d4});var E0=b(Cv=>{"use strict";Object.defineProperty(Cv,"__esModule",{value:!0});var z0=Q(),f4=ve(),m4={message:"property name must be valid",params:({params:e})=>(0,z0._)`{propertyName: ${e.propertyName}}`},h4={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:m4,code(e){let{gen:t,schema:r,data:o,it:n}=e;if((0,f4.alwaysValidSchema)(n,r))return;let i=t.name("valid");t.forIn("key",o,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if((0,z0.not)(i),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(i)}};Cv.default=h4});var Dv=b(Av=>{"use strict";Object.defineProperty(Av,"__esModule",{value:!0});var xd=Mt(),rr=Q(),g4=Or(),Sd=ve(),v4={message:"must NOT have additional properties",params:({params:e})=>(0,rr._)`{additionalProperty: ${e.additionalProperty}}`},_4={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:v4,code(e){let{gen:t,schema:r,parentSchema:o,data:n,errsCount:i,it:s}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&(0,Sd.alwaysValidSchema)(s,r))return;let u=(0,xd.allSchemaProperties)(o.properties),l=(0,xd.allSchemaProperties)(o.patternProperties);d(),e.ok((0,rr._)`${i} === ${g4.default.errors}`);function d(){t.forIn("key",n,g=>{!u.length&&!l.length?p(g):t.if(h(g),()=>p(g))})}function h(g){let y;if(u.length>8){let w=(0,Sd.schemaRefOrVal)(s,o.properties,"properties");y=(0,xd.isOwnProperty)(t,w,g)}else u.length?y=(0,rr.or)(...u.map(w=>(0,rr._)`${g} === ${w}`)):y=rr.nil;return l.length&&(y=(0,rr.or)(y,...l.map(w=>(0,rr._)`${(0,xd.usePattern)(e,w)}.test(${g})`))),(0,rr.not)(y)}function m(g){t.code((0,rr._)`delete ${n}[${g}]`)}function p(g){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){m(g);return}if(r===!1){e.setParams({additionalProperty:g}),e.error(),a||t.break();return}if(typeof r=="object"&&!(0,Sd.alwaysValidSchema)(s,r)){let y=t.name("valid");c.removeAdditional==="failing"?(f(g,y,!1),t.if((0,rr.not)(y),()=>{e.reset(),m(g)})):(f(g,y),a||t.if((0,rr.not)(y),()=>t.break()))}}function f(g,y,w){let k={keyword:"additionalProperties",dataProp:g,dataPropType:Sd.Type.Str};w===!1&&Object.assign(k,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(k,y)}}};Av.default=_4});var O0=b(Mv=>{"use strict";Object.defineProperty(Mv,"__esModule",{value:!0});var y4=xa(),I0=Mt(),qv=ve(),j0=Dv(),$4={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&j0.default.code(new y4.KeywordCxt(i,j0.default,"additionalProperties"));let s=(0,I0.allSchemaProperties)(r);for(let d of s)i.definedProperties.add(d);i.opts.unevaluated&&s.length&&i.props!==!0&&(i.props=qv.mergeEvaluated.props(t,(0,qv.toHash)(s),i.props));let a=s.filter(d=>!(0,qv.alwaysValidSchema)(i,r[d]));if(a.length===0)return;let c=t.name("valid");for(let d of a)u(d)?l(d):(t.if((0,I0.propertyInData)(t,n,d,i.opts.ownProperties)),l(d),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(d),e.ok(c);function u(d){return i.opts.useDefaults&&!i.compositeRule&&r[d].default!==void 0}function l(d){e.subschema({keyword:"properties",schemaProp:d,dataProp:d},c)}}};Mv.default=$4});var A0=b(Uv=>{"use strict";Object.defineProperty(Uv,"__esModule",{value:!0});var N0=Mt(),Td=Q(),R0=ve(),C0=ve(),b4={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:n,it:i}=e,{opts:s}=i,a=(0,N0.allSchemaProperties)(r),c=a.filter(f=>(0,R0.alwaysValidSchema)(i,r[f]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&n.properties,l=t.name("valid");i.props!==!0&&!(i.props instanceof Td.Name)&&(i.props=(0,C0.evaluatedPropsToName)(t,i.props));let{props:d}=i;h();function h(){for(let f of a)u&&m(f),i.allErrors?p(f):(t.var(l,!0),p(f),t.if(l))}function m(f){for(let g in u)new RegExp(f).test(g)&&(0,R0.checkStrictMode)(i,`property ${g} matches pattern ${f} (use allowMatchingProperties)`)}function p(f){t.forIn("key",o,g=>{t.if((0,Td._)`${(0,N0.usePattern)(e,f)}.test(${g})`,()=>{let y=c.includes(f);y||e.subschema({keyword:"patternProperties",schemaProp:f,dataProp:g,dataPropType:C0.Type.Str},l),i.opts.unevaluated&&d!==!0?t.assign((0,Td._)`${d}[${g}]`,!0):!y&&!i.allErrors&&t.if((0,Td.not)(l),()=>t.break())})})}}};Uv.default=b4});var D0=b(Zv=>{"use strict";Object.defineProperty(Zv,"__esModule",{value:!0});var w4=ve(),k4={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:o}=e;if((0,w4.alwaysValidSchema)(o,r)){e.fail();return}let n=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},n),e.failResult(n,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};Zv.default=k4});var q0=b(Lv=>{"use strict";Object.defineProperty(Lv,"__esModule",{value:!0});var x4=Mt(),S4={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:x4.validateUnion,error:{message:"must match a schema in anyOf"}};Lv.default=S4});var M0=b(Vv=>{"use strict";Object.defineProperty(Vv,"__esModule",{value:!0});var Pd=Q(),T4=ve(),P4={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Pd._)`{passingSchemas: ${e.passing}}`},z4={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:P4,code(e){let{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.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,d)=>{let h;(0,T4.alwaysValidSchema)(n,l)?t.var(c,!0):h=e.subschema({keyword:"oneOf",schemaProp:d,compositeRule:!0},c),d>0&&t.if((0,Pd._)`${c} && ${s}`).assign(s,!1).assign(a,(0,Pd._)`[${a}, ${d}]`).else(),t.if(c,()=>{t.assign(s,!0),t.assign(a,d),h&&e.mergeEvaluated(h,Pd.Name)})})}}};Vv.default=z4});var U0=b(Fv=>{"use strict";Object.defineProperty(Fv,"__esModule",{value:!0});var E4=ve(),I4={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:o}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");let n=t.name("valid");r.forEach((i,s)=>{if((0,E4.alwaysValidSchema)(o,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},n);e.ok(n),e.mergeEvaluated(a)})}};Fv.default=I4});var V0=b(Gv=>{"use strict";Object.defineProperty(Gv,"__esModule",{value:!0});var zd=Q(),L0=ve(),j4={message:({params:e})=>(0,zd.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,zd._)`{failingKeyword: ${e.ifClause}}`},O4={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:j4,code(e){let{gen:t,parentSchema:r,it:o}=e;r.then===void 0&&r.else===void 0&&(0,L0.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let n=Z0(o,"then"),i=Z0(o,"else");if(!n&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),n&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else n?t.if(a,u("then")):t.if((0,zd.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,d){return()=>{let h=e.subschema({keyword:l},a);t.assign(s,a),e.mergeValidEvaluated(h,s),d?t.assign(d,(0,zd._)`${l}`):e.setParams({ifClause:l})}}}};function Z0(e,t){let r=e.schema[t];return r!==void 0&&!(0,L0.alwaysValidSchema)(e,r)}Gv.default=O4});var F0=b(Wv=>{"use strict";Object.defineProperty(Wv,"__esModule",{value:!0});var N4=ve(),R4={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){t.if===void 0&&(0,N4.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};Wv.default=R4});var G0=b(Kv=>{"use strict";Object.defineProperty(Kv,"__esModule",{value:!0});var C4=Ev(),A4=b0(),D4=Iv(),q4=k0(),M4=x0(),U4=P0(),Z4=E0(),L4=Dv(),V4=O0(),F4=A0(),G4=D0(),W4=q0(),K4=M0(),H4=U0(),J4=V0(),B4=F0();function Y4(e=!1){let t=[G4.default,W4.default,K4.default,H4.default,J4.default,B4.default,Z4.default,L4.default,U4.default,V4.default,F4.default];return e?t.push(A4.default,q4.default):t.push(C4.default,D4.default),t.push(M4.default),t}Kv.default=Y4});var W0=b(Hv=>{"use strict";Object.defineProperty(Hv,"__esModule",{value:!0});var Le=Q(),X4={message:({schemaCode:e})=>(0,Le.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Le._)`{format: ${e}}`},Q4={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:X4,code(e,t){let{gen:r,data:o,$data:n,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:d}=a;if(!c.validateFormats)return;n?h():m();function h(){let p=r.scopeValue("formats",{ref:d.formats,code:c.code.formats}),f=r.const("fDef",(0,Le._)`${p}[${s}]`),g=r.let("fType"),y=r.let("format");r.if((0,Le._)`typeof ${f} == "object" && !(${f} instanceof RegExp)`,()=>r.assign(g,(0,Le._)`${f}.type || "string"`).assign(y,(0,Le._)`${f}.validate`),()=>r.assign(g,(0,Le._)`"string"`).assign(y,f)),e.fail$data((0,Le.or)(w(),k()));function w(){return c.strictSchema===!1?Le.nil:(0,Le._)`${s} && !${y}`}function k(){let E=l.$async?(0,Le._)`(${f}.async ? await ${y}(${o}) : ${y}(${o}))`:(0,Le._)`${y}(${o})`,P=(0,Le._)`(typeof ${y} == "function" ? ${E} : ${y}.test(${o}))`;return(0,Le._)`${y} && ${y} !== true && ${g} === ${t} && !${P}`}}function m(){let p=d.formats[i];if(!p){w();return}if(p===!0)return;let[f,g,y]=k(p);f===t&&e.pass(E());function w(){if(c.strictSchema===!1){d.logger.warn(P());return}throw new Error(P());function P(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function k(P){let ze=P instanceof RegExp?(0,Le.regexpCode)(P):c.code.formats?(0,Le._)`${c.code.formats}${(0,Le.getProperty)(i)}`:void 0,Me=r.scopeValue("formats",{key:i,ref:P,code:ze});return typeof P=="object"&&!(P instanceof RegExp)?[P.type||"string",P.validate,(0,Le._)`${Me}.validate`]:["string",P,Me]}function E(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!l.$async)throw new Error("async format in sync schema");return(0,Le._)`await ${y}(${o})`}return typeof g=="function"?(0,Le._)`${y}(${o})`:(0,Le._)`${y}.test(${o})`}}}};Hv.default=Q4});var K0=b(Jv=>{"use strict";Object.defineProperty(Jv,"__esModule",{value:!0});var eM=W0(),tM=[eM.default];Jv.default=tM});var H0=b(ni=>{"use strict";Object.defineProperty(ni,"__esModule",{value:!0});ni.contentVocabulary=ni.metadataVocabulary=void 0;ni.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];ni.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var B0=b(Bv=>{"use strict";Object.defineProperty(Bv,"__esModule",{value:!0});var rM=n0(),nM=v0(),oM=G0(),iM=K0(),J0=H0(),sM=[rM.default,nM.default,(0,oM.default)(),iM.default,J0.metadataVocabulary,J0.contentVocabulary];Bv.default=sM});var X0=b(Ed=>{"use strict";Object.defineProperty(Ed,"__esModule",{value:!0});Ed.DiscrError=void 0;var Y0;(function(e){e.Tag="tag",e.Mapping="mapping"})(Y0||(Ed.DiscrError=Y0={}))});var eS=b(Xv=>{"use strict";Object.defineProperty(Xv,"__esModule",{value:!0});var oi=Q(),Yv=X0(),Q0=md(),aM=Sa(),cM=ve(),uM={message:({params:{discrError:e,tagName:t}})=>e===Yv.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,oi._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},lM={keyword:"discriminator",type:"object",schemaType:"object",error:uM,code(e){let{gen:t,data:r,schema:o,parentSchema:n,it:i}=e,{oneOf:s}=n;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=o.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",(0,oi._)`${r}${(0,oi.getProperty)(a)}`);t.if((0,oi._)`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:Yv.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let m=h();t.if(!1);for(let p in m)t.elseIf((0,oi._)`${u} === ${p}`),t.assign(c,d(m[p]));t.else(),e.error(!1,{discrError:Yv.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function d(m){let p=t.name("valid"),f=e.subschema({keyword:"oneOf",schemaProp:m},p);return e.mergeEvaluated(f,oi.Name),p}function h(){var m;let p={},f=y(n),g=!0;for(let E=0;E<s.length;E++){let P=s[E];if(P?.$ref&&!(0,cM.schemaHasRulesButRef)(P,i.self.RULES)){let Me=P.$ref;if(P=Q0.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,Me),P instanceof Q0.SchemaEnv&&(P=P.schema),P===void 0)throw new aM.default(i.opts.uriResolver,i.baseId,Me)}let ze=(m=P?.properties)===null||m===void 0?void 0:m[a];if(typeof ze!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);g=g&&(f||y(P)),w(ze,E)}if(!g)throw new Error(`discriminator: "${a}" must be required`);return p;function y({required:E}){return Array.isArray(E)&&E.includes(a)}function w(E,P){if(E.const)k(E.const,P);else if(E.enum)for(let ze of E.enum)k(ze,P);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function k(E,P){if(typeof E!="string"||E in p)throw new Error(`discriminator: "${a}" values must be unique strings`);p[E]=P}}}};Xv.default=lM});var tS=b((uH,dM)=>{dM.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 nS=b((Ae,Qv)=>{"use strict";Object.defineProperty(Ae,"__esModule",{value:!0});Ae.MissingRefError=Ae.ValidationError=Ae.CodeGen=Ae.Name=Ae.nil=Ae.stringify=Ae.str=Ae._=Ae.KeywordCxt=Ae.Ajv=void 0;var pM=Yx(),fM=B0(),mM=eS(),rS=tS(),hM=["/properties"],Id="http://json-schema.org/draft-07/schema",ii=class extends pM.default{_addVocabularies(){super._addVocabularies(),fM.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(mM.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(rS,hM):rS;this.addMetaSchema(t,Id,!1),this.refs["http://json-schema.org/schema"]=Id}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(Id)?Id:void 0)}};Ae.Ajv=ii;Qv.exports=Ae=ii;Qv.exports.Ajv=ii;Object.defineProperty(Ae,"__esModule",{value:!0});Ae.default=ii;var gM=xa();Object.defineProperty(Ae,"KeywordCxt",{enumerable:!0,get:function(){return gM.KeywordCxt}});var si=Q();Object.defineProperty(Ae,"_",{enumerable:!0,get:function(){return si._}});Object.defineProperty(Ae,"str",{enumerable:!0,get:function(){return si.str}});Object.defineProperty(Ae,"stringify",{enumerable:!0,get:function(){return si.stringify}});Object.defineProperty(Ae,"nil",{enumerable:!0,get:function(){return si.nil}});Object.defineProperty(Ae,"Name",{enumerable:!0,get:function(){return si.Name}});Object.defineProperty(Ae,"CodeGen",{enumerable:!0,get:function(){return si.CodeGen}});var vM=pd();Object.defineProperty(Ae,"ValidationError",{enumerable:!0,get:function(){return vM.default}});var _M=Sa();Object.defineProperty(Ae,"MissingRefError",{enumerable:!0,get:function(){return _M.default}})});var oS=b(ai=>{"use strict";Object.defineProperty(ai,"__esModule",{value:!0});ai.formatLimitDefinition=void 0;var yM=nS(),nr=Q(),ln=nr.operators,jd={formatMaximum:{okStr:"<=",ok:ln.LTE,fail:ln.GT},formatMinimum:{okStr:">=",ok:ln.GTE,fail:ln.LT},formatExclusiveMaximum:{okStr:"<",ok:ln.LT,fail:ln.GTE},formatExclusiveMinimum:{okStr:">",ok:ln.GT,fail:ln.LTE}},$M={message:({keyword:e,schemaCode:t})=>(0,nr.str)`should be ${jd[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,nr._)`{comparison: ${jd[e].okStr}, limit: ${t}}`};ai.formatLimitDefinition={keyword:Object.keys(jd),type:"string",schemaType:"string",$data:!0,error:$M,code(e){let{gen:t,data:r,schemaCode:o,keyword:n,it:i}=e,{opts:s,self:a}=i;if(!s.validateFormats)return;let c=new yM.KeywordCxt(i,a.RULES.all.format.definition,"format");c.$data?u():l();function u(){let h=t.scopeValue("formats",{ref:a.formats,code:s.code.formats}),m=t.const("fmt",(0,nr._)`${h}[${c.schemaCode}]`);e.fail$data((0,nr.or)((0,nr._)`typeof ${m} != "object"`,(0,nr._)`${m} instanceof RegExp`,(0,nr._)`typeof ${m}.compare != "function"`,d(m)))}function l(){let h=c.schema,m=a.formats[h];if(!m||m===!0)return;if(typeof m!="object"||m instanceof RegExp||typeof m.compare!="function")throw new Error(`"${n}": format "${h}" does not define "compare" function`);let p=t.scopeValue("formats",{key:h,ref:m,code:s.code.formats?(0,nr._)`${s.code.formats}${(0,nr.getProperty)(h)}`:void 0});e.fail$data(d(p))}function d(h){return(0,nr._)`${h}.compare(${r}, ${o}) ${jd[n].fail} 0`}},dependencies:["format"]};var bM=e=>(e.addKeyword(ai.formatLimitDefinition),e);ai.default=bM});var cS=b((qa,aS)=>{"use strict";Object.defineProperty(qa,"__esModule",{value:!0});var ci=Vk(),wM=oS(),e_=Q(),iS=new e_.Name("fullFormats"),kM=new e_.Name("fastFormats"),t_=(e,t={keywords:!0})=>{if(Array.isArray(t))return sS(e,t,ci.fullFormats,iS),e;let[r,o]=t.mode==="fast"?[ci.fastFormats,kM]:[ci.fullFormats,iS],n=t.formats||ci.formatNames;return sS(e,n,r,o),t.keywords&&(0,wM.default)(e),e};t_.get=(e,t="full")=>{let o=(t==="fast"?ci.fastFormats:ci.fullFormats)[e];if(!o)throw new Error(`Unknown format "${e}"`);return o};function sS(e,t,r,o){var n,i;(n=(i=e.opts.code).formats)!==null&&n!==void 0||(i.formats=(0,e_._)`require("ajv-formats/dist/formats").${o}`);for(let s of t)e.addFormat(s,r[s])}aS.exports=qa=t_;Object.defineProperty(qa,"__esModule",{value:!0});qa.default=t_});var Rr=b((z3,xS)=>{var u_=Object.defineProperty,BM=Object.getOwnPropertyDescriptor,YM=Object.getOwnPropertyNames,XM=Object.prototype.hasOwnProperty,QM=(e,t)=>{for(var r in t)u_(e,r,{get:t[r],enumerable:!0})},eU=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of YM(t))!XM.call(e,n)&&n!==r&&u_(e,n,{get:()=>t[n],enumerable:!(o=BM(t,n))||o.enumerable});return e},tU=e=>eU(u_({},"__esModule",{value:!0}),e),kS={};QM(kS,{APIV2Client:()=>aU,VantageAPIError:()=>Md,pathEncode:()=>S});xS.exports=tU(kS);function S(e){return encodeURIComponent(e)}var rU={"/v2/exchange_rates/csv":{POST:!0},"/v2/business_metrics/{}/values.csv":{PUT:!0},"/v2/integrations/{}/costs.csv":{POST:!0}},Ua={};function nU(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}for(let[e,t]of Object.entries(rU)){let r=e.split("{}").map(nU).join("(.+?)");for(let[o,n]of Object.entries(t))n&&(Ua[o]||(Ua[o]=[]),Ua[o].push(new RegExp(`^${r}$`)))}function oU(e,t){if(Object.prototype.hasOwnProperty.call(Ua,e))for(let r of Ua[e]){let o=r.test(t);if(r.lastIndex=0,o)return!0}return!1}function iU(e,t){if(t)for(let[r,o]of Object.entries(t))e.searchParams.append(r,Array.isArray(o)?o.map(String).join(","):String(o))}var Md=class extends Error{constructor(e,t,r){let o=null;if(e!==null)try{let i=JSON.parse(r);Array.isArray(i.errors)&&(o=i.errors)}catch{}let n=e===null?`Vantage API Error: ${r}`:`Vantage API Error: ${e} ${t}`+(o?` - ${o.join(", ")}`:"");super(n),this.status=e,this.statusText=t,this.body=r,this.errors=o}errors};async function c_(e,t,r,o,n){let i;try{i=await fetch(e.toString(),{method:t,headers:r,body:o})}catch(s){let a=s instanceof Error?s.message:String(s),c=new Md(null,null,a);if(n)return[null,c];throw c}if(!i.ok){let s=new Md(i.status,i.statusText,await i.text());if(n)return[null,s];throw s}if(i.status===204)return n?[void 0,null]:void 0;try{let s=await i.text(),a;return s&&(a=JSON.parse(s)),n?[a,null]:a}catch(s){let a=s instanceof Error?s.message:String(s),c=new Md(i.status,i.statusText,a);if(n)return[null,c];throw c}}var sU=class{constructor(e,t,r){this.bearerToken=e,this.neverThrow=t,this.baseUrl=r}async request(e,t,r){let o=new URL(e,this.baseUrl),n={Authorization:`Bearer ${this.bearerToken}`};if(t==="GET")return iU(o,r),c_(o,t,n,void 0,this.neverThrow);if(oU(t,e)){let i=new FormData;for(let[s,a]of Object.entries(r))i.append(s,a);return n["Content-Type"]="multipart/form-data",c_(o,t,n,i,this.neverThrow)}return n["Content-Type"]="application/json",c_(o,t,n,JSON.stringify(r),this.neverThrow)}},aU=class extends sU{constructor(e,t=!1,r="https://api.vantage.sh"){super(e,t,r)}_accessGrants;_anomalyAlerts;_anomalyNotifications;_auditLogs;_billingProfiles;_billingRules;_budgetAlerts;_budgets;_businessMetrics;_costAlerts;_costProviderAccounts;_costReports;_costs;_dashboards;_dataExports;_exchangeRates;_financialCommitmentReports;_financialCommitments;_folders;_integrations;_invoices;_kubernetesEfficiencyReports;_managedAccounts;_me;_costProviders;_costServices;_userFeedback;_networkFlowReports;_products;_recommendations;_recommendationViews;_reportNotifications;_resourceReports;_resources;_savedFilters;_segments;_tags;_teams;_unitCosts;_users;_virtualTagConfigs;_workspaces;_ping;get accessGrants(){return this._accessGrants||(this._accessGrants=new cU(this)),this._accessGrants}get anomalyAlerts(){return this._anomalyAlerts||(this._anomalyAlerts=new uU(this)),this._anomalyAlerts}get anomalyNotifications(){return this._anomalyNotifications||(this._anomalyNotifications=new lU(this)),this._anomalyNotifications}get auditLogs(){return this._auditLogs||(this._auditLogs=new dU(this)),this._auditLogs}get billingProfiles(){return this._billingProfiles||(this._billingProfiles=new pU(this)),this._billingProfiles}get billingRules(){return this._billingRules||(this._billingRules=new fU(this)),this._billingRules}get budgetAlerts(){return this._budgetAlerts||(this._budgetAlerts=new mU(this)),this._budgetAlerts}get budgets(){return this._budgets||(this._budgets=new hU(this)),this._budgets}get businessMetrics(){return this._businessMetrics||(this._businessMetrics=new gU(this)),this._businessMetrics}get costAlerts(){return this._costAlerts||(this._costAlerts=new vU(this)),this._costAlerts}get costProviderAccounts(){return this._costProviderAccounts||(this._costProviderAccounts=new _U(this)),this._costProviderAccounts}get costReports(){return this._costReports||(this._costReports=new yU(this)),this._costReports}get costs(){return this._costs||(this._costs=new $U(this)),this._costs}get dashboards(){return this._dashboards||(this._dashboards=new bU(this)),this._dashboards}get dataExports(){return this._dataExports||(this._dataExports=new wU(this)),this._dataExports}get exchangeRates(){return this._exchangeRates||(this._exchangeRates=new kU(this)),this._exchangeRates}get financialCommitmentReports(){return this._financialCommitmentReports||(this._financialCommitmentReports=new xU(this)),this._financialCommitmentReports}get financialCommitments(){return this._financialCommitments||(this._financialCommitments=new SU(this)),this._financialCommitments}get folders(){return this._folders||(this._folders=new TU(this)),this._folders}get integrations(){return this._integrations||(this._integrations=new PU(this)),this._integrations}get invoices(){return this._invoices||(this._invoices=new zU(this)),this._invoices}get kubernetesEfficiencyReports(){return this._kubernetesEfficiencyReports||(this._kubernetesEfficiencyReports=new EU(this)),this._kubernetesEfficiencyReports}get managedAccounts(){return this._managedAccounts||(this._managedAccounts=new IU(this)),this._managedAccounts}get me(){return this._me||(this._me=new jU(this)),this._me}get costProviders(){return this._costProviders||(this._costProviders=new OU(this)),this._costProviders}get costServices(){return this._costServices||(this._costServices=new NU(this)),this._costServices}get userFeedback(){return this._userFeedback||(this._userFeedback=new RU(this)),this._userFeedback}get networkFlowReports(){return this._networkFlowReports||(this._networkFlowReports=new CU(this)),this._networkFlowReports}get products(){return this._products||(this._products=new AU(this)),this._products}get recommendations(){return this._recommendations||(this._recommendations=new DU(this)),this._recommendations}get recommendationViews(){return this._recommendationViews||(this._recommendationViews=new qU(this)),this._recommendationViews}get reportNotifications(){return this._reportNotifications||(this._reportNotifications=new MU(this)),this._reportNotifications}get resourceReports(){return this._resourceReports||(this._resourceReports=new UU(this)),this._resourceReports}get resources(){return this._resources||(this._resources=new ZU(this)),this._resources}get savedFilters(){return this._savedFilters||(this._savedFilters=new LU(this)),this._savedFilters}get segments(){return this._segments||(this._segments=new VU(this)),this._segments}get tags(){return this._tags||(this._tags=new FU(this)),this._tags}get teams(){return this._teams||(this._teams=new GU(this)),this._teams}get unitCosts(){return this._unitCosts||(this._unitCosts=new WU(this)),this._unitCosts}get users(){return this._users||(this._users=new KU(this)),this._users}get virtualTagConfigs(){return this._virtualTagConfigs||(this._virtualTagConfigs=new HU(this)),this._virtualTagConfigs}get workspaces(){return this._workspaces||(this._workspaces=new JU(this)),this._workspaces}get ping(){return this._ping||(this._ping=new BU(this)),this._ping}},cU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/access_grants","GET",e)}create(e){return this.client.request("/v2/access_grants","POST",e)}get(e){return this.client.request(`/v2/access_grants/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/access_grants/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/access_grants/${S(e)}`,"DELETE",{})}},uU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/anomaly_alerts","GET",e)}get(e){return this.client.request(`/v2/anomaly_alerts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/anomaly_alerts/${S(e)}`,"PUT",t)}},lU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/anomaly_notifications","GET",e)}create(e){return this.client.request("/v2/anomaly_notifications","POST",e)}get(e){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"DELETE",{})}},dU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/audit_logs","GET",e)}get(e){return this.client.request(`/v2/audit_logs/${S(e)}`,"GET",{})}},pU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/billing_profiles","GET",e)}create(e){return this.client.request("/v2/billing_profiles","POST",e)}get(e){return this.client.request(`/v2/billing_profiles/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/billing_profiles/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/billing_profiles/${S(e)}`,"DELETE",{})}},fU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/billing_rules","GET",e)}create(e){return this.client.request("/v2/billing_rules","POST",e)}get(e){return this.client.request(`/v2/billing_rules/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/billing_rules/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/billing_rules/${S(e)}`,"DELETE",{})}},mU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/budget_alerts","GET",e)}create(e){return this.client.request("/v2/budget_alerts","POST",e)}get(e){return this.client.request(`/v2/budget_alerts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/budget_alerts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/budget_alerts/${S(e)}`,"DELETE",{})}},hU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/budgets","GET",e)}create(e){return this.client.request("/v2/budgets","POST",e)}update(e,t){return this.client.request(`/v2/budgets/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/budgets/${S(e)}`,"DELETE",{})}},gU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/business_metrics","GET",e)}create(e){return this.client.request("/v2/business_metrics","POST",e)}get(e){return this.client.request(`/v2/business_metrics/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/business_metrics/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/business_metrics/${S(e)}`,"DELETE",{})}getValues(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/values`,"GET",t)}getForecastedValues(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/forecasted_values`,"GET",t)}updateValuesCSV(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/values.csv`,"PUT",t)}},vU=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/cost_alerts","POST",e)}get(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events/${S(t)}`,"GET",{})}update(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/cost_alerts/${S(e)}`,"DELETE",{})}getEvents(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events`,"GET",t)}getEvent(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events/${S(t)}`,"GET",{})}},_U=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_provider_accounts","GET",e)}},yU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_reports","GET",e)}create(e){return this.client.request("/v2/cost_reports","POST",e)}get(e){return this.client.request(`/v2/cost_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/cost_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/cost_reports/${S(e)}`,"DELETE",{})}getForecastedCosts(e,t){return this.client.request(`/v2/cost_reports/${S(e)}/forecasted_costs`,"GET",t)}},$U=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/costs","GET",e)}createExport(e){return this.client.request("/v2/costs/data_exports","POST",e)}},bU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/dashboards","GET",e)}create(e){return this.client.request("/v2/dashboards","POST",e)}get(e){return this.client.request(`/v2/dashboards/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/dashboards/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/dashboards/${S(e)}`,"DELETE",{})}},wU=class{constructor(e){this.client=e}get(e){return this.client.request(`/v2/data_exports/${S(e)}`,"GET",{})}},kU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/exchange_rates","GET",e)}createViaCsv(e){return this.client.request("/v2/exchange_rates/csv","POST",e)}},xU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/financial_commitment_reports","GET",e)}create(e){return this.client.request("/v2/financial_commitment_reports","POST",e)}get(e){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"DELETE",{})}},SU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/financial_commitments","GET",e)}},TU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/folders","GET",e)}create(e){return this.client.request("/v2/folders","POST",e)}get(e){return this.client.request(`/v2/folders/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/folders/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/folders/${S(e)}`,"DELETE",{})}},PU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/integrations","GET",e)}get(e){return this.client.request(`/v2/integrations/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/integrations/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/integrations/${S(e)}`,"DELETE",{})}createCustomProviderIntegration(e){return this.client.request("/v2/integrations/custom_provider","POST",e)}createUserCostsUploadViaCsv(e,t){return this.client.request(`/v2/integrations/${S(e)}/costs.csv`,"POST",t)}deleteUserCostsUpload(e,t){return this.client.request(`/v2/integrations/${S(e)}/costs/${S(t)}`,"DELETE",{})}getUserCostsUploads(e){return this.client.request(`/v2/integrations/${S(e)}/costs`,"GET",{})}createGCPIntegration(e){return this.client.request("/v2/integrations/gcp","POST",e)}createAzureIntegration(e){return this.client.request("/v2/integrations/azure","POST",e)}},zU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/invoices","GET",e)}create(e){return this.client.request("/v2/invoices","POST",e)}get(e){return this.client.request(`/v2/invoices/${S(e)}`,"GET",{})}downloadInvoice(e,t){return this.client.request(`/v2/invoices/${S(e)}/download`,"POST",t)}sendInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/send`,"POST",{})}sendAndApproveInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/send_and_approve`,"POST",{})}getCostReport(e){return this.client.request(`/v2/invoices/${S(e)}/cost_report`,"GET",{})}regenerateInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/regenerate`,"POST",{})}},EU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/kubernetes_efficiency_reports","GET",e)}create(e){return this.client.request("/v2/kubernetes_efficiency_reports","POST",e)}get(e){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"DELETE",{})}createExport(e){return this.client.request("/v2/kubernetes_efficiency_reports/data_exports","POST",e)}},IU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/managed_accounts","GET",e)}create(e){return this.client.request("/v2/managed_accounts","POST",e)}get(e){return this.client.request(`/v2/managed_accounts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/managed_accounts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/managed_accounts/${S(e)}`,"DELETE",{})}},jU=class{constructor(e){this.client=e}get(){return this.client.request("/v2/me","GET",{})}},OU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_providers","GET",e)}},NU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_services","GET",e)}},RU=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/user_feedback","POST",e)}},CU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/network_flow_reports","GET",e)}create(e){return this.client.request("/v2/network_flow_reports","POST",e)}get(e){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"DELETE",{})}},AU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/products","GET",e)}get(e,t){return this.client.request(`/v2/products/${S(e)}/prices/${S(t)}`,"GET",{})}getPrices(e,t){return this.client.request(`/v2/products/${S(e)}/prices`,"GET",t)}getPrice(e,t){return this.client.request(`/v2/products/${S(e)}/prices/${S(t)}`,"GET",{})}},DU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/recommendations","GET",e)}get(e){return this.client.request(`/v2/recommendations/${S(e)}`,"GET",{})}getResources(e,t){return this.client.request(`/v2/recommendations/${S(e)}/resources`,"GET",t)}getResource(e,t){return this.client.request(`/v2/recommendations/${S(e)}/resources/${S(t)}`,"GET",{})}},qU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/recommendation_views","GET",e)}create(e){return this.client.request("/v2/recommendation_views","POST",e)}get(e){return this.client.request(`/v2/recommendation_views/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/recommendation_views/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/recommendation_views/${S(e)}`,"DELETE",{})}},MU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/report_notifications","GET",e)}create(e){return this.client.request("/v2/report_notifications","POST",e)}get(e){return this.client.request(`/v2/report_notifications/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/report_notifications/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/report_notifications/${S(e)}`,"DELETE",{})}},UU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/resource_reports","GET",e)}create(e){return this.client.request("/v2/resource_reports","POST",e)}get(e){return this.client.request(`/v2/resource_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/resource_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/resource_reports/${S(e)}`,"DELETE",{})}getColumns(e){return this.client.request("/v2/resource_reports/columns","GET",e)}},ZU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/resources","GET",e)}},LU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/saved_filters","GET",e)}create(e){return this.client.request("/v2/saved_filters","POST",e)}get(e){return this.client.request(`/v2/saved_filters/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/saved_filters/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/saved_filters/${S(e)}`,"DELETE",{})}},VU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/segments","GET",e)}create(e){return this.client.request("/v2/segments","POST",e)}get(e){return this.client.request(`/v2/segments/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/segments/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/segments/${S(e)}`,"DELETE",{})}},FU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/tags","GET",e)}getValues(e,t){return this.client.request(`/v2/tags/${S(e)}/values`,"GET",t)}},GU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/teams","GET",e)}create(e){return this.client.request("/v2/teams","POST",e)}get(e){return this.client.request(`/v2/teams/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/teams/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/teams/${S(e)}`,"DELETE",{})}getMembers(e,t){return this.client.request(`/v2/teams/${S(e)}/members`,"GET",t)}addTeamMember(e,t){return this.client.request(`/v2/teams/${S(e)}/members`,"POST",t)}removeTeamMember(e,t){return this.client.request(`/v2/teams/${S(e)}/members/${S(t)}`,"DELETE",{})}},WU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/unit_costs","GET",e)}createExport(e){return this.client.request("/v2/unit_costs/data_exports","POST",e)}},KU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/users","GET",e)}get(e){return this.client.request(`/v2/users/${S(e)}`,"GET",{})}},HU=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/virtual_tag_configs","POST",e)}get(){return this.client.request("/v2/virtual_tag_configs","GET",{})}update(e,t){return this.client.request(`/v2/virtual_tag_configs/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/virtual_tag_configs/${S(e)}`,"DELETE",{})}updateAsyncVirtualTagConfig(e,t){return this.client.request(`/v2/virtual_tag_configs/${S(e)}/async`,"PUT",t)}getAsyncVirtualTagConfigStatus(e){return this.client.request(`/v2/virtual_tag_configs/async/${S(e)}`,"GET",{})}},JU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/workspaces","GET",e)}create(e){return this.client.request("/v2/workspaces","POST",e)}get(e){return this.client.request(`/v2/workspaces/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/workspaces/${S(e)}`,"PUT",t)}},BU=class{constructor(e){this.client=e}get(){return this.client.request("/v2/ping","GET",{})}}});var ce;(function(e){e.assertEqual=n=>{};function t(n){}e.assertIs=t;function r(n){throw new Error}e.assertNever=r,e.arrayToEnum=n=>{let i={};for(let s of n)i[s]=s;return i},e.getValidEnumValues=n=>{let i=e.objectKeys(n).filter(a=>typeof n[n[a]]!="number"),s={};for(let a of i)s[a]=n[a];return e.objectValues(s)},e.objectValues=n=>e.objectKeys(n).map(function(i){return n[i]}),e.objectKeys=typeof Object.keys=="function"?n=>Object.keys(n):n=>{let i=[];for(let s in n)Object.prototype.hasOwnProperty.call(n,s)&&i.push(s);return i},e.find=(n,i)=>{for(let s of n)if(i(s))return s},e.isInteger=typeof Number.isInteger=="function"?n=>Number.isInteger(n):n=>typeof n=="number"&&Number.isFinite(n)&&Math.floor(n)===n;function o(n,i=" | "){return n.map(s=>typeof s=="string"?`'${s}'`:s).join(i)}e.joinValues=o,e.jsonStringifyReplacer=(n,i)=>typeof i=="bigint"?i.toString():i})(ce||(ce={}));var d_;(function(e){e.mergeShapes=(t,r)=>({...t,...r})})(d_||(d_={}));var A=ce.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),gr=e=>{switch(typeof e){case"undefined":return A.undefined;case"string":return A.string;case"number":return Number.isNaN(e)?A.nan:A.number;case"boolean":return A.boolean;case"function":return A.function;case"bigint":return A.bigint;case"symbol":return A.symbol;case"object":return Array.isArray(e)?A.array:e===null?A.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?A.promise:typeof Map<"u"&&e instanceof Map?A.map:typeof Set<"u"&&e instanceof Set?A.set:typeof Date<"u"&&e instanceof Date?A.date:A.object;default:return A.unknown}};var T=ce.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"]);var xt=class e extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=o=>{this.issues=[...this.issues,o]},this.addIssues=(o=[])=>{this.issues=[...this.issues,...o]};let r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=t}format(t){let r=t||function(i){return i.message},o={_errors:[]},n=i=>{for(let s of i.issues)if(s.code==="invalid_union")s.unionErrors.map(n);else if(s.code==="invalid_return_type")n(s.returnTypeError);else if(s.code==="invalid_arguments")n(s.argumentsError);else if(s.path.length===0)o._errors.push(r(s));else{let a=o,c=0;for(;c<s.path.length;){let u=s.path[c];c===s.path.length-1?(a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s))):a[u]=a[u]||{_errors:[]},a=a[u],c++}}};return n(this),o}static assert(t){if(!(t instanceof e))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ce.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=r=>r.message){let r={},o=[];for(let n of this.issues)if(n.path.length>0){let i=n.path[0];r[i]=r[i]||[],r[i].push(t(n))}else o.push(t(n));return{formErrors:o,fieldErrors:r}}get formErrors(){return this.flatten()}};xt.create=e=>new xt(e);var MS=(e,t)=>{let r;switch(e.code){case T.invalid_type:e.received===A.undefined?r="Required":r=`Expected ${e.expected}, received ${e.received}`;break;case T.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,ce.jsonStringifyReplacer)}`;break;case T.unrecognized_keys:r=`Unrecognized key(s) in object: ${ce.joinValues(e.keys,", ")}`;break;case T.invalid_union:r="Invalid input";break;case T.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${ce.joinValues(e.options)}`;break;case T.invalid_enum_value:r=`Invalid enum value. Expected ${ce.joinValues(e.options)}, received '${e.received}'`;break;case T.invalid_arguments:r="Invalid function arguments";break;case T.invalid_return_type:r="Invalid function return type";break;case T.invalid_date:r="Invalid date";break;case T.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(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}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:ce.assertNever(e.validation):e.validation!=="regex"?r=`Invalid ${e.validation}`:r="Invalid";break;case T.too_small:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`: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))}`:r="Invalid input";break;case T.too_big:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?r=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?r=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:r="Invalid input";break;case T.custom:r="Invalid input";break;case T.invalid_intersection_types:r="Intersection results could not be merged";break;case T.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case T.not_finite:r="Number must be finite";break;default:r=t.defaultError,ce.assertNever(e)}return{message:r}},Cr=MS;var US=Cr;function di(){return US}var Za=e=>{let{data:t,path:r,errorMaps:o,issueData:n}=e,i=[...r,...n.path||[]],s={...n,path:i};if(n.message!==void 0)return{...n,path:i,message:n.message};let a="",c=o.filter(u=>!!u).slice().reverse();for(let u of c)a=u(s,{data:t,defaultError:a}).message;return{...n,path:i,message:a}};function N(e,t){let r=di(),o=Za({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===Cr?void 0:Cr].filter(n=>!!n)});e.common.issues.push(o)}var Xe=class e{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,r){let o=[];for(let n of r){if(n.status==="aborted")return F;n.status==="dirty"&&t.dirty(),o.push(n.value)}return{status:t.value,value:o}}static async mergeObjectAsync(t,r){let o=[];for(let n of r){let i=await n.key,s=await n.value;o.push({key:i,value:s})}return e.mergeObjectSync(t,o)}static mergeObjectSync(t,r){let o={};for(let n of r){let{key:i,value:s}=n;if(i.status==="aborted"||s.status==="aborted")return F;i.status==="dirty"&&t.dirty(),s.status==="dirty"&&t.dirty(),i.value!=="__proto__"&&(typeof s.value<"u"||n.alwaysSet)&&(o[i.value]=s.value)}return{status:t.value,value:o}}},F=Object.freeze({status:"aborted"}),Kn=e=>({status:"dirty",value:e}),at=e=>({status:"valid",value:e}),Ld=e=>e.status==="aborted",Vd=e=>e.status==="dirty",hn=e=>e.status==="valid",pi=e=>typeof Promise<"u"&&e instanceof Promise;var q;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t?.message})(q||(q={}));var Et=class{constructor(t,r,o,n){this._cachedPath=[],this.parent=t,this.data=r,this._path=o,this._key=n}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},p_=(e,t)=>{if(hn(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let r=new xt(e.common.issues);return this._error=r,this._error}}};function J(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:o,description:n}=e;if(t&&(r||o))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:n}:{errorMap:(s,a)=>{let{message:c}=e;return s.code==="invalid_enum_value"?{message:c??a.defaultError}:typeof a.data>"u"?{message:c??o??a.defaultError}:s.code!=="invalid_type"?{message:a.defaultError}:{message:c??r??a.defaultError}},description:n}}var ee=class{get description(){return this._def.description}_getType(t){return gr(t.data)}_getOrReturnCtx(t,r){return r||{common:t.parent.common,data:t.data,parsedType:gr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new Xe,ctx:{common:t.parent.common,data:t.data,parsedType:gr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let r=this._parse(t);if(pi(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(t){let r=this._parse(t);return Promise.resolve(r)}parse(t,r){let o=this.safeParse(t,r);if(o.success)return o.data;throw o.error}safeParse(t,r){let o={common:{issues:[],async:r?.async??!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:gr(t)},n=this._parseSync({data:t,path:o.path,parent:o});return p_(o,n)}"~validate"(t){let r={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:gr(t)};if(!this["~standard"].async)try{let o=this._parseSync({data:t,path:[],parent:r});return hn(o)?{value:o.value}:{issues:r.common.issues}}catch(o){o?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),r.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:r}).then(o=>hn(o)?{value:o.value}:{issues:r.common.issues})}async parseAsync(t,r){let o=await this.safeParseAsync(t,r);if(o.success)return o.data;throw o.error}async safeParseAsync(t,r){let o={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:gr(t)},n=this._parse({data:t,path:o.path,parent:o}),i=await(pi(n)?n:Promise.resolve(n));return p_(o,i)}refine(t,r){let o=n=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(n):r;return this._refinement((n,i)=>{let s=t(n),a=()=>i.addIssue({code:T.custom,...o(n)});return typeof Promise<"u"&&s instanceof Promise?s.then(c=>c?!0:(a(),!1)):s?!0:(a(),!1)})}refinement(t,r){return this._refinement((o,n)=>t(o)?!0:(n.addIssue(typeof r=="function"?r(o,n):r),!1))}_refinement(t){return new Ft({schema:this,typeName:z.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,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:r=>this["~validate"](r)}}optional(){return St.create(this,this._def)}nullable(){return yr.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Dr.create(this)}promise(){return gn.create(this,this._def)}or(t){return Xn.create([this,t],this._def)}and(t){return Qn.create(this,t,this._def)}transform(t){return new Ft({...J(this._def),schema:this,typeName:z.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let r=typeof t=="function"?t:()=>t;return new oo({...J(this._def),innerType:this,defaultValue:r,typeName:z.ZodDefault})}brand(){return new La({typeName:z.ZodBranded,type:this,...J(this._def)})}catch(t){let r=typeof t=="function"?t:()=>t;return new io({...J(this._def),innerType:this,catchValue:r,typeName:z.ZodCatch})}describe(t){let r=this.constructor;return new r({...this._def,description:t})}pipe(t){return Va.create(this,t)}readonly(){return so.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},ZS=/^c[^\s-]{8,}$/i,LS=/^[0-9a-z]+$/,VS=/^[0-9A-HJKMNP-TV-Z]{26}$/i,FS=/^[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,GS=/^[a-z0-9_-]{21}$/i,WS=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,KS=/^[-+]?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)?)??$/,HS=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,JS="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Fd,BS=/^(?:(?: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])$/,YS=/^(?:(?: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])$/,XS=/^(([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]))$/,QS=/^(([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])$/,eT=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,tT=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,f_="((\\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])))",rT=new RegExp(`^${f_}$`);function m_(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}function nT(e){return new RegExp(`^${m_(e)}$`)}function oT(e){let t=`${f_}T${m_(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,new RegExp(`^${t}$`)}function iT(e,t){return!!((t==="v4"||!t)&&BS.test(e)||(t==="v6"||!t)&&XS.test(e))}function sT(e,t){if(!WS.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let o=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),n=JSON.parse(atob(o));return!(typeof n!="object"||n===null||"typ"in n&&n?.typ!=="JWT"||!n.alg||t&&n.alg!==t)}catch{return!1}}function aT(e,t){return!!((t==="v4"||!t)&&YS.test(e)||(t==="v6"||!t)&&QS.test(e))}var Jn=class e extends ee{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==A.string){let i=this._getOrReturnCtx(t);return N(i,{code:T.invalid_type,expected:A.string,received:i.parsedType}),F}let o=new Xe,n;for(let i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(n=this._getOrReturnCtx(t,n),N(n,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="max")t.data.length>i.value&&(n=this._getOrReturnCtx(t,n),N(n,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="length"){let s=t.data.length>i.value,a=t.data.length<i.value;(s||a)&&(n=this._getOrReturnCtx(t,n),s?N(n,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):a&&N(n,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),o.dirty())}else if(i.kind==="email")HS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"email",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="emoji")Fd||(Fd=new RegExp(JS,"u")),Fd.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"emoji",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="uuid")FS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"uuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="nanoid")GS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"nanoid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid")ZS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"cuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid2")LS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"cuid2",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="ulid")VS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"ulid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{n=this._getOrReturnCtx(t,n),N(n,{validation:"url",code:T.invalid_string,message:i.message}),o.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"regex",code:T.invalid_string,message:i.message}),o.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),o.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:{startsWith:i.value},message:i.message}),o.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:{endsWith:i.value},message:i.message}),o.dirty()):i.kind==="datetime"?oT(i).test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:"datetime",message:i.message}),o.dirty()):i.kind==="date"?rT.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:"date",message:i.message}),o.dirty()):i.kind==="time"?nT(i).test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{code:T.invalid_string,validation:"time",message:i.message}),o.dirty()):i.kind==="duration"?KS.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"duration",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="ip"?iT(t.data,i.version)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"ip",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="jwt"?sT(t.data,i.alg)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"jwt",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="cidr"?aT(t.data,i.version)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"cidr",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64"?eT.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"base64",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64url"?tT.test(t.data)||(n=this._getOrReturnCtx(t,n),N(n,{validation:"base64url",code:T.invalid_string,message:i.message}),o.dirty()):ce.assertNever(i);return{status:o.value,value:t.data}}_regex(t,r,o){return this.refinement(n=>t.test(n),{validation:r,code:T.invalid_string,...q.errToObj(o)})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...q.errToObj(t)})}url(t){return this._addCheck({kind:"url",...q.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...q.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...q.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...q.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...q.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...q.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...q.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...q.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...q.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...q.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...q.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...q.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...q.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...q.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...q.errToObj(t)})}regex(t,r){return this._addCheck({kind:"regex",regex:t,...q.errToObj(r)})}includes(t,r){return this._addCheck({kind:"includes",value:t,position:r?.position,...q.errToObj(r?.message)})}startsWith(t,r){return this._addCheck({kind:"startsWith",value:t,...q.errToObj(r)})}endsWith(t,r){return this._addCheck({kind:"endsWith",value:t,...q.errToObj(r)})}min(t,r){return this._addCheck({kind:"min",value:t,...q.errToObj(r)})}max(t,r){return this._addCheck({kind:"max",value:t,...q.errToObj(r)})}length(t,r){return this._addCheck({kind:"length",value:t,...q.errToObj(r)})}nonempty(t){return this.min(1,q.errToObj(t))}trim(){return new e({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxLength(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}};Jn.create=e=>new Jn({checks:[],typeName:z.ZodString,coerce:e?.coerce??!1,...J(e)});function cT(e,t){let r=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,n=r>o?r:o,i=Number.parseInt(e.toFixed(n).replace(".","")),s=Number.parseInt(t.toFixed(n).replace(".",""));return i%s/10**n}var fi=class e extends ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==A.number){let i=this._getOrReturnCtx(t);return N(i,{code:T.invalid_type,expected:A.number,received:i.parsedType}),F}let o,n=new Xe;for(let i of this._def.checks)i.kind==="int"?ce.isInteger(t.data)||(o=this._getOrReturnCtx(t,o),N(o,{code:T.invalid_type,expected:"integer",received:"float",message:i.message}),n.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="multipleOf"?cT(t.data,i.value)!==0&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(o=this._getOrReturnCtx(t,o),N(o,{code:T.not_finite,message:i.message}),n.dirty()):ce.assertNever(i);return{status:n.value,value:t.data}}gte(t,r){return this.setLimit("min",t,!0,q.toString(r))}gt(t,r){return this.setLimit("min",t,!1,q.toString(r))}lte(t,r){return this.setLimit("max",t,!0,q.toString(r))}lt(t,r){return this.setLimit("max",t,!1,q.toString(r))}setLimit(t,r,o,n){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:o,message:q.toString(n)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:q.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:q.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(r)})}finite(t){return this._addCheck({kind:"finite",message:q.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:q.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:q.toString(t)})}get minValue(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&ce.isInteger(t.value))}get isFinite(){let t=null,r=null;for(let o of this._def.checks){if(o.kind==="finite"||o.kind==="int"||o.kind==="multipleOf")return!0;o.kind==="min"?(r===null||o.value>r)&&(r=o.value):o.kind==="max"&&(t===null||o.value<t)&&(t=o.value)}return Number.isFinite(r)&&Number.isFinite(t)}};fi.create=e=>new fi({checks:[],typeName:z.ZodNumber,coerce:e?.coerce||!1,...J(e)});var mi=class e extends ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==A.bigint)return this._getInvalidInput(t);let o,n=new Xe;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(o=this._getOrReturnCtx(t,o),N(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):ce.assertNever(i);return{status:n.value,value:t.data}}_getInvalidInput(t){let r=this._getOrReturnCtx(t);return N(r,{code:T.invalid_type,expected:A.bigint,received:r.parsedType}),F}gte(t,r){return this.setLimit("min",t,!0,q.toString(r))}gt(t,r){return this.setLimit("min",t,!1,q.toString(r))}lte(t,r){return this.setLimit("max",t,!0,q.toString(r))}lt(t,r){return this.setLimit("max",t,!1,q.toString(r))}setLimit(t,r,o,n){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:o,message:q.toString(n)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:q.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(r)})}get minValue(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}};mi.create=e=>new mi({checks:[],typeName:z.ZodBigInt,coerce:e?.coerce??!1,...J(e)});var hi=class extends ee{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==A.boolean){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.boolean,received:o.parsedType}),F}return at(t.data)}};hi.create=e=>new hi({typeName:z.ZodBoolean,coerce:e?.coerce||!1,...J(e)});var gi=class e extends ee{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==A.date){let i=this._getOrReturnCtx(t);return N(i,{code:T.invalid_type,expected:A.date,received:i.parsedType}),F}if(Number.isNaN(t.data.getTime())){let i=this._getOrReturnCtx(t);return N(i,{code:T.invalid_date}),F}let o=new Xe,n;for(let i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(n=this._getOrReturnCtx(t,n),N(n,{code:T.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),o.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(n=this._getOrReturnCtx(t,n),N(n,{code:T.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),o.dirty()):ce.assertNever(i);return{status:o.value,value:new Date(t.data.getTime())}}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}min(t,r){return this._addCheck({kind:"min",value:t.getTime(),message:q.toString(r)})}max(t,r){return this._addCheck({kind:"max",value:t.getTime(),message:q.toString(r)})}get minDate(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t!=null?new Date(t):null}};gi.create=e=>new gi({checks:[],coerce:e?.coerce||!1,typeName:z.ZodDate,...J(e)});var vi=class extends ee{_parse(t){if(this._getType(t)!==A.symbol){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.symbol,received:o.parsedType}),F}return at(t.data)}};vi.create=e=>new vi({typeName:z.ZodSymbol,...J(e)});var Bn=class extends ee{_parse(t){if(this._getType(t)!==A.undefined){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.undefined,received:o.parsedType}),F}return at(t.data)}};Bn.create=e=>new Bn({typeName:z.ZodUndefined,...J(e)});var Yn=class extends ee{_parse(t){if(this._getType(t)!==A.null){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.null,received:o.parsedType}),F}return at(t.data)}};Yn.create=e=>new Yn({typeName:z.ZodNull,...J(e)});var _i=class extends ee{constructor(){super(...arguments),this._any=!0}_parse(t){return at(t.data)}};_i.create=e=>new _i({typeName:z.ZodAny,...J(e)});var Ar=class extends ee{constructor(){super(...arguments),this._unknown=!0}_parse(t){return at(t.data)}};Ar.create=e=>new Ar({typeName:z.ZodUnknown,...J(e)});var ir=class extends ee{_parse(t){let r=this._getOrReturnCtx(t);return N(r,{code:T.invalid_type,expected:A.never,received:r.parsedType}),F}};ir.create=e=>new ir({typeName:z.ZodNever,...J(e)});var yi=class extends ee{_parse(t){if(this._getType(t)!==A.undefined){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.void,received:o.parsedType}),F}return at(t.data)}};yi.create=e=>new yi({typeName:z.ZodVoid,...J(e)});var Dr=class e extends ee{_parse(t){let{ctx:r,status:o}=this._processInputParams(t),n=this._def;if(r.parsedType!==A.array)return N(r,{code:T.invalid_type,expected:A.array,received:r.parsedType}),F;if(n.exactLength!==null){let s=r.data.length>n.exactLength.value,a=r.data.length<n.exactLength.value;(s||a)&&(N(r,{code:s?T.too_big:T.too_small,minimum:a?n.exactLength.value:void 0,maximum:s?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),o.dirty())}if(n.minLength!==null&&r.data.length<n.minLength.value&&(N(r,{code:T.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),o.dirty()),n.maxLength!==null&&r.data.length>n.maxLength.value&&(N(r,{code:T.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),o.dirty()),r.common.async)return Promise.all([...r.data].map((s,a)=>n.type._parseAsync(new Et(r,s,r.path,a)))).then(s=>Xe.mergeArray(o,s));let i=[...r.data].map((s,a)=>n.type._parseSync(new Et(r,s,r.path,a)));return Xe.mergeArray(o,i)}get element(){return this._def.type}min(t,r){return new e({...this._def,minLength:{value:t,message:q.toString(r)}})}max(t,r){return new e({...this._def,maxLength:{value:t,message:q.toString(r)}})}length(t,r){return new e({...this._def,exactLength:{value:t,message:q.toString(r)}})}nonempty(t){return this.min(1,t)}};Dr.create=(e,t)=>new Dr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:z.ZodArray,...J(t)});function Hn(e){if(e instanceof Tt){let t={};for(let r in e.shape){let o=e.shape[r];t[r]=St.create(Hn(o))}return new Tt({...e._def,shape:()=>t})}else return e instanceof Dr?new Dr({...e._def,type:Hn(e.element)}):e instanceof St?St.create(Hn(e.unwrap())):e instanceof yr?yr.create(Hn(e.unwrap())):e instanceof _r?_r.create(e.items.map(t=>Hn(t))):e}var Tt=class e extends ee{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),r=ce.objectKeys(t);return this._cached={shape:t,keys:r},this._cached}_parse(t){if(this._getType(t)!==A.object){let u=this._getOrReturnCtx(t);return N(u,{code:T.invalid_type,expected:A.object,received:u.parsedType}),F}let{status:o,ctx:n}=this._processInputParams(t),{shape:i,keys:s}=this._getCached(),a=[];if(!(this._def.catchall instanceof ir&&this._def.unknownKeys==="strip"))for(let u in n.data)s.includes(u)||a.push(u);let c=[];for(let u of s){let l=i[u],d=n.data[u];c.push({key:{status:"valid",value:u},value:l._parse(new Et(n,d,n.path,u)),alwaysSet:u in n.data})}if(this._def.catchall instanceof ir){let u=this._def.unknownKeys;if(u==="passthrough")for(let l of a)c.push({key:{status:"valid",value:l},value:{status:"valid",value:n.data[l]}});else if(u==="strict")a.length>0&&(N(n,{code:T.unrecognized_keys,keys:a}),o.dirty());else if(u!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let u=this._def.catchall;for(let l of a){let d=n.data[l];c.push({key:{status:"valid",value:l},value:u._parse(new Et(n,d,n.path,l)),alwaysSet:l in n.data})}}return n.common.async?Promise.resolve().then(async()=>{let u=[];for(let l of c){let d=await l.key,h=await l.value;u.push({key:d,value:h,alwaysSet:l.alwaysSet})}return u}).then(u=>Xe.mergeObjectSync(o,u)):Xe.mergeObjectSync(o,c)}get shape(){return this._def.shape()}strict(t){return q.errToObj,new e({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(r,o)=>{let n=this._def.errorMap?.(r,o).message??o.defaultError;return r.code==="unrecognized_keys"?{message:q.errToObj(t).message??n}:{message:n}}}:{}})}strip(){return new e({...this._def,unknownKeys:"strip"})}passthrough(){return new e({...this._def,unknownKeys:"passthrough"})}extend(t){return new e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:z.ZodObject})}setKey(t,r){return this.augment({[t]:r})}catchall(t){return new e({...this._def,catchall:t})}pick(t){let r={};for(let o of ce.objectKeys(t))t[o]&&this.shape[o]&&(r[o]=this.shape[o]);return new e({...this._def,shape:()=>r})}omit(t){let r={};for(let o of ce.objectKeys(this.shape))t[o]||(r[o]=this.shape[o]);return new e({...this._def,shape:()=>r})}deepPartial(){return Hn(this)}partial(t){let r={};for(let o of ce.objectKeys(this.shape)){let n=this.shape[o];t&&!t[o]?r[o]=n:r[o]=n.optional()}return new e({...this._def,shape:()=>r})}required(t){let r={};for(let o of ce.objectKeys(this.shape))if(t&&!t[o])r[o]=this.shape[o];else{let i=this.shape[o];for(;i instanceof St;)i=i._def.innerType;r[o]=i}return new e({...this._def,shape:()=>r})}keyof(){return h_(ce.objectKeys(this.shape))}};Tt.create=(e,t)=>new Tt({shape:()=>e,unknownKeys:"strip",catchall:ir.create(),typeName:z.ZodObject,...J(t)});Tt.strictCreate=(e,t)=>new Tt({shape:()=>e,unknownKeys:"strict",catchall:ir.create(),typeName:z.ZodObject,...J(t)});Tt.lazycreate=(e,t)=>new Tt({shape:e,unknownKeys:"strip",catchall:ir.create(),typeName:z.ZodObject,...J(t)});var Xn=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=this._def.options;function n(i){for(let a of i)if(a.result.status==="valid")return a.result;for(let a of i)if(a.result.status==="dirty")return r.common.issues.push(...a.ctx.common.issues),a.result;let s=i.map(a=>new xt(a.ctx.common.issues));return N(r,{code:T.invalid_union,unionErrors:s}),F}if(r.common.async)return Promise.all(o.map(async i=>{let s={...r,common:{...r.common,issues:[]},parent:null};return{result:await i._parseAsync({data:r.data,path:r.path,parent:s}),ctx:s}})).then(n);{let i,s=[];for(let c of o){let u={...r,common:{...r.common,issues:[]},parent:null},l=c._parseSync({data:r.data,path:r.path,parent:u});if(l.status==="valid")return l;l.status==="dirty"&&!i&&(i={result:l,ctx:u}),u.common.issues.length&&s.push(u.common.issues)}if(i)return r.common.issues.push(...i.ctx.common.issues),i.result;let a=s.map(c=>new xt(c));return N(r,{code:T.invalid_union,unionErrors:a}),F}}get options(){return this._def.options}};Xn.create=(e,t)=>new Xn({options:e,typeName:z.ZodUnion,...J(t)});var vr=e=>e instanceof eo?vr(e.schema):e instanceof Ft?vr(e.innerType()):e instanceof to?[e.value]:e instanceof ro?e.options:e instanceof no?ce.objectValues(e.enum):e instanceof oo?vr(e._def.innerType):e instanceof Bn?[void 0]:e instanceof Yn?[null]:e instanceof St?[void 0,...vr(e.unwrap())]:e instanceof yr?[null,...vr(e.unwrap())]:e instanceof La||e instanceof so?vr(e.unwrap()):e instanceof io?vr(e._def.innerType):[],Gd=class e extends ee{_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.object)return N(r,{code:T.invalid_type,expected:A.object,received:r.parsedType}),F;let o=this.discriminator,n=r.data[o],i=this.optionsMap.get(n);return i?r.common.async?i._parseAsync({data:r.data,path:r.path,parent:r}):i._parseSync({data:r.data,path:r.path,parent:r}):(N(r,{code:T.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[o]}),F)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,r,o){let n=new Map;for(let i of r){let s=vr(i.shape[t]);if(!s.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let a of s){if(n.has(a))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(a)}`);n.set(a,i)}}return new e({typeName:z.ZodDiscriminatedUnion,discriminator:t,options:r,optionsMap:n,...J(o)})}};function Wd(e,t){let r=gr(e),o=gr(t);if(e===t)return{valid:!0,data:e};if(r===A.object&&o===A.object){let n=ce.objectKeys(t),i=ce.objectKeys(e).filter(a=>n.indexOf(a)!==-1),s={...e,...t};for(let a of i){let c=Wd(e[a],t[a]);if(!c.valid)return{valid:!1};s[a]=c.data}return{valid:!0,data:s}}else if(r===A.array&&o===A.array){if(e.length!==t.length)return{valid:!1};let n=[];for(let i=0;i<e.length;i++){let s=e[i],a=t[i],c=Wd(s,a);if(!c.valid)return{valid:!1};n.push(c.data)}return{valid:!0,data:n}}else return r===A.date&&o===A.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}var Qn=class extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t),n=(i,s)=>{if(Ld(i)||Ld(s))return F;let a=Wd(i.value,s.value);return a.valid?((Vd(i)||Vd(s))&&r.dirty(),{status:r.value,value:a.data}):(N(o,{code:T.invalid_intersection_types}),F)};return o.common.async?Promise.all([this._def.left._parseAsync({data:o.data,path:o.path,parent:o}),this._def.right._parseAsync({data:o.data,path:o.path,parent:o})]).then(([i,s])=>n(i,s)):n(this._def.left._parseSync({data:o.data,path:o.path,parent:o}),this._def.right._parseSync({data:o.data,path:o.path,parent:o}))}};Qn.create=(e,t,r)=>new Qn({left:e,right:t,typeName:z.ZodIntersection,...J(r)});var _r=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.array)return N(o,{code:T.invalid_type,expected:A.array,received:o.parsedType}),F;if(o.data.length<this._def.items.length)return N(o,{code:T.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),F;!this._def.rest&&o.data.length>this._def.items.length&&(N(o,{code:T.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());let i=[...o.data].map((s,a)=>{let c=this._def.items[a]||this._def.rest;return c?c._parse(new Et(o,s,o.path,a)):null}).filter(s=>!!s);return o.common.async?Promise.all(i).then(s=>Xe.mergeArray(r,s)):Xe.mergeArray(r,i)}get items(){return this._def.items}rest(t){return new e({...this._def,rest:t})}};_r.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new _r({items:e,typeName:z.ZodTuple,rest:null,...J(t)})};var Kd=class e extends ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.object)return N(o,{code:T.invalid_type,expected:A.object,received:o.parsedType}),F;let n=[],i=this._def.keyType,s=this._def.valueType;for(let a in o.data)n.push({key:i._parse(new Et(o,a,o.path,a)),value:s._parse(new Et(o,o.data[a],o.path,a)),alwaysSet:a in o.data});return o.common.async?Xe.mergeObjectAsync(r,n):Xe.mergeObjectSync(r,n)}get element(){return this._def.valueType}static create(t,r,o){return r instanceof ee?new e({keyType:t,valueType:r,typeName:z.ZodRecord,...J(o)}):new e({keyType:Jn.create(),valueType:t,typeName:z.ZodRecord,...J(r)})}},$i=class extends ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.map)return N(o,{code:T.invalid_type,expected:A.map,received:o.parsedType}),F;let n=this._def.keyType,i=this._def.valueType,s=[...o.data.entries()].map(([a,c],u)=>({key:n._parse(new Et(o,a,o.path,[u,"key"])),value:i._parse(new Et(o,c,o.path,[u,"value"]))}));if(o.common.async){let a=new Map;return Promise.resolve().then(async()=>{for(let c of s){let u=await c.key,l=await c.value;if(u.status==="aborted"||l.status==="aborted")return F;(u.status==="dirty"||l.status==="dirty")&&r.dirty(),a.set(u.value,l.value)}return{status:r.value,value:a}})}else{let a=new Map;for(let c of s){let u=c.key,l=c.value;if(u.status==="aborted"||l.status==="aborted")return F;(u.status==="dirty"||l.status==="dirty")&&r.dirty(),a.set(u.value,l.value)}return{status:r.value,value:a}}}};$i.create=(e,t,r)=>new $i({valueType:t,keyType:e,typeName:z.ZodMap,...J(r)});var bi=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.set)return N(o,{code:T.invalid_type,expected:A.set,received:o.parsedType}),F;let n=this._def;n.minSize!==null&&o.data.size<n.minSize.value&&(N(o,{code:T.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),r.dirty()),n.maxSize!==null&&o.data.size>n.maxSize.value&&(N(o,{code:T.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),r.dirty());let i=this._def.valueType;function s(c){let u=new Set;for(let l of c){if(l.status==="aborted")return F;l.status==="dirty"&&r.dirty(),u.add(l.value)}return{status:r.value,value:u}}let a=[...o.data.values()].map((c,u)=>i._parse(new Et(o,c,o.path,u)));return o.common.async?Promise.all(a).then(c=>s(c)):s(a)}min(t,r){return new e({...this._def,minSize:{value:t,message:q.toString(r)}})}max(t,r){return new e({...this._def,maxSize:{value:t,message:q.toString(r)}})}size(t,r){return this.min(t,r).max(t,r)}nonempty(t){return this.min(1,t)}};bi.create=(e,t)=>new bi({valueType:e,minSize:null,maxSize:null,typeName:z.ZodSet,...J(t)});var Hd=class e extends ee{constructor(){super(...arguments),this.validate=this.implement}_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.function)return N(r,{code:T.invalid_type,expected:A.function,received:r.parsedType}),F;function o(a,c){return Za({data:a,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,di(),Cr].filter(u=>!!u),issueData:{code:T.invalid_arguments,argumentsError:c}})}function n(a,c){return Za({data:a,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,di(),Cr].filter(u=>!!u),issueData:{code:T.invalid_return_type,returnTypeError:c}})}let i={errorMap:r.common.contextualErrorMap},s=r.data;if(this._def.returns instanceof gn){let a=this;return at(async function(...c){let u=new xt([]),l=await a._def.args.parseAsync(c,i).catch(m=>{throw u.addIssue(o(c,m)),u}),d=await Reflect.apply(s,this,l);return await a._def.returns._def.type.parseAsync(d,i).catch(m=>{throw u.addIssue(n(d,m)),u})})}else{let a=this;return at(function(...c){let u=a._def.args.safeParse(c,i);if(!u.success)throw new xt([o(c,u.error)]);let l=Reflect.apply(s,this,u.data),d=a._def.returns.safeParse(l,i);if(!d.success)throw new xt([n(l,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new e({...this._def,args:_r.create(t).rest(Ar.create())})}returns(t){return new e({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,r,o){return new e({args:t||_r.create([]).rest(Ar.create()),returns:r||Ar.create(),typeName:z.ZodFunction,...J(o)})}},eo=class extends ee{get schema(){return this._def.getter()}_parse(t){let{ctx:r}=this._processInputParams(t);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}};eo.create=(e,t)=>new eo({getter:e,typeName:z.ZodLazy,...J(t)});var to=class extends ee{_parse(t){if(t.data!==this._def.value){let r=this._getOrReturnCtx(t);return N(r,{received:r.data,code:T.invalid_literal,expected:this._def.value}),F}return{status:"valid",value:t.data}}get value(){return this._def.value}};to.create=(e,t)=>new to({value:e,typeName:z.ZodLiteral,...J(t)});function h_(e,t){return new ro({values:e,typeName:z.ZodEnum,...J(t)})}var ro=class e extends ee{_parse(t){if(typeof t.data!="string"){let r=this._getOrReturnCtx(t),o=this._def.values;return N(r,{expected:ce.joinValues(o),received:r.parsedType,code:T.invalid_type}),F}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){let r=this._getOrReturnCtx(t),o=this._def.values;return N(r,{received:r.data,code:T.invalid_enum_value,options:o}),F}return at(t.data)}get options(){return this._def.values}get enum(){let t={};for(let r of this._def.values)t[r]=r;return t}get Values(){let t={};for(let r of this._def.values)t[r]=r;return t}get Enum(){let t={};for(let r of this._def.values)t[r]=r;return t}extract(t,r=this._def){return e.create(t,{...this._def,...r})}exclude(t,r=this._def){return e.create(this.options.filter(o=>!t.includes(o)),{...this._def,...r})}};ro.create=h_;var no=class extends ee{_parse(t){let r=ce.getValidEnumValues(this._def.values),o=this._getOrReturnCtx(t);if(o.parsedType!==A.string&&o.parsedType!==A.number){let n=ce.objectValues(r);return N(o,{expected:ce.joinValues(n),received:o.parsedType,code:T.invalid_type}),F}if(this._cache||(this._cache=new Set(ce.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){let n=ce.objectValues(r);return N(o,{received:o.data,code:T.invalid_enum_value,options:n}),F}return at(t.data)}get enum(){return this._def.values}};no.create=(e,t)=>new no({values:e,typeName:z.ZodNativeEnum,...J(t)});var gn=class extends ee{unwrap(){return this._def.type}_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.promise&&r.common.async===!1)return N(r,{code:T.invalid_type,expected:A.promise,received:r.parsedType}),F;let o=r.parsedType===A.promise?r.data:Promise.resolve(r.data);return at(o.then(n=>this._def.type.parseAsync(n,{path:r.path,errorMap:r.common.contextualErrorMap})))}};gn.create=(e,t)=>new gn({type:e,typeName:z.ZodPromise,...J(t)});var Ft=class extends ee{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===z.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:r,ctx:o}=this._processInputParams(t),n=this._def.effect||null,i={addIssue:s=>{N(o,s),s.fatal?r.abort():r.dirty()},get path(){return o.path}};if(i.addIssue=i.addIssue.bind(i),n.type==="preprocess"){let s=n.transform(o.data,i);if(o.common.async)return Promise.resolve(s).then(async a=>{if(r.value==="aborted")return F;let c=await this._def.schema._parseAsync({data:a,path:o.path,parent:o});return c.status==="aborted"?F:c.status==="dirty"?Kn(c.value):r.value==="dirty"?Kn(c.value):c});{if(r.value==="aborted")return F;let a=this._def.schema._parseSync({data:s,path:o.path,parent:o});return a.status==="aborted"?F:a.status==="dirty"?Kn(a.value):r.value==="dirty"?Kn(a.value):a}}if(n.type==="refinement"){let s=a=>{let c=n.refinement(a,i);if(o.common.async)return Promise.resolve(c);if(c instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return a};if(o.common.async===!1){let a=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});return a.status==="aborted"?F:(a.status==="dirty"&&r.dirty(),s(a.value),{status:r.value,value:a.value})}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(a=>a.status==="aborted"?F:(a.status==="dirty"&&r.dirty(),s(a.value).then(()=>({status:r.value,value:a.value}))))}if(n.type==="transform")if(o.common.async===!1){let s=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});if(!hn(s))return F;let a=n.transform(s.value,i);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:a}}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(s=>hn(s)?Promise.resolve(n.transform(s.value,i)).then(a=>({status:r.value,value:a})):F);ce.assertNever(n)}};Ft.create=(e,t,r)=>new Ft({schema:e,typeName:z.ZodEffects,effect:t,...J(r)});Ft.createWithPreprocess=(e,t,r)=>new Ft({schema:t,effect:{type:"preprocess",transform:e},typeName:z.ZodEffects,...J(r)});var St=class extends ee{_parse(t){return this._getType(t)===A.undefined?at(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};St.create=(e,t)=>new St({innerType:e,typeName:z.ZodOptional,...J(t)});var yr=class extends ee{_parse(t){return this._getType(t)===A.null?at(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};yr.create=(e,t)=>new yr({innerType:e,typeName:z.ZodNullable,...J(t)});var oo=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=r.data;return r.parsedType===A.undefined&&(o=this._def.defaultValue()),this._def.innerType._parse({data:o,path:r.path,parent:r})}removeDefault(){return this._def.innerType}};oo.create=(e,t)=>new oo({innerType:e,typeName:z.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...J(t)});var io=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o={...r,common:{...r.common,issues:[]}},n=this._def.innerType._parse({data:o.data,path:o.path,parent:{...o}});return pi(n)?n.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new xt(o.common.issues)},input:o.data})})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new xt(o.common.issues)},input:o.data})}}removeCatch(){return this._def.innerType}};io.create=(e,t)=>new io({innerType:e,typeName:z.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...J(t)});var wi=class extends ee{_parse(t){if(this._getType(t)!==A.nan){let o=this._getOrReturnCtx(t);return N(o,{code:T.invalid_type,expected:A.nan,received:o.parsedType}),F}return{status:"valid",value:t.data}}};wi.create=e=>new wi({typeName:z.ZodNaN,...J(e)});var _2=Symbol("zod_brand"),La=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=r.data;return this._def.type._parse({data:o,path:r.path,parent:r})}unwrap(){return this._def.type}},Va=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:o.data,path:o.path,parent:o});return i.status==="aborted"?F:i.status==="dirty"?(r.dirty(),Kn(i.value)):this._def.out._parseAsync({data:i.value,path:o.path,parent:o})})();{let n=this._def.in._parseSync({data:o.data,path:o.path,parent:o});return n.status==="aborted"?F:n.status==="dirty"?(r.dirty(),{status:"dirty",value:n.value}):this._def.out._parseSync({data:n.value,path:o.path,parent:o})}}static create(t,r){return new e({in:t,out:r,typeName:z.ZodPipeline})}},so=class extends ee{_parse(t){let r=this._def.innerType._parse(t),o=n=>(hn(n)&&(n.value=Object.freeze(n.value)),n);return pi(r)?r.then(n=>o(n)):o(r)}unwrap(){return this._def.innerType}};so.create=(e,t)=>new so({innerType:e,typeName:z.ZodReadonly,...J(t)});var y2={object:Tt.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 $2=Jn.create,b2=fi.create,w2=wi.create,k2=mi.create,x2=hi.create,S2=gi.create,T2=vi.create,P2=Bn.create,z2=Yn.create,E2=_i.create,I2=Ar.create,j2=ir.create,O2=yi.create,N2=Dr.create,g_=Tt.create,R2=Tt.strictCreate,C2=Xn.create,A2=Gd.create,D2=Qn.create,q2=_r.create,M2=Kd.create,U2=$i.create,Z2=bi.create,L2=Hd.create,V2=eo.create,F2=to.create,G2=ro.create,W2=no.create,K2=gn.create,H2=Ft.create,J2=St.create,B2=yr.create,Y2=Ft.createWithPreprocess,X2=Va.create;var Wt={};mn(Wt,{$ZodAny:()=>Ec,$ZodArray:()=>ho,$ZodAsyncError:()=>sr,$ZodBase64:()=>yc,$ZodBase64URL:()=>$c,$ZodBigInt:()=>Ri,$ZodBigIntFormat:()=>Sc,$ZodBoolean:()=>mo,$ZodCIDRv4:()=>vc,$ZodCIDRv6:()=>_c,$ZodCUID:()=>lc,$ZodCUID2:()=>dc,$ZodCatch:()=>Kc,$ZodCheck:()=>De,$ZodCheckBigIntFormat:()=>Dp,$ZodCheckEndsWith:()=>Jp,$ZodCheckGreaterThan:()=>tc,$ZodCheckIncludes:()=>Kp,$ZodCheckLengthEquals:()=>Vp,$ZodCheckLessThan:()=>ec,$ZodCheckLowerCase:()=>Gp,$ZodCheckMaxLength:()=>Zp,$ZodCheckMaxSize:()=>qp,$ZodCheckMimeType:()=>Yp,$ZodCheckMinLength:()=>Lp,$ZodCheckMinSize:()=>Mp,$ZodCheckMultipleOf:()=>Cp,$ZodCheckNumberFormat:()=>Ap,$ZodCheckOverwrite:()=>Xp,$ZodCheckProperty:()=>Bp,$ZodCheckRegex:()=>Fp,$ZodCheckSizeEquals:()=>Up,$ZodCheckStartsWith:()=>Hp,$ZodCheckStringFormat:()=>fo,$ZodCheckUpperCase:()=>Wp,$ZodCustom:()=>Qc,$ZodCustomStringFormat:()=>kc,$ZodDate:()=>Oc,$ZodDefault:()=>Vc,$ZodDiscriminatedUnion:()=>Nc,$ZodE164:()=>bc,$ZodEmail:()=>sc,$ZodEmoji:()=>cc,$ZodEnum:()=>qc,$ZodError:()=>ji,$ZodFile:()=>Uc,$ZodFunction:()=>zu,$ZodGUID:()=>oc,$ZodIPv4:()=>hc,$ZodIPv6:()=>gc,$ZodISODate:()=>rf,$ZodISODateTime:()=>tf,$ZodISODuration:()=>of,$ZodISOTime:()=>nf,$ZodIntersection:()=>Rc,$ZodJWT:()=>wc,$ZodKSUID:()=>mc,$ZodLazy:()=>Xc,$ZodLiteral:()=>Mc,$ZodMap:()=>Ac,$ZodNaN:()=>Hc,$ZodNanoID:()=>uc,$ZodNever:()=>Ic,$ZodNonOptional:()=>Gc,$ZodNull:()=>zc,$ZodNullable:()=>Lc,$ZodNumber:()=>Ni,$ZodNumberFormat:()=>xc,$ZodObject:()=>Ci,$ZodOptional:()=>Zc,$ZodPipe:()=>vo,$ZodPrefault:()=>Fc,$ZodPromise:()=>Yc,$ZodReadonly:()=>Jc,$ZodRealError:()=>uo,$ZodRecord:()=>Cc,$ZodRegistry:()=>yo,$ZodSet:()=>Dc,$ZodString:()=>Lr,$ZodStringFormat:()=>ke,$ZodSuccess:()=>Wc,$ZodSymbol:()=>Tc,$ZodTemplateLiteral:()=>Bc,$ZodTransform:()=>go,$ZodTuple:()=>Vr,$ZodType:()=>W,$ZodULID:()=>pc,$ZodURL:()=>ac,$ZodUUID:()=>ic,$ZodUndefined:()=>Pc,$ZodUnion:()=>Ai,$ZodUnknown:()=>wn,$ZodVoid:()=>jc,$ZodXID:()=>fc,$brand:()=>Ga,$constructor:()=>_,$input:()=>ru,$output:()=>tu,Doc:()=>Oi,JSONSchema:()=>Sy,JSONSchemaGenerator:()=>_s,NEVER:()=>Fa,TimePrecision:()=>ou,_any:()=>_u,_array:()=>vs,_base64:()=>ts,_base64url:()=>rs,_bigint:()=>pu,_boolean:()=>du,_catch:()=>UP,_cidrv4:()=>Qi,_cidrv6:()=>es,_coercedBigint:()=>mf,_coercedBoolean:()=>ff,_coercedDate:()=>hf,_coercedNumber:()=>pf,_coercedString:()=>af,_cuid:()=>Wi,_cuid2:()=>Ki,_custom:()=>xu,_date:()=>bu,_default:()=>DP,_discriminatedUnion:()=>TP,_e164:()=>ns,_email:()=>qi,_emoji:()=>Fi,_endsWith:()=>ds,_enum:()=>jP,_file:()=>ku,_float32:()=>au,_float64:()=>cu,_gt:()=>wr,_gte:()=>ht,_guid:()=>$o,_includes:()=>us,_int:()=>su,_int32:()=>uu,_int64:()=>fu,_intersection:()=>PP,_ipv4:()=>Yi,_ipv6:()=>Xi,_isoDate:()=>uf,_isoDateTime:()=>cf,_isoDuration:()=>df,_isoTime:()=>lf,_jwt:()=>os,_ksuid:()=>Bi,_lazy:()=>FP,_length:()=>ko,_literal:()=>NP,_lowercase:()=>as,_lt:()=>br,_lte:()=>It,_map:()=>EP,_max:()=>It,_maxLength:()=>wo,_maxSize:()=>bo,_mime:()=>ps,_min:()=>ht,_minLength:()=>Fr,_minSize:()=>Sn,_multipleOf:()=>xn,_nan:()=>wu,_nanoid:()=>Gi,_nativeEnum:()=>OP,_negative:()=>vf,_never:()=>yu,_nonnegative:()=>yf,_nonoptional:()=>qP,_nonpositive:()=>_f,_normalize:()=>fs,_null:()=>vu,_nullable:()=>AP,_number:()=>iu,_optional:()=>CP,_overwrite:()=>kr,_parse:()=>Ja,_parseAsync:()=>Ba,_pipe:()=>ZP,_positive:()=>gf,_promise:()=>GP,_property:()=>$f,_readonly:()=>LP,_record:()=>zP,_refine:()=>Su,_regex:()=>ss,_safeParse:()=>Ya,_safeParseAsync:()=>Xa,_set:()=>IP,_size:()=>is,_startsWith:()=>ls,_string:()=>nu,_stringFormat:()=>Pu,_stringbool:()=>Tu,_success:()=>MP,_symbol:()=>hu,_templateLiteral:()=>VP,_toLowerCase:()=>hs,_toUpperCase:()=>gs,_transform:()=>RP,_trim:()=>ms,_tuple:()=>bf,_uint32:()=>lu,_uint64:()=>mu,_ulid:()=>Hi,_undefined:()=>gu,_union:()=>SP,_unknown:()=>kn,_uppercase:()=>cs,_url:()=>Vi,_uuid:()=>Mi,_uuidv4:()=>Ui,_uuidv6:()=>Zi,_uuidv7:()=>Li,_void:()=>$u,_xid:()=>Ji,clone:()=>Qe,config:()=>Ue,flattenError:()=>lo,formatError:()=>po,function:()=>Eu,globalConfig:()=>ki,globalRegistry:()=>Gt,isValidBase64:()=>sf,isValidBase64URL:()=>A_,isValidJWT:()=>D_,locales:()=>_o,parse:()=>yn,parseAsync:()=>$n,prettifyError:()=>Ha,regexes:()=>Zr,registry:()=>Di,safeParse:()=>Mr,safeParseAsync:()=>Ur,toDotPath:()=>__,toJSONSchema:()=>xo,treeifyError:()=>Ka,util:()=>j,version:()=>Qp});var Fa=Object.freeze({status:"aborted"});function _(e,t,r){function o(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)l in a||Object.defineProperty(a,l,{value:s.prototype[l].bind(a)});a._zod.constr=s,a._zod.def=c}let n=r?.Parent??Object;class i extends n{}Object.defineProperty(i,"name",{value:e});function s(a){var c;let u=r?.Parent?new i:this;o(u,a),(c=u._zod).deferred??(c.deferred=[]);for(let l of u._zod.deferred)l();return u}return Object.defineProperty(s,"init",{value:o}),Object.defineProperty(s,Symbol.hasInstance,{value:a=>r?.Parent&&a instanceof r.Parent?!0:a?._zod?.traits?.has(e)}),Object.defineProperty(s,"name",{value:e}),s}var Ga=Symbol("zod_brand"),sr=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},ki={};function Ue(e){return e&&Object.assign(ki,e),ki}var j={};mn(j,{BIGINT_FORMAT_RANGES:()=>op,Class:()=>Bd,NUMBER_FORMAT_RANGES:()=>np,aborted:()=>_n,allowsEval:()=>ep,assert:()=>fT,assertEqual:()=>uT,assertIs:()=>dT,assertNever:()=>pT,assertNotEqual:()=>lT,assignProp:()=>Qd,cached:()=>Ti,captureStackTrace:()=>Wa,cleanEnum:()=>TT,cleanRegex:()=>Pi,clone:()=>Qe,createTransparentProxy:()=>yT,defineLazy:()=>_e,esc:()=>vn,escapeRegex:()=>$r,extend:()=>wT,finalizeIssue:()=>Pt,floatSafeRemainder:()=>Xd,getElementAtPath:()=>mT,getEnumValues:()=>Si,getLengthableOrigin:()=>Ii,getParsedType:()=>_T,getSizableOrigin:()=>Ei,isObject:()=>ao,isPlainObject:()=>co,issue:()=>ip,joinValues:()=>x,jsonStringifyReplacer:()=>Yd,merge:()=>kT,normalizeParams:()=>I,nullish:()=>qr,numKeys:()=>vT,omit:()=>bT,optionalKeys:()=>rp,partial:()=>xT,pick:()=>$T,prefixIssues:()=>mt,primitiveTypes:()=>tp,promiseAllObject:()=>hT,propertyKeyTypes:()=>zi,randomString:()=>gT,required:()=>ST,stringifyPrimitive:()=>O,unwrapMessage:()=>xi});function uT(e){return e}function lT(e){return e}function dT(e){}function pT(e){throw new Error}function fT(e){}function Si(e){let t=Object.values(e).filter(o=>typeof o=="number");return Object.entries(e).filter(([o,n])=>t.indexOf(+o)===-1).map(([o,n])=>n)}function x(e,t="|"){return e.map(r=>O(r)).join(t)}function Yd(e,t){return typeof t=="bigint"?t.toString():t}function Ti(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}function qr(e){return e==null}function Pi(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}function Xd(e,t){let r=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,n=r>o?r:o,i=Number.parseInt(e.toFixed(n).replace(".","")),s=Number.parseInt(t.toFixed(n).replace(".",""));return i%s/10**n}function _e(e,t,r){Object.defineProperty(e,t,{get(){{let n=r();return e[t]=n,n}throw new Error("cached value already set")},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function Qd(e,t,r){Object.defineProperty(e,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}function mT(e,t){return t?t.reduce((r,o)=>r?.[o],e):e}function hT(e){let t=Object.keys(e),r=t.map(o=>e[o]);return Promise.all(r).then(o=>{let n={};for(let i=0;i<t.length;i++)n[t[i]]=o[i];return n})}function gT(e=10){let t="abcdefghijklmnopqrstuvwxyz",r="";for(let o=0;o<e;o++)r+=t[Math.floor(Math.random()*t.length)];return r}function vn(e){return JSON.stringify(e)}var Wa=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};function ao(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}var ep=Ti(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function co(e){if(ao(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let r=t.prototype;return!(ao(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}function vT(e){let t=0;for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t++;return t}var _T=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":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},zi=new Set(["string","number","symbol"]),tp=new Set(["string","number","bigint","boolean","symbol","undefined"]);function $r(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Qe(e,t,r){let o=new e._zod.constr(t??e._zod.def);return(!t||r?.parent)&&(o._zod.parent=e),o}function I(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 new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function yT(e){let t;return new Proxy({},{get(r,o,n){return t??(t=e()),Reflect.get(t,o,n)},set(r,o,n,i){return t??(t=e()),Reflect.set(t,o,n,i)},has(r,o){return t??(t=e()),Reflect.has(t,o)},deleteProperty(r,o){return t??(t=e()),Reflect.deleteProperty(t,o)},ownKeys(r){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(r,o){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,o)},defineProperty(r,o,n){return t??(t=e()),Reflect.defineProperty(t,o,n)}})}function O(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function rp(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var np={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},op={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function $T(e,t){let r={},o=e._zod.def;for(let n in t){if(!(n in o.shape))throw new Error(`Unrecognized key: "${n}"`);t[n]&&(r[n]=o.shape[n])}return Qe(e,{...e._zod.def,shape:r,checks:[]})}function bT(e,t){let r={...e._zod.def.shape},o=e._zod.def;for(let n in t){if(!(n in o.shape))throw new Error(`Unrecognized key: "${n}"`);t[n]&&delete r[n]}return Qe(e,{...e._zod.def,shape:r,checks:[]})}function wT(e,t){if(!co(t))throw new Error("Invalid input to extend: expected a plain object");let r={...e._zod.def,get shape(){let o={...e._zod.def.shape,...t};return Qd(this,"shape",o),o},checks:[]};return Qe(e,r)}function kT(e,t){return Qe(e,{...e._zod.def,get shape(){let r={...e._zod.def.shape,...t._zod.def.shape};return Qd(this,"shape",r),r},catchall:t._zod.def.catchall,checks:[]})}function xT(e,t,r){let o=t._zod.def.shape,n={...o};if(r)for(let i in r){if(!(i in o))throw new Error(`Unrecognized key: "${i}"`);r[i]&&(n[i]=e?new e({type:"optional",innerType:o[i]}):o[i])}else for(let i in o)n[i]=e?new e({type:"optional",innerType:o[i]}):o[i];return Qe(t,{...t._zod.def,shape:n,checks:[]})}function ST(e,t,r){let o=t._zod.def.shape,n={...o};if(r)for(let i in r){if(!(i in n))throw new Error(`Unrecognized key: "${i}"`);r[i]&&(n[i]=new e({type:"nonoptional",innerType:o[i]}))}else for(let i in o)n[i]=new e({type:"nonoptional",innerType:o[i]});return Qe(t,{...t._zod.def,shape:n,checks:[]})}function _n(e,t=0){for(let r=t;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}function mt(e,t){return t.map(r=>{var o;return(o=r).path??(o.path=[]),r.path.unshift(e),r})}function xi(e){return typeof e=="string"?e:e?.message}function Pt(e,t,r){let o={...e,path:e.path??[]};if(!e.message){let n=xi(e.inst?._zod.def?.error?.(e))??xi(t?.error?.(e))??xi(r.customError?.(e))??xi(r.localeError?.(e))??"Invalid input";o.message=n}return delete o.inst,delete o.continue,t?.reportInput||delete o.input,o}function Ei(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function Ii(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function ip(...e){let[t,r,o]=e;return typeof t=="string"?{message:t,code:"custom",input:r,inst:o}:{...t}}function TT(e){return Object.entries(e).filter(([t,r])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}var Bd=class{constructor(...t){}};var v_=(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,Yd,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ji=_("$ZodError",v_),uo=_("$ZodError",v_,{Parent:Error});function lo(e,t=r=>r.message){let r={},o=[];for(let n of e.issues)n.path.length>0?(r[n.path[0]]=r[n.path[0]]||[],r[n.path[0]].push(t(n))):o.push(t(n));return{formErrors:o,fieldErrors:r}}function po(e,t){let r=t||function(i){return i.message},o={_errors:[]},n=i=>{for(let s of i.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map(a=>n({issues:a}));else if(s.code==="invalid_key")n({issues:s.issues});else if(s.code==="invalid_element")n({issues:s.issues});else if(s.path.length===0)o._errors.push(r(s));else{let a=o,c=0;for(;c<s.path.length;){let u=s.path[c];c===s.path.length-1?(a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s))):a[u]=a[u]||{_errors:[]},a=a[u],c++}}};return n(e),o}function Ka(e,t){let r=t||function(i){return i.message},o={errors:[]},n=(i,s=[])=>{var a,c;for(let u of i.issues)if(u.code==="invalid_union"&&u.errors.length)u.errors.map(l=>n({issues:l},u.path));else if(u.code==="invalid_key")n({issues:u.issues},u.path);else if(u.code==="invalid_element")n({issues:u.issues},u.path);else{let l=[...s,...u.path];if(l.length===0){o.errors.push(r(u));continue}let d=o,h=0;for(;h<l.length;){let m=l[h],p=h===l.length-1;typeof m=="string"?(d.properties??(d.properties={}),(a=d.properties)[m]??(a[m]={errors:[]}),d=d.properties[m]):(d.items??(d.items=[]),(c=d.items)[m]??(c[m]={errors:[]}),d=d.items[m]),p&&d.errors.push(r(u)),h++}}};return n(e),o}function __(e){let t=[];for(let r of e)typeof r=="number"?t.push(`[${r}]`):typeof r=="symbol"?t.push(`[${JSON.stringify(String(r))}]`):/[^\w$]/.test(r)?t.push(`[${JSON.stringify(r)}]`):(t.length&&t.push("."),t.push(r));return t.join("")}function Ha(e){let t=[],r=[...e.issues].sort((o,n)=>o.path.length-n.path.length);for(let o of r)t.push(`\u2716 ${o.message}`),o.path?.length&&t.push(` \u2192 at ${__(o.path)}`);return t.join(`
17
- `)}var Ja=e=>(t,r,o,n)=>{let i=o?Object.assign(o,{async:!1}):{async:!1},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)throw new sr;if(s.issues.length){let a=new(n?.Err??e)(s.issues.map(c=>Pt(c,i,Ue())));throw Wa(a,n?.callee),a}return s.value},yn=Ja(uo),Ba=e=>async(t,r,o,n)=>{let i=o?Object.assign(o,{async:!0}):{async:!0},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise&&(s=await s),s.issues.length){let a=new(n?.Err??e)(s.issues.map(c=>Pt(c,i,Ue())));throw Wa(a,n?.callee),a}return s.value},$n=Ba(uo),Ya=e=>(t,r,o)=>{let n=o?{...o,async:!1}:{async:!1},i=t._zod.run({value:r,issues:[]},n);if(i instanceof Promise)throw new sr;return i.issues.length?{success:!1,error:new(e??ji)(i.issues.map(s=>Pt(s,n,Ue())))}:{success:!0,data:i.value}},Mr=Ya(uo),Xa=e=>async(t,r,o)=>{let n=o?Object.assign(o,{async:!0}):{async:!0},i=t._zod.run({value:r,issues:[]},n);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(s=>Pt(s,n,Ue())))}:{success:!0,data:i.value}},Ur=Xa(uo);var Zr={};mn(Zr,{_emoji:()=>y_,base64:()=>$p,base64url:()=>Qa,bigint:()=>Pp,boolean:()=>Ip,browserEmail:()=>CT,cidrv4:()=>_p,cidrv6:()=>yp,cuid:()=>sp,cuid2:()=>ap,date:()=>kp,datetime:()=>Sp,domain:()=>AT,duration:()=>pp,e164:()=>wp,email:()=>mp,emoji:()=>hp,extendedDuration:()=>zT,guid:()=>fp,hostname:()=>bp,html5Email:()=>OT,integer:()=>zp,ipv4:()=>gp,ipv6:()=>vp,ksuid:()=>lp,lowercase:()=>Np,nanoid:()=>dp,null:()=>jp,number:()=>Ep,rfc5322Email:()=>NT,string:()=>Tp,time:()=>xp,ulid:()=>cp,undefined:()=>Op,unicodeEmail:()=>RT,uppercase:()=>Rp,uuid:()=>bn,uuid4:()=>ET,uuid6:()=>IT,uuid7:()=>jT,xid:()=>up});var sp=/^[cC][^\s-]{8,}$/,ap=/^[0-9a-z]+$/,cp=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,up=/^[0-9a-vA-V]{20}$/,lp=/^[A-Za-z0-9]{27}$/,dp=/^[a-zA-Z0-9_-]{21}$/,pp=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,zT=/^[-+]?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)?)??$/,fp=/^([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})$/,bn=e=>e?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})$`):/^([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)$/,ET=bn(4),IT=bn(6),jT=bn(7),mp=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,OT=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,NT=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,RT=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,CT=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,y_="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function hp(){return new RegExp(y_,"u")}var gp=/^(?:(?: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])$/,vp=/^(([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})$/,_p=/^((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])$/,yp=/^(([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])$/,$p=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Qa=/^[A-Za-z0-9_-]*$/,bp=/^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/,AT=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,wp=/^\+(?:[0-9]){6,14}[0-9]$/,$_="(?:(?:\\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])))",kp=new RegExp(`^${$_}$`);function b_(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function xp(e){return new RegExp(`^${b_(e)}$`)}function Sp(e){let t=b_({precision:e.precision}),r=["Z"];e.local&&r.push(""),e.offset&&r.push("([+-]\\d{2}:\\d{2})");let o=`${t}(?:${r.join("|")})`;return new RegExp(`^${$_}T(?:${o})$`)}var Tp=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},Pp=/^\d+n?$/,zp=/^\d+$/,Ep=/^-?\d+(?:\.\d+)?/i,Ip=/true|false/i,jp=/null/i;var Op=/undefined/i;var Np=/^[^A-Z]*$/,Rp=/^[^a-z]*$/;var De=_("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),k_={number:"number",bigint:"bigint",object:"date"},ec=_("$ZodCheckLessThan",(e,t)=>{De.init(e,t);let r=k_[typeof t.value];e._zod.onattach.push(o=>{let n=o._zod.bag,i=(t.inclusive?n.maximum:n.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<i&&(t.inclusive?n.maximum=t.value:n.exclusiveMaximum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value<=t.value:o.value<t.value)||o.issues.push({origin:r,code:"too_big",maximum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),tc=_("$ZodCheckGreaterThan",(e,t)=>{De.init(e,t);let r=k_[typeof t.value];e._zod.onattach.push(o=>{let n=o._zod.bag,i=(t.inclusive?n.minimum:n.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?n.minimum=t.value:n.exclusiveMinimum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value>=t.value:o.value>t.value)||o.issues.push({origin:r,code:"too_small",minimum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Cp=_("$ZodCheckMultipleOf",(e,t)=>{De.init(e,t),e._zod.onattach.push(r=>{var o;(o=r._zod.bag).multipleOf??(o.multipleOf=t.value)}),e._zod.check=r=>{if(typeof r.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof r.value=="bigint"?r.value%t.value===BigInt(0):Xd(r.value,t.value)===0)||r.issues.push({origin:typeof r.value,code:"not_multiple_of",divisor:t.value,input:r.value,inst:e,continue:!t.abort})}}),Ap=_("$ZodCheckNumberFormat",(e,t)=>{De.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),o=r?"int":"number",[n,i]=np[t.format];e._zod.onattach.push(s=>{let a=s._zod.bag;a.format=t.format,a.minimum=n,a.maximum=i,r&&(a.pattern=zp)}),e._zod.check=s=>{let a=s.value;if(r){if(!Number.isInteger(a)){s.issues.push({expected:o,format:t.format,code:"invalid_type",input:a,inst:e});return}if(!Number.isSafeInteger(a)){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:o,continue:!t.abort}):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:o,continue:!t.abort});return}}a<n&&s.issues.push({origin:"number",input:a,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),a>i&&s.issues.push({origin:"number",input:a,code:"too_big",maximum:i,inst:e})}}),Dp=_("$ZodCheckBigIntFormat",(e,t)=>{De.init(e,t);let[r,o]=op[t.format];e._zod.onattach.push(n=>{let i=n._zod.bag;i.format=t.format,i.minimum=r,i.maximum=o}),e._zod.check=n=>{let i=n.value;i<r&&n.issues.push({origin:"bigint",input:i,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!t.abort}),i>o&&n.issues.push({origin:"bigint",input:i,code:"too_big",maximum:o,inst:e})}}),qp=_("$ZodCheckMaxSize",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let n=o.value;n.size<=t.maximum||o.issues.push({origin:Ei(n),code:"too_big",maximum:t.maximum,input:n,inst:e,continue:!t.abort})}}),Mp=_("$ZodCheckMinSize",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let n=o.value;n.size>=t.minimum||o.issues.push({origin:Ei(n),code:"too_small",minimum:t.minimum,input:n,inst:e,continue:!t.abort})}}),Up=_("$ZodCheckSizeEquals",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag;n.minimum=t.size,n.maximum=t.size,n.size=t.size}),e._zod.check=o=>{let n=o.value,i=n.size;if(i===t.size)return;let s=i>t.size;o.issues.push({origin:Ei(n),...s?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),Zp=_("$ZodCheckMaxLength",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let n=o.value;if(n.length<=t.maximum)return;let s=Ii(n);o.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),Lp=_("$ZodCheckMinLength",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let n=o.value;if(n.length>=t.minimum)return;let s=Ii(n);o.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),Vp=_("$ZodCheckLengthEquals",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag;n.minimum=t.length,n.maximum=t.length,n.length=t.length}),e._zod.check=o=>{let n=o.value,i=n.length;if(i===t.length)return;let s=Ii(n),a=i>t.length;o.issues.push({origin:s,...a?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),fo=_("$ZodCheckStringFormat",(e,t)=>{var r,o;De.init(e,t),e._zod.onattach.push(n=>{let i=n._zod.bag;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=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:t.format,input:n.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(o=e._zod).check??(o.check=()=>{})}),Fp=_("$ZodCheckRegex",(e,t)=>{fo.init(e,t),e._zod.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Gp=_("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=Np),fo.init(e,t)}),Wp=_("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=Rp),fo.init(e,t)}),Kp=_("$ZodCheckIncludes",(e,t)=>{De.init(e,t);let r=$r(t.includes),o=new RegExp(typeof t.position=="number"?`^.{${t.position}}${r}`:r);t.pattern=o,e._zod.onattach.push(n=>{let i=n._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(o)}),e._zod.check=n=>{n.value.includes(t.includes,t.position)||n.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:n.value,inst:e,continue:!t.abort})}}),Hp=_("$ZodCheckStartsWith",(e,t)=>{De.init(e,t);let r=new RegExp(`^${$r(t.prefix)}.*`);t.pattern??(t.pattern=r),e._zod.onattach.push(o=>{let n=o._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(r)}),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),Jp=_("$ZodCheckEndsWith",(e,t)=>{De.init(e,t);let r=new RegExp(`.*${$r(t.suffix)}$`);t.pattern??(t.pattern=r),e._zod.onattach.push(o=>{let n=o._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(r)}),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}});function w_(e,t,r){e.issues.length&&t.issues.push(...mt(r,e.issues))}var Bp=_("$ZodCheckProperty",(e,t)=>{De.init(e,t),e._zod.check=r=>{let o=t.schema._zod.run({value:r.value[t.property],issues:[]},{});if(o instanceof Promise)return o.then(n=>w_(n,r,t.property));w_(o,r,t.property)}}),Yp=_("$ZodCheckMimeType",(e,t)=>{De.init(e,t);let r=new Set(t.mime);e._zod.onattach.push(o=>{o._zod.bag.mime=t.mime}),e._zod.check=o=>{r.has(o.value.type)||o.issues.push({code:"invalid_value",values:t.mime,input:o.value.type,inst:e})}}),Xp=_("$ZodCheckOverwrite",(e,t)=>{De.init(e,t),e._zod.check=r=>{r.value=t.tx(r.value)}});var Oi=class{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let o=t.split(`
16
+ deps: ${r}}`};var yM={keyword:"dependencies",type:"object",schemaType:"object",error:gr.error,code(e){let[t,r]=bM(e);T0(e,t),P0(e,r)}};function bM({schema:e}){let t={},r={};for(let o in e){if(o==="__proto__")continue;let n=Array.isArray(e[o])?t:r;n[o]=e[o]}return[t,r]}function T0(e,t=e.schema){let{gen:r,data:o,it:n}=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,Ma.propertyInData)(r,o,s,n.opts.ownProperties);e.setParams({property:s,depsCount:a.length,deps:a.join(", ")}),n.allErrors?r.if(c,()=>{for(let u of a)(0,Ma.checkReportMissingProp)(e,u)}):(r.if((0,Cv._)`${c} && (${(0,Ma.checkMissingProp)(e,a,i)})`),(0,Ma.reportMissingProp)(e,i),r.else())}}gr.validatePropertyDeps=T0;function P0(e,t=e.schema){let{gen:r,data:o,keyword:n,it:i}=e,s=r.name("valid");for(let a in t)(0,_M.alwaysValidSchema)(i,t[a])||(r.if((0,Ma.propertyInData)(r,o,a,i.opts.ownProperties),()=>{let c=e.subschema({keyword:n,schemaProp:a},s);e.mergeValidEvaluated(c,s)},()=>r.var(s,!0)),e.ok(s))}gr.validateSchemaDeps=P0;gr.default=yM});var I0=$(Av=>{"use strict";Object.defineProperty(Av,"__esModule",{value:!0});var E0=Q(),$M=ve(),wM={message:"property name must be valid",params:({params:e})=>(0,E0._)`{propertyName: ${e.propertyName}}`},kM={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:wM,code(e){let{gen:t,schema:r,data:o,it:n}=e;if((0,$M.alwaysValidSchema)(n,r))return;let i=t.name("valid");t.forIn("key",o,s=>{e.setParams({propertyName:s}),e.subschema({keyword:"propertyNames",data:s,dataTypes:["string"],propertyName:s,compositeRule:!0},i),t.if((0,E0.not)(i),()=>{e.error(!0),n.allErrors||t.break()})}),e.ok(i)}};Av.default=kM});var qv=$(Dv=>{"use strict";Object.defineProperty(Dv,"__esModule",{value:!0});var Td=Zt(),nr=Q(),xM=Nr(),Pd=ve(),SM={message:"must NOT have additional properties",params:({params:e})=>(0,nr._)`{additionalProperty: ${e.additionalProperty}}`},TM={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:SM,code(e){let{gen:t,schema:r,parentSchema:o,data:n,errsCount:i,it:s}=e;if(!i)throw new Error("ajv implementation error");let{allErrors:a,opts:c}=s;if(s.props=!0,c.removeAdditional!=="all"&&(0,Pd.alwaysValidSchema)(s,r))return;let u=(0,Td.allSchemaProperties)(o.properties),l=(0,Td.allSchemaProperties)(o.patternProperties);d(),e.ok((0,nr._)`${i} === ${xM.default.errors}`);function d(){t.forIn("key",n,v=>{!u.length&&!l.length?p(v):t.if(h(v),()=>p(v))})}function h(v){let y;if(u.length>8){let w=(0,Pd.schemaRefOrVal)(s,o.properties,"properties");y=(0,Td.isOwnProperty)(t,w,v)}else u.length?y=(0,nr.or)(...u.map(w=>(0,nr._)`${v} === ${w}`)):y=nr.nil;return l.length&&(y=(0,nr.or)(y,...l.map(w=>(0,nr._)`${(0,Td.usePattern)(e,w)}.test(${v})`))),(0,nr.not)(y)}function m(v){t.code((0,nr._)`delete ${n}[${v}]`)}function p(v){if(c.removeAdditional==="all"||c.removeAdditional&&r===!1){m(v);return}if(r===!1){e.setParams({additionalProperty:v}),e.error(),a||t.break();return}if(typeof r=="object"&&!(0,Pd.alwaysValidSchema)(s,r)){let y=t.name("valid");c.removeAdditional==="failing"?(f(v,y,!1),t.if((0,nr.not)(y),()=>{e.reset(),m(v)})):(f(v,y),a||t.if((0,nr.not)(y),()=>t.break()))}}function f(v,y,w){let k={keyword:"additionalProperties",dataProp:v,dataPropType:Pd.Type.Str};w===!1&&Object.assign(k,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(k,y)}}};Dv.default=TM});var N0=$(Uv=>{"use strict";Object.defineProperty(Uv,"__esModule",{value:!0});var PM=Ta(),O0=Zt(),Mv=ve(),j0=qv(),zM={keyword:"properties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,parentSchema:o,data:n,it:i}=e;i.opts.removeAdditional==="all"&&o.additionalProperties===void 0&&j0.default.code(new PM.KeywordCxt(i,j0.default,"additionalProperties"));let s=(0,O0.allSchemaProperties)(r);for(let d of s)i.definedProperties.add(d);i.opts.unevaluated&&s.length&&i.props!==!0&&(i.props=Mv.mergeEvaluated.props(t,(0,Mv.toHash)(s),i.props));let a=s.filter(d=>!(0,Mv.alwaysValidSchema)(i,r[d]));if(a.length===0)return;let c=t.name("valid");for(let d of a)u(d)?l(d):(t.if((0,O0.propertyInData)(t,n,d,i.opts.ownProperties)),l(d),i.allErrors||t.else().var(c,!0),t.endIf()),e.it.definedProperties.add(d),e.ok(c);function u(d){return i.opts.useDefaults&&!i.compositeRule&&r[d].default!==void 0}function l(d){e.subschema({keyword:"properties",schemaProp:d,dataProp:d},c)}}};Uv.default=zM});var D0=$(Zv=>{"use strict";Object.defineProperty(Zv,"__esModule",{value:!0});var R0=Zt(),zd=Q(),C0=ve(),A0=ve(),EM={keyword:"patternProperties",type:"object",schemaType:"object",code(e){let{gen:t,schema:r,data:o,parentSchema:n,it:i}=e,{opts:s}=i,a=(0,R0.allSchemaProperties)(r),c=a.filter(f=>(0,C0.alwaysValidSchema)(i,r[f]));if(a.length===0||c.length===a.length&&(!i.opts.unevaluated||i.props===!0))return;let u=s.strictSchema&&!s.allowMatchingProperties&&n.properties,l=t.name("valid");i.props!==!0&&!(i.props instanceof zd.Name)&&(i.props=(0,A0.evaluatedPropsToName)(t,i.props));let{props:d}=i;h();function h(){for(let f of a)u&&m(f),i.allErrors?p(f):(t.var(l,!0),p(f),t.if(l))}function m(f){for(let v in u)new RegExp(f).test(v)&&(0,C0.checkStrictMode)(i,`property ${v} matches pattern ${f} (use allowMatchingProperties)`)}function p(f){t.forIn("key",o,v=>{t.if((0,zd._)`${(0,R0.usePattern)(e,f)}.test(${v})`,()=>{let y=c.includes(f);y||e.subschema({keyword:"patternProperties",schemaProp:f,dataProp:v,dataPropType:A0.Type.Str},l),i.opts.unevaluated&&d!==!0?t.assign((0,zd._)`${d}[${v}]`,!0):!y&&!i.allErrors&&t.if((0,zd.not)(l),()=>t.break())})})}}};Zv.default=EM});var q0=$(Vv=>{"use strict";Object.defineProperty(Vv,"__esModule",{value:!0});var IM=ve(),OM={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){let{gen:t,schema:r,it:o}=e;if((0,IM.alwaysValidSchema)(o,r)){e.fail();return}let n=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},n),e.failResult(n,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};Vv.default=OM});var M0=$(Lv=>{"use strict";Object.defineProperty(Lv,"__esModule",{value:!0});var jM=Zt(),NM={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:jM.validateUnion,error:{message:"must match a schema in anyOf"}};Lv.default=NM});var U0=$(Fv=>{"use strict";Object.defineProperty(Fv,"__esModule",{value:!0});var Ed=Q(),RM=ve(),CM={message:"must match exactly one schema in oneOf",params:({params:e})=>(0,Ed._)`{passingSchemas: ${e.passing}}`},AM={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:CM,code(e){let{gen:t,schema:r,parentSchema:o,it:n}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");if(n.opts.discriminator&&o.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,d)=>{let h;(0,RM.alwaysValidSchema)(n,l)?t.var(c,!0):h=e.subschema({keyword:"oneOf",schemaProp:d,compositeRule:!0},c),d>0&&t.if((0,Ed._)`${c} && ${s}`).assign(s,!1).assign(a,(0,Ed._)`[${a}, ${d}]`).else(),t.if(c,()=>{t.assign(s,!0),t.assign(a,d),h&&e.mergeEvaluated(h,Ed.Name)})})}}};Fv.default=AM});var Z0=$(Gv=>{"use strict";Object.defineProperty(Gv,"__esModule",{value:!0});var DM=ve(),qM={keyword:"allOf",schemaType:"array",code(e){let{gen:t,schema:r,it:o}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");let n=t.name("valid");r.forEach((i,s)=>{if((0,DM.alwaysValidSchema)(o,i))return;let a=e.subschema({keyword:"allOf",schemaProp:s},n);e.ok(n),e.mergeEvaluated(a)})}};Gv.default=qM});var F0=$(Wv=>{"use strict";Object.defineProperty(Wv,"__esModule",{value:!0});var Id=Q(),L0=ve(),MM={message:({params:e})=>(0,Id.str)`must match "${e.ifClause}" schema`,params:({params:e})=>(0,Id._)`{failingKeyword: ${e.ifClause}}`},UM={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:MM,code(e){let{gen:t,parentSchema:r,it:o}=e;r.then===void 0&&r.else===void 0&&(0,L0.checkStrictMode)(o,'"if" without "then" and "else" is ignored');let n=V0(o,"then"),i=V0(o,"else");if(!n&&!i)return;let s=t.let("valid",!0),a=t.name("_valid");if(c(),e.reset(),n&&i){let l=t.let("ifClause");e.setParams({ifClause:l}),t.if(a,u("then",l),u("else",l))}else n?t.if(a,u("then")):t.if((0,Id.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,d){return()=>{let h=e.subschema({keyword:l},a);t.assign(s,a),e.mergeValidEvaluated(h,s),d?t.assign(d,(0,Id._)`${l}`):e.setParams({ifClause:l})}}}};function V0(e,t){let r=e.schema[t];return r!==void 0&&!(0,L0.alwaysValidSchema)(e,r)}Wv.default=UM});var G0=$(Kv=>{"use strict";Object.defineProperty(Kv,"__esModule",{value:!0});var ZM=ve(),VM={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:r}){t.if===void 0&&(0,ZM.checkStrictMode)(r,`"${e}" without "if" is ignored`)}};Kv.default=VM});var W0=$(Hv=>{"use strict";Object.defineProperty(Hv,"__esModule",{value:!0});var LM=Iv(),FM=w0(),GM=Ov(),WM=x0(),KM=S0(),HM=z0(),JM=I0(),BM=qv(),YM=N0(),XM=D0(),QM=q0(),e4=M0(),t4=U0(),r4=Z0(),n4=F0(),o4=G0();function i4(e=!1){let t=[QM.default,e4.default,t4.default,r4.default,n4.default,o4.default,JM.default,BM.default,HM.default,YM.default,XM.default];return e?t.push(FM.default,WM.default):t.push(LM.default,GM.default),t.push(KM.default),t}Hv.default=i4});var K0=$(Jv=>{"use strict";Object.defineProperty(Jv,"__esModule",{value:!0});var Ve=Q(),s4={message:({schemaCode:e})=>(0,Ve.str)`must match format "${e}"`,params:({schemaCode:e})=>(0,Ve._)`{format: ${e}}`},a4={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:s4,code(e,t){let{gen:r,data:o,$data:n,schema:i,schemaCode:s,it:a}=e,{opts:c,errSchemaPath:u,schemaEnv:l,self:d}=a;if(!c.validateFormats)return;n?h():m();function h(){let p=r.scopeValue("formats",{ref:d.formats,code:c.code.formats}),f=r.const("fDef",(0,Ve._)`${p}[${s}]`),v=r.let("fType"),y=r.let("format");r.if((0,Ve._)`typeof ${f} == "object" && !(${f} instanceof RegExp)`,()=>r.assign(v,(0,Ve._)`${f}.type || "string"`).assign(y,(0,Ve._)`${f}.validate`),()=>r.assign(v,(0,Ve._)`"string"`).assign(y,f)),e.fail$data((0,Ve.or)(w(),k()));function w(){return c.strictSchema===!1?Ve.nil:(0,Ve._)`${s} && !${y}`}function k(){let E=l.$async?(0,Ve._)`(${f}.async ? await ${y}(${o}) : ${y}(${o}))`:(0,Ve._)`${y}(${o})`,P=(0,Ve._)`(typeof ${y} == "function" ? ${E} : ${y}.test(${o}))`;return(0,Ve._)`${y} && ${y} !== true && ${v} === ${t} && !${P}`}}function m(){let p=d.formats[i];if(!p){w();return}if(p===!0)return;let[f,v,y]=k(p);f===t&&e.pass(E());function w(){if(c.strictSchema===!1){d.logger.warn(P());return}throw new Error(P());function P(){return`unknown format "${i}" ignored in schema at path "${u}"`}}function k(P){let ze=P instanceof RegExp?(0,Ve.regexpCode)(P):c.code.formats?(0,Ve._)`${c.code.formats}${(0,Ve.getProperty)(i)}`:void 0,Me=r.scopeValue("formats",{key:i,ref:P,code:ze});return typeof P=="object"&&!(P instanceof RegExp)?[P.type||"string",P.validate,(0,Ve._)`${Me}.validate`]:["string",P,Me]}function E(){if(typeof p=="object"&&!(p instanceof RegExp)&&p.async){if(!l.$async)throw new Error("async format in sync schema");return(0,Ve._)`await ${y}(${o})`}return typeof v=="function"?(0,Ve._)`${y}(${o})`:(0,Ve._)`${y}.test(${o})`}}}};Jv.default=a4});var H0=$(Bv=>{"use strict";Object.defineProperty(Bv,"__esModule",{value:!0});var c4=K0(),u4=[c4.default];Bv.default=u4});var J0=$(oi=>{"use strict";Object.defineProperty(oi,"__esModule",{value:!0});oi.contentVocabulary=oi.metadataVocabulary=void 0;oi.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"];oi.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]});var Y0=$(Yv=>{"use strict";Object.defineProperty(Yv,"__esModule",{value:!0});var l4=o0(),d4=_0(),p4=W0(),f4=H0(),B0=J0(),m4=[l4.default,d4.default,(0,p4.default)(),f4.default,B0.metadataVocabulary,B0.contentVocabulary];Yv.default=m4});var Q0=$(Od=>{"use strict";Object.defineProperty(Od,"__esModule",{value:!0});Od.DiscrError=void 0;var X0;(function(e){e.Tag="tag",e.Mapping="mapping"})(X0||(Od.DiscrError=X0={}))});var tS=$(Qv=>{"use strict";Object.defineProperty(Qv,"__esModule",{value:!0});var ii=Q(),Xv=Q0(),eS=gd(),h4=Pa(),g4=ve(),v4={message:({params:{discrError:e,tagName:t}})=>e===Xv.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:r}})=>(0,ii._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`},_4={keyword:"discriminator",type:"object",schemaType:"object",error:v4,code(e){let{gen:t,data:r,schema:o,parentSchema:n,it:i}=e,{oneOf:s}=n;if(!i.opts.discriminator)throw new Error("discriminator: requires discriminator option");let a=o.propertyName;if(typeof a!="string")throw new Error("discriminator: requires propertyName");if(o.mapping)throw new Error("discriminator: mapping is not supported");if(!s)throw new Error("discriminator: requires oneOf keyword");let c=t.let("valid",!1),u=t.const("tag",(0,ii._)`${r}${(0,ii.getProperty)(a)}`);t.if((0,ii._)`typeof ${u} == "string"`,()=>l(),()=>e.error(!1,{discrError:Xv.DiscrError.Tag,tag:u,tagName:a})),e.ok(c);function l(){let m=h();t.if(!1);for(let p in m)t.elseIf((0,ii._)`${u} === ${p}`),t.assign(c,d(m[p]));t.else(),e.error(!1,{discrError:Xv.DiscrError.Mapping,tag:u,tagName:a}),t.endIf()}function d(m){let p=t.name("valid"),f=e.subschema({keyword:"oneOf",schemaProp:m},p);return e.mergeEvaluated(f,ii.Name),p}function h(){var m;let p={},f=y(n),v=!0;for(let E=0;E<s.length;E++){let P=s[E];if(P?.$ref&&!(0,g4.schemaHasRulesButRef)(P,i.self.RULES)){let Me=P.$ref;if(P=eS.resolveRef.call(i.self,i.schemaEnv.root,i.baseId,Me),P instanceof eS.SchemaEnv&&(P=P.schema),P===void 0)throw new h4.default(i.opts.uriResolver,i.baseId,Me)}let ze=(m=P?.properties)===null||m===void 0?void 0:m[a];if(typeof ze!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${a}"`);v=v&&(f||y(P)),w(ze,E)}if(!v)throw new Error(`discriminator: "${a}" must be required`);return p;function y({required:E}){return Array.isArray(E)&&E.includes(a)}function w(E,P){if(E.const)k(E.const,P);else if(E.enum)for(let ze of E.enum)k(ze,P);else throw new Error(`discriminator: "properties/${a}" must have "const" or "enum"`)}function k(E,P){if(typeof E!="string"||E in p)throw new Error(`discriminator: "${a}" values must be unique strings`);p[E]=P}}}};Qv.default=_4});var rS=$((j3,y4)=>{y4.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 oS=$((Ae,e_)=>{"use strict";Object.defineProperty(Ae,"__esModule",{value:!0});Ae.MissingRefError=Ae.ValidationError=Ae.CodeGen=Ae.Name=Ae.nil=Ae.stringify=Ae.str=Ae._=Ae.KeywordCxt=Ae.Ajv=void 0;var b4=Xx(),$4=Y0(),w4=tS(),nS=rS(),k4=["/properties"],jd="http://json-schema.org/draft-07/schema",si=class extends b4.default{_addVocabularies(){super._addVocabularies(),$4.default.forEach(t=>this.addVocabulary(t)),this.opts.discriminator&&this.addKeyword(w4.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;let t=this.opts.$data?this.$dataMetaSchema(nS,k4):nS;this.addMetaSchema(t,jd,!1),this.refs["http://json-schema.org/schema"]=jd}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(jd)?jd:void 0)}};Ae.Ajv=si;e_.exports=Ae=si;e_.exports.Ajv=si;Object.defineProperty(Ae,"__esModule",{value:!0});Ae.default=si;var x4=Ta();Object.defineProperty(Ae,"KeywordCxt",{enumerable:!0,get:function(){return x4.KeywordCxt}});var ai=Q();Object.defineProperty(Ae,"_",{enumerable:!0,get:function(){return ai._}});Object.defineProperty(Ae,"str",{enumerable:!0,get:function(){return ai.str}});Object.defineProperty(Ae,"stringify",{enumerable:!0,get:function(){return ai.stringify}});Object.defineProperty(Ae,"nil",{enumerable:!0,get:function(){return ai.nil}});Object.defineProperty(Ae,"Name",{enumerable:!0,get:function(){return ai.Name}});Object.defineProperty(Ae,"CodeGen",{enumerable:!0,get:function(){return ai.CodeGen}});var S4=md();Object.defineProperty(Ae,"ValidationError",{enumerable:!0,get:function(){return S4.default}});var T4=Pa();Object.defineProperty(Ae,"MissingRefError",{enumerable:!0,get:function(){return T4.default}})});var iS=$(ci=>{"use strict";Object.defineProperty(ci,"__esModule",{value:!0});ci.formatLimitDefinition=void 0;var P4=oS(),or=Q(),ln=or.operators,Nd={formatMaximum:{okStr:"<=",ok:ln.LTE,fail:ln.GT},formatMinimum:{okStr:">=",ok:ln.GTE,fail:ln.LT},formatExclusiveMaximum:{okStr:"<",ok:ln.LT,fail:ln.GTE},formatExclusiveMinimum:{okStr:">",ok:ln.GT,fail:ln.LTE}},z4={message:({keyword:e,schemaCode:t})=>(0,or.str)`should be ${Nd[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,or._)`{comparison: ${Nd[e].okStr}, limit: ${t}}`};ci.formatLimitDefinition={keyword:Object.keys(Nd),type:"string",schemaType:"string",$data:!0,error:z4,code(e){let{gen:t,data:r,schemaCode:o,keyword:n,it:i}=e,{opts:s,self:a}=i;if(!s.validateFormats)return;let c=new P4.KeywordCxt(i,a.RULES.all.format.definition,"format");c.$data?u():l();function u(){let h=t.scopeValue("formats",{ref:a.formats,code:s.code.formats}),m=t.const("fmt",(0,or._)`${h}[${c.schemaCode}]`);e.fail$data((0,or.or)((0,or._)`typeof ${m} != "object"`,(0,or._)`${m} instanceof RegExp`,(0,or._)`typeof ${m}.compare != "function"`,d(m)))}function l(){let h=c.schema,m=a.formats[h];if(!m||m===!0)return;if(typeof m!="object"||m instanceof RegExp||typeof m.compare!="function")throw new Error(`"${n}": format "${h}" does not define "compare" function`);let p=t.scopeValue("formats",{key:h,ref:m,code:s.code.formats?(0,or._)`${s.code.formats}${(0,or.getProperty)(h)}`:void 0});e.fail$data(d(p))}function d(h){return(0,or._)`${h}.compare(${r}, ${o}) ${Nd[n].fail} 0`}},dependencies:["format"]};var E4=e=>(e.addKeyword(ci.formatLimitDefinition),e);ci.default=E4});var uS=$((Ua,cS)=>{"use strict";Object.defineProperty(Ua,"__esModule",{value:!0});var ui=Fk(),I4=iS(),t_=Q(),sS=new t_.Name("fullFormats"),O4=new t_.Name("fastFormats"),r_=(e,t={keywords:!0})=>{if(Array.isArray(t))return aS(e,t,ui.fullFormats,sS),e;let[r,o]=t.mode==="fast"?[ui.fastFormats,O4]:[ui.fullFormats,sS],n=t.formats||ui.formatNames;return aS(e,n,r,o),t.keywords&&(0,I4.default)(e),e};r_.get=(e,t="full")=>{let o=(t==="fast"?ui.fastFormats:ui.fullFormats)[e];if(!o)throw new Error(`Unknown format "${e}"`);return o};function aS(e,t,r,o){var n,i;(n=(i=e.opts.code).formats)!==null&&n!==void 0||(i.formats=(0,t_._)`require("ajv-formats/dist/formats").${o}`);for(let s of t)e.addFormat(s,r[s])}cS.exports=Ua=r_;Object.defineProperty(Ua,"__esModule",{value:!0});Ua.default=r_});var ct=$((XH,SS)=>{var l_=Object.defineProperty,oU=Object.getOwnPropertyDescriptor,iU=Object.getOwnPropertyNames,sU=Object.prototype.hasOwnProperty,aU=(e,t)=>{for(var r in t)l_(e,r,{get:t[r],enumerable:!0})},cU=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of iU(t))!sU.call(e,n)&&n!==r&&l_(e,n,{get:()=>t[n],enumerable:!(o=oU(t,n))||o.enumerable});return e},uU=e=>cU(l_({},"__esModule",{value:!0}),e),xS={};aU(xS,{APIV2Client:()=>hU,VantageAPIError:()=>Zd,pathEncode:()=>S});SS.exports=uU(xS);function S(e){return encodeURIComponent(e)}var lU={"/v2/exchange_rates/csv":{POST:!0},"/v2/business_metrics/{}/values.csv":{PUT:!0},"/v2/integrations/{}/costs.csv":{POST:!0}},Va={};function dU(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}for(let[e,t]of Object.entries(lU)){let r=e.split("{}").map(dU).join("(.+?)");for(let[o,n]of Object.entries(t))n&&(Va[o]||(Va[o]=[]),Va[o].push(new RegExp(`^${r}$`)))}function pU(e,t){if(Object.prototype.hasOwnProperty.call(Va,e))for(let r of Va[e]){let o=r.test(t);if(r.lastIndex=0,o)return!0}return!1}function fU(e,t){if(t)for(let[r,o]of Object.entries(t))e.searchParams.append(r,Array.isArray(o)?o.map(String).join(","):String(o))}var Zd=class extends Error{constructor(e,t,r){let o=null;if(e!==null)try{let i=JSON.parse(r);Array.isArray(i.errors)&&(o=i.errors)}catch{}let n=e===null?`Vantage API Error: ${r}`:`Vantage API Error: ${e} ${t}`+(o?` - ${o.join(", ")}`:"");super(n),this.status=e,this.statusText=t,this.body=r,this.errors=o}errors};async function u_(e,t,r,o,n){let i;try{i=await fetch(e.toString(),{method:t,headers:r,body:o})}catch(s){let a=s instanceof Error?s.message:String(s),c=new Zd(null,null,a);if(n)return[null,c];throw c}if(!i.ok){let s=new Zd(i.status,i.statusText,await i.text());if(n)return[null,s];throw s}if(i.status===204)return n?[void 0,null]:void 0;try{let s=await i.text(),a;return s&&(a=JSON.parse(s)),n?[a,null]:a}catch(s){let a=s instanceof Error?s.message:String(s),c=new Zd(i.status,i.statusText,a);if(n)return[null,c];throw c}}var mU=class{constructor(e,t,r){this.bearerToken=e,this.neverThrow=t,this.baseUrl=r}async request(e,t,r){let o=new URL(e,this.baseUrl),n={Authorization:`Bearer ${this.bearerToken}`};if(t==="GET")return fU(o,r),u_(o,t,n,void 0,this.neverThrow);if(pU(t,e)){let i=new FormData;for(let[s,a]of Object.entries(r))i.append(s,a);return n["Content-Type"]="multipart/form-data",u_(o,t,n,i,this.neverThrow)}return n["Content-Type"]="application/json",u_(o,t,n,JSON.stringify(r),this.neverThrow)}},hU=class extends mU{constructor(e,t=!1,r="https://api.vantage.sh"){super(e,t,r)}_accessGrants;_anomalyAlerts;_anomalyNotifications;_auditLogs;_billingProfiles;_billingRules;_budgetAlerts;_budgets;_businessMetrics;_costAlerts;_costProviderAccounts;_costReports;_costs;_dashboards;_dataExports;_exchangeRates;_financialCommitmentReports;_financialCommitments;_folders;_integrations;_invoices;_kubernetesEfficiencyReports;_managedAccounts;_me;_costProviders;_costServices;_userFeedback;_networkFlowReports;_products;_recommendations;_recommendationViews;_reportNotifications;_resourceReports;_resources;_savedFilters;_segments;_tags;_teams;_unitCosts;_users;_virtualTagConfigs;_workspaces;_ping;get accessGrants(){return this._accessGrants||(this._accessGrants=new gU(this)),this._accessGrants}get anomalyAlerts(){return this._anomalyAlerts||(this._anomalyAlerts=new vU(this)),this._anomalyAlerts}get anomalyNotifications(){return this._anomalyNotifications||(this._anomalyNotifications=new _U(this)),this._anomalyNotifications}get auditLogs(){return this._auditLogs||(this._auditLogs=new yU(this)),this._auditLogs}get billingProfiles(){return this._billingProfiles||(this._billingProfiles=new bU(this)),this._billingProfiles}get billingRules(){return this._billingRules||(this._billingRules=new $U(this)),this._billingRules}get budgetAlerts(){return this._budgetAlerts||(this._budgetAlerts=new wU(this)),this._budgetAlerts}get budgets(){return this._budgets||(this._budgets=new kU(this)),this._budgets}get businessMetrics(){return this._businessMetrics||(this._businessMetrics=new xU(this)),this._businessMetrics}get costAlerts(){return this._costAlerts||(this._costAlerts=new SU(this)),this._costAlerts}get costProviderAccounts(){return this._costProviderAccounts||(this._costProviderAccounts=new TU(this)),this._costProviderAccounts}get costReports(){return this._costReports||(this._costReports=new PU(this)),this._costReports}get costs(){return this._costs||(this._costs=new zU(this)),this._costs}get dashboards(){return this._dashboards||(this._dashboards=new EU(this)),this._dashboards}get dataExports(){return this._dataExports||(this._dataExports=new IU(this)),this._dataExports}get exchangeRates(){return this._exchangeRates||(this._exchangeRates=new OU(this)),this._exchangeRates}get financialCommitmentReports(){return this._financialCommitmentReports||(this._financialCommitmentReports=new jU(this)),this._financialCommitmentReports}get financialCommitments(){return this._financialCommitments||(this._financialCommitments=new NU(this)),this._financialCommitments}get folders(){return this._folders||(this._folders=new RU(this)),this._folders}get integrations(){return this._integrations||(this._integrations=new CU(this)),this._integrations}get invoices(){return this._invoices||(this._invoices=new AU(this)),this._invoices}get kubernetesEfficiencyReports(){return this._kubernetesEfficiencyReports||(this._kubernetesEfficiencyReports=new DU(this)),this._kubernetesEfficiencyReports}get managedAccounts(){return this._managedAccounts||(this._managedAccounts=new qU(this)),this._managedAccounts}get me(){return this._me||(this._me=new MU(this)),this._me}get costProviders(){return this._costProviders||(this._costProviders=new UU(this)),this._costProviders}get costServices(){return this._costServices||(this._costServices=new ZU(this)),this._costServices}get userFeedback(){return this._userFeedback||(this._userFeedback=new VU(this)),this._userFeedback}get networkFlowReports(){return this._networkFlowReports||(this._networkFlowReports=new LU(this)),this._networkFlowReports}get products(){return this._products||(this._products=new FU(this)),this._products}get recommendations(){return this._recommendations||(this._recommendations=new GU(this)),this._recommendations}get recommendationViews(){return this._recommendationViews||(this._recommendationViews=new WU(this)),this._recommendationViews}get reportNotifications(){return this._reportNotifications||(this._reportNotifications=new KU(this)),this._reportNotifications}get resourceReports(){return this._resourceReports||(this._resourceReports=new HU(this)),this._resourceReports}get resources(){return this._resources||(this._resources=new JU(this)),this._resources}get savedFilters(){return this._savedFilters||(this._savedFilters=new BU(this)),this._savedFilters}get segments(){return this._segments||(this._segments=new YU(this)),this._segments}get tags(){return this._tags||(this._tags=new XU(this)),this._tags}get teams(){return this._teams||(this._teams=new QU(this)),this._teams}get unitCosts(){return this._unitCosts||(this._unitCosts=new eZ(this)),this._unitCosts}get users(){return this._users||(this._users=new tZ(this)),this._users}get virtualTagConfigs(){return this._virtualTagConfigs||(this._virtualTagConfigs=new rZ(this)),this._virtualTagConfigs}get workspaces(){return this._workspaces||(this._workspaces=new nZ(this)),this._workspaces}get ping(){return this._ping||(this._ping=new oZ(this)),this._ping}},gU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/access_grants","GET",e)}create(e){return this.client.request("/v2/access_grants","POST",e)}get(e){return this.client.request(`/v2/access_grants/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/access_grants/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/access_grants/${S(e)}`,"DELETE",{})}},vU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/anomaly_alerts","GET",e)}get(e){return this.client.request(`/v2/anomaly_alerts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/anomaly_alerts/${S(e)}`,"PUT",t)}},_U=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/anomaly_notifications","GET",e)}create(e){return this.client.request("/v2/anomaly_notifications","POST",e)}get(e){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/anomaly_notifications/${S(e)}`,"DELETE",{})}},yU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/audit_logs","GET",e)}get(e){return this.client.request(`/v2/audit_logs/${S(e)}`,"GET",{})}},bU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/billing_profiles","GET",e)}create(e){return this.client.request("/v2/billing_profiles","POST",e)}get(e){return this.client.request(`/v2/billing_profiles/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/billing_profiles/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/billing_profiles/${S(e)}`,"DELETE",{})}},$U=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/billing_rules","GET",e)}create(e){return this.client.request("/v2/billing_rules","POST",e)}get(e){return this.client.request(`/v2/billing_rules/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/billing_rules/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/billing_rules/${S(e)}`,"DELETE",{})}},wU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/budget_alerts","GET",e)}create(e){return this.client.request("/v2/budget_alerts","POST",e)}get(e){return this.client.request(`/v2/budget_alerts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/budget_alerts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/budget_alerts/${S(e)}`,"DELETE",{})}},kU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/budgets","GET",e)}create(e){return this.client.request("/v2/budgets","POST",e)}update(e,t){return this.client.request(`/v2/budgets/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/budgets/${S(e)}`,"DELETE",{})}},xU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/business_metrics","GET",e)}create(e){return this.client.request("/v2/business_metrics","POST",e)}get(e){return this.client.request(`/v2/business_metrics/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/business_metrics/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/business_metrics/${S(e)}`,"DELETE",{})}getValues(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/values`,"GET",t)}getForecastedValues(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/forecasted_values`,"GET",t)}updateValuesCSV(e,t){return this.client.request(`/v2/business_metrics/${S(e)}/values.csv`,"PUT",t)}},SU=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/cost_alerts","POST",e)}get(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events/${S(t)}`,"GET",{})}update(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/cost_alerts/${S(e)}`,"DELETE",{})}getEvents(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events`,"GET",t)}getEvent(e,t){return this.client.request(`/v2/cost_alerts/${S(e)}/events/${S(t)}`,"GET",{})}},TU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_provider_accounts","GET",e)}},PU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_reports","GET",e)}create(e){return this.client.request("/v2/cost_reports","POST",e)}get(e){return this.client.request(`/v2/cost_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/cost_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/cost_reports/${S(e)}`,"DELETE",{})}getForecastedCosts(e,t){return this.client.request(`/v2/cost_reports/${S(e)}/forecasted_costs`,"GET",t)}},zU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/costs","GET",e)}createExport(e){return this.client.request("/v2/costs/data_exports","POST",e)}},EU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/dashboards","GET",e)}create(e){return this.client.request("/v2/dashboards","POST",e)}get(e){return this.client.request(`/v2/dashboards/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/dashboards/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/dashboards/${S(e)}`,"DELETE",{})}},IU=class{constructor(e){this.client=e}get(e){return this.client.request(`/v2/data_exports/${S(e)}`,"GET",{})}},OU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/exchange_rates","GET",e)}createViaCsv(e){return this.client.request("/v2/exchange_rates/csv","POST",e)}},jU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/financial_commitment_reports","GET",e)}create(e){return this.client.request("/v2/financial_commitment_reports","POST",e)}get(e){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/financial_commitment_reports/${S(e)}`,"DELETE",{})}},NU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/financial_commitments","GET",e)}},RU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/folders","GET",e)}create(e){return this.client.request("/v2/folders","POST",e)}get(e){return this.client.request(`/v2/folders/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/folders/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/folders/${S(e)}`,"DELETE",{})}},CU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/integrations","GET",e)}get(e){return this.client.request(`/v2/integrations/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/integrations/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/integrations/${S(e)}`,"DELETE",{})}createCustomProviderIntegration(e){return this.client.request("/v2/integrations/custom_provider","POST",e)}createUserCostsUploadViaCsv(e,t){return this.client.request(`/v2/integrations/${S(e)}/costs.csv`,"POST",t)}deleteUserCostsUpload(e,t){return this.client.request(`/v2/integrations/${S(e)}/costs/${S(t)}`,"DELETE",{})}getUserCostsUploads(e){return this.client.request(`/v2/integrations/${S(e)}/costs`,"GET",{})}createGCPIntegration(e){return this.client.request("/v2/integrations/gcp","POST",e)}createAzureIntegration(e){return this.client.request("/v2/integrations/azure","POST",e)}},AU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/invoices","GET",e)}create(e){return this.client.request("/v2/invoices","POST",e)}get(e){return this.client.request(`/v2/invoices/${S(e)}`,"GET",{})}downloadInvoice(e,t){return this.client.request(`/v2/invoices/${S(e)}/download`,"POST",t)}sendInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/send`,"POST",{})}sendAndApproveInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/send_and_approve`,"POST",{})}getCostReport(e){return this.client.request(`/v2/invoices/${S(e)}/cost_report`,"GET",{})}regenerateInvoice(e){return this.client.request(`/v2/invoices/${S(e)}/regenerate`,"POST",{})}},DU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/kubernetes_efficiency_reports","GET",e)}create(e){return this.client.request("/v2/kubernetes_efficiency_reports","POST",e)}get(e){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/kubernetes_efficiency_reports/${S(e)}`,"DELETE",{})}createExport(e){return this.client.request("/v2/kubernetes_efficiency_reports/data_exports","POST",e)}},qU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/managed_accounts","GET",e)}create(e){return this.client.request("/v2/managed_accounts","POST",e)}get(e){return this.client.request(`/v2/managed_accounts/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/managed_accounts/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/managed_accounts/${S(e)}`,"DELETE",{})}updateSsoConnectionForManagedAccount(e,t){return this.client.request(`/v2/managed_accounts/${S(e)}/sso_connection`,"PUT",t)}createSsoConnectionForManagedAccount(e,t){return this.client.request(`/v2/managed_accounts/${S(e)}/sso_connection`,"POST",t)}},MU=class{constructor(e){this.client=e}get(){return this.client.request("/v2/me","GET",{})}},UU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_providers","GET",e)}},ZU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/cost_services","GET",e)}},VU=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/user_feedback","POST",e)}},LU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/network_flow_reports","GET",e)}create(e){return this.client.request("/v2/network_flow_reports","POST",e)}get(e){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/network_flow_reports/${S(e)}`,"DELETE",{})}},FU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/products","GET",e)}get(e,t){return this.client.request(`/v2/products/${S(e)}/prices/${S(t)}`,"GET",{})}getPrices(e,t){return this.client.request(`/v2/products/${S(e)}/prices`,"GET",t)}getPrice(e,t){return this.client.request(`/v2/products/${S(e)}/prices/${S(t)}`,"GET",{})}},GU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/recommendations","GET",e)}get(e){return this.client.request(`/v2/recommendations/${S(e)}`,"GET",{})}getResources(e,t){return this.client.request(`/v2/recommendations/${S(e)}/resources`,"GET",t)}getResource(e,t){return this.client.request(`/v2/recommendations/${S(e)}/resources/${S(t)}`,"GET",{})}getTypeResources(e,t){return this.client.request(`/v2/recommendations/by_type/${S(e)}/resources`,"GET",t)}},WU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/recommendation_views","GET",e)}create(e){return this.client.request("/v2/recommendation_views","POST",e)}get(e){return this.client.request(`/v2/recommendation_views/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/recommendation_views/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/recommendation_views/${S(e)}`,"DELETE",{})}},KU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/report_notifications","GET",e)}create(e){return this.client.request("/v2/report_notifications","POST",e)}get(e){return this.client.request(`/v2/report_notifications/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/report_notifications/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/report_notifications/${S(e)}`,"DELETE",{})}},HU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/resource_reports","GET",e)}create(e){return this.client.request("/v2/resource_reports","POST",e)}get(e){return this.client.request(`/v2/resource_reports/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/resource_reports/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/resource_reports/${S(e)}`,"DELETE",{})}getColumns(e){return this.client.request("/v2/resource_reports/columns","GET",e)}},JU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/resources","GET",e)}},BU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/saved_filters","GET",e)}create(e){return this.client.request("/v2/saved_filters","POST",e)}get(e){return this.client.request(`/v2/saved_filters/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/saved_filters/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/saved_filters/${S(e)}`,"DELETE",{})}},YU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/segments","GET",e)}create(e){return this.client.request("/v2/segments","POST",e)}get(e){return this.client.request(`/v2/segments/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/segments/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/segments/${S(e)}`,"DELETE",{})}},XU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/tags","GET",e)}getValues(e,t){return this.client.request(`/v2/tags/${S(e)}/values`,"GET",t)}},QU=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/teams","GET",e)}create(e){return this.client.request("/v2/teams","POST",e)}get(e){return this.client.request(`/v2/teams/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/teams/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/teams/${S(e)}`,"DELETE",{})}getMembers(e,t){return this.client.request(`/v2/teams/${S(e)}/members`,"GET",t)}addTeamMember(e,t){return this.client.request(`/v2/teams/${S(e)}/members`,"POST",t)}removeTeamMember(e,t){return this.client.request(`/v2/teams/${S(e)}/members/${S(t)}`,"DELETE",{})}},eZ=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/unit_costs","GET",e)}createExport(e){return this.client.request("/v2/unit_costs/data_exports","POST",e)}},tZ=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/users","GET",e)}get(e){return this.client.request(`/v2/users/${S(e)}`,"GET",{})}},rZ=class{constructor(e){this.client=e}create(e){return this.client.request("/v2/virtual_tag_configs","POST",e)}get(){return this.client.request("/v2/virtual_tag_configs","GET",{})}update(e,t){return this.client.request(`/v2/virtual_tag_configs/${S(e)}`,"PUT",t)}delete(e){return this.client.request(`/v2/virtual_tag_configs/${S(e)}`,"DELETE",{})}getStatus(e){return this.client.request(`/v2/virtual_tag_configs/${S(e)}/status`,"GET",{})}updateAsyncVirtualTagConfig(e,t){return this.client.request(`/v2/virtual_tag_configs/${S(e)}/async`,"PUT",t)}getAsyncVirtualTagConfigStatus(e){return this.client.request(`/v2/virtual_tag_configs/async/${S(e)}`,"GET",{})}},nZ=class{constructor(e){this.client=e}list(e){return this.client.request("/v2/workspaces","GET",e)}create(e){return this.client.request("/v2/workspaces","POST",e)}get(e){return this.client.request(`/v2/workspaces/${S(e)}`,"GET",{})}update(e,t){return this.client.request(`/v2/workspaces/${S(e)}`,"PUT",t)}},oZ=class{constructor(e){this.client=e}get(){return this.client.request("/v2/ping","GET",{})}}});var ce;(function(e){e.assertEqual=n=>{};function t(n){}e.assertIs=t;function r(n){throw new Error}e.assertNever=r,e.arrayToEnum=n=>{let i={};for(let s of n)i[s]=s;return i},e.getValidEnumValues=n=>{let i=e.objectKeys(n).filter(a=>typeof n[n[a]]!="number"),s={};for(let a of i)s[a]=n[a];return e.objectValues(s)},e.objectValues=n=>e.objectKeys(n).map(function(i){return n[i]}),e.objectKeys=typeof Object.keys=="function"?n=>Object.keys(n):n=>{let i=[];for(let s in n)Object.prototype.hasOwnProperty.call(n,s)&&i.push(s);return i},e.find=(n,i)=>{for(let s of n)if(i(s))return s},e.isInteger=typeof Number.isInteger=="function"?n=>Number.isInteger(n):n=>typeof n=="number"&&Number.isFinite(n)&&Math.floor(n)===n;function o(n,i=" | "){return n.map(s=>typeof s=="string"?`'${s}'`:s).join(i)}e.joinValues=o,e.jsonStringifyReplacer=(n,i)=>typeof i=="bigint"?i.toString():i})(ce||(ce={}));var p_;(function(e){e.mergeShapes=(t,r)=>({...t,...r})})(p_||(p_={}));var A=ce.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),vr=e=>{switch(typeof e){case"undefined":return A.undefined;case"string":return A.string;case"number":return Number.isNaN(e)?A.nan:A.number;case"boolean":return A.boolean;case"function":return A.function;case"bigint":return A.bigint;case"symbol":return A.symbol;case"object":return Array.isArray(e)?A.array:e===null?A.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?A.promise:typeof Map<"u"&&e instanceof Map?A.map:typeof Set<"u"&&e instanceof Set?A.set:typeof Date<"u"&&e instanceof Date?A.date:A.object;default:return A.unknown}};var T=ce.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"]);var Tt=class e extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=o=>{this.issues=[...this.issues,o]},this.addIssues=(o=[])=>{this.issues=[...this.issues,...o]};let r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=t}format(t){let r=t||function(i){return i.message},o={_errors:[]},n=i=>{for(let s of i.issues)if(s.code==="invalid_union")s.unionErrors.map(n);else if(s.code==="invalid_return_type")n(s.returnTypeError);else if(s.code==="invalid_arguments")n(s.argumentsError);else if(s.path.length===0)o._errors.push(r(s));else{let a=o,c=0;for(;c<s.path.length;){let u=s.path[c];c===s.path.length-1?(a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s))):a[u]=a[u]||{_errors:[]},a=a[u],c++}}};return n(this),o}static assert(t){if(!(t instanceof e))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ce.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=r=>r.message){let r={},o=[];for(let n of this.issues)if(n.path.length>0){let i=n.path[0];r[i]=r[i]||[],r[i].push(t(n))}else o.push(t(n));return{formErrors:o,fieldErrors:r}}get formErrors(){return this.flatten()}};Tt.create=e=>new Tt(e);var KS=(e,t)=>{let r;switch(e.code){case T.invalid_type:e.received===A.undefined?r="Required":r=`Expected ${e.expected}, received ${e.received}`;break;case T.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,ce.jsonStringifyReplacer)}`;break;case T.unrecognized_keys:r=`Unrecognized key(s) in object: ${ce.joinValues(e.keys,", ")}`;break;case T.invalid_union:r="Invalid input";break;case T.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${ce.joinValues(e.options)}`;break;case T.invalid_enum_value:r=`Invalid enum value. Expected ${ce.joinValues(e.options)}, received '${e.received}'`;break;case T.invalid_arguments:r="Invalid function arguments";break;case T.invalid_return_type:r="Invalid function return type";break;case T.invalid_date:r="Invalid date";break;case T.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(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}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:ce.assertNever(e.validation):e.validation!=="regex"?r=`Invalid ${e.validation}`:r="Invalid";break;case T.too_small:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?r=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`: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))}`:r="Invalid input";break;case T.too_big:e.type==="array"?r=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?r=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?r=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?r=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?r=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:r="Invalid input";break;case T.custom:r="Invalid input";break;case T.invalid_intersection_types:r="Intersection results could not be merged";break;case T.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case T.not_finite:r="Number must be finite";break;default:r=t.defaultError,ce.assertNever(e)}return{message:r}},Cr=KS;var HS=Cr;function pi(){return HS}var Fa=e=>{let{data:t,path:r,errorMaps:o,issueData:n}=e,i=[...r,...n.path||[]],s={...n,path:i};if(n.message!==void 0)return{...n,path:i,message:n.message};let a="",c=o.filter(u=>!!u).slice().reverse();for(let u of c)a=u(s,{data:t,defaultError:a}).message;return{...n,path:i,message:a}};function C(e,t){let r=pi(),o=Fa({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===Cr?void 0:Cr].filter(n=>!!n)});e.common.issues.push(o)}var Qe=class e{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,r){let o=[];for(let n of r){if(n.status==="aborted")return F;n.status==="dirty"&&t.dirty(),o.push(n.value)}return{status:t.value,value:o}}static async mergeObjectAsync(t,r){let o=[];for(let n of r){let i=await n.key,s=await n.value;o.push({key:i,value:s})}return e.mergeObjectSync(t,o)}static mergeObjectSync(t,r){let o={};for(let n of r){let{key:i,value:s}=n;if(i.status==="aborted"||s.status==="aborted")return F;i.status==="dirty"&&t.dirty(),s.status==="dirty"&&t.dirty(),i.value!=="__proto__"&&(typeof s.value<"u"||n.alwaysSet)&&(o[i.value]=s.value)}return{status:t.value,value:o}}},F=Object.freeze({status:"aborted"}),Kn=e=>({status:"dirty",value:e}),ut=e=>({status:"valid",value:e}),Fd=e=>e.status==="aborted",Gd=e=>e.status==="dirty",hn=e=>e.status==="valid",fi=e=>typeof Promise<"u"&&e instanceof Promise;var q;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t?.message})(q||(q={}));var Ot=class{constructor(t,r,o,n){this._cachedPath=[],this.parent=t,this.data=r,this._path=o,this._key=n}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}},f_=(e,t)=>{if(hn(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let r=new Tt(e.common.issues);return this._error=r,this._error}}};function J(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:o,description:n}=e;if(t&&(r||o))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:n}:{errorMap:(s,a)=>{let{message:c}=e;return s.code==="invalid_enum_value"?{message:c??a.defaultError}:typeof a.data>"u"?{message:c??o??a.defaultError}:s.code!=="invalid_type"?{message:a.defaultError}:{message:c??r??a.defaultError}},description:n}}var ee=class{get description(){return this._def.description}_getType(t){return vr(t.data)}_getOrReturnCtx(t,r){return r||{common:t.parent.common,data:t.data,parsedType:vr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new Qe,ctx:{common:t.parent.common,data:t.data,parsedType:vr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){let r=this._parse(t);if(fi(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(t){let r=this._parse(t);return Promise.resolve(r)}parse(t,r){let o=this.safeParse(t,r);if(o.success)return o.data;throw o.error}safeParse(t,r){let o={common:{issues:[],async:r?.async??!1,contextualErrorMap:r?.errorMap},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:vr(t)},n=this._parseSync({data:t,path:o.path,parent:o});return f_(o,n)}"~validate"(t){let r={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:vr(t)};if(!this["~standard"].async)try{let o=this._parseSync({data:t,path:[],parent:r});return hn(o)?{value:o.value}:{issues:r.common.issues}}catch(o){o?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),r.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:r}).then(o=>hn(o)?{value:o.value}:{issues:r.common.issues})}async parseAsync(t,r){let o=await this.safeParseAsync(t,r);if(o.success)return o.data;throw o.error}async safeParseAsync(t,r){let o={common:{issues:[],contextualErrorMap:r?.errorMap,async:!0},path:r?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:vr(t)},n=this._parse({data:t,path:o.path,parent:o}),i=await(fi(n)?n:Promise.resolve(n));return f_(o,i)}refine(t,r){let o=n=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(n):r;return this._refinement((n,i)=>{let s=t(n),a=()=>i.addIssue({code:T.custom,...o(n)});return typeof Promise<"u"&&s instanceof Promise?s.then(c=>c?!0:(a(),!1)):s?!0:(a(),!1)})}refinement(t,r){return this._refinement((o,n)=>t(o)?!0:(n.addIssue(typeof r=="function"?r(o,n):r),!1))}_refinement(t){return new Gt({schema:this,typeName:z.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,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:r=>this["~validate"](r)}}optional(){return Pt.create(this,this._def)}nullable(){return br.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Dr.create(this)}promise(){return gn.create(this,this._def)}or(t){return Xn.create([this,t],this._def)}and(t){return Qn.create(this,t,this._def)}transform(t){return new Gt({...J(this._def),schema:this,typeName:z.ZodEffects,effect:{type:"transform",transform:t}})}default(t){let r=typeof t=="function"?t:()=>t;return new oo({...J(this._def),innerType:this,defaultValue:r,typeName:z.ZodDefault})}brand(){return new Ga({typeName:z.ZodBranded,type:this,...J(this._def)})}catch(t){let r=typeof t=="function"?t:()=>t;return new io({...J(this._def),innerType:this,catchValue:r,typeName:z.ZodCatch})}describe(t){let r=this.constructor;return new r({...this._def,description:t})}pipe(t){return Wa.create(this,t)}readonly(){return so.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}},JS=/^c[^\s-]{8,}$/i,BS=/^[0-9a-z]+$/,YS=/^[0-9A-HJKMNP-TV-Z]{26}$/i,XS=/^[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,QS=/^[a-z0-9_-]{21}$/i,eT=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,tT=/^[-+]?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)?)??$/,rT=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,nT="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",Wd,oT=/^(?:(?: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])$/,iT=/^(?:(?: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])$/,sT=/^(([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]))$/,aT=/^(([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])$/,cT=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,uT=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,m_="((\\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])))",lT=new RegExp(`^${m_}$`);function h_(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);let r=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${r}`}function dT(e){return new RegExp(`^${h_(e)}$`)}function pT(e){let t=`${m_}T${h_(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,new RegExp(`^${t}$`)}function fT(e,t){return!!((t==="v4"||!t)&&oT.test(e)||(t==="v6"||!t)&&sT.test(e))}function mT(e,t){if(!eT.test(e))return!1;try{let[r]=e.split(".");if(!r)return!1;let o=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),n=JSON.parse(atob(o));return!(typeof n!="object"||n===null||"typ"in n&&n?.typ!=="JWT"||!n.alg||t&&n.alg!==t)}catch{return!1}}function hT(e,t){return!!((t==="v4"||!t)&&iT.test(e)||(t==="v6"||!t)&&aT.test(e))}var Jn=class e extends ee{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==A.string){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:A.string,received:i.parsedType}),F}let o=new Qe,n;for(let i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(n=this._getOrReturnCtx(t,n),C(n,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="max")t.data.length>i.value&&(n=this._getOrReturnCtx(t,n),C(n,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),o.dirty());else if(i.kind==="length"){let s=t.data.length>i.value,a=t.data.length<i.value;(s||a)&&(n=this._getOrReturnCtx(t,n),s?C(n,{code:T.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):a&&C(n,{code:T.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),o.dirty())}else if(i.kind==="email")rT.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"email",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="emoji")Wd||(Wd=new RegExp(nT,"u")),Wd.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"emoji",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="uuid")XS.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"uuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="nanoid")QS.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"nanoid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid")JS.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"cuid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="cuid2")BS.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"cuid2",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="ulid")YS.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"ulid",code:T.invalid_string,message:i.message}),o.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{n=this._getOrReturnCtx(t,n),C(n,{validation:"url",code:T.invalid_string,message:i.message}),o.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"regex",code:T.invalid_string,message:i.message}),o.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),o.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:{startsWith:i.value},message:i.message}),o.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:{endsWith:i.value},message:i.message}),o.dirty()):i.kind==="datetime"?pT(i).test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:"datetime",message:i.message}),o.dirty()):i.kind==="date"?lT.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:"date",message:i.message}),o.dirty()):i.kind==="time"?dT(i).test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{code:T.invalid_string,validation:"time",message:i.message}),o.dirty()):i.kind==="duration"?tT.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"duration",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="ip"?fT(t.data,i.version)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"ip",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="jwt"?mT(t.data,i.alg)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"jwt",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="cidr"?hT(t.data,i.version)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"cidr",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64"?cT.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"base64",code:T.invalid_string,message:i.message}),o.dirty()):i.kind==="base64url"?uT.test(t.data)||(n=this._getOrReturnCtx(t,n),C(n,{validation:"base64url",code:T.invalid_string,message:i.message}),o.dirty()):ce.assertNever(i);return{status:o.value,value:t.data}}_regex(t,r,o){return this.refinement(n=>t.test(n),{validation:r,code:T.invalid_string,...q.errToObj(o)})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...q.errToObj(t)})}url(t){return this._addCheck({kind:"url",...q.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...q.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...q.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...q.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...q.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...q.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...q.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...q.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...q.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...q.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...q.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...q.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof t?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...q.errToObj(t?.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof t?.precision>"u"?null:t?.precision,...q.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...q.errToObj(t)})}regex(t,r){return this._addCheck({kind:"regex",regex:t,...q.errToObj(r)})}includes(t,r){return this._addCheck({kind:"includes",value:t,position:r?.position,...q.errToObj(r?.message)})}startsWith(t,r){return this._addCheck({kind:"startsWith",value:t,...q.errToObj(r)})}endsWith(t,r){return this._addCheck({kind:"endsWith",value:t,...q.errToObj(r)})}min(t,r){return this._addCheck({kind:"min",value:t,...q.errToObj(r)})}max(t,r){return this._addCheck({kind:"max",value:t,...q.errToObj(r)})}length(t,r){return this._addCheck({kind:"length",value:t,...q.errToObj(r)})}nonempty(t){return this.min(1,q.errToObj(t))}trim(){return new e({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new e({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxLength(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}};Jn.create=e=>new Jn({checks:[],typeName:z.ZodString,coerce:e?.coerce??!1,...J(e)});function gT(e,t){let r=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,n=r>o?r:o,i=Number.parseInt(e.toFixed(n).replace(".","")),s=Number.parseInt(t.toFixed(n).replace(".",""));return i%s/10**n}var mi=class e extends ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==A.number){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:A.number,received:i.parsedType}),F}let o,n=new Qe;for(let i of this._def.checks)i.kind==="int"?ce.isInteger(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.invalid_type,expected:"integer",received:"float",message:i.message}),n.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),n.dirty()):i.kind==="multipleOf"?gT(t.data,i.value)!==0&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_finite,message:i.message}),n.dirty()):ce.assertNever(i);return{status:n.value,value:t.data}}gte(t,r){return this.setLimit("min",t,!0,q.toString(r))}gt(t,r){return this.setLimit("min",t,!1,q.toString(r))}lte(t,r){return this.setLimit("max",t,!0,q.toString(r))}lt(t,r){return this.setLimit("max",t,!1,q.toString(r))}setLimit(t,r,o,n){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:o,message:q.toString(n)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:q.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:q.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(r)})}finite(t){return this._addCheck({kind:"finite",message:q.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:q.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:q.toString(t)})}get minValue(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&ce.isInteger(t.value))}get isFinite(){let t=null,r=null;for(let o of this._def.checks){if(o.kind==="finite"||o.kind==="int"||o.kind==="multipleOf")return!0;o.kind==="min"?(r===null||o.value>r)&&(r=o.value):o.kind==="max"&&(t===null||o.value<t)&&(t=o.value)}return Number.isFinite(r)&&Number.isFinite(t)}};mi.create=e=>new mi({checks:[],typeName:z.ZodNumber,coerce:e?.coerce||!1,...J(e)});var hi=class e extends ee{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==A.bigint)return this._getInvalidInput(t);let o,n=new Qe;for(let i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),n.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(o=this._getOrReturnCtx(t,o),C(o,{code:T.not_multiple_of,multipleOf:i.value,message:i.message}),n.dirty()):ce.assertNever(i);return{status:n.value,value:t.data}}_getInvalidInput(t){let r=this._getOrReturnCtx(t);return C(r,{code:T.invalid_type,expected:A.bigint,received:r.parsedType}),F}gte(t,r){return this.setLimit("min",t,!0,q.toString(r))}gt(t,r){return this.setLimit("min",t,!1,q.toString(r))}lte(t,r){return this.setLimit("max",t,!0,q.toString(r))}lt(t,r){return this.setLimit("max",t,!1,q.toString(r))}setLimit(t,r,o,n){return new e({...this._def,checks:[...this._def.checks,{kind:t,value:r,inclusive:o,message:q.toString(n)}]})}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:q.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:q.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:q.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:q.toString(t)})}multipleOf(t,r){return this._addCheck({kind:"multipleOf",value:t,message:q.toString(r)})}get minValue(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t}get maxValue(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t}};hi.create=e=>new hi({checks:[],typeName:z.ZodBigInt,coerce:e?.coerce??!1,...J(e)});var gi=class extends ee{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==A.boolean){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.boolean,received:o.parsedType}),F}return ut(t.data)}};gi.create=e=>new gi({typeName:z.ZodBoolean,coerce:e?.coerce||!1,...J(e)});var vi=class e extends ee{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==A.date){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_type,expected:A.date,received:i.parsedType}),F}if(Number.isNaN(t.data.getTime())){let i=this._getOrReturnCtx(t);return C(i,{code:T.invalid_date}),F}let o=new Qe,n;for(let i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(n=this._getOrReturnCtx(t,n),C(n,{code:T.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),o.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(n=this._getOrReturnCtx(t,n),C(n,{code:T.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),o.dirty()):ce.assertNever(i);return{status:o.value,value:new Date(t.data.getTime())}}_addCheck(t){return new e({...this._def,checks:[...this._def.checks,t]})}min(t,r){return this._addCheck({kind:"min",value:t.getTime(),message:q.toString(r)})}max(t,r){return this._addCheck({kind:"max",value:t.getTime(),message:q.toString(r)})}get minDate(){let t=null;for(let r of this._def.checks)r.kind==="min"&&(t===null||r.value>t)&&(t=r.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(let r of this._def.checks)r.kind==="max"&&(t===null||r.value<t)&&(t=r.value);return t!=null?new Date(t):null}};vi.create=e=>new vi({checks:[],coerce:e?.coerce||!1,typeName:z.ZodDate,...J(e)});var _i=class extends ee{_parse(t){if(this._getType(t)!==A.symbol){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.symbol,received:o.parsedType}),F}return ut(t.data)}};_i.create=e=>new _i({typeName:z.ZodSymbol,...J(e)});var Bn=class extends ee{_parse(t){if(this._getType(t)!==A.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.undefined,received:o.parsedType}),F}return ut(t.data)}};Bn.create=e=>new Bn({typeName:z.ZodUndefined,...J(e)});var Yn=class extends ee{_parse(t){if(this._getType(t)!==A.null){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.null,received:o.parsedType}),F}return ut(t.data)}};Yn.create=e=>new Yn({typeName:z.ZodNull,...J(e)});var yi=class extends ee{constructor(){super(...arguments),this._any=!0}_parse(t){return ut(t.data)}};yi.create=e=>new yi({typeName:z.ZodAny,...J(e)});var Ar=class extends ee{constructor(){super(...arguments),this._unknown=!0}_parse(t){return ut(t.data)}};Ar.create=e=>new Ar({typeName:z.ZodUnknown,...J(e)});var sr=class extends ee{_parse(t){let r=this._getOrReturnCtx(t);return C(r,{code:T.invalid_type,expected:A.never,received:r.parsedType}),F}};sr.create=e=>new sr({typeName:z.ZodNever,...J(e)});var bi=class extends ee{_parse(t){if(this._getType(t)!==A.undefined){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.void,received:o.parsedType}),F}return ut(t.data)}};bi.create=e=>new bi({typeName:z.ZodVoid,...J(e)});var Dr=class e extends ee{_parse(t){let{ctx:r,status:o}=this._processInputParams(t),n=this._def;if(r.parsedType!==A.array)return C(r,{code:T.invalid_type,expected:A.array,received:r.parsedType}),F;if(n.exactLength!==null){let s=r.data.length>n.exactLength.value,a=r.data.length<n.exactLength.value;(s||a)&&(C(r,{code:s?T.too_big:T.too_small,minimum:a?n.exactLength.value:void 0,maximum:s?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),o.dirty())}if(n.minLength!==null&&r.data.length<n.minLength.value&&(C(r,{code:T.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),o.dirty()),n.maxLength!==null&&r.data.length>n.maxLength.value&&(C(r,{code:T.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),o.dirty()),r.common.async)return Promise.all([...r.data].map((s,a)=>n.type._parseAsync(new Ot(r,s,r.path,a)))).then(s=>Qe.mergeArray(o,s));let i=[...r.data].map((s,a)=>n.type._parseSync(new Ot(r,s,r.path,a)));return Qe.mergeArray(o,i)}get element(){return this._def.type}min(t,r){return new e({...this._def,minLength:{value:t,message:q.toString(r)}})}max(t,r){return new e({...this._def,maxLength:{value:t,message:q.toString(r)}})}length(t,r){return new e({...this._def,exactLength:{value:t,message:q.toString(r)}})}nonempty(t){return this.min(1,t)}};Dr.create=(e,t)=>new Dr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:z.ZodArray,...J(t)});function Hn(e){if(e instanceof zt){let t={};for(let r in e.shape){let o=e.shape[r];t[r]=Pt.create(Hn(o))}return new zt({...e._def,shape:()=>t})}else return e instanceof Dr?new Dr({...e._def,type:Hn(e.element)}):e instanceof Pt?Pt.create(Hn(e.unwrap())):e instanceof br?br.create(Hn(e.unwrap())):e instanceof yr?yr.create(e.items.map(t=>Hn(t))):e}var zt=class e extends ee{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let t=this._def.shape(),r=ce.objectKeys(t);return this._cached={shape:t,keys:r},this._cached}_parse(t){if(this._getType(t)!==A.object){let u=this._getOrReturnCtx(t);return C(u,{code:T.invalid_type,expected:A.object,received:u.parsedType}),F}let{status:o,ctx:n}=this._processInputParams(t),{shape:i,keys:s}=this._getCached(),a=[];if(!(this._def.catchall instanceof sr&&this._def.unknownKeys==="strip"))for(let u in n.data)s.includes(u)||a.push(u);let c=[];for(let u of s){let l=i[u],d=n.data[u];c.push({key:{status:"valid",value:u},value:l._parse(new Ot(n,d,n.path,u)),alwaysSet:u in n.data})}if(this._def.catchall instanceof sr){let u=this._def.unknownKeys;if(u==="passthrough")for(let l of a)c.push({key:{status:"valid",value:l},value:{status:"valid",value:n.data[l]}});else if(u==="strict")a.length>0&&(C(n,{code:T.unrecognized_keys,keys:a}),o.dirty());else if(u!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{let u=this._def.catchall;for(let l of a){let d=n.data[l];c.push({key:{status:"valid",value:l},value:u._parse(new Ot(n,d,n.path,l)),alwaysSet:l in n.data})}}return n.common.async?Promise.resolve().then(async()=>{let u=[];for(let l of c){let d=await l.key,h=await l.value;u.push({key:d,value:h,alwaysSet:l.alwaysSet})}return u}).then(u=>Qe.mergeObjectSync(o,u)):Qe.mergeObjectSync(o,c)}get shape(){return this._def.shape()}strict(t){return q.errToObj,new e({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(r,o)=>{let n=this._def.errorMap?.(r,o).message??o.defaultError;return r.code==="unrecognized_keys"?{message:q.errToObj(t).message??n}:{message:n}}}:{}})}strip(){return new e({...this._def,unknownKeys:"strip"})}passthrough(){return new e({...this._def,unknownKeys:"passthrough"})}extend(t){return new e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:z.ZodObject})}setKey(t,r){return this.augment({[t]:r})}catchall(t){return new e({...this._def,catchall:t})}pick(t){let r={};for(let o of ce.objectKeys(t))t[o]&&this.shape[o]&&(r[o]=this.shape[o]);return new e({...this._def,shape:()=>r})}omit(t){let r={};for(let o of ce.objectKeys(this.shape))t[o]||(r[o]=this.shape[o]);return new e({...this._def,shape:()=>r})}deepPartial(){return Hn(this)}partial(t){let r={};for(let o of ce.objectKeys(this.shape)){let n=this.shape[o];t&&!t[o]?r[o]=n:r[o]=n.optional()}return new e({...this._def,shape:()=>r})}required(t){let r={};for(let o of ce.objectKeys(this.shape))if(t&&!t[o])r[o]=this.shape[o];else{let i=this.shape[o];for(;i instanceof Pt;)i=i._def.innerType;r[o]=i}return new e({...this._def,shape:()=>r})}keyof(){return g_(ce.objectKeys(this.shape))}};zt.create=(e,t)=>new zt({shape:()=>e,unknownKeys:"strip",catchall:sr.create(),typeName:z.ZodObject,...J(t)});zt.strictCreate=(e,t)=>new zt({shape:()=>e,unknownKeys:"strict",catchall:sr.create(),typeName:z.ZodObject,...J(t)});zt.lazycreate=(e,t)=>new zt({shape:e,unknownKeys:"strip",catchall:sr.create(),typeName:z.ZodObject,...J(t)});var Xn=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=this._def.options;function n(i){for(let a of i)if(a.result.status==="valid")return a.result;for(let a of i)if(a.result.status==="dirty")return r.common.issues.push(...a.ctx.common.issues),a.result;let s=i.map(a=>new Tt(a.ctx.common.issues));return C(r,{code:T.invalid_union,unionErrors:s}),F}if(r.common.async)return Promise.all(o.map(async i=>{let s={...r,common:{...r.common,issues:[]},parent:null};return{result:await i._parseAsync({data:r.data,path:r.path,parent:s}),ctx:s}})).then(n);{let i,s=[];for(let c of o){let u={...r,common:{...r.common,issues:[]},parent:null},l=c._parseSync({data:r.data,path:r.path,parent:u});if(l.status==="valid")return l;l.status==="dirty"&&!i&&(i={result:l,ctx:u}),u.common.issues.length&&s.push(u.common.issues)}if(i)return r.common.issues.push(...i.ctx.common.issues),i.result;let a=s.map(c=>new Tt(c));return C(r,{code:T.invalid_union,unionErrors:a}),F}}get options(){return this._def.options}};Xn.create=(e,t)=>new Xn({options:e,typeName:z.ZodUnion,...J(t)});var _r=e=>e instanceof eo?_r(e.schema):e instanceof Gt?_r(e.innerType()):e instanceof to?[e.value]:e instanceof ro?e.options:e instanceof no?ce.objectValues(e.enum):e instanceof oo?_r(e._def.innerType):e instanceof Bn?[void 0]:e instanceof Yn?[null]:e instanceof Pt?[void 0,..._r(e.unwrap())]:e instanceof br?[null,..._r(e.unwrap())]:e instanceof Ga||e instanceof so?_r(e.unwrap()):e instanceof io?_r(e._def.innerType):[],Kd=class e extends ee{_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.object)return C(r,{code:T.invalid_type,expected:A.object,received:r.parsedType}),F;let o=this.discriminator,n=r.data[o],i=this.optionsMap.get(n);return i?r.common.async?i._parseAsync({data:r.data,path:r.path,parent:r}):i._parseSync({data:r.data,path:r.path,parent:r}):(C(r,{code:T.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[o]}),F)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,r,o){let n=new Map;for(let i of r){let s=_r(i.shape[t]);if(!s.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(let a of s){if(n.has(a))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(a)}`);n.set(a,i)}}return new e({typeName:z.ZodDiscriminatedUnion,discriminator:t,options:r,optionsMap:n,...J(o)})}};function Hd(e,t){let r=vr(e),o=vr(t);if(e===t)return{valid:!0,data:e};if(r===A.object&&o===A.object){let n=ce.objectKeys(t),i=ce.objectKeys(e).filter(a=>n.indexOf(a)!==-1),s={...e,...t};for(let a of i){let c=Hd(e[a],t[a]);if(!c.valid)return{valid:!1};s[a]=c.data}return{valid:!0,data:s}}else if(r===A.array&&o===A.array){if(e.length!==t.length)return{valid:!1};let n=[];for(let i=0;i<e.length;i++){let s=e[i],a=t[i],c=Hd(s,a);if(!c.valid)return{valid:!1};n.push(c.data)}return{valid:!0,data:n}}else return r===A.date&&o===A.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}var Qn=class extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t),n=(i,s)=>{if(Fd(i)||Fd(s))return F;let a=Hd(i.value,s.value);return a.valid?((Gd(i)||Gd(s))&&r.dirty(),{status:r.value,value:a.data}):(C(o,{code:T.invalid_intersection_types}),F)};return o.common.async?Promise.all([this._def.left._parseAsync({data:o.data,path:o.path,parent:o}),this._def.right._parseAsync({data:o.data,path:o.path,parent:o})]).then(([i,s])=>n(i,s)):n(this._def.left._parseSync({data:o.data,path:o.path,parent:o}),this._def.right._parseSync({data:o.data,path:o.path,parent:o}))}};Qn.create=(e,t,r)=>new Qn({left:e,right:t,typeName:z.ZodIntersection,...J(r)});var yr=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.array)return C(o,{code:T.invalid_type,expected:A.array,received:o.parsedType}),F;if(o.data.length<this._def.items.length)return C(o,{code:T.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),F;!this._def.rest&&o.data.length>this._def.items.length&&(C(o,{code:T.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());let i=[...o.data].map((s,a)=>{let c=this._def.items[a]||this._def.rest;return c?c._parse(new Ot(o,s,o.path,a)):null}).filter(s=>!!s);return o.common.async?Promise.all(i).then(s=>Qe.mergeArray(r,s)):Qe.mergeArray(r,i)}get items(){return this._def.items}rest(t){return new e({...this._def,rest:t})}};yr.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new yr({items:e,typeName:z.ZodTuple,rest:null,...J(t)})};var Jd=class e extends ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.object)return C(o,{code:T.invalid_type,expected:A.object,received:o.parsedType}),F;let n=[],i=this._def.keyType,s=this._def.valueType;for(let a in o.data)n.push({key:i._parse(new Ot(o,a,o.path,a)),value:s._parse(new Ot(o,o.data[a],o.path,a)),alwaysSet:a in o.data});return o.common.async?Qe.mergeObjectAsync(r,n):Qe.mergeObjectSync(r,n)}get element(){return this._def.valueType}static create(t,r,o){return r instanceof ee?new e({keyType:t,valueType:r,typeName:z.ZodRecord,...J(o)}):new e({keyType:Jn.create(),valueType:t,typeName:z.ZodRecord,...J(r)})}},$i=class extends ee{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.map)return C(o,{code:T.invalid_type,expected:A.map,received:o.parsedType}),F;let n=this._def.keyType,i=this._def.valueType,s=[...o.data.entries()].map(([a,c],u)=>({key:n._parse(new Ot(o,a,o.path,[u,"key"])),value:i._parse(new Ot(o,c,o.path,[u,"value"]))}));if(o.common.async){let a=new Map;return Promise.resolve().then(async()=>{for(let c of s){let u=await c.key,l=await c.value;if(u.status==="aborted"||l.status==="aborted")return F;(u.status==="dirty"||l.status==="dirty")&&r.dirty(),a.set(u.value,l.value)}return{status:r.value,value:a}})}else{let a=new Map;for(let c of s){let u=c.key,l=c.value;if(u.status==="aborted"||l.status==="aborted")return F;(u.status==="dirty"||l.status==="dirty")&&r.dirty(),a.set(u.value,l.value)}return{status:r.value,value:a}}}};$i.create=(e,t,r)=>new $i({valueType:t,keyType:e,typeName:z.ZodMap,...J(r)});var wi=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.parsedType!==A.set)return C(o,{code:T.invalid_type,expected:A.set,received:o.parsedType}),F;let n=this._def;n.minSize!==null&&o.data.size<n.minSize.value&&(C(o,{code:T.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),r.dirty()),n.maxSize!==null&&o.data.size>n.maxSize.value&&(C(o,{code:T.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),r.dirty());let i=this._def.valueType;function s(c){let u=new Set;for(let l of c){if(l.status==="aborted")return F;l.status==="dirty"&&r.dirty(),u.add(l.value)}return{status:r.value,value:u}}let a=[...o.data.values()].map((c,u)=>i._parse(new Ot(o,c,o.path,u)));return o.common.async?Promise.all(a).then(c=>s(c)):s(a)}min(t,r){return new e({...this._def,minSize:{value:t,message:q.toString(r)}})}max(t,r){return new e({...this._def,maxSize:{value:t,message:q.toString(r)}})}size(t,r){return this.min(t,r).max(t,r)}nonempty(t){return this.min(1,t)}};wi.create=(e,t)=>new wi({valueType:e,minSize:null,maxSize:null,typeName:z.ZodSet,...J(t)});var Bd=class e extends ee{constructor(){super(...arguments),this.validate=this.implement}_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.function)return C(r,{code:T.invalid_type,expected:A.function,received:r.parsedType}),F;function o(a,c){return Fa({data:a,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,pi(),Cr].filter(u=>!!u),issueData:{code:T.invalid_arguments,argumentsError:c}})}function n(a,c){return Fa({data:a,path:r.path,errorMaps:[r.common.contextualErrorMap,r.schemaErrorMap,pi(),Cr].filter(u=>!!u),issueData:{code:T.invalid_return_type,returnTypeError:c}})}let i={errorMap:r.common.contextualErrorMap},s=r.data;if(this._def.returns instanceof gn){let a=this;return ut(async function(...c){let u=new Tt([]),l=await a._def.args.parseAsync(c,i).catch(m=>{throw u.addIssue(o(c,m)),u}),d=await Reflect.apply(s,this,l);return await a._def.returns._def.type.parseAsync(d,i).catch(m=>{throw u.addIssue(n(d,m)),u})})}else{let a=this;return ut(function(...c){let u=a._def.args.safeParse(c,i);if(!u.success)throw new Tt([o(c,u.error)]);let l=Reflect.apply(s,this,u.data),d=a._def.returns.safeParse(l,i);if(!d.success)throw new Tt([n(l,d.error)]);return d.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...t){return new e({...this._def,args:yr.create(t).rest(Ar.create())})}returns(t){return new e({...this._def,returns:t})}implement(t){return this.parse(t)}strictImplement(t){return this.parse(t)}static create(t,r,o){return new e({args:t||yr.create([]).rest(Ar.create()),returns:r||Ar.create(),typeName:z.ZodFunction,...J(o)})}},eo=class extends ee{get schema(){return this._def.getter()}_parse(t){let{ctx:r}=this._processInputParams(t);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}};eo.create=(e,t)=>new eo({getter:e,typeName:z.ZodLazy,...J(t)});var to=class extends ee{_parse(t){if(t.data!==this._def.value){let r=this._getOrReturnCtx(t);return C(r,{received:r.data,code:T.invalid_literal,expected:this._def.value}),F}return{status:"valid",value:t.data}}get value(){return this._def.value}};to.create=(e,t)=>new to({value:e,typeName:z.ZodLiteral,...J(t)});function g_(e,t){return new ro({values:e,typeName:z.ZodEnum,...J(t)})}var ro=class e extends ee{_parse(t){if(typeof t.data!="string"){let r=this._getOrReturnCtx(t),o=this._def.values;return C(r,{expected:ce.joinValues(o),received:r.parsedType,code:T.invalid_type}),F}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){let r=this._getOrReturnCtx(t),o=this._def.values;return C(r,{received:r.data,code:T.invalid_enum_value,options:o}),F}return ut(t.data)}get options(){return this._def.values}get enum(){let t={};for(let r of this._def.values)t[r]=r;return t}get Values(){let t={};for(let r of this._def.values)t[r]=r;return t}get Enum(){let t={};for(let r of this._def.values)t[r]=r;return t}extract(t,r=this._def){return e.create(t,{...this._def,...r})}exclude(t,r=this._def){return e.create(this.options.filter(o=>!t.includes(o)),{...this._def,...r})}};ro.create=g_;var no=class extends ee{_parse(t){let r=ce.getValidEnumValues(this._def.values),o=this._getOrReturnCtx(t);if(o.parsedType!==A.string&&o.parsedType!==A.number){let n=ce.objectValues(r);return C(o,{expected:ce.joinValues(n),received:o.parsedType,code:T.invalid_type}),F}if(this._cache||(this._cache=new Set(ce.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){let n=ce.objectValues(r);return C(o,{received:o.data,code:T.invalid_enum_value,options:n}),F}return ut(t.data)}get enum(){return this._def.values}};no.create=(e,t)=>new no({values:e,typeName:z.ZodNativeEnum,...J(t)});var gn=class extends ee{unwrap(){return this._def.type}_parse(t){let{ctx:r}=this._processInputParams(t);if(r.parsedType!==A.promise&&r.common.async===!1)return C(r,{code:T.invalid_type,expected:A.promise,received:r.parsedType}),F;let o=r.parsedType===A.promise?r.data:Promise.resolve(r.data);return ut(o.then(n=>this._def.type.parseAsync(n,{path:r.path,errorMap:r.common.contextualErrorMap})))}};gn.create=(e,t)=>new gn({type:e,typeName:z.ZodPromise,...J(t)});var Gt=class extends ee{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===z.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){let{status:r,ctx:o}=this._processInputParams(t),n=this._def.effect||null,i={addIssue:s=>{C(o,s),s.fatal?r.abort():r.dirty()},get path(){return o.path}};if(i.addIssue=i.addIssue.bind(i),n.type==="preprocess"){let s=n.transform(o.data,i);if(o.common.async)return Promise.resolve(s).then(async a=>{if(r.value==="aborted")return F;let c=await this._def.schema._parseAsync({data:a,path:o.path,parent:o});return c.status==="aborted"?F:c.status==="dirty"?Kn(c.value):r.value==="dirty"?Kn(c.value):c});{if(r.value==="aborted")return F;let a=this._def.schema._parseSync({data:s,path:o.path,parent:o});return a.status==="aborted"?F:a.status==="dirty"?Kn(a.value):r.value==="dirty"?Kn(a.value):a}}if(n.type==="refinement"){let s=a=>{let c=n.refinement(a,i);if(o.common.async)return Promise.resolve(c);if(c instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return a};if(o.common.async===!1){let a=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});return a.status==="aborted"?F:(a.status==="dirty"&&r.dirty(),s(a.value),{status:r.value,value:a.value})}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(a=>a.status==="aborted"?F:(a.status==="dirty"&&r.dirty(),s(a.value).then(()=>({status:r.value,value:a.value}))))}if(n.type==="transform")if(o.common.async===!1){let s=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});if(!hn(s))return F;let a=n.transform(s.value,i);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:a}}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(s=>hn(s)?Promise.resolve(n.transform(s.value,i)).then(a=>({status:r.value,value:a})):F);ce.assertNever(n)}};Gt.create=(e,t,r)=>new Gt({schema:e,typeName:z.ZodEffects,effect:t,...J(r)});Gt.createWithPreprocess=(e,t,r)=>new Gt({schema:t,effect:{type:"preprocess",transform:e},typeName:z.ZodEffects,...J(r)});var Pt=class extends ee{_parse(t){return this._getType(t)===A.undefined?ut(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};Pt.create=(e,t)=>new Pt({innerType:e,typeName:z.ZodOptional,...J(t)});var br=class extends ee{_parse(t){return this._getType(t)===A.null?ut(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}};br.create=(e,t)=>new br({innerType:e,typeName:z.ZodNullable,...J(t)});var oo=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=r.data;return r.parsedType===A.undefined&&(o=this._def.defaultValue()),this._def.innerType._parse({data:o,path:r.path,parent:r})}removeDefault(){return this._def.innerType}};oo.create=(e,t)=>new oo({innerType:e,typeName:z.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...J(t)});var io=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o={...r,common:{...r.common,issues:[]}},n=this._def.innerType._parse({data:o.data,path:o.path,parent:{...o}});return fi(n)?n.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new Tt(o.common.issues)},input:o.data})})):{status:"valid",value:n.status==="valid"?n.value:this._def.catchValue({get error(){return new Tt(o.common.issues)},input:o.data})}}removeCatch(){return this._def.innerType}};io.create=(e,t)=>new io({innerType:e,typeName:z.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...J(t)});var ki=class extends ee{_parse(t){if(this._getType(t)!==A.nan){let o=this._getOrReturnCtx(t);return C(o,{code:T.invalid_type,expected:A.nan,received:o.parsedType}),F}return{status:"valid",value:t.data}}};ki.create=e=>new ki({typeName:z.ZodNaN,...J(e)});var Z2=Symbol("zod_brand"),Ga=class extends ee{_parse(t){let{ctx:r}=this._processInputParams(t),o=r.data;return this._def.type._parse({data:o,path:r.path,parent:r})}unwrap(){return this._def.type}},Wa=class e extends ee{_parse(t){let{status:r,ctx:o}=this._processInputParams(t);if(o.common.async)return(async()=>{let i=await this._def.in._parseAsync({data:o.data,path:o.path,parent:o});return i.status==="aborted"?F:i.status==="dirty"?(r.dirty(),Kn(i.value)):this._def.out._parseAsync({data:i.value,path:o.path,parent:o})})();{let n=this._def.in._parseSync({data:o.data,path:o.path,parent:o});return n.status==="aborted"?F:n.status==="dirty"?(r.dirty(),{status:"dirty",value:n.value}):this._def.out._parseSync({data:n.value,path:o.path,parent:o})}}static create(t,r){return new e({in:t,out:r,typeName:z.ZodPipeline})}},so=class extends ee{_parse(t){let r=this._def.innerType._parse(t),o=n=>(hn(n)&&(n.value=Object.freeze(n.value)),n);return fi(r)?r.then(n=>o(n)):o(r)}unwrap(){return this._def.innerType}};so.create=(e,t)=>new so({innerType:e,typeName:z.ZodReadonly,...J(t)});var V2={object:zt.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 L2=Jn.create,F2=mi.create,G2=ki.create,W2=hi.create,K2=gi.create,H2=vi.create,J2=_i.create,B2=Bn.create,Y2=Yn.create,X2=yi.create,Q2=Ar.create,e6=sr.create,t6=bi.create,r6=Dr.create,v_=zt.create,n6=zt.strictCreate,o6=Xn.create,i6=Kd.create,s6=Qn.create,a6=yr.create,c6=Jd.create,u6=$i.create,l6=wi.create,d6=Bd.create,p6=eo.create,f6=to.create,m6=ro.create,h6=no.create,g6=gn.create,v6=Gt.create,_6=Pt.create,y6=br.create,b6=Gt.createWithPreprocess,$6=Wa.create;var Kt={};mn(Kt,{$ZodAny:()=>jc,$ZodArray:()=>ho,$ZodAsyncError:()=>ar,$ZodBase64:()=>wc,$ZodBase64URL:()=>kc,$ZodBigInt:()=>Ci,$ZodBigIntFormat:()=>zc,$ZodBoolean:()=>mo,$ZodCIDRv4:()=>bc,$ZodCIDRv6:()=>$c,$ZodCUID:()=>fc,$ZodCUID2:()=>mc,$ZodCatch:()=>Bc,$ZodCheck:()=>De,$ZodCheckBigIntFormat:()=>Mp,$ZodCheckEndsWith:()=>Yp,$ZodCheckGreaterThan:()=>oc,$ZodCheckIncludes:()=>Jp,$ZodCheckLengthEquals:()=>Gp,$ZodCheckLessThan:()=>nc,$ZodCheckLowerCase:()=>Kp,$ZodCheckMaxLength:()=>Lp,$ZodCheckMaxSize:()=>Up,$ZodCheckMimeType:()=>Qp,$ZodCheckMinLength:()=>Fp,$ZodCheckMinSize:()=>Zp,$ZodCheckMultipleOf:()=>Dp,$ZodCheckNumberFormat:()=>qp,$ZodCheckOverwrite:()=>ef,$ZodCheckProperty:()=>Xp,$ZodCheckRegex:()=>Wp,$ZodCheckSizeEquals:()=>Vp,$ZodCheckStartsWith:()=>Bp,$ZodCheckStringFormat:()=>fo,$ZodCheckUpperCase:()=>Hp,$ZodCustom:()=>ru,$ZodCustomStringFormat:()=>Tc,$ZodDate:()=>Cc,$ZodDefault:()=>Wc,$ZodDiscriminatedUnion:()=>Ac,$ZodE164:()=>xc,$ZodEmail:()=>uc,$ZodEmoji:()=>dc,$ZodEnum:()=>Zc,$ZodError:()=>ji,$ZodFile:()=>Lc,$ZodFunction:()=>Ou,$ZodGUID:()=>ac,$ZodIPv4:()=>_c,$ZodIPv6:()=>yc,$ZodISODate:()=>of,$ZodISODateTime:()=>nf,$ZodISODuration:()=>af,$ZodISOTime:()=>sf,$ZodIntersection:()=>Dc,$ZodJWT:()=>Sc,$ZodKSUID:()=>vc,$ZodLazy:()=>tu,$ZodLiteral:()=>Vc,$ZodMap:()=>Mc,$ZodNaN:()=>Yc,$ZodNanoID:()=>pc,$ZodNever:()=>Nc,$ZodNonOptional:()=>Hc,$ZodNull:()=>Oc,$ZodNullable:()=>Gc,$ZodNumber:()=>Ri,$ZodNumberFormat:()=>Pc,$ZodObject:()=>Ai,$ZodOptional:()=>Fc,$ZodPipe:()=>vo,$ZodPrefault:()=>Kc,$ZodPromise:()=>eu,$ZodReadonly:()=>Xc,$ZodRealError:()=>uo,$ZodRecord:()=>qc,$ZodRegistry:()=>yo,$ZodSet:()=>Uc,$ZodString:()=>Vr,$ZodStringFormat:()=>ke,$ZodSuccess:()=>Jc,$ZodSymbol:()=>Ec,$ZodTemplateLiteral:()=>Qc,$ZodTransform:()=>go,$ZodTuple:()=>Lr,$ZodType:()=>W,$ZodULID:()=>hc,$ZodURL:()=>lc,$ZodUUID:()=>cc,$ZodUndefined:()=>Ic,$ZodUnion:()=>Di,$ZodUnknown:()=>wn,$ZodVoid:()=>Rc,$ZodXID:()=>gc,$brand:()=>Ha,$constructor:()=>_,$input:()=>iu,$output:()=>ou,Doc:()=>Ni,JSONSchema:()=>Ty,JSONSchemaGenerator:()=>ys,NEVER:()=>Ka,TimePrecision:()=>au,_any:()=>$u,_array:()=>_s,_base64:()=>rs,_base64url:()=>ns,_bigint:()=>hu,_boolean:()=>mu,_catch:()=>HP,_cidrv4:()=>es,_cidrv6:()=>ts,_coercedBigint:()=>gf,_coercedBoolean:()=>hf,_coercedDate:()=>vf,_coercedNumber:()=>mf,_coercedString:()=>uf,_cuid:()=>Ki,_cuid2:()=>Hi,_custom:()=>Pu,_date:()=>xu,_default:()=>GP,_discriminatedUnion:()=>RP,_e164:()=>os,_email:()=>Mi,_emoji:()=>Gi,_endsWith:()=>ps,_enum:()=>MP,_file:()=>Tu,_float32:()=>lu,_float64:()=>du,_gt:()=>kr,_gte:()=>vt,_guid:()=>bo,_includes:()=>ls,_int:()=>uu,_int32:()=>pu,_int64:()=>gu,_intersection:()=>CP,_ipv4:()=>Xi,_ipv6:()=>Qi,_isoDate:()=>df,_isoDateTime:()=>lf,_isoDuration:()=>ff,_isoTime:()=>pf,_jwt:()=>is,_ksuid:()=>Yi,_lazy:()=>XP,_length:()=>ko,_literal:()=>ZP,_lowercase:()=>cs,_lt:()=>wr,_lte:()=>jt,_map:()=>DP,_max:()=>jt,_maxLength:()=>wo,_maxSize:()=>$o,_mime:()=>fs,_min:()=>vt,_minLength:()=>Fr,_minSize:()=>Sn,_multipleOf:()=>xn,_nan:()=>Su,_nanoid:()=>Wi,_nativeEnum:()=>UP,_negative:()=>yf,_never:()=>wu,_nonnegative:()=>$f,_nonoptional:()=>WP,_nonpositive:()=>bf,_normalize:()=>ms,_null:()=>bu,_nullable:()=>FP,_number:()=>cu,_optional:()=>LP,_overwrite:()=>xr,_parse:()=>Xa,_parseAsync:()=>Qa,_pipe:()=>JP,_positive:()=>_f,_promise:()=>QP,_property:()=>wf,_readonly:()=>BP,_record:()=>AP,_refine:()=>zu,_regex:()=>as,_safeParse:()=>ec,_safeParseAsync:()=>tc,_set:()=>qP,_size:()=>ss,_startsWith:()=>ds,_string:()=>su,_stringFormat:()=>Iu,_stringbool:()=>Eu,_success:()=>KP,_symbol:()=>_u,_templateLiteral:()=>YP,_toLowerCase:()=>gs,_toUpperCase:()=>vs,_transform:()=>VP,_trim:()=>hs,_tuple:()=>kf,_uint32:()=>fu,_uint64:()=>vu,_ulid:()=>Ji,_undefined:()=>yu,_union:()=>NP,_unknown:()=>kn,_uppercase:()=>us,_url:()=>Fi,_uuid:()=>Ui,_uuidv4:()=>Zi,_uuidv6:()=>Vi,_uuidv7:()=>Li,_void:()=>ku,_xid:()=>Bi,clone:()=>et,config:()=>Ue,flattenError:()=>lo,formatError:()=>po,function:()=>ju,globalConfig:()=>xi,globalRegistry:()=>Wt,isValidBase64:()=>cf,isValidBase64URL:()=>D_,isValidJWT:()=>q_,locales:()=>_o,parse:()=>yn,parseAsync:()=>bn,prettifyError:()=>Ya,regexes:()=>Zr,registry:()=>qi,safeParse:()=>Mr,safeParseAsync:()=>Ur,toDotPath:()=>y_,toJSONSchema:()=>xo,treeifyError:()=>Ba,util:()=>N,version:()=>tf});var Ka=Object.freeze({status:"aborted"});function _(e,t,r){function o(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)l in a||Object.defineProperty(a,l,{value:s.prototype[l].bind(a)});a._zod.constr=s,a._zod.def=c}let n=r?.Parent??Object;class i extends n{}Object.defineProperty(i,"name",{value:e});function s(a){var c;let u=r?.Parent?new i:this;o(u,a),(c=u._zod).deferred??(c.deferred=[]);for(let l of u._zod.deferred)l();return u}return Object.defineProperty(s,"init",{value:o}),Object.defineProperty(s,Symbol.hasInstance,{value:a=>r?.Parent&&a instanceof r.Parent?!0:a?._zod?.traits?.has(e)}),Object.defineProperty(s,"name",{value:e}),s}var Ha=Symbol("zod_brand"),ar=class extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},xi={};function Ue(e){return e&&Object.assign(xi,e),xi}var N={};mn(N,{BIGINT_FORMAT_RANGES:()=>sp,Class:()=>Xd,NUMBER_FORMAT_RANGES:()=>ip,aborted:()=>_n,allowsEval:()=>rp,assert:()=>$T,assertEqual:()=>vT,assertIs:()=>yT,assertNever:()=>bT,assertNotEqual:()=>_T,assignProp:()=>tp,cached:()=>Pi,captureStackTrace:()=>Ja,cleanEnum:()=>RT,cleanRegex:()=>zi,clone:()=>et,createTransparentProxy:()=>PT,defineLazy:()=>_e,esc:()=>vn,escapeRegex:()=>$r,extend:()=>IT,finalizeIssue:()=>Et,floatSafeRemainder:()=>ep,getElementAtPath:()=>wT,getEnumValues:()=>Ti,getLengthableOrigin:()=>Oi,getParsedType:()=>TT,getSizableOrigin:()=>Ii,isObject:()=>ao,isPlainObject:()=>co,issue:()=>ap,joinValues:()=>x,jsonStringifyReplacer:()=>Qd,merge:()=>OT,normalizeParams:()=>O,nullish:()=>qr,numKeys:()=>ST,omit:()=>ET,optionalKeys:()=>op,partial:()=>jT,pick:()=>zT,prefixIssues:()=>gt,primitiveTypes:()=>np,promiseAllObject:()=>kT,propertyKeyTypes:()=>Ei,randomString:()=>xT,required:()=>NT,stringifyPrimitive:()=>R,unwrapMessage:()=>Si});function vT(e){return e}function _T(e){return e}function yT(e){}function bT(e){throw new Error}function $T(e){}function Ti(e){let t=Object.values(e).filter(o=>typeof o=="number");return Object.entries(e).filter(([o,n])=>t.indexOf(+o)===-1).map(([o,n])=>n)}function x(e,t="|"){return e.map(r=>R(r)).join(t)}function Qd(e,t){return typeof t=="bigint"?t.toString():t}function Pi(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}function qr(e){return e==null}function zi(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}function ep(e,t){let r=(e.toString().split(".")[1]||"").length,o=(t.toString().split(".")[1]||"").length,n=r>o?r:o,i=Number.parseInt(e.toFixed(n).replace(".","")),s=Number.parseInt(t.toFixed(n).replace(".",""));return i%s/10**n}function _e(e,t,r){Object.defineProperty(e,t,{get(){{let n=r();return e[t]=n,n}throw new Error("cached value already set")},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function tp(e,t,r){Object.defineProperty(e,t,{value:r,writable:!0,enumerable:!0,configurable:!0})}function wT(e,t){return t?t.reduce((r,o)=>r?.[o],e):e}function kT(e){let t=Object.keys(e),r=t.map(o=>e[o]);return Promise.all(r).then(o=>{let n={};for(let i=0;i<t.length;i++)n[t[i]]=o[i];return n})}function xT(e=10){let t="abcdefghijklmnopqrstuvwxyz",r="";for(let o=0;o<e;o++)r+=t[Math.floor(Math.random()*t.length)];return r}function vn(e){return JSON.stringify(e)}var Ja=Error.captureStackTrace?Error.captureStackTrace:(...e)=>{};function ao(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}var rp=Pi(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function co(e){if(ao(e)===!1)return!1;let t=e.constructor;if(t===void 0)return!0;let r=t.prototype;return!(ao(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}function ST(e){let t=0;for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t++;return t}var TT=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":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},Ei=new Set(["string","number","symbol"]),np=new Set(["string","number","bigint","boolean","symbol","undefined"]);function $r(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function et(e,t,r){let o=new e._zod.constr(t??e._zod.def);return(!t||r?.parent)&&(o._zod.parent=e),o}function O(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 new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function PT(e){let t;return new Proxy({},{get(r,o,n){return t??(t=e()),Reflect.get(t,o,n)},set(r,o,n,i){return t??(t=e()),Reflect.set(t,o,n,i)},has(r,o){return t??(t=e()),Reflect.has(t,o)},deleteProperty(r,o){return t??(t=e()),Reflect.deleteProperty(t,o)},ownKeys(r){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(r,o){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,o)},defineProperty(r,o,n){return t??(t=e()),Reflect.defineProperty(t,o,n)}})}function R(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}function op(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}var ip={safeint:[Number.MIN_SAFE_INTEGER,Number.MAX_SAFE_INTEGER],int32:[-2147483648,2147483647],uint32:[0,4294967295],float32:[-34028234663852886e22,34028234663852886e22],float64:[-Number.MAX_VALUE,Number.MAX_VALUE]},sp={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function zT(e,t){let r={},o=e._zod.def;for(let n in t){if(!(n in o.shape))throw new Error(`Unrecognized key: "${n}"`);t[n]&&(r[n]=o.shape[n])}return et(e,{...e._zod.def,shape:r,checks:[]})}function ET(e,t){let r={...e._zod.def.shape},o=e._zod.def;for(let n in t){if(!(n in o.shape))throw new Error(`Unrecognized key: "${n}"`);t[n]&&delete r[n]}return et(e,{...e._zod.def,shape:r,checks:[]})}function IT(e,t){if(!co(t))throw new Error("Invalid input to extend: expected a plain object");let r={...e._zod.def,get shape(){let o={...e._zod.def.shape,...t};return tp(this,"shape",o),o},checks:[]};return et(e,r)}function OT(e,t){return et(e,{...e._zod.def,get shape(){let r={...e._zod.def.shape,...t._zod.def.shape};return tp(this,"shape",r),r},catchall:t._zod.def.catchall,checks:[]})}function jT(e,t,r){let o=t._zod.def.shape,n={...o};if(r)for(let i in r){if(!(i in o))throw new Error(`Unrecognized key: "${i}"`);r[i]&&(n[i]=e?new e({type:"optional",innerType:o[i]}):o[i])}else for(let i in o)n[i]=e?new e({type:"optional",innerType:o[i]}):o[i];return et(t,{...t._zod.def,shape:n,checks:[]})}function NT(e,t,r){let o=t._zod.def.shape,n={...o};if(r)for(let i in r){if(!(i in n))throw new Error(`Unrecognized key: "${i}"`);r[i]&&(n[i]=new e({type:"nonoptional",innerType:o[i]}))}else for(let i in o)n[i]=new e({type:"nonoptional",innerType:o[i]});return et(t,{...t._zod.def,shape:n,checks:[]})}function _n(e,t=0){for(let r=t;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}function gt(e,t){return t.map(r=>{var o;return(o=r).path??(o.path=[]),r.path.unshift(e),r})}function Si(e){return typeof e=="string"?e:e?.message}function Et(e,t,r){let o={...e,path:e.path??[]};if(!e.message){let n=Si(e.inst?._zod.def?.error?.(e))??Si(t?.error?.(e))??Si(r.customError?.(e))??Si(r.localeError?.(e))??"Invalid input";o.message=n}return delete o.inst,delete o.continue,t?.reportInput||delete o.input,o}function Ii(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function Oi(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function ap(...e){let[t,r,o]=e;return typeof t=="string"?{message:t,code:"custom",input:r,inst:o}:{...t}}function RT(e){return Object.entries(e).filter(([t,r])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}var Xd=class{constructor(...t){}};var __=(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,Qd,2)},enumerable:!0}),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},ji=_("$ZodError",__),uo=_("$ZodError",__,{Parent:Error});function lo(e,t=r=>r.message){let r={},o=[];for(let n of e.issues)n.path.length>0?(r[n.path[0]]=r[n.path[0]]||[],r[n.path[0]].push(t(n))):o.push(t(n));return{formErrors:o,fieldErrors:r}}function po(e,t){let r=t||function(i){return i.message},o={_errors:[]},n=i=>{for(let s of i.issues)if(s.code==="invalid_union"&&s.errors.length)s.errors.map(a=>n({issues:a}));else if(s.code==="invalid_key")n({issues:s.issues});else if(s.code==="invalid_element")n({issues:s.issues});else if(s.path.length===0)o._errors.push(r(s));else{let a=o,c=0;for(;c<s.path.length;){let u=s.path[c];c===s.path.length-1?(a[u]=a[u]||{_errors:[]},a[u]._errors.push(r(s))):a[u]=a[u]||{_errors:[]},a=a[u],c++}}};return n(e),o}function Ba(e,t){let r=t||function(i){return i.message},o={errors:[]},n=(i,s=[])=>{var a,c;for(let u of i.issues)if(u.code==="invalid_union"&&u.errors.length)u.errors.map(l=>n({issues:l},u.path));else if(u.code==="invalid_key")n({issues:u.issues},u.path);else if(u.code==="invalid_element")n({issues:u.issues},u.path);else{let l=[...s,...u.path];if(l.length===0){o.errors.push(r(u));continue}let d=o,h=0;for(;h<l.length;){let m=l[h],p=h===l.length-1;typeof m=="string"?(d.properties??(d.properties={}),(a=d.properties)[m]??(a[m]={errors:[]}),d=d.properties[m]):(d.items??(d.items=[]),(c=d.items)[m]??(c[m]={errors:[]}),d=d.items[m]),p&&d.errors.push(r(u)),h++}}};return n(e),o}function y_(e){let t=[];for(let r of e)typeof r=="number"?t.push(`[${r}]`):typeof r=="symbol"?t.push(`[${JSON.stringify(String(r))}]`):/[^\w$]/.test(r)?t.push(`[${JSON.stringify(r)}]`):(t.length&&t.push("."),t.push(r));return t.join("")}function Ya(e){let t=[],r=[...e.issues].sort((o,n)=>o.path.length-n.path.length);for(let o of r)t.push(`\u2716 ${o.message}`),o.path?.length&&t.push(` \u2192 at ${y_(o.path)}`);return t.join(`
17
+ `)}var Xa=e=>(t,r,o,n)=>{let i=o?Object.assign(o,{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(n?.Err??e)(s.issues.map(c=>Et(c,i,Ue())));throw Ja(a,n?.callee),a}return s.value},yn=Xa(uo),Qa=e=>async(t,r,o,n)=>{let i=o?Object.assign(o,{async:!0}):{async:!0},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise&&(s=await s),s.issues.length){let a=new(n?.Err??e)(s.issues.map(c=>Et(c,i,Ue())));throw Ja(a,n?.callee),a}return s.value},bn=Qa(uo),ec=e=>(t,r,o)=>{let n=o?{...o,async:!1}:{async:!1},i=t._zod.run({value:r,issues:[]},n);if(i instanceof Promise)throw new ar;return i.issues.length?{success:!1,error:new(e??ji)(i.issues.map(s=>Et(s,n,Ue())))}:{success:!0,data:i.value}},Mr=ec(uo),tc=e=>async(t,r,o)=>{let n=o?Object.assign(o,{async:!0}):{async:!0},i=t._zod.run({value:r,issues:[]},n);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(s=>Et(s,n,Ue())))}:{success:!0,data:i.value}},Ur=tc(uo);var Zr={};mn(Zr,{_emoji:()=>b_,base64:()=>wp,base64url:()=>rc,bigint:()=>Ep,boolean:()=>jp,browserEmail:()=>LT,cidrv4:()=>bp,cidrv6:()=>$p,cuid:()=>cp,cuid2:()=>up,date:()=>Sp,datetime:()=>Pp,domain:()=>FT,duration:()=>mp,e164:()=>xp,email:()=>gp,emoji:()=>vp,extendedDuration:()=>AT,guid:()=>hp,hostname:()=>kp,html5Email:()=>UT,integer:()=>Ip,ipv4:()=>_p,ipv6:()=>yp,ksuid:()=>pp,lowercase:()=>Cp,nanoid:()=>fp,null:()=>Np,number:()=>Op,rfc5322Email:()=>ZT,string:()=>zp,time:()=>Tp,ulid:()=>lp,undefined:()=>Rp,unicodeEmail:()=>VT,uppercase:()=>Ap,uuid:()=>$n,uuid4:()=>DT,uuid6:()=>qT,uuid7:()=>MT,xid:()=>dp});var cp=/^[cC][^\s-]{8,}$/,up=/^[0-9a-z]+$/,lp=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,dp=/^[0-9a-vA-V]{20}$/,pp=/^[A-Za-z0-9]{27}$/,fp=/^[a-zA-Z0-9_-]{21}$/,mp=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,AT=/^[-+]?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)?)??$/,hp=/^([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})$/,$n=e=>e?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})$`):/^([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)$/,DT=$n(4),qT=$n(6),MT=$n(7),gp=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,UT=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,ZT=/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,VT=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,LT=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,b_="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function vp(){return new RegExp(b_,"u")}var _p=/^(?:(?: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])$/,yp=/^(([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})$/,bp=/^((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])$/,$p=/^(([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])$/,wp=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,rc=/^[A-Za-z0-9_-]*$/,kp=/^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/,FT=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,xp=/^\+(?:[0-9]){6,14}[0-9]$/,$_="(?:(?:\\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])))",Sp=new RegExp(`^${$_}$`);function w_(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Tp(e){return new RegExp(`^${w_(e)}$`)}function Pp(e){let t=w_({precision:e.precision}),r=["Z"];e.local&&r.push(""),e.offset&&r.push("([+-]\\d{2}:\\d{2})");let o=`${t}(?:${r.join("|")})`;return new RegExp(`^${$_}T(?:${o})$`)}var zp=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},Ep=/^\d+n?$/,Ip=/^\d+$/,Op=/^-?\d+(?:\.\d+)?/i,jp=/true|false/i,Np=/null/i;var Rp=/undefined/i;var Cp=/^[^A-Z]*$/,Ap=/^[^a-z]*$/;var De=_("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),x_={number:"number",bigint:"bigint",object:"date"},nc=_("$ZodCheckLessThan",(e,t)=>{De.init(e,t);let r=x_[typeof t.value];e._zod.onattach.push(o=>{let n=o._zod.bag,i=(t.inclusive?n.maximum:n.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<i&&(t.inclusive?n.maximum=t.value:n.exclusiveMaximum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value<=t.value:o.value<t.value)||o.issues.push({origin:r,code:"too_big",maximum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),oc=_("$ZodCheckGreaterThan",(e,t)=>{De.init(e,t);let r=x_[typeof t.value];e._zod.onattach.push(o=>{let n=o._zod.bag,i=(t.inclusive?n.minimum:n.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?n.minimum=t.value:n.exclusiveMinimum=t.value)}),e._zod.check=o=>{(t.inclusive?o.value>=t.value:o.value>t.value)||o.issues.push({origin:r,code:"too_small",minimum:t.value,input:o.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Dp=_("$ZodCheckMultipleOf",(e,t)=>{De.init(e,t),e._zod.onattach.push(r=>{var o;(o=r._zod.bag).multipleOf??(o.multipleOf=t.value)}),e._zod.check=r=>{if(typeof r.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof r.value=="bigint"?r.value%t.value===BigInt(0):ep(r.value,t.value)===0)||r.issues.push({origin:typeof r.value,code:"not_multiple_of",divisor:t.value,input:r.value,inst:e,continue:!t.abort})}}),qp=_("$ZodCheckNumberFormat",(e,t)=>{De.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),o=r?"int":"number",[n,i]=ip[t.format];e._zod.onattach.push(s=>{let a=s._zod.bag;a.format=t.format,a.minimum=n,a.maximum=i,r&&(a.pattern=Ip)}),e._zod.check=s=>{let a=s.value;if(r){if(!Number.isInteger(a)){s.issues.push({expected:o,format:t.format,code:"invalid_type",input:a,inst:e});return}if(!Number.isSafeInteger(a)){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:o,continue:!t.abort}):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:o,continue:!t.abort});return}}a<n&&s.issues.push({origin:"number",input:a,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),a>i&&s.issues.push({origin:"number",input:a,code:"too_big",maximum:i,inst:e})}}),Mp=_("$ZodCheckBigIntFormat",(e,t)=>{De.init(e,t);let[r,o]=sp[t.format];e._zod.onattach.push(n=>{let i=n._zod.bag;i.format=t.format,i.minimum=r,i.maximum=o}),e._zod.check=n=>{let i=n.value;i<r&&n.issues.push({origin:"bigint",input:i,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!t.abort}),i>o&&n.issues.push({origin:"bigint",input:i,code:"too_big",maximum:o,inst:e})}}),Up=_("$ZodCheckMaxSize",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let n=o.value;n.size<=t.maximum||o.issues.push({origin:Ii(n),code:"too_big",maximum:t.maximum,input:n,inst:e,continue:!t.abort})}}),Zp=_("$ZodCheckMinSize",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let n=o.value;n.size>=t.minimum||o.issues.push({origin:Ii(n),code:"too_small",minimum:t.minimum,input:n,inst:e,continue:!t.abort})}}),Vp=_("$ZodCheckSizeEquals",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.size!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag;n.minimum=t.size,n.maximum=t.size,n.size=t.size}),e._zod.check=o=>{let n=o.value,i=n.size;if(i===t.size)return;let s=i>t.size;o.issues.push({origin:Ii(n),...s?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),Lp=_("$ZodCheckMaxLength",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(o._zod.bag.maximum=t.maximum)}),e._zod.check=o=>{let n=o.value;if(n.length<=t.maximum)return;let s=Oi(n);o.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),Fp=_("$ZodCheckMinLength",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(o._zod.bag.minimum=t.minimum)}),e._zod.check=o=>{let n=o.value;if(n.length>=t.minimum)return;let s=Oi(n);o.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:n,inst:e,continue:!t.abort})}}),Gp=_("$ZodCheckLengthEquals",(e,t)=>{var r;De.init(e,t),(r=e._zod.def).when??(r.when=o=>{let n=o.value;return!qr(n)&&n.length!==void 0}),e._zod.onattach.push(o=>{let n=o._zod.bag;n.minimum=t.length,n.maximum=t.length,n.length=t.length}),e._zod.check=o=>{let n=o.value,i=n.length;if(i===t.length)return;let s=Oi(n),a=i>t.length;o.issues.push({origin:s,...a?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:o.value,inst:e,continue:!t.abort})}}),fo=_("$ZodCheckStringFormat",(e,t)=>{var r,o;De.init(e,t),e._zod.onattach.push(n=>{let i=n._zod.bag;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=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:t.format,input:n.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(o=e._zod).check??(o.check=()=>{})}),Wp=_("$ZodCheckRegex",(e,t)=>{fo.init(e,t),e._zod.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Kp=_("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=Cp),fo.init(e,t)}),Hp=_("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=Ap),fo.init(e,t)}),Jp=_("$ZodCheckIncludes",(e,t)=>{De.init(e,t);let r=$r(t.includes),o=new RegExp(typeof t.position=="number"?`^.{${t.position}}${r}`:r);t.pattern=o,e._zod.onattach.push(n=>{let i=n._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(o)}),e._zod.check=n=>{n.value.includes(t.includes,t.position)||n.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:n.value,inst:e,continue:!t.abort})}}),Bp=_("$ZodCheckStartsWith",(e,t)=>{De.init(e,t);let r=new RegExp(`^${$r(t.prefix)}.*`);t.pattern??(t.pattern=r),e._zod.onattach.push(o=>{let n=o._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(r)}),e._zod.check=o=>{o.value.startsWith(t.prefix)||o.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:o.value,inst:e,continue:!t.abort})}}),Yp=_("$ZodCheckEndsWith",(e,t)=>{De.init(e,t);let r=new RegExp(`.*${$r(t.suffix)}$`);t.pattern??(t.pattern=r),e._zod.onattach.push(o=>{let n=o._zod.bag;n.patterns??(n.patterns=new Set),n.patterns.add(r)}),e._zod.check=o=>{o.value.endsWith(t.suffix)||o.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:o.value,inst:e,continue:!t.abort})}});function k_(e,t,r){e.issues.length&&t.issues.push(...gt(r,e.issues))}var Xp=_("$ZodCheckProperty",(e,t)=>{De.init(e,t),e._zod.check=r=>{let o=t.schema._zod.run({value:r.value[t.property],issues:[]},{});if(o instanceof Promise)return o.then(n=>k_(n,r,t.property));k_(o,r,t.property)}}),Qp=_("$ZodCheckMimeType",(e,t)=>{De.init(e,t);let r=new Set(t.mime);e._zod.onattach.push(o=>{o._zod.bag.mime=t.mime}),e._zod.check=o=>{r.has(o.value.type)||o.issues.push({code:"invalid_value",values:t.mime,input:o.value.type,inst:e})}}),ef=_("$ZodCheckOverwrite",(e,t)=>{De.init(e,t),e._zod.check=r=>{r.value=t.tx(r.value)}});var Ni=class{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let o=t.split(`
18
18
  `).filter(s=>s),n=Math.min(...o.map(s=>s.length-s.trimStart().length)),i=o.map(s=>s.slice(n)).map(s=>" ".repeat(this.indent*2)+s);for(let s of i)this.content.push(s)}compile(){let t=Function,r=this?.args,n=[...(this?.content??[""]).map(i=>` ${i}`)];return new t(...r,n.join(`
19
- `))}};var Qp={major:4,minor:0,patch:0};var W=_("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Qp;let o=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&o.unshift(e);for(let n of o)for(let i of n._zod.onattach)i(e);if(o.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let n=(i,s,a)=>{let c=_n(i),u;for(let l of s){if(l._zod.def.when){if(!l._zod.def.when(i))continue}else if(c)continue;let d=i.issues.length,h=l._zod.check(i);if(h instanceof Promise&&a?.async===!1)throw new sr;if(u||h instanceof Promise)u=(u??Promise.resolve()).then(async()=>{await h,i.issues.length!==d&&(c||(c=_n(i,d)))});else{if(i.issues.length===d)continue;c||(c=_n(i,d))}}return u?u.then(()=>i):i};e._zod.run=(i,s)=>{let a=e._zod.parse(i,s);if(a instanceof Promise){if(s.async===!1)throw new sr;return a.then(c=>n(c,o,s))}return n(a,o,s)}}e["~standard"]={validate:n=>{try{let i=Mr(e,n);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return Ur(e,n).then(s=>s.success?{value:s.data}:{issues:s.error?.issues})}},vendor:"zod",version:1}}),Lr=_("$ZodString",(e,t)=>{W.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Tp(e._zod.bag),e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),ke=_("$ZodStringFormat",(e,t)=>{fo.init(e,t),Lr.init(e,t)}),oc=_("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=fp),ke.init(e,t)}),ic=_("$ZodUUID",(e,t)=>{if(t.version){let o={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(o===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=bn(o))}else t.pattern??(t.pattern=bn());ke.init(e,t)}),sc=_("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=mp),ke.init(e,t)}),ac=_("$ZodURL",(e,t)=>{ke.init(e,t),e._zod.check=r=>{try{let o=r.value,n=new URL(o),i=n.href;t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(n.hostname)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:bp.source,input:r.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(n.protocol.endsWith(":")?n.protocol.slice(0,-1):n.protocol)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:r.value,inst:e,continue:!t.abort})),!o.endsWith("/")&&i.endsWith("/")?r.value=i.slice(0,-1):r.value=i;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}}),cc=_("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=hp()),ke.init(e,t)}),uc=_("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=dp),ke.init(e,t)}),lc=_("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=sp),ke.init(e,t)}),dc=_("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=ap),ke.init(e,t)}),pc=_("$ZodULID",(e,t)=>{t.pattern??(t.pattern=cp),ke.init(e,t)}),fc=_("$ZodXID",(e,t)=>{t.pattern??(t.pattern=up),ke.init(e,t)}),mc=_("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=lp),ke.init(e,t)}),tf=_("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=Sp(t)),ke.init(e,t)}),rf=_("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=kp),ke.init(e,t)}),nf=_("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=xp(t)),ke.init(e,t)}),of=_("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=pp),ke.init(e,t)}),hc=_("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=gp),ke.init(e,t),e._zod.onattach.push(r=>{let o=r._zod.bag;o.format="ipv4"})}),gc=_("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=vp),ke.init(e,t),e._zod.onattach.push(r=>{let o=r._zod.bag;o.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})}}}),vc=_("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=_p),ke.init(e,t)}),_c=_("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=yp),ke.init(e,t),e._zod.check=r=>{let[o,n]=r.value.split("/");try{if(!n)throw new Error;let i=Number(n);if(`${i}`!==n)throw new Error;if(i<0||i>128)throw new Error;new URL(`http://[${o}]`)}catch{r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!t.abort})}}});function sf(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}var yc=_("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=$p),ke.init(e,t),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64"}),e._zod.check=r=>{sf(r.value)||r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!t.abort})}});function A_(e){if(!Qa.test(e))return!1;let t=e.replace(/[-_]/g,o=>o==="-"?"+":"/"),r=t.padEnd(Math.ceil(t.length/4)*4,"=");return sf(r)}var $c=_("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=Qa),ke.init(e,t),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64url"}),e._zod.check=r=>{A_(r.value)||r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!t.abort})}}),bc=_("$ZodE164",(e,t)=>{t.pattern??(t.pattern=wp),ke.init(e,t)});function D_(e,t=null){try{let r=e.split(".");if(r.length!==3)return!1;let[o]=r;if(!o)return!1;let n=JSON.parse(atob(o));return!("typ"in n&&n?.typ!=="JWT"||!n.alg||t&&(!("alg"in n)||n.alg!==t))}catch{return!1}}var wc=_("$ZodJWT",(e,t)=>{ke.init(e,t),e._zod.check=r=>{D_(r.value,t.alg)||r.issues.push({code:"invalid_format",format:"jwt",input:r.value,inst:e,continue:!t.abort})}}),kc=_("$ZodCustomStringFormat",(e,t)=>{ke.init(e,t),e._zod.check=r=>{t.fn(r.value)||r.issues.push({code:"invalid_format",format:t.format,input:r.value,inst:e,continue:!t.abort})}}),Ni=_("$ZodNumber",(e,t)=>{W.init(e,t),e._zod.pattern=e._zod.bag.pattern??Ep,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=Number(r.value)}catch{}let n=r.value;if(typeof n=="number"&&!Number.isNaN(n)&&Number.isFinite(n))return r;let i=typeof n=="number"?Number.isNaN(n)?"NaN":Number.isFinite(n)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:n,inst:e,...i?{received:i}:{}}),r}}),xc=_("$ZodNumber",(e,t)=>{Ap.init(e,t),Ni.init(e,t)}),mo=_("$ZodBoolean",(e,t)=>{W.init(e,t),e._zod.pattern=Ip,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=!!r.value}catch{}let n=r.value;return typeof n=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:n,inst:e}),r}}),Ri=_("$ZodBigInt",(e,t)=>{W.init(e,t),e._zod.pattern=Pp,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=BigInt(r.value)}catch{}return typeof r.value=="bigint"||r.issues.push({expected:"bigint",code:"invalid_type",input:r.value,inst:e}),r}}),Sc=_("$ZodBigInt",(e,t)=>{Dp.init(e,t),Ri.init(e,t)}),Tc=_("$ZodSymbol",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return typeof n=="symbol"||r.issues.push({expected:"symbol",code:"invalid_type",input:n,inst:e}),r}}),Pc=_("$ZodUndefined",(e,t)=>{W.init(e,t),e._zod.pattern=Op,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(r,o)=>{let n=r.value;return typeof n>"u"||r.issues.push({expected:"undefined",code:"invalid_type",input:n,inst:e}),r}}),zc=_("$ZodNull",(e,t)=>{W.init(e,t),e._zod.pattern=jp,e._zod.values=new Set([null]),e._zod.parse=(r,o)=>{let n=r.value;return n===null||r.issues.push({expected:"null",code:"invalid_type",input:n,inst:e}),r}}),Ec=_("$ZodAny",(e,t)=>{W.init(e,t),e._zod.parse=r=>r}),wn=_("$ZodUnknown",(e,t)=>{W.init(e,t),e._zod.parse=r=>r}),Ic=_("$ZodNever",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>(r.issues.push({expected:"never",code:"invalid_type",input:r.value,inst:e}),r)}),jc=_("$ZodVoid",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return typeof n>"u"||r.issues.push({expected:"void",code:"invalid_type",input:n,inst:e}),r}}),Oc=_("$ZodDate",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=new Date(r.value)}catch{}let n=r.value,i=n instanceof Date;return i&&!Number.isNaN(n.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:n,...i?{received:"Invalid Date"}:{},inst:e}),r}});function S_(e,t,r){e.issues.length&&t.issues.push(...mt(r,e.issues)),t.value[r]=e.value}var ho=_("$ZodArray",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!Array.isArray(n))return r.issues.push({expected:"array",code:"invalid_type",input:n,inst:e}),r;r.value=Array(n.length);let i=[];for(let s=0;s<n.length;s++){let a=n[s],c=t.element._zod.run({value:a,issues:[]},o);c instanceof Promise?i.push(c.then(u=>S_(u,r,s))):S_(c,r,s)}return i.length?Promise.all(i).then(()=>r):r}});function rc(e,t,r){e.issues.length&&t.issues.push(...mt(r,e.issues)),t.value[r]=e.value}function T_(e,t,r,o){e.issues.length?o[r]===void 0?r in o?t.value[r]=void 0:t.value[r]=e.value:t.issues.push(...mt(r,e.issues)):e.value===void 0?r in o&&(t.value[r]=void 0):t.value[r]=e.value}var Ci=_("$ZodObject",(e,t)=>{W.init(e,t);let r=Ti(()=>{let d=Object.keys(t.shape);for(let m of d)if(!(t.shape[m]instanceof W))throw new Error(`Invalid element at key "${m}": expected a Zod schema`);let h=rp(t.shape);return{shape:t.shape,keys:d,keySet:new Set(d),numKeys:d.length,optionalKeys:new Set(h)}});_e(e._zod,"propValues",()=>{let d=t.shape,h={};for(let m in d){let p=d[m]._zod;if(p.values){h[m]??(h[m]=new Set);for(let f of p.values)h[m].add(f)}}return h});let o=d=>{let h=new Oi(["shape","payload","ctx"]),m=r.value,p=w=>{let k=vn(w);return`shape[${k}]._zod.run({ value: input[${k}], issues: [] }, ctx)`};h.write("const input = payload.value;");let f=Object.create(null),g=0;for(let w of m.keys)f[w]=`key_${g++}`;h.write("const newResult = {}");for(let w of m.keys)if(m.optionalKeys.has(w)){let k=f[w];h.write(`const ${k} = ${p(w)};`);let E=vn(w);h.write(`
19
+ `))}};var tf={major:4,minor:0,patch:0};var W=_("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=tf;let o=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&o.unshift(e);for(let n of o)for(let i of n._zod.onattach)i(e);if(o.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let n=(i,s,a)=>{let c=_n(i),u;for(let l of s){if(l._zod.def.when){if(!l._zod.def.when(i))continue}else if(c)continue;let d=i.issues.length,h=l._zod.check(i);if(h instanceof Promise&&a?.async===!1)throw new ar;if(u||h instanceof Promise)u=(u??Promise.resolve()).then(async()=>{await h,i.issues.length!==d&&(c||(c=_n(i,d)))});else{if(i.issues.length===d)continue;c||(c=_n(i,d))}}return u?u.then(()=>i):i};e._zod.run=(i,s)=>{let a=e._zod.parse(i,s);if(a instanceof Promise){if(s.async===!1)throw new ar;return a.then(c=>n(c,o,s))}return n(a,o,s)}}e["~standard"]={validate:n=>{try{let i=Mr(e,n);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return Ur(e,n).then(s=>s.success?{value:s.data}:{issues:s.error?.issues})}},vendor:"zod",version:1}}),Vr=_("$ZodString",(e,t)=>{W.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??zp(e._zod.bag),e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),ke=_("$ZodStringFormat",(e,t)=>{fo.init(e,t),Vr.init(e,t)}),ac=_("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=hp),ke.init(e,t)}),cc=_("$ZodUUID",(e,t)=>{if(t.version){let o={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(o===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=$n(o))}else t.pattern??(t.pattern=$n());ke.init(e,t)}),uc=_("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=gp),ke.init(e,t)}),lc=_("$ZodURL",(e,t)=>{ke.init(e,t),e._zod.check=r=>{try{let o=r.value,n=new URL(o),i=n.href;t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(n.hostname)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:kp.source,input:r.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(n.protocol.endsWith(":")?n.protocol.slice(0,-1):n.protocol)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:r.value,inst:e,continue:!t.abort})),!o.endsWith("/")&&i.endsWith("/")?r.value=i.slice(0,-1):r.value=i;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}}),dc=_("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=vp()),ke.init(e,t)}),pc=_("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=fp),ke.init(e,t)}),fc=_("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=cp),ke.init(e,t)}),mc=_("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=up),ke.init(e,t)}),hc=_("$ZodULID",(e,t)=>{t.pattern??(t.pattern=lp),ke.init(e,t)}),gc=_("$ZodXID",(e,t)=>{t.pattern??(t.pattern=dp),ke.init(e,t)}),vc=_("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=pp),ke.init(e,t)}),nf=_("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=Pp(t)),ke.init(e,t)}),of=_("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=Sp),ke.init(e,t)}),sf=_("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=Tp(t)),ke.init(e,t)}),af=_("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=mp),ke.init(e,t)}),_c=_("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=_p),ke.init(e,t),e._zod.onattach.push(r=>{let o=r._zod.bag;o.format="ipv4"})}),yc=_("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=yp),ke.init(e,t),e._zod.onattach.push(r=>{let o=r._zod.bag;o.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})}}}),bc=_("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=bp),ke.init(e,t)}),$c=_("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=$p),ke.init(e,t),e._zod.check=r=>{let[o,n]=r.value.split("/");try{if(!n)throw new Error;let i=Number(n);if(`${i}`!==n)throw new Error;if(i<0||i>128)throw new Error;new URL(`http://[${o}]`)}catch{r.issues.push({code:"invalid_format",format:"cidrv6",input:r.value,inst:e,continue:!t.abort})}}});function cf(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}var wc=_("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=wp),ke.init(e,t),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64"}),e._zod.check=r=>{cf(r.value)||r.issues.push({code:"invalid_format",format:"base64",input:r.value,inst:e,continue:!t.abort})}});function D_(e){if(!rc.test(e))return!1;let t=e.replace(/[-_]/g,o=>o==="-"?"+":"/"),r=t.padEnd(Math.ceil(t.length/4)*4,"=");return cf(r)}var kc=_("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=rc),ke.init(e,t),e._zod.onattach.push(r=>{r._zod.bag.contentEncoding="base64url"}),e._zod.check=r=>{D_(r.value)||r.issues.push({code:"invalid_format",format:"base64url",input:r.value,inst:e,continue:!t.abort})}}),xc=_("$ZodE164",(e,t)=>{t.pattern??(t.pattern=xp),ke.init(e,t)});function q_(e,t=null){try{let r=e.split(".");if(r.length!==3)return!1;let[o]=r;if(!o)return!1;let n=JSON.parse(atob(o));return!("typ"in n&&n?.typ!=="JWT"||!n.alg||t&&(!("alg"in n)||n.alg!==t))}catch{return!1}}var Sc=_("$ZodJWT",(e,t)=>{ke.init(e,t),e._zod.check=r=>{q_(r.value,t.alg)||r.issues.push({code:"invalid_format",format:"jwt",input:r.value,inst:e,continue:!t.abort})}}),Tc=_("$ZodCustomStringFormat",(e,t)=>{ke.init(e,t),e._zod.check=r=>{t.fn(r.value)||r.issues.push({code:"invalid_format",format:t.format,input:r.value,inst:e,continue:!t.abort})}}),Ri=_("$ZodNumber",(e,t)=>{W.init(e,t),e._zod.pattern=e._zod.bag.pattern??Op,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=Number(r.value)}catch{}let n=r.value;if(typeof n=="number"&&!Number.isNaN(n)&&Number.isFinite(n))return r;let i=typeof n=="number"?Number.isNaN(n)?"NaN":Number.isFinite(n)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:n,inst:e,...i?{received:i}:{}}),r}}),Pc=_("$ZodNumber",(e,t)=>{qp.init(e,t),Ri.init(e,t)}),mo=_("$ZodBoolean",(e,t)=>{W.init(e,t),e._zod.pattern=jp,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=!!r.value}catch{}let n=r.value;return typeof n=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:n,inst:e}),r}}),Ci=_("$ZodBigInt",(e,t)=>{W.init(e,t),e._zod.pattern=Ep,e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=BigInt(r.value)}catch{}return typeof r.value=="bigint"||r.issues.push({expected:"bigint",code:"invalid_type",input:r.value,inst:e}),r}}),zc=_("$ZodBigInt",(e,t)=>{Mp.init(e,t),Ci.init(e,t)}),Ec=_("$ZodSymbol",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return typeof n=="symbol"||r.issues.push({expected:"symbol",code:"invalid_type",input:n,inst:e}),r}}),Ic=_("$ZodUndefined",(e,t)=>{W.init(e,t),e._zod.pattern=Rp,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(r,o)=>{let n=r.value;return typeof n>"u"||r.issues.push({expected:"undefined",code:"invalid_type",input:n,inst:e}),r}}),Oc=_("$ZodNull",(e,t)=>{W.init(e,t),e._zod.pattern=Np,e._zod.values=new Set([null]),e._zod.parse=(r,o)=>{let n=r.value;return n===null||r.issues.push({expected:"null",code:"invalid_type",input:n,inst:e}),r}}),jc=_("$ZodAny",(e,t)=>{W.init(e,t),e._zod.parse=r=>r}),wn=_("$ZodUnknown",(e,t)=>{W.init(e,t),e._zod.parse=r=>r}),Nc=_("$ZodNever",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>(r.issues.push({expected:"never",code:"invalid_type",input:r.value,inst:e}),r)}),Rc=_("$ZodVoid",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return typeof n>"u"||r.issues.push({expected:"void",code:"invalid_type",input:n,inst:e}),r}}),Cc=_("$ZodDate",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{if(t.coerce)try{r.value=new Date(r.value)}catch{}let n=r.value,i=n instanceof Date;return i&&!Number.isNaN(n.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:n,...i?{received:"Invalid Date"}:{},inst:e}),r}});function T_(e,t,r){e.issues.length&&t.issues.push(...gt(r,e.issues)),t.value[r]=e.value}var ho=_("$ZodArray",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!Array.isArray(n))return r.issues.push({expected:"array",code:"invalid_type",input:n,inst:e}),r;r.value=Array(n.length);let i=[];for(let s=0;s<n.length;s++){let a=n[s],c=t.element._zod.run({value:a,issues:[]},o);c instanceof Promise?i.push(c.then(u=>T_(u,r,s))):T_(c,r,s)}return i.length?Promise.all(i).then(()=>r):r}});function ic(e,t,r){e.issues.length&&t.issues.push(...gt(r,e.issues)),t.value[r]=e.value}function P_(e,t,r,o){e.issues.length?o[r]===void 0?r in o?t.value[r]=void 0:t.value[r]=e.value:t.issues.push(...gt(r,e.issues)):e.value===void 0?r in o&&(t.value[r]=void 0):t.value[r]=e.value}var Ai=_("$ZodObject",(e,t)=>{W.init(e,t);let r=Pi(()=>{let d=Object.keys(t.shape);for(let m of d)if(!(t.shape[m]instanceof W))throw new Error(`Invalid element at key "${m}": expected a Zod schema`);let h=op(t.shape);return{shape:t.shape,keys:d,keySet:new Set(d),numKeys:d.length,optionalKeys:new Set(h)}});_e(e._zod,"propValues",()=>{let d=t.shape,h={};for(let m in d){let p=d[m]._zod;if(p.values){h[m]??(h[m]=new Set);for(let f of p.values)h[m].add(f)}}return h});let o=d=>{let h=new Ni(["shape","payload","ctx"]),m=r.value,p=w=>{let k=vn(w);return`shape[${k}]._zod.run({ value: input[${k}], issues: [] }, ctx)`};h.write("const input = payload.value;");let f=Object.create(null),v=0;for(let w of m.keys)f[w]=`key_${v++}`;h.write("const newResult = {}");for(let w of m.keys)if(m.optionalKeys.has(w)){let k=f[w];h.write(`const ${k} = ${p(w)};`);let E=vn(w);h.write(`
20
20
  if (${k}.issues.length) {
21
21
  if (input[${E}] === undefined) {
22
22
  if (${E} in input) {
@@ -39,20 +39,20 @@
39
39
  if (${k}.issues.length) payload.issues = payload.issues.concat(${k}.issues.map(iss => ({
40
40
  ...iss,
41
41
  path: iss.path ? [${vn(w)}, ...iss.path] : [${vn(w)}]
42
- })));`),h.write(`newResult[${vn(w)}] = ${k}.value`)}h.write("payload.value = newResult;"),h.write("return payload;");let y=h.compile();return(w,k)=>y(d,w,k)},n,i=ao,s=!ki.jitless,c=s&&ep.value,u=t.catchall,l;e._zod.parse=(d,h)=>{l??(l=r.value);let m=d.value;if(!i(m))return d.issues.push({expected:"object",code:"invalid_type",input:m,inst:e}),d;let p=[];if(s&&c&&h?.async===!1&&h.jitless!==!0)n||(n=o(t.shape)),d=n(d,h);else{d.value={};let k=l.shape;for(let E of l.keys){let P=k[E],ze=P._zod.run({value:m[E],issues:[]},h),Me=P._zod.optin==="optional"&&P._zod.optout==="optional";ze instanceof Promise?p.push(ze.then(or=>Me?T_(or,d,E,m):rc(or,d,E))):Me?T_(ze,d,E,m):rc(ze,d,E)}}if(!u)return p.length?Promise.all(p).then(()=>d):d;let f=[],g=l.keySet,y=u._zod,w=y.def.type;for(let k of Object.keys(m)){if(g.has(k))continue;if(w==="never"){f.push(k);continue}let E=y.run({value:m[k],issues:[]},h);E instanceof Promise?p.push(E.then(P=>rc(P,d,k))):rc(E,d,k)}return f.length&&d.issues.push({code:"unrecognized_keys",keys:f,input:m,inst:e}),p.length?Promise.all(p).then(()=>d):d}});function P_(e,t,r,o){for(let n of e)if(n.issues.length===0)return t.value=n.value,t;return t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map(n=>n.issues.map(i=>Pt(i,o,Ue())))}),t}var Ai=_("$ZodUnion",(e,t)=>{W.init(e,t),_e(e._zod,"optin",()=>t.options.some(r=>r._zod.optin==="optional")?"optional":void 0),_e(e._zod,"optout",()=>t.options.some(r=>r._zod.optout==="optional")?"optional":void 0),_e(e._zod,"values",()=>{if(t.options.every(r=>r._zod.values))return new Set(t.options.flatMap(r=>Array.from(r._zod.values)))}),_e(e._zod,"pattern",()=>{if(t.options.every(r=>r._zod.pattern)){let r=t.options.map(o=>o._zod.pattern);return new RegExp(`^(${r.map(o=>Pi(o.source)).join("|")})$`)}}),e._zod.parse=(r,o)=>{let n=!1,i=[];for(let s of t.options){let a=s._zod.run({value:r.value,issues:[]},o);if(a instanceof Promise)i.push(a),n=!0;else{if(a.issues.length===0)return a;i.push(a)}}return n?Promise.all(i).then(s=>P_(s,r,e,o)):P_(i,r,e,o)}}),Nc=_("$ZodDiscriminatedUnion",(e,t)=>{Ai.init(e,t);let r=e._zod.parse;_e(e._zod,"propValues",()=>{let n={};for(let i of t.options){let s=i._zod.propValues;if(!s||Object.keys(s).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[a,c]of Object.entries(s)){n[a]||(n[a]=new Set);for(let u of c)n[a].add(u)}}return n});let o=Ti(()=>{let n=t.options,i=new Map;for(let s of n){let a=s._zod.propValues[t.discriminator];if(!a||a.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(let c of a){if(i.has(c))throw new Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,s)}}return i});e._zod.parse=(n,i)=>{let s=n.value;if(!ao(s))return n.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),n;let a=o.value.get(s?.[t.discriminator]);return a?a._zod.run(n,i):t.unionFallback?r(n,i):(n.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:s,path:[t.discriminator],inst:e}),n)}}),Rc=_("$ZodIntersection",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value,i=t.left._zod.run({value:n,issues:[]},o),s=t.right._zod.run({value:n,issues:[]},o);return i instanceof Promise||s instanceof Promise?Promise.all([i,s]).then(([c,u])=>z_(r,c,u)):z_(r,i,s)}});function ef(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(co(e)&&co(t)){let r=Object.keys(t),o=Object.keys(e).filter(i=>r.indexOf(i)!==-1),n={...e,...t};for(let i of o){let s=ef(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};n[i]=s.data}return{valid:!0,data:n}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let o=0;o<e.length;o++){let n=e[o],i=t[o],s=ef(n,i);if(!s.valid)return{valid:!1,mergeErrorPath:[o,...s.mergeErrorPath]};r.push(s.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}function z_(e,t,r){if(t.issues.length&&e.issues.push(...t.issues),r.issues.length&&e.issues.push(...r.issues),_n(e))return e;let o=ef(t.value,r.value);if(!o.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);return e.value=o.data,e}var Vr=_("$ZodTuple",(e,t)=>{W.init(e,t);let r=t.items,o=r.length-[...r].reverse().findIndex(n=>n._zod.optin!=="optional");e._zod.parse=(n,i)=>{let s=n.value;if(!Array.isArray(s))return n.issues.push({input:s,inst:e,expected:"tuple",code:"invalid_type"}),n;n.value=[];let a=[];if(!t.rest){let u=s.length>r.length,l=s.length<o-1;if(u||l)return n.issues.push({input:s,inst:e,origin:"array",...u?{code:"too_big",maximum:r.length}:{code:"too_small",minimum:r.length}}),n}let c=-1;for(let u of r){if(c++,c>=s.length&&c>=o)continue;let l=u._zod.run({value:s[c],issues:[]},i);l instanceof Promise?a.push(l.then(d=>nc(d,n,c))):nc(l,n,c)}if(t.rest){let u=s.slice(r.length);for(let l of u){c++;let d=t.rest._zod.run({value:l,issues:[]},i);d instanceof Promise?a.push(d.then(h=>nc(h,n,c))):nc(d,n,c)}}return a.length?Promise.all(a).then(()=>n):n}});function nc(e,t,r){e.issues.length&&t.issues.push(...mt(r,e.issues)),t.value[r]=e.value}var Cc=_("$ZodRecord",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!co(n))return r.issues.push({expected:"record",code:"invalid_type",input:n,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:n[c],issues:[]},o);u instanceof Promise?i.push(u.then(l=>{l.issues.length&&r.issues.push(...mt(c,l.issues)),r.value[c]=l.value})):(u.issues.length&&r.issues.push(...mt(c,u.issues)),r.value[c]=u.value)}let a;for(let c in n)s.has(c)||(a=a??[],a.push(c));a&&a.length>0&&r.issues.push({code:"unrecognized_keys",input:n,inst:e,keys:a})}else{r.value={};for(let s of Reflect.ownKeys(n)){if(s==="__proto__")continue;let a=t.keyType._zod.run({value:s,issues:[]},o);if(a instanceof Promise)throw new 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=>Pt(u,o,Ue())),input:s,path:[s],inst:e}),r.value[a.value]=a.value;continue}let c=t.valueType._zod.run({value:n[s],issues:[]},o);c instanceof Promise?i.push(c.then(u=>{u.issues.length&&r.issues.push(...mt(s,u.issues)),r.value[a.value]=u.value})):(c.issues.length&&r.issues.push(...mt(s,c.issues)),r.value[a.value]=c.value)}}return i.length?Promise.all(i).then(()=>r):r}}),Ac=_("$ZodMap",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!(n instanceof Map))return r.issues.push({expected:"map",code:"invalid_type",input:n,inst:e}),r;let i=[];r.value=new Map;for(let[s,a]of n){let c=t.keyType._zod.run({value:s,issues:[]},o),u=t.valueType._zod.run({value:a,issues:[]},o);c instanceof Promise||u instanceof Promise?i.push(Promise.all([c,u]).then(([l,d])=>{E_(l,d,r,s,n,e,o)})):E_(c,u,r,s,n,e,o)}return i.length?Promise.all(i).then(()=>r):r}});function E_(e,t,r,o,n,i,s){e.issues.length&&(zi.has(typeof o)?r.issues.push(...mt(o,e.issues)):r.issues.push({origin:"map",code:"invalid_key",input:n,inst:i,issues:e.issues.map(a=>Pt(a,s,Ue()))})),t.issues.length&&(zi.has(typeof o)?r.issues.push(...mt(o,t.issues)):r.issues.push({origin:"map",code:"invalid_element",input:n,inst:i,key:o,issues:t.issues.map(a=>Pt(a,s,Ue()))})),r.value.set(e.value,t.value)}var Dc=_("$ZodSet",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!(n instanceof Set))return r.issues.push({input:n,inst:e,expected:"set",code:"invalid_type"}),r;let i=[];r.value=new Set;for(let s of n){let a=t.valueType._zod.run({value:s,issues:[]},o);a instanceof Promise?i.push(a.then(c=>I_(c,r))):I_(a,r)}return i.length?Promise.all(i).then(()=>r):r}});function I_(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}var qc=_("$ZodEnum",(e,t)=>{W.init(e,t);let r=Si(t.entries);e._zod.values=new Set(r),e._zod.pattern=new RegExp(`^(${r.filter(o=>zi.has(typeof o)).map(o=>typeof o=="string"?$r(o):o.toString()).join("|")})$`),e._zod.parse=(o,n)=>{let i=o.value;return e._zod.values.has(i)||o.issues.push({code:"invalid_value",values:r,input:i,inst:e}),o}}),Mc=_("$ZodLiteral",(e,t)=>{W.init(e,t),e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map(r=>typeof r=="string"?$r(r):r?r.toString():String(r)).join("|")})$`),e._zod.parse=(r,o)=>{let n=r.value;return e._zod.values.has(n)||r.issues.push({code:"invalid_value",values:t.values,input:n,inst:e}),r}}),Uc=_("$ZodFile",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return n instanceof File||r.issues.push({expected:"file",code:"invalid_type",input:n,inst:e}),r}}),go=_("$ZodTransform",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=t.transform(r.value,r);if(o.async)return(n instanceof Promise?n:Promise.resolve(n)).then(s=>(r.value=s,r));if(n instanceof Promise)throw new sr;return r.value=n,r}}),Zc=_("$ZodOptional",(e,t)=>{W.init(e,t),e._zod.optin="optional",e._zod.optout="optional",_e(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),_e(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${Pi(r.source)})?$`):void 0}),e._zod.parse=(r,o)=>t.innerType._zod.optin==="optional"?t.innerType._zod.run(r,o):r.value===void 0?r:t.innerType._zod.run(r,o)}),Lc=_("$ZodNullable",(e,t)=>{W.init(e,t),_e(e._zod,"optin",()=>t.innerType._zod.optin),_e(e._zod,"optout",()=>t.innerType._zod.optout),_e(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${Pi(r.source)}|null)$`):void 0}),_e(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(r,o)=>r.value===null?r:t.innerType._zod.run(r,o)}),Vc=_("$ZodDefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>{if(r.value===void 0)return r.value=t.defaultValue,r;let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>j_(i,t)):j_(n,t)}});function j_(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var Fc=_("$ZodPrefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>(r.value===void 0&&(r.value=t.defaultValue),t.innerType._zod.run(r,o))}),Gc=_("$ZodNonOptional",(e,t)=>{W.init(e,t),_e(e._zod,"values",()=>{let r=t.innerType._zod.values;return r?new Set([...r].filter(o=>o!==void 0)):void 0}),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>O_(i,e)):O_(n,e)}});function O_(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}var Wc=_("$ZodSuccess",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>(r.value=i.issues.length===0,r)):(r.value=n.issues.length===0,r)}}),Kc=_("$ZodCatch",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"optout",()=>t.innerType._zod.optout),_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>(r.value=i.value,i.issues.length&&(r.value=t.catchValue({...r,error:{issues:i.issues.map(s=>Pt(s,o,Ue()))},input:r.value}),r.issues=[]),r)):(r.value=n.value,n.issues.length&&(r.value=t.catchValue({...r,error:{issues:n.issues.map(i=>Pt(i,o,Ue()))},input:r.value}),r.issues=[]),r)}}),Hc=_("$ZodNaN",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>((typeof r.value!="number"||!Number.isNaN(r.value))&&r.issues.push({input:r.value,inst:e,expected:"nan",code:"invalid_type"}),r)}),vo=_("$ZodPipe",(e,t)=>{W.init(e,t),_e(e._zod,"values",()=>t.in._zod.values),_e(e._zod,"optin",()=>t.in._zod.optin),_e(e._zod,"optout",()=>t.out._zod.optout),e._zod.parse=(r,o)=>{let n=t.in._zod.run(r,o);return n instanceof Promise?n.then(i=>N_(i,t,o)):N_(n,t,o)}});function N_(e,t,r){return _n(e)?e:t.out._zod.run({value:e.value,issues:e.issues},r)}var Jc=_("$ZodReadonly",(e,t)=>{W.init(e,t),_e(e._zod,"propValues",()=>t.innerType._zod.propValues),_e(e._zod,"values",()=>t.innerType._zod.values),_e(e._zod,"optin",()=>t.innerType._zod.optin),_e(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(R_):R_(n)}});function R_(e){return e.value=Object.freeze(e.value),e}var Bc=_("$ZodTemplateLiteral",(e,t)=>{W.init(e,t);let r=[];for(let o of t.parts)if(o instanceof W){if(!o._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...o._zod.traits].shift()}`);let n=o._zod.pattern instanceof RegExp?o._zod.pattern.source:o._zod.pattern;if(!n)throw new Error(`Invalid template literal part: ${o._zod.traits}`);let i=n.startsWith("^")?1:0,s=n.endsWith("$")?n.length-1:n.length;r.push(n.slice(i,s))}else if(o===null||tp.has(typeof o))r.push($r(`${o}`));else throw new Error(`Invalid template literal part: ${o}`);e._zod.pattern=new RegExp(`^${r.join("")}$`),e._zod.parse=(o,n)=>typeof o.value!="string"?(o.issues.push({input:o.value,inst:e,expected:"template_literal",code:"invalid_type"}),o):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(o.value)||o.issues.push({input:o.value,inst:e,code:"invalid_format",format:"template_literal",pattern:e._zod.pattern.source}),o)}),Yc=_("$ZodPromise",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>Promise.resolve(r.value).then(n=>t.innerType._zod.run({value:n,issues:[]},o))}),Xc=_("$ZodLazy",(e,t)=>{W.init(e,t),_e(e._zod,"innerType",()=>t.getter()),_e(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),_e(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),_e(e._zod,"optin",()=>e._zod.innerType._zod.optin),_e(e._zod,"optout",()=>e._zod.innerType._zod.optout),e._zod.parse=(r,o)=>e._zod.innerType._zod.run(r,o)}),Qc=_("$ZodCustom",(e,t)=>{De.init(e,t),W.init(e,t),e._zod.parse=(r,o)=>r,e._zod.check=r=>{let o=r.value,n=t.fn(o);if(n instanceof Promise)return n.then(i=>C_(i,r,o,e));C_(n,r,o,e)}});function C_(e,t,r,o){if(!e){let n={code:"custom",input:r,inst:o,path:[...o._zod.def.path??[]],continue:!o._zod.def.abort};o._zod.def.params&&(n.params=o._zod.def.params),t.issues.push(ip(n))}}var _o={};mn(_o,{ar:()=>M_,az:()=>U_,be:()=>L_,ca:()=>V_,cs:()=>F_,de:()=>G_,en:()=>eu,eo:()=>W_,es:()=>K_,fa:()=>H_,fi:()=>J_,fr:()=>B_,frCA:()=>Y_,he:()=>X_,hu:()=>Q_,id:()=>ey,it:()=>ty,ja:()=>ry,kh:()=>ny,ko:()=>oy,mk:()=>iy,ms:()=>sy,nl:()=>ay,no:()=>cy,ota:()=>uy,pl:()=>dy,ps:()=>ly,pt:()=>py,ru:()=>my,sl:()=>hy,sv:()=>gy,ta:()=>vy,th:()=>_y,tr:()=>yy,ua:()=>$y,ur:()=>by,vi:()=>wy,zhCN:()=>ky,zhTW:()=>xy});var DT=()=>{let e={string:{unit:"\u062D\u0631\u0641",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},file:{unit:"\u0628\u0627\u064A\u062A",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},array:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},set:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0645\u062F\u062E\u0644",email:"\u0628\u0631\u064A\u062F \u0625\u0644\u0643\u062A\u0631\u0648\u0646\u064A",url:"\u0631\u0627\u0628\u0637",emoji:"\u0625\u064A\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u064A\u062E \u0648\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",date:"\u062A\u0627\u0631\u064A\u062E \u0628\u0645\u0639\u064A\u0627\u0631 ISO",time:"\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",duration:"\u0645\u062F\u0629 \u0628\u0645\u0639\u064A\u0627\u0631 ISO",ipv4:"\u0639\u0646\u0648\u0627\u0646 IPv4",ipv6:"\u0639\u0646\u0648\u0627\u0646 IPv6",cidrv4:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv4",cidrv6:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv6",base64:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64-encoded",base64url:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64url-encoded",json_string:"\u0646\u064E\u0635 \u0639\u0644\u0649 \u0647\u064A\u0626\u0629 JSON",e164:"\u0631\u0642\u0645 \u0647\u0627\u062A\u0641 \u0628\u0645\u0639\u064A\u0627\u0631 E.164",jwt:"JWT",template_literal:"\u0645\u062F\u062E\u0644"};return n=>{switch(n.code){case"invalid_type":return`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${n.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${O(n.values[0])}`:`\u0627\u062E\u062A\u064A\u0627\u0631 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062A\u0648\u0642\u0639 \u0627\u0646\u062A\u0642\u0627\u0621 \u0623\u062D\u062F \u0647\u0630\u0647 \u0627\u0644\u062E\u064A\u0627\u0631\u0627\u062A: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${n.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631"}`:`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${n.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${n.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${n.minimum.toString()} ${s.unit}`:`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${n.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${n.prefix}"`:i.format==="ends_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0646\u062A\u0647\u064A \u0628\u0640 "${i.suffix}"`:i.format==="includes"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u062A\u0636\u0645\u0651\u064E\u0646 "${i.includes}"`:i.format==="regex"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0637\u0627\u0628\u0642 \u0627\u0644\u0646\u0645\u0637 ${i.pattern}`:`${o[i.format]??n.format} \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644`}case"not_multiple_of":return`\u0631\u0642\u0645 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0643\u0648\u0646 \u0645\u0646 \u0645\u0636\u0627\u0639\u0641\u0627\u062A ${n.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${n.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${n.keys.length>1?"\u0629":""}: ${x(n.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${n.origin}`;case"invalid_union":return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644";case"invalid_element":return`\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${n.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}};function M_(){return{localeError:DT()}}var qT=()=>{let e={string:{unit:"simvol",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"element",verb:"olmal\u0131d\u0131r"},set:{unit:"element",verb:"olmal\u0131d\u0131r"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={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`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${n.expected}, daxil olan ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${O(n.values[0])}`:`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${n.origin??"d\u0259y\u0259r"} ${i}${n.maximum.toString()} ${s.unit??"element"}`:`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${n.origin??"d\u0259y\u0259r"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${n.origin} ${i}${n.minimum.toString()} ${s.unit}`:`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Yanl\u0131\u015F m\u0259tn: "${i.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`:i.format==="ends_with"?`Yanl\u0131\u015F m\u0259tn: "${i.suffix}" il\u0259 bitm\u0259lidir`:i.format==="includes"?`Yanl\u0131\u015F m\u0259tn: "${i.includes}" daxil olmal\u0131d\u0131r`:i.format==="regex"?`Yanl\u0131\u015F m\u0259tn: ${i.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`:`Yanl\u0131\u015F ${o[i.format]??n.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${n.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${n.keys.length>1?"lar":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${n.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}};function U_(){return{localeError:qT()}}function Z_(e,t,r,o){let n=Math.abs(e),i=n%10,s=n%100;return s>=11&&s<=19?o:i===1?t:i>=2&&i<=4?r:o}var MT=()=>{let e={string:{unit:{one:"\u0441\u0456\u043C\u0432\u0430\u043B",few:"\u0441\u0456\u043C\u0432\u0430\u043B\u044B",many:"\u0441\u0456\u043C\u0432\u0430\u043B\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u044B",many:"\u0431\u0430\u0439\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u043B\u0456\u043A";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0456\u045E";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0443\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0430\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0456 \u0447\u0430\u0441",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0447\u0430\u0441",duration:"ISO \u043F\u0440\u0430\u0446\u044F\u0433\u043B\u0430\u0441\u0446\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0430\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0430\u0441",cidrv4:"IPv4 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",base64:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64",base64url:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64url",json_string:"JSON \u0440\u0430\u0434\u043E\u043A",e164:"\u043D\u0443\u043C\u0430\u0440 E.164",jwt:"JWT",template_literal:"\u0443\u0432\u043E\u0434"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${n.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${O(n.values[0])}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0432\u0430\u0440\u044B\u044F\u043D\u0442: \u0447\u0430\u043A\u0430\u045E\u0441\u044F \u0430\u0434\u0437\u0456\u043D \u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);if(s){let a=Number(n.maximum),c=Z_(a,s.unit.one,s.unit.few,s.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${s.verb} ${i}${n.maximum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);if(s){let a=Number(n.minimum),c=Z_(a,s.unit.one,s.unit.few,s.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${s.verb} ${i}${n.minimum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u043F\u0430\u0447\u044B\u043D\u0430\u0446\u0446\u0430 \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u0430\u043A\u0430\u043D\u0447\u0432\u0430\u0446\u0446\u0430 \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u043C\u044F\u0448\u0447\u0430\u0446\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0430\u0434\u043F\u0430\u0432\u044F\u0434\u0430\u0446\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043B\u0456\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0431\u044B\u0446\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${n.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${n.origin}`;case"invalid_union":return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434";case"invalid_element":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u0430\u0435 \u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435 \u045E ${n.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}};function L_(){return{localeError:MT()}}var UT=()=>{let e={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entrada",email:"adre\xE7a electr\xF2nica",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:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\xE7a IPv4",ipv6:"adre\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Tipus inv\xE0lid: s'esperava ${n.expected}, s'ha rebut ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Valor inv\xE0lid: s'esperava ${O(n.values[0])}`:`Opci\xF3 inv\xE0lida: s'esperava una de ${x(n.values," o ")}`;case"too_big":{let i=n.inclusive?"com a m\xE0xim":"menys de",s=t(n.origin);return s?`Massa gran: s'esperava que ${n.origin??"el valor"} contingu\xE9s ${i} ${n.maximum.toString()} ${s.unit??"elements"}`:`Massa gran: s'esperava que ${n.origin??"el valor"} fos ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"com a m\xEDnim":"m\xE9s de",s=t(n.origin);return s?`Massa petit: s'esperava que ${n.origin} contingu\xE9s ${i} ${n.minimum.toString()} ${s.unit}`:`Massa petit: s'esperava que ${n.origin} fos ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Format inv\xE0lid: ha de comen\xE7ar amb "${i.prefix}"`:i.format==="ends_with"?`Format inv\xE0lid: ha d'acabar amb "${i.suffix}"`:i.format==="includes"?`Format inv\xE0lid: ha d'incloure "${i.includes}"`:i.format==="regex"?`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${i.pattern}`:`Format inv\xE0lid per a ${o[i.format]??n.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${n.divisor}`;case"unrecognized_keys":return`Clau${n.keys.length>1?"s":""} no reconeguda${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${n.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${n.origin}`;default:return"Entrada inv\xE0lida"}}};function V_(){return{localeError:UT()}}var ZT=()=>{let e={string:{unit:"znak\u016F",verb:"m\xEDt"},file:{unit:"bajt\u016F",verb:"m\xEDt"},array:{unit:"prvk\u016F",verb:"m\xEDt"},set:{unit:"prvk\u016F",verb:"m\xEDt"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u010D\xEDslo";case"string":return"\u0159et\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(n))return"pole";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"regul\xE1rn\xED v\xFDraz",email:"e-mailov\xE1 adresa",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:"datum a \u010Das ve form\xE1tu ISO",date:"datum ve form\xE1tu ISO",time:"\u010Das ve form\xE1tu ISO",duration:"doba trv\xE1n\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64",base64url:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64url",json_string:"\u0159et\u011Bzec ve form\xE1tu JSON",e164:"\u010D\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return n=>{switch(n.code){case"invalid_type":return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${n.expected}, obdr\u017Eeno ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${O(n.values[0])}`:`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${n.origin??"hodnota"} mus\xED m\xEDt ${i}${n.maximum.toString()} ${s.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${n.origin??"hodnota"} mus\xED b\xFDt ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${n.origin??"hodnota"} mus\xED m\xEDt ${i}${n.minimum.toString()} ${s.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${n.origin??"hodnota"} mus\xED b\xFDt ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${i.prefix}"`:i.format==="ends_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${i.suffix}"`:i.format==="includes"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${i.includes}"`:i.format==="regex"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${i.pattern}`:`Neplatn\xFD form\xE1t ${o[i.format]??n.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${n.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${x(n.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${n.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${n.origin}`;default:return"Neplatn\xFD vstup"}}};function F_(){return{localeError:ZT()}}var LT=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"Zahl";case"object":{if(Array.isArray(n))return"Array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"Eingabe",email:"E-Mail-Adresse",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-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return n=>{switch(n.code){case"invalid_type":return`Ung\xFCltige Eingabe: erwartet ${n.expected}, erhalten ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ung\xFCltige Eingabe: erwartet ${O(n.values[0])}`:`Ung\xFCltige Option: erwartet eine von ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Zu gro\xDF: erwartet, dass ${n.origin??"Wert"} ${i}${n.maximum.toString()} ${s.unit??"Elemente"} hat`:`Zu gro\xDF: erwartet, dass ${n.origin??"Wert"} ${i}${n.maximum.toString()} ist`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Zu klein: erwartet, dass ${n.origin} ${i}${n.minimum.toString()} ${s.unit} hat`:`Zu klein: erwartet, dass ${n.origin} ${i}${n.minimum.toString()} ist`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ung\xFCltiger String: muss mit "${i.prefix}" beginnen`:i.format==="ends_with"?`Ung\xFCltiger String: muss mit "${i.suffix}" enden`:i.format==="includes"?`Ung\xFCltiger String: muss "${i.includes}" enthalten`:i.format==="regex"?`Ung\xFCltiger String: muss dem Muster ${i.pattern} entsprechen`:`Ung\xFCltig: ${o[i.format]??n.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${n.divisor} sein`;case"unrecognized_keys":return`${n.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${n.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${n.origin}`;default:return"Ung\xFCltige Eingabe"}}};function G_(){return{localeError:LT()}}var VT=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},FT=()=>{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(o){return e[o]??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 o=>{switch(o.code){case"invalid_type":return`Invalid input: expected ${o.expected}, received ${VT(o.input)}`;case"invalid_value":return o.values.length===1?`Invalid input: expected ${O(o.values[0])}`:`Invalid option: expected one of ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`Too big: expected ${o.origin??"value"} to have ${n}${o.maximum.toString()} ${i.unit??"elements"}`:`Too big: expected ${o.origin??"value"} to be ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`Too small: expected ${o.origin} to have ${n}${o.minimum.toString()} ${i.unit}`:`Too small: expected ${o.origin} to be ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Invalid string: must start with "${n.prefix}"`:n.format==="ends_with"?`Invalid string: must end with "${n.suffix}"`:n.format==="includes"?`Invalid string: must include "${n.includes}"`:n.format==="regex"?`Invalid string: must match pattern ${n.pattern}`:`Invalid ${r[n.format]??o.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${o.divisor}`;case"unrecognized_keys":return`Unrecognized key${o.keys.length>1?"s":""}: ${x(o.keys,", ")}`;case"invalid_key":return`Invalid key in ${o.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${o.origin}`;default:return"Invalid input"}}};function eu(){return{localeError:FT()}}var GT=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},WT=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(o){return e[o]??null}let r={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return o=>{switch(o.code){case"invalid_type":return`Nevalida enigo: atendi\u011Dis ${o.expected}, ricevi\u011Dis ${GT(o.input)}`;case"invalid_value":return o.values.length===1?`Nevalida enigo: atendi\u011Dis ${O(o.values[0])}`:`Nevalida opcio: atendi\u011Dis unu el ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${n}${o.maximum.toString()} ${i.unit??"elementojn"}`:`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`Tro malgranda: atendi\u011Dis ke ${o.origin} havu ${n}${o.minimum.toString()} ${i.unit}`:`Tro malgranda: atendi\u011Dis ke ${o.origin} estu ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Nevalida karaktraro: devas komenci\u011Di per "${n.prefix}"`:n.format==="ends_with"?`Nevalida karaktraro: devas fini\u011Di per "${n.suffix}"`:n.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${n.includes}"`:n.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${n.pattern}`:`Nevalida ${r[n.format]??o.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${o.divisor}`;case"unrecognized_keys":return`Nekonata${o.keys.length>1?"j":""} \u015Dlosilo${o.keys.length>1?"j":""}: ${x(o.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${o.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${o.origin}`;default:return"Nevalida enigo"}}};function W_(){return{localeError:WT()}}var KT=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(n))return"arreglo";if(n===null)return"nulo";if(Object.getPrototypeOf(n)!==Object.prototype)return n.constructor.name}}return i},o={regex:"entrada",email:"direcci\xF3n de correo electr\xF3nico",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:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\xF3n ISO",ipv4:"direcci\xF3n IPv4",ipv6:"direcci\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Entrada inv\xE1lida: se esperaba ${n.expected}, recibido ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entrada inv\xE1lida: se esperaba ${O(n.values[0])}`:`Opci\xF3n inv\xE1lida: se esperaba una de ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Demasiado grande: se esperaba que ${n.origin??"valor"} tuviera ${i}${n.maximum.toString()} ${s.unit??"elementos"}`:`Demasiado grande: se esperaba que ${n.origin??"valor"} fuera ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Demasiado peque\xF1o: se esperaba que ${n.origin} tuviera ${i}${n.minimum.toString()} ${s.unit}`:`Demasiado peque\xF1o: se esperaba que ${n.origin} fuera ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cadena inv\xE1lida: debe comenzar con "${i.prefix}"`:i.format==="ends_with"?`Cadena inv\xE1lida: debe terminar en "${i.suffix}"`:i.format==="includes"?`Cadena inv\xE1lida: debe incluir "${i.includes}"`:i.format==="regex"?`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${i.pattern}`:`Inv\xE1lido ${o[i.format]??n.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${n.divisor}`;case"unrecognized_keys":return`Llave${n.keys.length>1?"s":""} desconocida${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${n.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${n.origin}`;default:return"Entrada inv\xE1lida"}}};function K_(){return{localeError:KT()}}var HT=()=>{let e={string:{unit:"\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},file:{unit:"\u0628\u0627\u06CC\u062A",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},array:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},set:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(n))return"\u0622\u0631\u0627\u06CC\u0647";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u06CC",email:"\u0622\u062F\u0631\u0633 \u0627\u06CC\u0645\u06CC\u0644",url:"URL",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u06CC\u062E \u0648 \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",date:"\u062A\u0627\u0631\u06CC\u062E \u0627\u06CC\u0632\u0648",time:"\u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",duration:"\u0645\u062F\u062A \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",ipv4:"IPv4 \u0622\u062F\u0631\u0633",ipv6:"IPv6 \u0622\u062F\u0631\u0633",cidrv4:"IPv4 \u062F\u0627\u0645\u0646\u0647",cidrv6:"IPv6 \u062F\u0627\u0645\u0646\u0647",base64:"base64-encoded \u0631\u0634\u062A\u0647",base64url:"base64url-encoded \u0631\u0634\u062A\u0647",json_string:"JSON \u0631\u0634\u062A\u0647",e164:"E.164 \u0639\u062F\u062F",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u06CC"};return n=>{switch(n.code){case"invalid_type":return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${n.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${r(n.input)} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`;case"invalid_value":return n.values.length===1?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${O(n.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`:`\u06AF\u0632\u06CC\u0646\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A \u06CC\u06A9\u06CC \u0627\u0632 ${x(n.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${n.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${n.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} ${s.unit} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.prefix}" \u0634\u0631\u0648\u0639 \u0634\u0648\u062F`:i.format==="ends_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.suffix}" \u062A\u0645\u0627\u0645 \u0634\u0648\u062F`:i.format==="includes"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0634\u0627\u0645\u0644 "${i.includes}" \u0628\u0627\u0634\u062F`:i.format==="regex"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 \u0627\u0644\u06AF\u0648\u06CC ${i.pattern} \u0645\u0637\u0627\u0628\u0642\u062A \u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F`:`${o[i.format]??n.format} \u0646\u0627\u0645\u0639\u062A\u0628\u0631`}case"not_multiple_of":return`\u0639\u062F\u062F \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0645\u0636\u0631\u0628 ${n.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${n.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${x(n.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${n.origin}`;case"invalid_union":return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631";case"invalid_element":return`\u0645\u0642\u062F\u0627\u0631 \u0646\u0627\u0645\u0639\u062A\u0628\u0631 \u062F\u0631 ${n.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}};function H_(){return{localeError:HT()}}var JT=()=>{let e={string:{unit:"merkki\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\xE4iv\xE4m\xE4\xE4r\xE4n"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"s\xE4\xE4nn\xF6llinen lauseke",email:"s\xE4hk\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\xE4iv\xE4m\xE4\xE4r\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return n=>{switch(n.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${n.expected}, oli ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Virheellinen sy\xF6te: t\xE4ytyy olla ${O(n.values[0])}`:`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Liian suuri: ${s.subject} t\xE4ytyy olla ${i}${n.maximum.toString()} ${s.unit}`.trim():`Liian suuri: arvon t\xE4ytyy olla ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Liian pieni: ${s.subject} t\xE4ytyy olla ${i}${n.minimum.toString()} ${s.unit}`.trim():`Liian pieni: arvon t\xE4ytyy olla ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${i.prefix}"`:i.format==="ends_with"?`Virheellinen sy\xF6te: t\xE4ytyy loppua "${i.suffix}"`:i.format==="includes"?`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${i.includes}"`:i.format==="regex"?`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${i.pattern}`:`Virheellinen ${o[i.format]??n.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${n.divisor} monikerta`;case"unrecognized_keys":return`${n.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${x(n.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\xF6te"}}};function J_(){return{localeError:JT()}}var BT=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"nombre";case"object":{if(Array.isArray(n))return"tableau";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse e-mail",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:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return n=>{switch(n.code){case"invalid_type":return`Entr\xE9e invalide : ${n.expected} attendu, ${r(n.input)} re\xE7u`;case"invalid_value":return n.values.length===1?`Entr\xE9e invalide : ${O(n.values[0])} attendu`:`Option invalide : une valeur parmi ${x(n.values,"|")} attendue`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Trop grand : ${n.origin??"valeur"} doit ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"\xE9l\xE9ment(s)"}`:`Trop grand : ${n.origin??"valeur"} doit \xEAtre ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Trop petit : ${n.origin} doit ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Trop petit : ${n.origin} doit \xEAtre ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au mod\xE8le ${i.pattern}`:`${o[i.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${n.divisor}`;case"unrecognized_keys":return`Cl\xE9${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${x(n.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${n.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entr\xE9e invalide"}}};function B_(){return{localeError:BT()}}var YT=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse courriel",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:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return n=>{switch(n.code){case"invalid_type":return`Entr\xE9e invalide : attendu ${n.expected}, re\xE7u ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entr\xE9e invalide : attendu ${O(n.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"\u2264":"<",s=t(n.origin);return s?`Trop grand : attendu que ${n.origin??"la valeur"} ait ${i}${n.maximum.toString()} ${s.unit}`:`Trop grand : attendu que ${n.origin??"la valeur"} soit ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"\u2265":">",s=t(n.origin);return s?`Trop petit : attendu que ${n.origin} ait ${i}${n.minimum.toString()} ${s.unit}`:`Trop petit : attendu que ${n.origin} soit ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au motif ${i.pattern}`:`${o[i.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${n.divisor}`;case"unrecognized_keys":return`Cl\xE9${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${x(n.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${n.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entr\xE9e invalide"}}};function Y_(){return{localeError:YT()}}var XT=()=>{let e={string:{unit:"\u05D0\u05D5\u05EA\u05D9\u05D5\u05EA",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u05E7\u05DC\u05D8",email:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",url:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",emoji:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",date:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",time:"\u05D6\u05DE\u05DF ISO",duration:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",ipv4:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",ipv6:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",cidrv4:"\u05D8\u05D5\u05D5\u05D7 IPv4",cidrv6:"\u05D8\u05D5\u05D5\u05D7 IPv6",base64:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",base64url:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",json_string:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",e164:"\u05DE\u05E1\u05E4\u05E8 E.164",jwt:"JWT",template_literal:"\u05E7\u05DC\u05D8"};return n=>{switch(n.code){case"invalid_type":return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${n.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${O(n.values[0])}`:`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05D0\u05D7\u05EA \u05DE\u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${n.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.maximum.toString()} ${s.unit??"elements"}`:`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${n.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${n.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.minimum.toString()} ${s.unit}`:`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${n.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1"${i.prefix}"`:i.format==="ends_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${i.suffix}"`:i.format==="includes"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${i.includes}"`:i.format==="regex"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${i.pattern}`:`${o[i.format]??n.format} \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF`}case"not_multiple_of":return`\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ${n.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${n.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${n.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u05DE\u05E4\u05EA\u05D7 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${n.origin}`;case"invalid_union":return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";case"invalid_element":return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${n.origin}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}};function X_(){return{localeError:XT()}}var QT=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"sz\xE1m";case"object":{if(Array.isArray(n))return"t\xF6mb";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"bemenet",email:"email c\xEDm",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 id\u0151b\xE9lyeg",date:"ISO d\xE1tum",time:"ISO id\u0151",duration:"ISO id\u0151intervallum",ipv4:"IPv4 c\xEDm",ipv6:"IPv6 c\xEDm",cidrv4:"IPv4 tartom\xE1ny",cidrv6:"IPv6 tartom\xE1ny",base64:"base64-k\xF3dolt string",base64url:"base64url-k\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\xE1m",jwt:"JWT",template_literal:"bemenet"};return n=>{switch(n.code){case"invalid_type":return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${n.expected}, a kapott \xE9rt\xE9k ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${O(n.values[0])}`:`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`T\xFAl nagy: ${n.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${i}${n.maximum.toString()} ${s.unit??"elem"}`:`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${n.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${n.origin} m\xE9rete t\xFAl kicsi ${i}${n.minimum.toString()} ${s.unit}`:`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${n.origin} t\xFAl kicsi ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\xC9rv\xE9nytelen string: "${i.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`:i.format==="ends_with"?`\xC9rv\xE9nytelen string: "${i.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`:i.format==="includes"?`\xC9rv\xE9nytelen string: "${i.includes}" \xE9rt\xE9ket kell tartalmaznia`:i.format==="regex"?`\xC9rv\xE9nytelen string: ${i.pattern} mint\xE1nak kell megfelelnie`:`\xC9rv\xE9nytelen ${o[i.format]??n.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${n.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${n.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${n.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}};function Q_(){return{localeError:QT()}}var eP=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"alamat email",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:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input tidak valid: diharapkan ${n.expected}, diterima ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input tidak valid: diharapkan ${O(n.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: diharapkan ${n.origin??"value"} memiliki ${i}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: diharapkan ${n.origin??"value"} menjadi ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: diharapkan ${n.origin} memiliki ${i}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: diharapkan ${n.origin} menjadi ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`String tidak valid: harus dimulai dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak valid: harus berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak valid: harus menyertakan "${i.includes}"`:i.format==="regex"?`String tidak valid: harus sesuai pola ${i.pattern}`:`${o[i.format]??n.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${n.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${n.origin}`;default:return"Input tidak valid"}}};function ey(){return{localeError:eP()}}var tP=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"numero";case"object":{if(Array.isArray(n))return"vettore";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"indirizzo email",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:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input non valido: atteso ${n.expected}, ricevuto ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input non valido: atteso ${O(n.values[0])}`:`Opzione non valida: atteso uno tra ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Troppo grande: ${n.origin??"valore"} deve avere ${i}${n.maximum.toString()} ${s.unit??"elementi"}`:`Troppo grande: ${n.origin??"valore"} deve essere ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Troppo piccolo: ${n.origin} deve avere ${i}${n.minimum.toString()} ${s.unit}`:`Troppo piccolo: ${n.origin} deve essere ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Stringa non valida: deve iniziare con "${i.prefix}"`:i.format==="ends_with"?`Stringa non valida: deve terminare con "${i.suffix}"`:i.format==="includes"?`Stringa non valida: deve includere "${i.includes}"`:i.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${i.pattern}`:`Invalid ${o[i.format]??n.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${n.divisor}`;case"unrecognized_keys":return`Chiav${n.keys.length>1?"i":"e"} non riconosciut${n.keys.length>1?"e":"a"}: ${x(n.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${n.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${n.origin}`;default:return"Input non valido"}}};function ty(){return{localeError:tP()}}var rP=()=>{let e={string:{unit:"\u6587\u5B57",verb:"\u3067\u3042\u308B"},file:{unit:"\u30D0\u30A4\u30C8",verb:"\u3067\u3042\u308B"},array:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"},set:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u6570\u5024";case"object":{if(Array.isArray(n))return"\u914D\u5217";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u5165\u529B\u5024",email:"\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9",url:"URL",emoji:"\u7D75\u6587\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u6642",date:"ISO\u65E5\u4ED8",time:"ISO\u6642\u523B",duration:"ISO\u671F\u9593",ipv4:"IPv4\u30A2\u30C9\u30EC\u30B9",ipv6:"IPv6\u30A2\u30C9\u30EC\u30B9",cidrv4:"IPv4\u7BC4\u56F2",cidrv6:"IPv6\u7BC4\u56F2",base64:"base64\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",base64url:"base64url\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",json_string:"JSON\u6587\u5B57\u5217",e164:"E.164\u756A\u53F7",jwt:"JWT",template_literal:"\u5165\u529B\u5024"};return n=>{switch(n.code){case"invalid_type":return`\u7121\u52B9\u306A\u5165\u529B: ${n.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${r(n.input)}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`;case"invalid_value":return n.values.length===1?`\u7121\u52B9\u306A\u5165\u529B: ${O(n.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u9078\u629E: ${x(n.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let i=n.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",s=t(n.origin);return s?`\u5927\u304D\u3059\u304E\u308B\u5024: ${n.origin??"\u5024"}\u306F${n.maximum.toString()}${s.unit??"\u8981\u7D20"}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5927\u304D\u3059\u304E\u308B\u5024: ${n.origin??"\u5024"}\u306F${n.maximum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let i=n.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",s=t(n.origin);return s?`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${n.origin}\u306F${n.minimum.toString()}${s.unit}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${n.origin}\u306F${n.minimum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="ends_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="includes"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="regex"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${i.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u7121\u52B9\u306A${o[i.format]??n.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${n.divisor}\u306E\u500D\u6570\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"unrecognized_keys":return`\u8A8D\u8B58\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC${n.keys.length>1?"\u7FA4":""}: ${x(n.keys,"\u3001")}`;case"invalid_key":return`${n.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${n.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}};function ry(){return{localeError:rP()}}var nP=()=>{let e={string:{unit:"\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},file:{unit:"\u1794\u17C3",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},array:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},set:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u1798\u17B7\u1793\u1798\u17C2\u1793\u1787\u17B6\u179B\u17C1\u1781 (NaN)":"\u179B\u17C1\u1781";case"object":{if(Array.isArray(n))return"\u17A2\u17B6\u179A\u17C1 (Array)";if(n===null)return"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B",email:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793\u17A2\u17CA\u17B8\u1798\u17C2\u179B",url:"URL",emoji:"\u179F\u1789\u17D2\u1789\u17B6\u17A2\u17B6\u179A\u1798\u17D2\u1798\u178E\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 \u1793\u17B7\u1784\u1798\u17C9\u17C4\u1784 ISO",date:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 ISO",time:"\u1798\u17C9\u17C4\u1784 ISO",duration:"\u179A\u1799\u17C8\u1796\u17C1\u179B ISO",ipv4:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",ipv6:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",cidrv4:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",cidrv6:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",base64:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64",base64url:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64url",json_string:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A JSON",e164:"\u179B\u17C1\u1781 E.164",jwt:"JWT",template_literal:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B"};return n=>{switch(n.code){case"invalid_type":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${O(n.values[0])}`:`\u1787\u1798\u17D2\u179A\u17BE\u179F\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1787\u17B6\u1798\u17BD\u1799\u1780\u17D2\u1793\u17BB\u1784\u1785\u17C6\u178E\u17C4\u1798 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${n.maximum.toString()} ${s.unit??"\u1792\u17B6\u178F\u17BB"}`:`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin} ${i} ${n.minimum.toString()} ${s.unit}`:`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin} ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798\u178A\u17C4\u1799 "${i.prefix}"`:i.format==="ends_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1794\u1789\u17D2\u1785\u1794\u17CB\u178A\u17C4\u1799 "${i.suffix}"`:i.format==="includes"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1798\u17B6\u1793 "${i.includes}"`:i.format==="regex"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1795\u17D2\u1782\u17BC\u1795\u17D2\u1782\u1784\u1793\u17B9\u1784\u1791\u1798\u17D2\u179A\u1784\u17CB\u178A\u17C2\u179B\u1794\u17B6\u1793\u1780\u17C6\u178E\u178F\u17CB ${i.pattern}`:`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u179B\u17C1\u1781\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1787\u17B6\u1796\u17A0\u17BB\u1782\u17BB\u178E\u1793\u17C3 ${n.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${x(n.keys,", ")}`;case"invalid_key":return`\u179F\u17C4\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${n.origin}`;case"invalid_union":return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C";case"invalid_element":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${n.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}};function ny(){return{localeError:nP()}}var oP=()=>{let e={string:{unit:"\uBB38\uC790",verb:"to have"},file:{unit:"\uBC14\uC774\uD2B8",verb:"to have"},array:{unit:"\uAC1C",verb:"to have"},set:{unit:"\uAC1C",verb:"to have"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\uC785\uB825",email:"\uC774\uBA54\uC77C \uC8FC\uC18C",url:"URL",emoji:"\uC774\uBAA8\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \uB0A0\uC9DC\uC2DC\uAC04",date:"ISO \uB0A0\uC9DC",time:"ISO \uC2DC\uAC04",duration:"ISO \uAE30\uAC04",ipv4:"IPv4 \uC8FC\uC18C",ipv6:"IPv6 \uC8FC\uC18C",cidrv4:"IPv4 \uBC94\uC704",cidrv6:"IPv6 \uBC94\uC704",base64:"base64 \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",base64url:"base64url \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",json_string:"JSON \uBB38\uC790\uC5F4",e164:"E.164 \uBC88\uD638",jwt:"JWT",template_literal:"\uC785\uB825"};return n=>{switch(n.code){case"invalid_type":return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${n.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${r(n.input)}\uC785\uB2C8\uB2E4`;case"invalid_value":return n.values.length===1?`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${O(n.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC635\uC158: ${x(n.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let i=n.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",s=i==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",a=t(n.origin),c=a?.unit??"\uC694\uC18C";return a?`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${n.maximum.toString()}${c} ${i}${s}`:`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${n.maximum.toString()} ${i}${s}`}case"too_small":{let i=n.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",s=i==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",a=t(n.origin),c=a?.unit??"\uC694\uC18C";return a?`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${n.minimum.toString()}${c} ${i}${s}`:`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${n.minimum.toString()} ${i}${s}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="ends_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`:i.format==="includes"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="regex"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${i.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C ${o[i.format]??n.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${n.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${x(n.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${n.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${n.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}};function oy(){return{localeError:oP()}}var iP=()=>{let e={string:{unit:"\u0437\u043D\u0430\u0446\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},file:{unit:"\u0431\u0430\u0458\u0442\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},array:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},set:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0431\u0440\u043E\u0458";case"object":{if(Array.isArray(n))return"\u043D\u0438\u0437\u0430";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u043D\u0435\u0441",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u043D\u0430 \u0435-\u043F\u043E\u0448\u0442\u0430",url:"URL",emoji:"\u0435\u043C\u043E\u045F\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0443\u043C \u0438 \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0443\u043C",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u0432\u0440\u0435\u043C\u0435\u0442\u0440\u0430\u0435\u045A\u0435",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441\u0430",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441\u0430",cidrv4:"IPv4 \u043E\u043F\u0441\u0435\u0433",cidrv6:"IPv6 \u043E\u043F\u0441\u0435\u0433",base64:"base64-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",base64url:"base64url-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",json_string:"JSON \u043D\u0438\u0437\u0430",e164:"E.164 \u0431\u0440\u043E\u0458",jwt:"JWT",template_literal:"\u0432\u043D\u0435\u0441"};return n=>{switch(n.code){case"invalid_type":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Invalid input: expected ${O(n.values[0])}`:`\u0413\u0440\u0435\u0448\u0430\u043D\u0430 \u043E\u043F\u0446\u0438\u0458\u0430: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 \u0435\u0434\u043D\u0430 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${i}${n.maximum.toString()} ${s.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin} \u0434\u0430 \u0438\u043C\u0430 ${i}${n.minimum.toString()} ${s.unit}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u043D\u0443\u0432\u0430 \u0441\u043E "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u0432\u0440\u0448\u0443\u0432\u0430 \u0441\u043E "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0432\u043A\u043B\u0443\u0447\u0443\u0432\u0430 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u043E\u0434\u0433\u043E\u0430\u0440\u0430 \u043D\u0430 \u043F\u0430\u0442\u0435\u0440\u043D\u043E\u0442 ${i.pattern}`:`Invalid ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0431\u0440\u043E\u0458: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0431\u0438\u0434\u0435 \u0434\u0435\u043B\u0438\u0432 \u0441\u043E ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D\u0438 \u043A\u043B\u0443\u0447\u0435\u0432\u0438":"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D \u043A\u043B\u0443\u0447"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${n.origin}`;case"invalid_union":return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441";case"invalid_element":return`\u0413\u0440\u0435\u0448\u043D\u0430 \u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442 \u0432\u043E ${n.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}};function iy(){return{localeError:iP()}}var sP=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"nombor";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"alamat e-mel",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:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input tidak sah: dijangka ${n.expected}, diterima ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input tidak sah: dijangka ${O(n.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: dijangka ${n.origin??"nilai"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: dijangka ${n.origin??"nilai"} adalah ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: dijangka ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: dijangka ${n.origin} adalah ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`String tidak sah: mesti bermula dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak sah: mesti mengandungi "${i.includes}"`:i.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${i.pattern}`:`${o[i.format]??n.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${x(n.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${n.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${n.origin}`;default:return"Input tidak sah"}}};function sy(){return{localeError:sP()}}var aP=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"getal";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"invoer",email:"emailadres",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 datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return n=>{switch(n.code){case"invalid_type":return`Ongeldige invoer: verwacht ${n.expected}, ontving ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ongeldige invoer: verwacht ${O(n.values[0])}`:`Ongeldige optie: verwacht \xE9\xE9n van ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Te lang: verwacht dat ${n.origin??"waarde"} ${i}${n.maximum.toString()} ${s.unit??"elementen"} bevat`:`Te lang: verwacht dat ${n.origin??"waarde"} ${i}${n.maximum.toString()} is`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Te kort: verwacht dat ${n.origin} ${i}${n.minimum.toString()} ${s.unit} bevat`:`Te kort: verwacht dat ${n.origin} ${i}${n.minimum.toString()} is`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ongeldige tekst: moet met "${i.prefix}" beginnen`:i.format==="ends_with"?`Ongeldige tekst: moet op "${i.suffix}" eindigen`:i.format==="includes"?`Ongeldige tekst: moet "${i.includes}" bevatten`:i.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${i.pattern}`:`Ongeldig: ${o[i.format]??n.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${n.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${n.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${n.origin}`;default:return"Ongeldige invoer"}}};function ay(){return{localeError:aP()}}var cP=()=>{let e={string:{unit:"tegn",verb:"\xE5 ha"},file:{unit:"bytes",verb:"\xE5 ha"},array:{unit:"elementer",verb:"\xE5 inneholde"},set:{unit:"elementer",verb:"\xE5 inneholde"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"tall";case"object":{if(Array.isArray(n))return"liste";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"e-postadresse",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 dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Ugyldig input: forventet ${n.expected}, fikk ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ugyldig verdi: forventet ${O(n.values[0])}`:`Ugyldig valg: forventet en av ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`For stor(t): forventet ${n.origin??"value"} til \xE5 ha ${i}${n.maximum.toString()} ${s.unit??"elementer"}`:`For stor(t): forventet ${n.origin??"value"} til \xE5 ha ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`For lite(n): forventet ${n.origin} til \xE5 ha ${i}${n.minimum.toString()} ${s.unit}`:`For lite(n): forventet ${n.origin} til \xE5 ha ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ugyldig streng: m\xE5 starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: m\xE5 ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: m\xE5 inneholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: m\xE5 matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??n.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${n.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${n.origin}`;default:return"Ugyldig input"}}};function cy(){return{localeError:cP()}}var uP=()=>{let e={string:{unit:"harf",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"unsur",verb:"olmal\u0131d\u0131r"},set:{unit:"unsur",verb:"olmal\u0131d\u0131r"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"numara";case"object":{if(Array.isArray(n))return"saf";if(n===null)return"gayb";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"giren",email:"epostag\xE2h",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 heng\xE2m\u0131",date:"ISO tarihi",time:"ISO zaman\u0131",duration:"ISO m\xFCddeti",ipv4:"IPv4 ni\u015F\xE2n\u0131",ipv6:"IPv6 ni\u015F\xE2n\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\u015Fifreli metin",base64url:"base64url-\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"giren"};return n=>{switch(n.code){case"invalid_type":return`F\xE2sit giren: umulan ${n.expected}, al\u0131nan ${r(n.input)}`;case"invalid_value":return n.values.length===1?`F\xE2sit giren: umulan ${O(n.values[0])}`:`F\xE2sit tercih: m\xFBteberler ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Fazla b\xFCy\xFCk: ${n.origin??"value"}, ${i}${n.maximum.toString()} ${s.unit??"elements"} sahip olmal\u0131yd\u0131.`:`Fazla b\xFCy\xFCk: ${n.origin??"value"}, ${i}${n.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Fazla k\xFC\xE7\xFCk: ${n.origin}, ${i}${n.minimum.toString()} ${s.unit} sahip olmal\u0131yd\u0131.`:`Fazla k\xFC\xE7\xFCk: ${n.origin}, ${i}${n.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let i=n;return i.format==="starts_with"?`F\xE2sit metin: "${i.prefix}" ile ba\u015Flamal\u0131.`:i.format==="ends_with"?`F\xE2sit metin: "${i.suffix}" ile bitmeli.`:i.format==="includes"?`F\xE2sit metin: "${i.includes}" ihtiv\xE2 etmeli.`:i.format==="regex"?`F\xE2sit metin: ${i.pattern} nak\u015F\u0131na uymal\u0131.`:`F\xE2sit ${o[i.format]??n.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${n.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${n.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}};function uy(){return{localeError:uP()}}var lP=()=>{let e={string:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},file:{unit:"\u0628\u0627\u06CC\u067C\u0633",verb:"\u0648\u0644\u0631\u064A"},array:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},set:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(n))return"\u0627\u0631\u06D0";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u064A",email:"\u0628\u0631\u06CC\u069A\u0646\u0627\u0644\u06CC\u06A9",url:"\u06CC\u0648 \u0622\u0631 \u0627\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0646\u06CC\u067C\u0647 \u0627\u0648 \u0648\u062E\u062A",date:"\u0646\u06D0\u067C\u0647",time:"\u0648\u062E\u062A",duration:"\u0645\u0648\u062F\u0647",ipv4:"\u062F IPv4 \u067E\u062A\u0647",ipv6:"\u062F IPv6 \u067E\u062A\u0647",cidrv4:"\u062F IPv4 \u0633\u0627\u062D\u0647",cidrv6:"\u062F IPv6 \u0633\u0627\u062D\u0647",base64:"base64-encoded \u0645\u062A\u0646",base64url:"base64url-encoded \u0645\u062A\u0646",json_string:"JSON \u0645\u062A\u0646",e164:"\u062F E.164 \u0634\u0645\u06D0\u0631\u0647",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u064A"};return n=>{switch(n.code){case"invalid_type":return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${n.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${r(n.input)} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`;case"invalid_value":return n.values.length===1?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${O(n.values[0])} \u0648\u0627\u06CC`:`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${x(n.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${n.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${n.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} \u0648\u064A`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} ${s.unit} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} \u0648\u064A`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`:i.format==="ends_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.suffix}" \u0633\u0631\u0647 \u067E\u0627\u06CC \u062A\u0647 \u0648\u0631\u0633\u064A\u0696\u064A`:i.format==="includes"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${i.includes}" \u0648\u0644\u0631\u064A`:i.format==="regex"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F ${i.pattern} \u0633\u0631\u0647 \u0645\u0637\u0627\u0628\u0642\u062A \u0648\u0644\u0631\u064A`:`${o[i.format]??n.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${n.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${n.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${n.origin} \u06A9\u06D0`;case"invalid_union":return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A";case"invalid_element":return`\u0646\u0627\u0633\u0645 \u0639\u0646\u0635\u0631 \u067E\u0647 ${n.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}};function ly(){return{localeError:lP()}}var dP=()=>{let e={string:{unit:"znak\xF3w",verb:"mie\u0107"},file:{unit:"bajt\xF3w",verb:"mie\u0107"},array:{unit:"element\xF3w",verb:"mie\u0107"},set:{unit:"element\xF3w",verb:"mie\u0107"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"liczba";case"object":{if(Array.isArray(n))return"tablica";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"wyra\u017Cenie",email:"adres email",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:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\u0105g znak\xF3w zakodowany w formacie base64",base64url:"ci\u0105g znak\xF3w zakodowany w formacie base64url",json_string:"ci\u0105g znak\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\u015Bcie"};return n=>{switch(n.code){case"invalid_type":return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${n.expected}, otrzymano ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${O(n.values[0])}`:`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${n.maximum.toString()} ${s.unit??"element\xF3w"}`:`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${n.minimum.toString()} ${s.unit??"element\xF3w"}`:`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${i.prefix}"`:i.format==="ends_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${i.suffix}"`:i.format==="includes"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${i.includes}"`:i.format==="regex"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${i.pattern}`:`Nieprawid\u0142ow(y/a/e) ${o[i.format]??n.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${n.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${n.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${n.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}};function dy(){return{localeError:dP()}}var pP=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(n))return"array";if(n===null)return"nulo";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"padr\xE3o",email:"endere\xE7o de e-mail",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:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\xE7\xE3o ISO",ipv4:"endere\xE7o IPv4",ipv6:"endere\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Tipo inv\xE1lido: esperado ${n.expected}, recebido ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entrada inv\xE1lida: esperado ${O(n.values[0])}`:`Op\xE7\xE3o inv\xE1lida: esperada uma das ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Muito grande: esperado que ${n.origin??"valor"} tivesse ${i}${n.maximum.toString()} ${s.unit??"elementos"}`:`Muito grande: esperado que ${n.origin??"valor"} fosse ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Muito pequeno: esperado que ${n.origin} tivesse ${i}${n.minimum.toString()} ${s.unit}`:`Muito pequeno: esperado que ${n.origin} fosse ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Texto inv\xE1lido: deve come\xE7ar com "${i.prefix}"`:i.format==="ends_with"?`Texto inv\xE1lido: deve terminar com "${i.suffix}"`:i.format==="includes"?`Texto inv\xE1lido: deve incluir "${i.includes}"`:i.format==="regex"?`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${i.pattern}`:`${o[i.format]??n.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${n.divisor}`;case"unrecognized_keys":return`Chave${n.keys.length>1?"s":""} desconhecida${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${n.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${n.origin}`;default:return"Campo inv\xE1lido"}}};function py(){return{localeError:pP()}}function fy(e,t,r,o){let n=Math.abs(e),i=n%10,s=n%100;return s>=11&&s<=19?o:i===1?t:i>=2&&i<=4?r:o}var fP=()=>{let e={string:{unit:{one:"\u0441\u0438\u043C\u0432\u043E\u043B",few:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",many:"\u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u0430",many:"\u0431\u0430\u0439\u0442"},verb:"\u0438\u043C\u0435\u0442\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0441\u0438\u0432";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0438 \u0432\u0440\u0435\u043C\u044F",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u044F",duration:"ISO \u0434\u043B\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0441\u0442\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64",base64url:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64url",json_string:"JSON \u0441\u0442\u0440\u043E\u043A\u0430",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0432\u043E\u0434"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${n.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${O(n.values[0])}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0430\u0440\u0438\u0430\u043D\u0442: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0434\u043D\u043E \u0438\u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);if(s){let a=Number(n.maximum),c=fy(a,s.unit.one,s.unit.few,s.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${n.maximum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);if(s){let a=Number(n.minimum),c=fy(a,s.unit.one,s.unit.few,s.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${n.minimum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin} \u0431\u0443\u0434\u0435\u0442 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0430\u0447\u0438\u043D\u0430\u0442\u044C\u0441\u044F \u0441 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0437\u0430\u043A\u0430\u043D\u0447\u0438\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0447\u0438\u0441\u043B\u043E: \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${n.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${n.keys.length>1?"\u0438":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${n.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435";case"invalid_element":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 ${n.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}};function my(){return{localeError:fP()}}var mP=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0161tevilo";case"object":{if(Array.isArray(n))return"tabela";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"vnos",email:"e-po\u0161tni naslov",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 datum in \u010Das",date:"ISO datum",time:"ISO \u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \u0161tevilka",jwt:"JWT",template_literal:"vnos"};return n=>{switch(n.code){case"invalid_type":return`Neveljaven vnos: pri\u010Dakovano ${n.expected}, prejeto ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Neveljaven vnos: pri\u010Dakovano ${O(n.values[0])}`:`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Preveliko: pri\u010Dakovano, da bo ${n.origin??"vrednost"} imelo ${i}${n.maximum.toString()} ${s.unit??"elementov"}`:`Preveliko: pri\u010Dakovano, da bo ${n.origin??"vrednost"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Premajhno: pri\u010Dakovano, da bo ${n.origin} imelo ${i}${n.minimum.toString()} ${s.unit}`:`Premajhno: pri\u010Dakovano, da bo ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Neveljaven niz: mora se za\u010Deti z "${i.prefix}"`:i.format==="ends_with"?`Neveljaven niz: mora se kon\u010Dati z "${i.suffix}"`:i.format==="includes"?`Neveljaven niz: mora vsebovati "${i.includes}"`:i.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${i.pattern}`:`Neveljaven ${o[i.format]??n.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${n.divisor}`;case"unrecognized_keys":return`Neprepoznan${n.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${x(n.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${n.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${n.origin}`;default:return"Neveljaven vnos"}}};function hy(){return{localeError:mP()}}var hP=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\xE5lla"},set:{unit:"objekt",verb:"att inneh\xE5lla"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"antal";case"object":{if(Array.isArray(n))return"lista";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"regulj\xE4rt uttryck",email:"e-postadress",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-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\xE4ng",base64url:"base64url-kodad str\xE4ng",json_string:"JSON-str\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return n=>{switch(n.code){case"invalid_type":return`Ogiltig inmatning: f\xF6rv\xE4ntat ${n.expected}, fick ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ogiltig inmatning: f\xF6rv\xE4ntat ${O(n.values[0])}`:`Ogiltigt val: f\xF6rv\xE4ntade en av ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`F\xF6r stor(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.maximum.toString()} ${s.unit??"element"}`:`F\xF6r stor(t): f\xF6rv\xE4ntat ${n.origin??"v\xE4rdet"} att ha ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`F\xF6r lite(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.minimum.toString()} ${s.unit}`:`F\xF6r lite(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${i.prefix}"`:i.format==="ends_with"?`Ogiltig str\xE4ng: m\xE5ste sluta med "${i.suffix}"`:i.format==="includes"?`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${i.includes}"`:i.format==="regex"?`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${i.pattern}"`:`Ogiltig(t) ${o[i.format]??n.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${n.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${n.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}};function gy(){return{localeError:hP()}}var gP=()=>{let e={string:{unit:"\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},file:{unit:"\u0BAA\u0BC8\u0B9F\u0BCD\u0B9F\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},array:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},set:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u0B8E\u0BA3\u0BCD \u0B85\u0BB2\u0BCD\u0BB2\u0BBE\u0BA4\u0BA4\u0BC1":"\u0B8E\u0BA3\u0BCD";case"object":{if(Array.isArray(n))return"\u0B85\u0BA3\u0BBF";if(n===null)return"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1",email:"\u0BAE\u0BBF\u0BA9\u0BCD\u0BA9\u0B9E\u0BCD\u0B9A\u0BB2\u0BCD \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",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 \u0BA4\u0BC7\u0BA4\u0BBF \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",date:"ISO \u0BA4\u0BC7\u0BA4\u0BBF",time:"ISO \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",duration:"ISO \u0B95\u0BBE\u0BB2 \u0B85\u0BB3\u0BB5\u0BC1",ipv4:"IPv4 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",ipv6:"IPv6 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",cidrv4:"IPv4 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",cidrv6:"IPv6 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",base64:"base64-encoded \u0B9A\u0BB0\u0BAE\u0BCD",base64url:"base64url-encoded \u0B9A\u0BB0\u0BAE\u0BCD",json_string:"JSON \u0B9A\u0BB0\u0BAE\u0BCD",e164:"E.164 \u0B8E\u0BA3\u0BCD",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${O(n.values[0])}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0BB0\u0BC1\u0BAA\u0BCD\u0BAA\u0BAE\u0BCD: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${x(n.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${n.maximum.toString()} ${s.unit??"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD"} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${n.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin} ${i}${n.minimum.toString()} ${s.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin} ${i}${n.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.prefix}" \u0B87\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="ends_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.suffix}" \u0B87\u0BB2\u0BCD \u0BAE\u0BC1\u0B9F\u0BBF\u0BB5\u0B9F\u0BC8\u0BAF \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="includes"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.includes}" \u0B90 \u0B89\u0BB3\u0BCD\u0BB3\u0B9F\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="regex"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: ${i.pattern} \u0BAE\u0BC1\u0BB1\u0BC8\u0BAA\u0BBE\u0B9F\u0BCD\u0B9F\u0BC1\u0B9F\u0BA9\u0BCD \u0BAA\u0BCA\u0BB0\u0BC1\u0BA8\u0BCD\u0BA4 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${n.divisor} \u0B87\u0BA9\u0BCD \u0BAA\u0BB2\u0BAE\u0BBE\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;case"unrecognized_keys":return`\u0B85\u0B9F\u0BC8\u0BAF\u0BBE\u0BB3\u0BAE\u0BCD \u0BA4\u0BC6\u0BB0\u0BBF\u0BAF\u0BBE\u0BA4 \u0BB5\u0BBF\u0B9A\u0BC8${n.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0B9A\u0BC8`;case"invalid_union":return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1";case"invalid_element":return`${n.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1`;default:return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1"}}};function vy(){return{localeError:gP()}}var vP=()=>{let e={string:{unit:"\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},file:{unit:"\u0E44\u0E1A\u0E15\u0E4C",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},array:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},set:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 (NaN)":"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02";case"object":{if(Array.isArray(n))return"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)";if(n===null)return"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19",email:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E2D\u0E35\u0E40\u0E21\u0E25",url:"URL",emoji:"\u0E2D\u0E34\u0E42\u0E21\u0E08\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",date:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E41\u0E1A\u0E1A ISO",time:"\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",duration:"\u0E0A\u0E48\u0E27\u0E07\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",ipv4:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv4",ipv6:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv6",cidrv4:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv4",cidrv6:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv6",base64:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64",base64url:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64 \u0E2A\u0E33\u0E2B\u0E23\u0E31\u0E1A URL",json_string:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A JSON",e164:"\u0E40\u0E1A\u0E2D\u0E23\u0E4C\u0E42\u0E17\u0E23\u0E28\u0E31\u0E1E\u0E17\u0E4C\u0E23\u0E30\u0E2B\u0E27\u0E48\u0E32\u0E07\u0E1B\u0E23\u0E30\u0E40\u0E17\u0E28 (E.164)",jwt:"\u0E42\u0E17\u0E40\u0E04\u0E19 JWT",template_literal:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19"};return n=>{switch(n.code){case"invalid_type":return`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${n.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${O(n.values[0])}`:`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19\u0E2B\u0E19\u0E36\u0E48\u0E07\u0E43\u0E19 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",s=t(n.origin);return s?`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.maximum.toString()} ${s.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`:`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",s=t(n.origin);return s?`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.minimum.toString()} ${s.unit}`:`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E02\u0E36\u0E49\u0E19\u0E15\u0E49\u0E19\u0E14\u0E49\u0E27\u0E22 "${i.prefix}"`:i.format==="ends_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E25\u0E07\u0E17\u0E49\u0E32\u0E22\u0E14\u0E49\u0E27\u0E22 "${i.suffix}"`:i.format==="includes"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E21\u0E35 "${i.includes}" \u0E2D\u0E22\u0E39\u0E48\u0E43\u0E19\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21`:i.format==="regex"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14 ${i.pattern}`:`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E40\u0E1B\u0E47\u0E19\u0E08\u0E33\u0E19\u0E27\u0E19\u0E17\u0E35\u0E48\u0E2B\u0E32\u0E23\u0E14\u0E49\u0E27\u0E22 ${n.divisor} \u0E44\u0E14\u0E49\u0E25\u0E07\u0E15\u0E31\u0E27`;case"unrecognized_keys":return`\u0E1E\u0E1A\u0E04\u0E35\u0E22\u0E4C\u0E17\u0E35\u0E48\u0E44\u0E21\u0E48\u0E23\u0E39\u0E49\u0E08\u0E31\u0E01: ${x(n.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${n.origin}`;case"invalid_union":return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E44\u0E21\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E22\u0E39\u0E40\u0E19\u0E35\u0E22\u0E19\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E44\u0E27\u0E49";case"invalid_element":return`\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${n.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}};function _y(){return{localeError:vP()}}var _P=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},yP=()=>{let e={string:{unit:"karakter",verb:"olmal\u0131"},file:{unit:"bayt",verb:"olmal\u0131"},array:{unit:"\xF6\u011Fe",verb:"olmal\u0131"},set:{unit:"\xF6\u011Fe",verb:"olmal\u0131"}};function t(o){return e[o]??null}let r={regex:"girdi",email:"e-posta adresi",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 tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\u0131\u011F\u0131",cidrv6:"IPv6 aral\u0131\u011F\u0131",base64:"base64 ile \u015Fifrelenmi\u015F metin",base64url:"base64url ile \u015Fifrelenmi\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"\u015Eablon dizesi"};return o=>{switch(o.code){case"invalid_type":return`Ge\xE7ersiz de\u011Fer: beklenen ${o.expected}, al\u0131nan ${_P(o.input)}`;case"invalid_value":return o.values.length===1?`Ge\xE7ersiz de\u011Fer: beklenen ${O(o.values[0])}`:`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${n}${o.maximum.toString()} ${i.unit??"\xF6\u011Fe"}`:`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${n}${o.minimum.toString()} ${i.unit}`:`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Ge\xE7ersiz metin: "${n.prefix}" ile ba\u015Flamal\u0131`:n.format==="ends_with"?`Ge\xE7ersiz metin: "${n.suffix}" ile bitmeli`:n.format==="includes"?`Ge\xE7ersiz metin: "${n.includes}" i\xE7ermeli`:n.format==="regex"?`Ge\xE7ersiz metin: ${n.pattern} desenine uymal\u0131`:`Ge\xE7ersiz ${r[n.format]??o.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${o.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${o.keys.length>1?"lar":""}: ${x(o.keys,", ")}`;case"invalid_key":return`${o.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${o.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}};function yy(){return{localeError:yP()}}var $P=()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},file:{unit:"\u0431\u0430\u0439\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0438\u0432";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u0435\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0457 \u043F\u043E\u0448\u0442\u0438",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0434\u0430\u0442\u0430 \u0442\u0430 \u0447\u0430\u0441 ISO",date:"\u0434\u0430\u0442\u0430 ISO",time:"\u0447\u0430\u0441 ISO",duration:"\u0442\u0440\u0438\u0432\u0430\u043B\u0456\u0441\u0442\u044C ISO",ipv4:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv4",ipv6:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv6",cidrv4:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv4",cidrv6:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv6",base64:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64",base64url:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64url",json_string:"\u0440\u044F\u0434\u043E\u043A JSON",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${n.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${O(n.values[0])}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0430 \u043E\u043F\u0446\u0456\u044F: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F \u043E\u0434\u043D\u0435 \u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin} \u0431\u0443\u0434\u0435 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043F\u043E\u0447\u0438\u043D\u0430\u0442\u0438\u0441\u044F \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0437\u0430\u043A\u0456\u043D\u0447\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043C\u0456\u0441\u0442\u0438\u0442\u0438 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u0430\u0442\u0438 \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0447\u0438\u0441\u043B\u043E: \u043F\u043E\u0432\u0438\u043D\u043D\u043E \u0431\u0443\u0442\u0438 \u043A\u0440\u0430\u0442\u043D\u0438\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${n.keys.length>1?"\u0456":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${n.origin}`;case"invalid_union":return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456";case"invalid_element":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F \u0443 ${n.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}};function $y(){return{localeError:$P()}}var bP=()=>{let e={string:{unit:"\u062D\u0631\u0648\u0641",verb:"\u06C1\u0648\u0646\u0627"},file:{unit:"\u0628\u0627\u0626\u0679\u0633",verb:"\u06C1\u0648\u0646\u0627"},array:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"},set:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0646\u0645\u0628\u0631";case"object":{if(Array.isArray(n))return"\u0622\u0631\u06D2";if(n===null)return"\u0646\u0644";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0627\u0646 \u067E\u0679",email:"\u0627\u06CC \u0645\u06CC\u0644 \u0627\u06CC\u0688\u0631\u06CC\u0633",url:"\u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",uuidv4:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 4",uuidv6:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 6",nanoid:"\u0646\u06CC\u0646\u0648 \u0622\u0626\u06CC \u0688\u06CC",guid:"\u062C\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid2:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC 2",ulid:"\u06CC\u0648 \u0627\u06CC\u0644 \u0622\u0626\u06CC \u0688\u06CC",xid:"\u0627\u06CC\u06A9\u0633 \u0622\u0626\u06CC \u0688\u06CC",ksuid:"\u06A9\u06D2 \u0627\u06CC\u0633 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",datetime:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0688\u06CC\u0679 \u0679\u0627\u0626\u0645",date:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u062A\u0627\u0631\u06CC\u062E",time:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0648\u0642\u062A",duration:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0645\u062F\u062A",ipv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0627\u06CC\u0688\u0631\u06CC\u0633",ipv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0627\u06CC\u0688\u0631\u06CC\u0633",cidrv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0631\u06CC\u0646\u062C",cidrv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0631\u06CC\u0646\u062C",base64:"\u0628\u06CC\u0633 64 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",base64url:"\u0628\u06CC\u0633 64 \u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",json_string:"\u062C\u06D2 \u0627\u06CC\u0633 \u0627\u0648 \u0627\u06CC\u0646 \u0633\u0679\u0631\u0646\u06AF",e164:"\u0627\u06CC 164 \u0646\u0645\u0628\u0631",jwt:"\u062C\u06D2 \u0688\u0628\u0644\u06CC\u0648 \u0679\u06CC",template_literal:"\u0627\u0646 \u067E\u0679"};return n=>{switch(n.code){case"invalid_type":return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${n.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${r(n.input)} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`;case"invalid_value":return n.values.length===1?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${O(n.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`:`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${x(n.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0628\u06C1\u062A \u0628\u0691\u0627: ${n.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0628\u0691\u0627: ${n.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${i}${n.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${n.origin} \u06A9\u06D2 ${i}${n.minimum.toString()} ${s.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${n.origin} \u06A9\u0627 ${i}${n.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.prefix}" \u0633\u06D2 \u0634\u0631\u0648\u0639 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="ends_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="includes"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="regex"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: \u067E\u06CC\u0679\u0631\u0646 ${i.pattern} \u0633\u06D2 \u0645\u06CC\u0686 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:`\u063A\u0644\u0637 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${n.divisor} \u06A9\u0627 \u0645\u0636\u0627\u0639\u0641 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;case"unrecognized_keys":return`\u063A\u06CC\u0631 \u062A\u0633\u0644\u06CC\u0645 \u0634\u062F\u06C1 \u06A9\u06CC${n.keys.length>1?"\u0632":""}: ${x(n.keys,"\u060C ")}`;case"invalid_key":return`${n.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${n.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}};function by(){return{localeError:bP()}}var wP=()=>{let e={string:{unit:"k\xFD t\u1EF1",verb:"c\xF3"},file:{unit:"byte",verb:"c\xF3"},array:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"},set:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"s\u1ED1";case"object":{if(Array.isArray(n))return"m\u1EA3ng";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0111\u1EA7u v\xE0o",email:"\u0111\u1ECBa ch\u1EC9 email",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:"ng\xE0y gi\u1EDD ISO",date:"ng\xE0y ISO",time:"gi\u1EDD ISO",duration:"kho\u1EA3ng th\u1EDDi gian ISO",ipv4:"\u0111\u1ECBa ch\u1EC9 IPv4",ipv6:"\u0111\u1ECBa ch\u1EC9 IPv6",cidrv4:"d\u1EA3i IPv4",cidrv6:"d\u1EA3i IPv6",base64:"chu\u1ED7i m\xE3 h\xF3a base64",base64url:"chu\u1ED7i m\xE3 h\xF3a base64url",json_string:"chu\u1ED7i JSON",e164:"s\u1ED1 E.164",jwt:"JWT",template_literal:"\u0111\u1EA7u v\xE0o"};return n=>{switch(n.code){case"invalid_type":return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${n.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${O(n.values[0])}`:`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${n.origin??"gi\xE1 tr\u1ECB"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"ph\u1EA7n t\u1EED"}`:`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${n.origin??"gi\xE1 tr\u1ECB"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${i.prefix}"`:i.format==="ends_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${i.suffix}"`:i.format==="includes"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${i.includes}"`:i.format==="regex"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${i.pattern}`:`${o[i.format]??n.format} kh\xF4ng h\u1EE3p l\u1EC7`}case"not_multiple_of":return`S\u1ED1 kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i l\xE0 b\u1ED9i s\u1ED1 c\u1EE7a ${n.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${x(n.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${n.origin}`;case"invalid_union":return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7";case"invalid_element":return`Gi\xE1 tr\u1ECB kh\xF4ng h\u1EE3p l\u1EC7 trong ${n.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}};function wy(){return{localeError:wP()}}var kP=()=>{let e={string:{unit:"\u5B57\u7B26",verb:"\u5305\u542B"},file:{unit:"\u5B57\u8282",verb:"\u5305\u542B"},array:{unit:"\u9879",verb:"\u5305\u542B"},set:{unit:"\u9879",verb:"\u5305\u542B"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u975E\u6570\u5B57(NaN)":"\u6570\u5B57";case"object":{if(Array.isArray(n))return"\u6570\u7EC4";if(n===null)return"\u7A7A\u503C(null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u8F93\u5165",email:"\u7535\u5B50\u90AE\u4EF6",url:"URL",emoji:"\u8868\u60C5\u7B26\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u671F\u65F6\u95F4",date:"ISO\u65E5\u671F",time:"ISO\u65F6\u95F4",duration:"ISO\u65F6\u957F",ipv4:"IPv4\u5730\u5740",ipv6:"IPv6\u5730\u5740",cidrv4:"IPv4\u7F51\u6BB5",cidrv6:"IPv6\u7F51\u6BB5",base64:"base64\u7F16\u7801\u5B57\u7B26\u4E32",base64url:"base64url\u7F16\u7801\u5B57\u7B26\u4E32",json_string:"JSON\u5B57\u7B26\u4E32",e164:"E.164\u53F7\u7801",jwt:"JWT",template_literal:"\u8F93\u5165"};return n=>{switch(n.code){case"invalid_type":return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${n.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${O(n.values[0])}`:`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${n.origin??"\u503C"} ${i}${n.maximum.toString()} ${s.unit??"\u4E2A\u5143\u7D20"}`:`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${n.origin??"\u503C"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${n.origin} ${i}${n.minimum.toString()} ${s.unit}`:`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.prefix}" \u5F00\u5934`:i.format==="ends_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.suffix}" \u7ED3\u5C3E`:i.format==="includes"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${i.pattern}`:`\u65E0\u6548${o[i.format]??n.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${n.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${n.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}};function ky(){return{localeError:kP()}}var xP=()=>{let e={string:{unit:"\u5B57\u5143",verb:"\u64C1\u6709"},file:{unit:"\u4F4D\u5143\u7D44",verb:"\u64C1\u6709"},array:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"},set:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u8F38\u5165",email:"\u90F5\u4EF6\u5730\u5740",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 \u65E5\u671F\u6642\u9593",date:"ISO \u65E5\u671F",time:"ISO \u6642\u9593",duration:"ISO \u671F\u9593",ipv4:"IPv4 \u4F4D\u5740",ipv6:"IPv6 \u4F4D\u5740",cidrv4:"IPv4 \u7BC4\u570D",cidrv6:"IPv6 \u7BC4\u570D",base64:"base64 \u7DE8\u78BC\u5B57\u4E32",base64url:"base64url \u7DE8\u78BC\u5B57\u4E32",json_string:"JSON \u5B57\u4E32",e164:"E.164 \u6578\u503C",jwt:"JWT",template_literal:"\u8F38\u5165"};return n=>{switch(n.code){case"invalid_type":return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${n.expected}\uFF0C\u4F46\u6536\u5230 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${O(n.values[0])}`:`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${n.origin??"\u503C"} \u61C9\u70BA ${i}${n.maximum.toString()} ${s.unit??"\u500B\u5143\u7D20"}`:`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${n.origin??"\u503C"} \u61C9\u70BA ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${n.origin} \u61C9\u70BA ${i}${n.minimum.toString()} ${s.unit}`:`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${n.origin} \u61C9\u70BA ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.prefix}" \u958B\u982D`:i.format==="ends_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.suffix}" \u7D50\u5C3E`:i.format==="includes"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${i.pattern}`:`\u7121\u6548\u7684 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${n.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${n.keys.length>1?"\u5011":""}\uFF1A${x(n.keys,"\u3001")}`;case"invalid_key":return`${n.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${n.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}};function xy(){return{localeError:xP()}}var tu=Symbol("ZodOutput"),ru=Symbol("ZodInput"),yo=class{constructor(){this._map=new Map,this._idmap=new Map}add(t,...r){let o=r[0];if(this._map.set(t,o),o&&typeof o=="object"&&"id"in o){if(this._idmap.has(o.id))throw new Error(`ID ${o.id} already exists in the registry`);this._idmap.set(o.id,t)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(t){let r=this._map.get(t);return r&&typeof r=="object"&&"id"in r&&this._idmap.delete(r.id),this._map.delete(t),this}get(t){let r=t._zod.parent;if(r){let o={...this.get(r)??{}};return delete o.id,{...o,...this._map.get(t)}}return this._map.get(t)}has(t){return this._map.has(t)}};function Di(){return new yo}var Gt=Di();function nu(e,t){return new e({type:"string",...I(t)})}function af(e,t){return new e({type:"string",coerce:!0,...I(t)})}function qi(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...I(t)})}function $o(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...I(t)})}function Mi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...I(t)})}function Ui(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...I(t)})}function Zi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...I(t)})}function Li(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...I(t)})}function Vi(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...I(t)})}function Fi(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...I(t)})}function Gi(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...I(t)})}function Wi(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...I(t)})}function Ki(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...I(t)})}function Hi(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...I(t)})}function Ji(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...I(t)})}function Bi(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...I(t)})}function Yi(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...I(t)})}function Xi(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...I(t)})}function Qi(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...I(t)})}function es(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...I(t)})}function ts(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...I(t)})}function rs(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...I(t)})}function ns(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...I(t)})}function os(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...I(t)})}var ou={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function cf(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...I(t)})}function uf(e,t){return new e({type:"string",format:"date",check:"string_format",...I(t)})}function lf(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...I(t)})}function df(e,t){return new e({type:"string",format:"duration",check:"string_format",...I(t)})}function iu(e,t){return new e({type:"number",checks:[],...I(t)})}function pf(e,t){return new e({type:"number",coerce:!0,checks:[],...I(t)})}function su(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...I(t)})}function au(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...I(t)})}function cu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...I(t)})}function uu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...I(t)})}function lu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...I(t)})}function du(e,t){return new e({type:"boolean",...I(t)})}function ff(e,t){return new e({type:"boolean",coerce:!0,...I(t)})}function pu(e,t){return new e({type:"bigint",...I(t)})}function mf(e,t){return new e({type:"bigint",coerce:!0,...I(t)})}function fu(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...I(t)})}function mu(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...I(t)})}function hu(e,t){return new e({type:"symbol",...I(t)})}function gu(e,t){return new e({type:"undefined",...I(t)})}function vu(e,t){return new e({type:"null",...I(t)})}function _u(e){return new e({type:"any"})}function kn(e){return new e({type:"unknown"})}function yu(e,t){return new e({type:"never",...I(t)})}function $u(e,t){return new e({type:"void",...I(t)})}function bu(e,t){return new e({type:"date",...I(t)})}function hf(e,t){return new e({type:"date",coerce:!0,...I(t)})}function wu(e,t){return new e({type:"nan",...I(t)})}function br(e,t){return new ec({check:"less_than",...I(t),value:e,inclusive:!1})}function It(e,t){return new ec({check:"less_than",...I(t),value:e,inclusive:!0})}function wr(e,t){return new tc({check:"greater_than",...I(t),value:e,inclusive:!1})}function ht(e,t){return new tc({check:"greater_than",...I(t),value:e,inclusive:!0})}function gf(e){return wr(0,e)}function vf(e){return br(0,e)}function _f(e){return It(0,e)}function yf(e){return ht(0,e)}function xn(e,t){return new Cp({check:"multiple_of",...I(t),value:e})}function bo(e,t){return new qp({check:"max_size",...I(t),maximum:e})}function Sn(e,t){return new Mp({check:"min_size",...I(t),minimum:e})}function is(e,t){return new Up({check:"size_equals",...I(t),size:e})}function wo(e,t){return new Zp({check:"max_length",...I(t),maximum:e})}function Fr(e,t){return new Lp({check:"min_length",...I(t),minimum:e})}function ko(e,t){return new Vp({check:"length_equals",...I(t),length:e})}function ss(e,t){return new Fp({check:"string_format",format:"regex",...I(t),pattern:e})}function as(e){return new Gp({check:"string_format",format:"lowercase",...I(e)})}function cs(e){return new Wp({check:"string_format",format:"uppercase",...I(e)})}function us(e,t){return new Kp({check:"string_format",format:"includes",...I(t),includes:e})}function ls(e,t){return new Hp({check:"string_format",format:"starts_with",...I(t),prefix:e})}function ds(e,t){return new Jp({check:"string_format",format:"ends_with",...I(t),suffix:e})}function $f(e,t,r){return new Bp({check:"property",property:e,schema:t,...I(r)})}function ps(e,t){return new Yp({check:"mime_type",mime:e,...I(t)})}function kr(e){return new Xp({check:"overwrite",tx:e})}function fs(e){return kr(t=>t.normalize(e))}function ms(){return kr(e=>e.trim())}function hs(){return kr(e=>e.toLowerCase())}function gs(){return kr(e=>e.toUpperCase())}function vs(e,t,r){return new e({type:"array",element:t,...I(r)})}function SP(e,t,r){return new e({type:"union",options:t,...I(r)})}function TP(e,t,r,o){return new e({type:"union",options:r,discriminator:t,...I(o)})}function PP(e,t,r){return new e({type:"intersection",left:t,right:r})}function bf(e,t,r,o){let n=r instanceof W,i=n?o:r,s=n?r:null;return new e({type:"tuple",items:t,rest:s,...I(i)})}function zP(e,t,r,o){return new e({type:"record",keyType:t,valueType:r,...I(o)})}function EP(e,t,r,o){return new e({type:"map",keyType:t,valueType:r,...I(o)})}function IP(e,t,r){return new e({type:"set",valueType:t,...I(r)})}function jP(e,t,r){let o=Array.isArray(t)?Object.fromEntries(t.map(n=>[n,n])):t;return new e({type:"enum",entries:o,...I(r)})}function OP(e,t,r){return new e({type:"enum",entries:t,...I(r)})}function NP(e,t,r){return new e({type:"literal",values:Array.isArray(t)?t:[t],...I(r)})}function ku(e,t){return new e({type:"file",...I(t)})}function RP(e,t){return new e({type:"transform",transform:t})}function CP(e,t){return new e({type:"optional",innerType:t})}function AP(e,t){return new e({type:"nullable",innerType:t})}function DP(e,t,r){return new e({type:"default",innerType:t,get defaultValue(){return typeof r=="function"?r():r}})}function qP(e,t,r){return new e({type:"nonoptional",innerType:t,...I(r)})}function MP(e,t){return new e({type:"success",innerType:t})}function UP(e,t,r){return new e({type:"catch",innerType:t,catchValue:typeof r=="function"?r:()=>r})}function ZP(e,t,r){return new e({type:"pipe",in:t,out:r})}function LP(e,t){return new e({type:"readonly",innerType:t})}function VP(e,t,r){return new e({type:"template_literal",parts:t,...I(r)})}function FP(e,t){return new e({type:"lazy",getter:t})}function GP(e,t){return new e({type:"promise",innerType:t})}function xu(e,t,r){let o=I(r);return o.abort??(o.abort=!0),new e({type:"custom",check:"custom",fn:t,...o})}function Su(e,t,r){return new e({type:"custom",check:"custom",fn:t,...I(r)})}function Tu(e,t){let r=I(t),o=r.truthy??["true","1","yes","on","y","enabled"],n=r.falsy??["false","0","no","off","n","disabled"];r.case!=="sensitive"&&(o=o.map(p=>typeof p=="string"?p.toLowerCase():p),n=n.map(p=>typeof p=="string"?p.toLowerCase():p));let i=new Set(o),s=new Set(n),a=e.Pipe??vo,c=e.Boolean??mo,u=e.String??Lr,l=e.Transform??go,d=new l({type:"transform",transform:(p,f)=>{let g=p;return r.case!=="sensitive"&&(g=g.toLowerCase()),i.has(g)?!0:s.has(g)?!1:(f.issues.push({code:"invalid_value",expected:"stringbool",values:[...i,...s],input:f.value,inst:d}),{})},error:r.error}),h=new a({type:"pipe",in:new u({type:"string",error:r.error}),out:d,error:r.error});return new a({type:"pipe",in:h,out:new c({type:"boolean",error:r.error}),error:r.error})}function Pu(e,t,r,o={}){let n=I(o),i={...I(o),check:"string_format",type:"string",format:t,fn:typeof r=="function"?r:a=>r.test(a),...n};return r instanceof RegExp&&(i.pattern=r),new e(i)}var zu=class{constructor(t){this._def=t,this.def=t}implement(t){if(typeof t!="function")throw new Error("implement() must be called with a function");let r=((...o)=>{let n=this._def.input?yn(this._def.input,o,void 0,{callee:r}):o;if(!Array.isArray(n))throw new Error("Invalid arguments schema: not an array or tuple schema.");let i=t(...n);return this._def.output?yn(this._def.output,i,void 0,{callee:r}):i});return r}implementAsync(t){if(typeof t!="function")throw new Error("implement() must be called with a function");let r=(async(...o)=>{let n=this._def.input?await $n(this._def.input,o,void 0,{callee:r}):o;if(!Array.isArray(n))throw new Error("Invalid arguments schema: not an array or tuple schema.");let i=await t(...n);return this._def.output?$n(this._def.output,i,void 0,{callee:r}):i});return r}input(...t){let r=this.constructor;return Array.isArray(t[0])?new r({type:"function",input:new Vr({type:"tuple",items:t[0],rest:t[1]}),output:this._def.output}):new r({type:"function",input:t[0],output:this._def.output})}output(t){let r=this.constructor;return new r({type:"function",input:this._def.input,output:t})}};function Eu(e){return new zu({type:"function",input:Array.isArray(e?.input)?bf(Vr,e?.input):e?.input??vs(ho,kn(wn)),output:e?.output??kn(wn)})}var _s=class{constructor(t){this.counter=0,this.metadataRegistry=t?.metadata??Gt,this.target=t?.target??"draft-2020-12",this.unrepresentable=t?.unrepresentable??"throw",this.override=t?.override??(()=>{}),this.io=t?.io??"output",this.seen=new Map}process(t,r={path:[],schemaPath:[]}){var o;let n=t._zod.def,i={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},s=this.seen.get(t);if(s)return s.count++,r.schemaPath.includes(t)&&(s.cycle=r.path),s.schema;let a={schema:{},count:1,cycle:void 0,path:r.path};this.seen.set(t,a);let c=t._zod.toJSONSchema?.();if(c)a.schema=c;else{let d={...r,schemaPath:[...r.schemaPath,t],path:r.path},h=t._zod.parent;if(h)a.ref=h,this.process(h,d),this.seen.get(h).isParent=!0;else{let m=a.schema;switch(n.type){case"string":{let p=m;p.type="string";let{minimum:f,maximum:g,format:y,patterns:w,contentEncoding:k}=t._zod.bag;if(typeof f=="number"&&(p.minLength=f),typeof g=="number"&&(p.maxLength=g),y&&(p.format=i[y]??y,p.format===""&&delete p.format),k&&(p.contentEncoding=k),w&&w.size>0){let E=[...w];E.length===1?p.pattern=E[0].source:E.length>1&&(a.schema.allOf=[...E.map(P=>({...this.target==="draft-7"?{type:"string"}:{},pattern:P.source}))])}break}case"number":{let p=m,{minimum:f,maximum:g,format:y,multipleOf:w,exclusiveMaximum:k,exclusiveMinimum:E}=t._zod.bag;typeof y=="string"&&y.includes("int")?p.type="integer":p.type="number",typeof E=="number"&&(p.exclusiveMinimum=E),typeof f=="number"&&(p.minimum=f,typeof E=="number"&&(E>=f?delete p.minimum:delete p.exclusiveMinimum)),typeof k=="number"&&(p.exclusiveMaximum=k),typeof g=="number"&&(p.maximum=g,typeof k=="number"&&(k<=g?delete p.maximum:delete p.exclusiveMaximum)),typeof w=="number"&&(p.multipleOf=w);break}case"boolean":{let p=m;p.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new 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 new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{m.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let p=m,{minimum:f,maximum:g}=t._zod.bag;typeof f=="number"&&(p.minItems=f),typeof g=="number"&&(p.maxItems=g),p.type="array",p.items=this.process(n.element,{...d,path:[...d.path,"items"]});break}case"object":{let p=m;p.type="object",p.properties={};let f=n.shape;for(let w in f)p.properties[w]=this.process(f[w],{...d,path:[...d.path,"properties",w]});let g=new Set(Object.keys(f)),y=new Set([...g].filter(w=>{let k=n.shape[w]._zod;return this.io==="input"?k.optin===void 0:k.optout===void 0}));y.size>0&&(p.required=Array.from(y)),n.catchall?._zod.def.type==="never"?p.additionalProperties=!1:n.catchall?n.catchall&&(p.additionalProperties=this.process(n.catchall,{...d,path:[...d.path,"additionalProperties"]})):this.io==="output"&&(p.additionalProperties=!1);break}case"union":{let p=m;p.anyOf=n.options.map((f,g)=>this.process(f,{...d,path:[...d.path,"anyOf",g]}));break}case"intersection":{let p=m,f=this.process(n.left,{...d,path:[...d.path,"allOf",0]}),g=this.process(n.right,{...d,path:[...d.path,"allOf",1]}),y=k=>"allOf"in k&&Object.keys(k).length===1,w=[...y(f)?f.allOf:[f],...y(g)?g.allOf:[g]];p.allOf=w;break}case"tuple":{let p=m;p.type="array";let f=n.items.map((w,k)=>this.process(w,{...d,path:[...d.path,"prefixItems",k]}));if(this.target==="draft-2020-12"?p.prefixItems=f:p.items=f,n.rest){let w=this.process(n.rest,{...d,path:[...d.path,"items"]});this.target==="draft-2020-12"?p.items=w:p.additionalItems=w}n.rest&&(p.items=this.process(n.rest,{...d,path:[...d.path,"items"]}));let{minimum:g,maximum:y}=t._zod.bag;typeof g=="number"&&(p.minItems=g),typeof y=="number"&&(p.maxItems=y);break}case"record":{let p=m;p.type="object",p.propertyNames=this.process(n.keyType,{...d,path:[...d.path,"propertyNames"]}),p.additionalProperties=this.process(n.valueType,{...d,path:[...d.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let p=m,f=Si(n.entries);f.every(g=>typeof g=="number")&&(p.type="number"),f.every(g=>typeof g=="string")&&(p.type="string"),p.enum=f;break}case"literal":{let p=m,f=[];for(let g of n.values)if(g===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof g=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");f.push(Number(g))}else f.push(g);if(f.length!==0)if(f.length===1){let g=f[0];p.type=g===null?"null":typeof g,p.const=g}else f.every(g=>typeof g=="number")&&(p.type="number"),f.every(g=>typeof g=="string")&&(p.type="string"),f.every(g=>typeof g=="boolean")&&(p.type="string"),f.every(g=>g===null)&&(p.type="null"),p.enum=f;break}case"file":{let p=m,f={type:"string",format:"binary",contentEncoding:"binary"},{minimum:g,maximum:y,mime:w}=t._zod.bag;g!==void 0&&(f.minLength=g),y!==void 0&&(f.maxLength=y),w?w.length===1?(f.contentMediaType=w[0],Object.assign(p,f)):p.anyOf=w.map(k=>({...f,contentMediaType:k})):Object.assign(p,f);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let p=this.process(n.innerType,d);m.anyOf=[p,{type:"null"}];break}case"nonoptional":{this.process(n.innerType,d),a.ref=n.innerType;break}case"success":{let p=m;p.type="boolean";break}case"default":{this.process(n.innerType,d),a.ref=n.innerType,m.default=JSON.parse(JSON.stringify(n.defaultValue));break}case"prefault":{this.process(n.innerType,d),a.ref=n.innerType,this.io==="input"&&(m._prefault=JSON.parse(JSON.stringify(n.defaultValue)));break}case"catch":{this.process(n.innerType,d),a.ref=n.innerType;let p;try{p=n.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}m.default=p;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let p=m,f=t._zod.pattern;if(!f)throw new Error("Pattern not found in template literal");p.type="string",p.pattern=f.source;break}case"pipe":{let p=this.io==="input"?n.in._zod.def.type==="transform"?n.out:n.in:n.out;this.process(p,d),a.ref=p;break}case"readonly":{this.process(n.innerType,d),a.ref=n.innerType,m.readOnly=!0;break}case"promise":{this.process(n.innerType,d),a.ref=n.innerType;break}case"optional":{this.process(n.innerType,d),a.ref=n.innerType;break}case"lazy":{let p=t._zod.innerType;this.process(p,d),a.ref=p;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}default:}}}let u=this.metadataRegistry.get(t);return u&&Object.assign(a.schema,u),this.io==="input"&&Fe(t)&&(delete a.schema.examples,delete a.schema.default),this.io==="input"&&a.schema._prefault&&((o=a.schema).default??(o.default=a.schema._prefault)),delete a.schema._prefault,this.seen.get(t).schema}emit(t,r){let o={cycles:r?.cycles??"ref",reused:r?.reused??"inline",external:r?.external??void 0},n=this.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");let i=l=>{let d=this.target==="draft-2020-12"?"$defs":"definitions";if(o.external){let f=o.external.registry.get(l[0])?.id,g=o.external.uri??(w=>w);if(f)return{ref:g(f)};let y=l[1].defId??l[1].schema.id??`schema${this.counter++}`;return l[1].defId=y,{defId:y,ref:`${g("__shared")}#/${d}/${y}`}}if(l[1]===n)return{ref:"#"};let m=`#/${d}/`,p=l[1].schema.id??`__schema${this.counter++}`;return{defId:p,ref:m+p}},s=l=>{if(l[1].schema.$ref)return;let d=l[1],{ref:h,defId:m}=i(l);d.def={...d.schema},m&&(d.defId=m);let p=d.schema;for(let f in p)delete p[f];p.$ref=h};if(o.cycles==="throw")for(let l of this.seen.entries()){let d=l[1];if(d.cycle)throw new Error(`Cycle detected: #/${d.cycle?.join("/")}/<root>
42
+ })));`),h.write(`newResult[${vn(w)}] = ${k}.value`)}h.write("payload.value = newResult;"),h.write("return payload;");let y=h.compile();return(w,k)=>y(d,w,k)},n,i=ao,s=!xi.jitless,c=s&&rp.value,u=t.catchall,l;e._zod.parse=(d,h)=>{l??(l=r.value);let m=d.value;if(!i(m))return d.issues.push({expected:"object",code:"invalid_type",input:m,inst:e}),d;let p=[];if(s&&c&&h?.async===!1&&h.jitless!==!0)n||(n=o(t.shape)),d=n(d,h);else{d.value={};let k=l.shape;for(let E of l.keys){let P=k[E],ze=P._zod.run({value:m[E],issues:[]},h),Me=P._zod.optin==="optional"&&P._zod.optout==="optional";ze instanceof Promise?p.push(ze.then(ir=>Me?P_(ir,d,E,m):ic(ir,d,E))):Me?P_(ze,d,E,m):ic(ze,d,E)}}if(!u)return p.length?Promise.all(p).then(()=>d):d;let f=[],v=l.keySet,y=u._zod,w=y.def.type;for(let k of Object.keys(m)){if(v.has(k))continue;if(w==="never"){f.push(k);continue}let E=y.run({value:m[k],issues:[]},h);E instanceof Promise?p.push(E.then(P=>ic(P,d,k))):ic(E,d,k)}return f.length&&d.issues.push({code:"unrecognized_keys",keys:f,input:m,inst:e}),p.length?Promise.all(p).then(()=>d):d}});function z_(e,t,r,o){for(let n of e)if(n.issues.length===0)return t.value=n.value,t;return t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map(n=>n.issues.map(i=>Et(i,o,Ue())))}),t}var Di=_("$ZodUnion",(e,t)=>{W.init(e,t),_e(e._zod,"optin",()=>t.options.some(r=>r._zod.optin==="optional")?"optional":void 0),_e(e._zod,"optout",()=>t.options.some(r=>r._zod.optout==="optional")?"optional":void 0),_e(e._zod,"values",()=>{if(t.options.every(r=>r._zod.values))return new Set(t.options.flatMap(r=>Array.from(r._zod.values)))}),_e(e._zod,"pattern",()=>{if(t.options.every(r=>r._zod.pattern)){let r=t.options.map(o=>o._zod.pattern);return new RegExp(`^(${r.map(o=>zi(o.source)).join("|")})$`)}}),e._zod.parse=(r,o)=>{let n=!1,i=[];for(let s of t.options){let a=s._zod.run({value:r.value,issues:[]},o);if(a instanceof Promise)i.push(a),n=!0;else{if(a.issues.length===0)return a;i.push(a)}}return n?Promise.all(i).then(s=>z_(s,r,e,o)):z_(i,r,e,o)}}),Ac=_("$ZodDiscriminatedUnion",(e,t)=>{Di.init(e,t);let r=e._zod.parse;_e(e._zod,"propValues",()=>{let n={};for(let i of t.options){let s=i._zod.propValues;if(!s||Object.keys(s).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[a,c]of Object.entries(s)){n[a]||(n[a]=new Set);for(let u of c)n[a].add(u)}}return n});let o=Pi(()=>{let n=t.options,i=new Map;for(let s of n){let a=s._zod.propValues[t.discriminator];if(!a||a.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(let c of a){if(i.has(c))throw new Error(`Duplicate discriminator value "${String(c)}"`);i.set(c,s)}}return i});e._zod.parse=(n,i)=>{let s=n.value;if(!ao(s))return n.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),n;let a=o.value.get(s?.[t.discriminator]);return a?a._zod.run(n,i):t.unionFallback?r(n,i):(n.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",input:s,path:[t.discriminator],inst:e}),n)}}),Dc=_("$ZodIntersection",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value,i=t.left._zod.run({value:n,issues:[]},o),s=t.right._zod.run({value:n,issues:[]},o);return i instanceof Promise||s instanceof Promise?Promise.all([i,s]).then(([c,u])=>E_(r,c,u)):E_(r,i,s)}});function rf(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(co(e)&&co(t)){let r=Object.keys(t),o=Object.keys(e).filter(i=>r.indexOf(i)!==-1),n={...e,...t};for(let i of o){let s=rf(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};n[i]=s.data}return{valid:!0,data:n}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let o=0;o<e.length;o++){let n=e[o],i=t[o],s=rf(n,i);if(!s.valid)return{valid:!1,mergeErrorPath:[o,...s.mergeErrorPath]};r.push(s.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}function E_(e,t,r){if(t.issues.length&&e.issues.push(...t.issues),r.issues.length&&e.issues.push(...r.issues),_n(e))return e;let o=rf(t.value,r.value);if(!o.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(o.mergeErrorPath)}`);return e.value=o.data,e}var Lr=_("$ZodTuple",(e,t)=>{W.init(e,t);let r=t.items,o=r.length-[...r].reverse().findIndex(n=>n._zod.optin!=="optional");e._zod.parse=(n,i)=>{let s=n.value;if(!Array.isArray(s))return n.issues.push({input:s,inst:e,expected:"tuple",code:"invalid_type"}),n;n.value=[];let a=[];if(!t.rest){let u=s.length>r.length,l=s.length<o-1;if(u||l)return n.issues.push({input:s,inst:e,origin:"array",...u?{code:"too_big",maximum:r.length}:{code:"too_small",minimum:r.length}}),n}let c=-1;for(let u of r){if(c++,c>=s.length&&c>=o)continue;let l=u._zod.run({value:s[c],issues:[]},i);l instanceof Promise?a.push(l.then(d=>sc(d,n,c))):sc(l,n,c)}if(t.rest){let u=s.slice(r.length);for(let l of u){c++;let d=t.rest._zod.run({value:l,issues:[]},i);d instanceof Promise?a.push(d.then(h=>sc(h,n,c))):sc(d,n,c)}}return a.length?Promise.all(a).then(()=>n):n}});function sc(e,t,r){e.issues.length&&t.issues.push(...gt(r,e.issues)),t.value[r]=e.value}var qc=_("$ZodRecord",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!co(n))return r.issues.push({expected:"record",code:"invalid_type",input:n,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:n[c],issues:[]},o);u instanceof Promise?i.push(u.then(l=>{l.issues.length&&r.issues.push(...gt(c,l.issues)),r.value[c]=l.value})):(u.issues.length&&r.issues.push(...gt(c,u.issues)),r.value[c]=u.value)}let a;for(let c in n)s.has(c)||(a=a??[],a.push(c));a&&a.length>0&&r.issues.push({code:"unrecognized_keys",input:n,inst:e,keys:a})}else{r.value={};for(let s of Reflect.ownKeys(n)){if(s==="__proto__")continue;let a=t.keyType._zod.run({value:s,issues:[]},o);if(a instanceof Promise)throw new 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=>Et(u,o,Ue())),input:s,path:[s],inst:e}),r.value[a.value]=a.value;continue}let c=t.valueType._zod.run({value:n[s],issues:[]},o);c instanceof Promise?i.push(c.then(u=>{u.issues.length&&r.issues.push(...gt(s,u.issues)),r.value[a.value]=u.value})):(c.issues.length&&r.issues.push(...gt(s,c.issues)),r.value[a.value]=c.value)}}return i.length?Promise.all(i).then(()=>r):r}}),Mc=_("$ZodMap",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!(n instanceof Map))return r.issues.push({expected:"map",code:"invalid_type",input:n,inst:e}),r;let i=[];r.value=new Map;for(let[s,a]of n){let c=t.keyType._zod.run({value:s,issues:[]},o),u=t.valueType._zod.run({value:a,issues:[]},o);c instanceof Promise||u instanceof Promise?i.push(Promise.all([c,u]).then(([l,d])=>{I_(l,d,r,s,n,e,o)})):I_(c,u,r,s,n,e,o)}return i.length?Promise.all(i).then(()=>r):r}});function I_(e,t,r,o,n,i,s){e.issues.length&&(Ei.has(typeof o)?r.issues.push(...gt(o,e.issues)):r.issues.push({origin:"map",code:"invalid_key",input:n,inst:i,issues:e.issues.map(a=>Et(a,s,Ue()))})),t.issues.length&&(Ei.has(typeof o)?r.issues.push(...gt(o,t.issues)):r.issues.push({origin:"map",code:"invalid_element",input:n,inst:i,key:o,issues:t.issues.map(a=>Et(a,s,Ue()))})),r.value.set(e.value,t.value)}var Uc=_("$ZodSet",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;if(!(n instanceof Set))return r.issues.push({input:n,inst:e,expected:"set",code:"invalid_type"}),r;let i=[];r.value=new Set;for(let s of n){let a=t.valueType._zod.run({value:s,issues:[]},o);a instanceof Promise?i.push(a.then(c=>O_(c,r))):O_(a,r)}return i.length?Promise.all(i).then(()=>r):r}});function O_(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}var Zc=_("$ZodEnum",(e,t)=>{W.init(e,t);let r=Ti(t.entries);e._zod.values=new Set(r),e._zod.pattern=new RegExp(`^(${r.filter(o=>Ei.has(typeof o)).map(o=>typeof o=="string"?$r(o):o.toString()).join("|")})$`),e._zod.parse=(o,n)=>{let i=o.value;return e._zod.values.has(i)||o.issues.push({code:"invalid_value",values:r,input:i,inst:e}),o}}),Vc=_("$ZodLiteral",(e,t)=>{W.init(e,t),e._zod.values=new Set(t.values),e._zod.pattern=new RegExp(`^(${t.values.map(r=>typeof r=="string"?$r(r):r?r.toString():String(r)).join("|")})$`),e._zod.parse=(r,o)=>{let n=r.value;return e._zod.values.has(n)||r.issues.push({code:"invalid_value",values:t.values,input:n,inst:e}),r}}),Lc=_("$ZodFile",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=r.value;return n instanceof File||r.issues.push({expected:"file",code:"invalid_type",input:n,inst:e}),r}}),go=_("$ZodTransform",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=t.transform(r.value,r);if(o.async)return(n instanceof Promise?n:Promise.resolve(n)).then(s=>(r.value=s,r));if(n instanceof Promise)throw new ar;return r.value=n,r}}),Fc=_("$ZodOptional",(e,t)=>{W.init(e,t),e._zod.optin="optional",e._zod.optout="optional",_e(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),_e(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${zi(r.source)})?$`):void 0}),e._zod.parse=(r,o)=>t.innerType._zod.optin==="optional"?t.innerType._zod.run(r,o):r.value===void 0?r:t.innerType._zod.run(r,o)}),Gc=_("$ZodNullable",(e,t)=>{W.init(e,t),_e(e._zod,"optin",()=>t.innerType._zod.optin),_e(e._zod,"optout",()=>t.innerType._zod.optout),_e(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${zi(r.source)}|null)$`):void 0}),_e(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(r,o)=>r.value===null?r:t.innerType._zod.run(r,o)}),Wc=_("$ZodDefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>{if(r.value===void 0)return r.value=t.defaultValue,r;let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>j_(i,t)):j_(n,t)}});function j_(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}var Kc=_("$ZodPrefault",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>(r.value===void 0&&(r.value=t.defaultValue),t.innerType._zod.run(r,o))}),Hc=_("$ZodNonOptional",(e,t)=>{W.init(e,t),_e(e._zod,"values",()=>{let r=t.innerType._zod.values;return r?new Set([...r].filter(o=>o!==void 0)):void 0}),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>N_(i,e)):N_(n,e)}});function N_(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}var Jc=_("$ZodSuccess",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>(r.value=i.issues.length===0,r)):(r.value=n.issues.length===0,r)}}),Bc=_("$ZodCatch",(e,t)=>{W.init(e,t),e._zod.optin="optional",_e(e._zod,"optout",()=>t.innerType._zod.optout),_e(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(i=>(r.value=i.value,i.issues.length&&(r.value=t.catchValue({...r,error:{issues:i.issues.map(s=>Et(s,o,Ue()))},input:r.value}),r.issues=[]),r)):(r.value=n.value,n.issues.length&&(r.value=t.catchValue({...r,error:{issues:n.issues.map(i=>Et(i,o,Ue()))},input:r.value}),r.issues=[]),r)}}),Yc=_("$ZodNaN",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>((typeof r.value!="number"||!Number.isNaN(r.value))&&r.issues.push({input:r.value,inst:e,expected:"nan",code:"invalid_type"}),r)}),vo=_("$ZodPipe",(e,t)=>{W.init(e,t),_e(e._zod,"values",()=>t.in._zod.values),_e(e._zod,"optin",()=>t.in._zod.optin),_e(e._zod,"optout",()=>t.out._zod.optout),e._zod.parse=(r,o)=>{let n=t.in._zod.run(r,o);return n instanceof Promise?n.then(i=>R_(i,t,o)):R_(n,t,o)}});function R_(e,t,r){return _n(e)?e:t.out._zod.run({value:e.value,issues:e.issues},r)}var Xc=_("$ZodReadonly",(e,t)=>{W.init(e,t),_e(e._zod,"propValues",()=>t.innerType._zod.propValues),_e(e._zod,"values",()=>t.innerType._zod.values),_e(e._zod,"optin",()=>t.innerType._zod.optin),_e(e._zod,"optout",()=>t.innerType._zod.optout),e._zod.parse=(r,o)=>{let n=t.innerType._zod.run(r,o);return n instanceof Promise?n.then(C_):C_(n)}});function C_(e){return e.value=Object.freeze(e.value),e}var Qc=_("$ZodTemplateLiteral",(e,t)=>{W.init(e,t);let r=[];for(let o of t.parts)if(o instanceof W){if(!o._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...o._zod.traits].shift()}`);let n=o._zod.pattern instanceof RegExp?o._zod.pattern.source:o._zod.pattern;if(!n)throw new Error(`Invalid template literal part: ${o._zod.traits}`);let i=n.startsWith("^")?1:0,s=n.endsWith("$")?n.length-1:n.length;r.push(n.slice(i,s))}else if(o===null||np.has(typeof o))r.push($r(`${o}`));else throw new Error(`Invalid template literal part: ${o}`);e._zod.pattern=new RegExp(`^${r.join("")}$`),e._zod.parse=(o,n)=>typeof o.value!="string"?(o.issues.push({input:o.value,inst:e,expected:"template_literal",code:"invalid_type"}),o):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(o.value)||o.issues.push({input:o.value,inst:e,code:"invalid_format",format:"template_literal",pattern:e._zod.pattern.source}),o)}),eu=_("$ZodPromise",(e,t)=>{W.init(e,t),e._zod.parse=(r,o)=>Promise.resolve(r.value).then(n=>t.innerType._zod.run({value:n,issues:[]},o))}),tu=_("$ZodLazy",(e,t)=>{W.init(e,t),_e(e._zod,"innerType",()=>t.getter()),_e(e._zod,"pattern",()=>e._zod.innerType._zod.pattern),_e(e._zod,"propValues",()=>e._zod.innerType._zod.propValues),_e(e._zod,"optin",()=>e._zod.innerType._zod.optin),_e(e._zod,"optout",()=>e._zod.innerType._zod.optout),e._zod.parse=(r,o)=>e._zod.innerType._zod.run(r,o)}),ru=_("$ZodCustom",(e,t)=>{De.init(e,t),W.init(e,t),e._zod.parse=(r,o)=>r,e._zod.check=r=>{let o=r.value,n=t.fn(o);if(n instanceof Promise)return n.then(i=>A_(i,r,o,e));A_(n,r,o,e)}});function A_(e,t,r,o){if(!e){let n={code:"custom",input:r,inst:o,path:[...o._zod.def.path??[]],continue:!o._zod.def.abort};o._zod.def.params&&(n.params=o._zod.def.params),t.issues.push(ap(n))}}var _o={};mn(_o,{ar:()=>U_,az:()=>Z_,be:()=>L_,ca:()=>F_,cs:()=>G_,de:()=>W_,en:()=>nu,eo:()=>K_,es:()=>H_,fa:()=>J_,fi:()=>B_,fr:()=>Y_,frCA:()=>X_,he:()=>Q_,hu:()=>ey,id:()=>ty,it:()=>ry,ja:()=>ny,kh:()=>oy,ko:()=>iy,mk:()=>sy,ms:()=>ay,nl:()=>cy,no:()=>uy,ota:()=>ly,pl:()=>py,ps:()=>dy,pt:()=>fy,ru:()=>hy,sl:()=>gy,sv:()=>vy,ta:()=>_y,th:()=>yy,tr:()=>by,ua:()=>$y,ur:()=>wy,vi:()=>ky,zhCN:()=>xy,zhTW:()=>Sy});var GT=()=>{let e={string:{unit:"\u062D\u0631\u0641",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},file:{unit:"\u0628\u0627\u064A\u062A",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},array:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},set:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0645\u062F\u062E\u0644",email:"\u0628\u0631\u064A\u062F \u0625\u0644\u0643\u062A\u0631\u0648\u0646\u064A",url:"\u0631\u0627\u0628\u0637",emoji:"\u0625\u064A\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u064A\u062E \u0648\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",date:"\u062A\u0627\u0631\u064A\u062E \u0628\u0645\u0639\u064A\u0627\u0631 ISO",time:"\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",duration:"\u0645\u062F\u0629 \u0628\u0645\u0639\u064A\u0627\u0631 ISO",ipv4:"\u0639\u0646\u0648\u0627\u0646 IPv4",ipv6:"\u0639\u0646\u0648\u0627\u0646 IPv6",cidrv4:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv4",cidrv6:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv6",base64:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64-encoded",base64url:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64url-encoded",json_string:"\u0646\u064E\u0635 \u0639\u0644\u0649 \u0647\u064A\u0626\u0629 JSON",e164:"\u0631\u0642\u0645 \u0647\u0627\u062A\u0641 \u0628\u0645\u0639\u064A\u0627\u0631 E.164",jwt:"JWT",template_literal:"\u0645\u062F\u062E\u0644"};return n=>{switch(n.code){case"invalid_type":return`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${n.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${R(n.values[0])}`:`\u0627\u062E\u062A\u064A\u0627\u0631 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062A\u0648\u0642\u0639 \u0627\u0646\u062A\u0642\u0627\u0621 \u0623\u062D\u062F \u0647\u0630\u0647 \u0627\u0644\u062E\u064A\u0627\u0631\u0627\u062A: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${n.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631"}`:`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${n.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${n.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${n.minimum.toString()} ${s.unit}`:`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${n.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${n.prefix}"`:i.format==="ends_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0646\u062A\u0647\u064A \u0628\u0640 "${i.suffix}"`:i.format==="includes"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u062A\u0636\u0645\u0651\u064E\u0646 "${i.includes}"`:i.format==="regex"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0637\u0627\u0628\u0642 \u0627\u0644\u0646\u0645\u0637 ${i.pattern}`:`${o[i.format]??n.format} \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644`}case"not_multiple_of":return`\u0631\u0642\u0645 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0643\u0648\u0646 \u0645\u0646 \u0645\u0636\u0627\u0639\u0641\u0627\u062A ${n.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${n.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${n.keys.length>1?"\u0629":""}: ${x(n.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${n.origin}`;case"invalid_union":return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644";case"invalid_element":return`\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${n.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}};function U_(){return{localeError:GT()}}var WT=()=>{let e={string:{unit:"simvol",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"element",verb:"olmal\u0131d\u0131r"},set:{unit:"element",verb:"olmal\u0131d\u0131r"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={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`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${n.expected}, daxil olan ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${R(n.values[0])}`:`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${n.origin??"d\u0259y\u0259r"} ${i}${n.maximum.toString()} ${s.unit??"element"}`:`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${n.origin??"d\u0259y\u0259r"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${n.origin} ${i}${n.minimum.toString()} ${s.unit}`:`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Yanl\u0131\u015F m\u0259tn: "${i.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`:i.format==="ends_with"?`Yanl\u0131\u015F m\u0259tn: "${i.suffix}" il\u0259 bitm\u0259lidir`:i.format==="includes"?`Yanl\u0131\u015F m\u0259tn: "${i.includes}" daxil olmal\u0131d\u0131r`:i.format==="regex"?`Yanl\u0131\u015F m\u0259tn: ${i.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`:`Yanl\u0131\u015F ${o[i.format]??n.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${n.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${n.keys.length>1?"lar":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${n.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}};function Z_(){return{localeError:WT()}}function V_(e,t,r,o){let n=Math.abs(e),i=n%10,s=n%100;return s>=11&&s<=19?o:i===1?t:i>=2&&i<=4?r:o}var KT=()=>{let e={string:{unit:{one:"\u0441\u0456\u043C\u0432\u0430\u043B",few:"\u0441\u0456\u043C\u0432\u0430\u043B\u044B",many:"\u0441\u0456\u043C\u0432\u0430\u043B\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u044B",many:"\u0431\u0430\u0439\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u043B\u0456\u043A";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0456\u045E";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0443\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0430\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0456 \u0447\u0430\u0441",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0447\u0430\u0441",duration:"ISO \u043F\u0440\u0430\u0446\u044F\u0433\u043B\u0430\u0441\u0446\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0430\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0430\u0441",cidrv4:"IPv4 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",base64:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64",base64url:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64url",json_string:"JSON \u0440\u0430\u0434\u043E\u043A",e164:"\u043D\u0443\u043C\u0430\u0440 E.164",jwt:"JWT",template_literal:"\u0443\u0432\u043E\u0434"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${n.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${R(n.values[0])}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0432\u0430\u0440\u044B\u044F\u043D\u0442: \u0447\u0430\u043A\u0430\u045E\u0441\u044F \u0430\u0434\u0437\u0456\u043D \u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);if(s){let a=Number(n.maximum),c=V_(a,s.unit.one,s.unit.few,s.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${s.verb} ${i}${n.maximum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);if(s){let a=Number(n.minimum),c=V_(a,s.unit.one,s.unit.few,s.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${s.verb} ${i}${n.minimum.toString()} ${c}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${n.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u043F\u0430\u0447\u044B\u043D\u0430\u0446\u0446\u0430 \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u0430\u043A\u0430\u043D\u0447\u0432\u0430\u0446\u0446\u0430 \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u043C\u044F\u0448\u0447\u0430\u0446\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0430\u0434\u043F\u0430\u0432\u044F\u0434\u0430\u0446\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043B\u0456\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0431\u044B\u0446\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${n.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${n.origin}`;case"invalid_union":return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434";case"invalid_element":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u0430\u0435 \u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435 \u045E ${n.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}};function L_(){return{localeError:KT()}}var HT=()=>{let e={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entrada",email:"adre\xE7a electr\xF2nica",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:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\xE7a IPv4",ipv6:"adre\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Tipus inv\xE0lid: s'esperava ${n.expected}, s'ha rebut ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Valor inv\xE0lid: s'esperava ${R(n.values[0])}`:`Opci\xF3 inv\xE0lida: s'esperava una de ${x(n.values," o ")}`;case"too_big":{let i=n.inclusive?"com a m\xE0xim":"menys de",s=t(n.origin);return s?`Massa gran: s'esperava que ${n.origin??"el valor"} contingu\xE9s ${i} ${n.maximum.toString()} ${s.unit??"elements"}`:`Massa gran: s'esperava que ${n.origin??"el valor"} fos ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"com a m\xEDnim":"m\xE9s de",s=t(n.origin);return s?`Massa petit: s'esperava que ${n.origin} contingu\xE9s ${i} ${n.minimum.toString()} ${s.unit}`:`Massa petit: s'esperava que ${n.origin} fos ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Format inv\xE0lid: ha de comen\xE7ar amb "${i.prefix}"`:i.format==="ends_with"?`Format inv\xE0lid: ha d'acabar amb "${i.suffix}"`:i.format==="includes"?`Format inv\xE0lid: ha d'incloure "${i.includes}"`:i.format==="regex"?`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${i.pattern}`:`Format inv\xE0lid per a ${o[i.format]??n.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${n.divisor}`;case"unrecognized_keys":return`Clau${n.keys.length>1?"s":""} no reconeguda${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${n.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${n.origin}`;default:return"Entrada inv\xE0lida"}}};function F_(){return{localeError:HT()}}var JT=()=>{let e={string:{unit:"znak\u016F",verb:"m\xEDt"},file:{unit:"bajt\u016F",verb:"m\xEDt"},array:{unit:"prvk\u016F",verb:"m\xEDt"},set:{unit:"prvk\u016F",verb:"m\xEDt"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u010D\xEDslo";case"string":return"\u0159et\u011Bzec";case"boolean":return"boolean";case"bigint":return"bigint";case"function":return"funkce";case"symbol":return"symbol";case"undefined":return"undefined";case"object":{if(Array.isArray(n))return"pole";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"regul\xE1rn\xED v\xFDraz",email:"e-mailov\xE1 adresa",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:"datum a \u010Das ve form\xE1tu ISO",date:"datum ve form\xE1tu ISO",time:"\u010Das ve form\xE1tu ISO",duration:"doba trv\xE1n\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64",base64url:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64url",json_string:"\u0159et\u011Bzec ve form\xE1tu JSON",e164:"\u010D\xEDslo E.164",jwt:"JWT",template_literal:"vstup"};return n=>{switch(n.code){case"invalid_type":return`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${n.expected}, obdr\u017Eeno ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${R(n.values[0])}`:`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${n.origin??"hodnota"} mus\xED m\xEDt ${i}${n.maximum.toString()} ${s.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${n.origin??"hodnota"} mus\xED b\xFDt ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${n.origin??"hodnota"} mus\xED m\xEDt ${i}${n.minimum.toString()} ${s.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${n.origin??"hodnota"} mus\xED b\xFDt ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${i.prefix}"`:i.format==="ends_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${i.suffix}"`:i.format==="includes"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${i.includes}"`:i.format==="regex"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${i.pattern}`:`Neplatn\xFD form\xE1t ${o[i.format]??n.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${n.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${x(n.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${n.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${n.origin}`;default:return"Neplatn\xFD vstup"}}};function G_(){return{localeError:JT()}}var BT=()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"Zahl";case"object":{if(Array.isArray(n))return"Array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"Eingabe",email:"E-Mail-Adresse",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-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"};return n=>{switch(n.code){case"invalid_type":return`Ung\xFCltige Eingabe: erwartet ${n.expected}, erhalten ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ung\xFCltige Eingabe: erwartet ${R(n.values[0])}`:`Ung\xFCltige Option: erwartet eine von ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Zu gro\xDF: erwartet, dass ${n.origin??"Wert"} ${i}${n.maximum.toString()} ${s.unit??"Elemente"} hat`:`Zu gro\xDF: erwartet, dass ${n.origin??"Wert"} ${i}${n.maximum.toString()} ist`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Zu klein: erwartet, dass ${n.origin} ${i}${n.minimum.toString()} ${s.unit} hat`:`Zu klein: erwartet, dass ${n.origin} ${i}${n.minimum.toString()} ist`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ung\xFCltiger String: muss mit "${i.prefix}" beginnen`:i.format==="ends_with"?`Ung\xFCltiger String: muss mit "${i.suffix}" enden`:i.format==="includes"?`Ung\xFCltiger String: muss "${i.includes}" enthalten`:i.format==="regex"?`Ung\xFCltiger String: muss dem Muster ${i.pattern} entsprechen`:`Ung\xFCltig: ${o[i.format]??n.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${n.divisor} sein`;case"unrecognized_keys":return`${n.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${n.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${n.origin}`;default:return"Ung\xFCltige Eingabe"}}};function W_(){return{localeError:BT()}}var YT=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},XT=()=>{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(o){return e[o]??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 o=>{switch(o.code){case"invalid_type":return`Invalid input: expected ${o.expected}, received ${YT(o.input)}`;case"invalid_value":return o.values.length===1?`Invalid input: expected ${R(o.values[0])}`:`Invalid option: expected one of ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`Too big: expected ${o.origin??"value"} to have ${n}${o.maximum.toString()} ${i.unit??"elements"}`:`Too big: expected ${o.origin??"value"} to be ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`Too small: expected ${o.origin} to have ${n}${o.minimum.toString()} ${i.unit}`:`Too small: expected ${o.origin} to be ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Invalid string: must start with "${n.prefix}"`:n.format==="ends_with"?`Invalid string: must end with "${n.suffix}"`:n.format==="includes"?`Invalid string: must include "${n.includes}"`:n.format==="regex"?`Invalid string: must match pattern ${n.pattern}`:`Invalid ${r[n.format]??o.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${o.divisor}`;case"unrecognized_keys":return`Unrecognized key${o.keys.length>1?"s":""}: ${x(o.keys,", ")}`;case"invalid_key":return`Invalid key in ${o.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${o.origin}`;default:return"Invalid input"}}};function nu(){return{localeError:XT()}}var QT=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"nombro";case"object":{if(Array.isArray(e))return"tabelo";if(e===null)return"senvalora";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}}return t},eP=()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(o){return e[o]??null}let r={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"};return o=>{switch(o.code){case"invalid_type":return`Nevalida enigo: atendi\u011Dis ${o.expected}, ricevi\u011Dis ${QT(o.input)}`;case"invalid_value":return o.values.length===1?`Nevalida enigo: atendi\u011Dis ${R(o.values[0])}`:`Nevalida opcio: atendi\u011Dis unu el ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${n}${o.maximum.toString()} ${i.unit??"elementojn"}`:`Tro granda: atendi\u011Dis ke ${o.origin??"valoro"} havu ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`Tro malgranda: atendi\u011Dis ke ${o.origin} havu ${n}${o.minimum.toString()} ${i.unit}`:`Tro malgranda: atendi\u011Dis ke ${o.origin} estu ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Nevalida karaktraro: devas komenci\u011Di per "${n.prefix}"`:n.format==="ends_with"?`Nevalida karaktraro: devas fini\u011Di per "${n.suffix}"`:n.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${n.includes}"`:n.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${n.pattern}`:`Nevalida ${r[n.format]??o.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${o.divisor}`;case"unrecognized_keys":return`Nekonata${o.keys.length>1?"j":""} \u015Dlosilo${o.keys.length>1?"j":""}: ${x(o.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${o.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${o.origin}`;default:return"Nevalida enigo"}}};function K_(){return{localeError:eP()}}var tP=()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(n))return"arreglo";if(n===null)return"nulo";if(Object.getPrototypeOf(n)!==Object.prototype)return n.constructor.name}}return i},o={regex:"entrada",email:"direcci\xF3n de correo electr\xF3nico",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:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\xF3n ISO",ipv4:"direcci\xF3n IPv4",ipv6:"direcci\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Entrada inv\xE1lida: se esperaba ${n.expected}, recibido ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entrada inv\xE1lida: se esperaba ${R(n.values[0])}`:`Opci\xF3n inv\xE1lida: se esperaba una de ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Demasiado grande: se esperaba que ${n.origin??"valor"} tuviera ${i}${n.maximum.toString()} ${s.unit??"elementos"}`:`Demasiado grande: se esperaba que ${n.origin??"valor"} fuera ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Demasiado peque\xF1o: se esperaba que ${n.origin} tuviera ${i}${n.minimum.toString()} ${s.unit}`:`Demasiado peque\xF1o: se esperaba que ${n.origin} fuera ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cadena inv\xE1lida: debe comenzar con "${i.prefix}"`:i.format==="ends_with"?`Cadena inv\xE1lida: debe terminar en "${i.suffix}"`:i.format==="includes"?`Cadena inv\xE1lida: debe incluir "${i.includes}"`:i.format==="regex"?`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${i.pattern}`:`Inv\xE1lido ${o[i.format]??n.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${n.divisor}`;case"unrecognized_keys":return`Llave${n.keys.length>1?"s":""} desconocida${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${n.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${n.origin}`;default:return"Entrada inv\xE1lida"}}};function H_(){return{localeError:tP()}}var rP=()=>{let e={string:{unit:"\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},file:{unit:"\u0628\u0627\u06CC\u062A",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},array:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},set:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(n))return"\u0622\u0631\u0627\u06CC\u0647";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u06CC",email:"\u0622\u062F\u0631\u0633 \u0627\u06CC\u0645\u06CC\u0644",url:"URL",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u06CC\u062E \u0648 \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",date:"\u062A\u0627\u0631\u06CC\u062E \u0627\u06CC\u0632\u0648",time:"\u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",duration:"\u0645\u062F\u062A \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",ipv4:"IPv4 \u0622\u062F\u0631\u0633",ipv6:"IPv6 \u0622\u062F\u0631\u0633",cidrv4:"IPv4 \u062F\u0627\u0645\u0646\u0647",cidrv6:"IPv6 \u062F\u0627\u0645\u0646\u0647",base64:"base64-encoded \u0631\u0634\u062A\u0647",base64url:"base64url-encoded \u0631\u0634\u062A\u0647",json_string:"JSON \u0631\u0634\u062A\u0647",e164:"E.164 \u0639\u062F\u062F",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u06CC"};return n=>{switch(n.code){case"invalid_type":return`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${n.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${r(n.input)} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`;case"invalid_value":return n.values.length===1?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${R(n.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`:`\u06AF\u0632\u06CC\u0646\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A \u06CC\u06A9\u06CC \u0627\u0632 ${x(n.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${n.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${n.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} ${s.unit} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.prefix}" \u0634\u0631\u0648\u0639 \u0634\u0648\u062F`:i.format==="ends_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.suffix}" \u062A\u0645\u0627\u0645 \u0634\u0648\u062F`:i.format==="includes"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0634\u0627\u0645\u0644 "${i.includes}" \u0628\u0627\u0634\u062F`:i.format==="regex"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 \u0627\u0644\u06AF\u0648\u06CC ${i.pattern} \u0645\u0637\u0627\u0628\u0642\u062A \u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F`:`${o[i.format]??n.format} \u0646\u0627\u0645\u0639\u062A\u0628\u0631`}case"not_multiple_of":return`\u0639\u062F\u062F \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0645\u0636\u0631\u0628 ${n.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${n.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${x(n.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${n.origin}`;case"invalid_union":return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631";case"invalid_element":return`\u0645\u0642\u062F\u0627\u0631 \u0646\u0627\u0645\u0639\u062A\u0628\u0631 \u062F\u0631 ${n.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}};function J_(){return{localeError:rP()}}var nP=()=>{let e={string:{unit:"merkki\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\xE4iv\xE4m\xE4\xE4r\xE4n"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"s\xE4\xE4nn\xF6llinen lauseke",email:"s\xE4hk\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\xE4iv\xE4m\xE4\xE4r\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"};return n=>{switch(n.code){case"invalid_type":return`Virheellinen tyyppi: odotettiin ${n.expected}, oli ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Virheellinen sy\xF6te: t\xE4ytyy olla ${R(n.values[0])}`:`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Liian suuri: ${s.subject} t\xE4ytyy olla ${i}${n.maximum.toString()} ${s.unit}`.trim():`Liian suuri: arvon t\xE4ytyy olla ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Liian pieni: ${s.subject} t\xE4ytyy olla ${i}${n.minimum.toString()} ${s.unit}`.trim():`Liian pieni: arvon t\xE4ytyy olla ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${i.prefix}"`:i.format==="ends_with"?`Virheellinen sy\xF6te: t\xE4ytyy loppua "${i.suffix}"`:i.format==="includes"?`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${i.includes}"`:i.format==="regex"?`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${i.pattern}`:`Virheellinen ${o[i.format]??n.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${n.divisor} monikerta`;case"unrecognized_keys":return`${n.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${x(n.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\xF6te"}}};function B_(){return{localeError:nP()}}var oP=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"nombre";case"object":{if(Array.isArray(n))return"tableau";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse e-mail",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:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return n=>{switch(n.code){case"invalid_type":return`Entr\xE9e invalide : ${n.expected} attendu, ${r(n.input)} re\xE7u`;case"invalid_value":return n.values.length===1?`Entr\xE9e invalide : ${R(n.values[0])} attendu`:`Option invalide : une valeur parmi ${x(n.values,"|")} attendue`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Trop grand : ${n.origin??"valeur"} doit ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"\xE9l\xE9ment(s)"}`:`Trop grand : ${n.origin??"valeur"} doit \xEAtre ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Trop petit : ${n.origin} doit ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Trop petit : ${n.origin} doit \xEAtre ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au mod\xE8le ${i.pattern}`:`${o[i.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${n.divisor}`;case"unrecognized_keys":return`Cl\xE9${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${x(n.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${n.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entr\xE9e invalide"}}};function Y_(){return{localeError:oP()}}var iP=()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"entr\xE9e",email:"adresse courriel",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:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"};return n=>{switch(n.code){case"invalid_type":return`Entr\xE9e invalide : attendu ${n.expected}, re\xE7u ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entr\xE9e invalide : attendu ${R(n.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"\u2264":"<",s=t(n.origin);return s?`Trop grand : attendu que ${n.origin??"la valeur"} ait ${i}${n.maximum.toString()} ${s.unit}`:`Trop grand : attendu que ${n.origin??"la valeur"} soit ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"\u2265":">",s=t(n.origin);return s?`Trop petit : attendu que ${n.origin} ait ${i}${n.minimum.toString()} ${s.unit}`:`Trop petit : attendu que ${n.origin} soit ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au motif ${i.pattern}`:`${o[i.format]??n.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${n.divisor}`;case"unrecognized_keys":return`Cl\xE9${n.keys.length>1?"s":""} non reconnue${n.keys.length>1?"s":""} : ${x(n.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${n.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${n.origin}`;default:return"Entr\xE9e invalide"}}};function X_(){return{localeError:iP()}}var sP=()=>{let e={string:{unit:"\u05D0\u05D5\u05EA\u05D9\u05D5\u05EA",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",verb:"\u05DC\u05DB\u05DC\u05D5\u05DC"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u05E7\u05DC\u05D8",email:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",url:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",emoji:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",date:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",time:"\u05D6\u05DE\u05DF ISO",duration:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",ipv4:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",ipv6:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",cidrv4:"\u05D8\u05D5\u05D5\u05D7 IPv4",cidrv6:"\u05D8\u05D5\u05D5\u05D7 IPv6",base64:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",base64url:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",json_string:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",e164:"\u05DE\u05E1\u05E4\u05E8 E.164",jwt:"JWT",template_literal:"\u05E7\u05DC\u05D8"};return n=>{switch(n.code){case"invalid_type":return`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${n.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA ${R(n.values[0])}`:`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05D0\u05D7\u05EA \u05DE\u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${n.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.maximum.toString()} ${s.unit??"elements"}`:`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${n.origin??"value"} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${n.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.minimum.toString()} ${s.unit}`:`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${n.origin} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1"${i.prefix}"`:i.format==="ends_with"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${i.suffix}"`:i.format==="includes"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${i.includes}"`:i.format==="regex"?`\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05E0\u05D4: \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${i.pattern}`:`${o[i.format]??n.format} \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF`}case"not_multiple_of":return`\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ${n.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${n.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${n.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u05DE\u05E4\u05EA\u05D7 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${n.origin}`;case"invalid_union":return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";case"invalid_element":return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${n.origin}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}};function Q_(){return{localeError:sP()}}var aP=()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"sz\xE1m";case"object":{if(Array.isArray(n))return"t\xF6mb";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"bemenet",email:"email c\xEDm",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 id\u0151b\xE9lyeg",date:"ISO d\xE1tum",time:"ISO id\u0151",duration:"ISO id\u0151intervallum",ipv4:"IPv4 c\xEDm",ipv6:"IPv6 c\xEDm",cidrv4:"IPv4 tartom\xE1ny",cidrv6:"IPv6 tartom\xE1ny",base64:"base64-k\xF3dolt string",base64url:"base64url-k\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\xE1m",jwt:"JWT",template_literal:"bemenet"};return n=>{switch(n.code){case"invalid_type":return`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${n.expected}, a kapott \xE9rt\xE9k ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${R(n.values[0])}`:`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`T\xFAl nagy: ${n.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${i}${n.maximum.toString()} ${s.unit??"elem"}`:`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${n.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${n.origin} m\xE9rete t\xFAl kicsi ${i}${n.minimum.toString()} ${s.unit}`:`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${n.origin} t\xFAl kicsi ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\xC9rv\xE9nytelen string: "${i.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`:i.format==="ends_with"?`\xC9rv\xE9nytelen string: "${i.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`:i.format==="includes"?`\xC9rv\xE9nytelen string: "${i.includes}" \xE9rt\xE9ket kell tartalmaznia`:i.format==="regex"?`\xC9rv\xE9nytelen string: ${i.pattern} mint\xE1nak kell megfelelnie`:`\xC9rv\xE9nytelen ${o[i.format]??n.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${n.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${n.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${n.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}};function ey(){return{localeError:aP()}}var cP=()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"alamat email",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:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input tidak valid: diharapkan ${n.expected}, diterima ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input tidak valid: diharapkan ${R(n.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: diharapkan ${n.origin??"value"} memiliki ${i}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: diharapkan ${n.origin??"value"} menjadi ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: diharapkan ${n.origin} memiliki ${i}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: diharapkan ${n.origin} menjadi ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`String tidak valid: harus dimulai dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak valid: harus berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak valid: harus menyertakan "${i.includes}"`:i.format==="regex"?`String tidak valid: harus sesuai pola ${i.pattern}`:`${o[i.format]??n.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${n.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${n.origin}`;default:return"Input tidak valid"}}};function ty(){return{localeError:cP()}}var uP=()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"numero";case"object":{if(Array.isArray(n))return"vettore";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"indirizzo email",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:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input non valido: atteso ${n.expected}, ricevuto ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input non valido: atteso ${R(n.values[0])}`:`Opzione non valida: atteso uno tra ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Troppo grande: ${n.origin??"valore"} deve avere ${i}${n.maximum.toString()} ${s.unit??"elementi"}`:`Troppo grande: ${n.origin??"valore"} deve essere ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Troppo piccolo: ${n.origin} deve avere ${i}${n.minimum.toString()} ${s.unit}`:`Troppo piccolo: ${n.origin} deve essere ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Stringa non valida: deve iniziare con "${i.prefix}"`:i.format==="ends_with"?`Stringa non valida: deve terminare con "${i.suffix}"`:i.format==="includes"?`Stringa non valida: deve includere "${i.includes}"`:i.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${i.pattern}`:`Invalid ${o[i.format]??n.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${n.divisor}`;case"unrecognized_keys":return`Chiav${n.keys.length>1?"i":"e"} non riconosciut${n.keys.length>1?"e":"a"}: ${x(n.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${n.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${n.origin}`;default:return"Input non valido"}}};function ry(){return{localeError:uP()}}var lP=()=>{let e={string:{unit:"\u6587\u5B57",verb:"\u3067\u3042\u308B"},file:{unit:"\u30D0\u30A4\u30C8",verb:"\u3067\u3042\u308B"},array:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"},set:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u6570\u5024";case"object":{if(Array.isArray(n))return"\u914D\u5217";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u5165\u529B\u5024",email:"\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9",url:"URL",emoji:"\u7D75\u6587\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u6642",date:"ISO\u65E5\u4ED8",time:"ISO\u6642\u523B",duration:"ISO\u671F\u9593",ipv4:"IPv4\u30A2\u30C9\u30EC\u30B9",ipv6:"IPv6\u30A2\u30C9\u30EC\u30B9",cidrv4:"IPv4\u7BC4\u56F2",cidrv6:"IPv6\u7BC4\u56F2",base64:"base64\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",base64url:"base64url\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",json_string:"JSON\u6587\u5B57\u5217",e164:"E.164\u756A\u53F7",jwt:"JWT",template_literal:"\u5165\u529B\u5024"};return n=>{switch(n.code){case"invalid_type":return`\u7121\u52B9\u306A\u5165\u529B: ${n.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${r(n.input)}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`;case"invalid_value":return n.values.length===1?`\u7121\u52B9\u306A\u5165\u529B: ${R(n.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u9078\u629E: ${x(n.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let i=n.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",s=t(n.origin);return s?`\u5927\u304D\u3059\u304E\u308B\u5024: ${n.origin??"\u5024"}\u306F${n.maximum.toString()}${s.unit??"\u8981\u7D20"}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5927\u304D\u3059\u304E\u308B\u5024: ${n.origin??"\u5024"}\u306F${n.maximum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let i=n.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",s=t(n.origin);return s?`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${n.origin}\u306F${n.minimum.toString()}${s.unit}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${n.origin}\u306F${n.minimum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="ends_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="includes"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="regex"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${i.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u7121\u52B9\u306A${o[i.format]??n.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${n.divisor}\u306E\u500D\u6570\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"unrecognized_keys":return`\u8A8D\u8B58\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC${n.keys.length>1?"\u7FA4":""}: ${x(n.keys,"\u3001")}`;case"invalid_key":return`${n.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${n.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}};function ny(){return{localeError:lP()}}var dP=()=>{let e={string:{unit:"\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},file:{unit:"\u1794\u17C3",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},array:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},set:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u1798\u17B7\u1793\u1798\u17C2\u1793\u1787\u17B6\u179B\u17C1\u1781 (NaN)":"\u179B\u17C1\u1781";case"object":{if(Array.isArray(n))return"\u17A2\u17B6\u179A\u17C1 (Array)";if(n===null)return"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B",email:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793\u17A2\u17CA\u17B8\u1798\u17C2\u179B",url:"URL",emoji:"\u179F\u1789\u17D2\u1789\u17B6\u17A2\u17B6\u179A\u1798\u17D2\u1798\u178E\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 \u1793\u17B7\u1784\u1798\u17C9\u17C4\u1784 ISO",date:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 ISO",time:"\u1798\u17C9\u17C4\u1784 ISO",duration:"\u179A\u1799\u17C8\u1796\u17C1\u179B ISO",ipv4:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",ipv6:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",cidrv4:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",cidrv6:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",base64:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64",base64url:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64url",json_string:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A JSON",e164:"\u179B\u17C1\u1781 E.164",jwt:"JWT",template_literal:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B"};return n=>{switch(n.code){case"invalid_type":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${R(n.values[0])}`:`\u1787\u1798\u17D2\u179A\u17BE\u179F\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1787\u17B6\u1798\u17BD\u1799\u1780\u17D2\u1793\u17BB\u1784\u1785\u17C6\u178E\u17C4\u1798 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${n.maximum.toString()} ${s.unit??"\u1792\u17B6\u178F\u17BB"}`:`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin} ${i} ${n.minimum.toString()} ${s.unit}`:`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${n.origin} ${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798\u178A\u17C4\u1799 "${i.prefix}"`:i.format==="ends_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1794\u1789\u17D2\u1785\u1794\u17CB\u178A\u17C4\u1799 "${i.suffix}"`:i.format==="includes"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1798\u17B6\u1793 "${i.includes}"`:i.format==="regex"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1795\u17D2\u1782\u17BC\u1795\u17D2\u1782\u1784\u1793\u17B9\u1784\u1791\u1798\u17D2\u179A\u1784\u17CB\u178A\u17C2\u179B\u1794\u17B6\u1793\u1780\u17C6\u178E\u178F\u17CB ${i.pattern}`:`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u179B\u17C1\u1781\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1787\u17B6\u1796\u17A0\u17BB\u1782\u17BB\u178E\u1793\u17C3 ${n.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${x(n.keys,", ")}`;case"invalid_key":return`\u179F\u17C4\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${n.origin}`;case"invalid_union":return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C";case"invalid_element":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${n.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}};function oy(){return{localeError:dP()}}var pP=()=>{let e={string:{unit:"\uBB38\uC790",verb:"to have"},file:{unit:"\uBC14\uC774\uD2B8",verb:"to have"},array:{unit:"\uAC1C",verb:"to have"},set:{unit:"\uAC1C",verb:"to have"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\uC785\uB825",email:"\uC774\uBA54\uC77C \uC8FC\uC18C",url:"URL",emoji:"\uC774\uBAA8\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \uB0A0\uC9DC\uC2DC\uAC04",date:"ISO \uB0A0\uC9DC",time:"ISO \uC2DC\uAC04",duration:"ISO \uAE30\uAC04",ipv4:"IPv4 \uC8FC\uC18C",ipv6:"IPv6 \uC8FC\uC18C",cidrv4:"IPv4 \uBC94\uC704",cidrv6:"IPv6 \uBC94\uC704",base64:"base64 \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",base64url:"base64url \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",json_string:"JSON \uBB38\uC790\uC5F4",e164:"E.164 \uBC88\uD638",jwt:"JWT",template_literal:"\uC785\uB825"};return n=>{switch(n.code){case"invalid_type":return`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${n.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${r(n.input)}\uC785\uB2C8\uB2E4`;case"invalid_value":return n.values.length===1?`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${R(n.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC635\uC158: ${x(n.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let i=n.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",s=i==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",a=t(n.origin),c=a?.unit??"\uC694\uC18C";return a?`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${n.maximum.toString()}${c} ${i}${s}`:`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${n.maximum.toString()} ${i}${s}`}case"too_small":{let i=n.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",s=i==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",a=t(n.origin),c=a?.unit??"\uC694\uC18C";return a?`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${n.minimum.toString()}${c} ${i}${s}`:`${n.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${n.minimum.toString()} ${i}${s}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="ends_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`:i.format==="includes"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="regex"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${i.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C ${o[i.format]??n.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${n.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${x(n.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${n.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${n.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}};function iy(){return{localeError:pP()}}var fP=()=>{let e={string:{unit:"\u0437\u043D\u0430\u0446\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},file:{unit:"\u0431\u0430\u0458\u0442\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},array:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},set:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0431\u0440\u043E\u0458";case"object":{if(Array.isArray(n))return"\u043D\u0438\u0437\u0430";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u043D\u0435\u0441",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u043D\u0430 \u0435-\u043F\u043E\u0448\u0442\u0430",url:"URL",emoji:"\u0435\u043C\u043E\u045F\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0443\u043C \u0438 \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0443\u043C",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u0432\u0440\u0435\u043C\u0435\u0442\u0440\u0430\u0435\u045A\u0435",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441\u0430",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441\u0430",cidrv4:"IPv4 \u043E\u043F\u0441\u0435\u0433",cidrv6:"IPv6 \u043E\u043F\u0441\u0435\u0433",base64:"base64-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",base64url:"base64url-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",json_string:"JSON \u043D\u0438\u0437\u0430",e164:"E.164 \u0431\u0440\u043E\u0458",jwt:"JWT",template_literal:"\u0432\u043D\u0435\u0441"};return n=>{switch(n.code){case"invalid_type":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Invalid input: expected ${R(n.values[0])}`:`\u0413\u0440\u0435\u0448\u0430\u043D\u0430 \u043E\u043F\u0446\u0438\u0458\u0430: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 \u0435\u0434\u043D\u0430 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${i}${n.maximum.toString()} ${s.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin} \u0434\u0430 \u0438\u043C\u0430 ${i}${n.minimum.toString()} ${s.unit}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${n.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u043D\u0443\u0432\u0430 \u0441\u043E "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u0432\u0440\u0448\u0443\u0432\u0430 \u0441\u043E "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0432\u043A\u043B\u0443\u0447\u0443\u0432\u0430 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u043E\u0434\u0433\u043E\u0430\u0440\u0430 \u043D\u0430 \u043F\u0430\u0442\u0435\u0440\u043D\u043E\u0442 ${i.pattern}`:`Invalid ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0431\u0440\u043E\u0458: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0431\u0438\u0434\u0435 \u0434\u0435\u043B\u0438\u0432 \u0441\u043E ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D\u0438 \u043A\u043B\u0443\u0447\u0435\u0432\u0438":"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D \u043A\u043B\u0443\u0447"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${n.origin}`;case"invalid_union":return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441";case"invalid_element":return`\u0413\u0440\u0435\u0448\u043D\u0430 \u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442 \u0432\u043E ${n.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}};function sy(){return{localeError:fP()}}var mP=()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"nombor";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"alamat e-mel",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:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Input tidak sah: dijangka ${n.expected}, diterima ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Input tidak sah: dijangka ${R(n.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Terlalu besar: dijangka ${n.origin??"nilai"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"elemen"}`:`Terlalu besar: dijangka ${n.origin??"nilai"} adalah ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Terlalu kecil: dijangka ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Terlalu kecil: dijangka ${n.origin} adalah ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`String tidak sah: mesti bermula dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak sah: mesti mengandungi "${i.includes}"`:i.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${i.pattern}`:`${o[i.format]??n.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${n.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${x(n.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${n.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${n.origin}`;default:return"Input tidak sah"}}};function ay(){return{localeError:mP()}}var hP=()=>{let e={string:{unit:"tekens"},file:{unit:"bytes"},array:{unit:"elementen"},set:{unit:"elementen"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"getal";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"invoer",email:"emailadres",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 datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"};return n=>{switch(n.code){case"invalid_type":return`Ongeldige invoer: verwacht ${n.expected}, ontving ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ongeldige invoer: verwacht ${R(n.values[0])}`:`Ongeldige optie: verwacht \xE9\xE9n van ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Te lang: verwacht dat ${n.origin??"waarde"} ${i}${n.maximum.toString()} ${s.unit??"elementen"} bevat`:`Te lang: verwacht dat ${n.origin??"waarde"} ${i}${n.maximum.toString()} is`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Te kort: verwacht dat ${n.origin} ${i}${n.minimum.toString()} ${s.unit} bevat`:`Te kort: verwacht dat ${n.origin} ${i}${n.minimum.toString()} is`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ongeldige tekst: moet met "${i.prefix}" beginnen`:i.format==="ends_with"?`Ongeldige tekst: moet op "${i.suffix}" eindigen`:i.format==="includes"?`Ongeldige tekst: moet "${i.includes}" bevatten`:i.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${i.pattern}`:`Ongeldig: ${o[i.format]??n.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${n.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${n.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${n.origin}`;default:return"Ongeldige invoer"}}};function cy(){return{localeError:hP()}}var gP=()=>{let e={string:{unit:"tegn",verb:"\xE5 ha"},file:{unit:"bytes",verb:"\xE5 ha"},array:{unit:"elementer",verb:"\xE5 inneholde"},set:{unit:"elementer",verb:"\xE5 inneholde"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"tall";case"object":{if(Array.isArray(n))return"liste";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"input",email:"e-postadresse",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 dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Ugyldig input: forventet ${n.expected}, fikk ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ugyldig verdi: forventet ${R(n.values[0])}`:`Ugyldig valg: forventet en av ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`For stor(t): forventet ${n.origin??"value"} til \xE5 ha ${i}${n.maximum.toString()} ${s.unit??"elementer"}`:`For stor(t): forventet ${n.origin??"value"} til \xE5 ha ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`For lite(n): forventet ${n.origin} til \xE5 ha ${i}${n.minimum.toString()} ${s.unit}`:`For lite(n): forventet ${n.origin} til \xE5 ha ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ugyldig streng: m\xE5 starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: m\xE5 ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: m\xE5 inneholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: m\xE5 matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??n.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${n.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${n.origin}`;default:return"Ugyldig input"}}};function uy(){return{localeError:gP()}}var vP=()=>{let e={string:{unit:"harf",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"unsur",verb:"olmal\u0131d\u0131r"},set:{unit:"unsur",verb:"olmal\u0131d\u0131r"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"numara";case"object":{if(Array.isArray(n))return"saf";if(n===null)return"gayb";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"giren",email:"epostag\xE2h",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 heng\xE2m\u0131",date:"ISO tarihi",time:"ISO zaman\u0131",duration:"ISO m\xFCddeti",ipv4:"IPv4 ni\u015F\xE2n\u0131",ipv6:"IPv6 ni\u015F\xE2n\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\u015Fifreli metin",base64url:"base64url-\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"giren"};return n=>{switch(n.code){case"invalid_type":return`F\xE2sit giren: umulan ${n.expected}, al\u0131nan ${r(n.input)}`;case"invalid_value":return n.values.length===1?`F\xE2sit giren: umulan ${R(n.values[0])}`:`F\xE2sit tercih: m\xFBteberler ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Fazla b\xFCy\xFCk: ${n.origin??"value"}, ${i}${n.maximum.toString()} ${s.unit??"elements"} sahip olmal\u0131yd\u0131.`:`Fazla b\xFCy\xFCk: ${n.origin??"value"}, ${i}${n.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Fazla k\xFC\xE7\xFCk: ${n.origin}, ${i}${n.minimum.toString()} ${s.unit} sahip olmal\u0131yd\u0131.`:`Fazla k\xFC\xE7\xFCk: ${n.origin}, ${i}${n.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let i=n;return i.format==="starts_with"?`F\xE2sit metin: "${i.prefix}" ile ba\u015Flamal\u0131.`:i.format==="ends_with"?`F\xE2sit metin: "${i.suffix}" ile bitmeli.`:i.format==="includes"?`F\xE2sit metin: "${i.includes}" ihtiv\xE2 etmeli.`:i.format==="regex"?`F\xE2sit metin: ${i.pattern} nak\u015F\u0131na uymal\u0131.`:`F\xE2sit ${o[i.format]??n.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${n.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${n.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}};function ly(){return{localeError:vP()}}var _P=()=>{let e={string:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},file:{unit:"\u0628\u0627\u06CC\u067C\u0633",verb:"\u0648\u0644\u0631\u064A"},array:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},set:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0639\u062F\u062F";case"object":{if(Array.isArray(n))return"\u0627\u0631\u06D0";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0648\u0631\u0648\u062F\u064A",email:"\u0628\u0631\u06CC\u069A\u0646\u0627\u0644\u06CC\u06A9",url:"\u06CC\u0648 \u0622\u0631 \u0627\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0646\u06CC\u067C\u0647 \u0627\u0648 \u0648\u062E\u062A",date:"\u0646\u06D0\u067C\u0647",time:"\u0648\u062E\u062A",duration:"\u0645\u0648\u062F\u0647",ipv4:"\u062F IPv4 \u067E\u062A\u0647",ipv6:"\u062F IPv6 \u067E\u062A\u0647",cidrv4:"\u062F IPv4 \u0633\u0627\u062D\u0647",cidrv6:"\u062F IPv6 \u0633\u0627\u062D\u0647",base64:"base64-encoded \u0645\u062A\u0646",base64url:"base64url-encoded \u0645\u062A\u0646",json_string:"JSON \u0645\u062A\u0646",e164:"\u062F E.164 \u0634\u0645\u06D0\u0631\u0647",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u064A"};return n=>{switch(n.code){case"invalid_type":return`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${n.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${r(n.input)} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`;case"invalid_value":return n.values.length===1?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${R(n.values[0])} \u0648\u0627\u06CC`:`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${x(n.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${n.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${n.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${n.maximum.toString()} \u0648\u064A`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} ${s.unit} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${n.origin} \u0628\u0627\u06CC\u062F ${i}${n.minimum.toString()} \u0648\u064A`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`:i.format==="ends_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.suffix}" \u0633\u0631\u0647 \u067E\u0627\u06CC \u062A\u0647 \u0648\u0631\u0633\u064A\u0696\u064A`:i.format==="includes"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${i.includes}" \u0648\u0644\u0631\u064A`:i.format==="regex"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F ${i.pattern} \u0633\u0631\u0647 \u0645\u0637\u0627\u0628\u0642\u062A \u0648\u0644\u0631\u064A`:`${o[i.format]??n.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${n.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${n.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${x(n.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${n.origin} \u06A9\u06D0`;case"invalid_union":return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A";case"invalid_element":return`\u0646\u0627\u0633\u0645 \u0639\u0646\u0635\u0631 \u067E\u0647 ${n.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}};function dy(){return{localeError:_P()}}var yP=()=>{let e={string:{unit:"znak\xF3w",verb:"mie\u0107"},file:{unit:"bajt\xF3w",verb:"mie\u0107"},array:{unit:"element\xF3w",verb:"mie\u0107"},set:{unit:"element\xF3w",verb:"mie\u0107"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"liczba";case"object":{if(Array.isArray(n))return"tablica";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"wyra\u017Cenie",email:"adres email",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:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\u0105g znak\xF3w zakodowany w formacie base64",base64url:"ci\u0105g znak\xF3w zakodowany w formacie base64url",json_string:"ci\u0105g znak\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\u015Bcie"};return n=>{switch(n.code){case"invalid_type":return`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${n.expected}, otrzymano ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${R(n.values[0])}`:`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${n.maximum.toString()} ${s.unit??"element\xF3w"}`:`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${n.minimum.toString()} ${s.unit??"element\xF3w"}`:`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${n.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${i.prefix}"`:i.format==="ends_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${i.suffix}"`:i.format==="includes"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${i.includes}"`:i.format==="regex"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${i.pattern}`:`Nieprawid\u0142ow(y/a/e) ${o[i.format]??n.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${n.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${n.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${n.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}};function py(){return{localeError:yP()}}var bP=()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"n\xFAmero";case"object":{if(Array.isArray(n))return"array";if(n===null)return"nulo";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"padr\xE3o",email:"endere\xE7o de e-mail",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:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\xE7\xE3o ISO",ipv4:"endere\xE7o IPv4",ipv6:"endere\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"};return n=>{switch(n.code){case"invalid_type":return`Tipo inv\xE1lido: esperado ${n.expected}, recebido ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Entrada inv\xE1lida: esperado ${R(n.values[0])}`:`Op\xE7\xE3o inv\xE1lida: esperada uma das ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Muito grande: esperado que ${n.origin??"valor"} tivesse ${i}${n.maximum.toString()} ${s.unit??"elementos"}`:`Muito grande: esperado que ${n.origin??"valor"} fosse ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Muito pequeno: esperado que ${n.origin} tivesse ${i}${n.minimum.toString()} ${s.unit}`:`Muito pequeno: esperado que ${n.origin} fosse ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Texto inv\xE1lido: deve come\xE7ar com "${i.prefix}"`:i.format==="ends_with"?`Texto inv\xE1lido: deve terminar com "${i.suffix}"`:i.format==="includes"?`Texto inv\xE1lido: deve incluir "${i.includes}"`:i.format==="regex"?`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${i.pattern}`:`${o[i.format]??n.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${n.divisor}`;case"unrecognized_keys":return`Chave${n.keys.length>1?"s":""} desconhecida${n.keys.length>1?"s":""}: ${x(n.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${n.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${n.origin}`;default:return"Campo inv\xE1lido"}}};function fy(){return{localeError:bP()}}function my(e,t,r,o){let n=Math.abs(e),i=n%10,s=n%100;return s>=11&&s<=19?o:i===1?t:i>=2&&i<=4?r:o}var $P=()=>{let e={string:{unit:{one:"\u0441\u0438\u043C\u0432\u043E\u043B",few:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",many:"\u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u0430",many:"\u0431\u0430\u0439\u0442"},verb:"\u0438\u043C\u0435\u0442\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0441\u0438\u0432";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0438 \u0432\u0440\u0435\u043C\u044F",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u044F",duration:"ISO \u0434\u043B\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0441\u0442\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64",base64url:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64url",json_string:"JSON \u0441\u0442\u0440\u043E\u043A\u0430",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0432\u043E\u0434"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${n.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${R(n.values[0])}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0430\u0440\u0438\u0430\u043D\u0442: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0434\u043D\u043E \u0438\u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);if(s){let a=Number(n.maximum),c=my(a,s.unit.one,s.unit.few,s.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${n.maximum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);if(s){let a=Number(n.minimum),c=my(a,s.unit.one,s.unit.few,s.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${n.minimum.toString()} ${c}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${n.origin} \u0431\u0443\u0434\u0435\u0442 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0430\u0447\u0438\u043D\u0430\u0442\u044C\u0441\u044F \u0441 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0437\u0430\u043A\u0430\u043D\u0447\u0438\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0447\u0438\u0441\u043B\u043E: \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${n.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${n.keys.length>1?"\u0438":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${n.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435";case"invalid_element":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 ${n.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}};function hy(){return{localeError:$P()}}var wP=()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0161tevilo";case"object":{if(Array.isArray(n))return"tabela";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"vnos",email:"e-po\u0161tni naslov",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 datum in \u010Das",date:"ISO datum",time:"ISO \u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \u0161tevilka",jwt:"JWT",template_literal:"vnos"};return n=>{switch(n.code){case"invalid_type":return`Neveljaven vnos: pri\u010Dakovano ${n.expected}, prejeto ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Neveljaven vnos: pri\u010Dakovano ${R(n.values[0])}`:`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Preveliko: pri\u010Dakovano, da bo ${n.origin??"vrednost"} imelo ${i}${n.maximum.toString()} ${s.unit??"elementov"}`:`Preveliko: pri\u010Dakovano, da bo ${n.origin??"vrednost"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Premajhno: pri\u010Dakovano, da bo ${n.origin} imelo ${i}${n.minimum.toString()} ${s.unit}`:`Premajhno: pri\u010Dakovano, da bo ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Neveljaven niz: mora se za\u010Deti z "${i.prefix}"`:i.format==="ends_with"?`Neveljaven niz: mora se kon\u010Dati z "${i.suffix}"`:i.format==="includes"?`Neveljaven niz: mora vsebovati "${i.includes}"`:i.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${i.pattern}`:`Neveljaven ${o[i.format]??n.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${n.divisor}`;case"unrecognized_keys":return`Neprepoznan${n.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${x(n.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${n.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${n.origin}`;default:return"Neveljaven vnos"}}};function gy(){return{localeError:wP()}}var kP=()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\xE5lla"},set:{unit:"objekt",verb:"att inneh\xE5lla"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"antal";case"object":{if(Array.isArray(n))return"lista";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"regulj\xE4rt uttryck",email:"e-postadress",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-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\xE4ng",base64url:"base64url-kodad str\xE4ng",json_string:"JSON-str\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"};return n=>{switch(n.code){case"invalid_type":return`Ogiltig inmatning: f\xF6rv\xE4ntat ${n.expected}, fick ${r(n.input)}`;case"invalid_value":return n.values.length===1?`Ogiltig inmatning: f\xF6rv\xE4ntat ${R(n.values[0])}`:`Ogiltigt val: f\xF6rv\xE4ntade en av ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`F\xF6r stor(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.maximum.toString()} ${s.unit??"element"}`:`F\xF6r stor(t): f\xF6rv\xE4ntat ${n.origin??"v\xE4rdet"} att ha ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`F\xF6r lite(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.minimum.toString()} ${s.unit}`:`F\xF6r lite(t): f\xF6rv\xE4ntade ${n.origin??"v\xE4rdet"} att ha ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${i.prefix}"`:i.format==="ends_with"?`Ogiltig str\xE4ng: m\xE5ste sluta med "${i.suffix}"`:i.format==="includes"?`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${i.includes}"`:i.format==="regex"?`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${i.pattern}"`:`Ogiltig(t) ${o[i.format]??n.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${n.divisor}`;case"unrecognized_keys":return`${n.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${x(n.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${n.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${n.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}};function vy(){return{localeError:kP()}}var xP=()=>{let e={string:{unit:"\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},file:{unit:"\u0BAA\u0BC8\u0B9F\u0BCD\u0B9F\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},array:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},set:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u0B8E\u0BA3\u0BCD \u0B85\u0BB2\u0BCD\u0BB2\u0BBE\u0BA4\u0BA4\u0BC1":"\u0B8E\u0BA3\u0BCD";case"object":{if(Array.isArray(n))return"\u0B85\u0BA3\u0BBF";if(n===null)return"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1",email:"\u0BAE\u0BBF\u0BA9\u0BCD\u0BA9\u0B9E\u0BCD\u0B9A\u0BB2\u0BCD \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",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 \u0BA4\u0BC7\u0BA4\u0BBF \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",date:"ISO \u0BA4\u0BC7\u0BA4\u0BBF",time:"ISO \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",duration:"ISO \u0B95\u0BBE\u0BB2 \u0B85\u0BB3\u0BB5\u0BC1",ipv4:"IPv4 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",ipv6:"IPv6 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",cidrv4:"IPv4 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",cidrv6:"IPv6 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",base64:"base64-encoded \u0B9A\u0BB0\u0BAE\u0BCD",base64url:"base64url-encoded \u0B9A\u0BB0\u0BAE\u0BCD",json_string:"JSON \u0B9A\u0BB0\u0BAE\u0BCD",e164:"E.164 \u0B8E\u0BA3\u0BCD",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${R(n.values[0])}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0BB0\u0BC1\u0BAA\u0BCD\u0BAA\u0BAE\u0BCD: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${x(n.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${n.maximum.toString()} ${s.unit??"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD"} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${n.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin} ${i}${n.minimum.toString()} ${s.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${n.origin} ${i}${n.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.prefix}" \u0B87\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="ends_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.suffix}" \u0B87\u0BB2\u0BCD \u0BAE\u0BC1\u0B9F\u0BBF\u0BB5\u0B9F\u0BC8\u0BAF \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="includes"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.includes}" \u0B90 \u0B89\u0BB3\u0BCD\u0BB3\u0B9F\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="regex"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: ${i.pattern} \u0BAE\u0BC1\u0BB1\u0BC8\u0BAA\u0BBE\u0B9F\u0BCD\u0B9F\u0BC1\u0B9F\u0BA9\u0BCD \u0BAA\u0BCA\u0BB0\u0BC1\u0BA8\u0BCD\u0BA4 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${n.divisor} \u0B87\u0BA9\u0BCD \u0BAA\u0BB2\u0BAE\u0BBE\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;case"unrecognized_keys":return`\u0B85\u0B9F\u0BC8\u0BAF\u0BBE\u0BB3\u0BAE\u0BCD \u0BA4\u0BC6\u0BB0\u0BBF\u0BAF\u0BBE\u0BA4 \u0BB5\u0BBF\u0B9A\u0BC8${n.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0B9A\u0BC8`;case"invalid_union":return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1";case"invalid_element":return`${n.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1`;default:return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1"}}};function _y(){return{localeError:xP()}}var SP=()=>{let e={string:{unit:"\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},file:{unit:"\u0E44\u0E1A\u0E15\u0E4C",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},array:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},set:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u0E44\u0E21\u0E48\u0E43\u0E0A\u0E48\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02 (NaN)":"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02";case"object":{if(Array.isArray(n))return"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)";if(n===null)return"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19",email:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E2D\u0E35\u0E40\u0E21\u0E25",url:"URL",emoji:"\u0E2D\u0E34\u0E42\u0E21\u0E08\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",date:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E41\u0E1A\u0E1A ISO",time:"\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",duration:"\u0E0A\u0E48\u0E27\u0E07\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",ipv4:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv4",ipv6:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv6",cidrv4:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv4",cidrv6:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv6",base64:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64",base64url:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64 \u0E2A\u0E33\u0E2B\u0E23\u0E31\u0E1A URL",json_string:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A JSON",e164:"\u0E40\u0E1A\u0E2D\u0E23\u0E4C\u0E42\u0E17\u0E23\u0E28\u0E31\u0E1E\u0E17\u0E4C\u0E23\u0E30\u0E2B\u0E27\u0E48\u0E32\u0E07\u0E1B\u0E23\u0E30\u0E40\u0E17\u0E28 (E.164)",jwt:"\u0E42\u0E17\u0E40\u0E04\u0E19 JWT",template_literal:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19"};return n=>{switch(n.code){case"invalid_type":return`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${n.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${R(n.values[0])}`:`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19\u0E2B\u0E19\u0E36\u0E48\u0E07\u0E43\u0E19 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",s=t(n.origin);return s?`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.maximum.toString()} ${s.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`:`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",s=t(n.origin);return s?`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.minimum.toString()} ${s.unit}`:`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${n.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E02\u0E36\u0E49\u0E19\u0E15\u0E49\u0E19\u0E14\u0E49\u0E27\u0E22 "${i.prefix}"`:i.format==="ends_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E25\u0E07\u0E17\u0E49\u0E32\u0E22\u0E14\u0E49\u0E27\u0E22 "${i.suffix}"`:i.format==="includes"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E21\u0E35 "${i.includes}" \u0E2D\u0E22\u0E39\u0E48\u0E43\u0E19\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21`:i.format==="regex"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14 ${i.pattern}`:`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${o[i.format]??n.format}`}case"not_multiple_of":return`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E40\u0E1B\u0E47\u0E19\u0E08\u0E33\u0E19\u0E27\u0E19\u0E17\u0E35\u0E48\u0E2B\u0E32\u0E23\u0E14\u0E49\u0E27\u0E22 ${n.divisor} \u0E44\u0E14\u0E49\u0E25\u0E07\u0E15\u0E31\u0E27`;case"unrecognized_keys":return`\u0E1E\u0E1A\u0E04\u0E35\u0E22\u0E4C\u0E17\u0E35\u0E48\u0E44\u0E21\u0E48\u0E23\u0E39\u0E49\u0E08\u0E31\u0E01: ${x(n.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${n.origin}`;case"invalid_union":return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E44\u0E21\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E22\u0E39\u0E40\u0E19\u0E35\u0E22\u0E19\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E44\u0E27\u0E49";case"invalid_element":return`\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${n.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}};function yy(){return{localeError:SP()}}var TP=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},PP=()=>{let e={string:{unit:"karakter",verb:"olmal\u0131"},file:{unit:"bayt",verb:"olmal\u0131"},array:{unit:"\xF6\u011Fe",verb:"olmal\u0131"},set:{unit:"\xF6\u011Fe",verb:"olmal\u0131"}};function t(o){return e[o]??null}let r={regex:"girdi",email:"e-posta adresi",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 tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\u0131\u011F\u0131",cidrv6:"IPv6 aral\u0131\u011F\u0131",base64:"base64 ile \u015Fifrelenmi\u015F metin",base64url:"base64url ile \u015Fifrelenmi\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"\u015Eablon dizesi"};return o=>{switch(o.code){case"invalid_type":return`Ge\xE7ersiz de\u011Fer: beklenen ${o.expected}, al\u0131nan ${TP(o.input)}`;case"invalid_value":return o.values.length===1?`Ge\xE7ersiz de\u011Fer: beklenen ${R(o.values[0])}`:`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${x(o.values,"|")}`;case"too_big":{let n=o.inclusive?"<=":"<",i=t(o.origin);return i?`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${n}${o.maximum.toString()} ${i.unit??"\xF6\u011Fe"}`:`\xC7ok b\xFCy\xFCk: beklenen ${o.origin??"de\u011Fer"} ${n}${o.maximum.toString()}`}case"too_small":{let n=o.inclusive?">=":">",i=t(o.origin);return i?`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${n}${o.minimum.toString()} ${i.unit}`:`\xC7ok k\xFC\xE7\xFCk: beklenen ${o.origin} ${n}${o.minimum.toString()}`}case"invalid_format":{let n=o;return n.format==="starts_with"?`Ge\xE7ersiz metin: "${n.prefix}" ile ba\u015Flamal\u0131`:n.format==="ends_with"?`Ge\xE7ersiz metin: "${n.suffix}" ile bitmeli`:n.format==="includes"?`Ge\xE7ersiz metin: "${n.includes}" i\xE7ermeli`:n.format==="regex"?`Ge\xE7ersiz metin: ${n.pattern} desenine uymal\u0131`:`Ge\xE7ersiz ${r[n.format]??o.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${o.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${o.keys.length>1?"lar":""}: ${x(o.keys,", ")}`;case"invalid_key":return`${o.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${o.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}};function by(){return{localeError:PP()}}var zP=()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},file:{unit:"\u0431\u0430\u0439\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0447\u0438\u0441\u043B\u043E";case"object":{if(Array.isArray(n))return"\u043C\u0430\u0441\u0438\u0432";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u0435\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0457 \u043F\u043E\u0448\u0442\u0438",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0434\u0430\u0442\u0430 \u0442\u0430 \u0447\u0430\u0441 ISO",date:"\u0434\u0430\u0442\u0430 ISO",time:"\u0447\u0430\u0441 ISO",duration:"\u0442\u0440\u0438\u0432\u0430\u043B\u0456\u0441\u0442\u044C ISO",ipv4:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv4",ipv6:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv6",cidrv4:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv4",cidrv6:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv6",base64:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64",base64url:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64url",json_string:"\u0440\u044F\u0434\u043E\u043A JSON",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"};return n=>{switch(n.code){case"invalid_type":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${n.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${R(n.values[0])}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0430 \u043E\u043F\u0446\u0456\u044F: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F \u043E\u0434\u043D\u0435 \u0437 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${n.origin} \u0431\u0443\u0434\u0435 ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043F\u043E\u0447\u0438\u043D\u0430\u0442\u0438\u0441\u044F \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0437\u0430\u043A\u0456\u043D\u0447\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043C\u0456\u0441\u0442\u0438\u0442\u0438 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u0430\u0442\u0438 \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0447\u0438\u0441\u043B\u043E: \u043F\u043E\u0432\u0438\u043D\u043D\u043E \u0431\u0443\u0442\u0438 \u043A\u0440\u0430\u0442\u043D\u0438\u043C ${n.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${n.keys.length>1?"\u0456":""}: ${x(n.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${n.origin}`;case"invalid_union":return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456";case"invalid_element":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F \u0443 ${n.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}};function $y(){return{localeError:zP()}}var EP=()=>{let e={string:{unit:"\u062D\u0631\u0648\u0641",verb:"\u06C1\u0648\u0646\u0627"},file:{unit:"\u0628\u0627\u0626\u0679\u0633",verb:"\u06C1\u0648\u0646\u0627"},array:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"},set:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"\u0646\u0645\u0628\u0631";case"object":{if(Array.isArray(n))return"\u0622\u0631\u06D2";if(n===null)return"\u0646\u0644";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0627\u0646 \u067E\u0679",email:"\u0627\u06CC \u0645\u06CC\u0644 \u0627\u06CC\u0688\u0631\u06CC\u0633",url:"\u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",uuidv4:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 4",uuidv6:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 6",nanoid:"\u0646\u06CC\u0646\u0648 \u0622\u0626\u06CC \u0688\u06CC",guid:"\u062C\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid2:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC 2",ulid:"\u06CC\u0648 \u0627\u06CC\u0644 \u0622\u0626\u06CC \u0688\u06CC",xid:"\u0627\u06CC\u06A9\u0633 \u0622\u0626\u06CC \u0688\u06CC",ksuid:"\u06A9\u06D2 \u0627\u06CC\u0633 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",datetime:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0688\u06CC\u0679 \u0679\u0627\u0626\u0645",date:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u062A\u0627\u0631\u06CC\u062E",time:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0648\u0642\u062A",duration:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0645\u062F\u062A",ipv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0627\u06CC\u0688\u0631\u06CC\u0633",ipv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0627\u06CC\u0688\u0631\u06CC\u0633",cidrv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0631\u06CC\u0646\u062C",cidrv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0631\u06CC\u0646\u062C",base64:"\u0628\u06CC\u0633 64 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",base64url:"\u0628\u06CC\u0633 64 \u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",json_string:"\u062C\u06D2 \u0627\u06CC\u0633 \u0627\u0648 \u0627\u06CC\u0646 \u0633\u0679\u0631\u0646\u06AF",e164:"\u0627\u06CC 164 \u0646\u0645\u0628\u0631",jwt:"\u062C\u06D2 \u0688\u0628\u0644\u06CC\u0648 \u0679\u06CC",template_literal:"\u0627\u0646 \u067E\u0679"};return n=>{switch(n.code){case"invalid_type":return`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${n.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${r(n.input)} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`;case"invalid_value":return n.values.length===1?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${R(n.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`:`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${x(n.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u0628\u06C1\u062A \u0628\u0691\u0627: ${n.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${i}${n.maximum.toString()} ${s.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0628\u0691\u0627: ${n.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${i}${n.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${n.origin} \u06A9\u06D2 ${i}${n.minimum.toString()} ${s.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${n.origin} \u06A9\u0627 ${i}${n.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.prefix}" \u0633\u06D2 \u0634\u0631\u0648\u0639 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="ends_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="includes"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="regex"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: \u067E\u06CC\u0679\u0631\u0646 ${i.pattern} \u0633\u06D2 \u0645\u06CC\u0686 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:`\u063A\u0644\u0637 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${n.divisor} \u06A9\u0627 \u0645\u0636\u0627\u0639\u0641 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;case"unrecognized_keys":return`\u063A\u06CC\u0631 \u062A\u0633\u0644\u06CC\u0645 \u0634\u062F\u06C1 \u06A9\u06CC${n.keys.length>1?"\u0632":""}: ${x(n.keys,"\u060C ")}`;case"invalid_key":return`${n.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${n.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}};function wy(){return{localeError:EP()}}var IP=()=>{let e={string:{unit:"k\xFD t\u1EF1",verb:"c\xF3"},file:{unit:"byte",verb:"c\xF3"},array:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"},set:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"s\u1ED1";case"object":{if(Array.isArray(n))return"m\u1EA3ng";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u0111\u1EA7u v\xE0o",email:"\u0111\u1ECBa ch\u1EC9 email",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:"ng\xE0y gi\u1EDD ISO",date:"ng\xE0y ISO",time:"gi\u1EDD ISO",duration:"kho\u1EA3ng th\u1EDDi gian ISO",ipv4:"\u0111\u1ECBa ch\u1EC9 IPv4",ipv6:"\u0111\u1ECBa ch\u1EC9 IPv6",cidrv4:"d\u1EA3i IPv4",cidrv6:"d\u1EA3i IPv6",base64:"chu\u1ED7i m\xE3 h\xF3a base64",base64url:"chu\u1ED7i m\xE3 h\xF3a base64url",json_string:"chu\u1ED7i JSON",e164:"s\u1ED1 E.164",jwt:"JWT",template_literal:"\u0111\u1EA7u v\xE0o"};return n=>{switch(n.code){case"invalid_type":return`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${n.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${R(n.values[0])}`:`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${n.origin??"gi\xE1 tr\u1ECB"} ${s.verb} ${i}${n.maximum.toString()} ${s.unit??"ph\u1EA7n t\u1EED"}`:`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${n.origin??"gi\xE1 tr\u1ECB"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${n.origin} ${s.verb} ${i}${n.minimum.toString()} ${s.unit}`:`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${i.prefix}"`:i.format==="ends_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${i.suffix}"`:i.format==="includes"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${i.includes}"`:i.format==="regex"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${i.pattern}`:`${o[i.format]??n.format} kh\xF4ng h\u1EE3p l\u1EC7`}case"not_multiple_of":return`S\u1ED1 kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i l\xE0 b\u1ED9i s\u1ED1 c\u1EE7a ${n.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${x(n.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${n.origin}`;case"invalid_union":return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7";case"invalid_element":return`Gi\xE1 tr\u1ECB kh\xF4ng h\u1EE3p l\u1EC7 trong ${n.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}};function ky(){return{localeError:IP()}}var OP=()=>{let e={string:{unit:"\u5B57\u7B26",verb:"\u5305\u542B"},file:{unit:"\u5B57\u8282",verb:"\u5305\u542B"},array:{unit:"\u9879",verb:"\u5305\u542B"},set:{unit:"\u9879",verb:"\u5305\u542B"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"\u975E\u6570\u5B57(NaN)":"\u6570\u5B57";case"object":{if(Array.isArray(n))return"\u6570\u7EC4";if(n===null)return"\u7A7A\u503C(null)";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u8F93\u5165",email:"\u7535\u5B50\u90AE\u4EF6",url:"URL",emoji:"\u8868\u60C5\u7B26\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u671F\u65F6\u95F4",date:"ISO\u65E5\u671F",time:"ISO\u65F6\u95F4",duration:"ISO\u65F6\u957F",ipv4:"IPv4\u5730\u5740",ipv6:"IPv6\u5730\u5740",cidrv4:"IPv4\u7F51\u6BB5",cidrv6:"IPv6\u7F51\u6BB5",base64:"base64\u7F16\u7801\u5B57\u7B26\u4E32",base64url:"base64url\u7F16\u7801\u5B57\u7B26\u4E32",json_string:"JSON\u5B57\u7B26\u4E32",e164:"E.164\u53F7\u7801",jwt:"JWT",template_literal:"\u8F93\u5165"};return n=>{switch(n.code){case"invalid_type":return`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${n.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${R(n.values[0])}`:`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${n.origin??"\u503C"} ${i}${n.maximum.toString()} ${s.unit??"\u4E2A\u5143\u7D20"}`:`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${n.origin??"\u503C"} ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${n.origin} ${i}${n.minimum.toString()} ${s.unit}`:`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${n.origin} ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.prefix}" \u5F00\u5934`:i.format==="ends_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.suffix}" \u7ED3\u5C3E`:i.format==="includes"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${i.pattern}`:`\u65E0\u6548${o[i.format]??n.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${n.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${x(n.keys,", ")}`;case"invalid_key":return`${n.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${n.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}};function xy(){return{localeError:OP()}}var jP=()=>{let e={string:{unit:"\u5B57\u5143",verb:"\u64C1\u6709"},file:{unit:"\u4F4D\u5143\u7D44",verb:"\u64C1\u6709"},array:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"},set:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"}};function t(n){return e[n]??null}let r=n=>{let i=typeof n;switch(i){case"number":return Number.isNaN(n)?"NaN":"number";case"object":{if(Array.isArray(n))return"array";if(n===null)return"null";if(Object.getPrototypeOf(n)!==Object.prototype&&n.constructor)return n.constructor.name}}return i},o={regex:"\u8F38\u5165",email:"\u90F5\u4EF6\u5730\u5740",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 \u65E5\u671F\u6642\u9593",date:"ISO \u65E5\u671F",time:"ISO \u6642\u9593",duration:"ISO \u671F\u9593",ipv4:"IPv4 \u4F4D\u5740",ipv6:"IPv6 \u4F4D\u5740",cidrv4:"IPv4 \u7BC4\u570D",cidrv6:"IPv6 \u7BC4\u570D",base64:"base64 \u7DE8\u78BC\u5B57\u4E32",base64url:"base64url \u7DE8\u78BC\u5B57\u4E32",json_string:"JSON \u5B57\u4E32",e164:"E.164 \u6578\u503C",jwt:"JWT",template_literal:"\u8F38\u5165"};return n=>{switch(n.code){case"invalid_type":return`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${n.expected}\uFF0C\u4F46\u6536\u5230 ${r(n.input)}`;case"invalid_value":return n.values.length===1?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${R(n.values[0])}`:`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${x(n.values,"|")}`;case"too_big":{let i=n.inclusive?"<=":"<",s=t(n.origin);return s?`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${n.origin??"\u503C"} \u61C9\u70BA ${i}${n.maximum.toString()} ${s.unit??"\u500B\u5143\u7D20"}`:`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${n.origin??"\u503C"} \u61C9\u70BA ${i}${n.maximum.toString()}`}case"too_small":{let i=n.inclusive?">=":">",s=t(n.origin);return s?`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${n.origin} \u61C9\u70BA ${i}${n.minimum.toString()} ${s.unit}`:`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${n.origin} \u61C9\u70BA ${i}${n.minimum.toString()}`}case"invalid_format":{let i=n;return i.format==="starts_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.prefix}" \u958B\u982D`:i.format==="ends_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.suffix}" \u7D50\u5C3E`:i.format==="includes"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${i.pattern}`:`\u7121\u6548\u7684 ${o[i.format]??n.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${n.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${n.keys.length>1?"\u5011":""}\uFF1A${x(n.keys,"\u3001")}`;case"invalid_key":return`${n.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${n.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}};function Sy(){return{localeError:jP()}}var ou=Symbol("ZodOutput"),iu=Symbol("ZodInput"),yo=class{constructor(){this._map=new Map,this._idmap=new Map}add(t,...r){let o=r[0];if(this._map.set(t,o),o&&typeof o=="object"&&"id"in o){if(this._idmap.has(o.id))throw new Error(`ID ${o.id} already exists in the registry`);this._idmap.set(o.id,t)}return this}clear(){return this._map=new Map,this._idmap=new Map,this}remove(t){let r=this._map.get(t);return r&&typeof r=="object"&&"id"in r&&this._idmap.delete(r.id),this._map.delete(t),this}get(t){let r=t._zod.parent;if(r){let o={...this.get(r)??{}};return delete o.id,{...o,...this._map.get(t)}}return this._map.get(t)}has(t){return this._map.has(t)}};function qi(){return new yo}var Wt=qi();function su(e,t){return new e({type:"string",...O(t)})}function uf(e,t){return new e({type:"string",coerce:!0,...O(t)})}function Mi(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...O(t)})}function bo(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...O(t)})}function Ui(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...O(t)})}function Zi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...O(t)})}function Vi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...O(t)})}function Li(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...O(t)})}function Fi(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...O(t)})}function Gi(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...O(t)})}function Wi(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...O(t)})}function Ki(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...O(t)})}function Hi(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...O(t)})}function Ji(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...O(t)})}function Bi(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...O(t)})}function Yi(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...O(t)})}function Xi(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...O(t)})}function Qi(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...O(t)})}function es(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...O(t)})}function ts(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...O(t)})}function rs(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...O(t)})}function ns(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...O(t)})}function os(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...O(t)})}function is(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...O(t)})}var au={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function lf(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...O(t)})}function df(e,t){return new e({type:"string",format:"date",check:"string_format",...O(t)})}function pf(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...O(t)})}function ff(e,t){return new e({type:"string",format:"duration",check:"string_format",...O(t)})}function cu(e,t){return new e({type:"number",checks:[],...O(t)})}function mf(e,t){return new e({type:"number",coerce:!0,checks:[],...O(t)})}function uu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...O(t)})}function lu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...O(t)})}function du(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...O(t)})}function pu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...O(t)})}function fu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...O(t)})}function mu(e,t){return new e({type:"boolean",...O(t)})}function hf(e,t){return new e({type:"boolean",coerce:!0,...O(t)})}function hu(e,t){return new e({type:"bigint",...O(t)})}function gf(e,t){return new e({type:"bigint",coerce:!0,...O(t)})}function gu(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...O(t)})}function vu(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...O(t)})}function _u(e,t){return new e({type:"symbol",...O(t)})}function yu(e,t){return new e({type:"undefined",...O(t)})}function bu(e,t){return new e({type:"null",...O(t)})}function $u(e){return new e({type:"any"})}function kn(e){return new e({type:"unknown"})}function wu(e,t){return new e({type:"never",...O(t)})}function ku(e,t){return new e({type:"void",...O(t)})}function xu(e,t){return new e({type:"date",...O(t)})}function vf(e,t){return new e({type:"date",coerce:!0,...O(t)})}function Su(e,t){return new e({type:"nan",...O(t)})}function wr(e,t){return new nc({check:"less_than",...O(t),value:e,inclusive:!1})}function jt(e,t){return new nc({check:"less_than",...O(t),value:e,inclusive:!0})}function kr(e,t){return new oc({check:"greater_than",...O(t),value:e,inclusive:!1})}function vt(e,t){return new oc({check:"greater_than",...O(t),value:e,inclusive:!0})}function _f(e){return kr(0,e)}function yf(e){return wr(0,e)}function bf(e){return jt(0,e)}function $f(e){return vt(0,e)}function xn(e,t){return new Dp({check:"multiple_of",...O(t),value:e})}function $o(e,t){return new Up({check:"max_size",...O(t),maximum:e})}function Sn(e,t){return new Zp({check:"min_size",...O(t),minimum:e})}function ss(e,t){return new Vp({check:"size_equals",...O(t),size:e})}function wo(e,t){return new Lp({check:"max_length",...O(t),maximum:e})}function Fr(e,t){return new Fp({check:"min_length",...O(t),minimum:e})}function ko(e,t){return new Gp({check:"length_equals",...O(t),length:e})}function as(e,t){return new Wp({check:"string_format",format:"regex",...O(t),pattern:e})}function cs(e){return new Kp({check:"string_format",format:"lowercase",...O(e)})}function us(e){return new Hp({check:"string_format",format:"uppercase",...O(e)})}function ls(e,t){return new Jp({check:"string_format",format:"includes",...O(t),includes:e})}function ds(e,t){return new Bp({check:"string_format",format:"starts_with",...O(t),prefix:e})}function ps(e,t){return new Yp({check:"string_format",format:"ends_with",...O(t),suffix:e})}function wf(e,t,r){return new Xp({check:"property",property:e,schema:t,...O(r)})}function fs(e,t){return new Qp({check:"mime_type",mime:e,...O(t)})}function xr(e){return new ef({check:"overwrite",tx:e})}function ms(e){return xr(t=>t.normalize(e))}function hs(){return xr(e=>e.trim())}function gs(){return xr(e=>e.toLowerCase())}function vs(){return xr(e=>e.toUpperCase())}function _s(e,t,r){return new e({type:"array",element:t,...O(r)})}function NP(e,t,r){return new e({type:"union",options:t,...O(r)})}function RP(e,t,r,o){return new e({type:"union",options:r,discriminator:t,...O(o)})}function CP(e,t,r){return new e({type:"intersection",left:t,right:r})}function kf(e,t,r,o){let n=r instanceof W,i=n?o:r,s=n?r:null;return new e({type:"tuple",items:t,rest:s,...O(i)})}function AP(e,t,r,o){return new e({type:"record",keyType:t,valueType:r,...O(o)})}function DP(e,t,r,o){return new e({type:"map",keyType:t,valueType:r,...O(o)})}function qP(e,t,r){return new e({type:"set",valueType:t,...O(r)})}function MP(e,t,r){let o=Array.isArray(t)?Object.fromEntries(t.map(n=>[n,n])):t;return new e({type:"enum",entries:o,...O(r)})}function UP(e,t,r){return new e({type:"enum",entries:t,...O(r)})}function ZP(e,t,r){return new e({type:"literal",values:Array.isArray(t)?t:[t],...O(r)})}function Tu(e,t){return new e({type:"file",...O(t)})}function VP(e,t){return new e({type:"transform",transform:t})}function LP(e,t){return new e({type:"optional",innerType:t})}function FP(e,t){return new e({type:"nullable",innerType:t})}function GP(e,t,r){return new e({type:"default",innerType:t,get defaultValue(){return typeof r=="function"?r():r}})}function WP(e,t,r){return new e({type:"nonoptional",innerType:t,...O(r)})}function KP(e,t){return new e({type:"success",innerType:t})}function HP(e,t,r){return new e({type:"catch",innerType:t,catchValue:typeof r=="function"?r:()=>r})}function JP(e,t,r){return new e({type:"pipe",in:t,out:r})}function BP(e,t){return new e({type:"readonly",innerType:t})}function YP(e,t,r){return new e({type:"template_literal",parts:t,...O(r)})}function XP(e,t){return new e({type:"lazy",getter:t})}function QP(e,t){return new e({type:"promise",innerType:t})}function Pu(e,t,r){let o=O(r);return o.abort??(o.abort=!0),new e({type:"custom",check:"custom",fn:t,...o})}function zu(e,t,r){return new e({type:"custom",check:"custom",fn:t,...O(r)})}function Eu(e,t){let r=O(t),o=r.truthy??["true","1","yes","on","y","enabled"],n=r.falsy??["false","0","no","off","n","disabled"];r.case!=="sensitive"&&(o=o.map(p=>typeof p=="string"?p.toLowerCase():p),n=n.map(p=>typeof p=="string"?p.toLowerCase():p));let i=new Set(o),s=new Set(n),a=e.Pipe??vo,c=e.Boolean??mo,u=e.String??Vr,l=e.Transform??go,d=new l({type:"transform",transform:(p,f)=>{let v=p;return r.case!=="sensitive"&&(v=v.toLowerCase()),i.has(v)?!0:s.has(v)?!1:(f.issues.push({code:"invalid_value",expected:"stringbool",values:[...i,...s],input:f.value,inst:d}),{})},error:r.error}),h=new a({type:"pipe",in:new u({type:"string",error:r.error}),out:d,error:r.error});return new a({type:"pipe",in:h,out:new c({type:"boolean",error:r.error}),error:r.error})}function Iu(e,t,r,o={}){let n=O(o),i={...O(o),check:"string_format",type:"string",format:t,fn:typeof r=="function"?r:a=>r.test(a),...n};return r instanceof RegExp&&(i.pattern=r),new e(i)}var Ou=class{constructor(t){this._def=t,this.def=t}implement(t){if(typeof t!="function")throw new Error("implement() must be called with a function");let r=((...o)=>{let n=this._def.input?yn(this._def.input,o,void 0,{callee:r}):o;if(!Array.isArray(n))throw new Error("Invalid arguments schema: not an array or tuple schema.");let i=t(...n);return this._def.output?yn(this._def.output,i,void 0,{callee:r}):i});return r}implementAsync(t){if(typeof t!="function")throw new Error("implement() must be called with a function");let r=(async(...o)=>{let n=this._def.input?await bn(this._def.input,o,void 0,{callee:r}):o;if(!Array.isArray(n))throw new Error("Invalid arguments schema: not an array or tuple schema.");let i=await t(...n);return this._def.output?bn(this._def.output,i,void 0,{callee:r}):i});return r}input(...t){let r=this.constructor;return Array.isArray(t[0])?new r({type:"function",input:new Lr({type:"tuple",items:t[0],rest:t[1]}),output:this._def.output}):new r({type:"function",input:t[0],output:this._def.output})}output(t){let r=this.constructor;return new r({type:"function",input:this._def.input,output:t})}};function ju(e){return new Ou({type:"function",input:Array.isArray(e?.input)?kf(Lr,e?.input):e?.input??_s(ho,kn(wn)),output:e?.output??kn(wn)})}var ys=class{constructor(t){this.counter=0,this.metadataRegistry=t?.metadata??Wt,this.target=t?.target??"draft-2020-12",this.unrepresentable=t?.unrepresentable??"throw",this.override=t?.override??(()=>{}),this.io=t?.io??"output",this.seen=new Map}process(t,r={path:[],schemaPath:[]}){var o;let n=t._zod.def,i={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},s=this.seen.get(t);if(s)return s.count++,r.schemaPath.includes(t)&&(s.cycle=r.path),s.schema;let a={schema:{},count:1,cycle:void 0,path:r.path};this.seen.set(t,a);let c=t._zod.toJSONSchema?.();if(c)a.schema=c;else{let d={...r,schemaPath:[...r.schemaPath,t],path:r.path},h=t._zod.parent;if(h)a.ref=h,this.process(h,d),this.seen.get(h).isParent=!0;else{let m=a.schema;switch(n.type){case"string":{let p=m;p.type="string";let{minimum:f,maximum:v,format:y,patterns:w,contentEncoding:k}=t._zod.bag;if(typeof f=="number"&&(p.minLength=f),typeof v=="number"&&(p.maxLength=v),y&&(p.format=i[y]??y,p.format===""&&delete p.format),k&&(p.contentEncoding=k),w&&w.size>0){let E=[...w];E.length===1?p.pattern=E[0].source:E.length>1&&(a.schema.allOf=[...E.map(P=>({...this.target==="draft-7"?{type:"string"}:{},pattern:P.source}))])}break}case"number":{let p=m,{minimum:f,maximum:v,format:y,multipleOf:w,exclusiveMaximum:k,exclusiveMinimum:E}=t._zod.bag;typeof y=="string"&&y.includes("int")?p.type="integer":p.type="number",typeof E=="number"&&(p.exclusiveMinimum=E),typeof f=="number"&&(p.minimum=f,typeof E=="number"&&(E>=f?delete p.minimum:delete p.exclusiveMinimum)),typeof k=="number"&&(p.exclusiveMaximum=k),typeof v=="number"&&(p.maximum=v,typeof k=="number"&&(k<=v?delete p.maximum:delete p.exclusiveMaximum)),typeof w=="number"&&(p.multipleOf=w);break}case"boolean":{let p=m;p.type="boolean";break}case"bigint":{if(this.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema");break}case"symbol":{if(this.unrepresentable==="throw")throw new 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 new Error("Undefined cannot be represented in JSON Schema");break}case"void":{if(this.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema");break}case"never":{m.not={};break}case"date":{if(this.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema");break}case"array":{let p=m,{minimum:f,maximum:v}=t._zod.bag;typeof f=="number"&&(p.minItems=f),typeof v=="number"&&(p.maxItems=v),p.type="array",p.items=this.process(n.element,{...d,path:[...d.path,"items"]});break}case"object":{let p=m;p.type="object",p.properties={};let f=n.shape;for(let w in f)p.properties[w]=this.process(f[w],{...d,path:[...d.path,"properties",w]});let v=new Set(Object.keys(f)),y=new Set([...v].filter(w=>{let k=n.shape[w]._zod;return this.io==="input"?k.optin===void 0:k.optout===void 0}));y.size>0&&(p.required=Array.from(y)),n.catchall?._zod.def.type==="never"?p.additionalProperties=!1:n.catchall?n.catchall&&(p.additionalProperties=this.process(n.catchall,{...d,path:[...d.path,"additionalProperties"]})):this.io==="output"&&(p.additionalProperties=!1);break}case"union":{let p=m;p.anyOf=n.options.map((f,v)=>this.process(f,{...d,path:[...d.path,"anyOf",v]}));break}case"intersection":{let p=m,f=this.process(n.left,{...d,path:[...d.path,"allOf",0]}),v=this.process(n.right,{...d,path:[...d.path,"allOf",1]}),y=k=>"allOf"in k&&Object.keys(k).length===1,w=[...y(f)?f.allOf:[f],...y(v)?v.allOf:[v]];p.allOf=w;break}case"tuple":{let p=m;p.type="array";let f=n.items.map((w,k)=>this.process(w,{...d,path:[...d.path,"prefixItems",k]}));if(this.target==="draft-2020-12"?p.prefixItems=f:p.items=f,n.rest){let w=this.process(n.rest,{...d,path:[...d.path,"items"]});this.target==="draft-2020-12"?p.items=w:p.additionalItems=w}n.rest&&(p.items=this.process(n.rest,{...d,path:[...d.path,"items"]}));let{minimum:v,maximum:y}=t._zod.bag;typeof v=="number"&&(p.minItems=v),typeof y=="number"&&(p.maxItems=y);break}case"record":{let p=m;p.type="object",p.propertyNames=this.process(n.keyType,{...d,path:[...d.path,"propertyNames"]}),p.additionalProperties=this.process(n.valueType,{...d,path:[...d.path,"additionalProperties"]});break}case"map":{if(this.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema");break}case"set":{if(this.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema");break}case"enum":{let p=m,f=Ti(n.entries);f.every(v=>typeof v=="number")&&(p.type="number"),f.every(v=>typeof v=="string")&&(p.type="string"),p.enum=f;break}case"literal":{let p=m,f=[];for(let v of n.values)if(v===void 0){if(this.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof v=="bigint"){if(this.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");f.push(Number(v))}else f.push(v);if(f.length!==0)if(f.length===1){let v=f[0];p.type=v===null?"null":typeof v,p.const=v}else f.every(v=>typeof v=="number")&&(p.type="number"),f.every(v=>typeof v=="string")&&(p.type="string"),f.every(v=>typeof v=="boolean")&&(p.type="string"),f.every(v=>v===null)&&(p.type="null"),p.enum=f;break}case"file":{let p=m,f={type:"string",format:"binary",contentEncoding:"binary"},{minimum:v,maximum:y,mime:w}=t._zod.bag;v!==void 0&&(f.minLength=v),y!==void 0&&(f.maxLength=y),w?w.length===1?(f.contentMediaType=w[0],Object.assign(p,f)):p.anyOf=w.map(k=>({...f,contentMediaType:k})):Object.assign(p,f);break}case"transform":{if(this.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema");break}case"nullable":{let p=this.process(n.innerType,d);m.anyOf=[p,{type:"null"}];break}case"nonoptional":{this.process(n.innerType,d),a.ref=n.innerType;break}case"success":{let p=m;p.type="boolean";break}case"default":{this.process(n.innerType,d),a.ref=n.innerType,m.default=JSON.parse(JSON.stringify(n.defaultValue));break}case"prefault":{this.process(n.innerType,d),a.ref=n.innerType,this.io==="input"&&(m._prefault=JSON.parse(JSON.stringify(n.defaultValue)));break}case"catch":{this.process(n.innerType,d),a.ref=n.innerType;let p;try{p=n.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}m.default=p;break}case"nan":{if(this.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema");break}case"template_literal":{let p=m,f=t._zod.pattern;if(!f)throw new Error("Pattern not found in template literal");p.type="string",p.pattern=f.source;break}case"pipe":{let p=this.io==="input"?n.in._zod.def.type==="transform"?n.out:n.in:n.out;this.process(p,d),a.ref=p;break}case"readonly":{this.process(n.innerType,d),a.ref=n.innerType,m.readOnly=!0;break}case"promise":{this.process(n.innerType,d),a.ref=n.innerType;break}case"optional":{this.process(n.innerType,d),a.ref=n.innerType;break}case"lazy":{let p=t._zod.innerType;this.process(p,d),a.ref=p;break}case"custom":{if(this.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema");break}default:}}}let u=this.metadataRegistry.get(t);return u&&Object.assign(a.schema,u),this.io==="input"&&Fe(t)&&(delete a.schema.examples,delete a.schema.default),this.io==="input"&&a.schema._prefault&&((o=a.schema).default??(o.default=a.schema._prefault)),delete a.schema._prefault,this.seen.get(t).schema}emit(t,r){let o={cycles:r?.cycles??"ref",reused:r?.reused??"inline",external:r?.external??void 0},n=this.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");let i=l=>{let d=this.target==="draft-2020-12"?"$defs":"definitions";if(o.external){let f=o.external.registry.get(l[0])?.id,v=o.external.uri??(w=>w);if(f)return{ref:v(f)};let y=l[1].defId??l[1].schema.id??`schema${this.counter++}`;return l[1].defId=y,{defId:y,ref:`${v("__shared")}#/${d}/${y}`}}if(l[1]===n)return{ref:"#"};let m=`#/${d}/`,p=l[1].schema.id??`__schema${this.counter++}`;return{defId:p,ref:m+p}},s=l=>{if(l[1].schema.$ref)return;let d=l[1],{ref:h,defId:m}=i(l);d.def={...d.schema},m&&(d.defId=m);let p=d.schema;for(let f in p)delete p[f];p.$ref=h};if(o.cycles==="throw")for(let l of this.seen.entries()){let d=l[1];if(d.cycle)throw new Error(`Cycle detected: #/${d.cycle?.join("/")}/<root>
43
43
 
44
- Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let l of this.seen.entries()){let d=l[1];if(t===l[0]){s(l);continue}if(o.external){let m=o.external.registry.get(l[0])?.id;if(t!==l[0]&&m){s(l);continue}}if(this.metadataRegistry.get(l[0])?.id){s(l);continue}if(d.cycle){s(l);continue}if(d.count>1&&o.reused==="ref"){s(l);continue}}let a=(l,d)=>{let h=this.seen.get(l),m=h.def??h.schema,p={...m};if(h.ref===null)return;let f=h.ref;if(h.ref=null,f){a(f,d);let g=this.seen.get(f).schema;g.$ref&&d.target==="draft-7"?(m.allOf=m.allOf??[],m.allOf.push(g)):(Object.assign(m,g),Object.assign(m,p))}h.isParent||this.override({zodSchema:l,jsonSchema:m,path:h.path??[]})};for(let l of[...this.seen.entries()].reverse())a(l[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":console.warn(`Invalid target: ${this.target}`),o.external?.uri){let l=o.external.registry.get(t)?.id;if(!l)throw new Error("Schema is missing an `id` property");c.$id=o.external.uri(l)}Object.assign(c,n.def);let u=o.external?.defs??{};for(let l of this.seen.entries()){let d=l[1];d.def&&d.defId&&(u[d.defId]=d.def)}o.external||Object.keys(u).length>0&&(this.target==="draft-2020-12"?c.$defs=u:c.definitions=u);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}};function xo(e,t){if(e instanceof yo){let o=new _s(t),n={};for(let a of e._idmap.entries()){let[c,u]=a;o.process(u)}let i={},s={registry:e,uri:t?.uri,defs:n};for(let a of e._idmap.entries()){let[c,u]=a;i[c]=o.emit(u,{...t,external:s})}if(Object.keys(n).length>0){let a=o.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[a]:n}}return{schemas:i}}let r=new _s(t);return r.process(e),r.emit(e,t)}function Fe(e,t){let r=t??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let n=e._zod.def;switch(n.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 Fe(n.element,r);case"object":{for(let i in n.shape)if(Fe(n.shape[i],r))return!0;return!1}case"union":{for(let i of n.options)if(Fe(i,r))return!0;return!1}case"intersection":return Fe(n.left,r)||Fe(n.right,r);case"tuple":{for(let i of n.items)if(Fe(i,r))return!0;return!!(n.rest&&Fe(n.rest,r))}case"record":return Fe(n.keyType,r)||Fe(n.valueType,r);case"map":return Fe(n.keyType,r)||Fe(n.valueType,r);case"set":return Fe(n.valueType,r);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return Fe(n.innerType,r);case"lazy":return Fe(n.getter(),r);case"default":return Fe(n.innerType,r);case"prefault":return Fe(n.innerType,r);case"custom":return!1;case"transform":return!0;case"pipe":return Fe(n.in,r)||Fe(n.out,r);case"success":return!1;case"catch":return!1;default:}throw new Error(`Unknown schema type: ${n.type}`)}var Sy={};var KP=_("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");W.init(e,t),e.def=t,e.parse=(r,o)=>yn(e,r,o,{callee:e.parse}),e.safeParse=(r,o)=>Mr(e,r,o),e.parseAsync=async(r,o)=>$n(e,r,o,{callee:e.parseAsync}),e.safeParseAsync=async(r,o)=>Ur(e,r,o),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(r,o)=>Qe(e,r,o),e.brand=()=>e,e.register=((r,o)=>(r.add(e,o),e))});var HP=_("ZodMiniObject",(e,t)=>{Ci.init(e,t),KP.init(e,t),j.defineLazy(e,"shape",()=>t.shape)});function wf(e,t){let r={type:"object",get shape(){return j.assignProp(this,"shape",{...e}),this.shape},...j.normalizeParams(t)};return new HP(r)}function jt(e){return!!e._zod}function Tn(e){let t=Object.values(e);if(t.length===0)return wf({});let r=t.every(jt),o=t.every(n=>!jt(n));if(r)return wf(e);if(o)return g_(e);throw new Error("Mixed Zod versions detected in object shape.")}function Gr(e,t){return jt(e)?Mr(e,t):e.safeParse(t)}async function Iu(e,t){return jt(e)?await Ur(e,t):await e.safeParseAsync(t)}function Wr(e){if(!e)return;let t;if(jt(e)?t=e._zod?.def?.shape:t=e.shape,!!t){if(typeof t=="function")try{return t()}catch{return}return t}}function So(e){if(e){if(typeof e=="object"){let t=e,r=e;if(!t._def&&!r._zod){let o=Object.values(e);if(o.length>0&&o.every(n=>typeof n=="object"&&n!==null&&(n._def!==void 0||n._zod!==void 0||typeof n.parse=="function")))return Tn(e)}}if(jt(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}}function ju(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 Ty(e){return e.description}function Py(e){if(jt(e))return e._zod?.def?.type==="optional";let t=e;return typeof e.isOptional=="function"?e.isOptional():t._def?.typeName==="ZodOptional"}function Ou(e){if(jt(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 o=e.value;if(o!==void 0)return o}var sm={};mn(sm,{$brand:()=>Ga,$input:()=>ru,$output:()=>tu,NEVER:()=>Fa,TimePrecision:()=>ou,ZodAny:()=>Ry,ZodArray:()=>qy,ZodBase64:()=>Wf,ZodBase64URL:()=>Kf,ZodBigInt:()=>ks,ZodBigIntFormat:()=>Bf,ZodBoolean:()=>ws,ZodCIDRv4:()=>Ff,ZodCIDRv6:()=>Gf,ZodCUID:()=>Df,ZodCUID2:()=>qf,ZodCatch:()=>Qy,ZodCustom:()=>Fu,ZodCustomStringFormat:()=>Iy,ZodDate:()=>Zu,ZodDefault:()=>Ky,ZodDiscriminatedUnion:()=>My,ZodE164:()=>Hf,ZodEmail:()=>Nf,ZodEmoji:()=>Cf,ZodEnum:()=>ys,ZodError:()=>YP,ZodFile:()=>Gy,ZodGUID:()=>Du,ZodIPv4:()=>Lf,ZodIPv6:()=>Vf,ZodISODate:()=>Ru,ZodISODateTime:()=>Nu,ZodISODuration:()=>Au,ZodISOTime:()=>Cu,ZodIntersection:()=>Uy,ZodIssueCode:()=>Bz,ZodJWT:()=>Jf,ZodKSUID:()=>Zf,ZodLazy:()=>i$,ZodLiteral:()=>Fy,ZodMap:()=>Ly,ZodNaN:()=>t$,ZodNanoID:()=>Af,ZodNever:()=>Ay,ZodNonOptional:()=>rm,ZodNull:()=>Ny,ZodNullable:()=>Wy,ZodNumber:()=>bs,ZodNumberFormat:()=>zo,ZodObject:()=>Lu,ZodOptional:()=>tm,ZodPipe:()=>nm,ZodPrefault:()=>Jy,ZodPromise:()=>a$,ZodReadonly:()=>r$,ZodRealError:()=>Po,ZodRecord:()=>Xf,ZodSet:()=>Vy,ZodString:()=>$s,ZodStringFormat:()=>Ee,ZodSuccess:()=>Xy,ZodSymbol:()=>jy,ZodTemplateLiteral:()=>o$,ZodTransform:()=>Qf,ZodTuple:()=>Zy,ZodType:()=>te,ZodULID:()=>Mf,ZodURL:()=>Rf,ZodUUID:()=>xr,ZodUndefined:()=>Oy,ZodUnion:()=>Yf,ZodUnknown:()=>Cy,ZodVoid:()=>Dy,ZodXID:()=>Uf,_ZodString:()=>Of,_default:()=>Hy,any:()=>jz,array:()=>ae,base64:()=>vz,base64url:()=>_z,bigint:()=>Tz,boolean:()=>Ve,catch:()=>e$,check:()=>c$,cidrv4:()=>hz,cidrv6:()=>gz,clone:()=>Qe,coerce:()=>im,config:()=>Ue,core:()=>Wt,cuid:()=>cz,cuid2:()=>uz,custom:()=>om,date:()=>Nz,discriminatedUnion:()=>Vu,e164:()=>yz,email:()=>QP,emoji:()=>sz,endsWith:()=>ds,enum:()=>ct,file:()=>Zz,flattenError:()=>lo,float32:()=>wz,float64:()=>kz,formatError:()=>po,function:()=>Eu,getErrorMap:()=>Xz,globalRegistry:()=>Gt,gt:()=>wr,gte:()=>ht,guid:()=>ez,includes:()=>us,instanceof:()=>Kz,int:()=>jf,int32:()=>xz,int64:()=>Pz,intersection:()=>Ss,ipv4:()=>fz,ipv6:()=>mz,iso:()=>To,json:()=>Jz,jwt:()=>$z,keyof:()=>Rz,ksuid:()=>pz,lazy:()=>s$,length:()=>ko,literal:()=>M,locales:()=>_o,looseObject:()=>et,lowercase:()=>as,lt:()=>br,lte:()=>It,map:()=>qz,maxLength:()=>wo,maxSize:()=>bo,mime:()=>ps,minLength:()=>Fr,minSize:()=>Sn,multipleOf:()=>xn,nan:()=>Fz,nanoid:()=>az,nativeEnum:()=>Uz,negative:()=>vf,never:()=>Uu,nonnegative:()=>yf,nonoptional:()=>Yy,nonpositive:()=>_f,normalize:()=>fs,null:()=>xs,nullable:()=>qu,nullish:()=>Lz,number:()=>ye,object:()=>D,optional:()=>Oe,overwrite:()=>kr,parse:()=>Pf,parseAsync:()=>zf,partialRecord:()=>Dz,pipe:()=>Mu,positive:()=>gf,prefault:()=>By,preprocess:()=>Gu,prettifyError:()=>Ha,promise:()=>Wz,property:()=>$f,readonly:()=>n$,record:()=>Ie,refine:()=>u$,regex:()=>ss,regexes:()=>Zr,registry:()=>Di,safeParse:()=>Ef,safeParseAsync:()=>If,set:()=>Mz,setErrorMap:()=>Yz,size:()=>is,startsWith:()=>ls,strictObject:()=>Cz,string:()=>$,stringFormat:()=>bz,stringbool:()=>Hz,success:()=>Vz,superRefine:()=>l$,symbol:()=>Ez,templateLiteral:()=>Gz,toJSONSchema:()=>xo,toLowerCase:()=>hs,toUpperCase:()=>gs,transform:()=>em,treeifyError:()=>Ka,trim:()=>ms,tuple:()=>Az,uint32:()=>Sz,uint64:()=>zz,ulid:()=>lz,undefined:()=>Iz,union:()=>$e,unknown:()=>je,uppercase:()=>cs,url:()=>iz,uuid:()=>tz,uuidv4:()=>rz,uuidv6:()=>nz,uuidv7:()=>oz,void:()=>Oz,xid:()=>dz});var To={};mn(To,{ZodISODate:()=>Ru,ZodISODateTime:()=>Nu,ZodISODuration:()=>Au,ZodISOTime:()=>Cu,date:()=>xf,datetime:()=>kf,duration:()=>Tf,time:()=>Sf});var Nu=_("ZodISODateTime",(e,t)=>{tf.init(e,t),Ee.init(e,t)});function kf(e){return cf(Nu,e)}var Ru=_("ZodISODate",(e,t)=>{rf.init(e,t),Ee.init(e,t)});function xf(e){return uf(Ru,e)}var Cu=_("ZodISOTime",(e,t)=>{nf.init(e,t),Ee.init(e,t)});function Sf(e){return lf(Cu,e)}var Au=_("ZodISODuration",(e,t)=>{of.init(e,t),Ee.init(e,t)});function Tf(e){return df(Au,e)}var Ey=(e,t)=>{ji.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:r=>po(e,r)},flatten:{value:r=>lo(e,r)},addIssue:{value:r=>e.issues.push(r)},addIssues:{value:r=>e.issues.push(...r)},isEmpty:{get(){return e.issues.length===0}}})},YP=_("ZodError",Ey),Po=_("ZodError",Ey,{Parent:Error});var Pf=Ja(Po),zf=Ba(Po),Ef=Ya(Po),If=Xa(Po);var te=_("ZodType",(e,t)=>(W.init(e,t),e.def=t,Object.defineProperty(e,"_def",{value:t}),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(r,o)=>Qe(e,r,o),e.brand=()=>e,e.register=((r,o)=>(r.add(e,o),e)),e.parse=(r,o)=>Pf(e,r,o,{callee:e.parse}),e.safeParse=(r,o)=>Ef(e,r,o),e.parseAsync=async(r,o)=>zf(e,r,o,{callee:e.parseAsync}),e.safeParseAsync=async(r,o)=>If(e,r,o),e.spa=e.safeParseAsync,e.refine=(r,o)=>e.check(u$(r,o)),e.superRefine=r=>e.check(l$(r)),e.overwrite=r=>e.check(kr(r)),e.optional=()=>Oe(e),e.nullable=()=>qu(e),e.nullish=()=>Oe(qu(e)),e.nonoptional=r=>Yy(e,r),e.array=()=>ae(e),e.or=r=>$e([e,r]),e.and=r=>Ss(e,r),e.transform=r=>Mu(e,em(r)),e.default=r=>Hy(e,r),e.prefault=r=>By(e,r),e.catch=r=>e$(e,r),e.pipe=r=>Mu(e,r),e.readonly=()=>n$(e),e.describe=r=>{let o=e.clone();return Gt.add(o,{description:r}),o},Object.defineProperty(e,"description",{get(){return Gt.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return Gt.get(e);let o=e.clone();return Gt.add(o,r[0]),o},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Of=_("_ZodString",(e,t)=>{Lr.init(e,t),te.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=(...o)=>e.check(ss(...o)),e.includes=(...o)=>e.check(us(...o)),e.startsWith=(...o)=>e.check(ls(...o)),e.endsWith=(...o)=>e.check(ds(...o)),e.min=(...o)=>e.check(Fr(...o)),e.max=(...o)=>e.check(wo(...o)),e.length=(...o)=>e.check(ko(...o)),e.nonempty=(...o)=>e.check(Fr(1,...o)),e.lowercase=o=>e.check(as(o)),e.uppercase=o=>e.check(cs(o)),e.trim=()=>e.check(ms()),e.normalize=(...o)=>e.check(fs(...o)),e.toLowerCase=()=>e.check(hs()),e.toUpperCase=()=>e.check(gs())}),$s=_("ZodString",(e,t)=>{Lr.init(e,t),Of.init(e,t),e.email=r=>e.check(qi(Nf,r)),e.url=r=>e.check(Vi(Rf,r)),e.jwt=r=>e.check(os(Jf,r)),e.emoji=r=>e.check(Fi(Cf,r)),e.guid=r=>e.check($o(Du,r)),e.uuid=r=>e.check(Mi(xr,r)),e.uuidv4=r=>e.check(Ui(xr,r)),e.uuidv6=r=>e.check(Zi(xr,r)),e.uuidv7=r=>e.check(Li(xr,r)),e.nanoid=r=>e.check(Gi(Af,r)),e.guid=r=>e.check($o(Du,r)),e.cuid=r=>e.check(Wi(Df,r)),e.cuid2=r=>e.check(Ki(qf,r)),e.ulid=r=>e.check(Hi(Mf,r)),e.base64=r=>e.check(ts(Wf,r)),e.base64url=r=>e.check(rs(Kf,r)),e.xid=r=>e.check(Ji(Uf,r)),e.ksuid=r=>e.check(Bi(Zf,r)),e.ipv4=r=>e.check(Yi(Lf,r)),e.ipv6=r=>e.check(Xi(Vf,r)),e.cidrv4=r=>e.check(Qi(Ff,r)),e.cidrv6=r=>e.check(es(Gf,r)),e.e164=r=>e.check(ns(Hf,r)),e.datetime=r=>e.check(kf(r)),e.date=r=>e.check(xf(r)),e.time=r=>e.check(Sf(r)),e.duration=r=>e.check(Tf(r))});function $(e){return nu($s,e)}var Ee=_("ZodStringFormat",(e,t)=>{ke.init(e,t),Of.init(e,t)}),Nf=_("ZodEmail",(e,t)=>{sc.init(e,t),Ee.init(e,t)});function QP(e){return qi(Nf,e)}var Du=_("ZodGUID",(e,t)=>{oc.init(e,t),Ee.init(e,t)});function ez(e){return $o(Du,e)}var xr=_("ZodUUID",(e,t)=>{ic.init(e,t),Ee.init(e,t)});function tz(e){return Mi(xr,e)}function rz(e){return Ui(xr,e)}function nz(e){return Zi(xr,e)}function oz(e){return Li(xr,e)}var Rf=_("ZodURL",(e,t)=>{ac.init(e,t),Ee.init(e,t)});function iz(e){return Vi(Rf,e)}var Cf=_("ZodEmoji",(e,t)=>{cc.init(e,t),Ee.init(e,t)});function sz(e){return Fi(Cf,e)}var Af=_("ZodNanoID",(e,t)=>{uc.init(e,t),Ee.init(e,t)});function az(e){return Gi(Af,e)}var Df=_("ZodCUID",(e,t)=>{lc.init(e,t),Ee.init(e,t)});function cz(e){return Wi(Df,e)}var qf=_("ZodCUID2",(e,t)=>{dc.init(e,t),Ee.init(e,t)});function uz(e){return Ki(qf,e)}var Mf=_("ZodULID",(e,t)=>{pc.init(e,t),Ee.init(e,t)});function lz(e){return Hi(Mf,e)}var Uf=_("ZodXID",(e,t)=>{fc.init(e,t),Ee.init(e,t)});function dz(e){return Ji(Uf,e)}var Zf=_("ZodKSUID",(e,t)=>{mc.init(e,t),Ee.init(e,t)});function pz(e){return Bi(Zf,e)}var Lf=_("ZodIPv4",(e,t)=>{hc.init(e,t),Ee.init(e,t)});function fz(e){return Yi(Lf,e)}var Vf=_("ZodIPv6",(e,t)=>{gc.init(e,t),Ee.init(e,t)});function mz(e){return Xi(Vf,e)}var Ff=_("ZodCIDRv4",(e,t)=>{vc.init(e,t),Ee.init(e,t)});function hz(e){return Qi(Ff,e)}var Gf=_("ZodCIDRv6",(e,t)=>{_c.init(e,t),Ee.init(e,t)});function gz(e){return es(Gf,e)}var Wf=_("ZodBase64",(e,t)=>{yc.init(e,t),Ee.init(e,t)});function vz(e){return ts(Wf,e)}var Kf=_("ZodBase64URL",(e,t)=>{$c.init(e,t),Ee.init(e,t)});function _z(e){return rs(Kf,e)}var Hf=_("ZodE164",(e,t)=>{bc.init(e,t),Ee.init(e,t)});function yz(e){return ns(Hf,e)}var Jf=_("ZodJWT",(e,t)=>{wc.init(e,t),Ee.init(e,t)});function $z(e){return os(Jf,e)}var Iy=_("ZodCustomStringFormat",(e,t)=>{kc.init(e,t),Ee.init(e,t)});function bz(e,t,r={}){return Pu(Iy,e,t,r)}var bs=_("ZodNumber",(e,t)=>{Ni.init(e,t),te.init(e,t),e.gt=(o,n)=>e.check(wr(o,n)),e.gte=(o,n)=>e.check(ht(o,n)),e.min=(o,n)=>e.check(ht(o,n)),e.lt=(o,n)=>e.check(br(o,n)),e.lte=(o,n)=>e.check(It(o,n)),e.max=(o,n)=>e.check(It(o,n)),e.int=o=>e.check(jf(o)),e.safe=o=>e.check(jf(o)),e.positive=o=>e.check(wr(0,o)),e.nonnegative=o=>e.check(ht(0,o)),e.negative=o=>e.check(br(0,o)),e.nonpositive=o=>e.check(It(0,o)),e.multipleOf=(o,n)=>e.check(xn(o,n)),e.step=(o,n)=>e.check(xn(o,n)),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??.5),e.isFinite=!0,e.format=r.format??null});function ye(e){return iu(bs,e)}var zo=_("ZodNumberFormat",(e,t)=>{xc.init(e,t),bs.init(e,t)});function jf(e){return su(zo,e)}function wz(e){return au(zo,e)}function kz(e){return cu(zo,e)}function xz(e){return uu(zo,e)}function Sz(e){return lu(zo,e)}var ws=_("ZodBoolean",(e,t)=>{mo.init(e,t),te.init(e,t)});function Ve(e){return du(ws,e)}var ks=_("ZodBigInt",(e,t)=>{Ri.init(e,t),te.init(e,t),e.gte=(o,n)=>e.check(ht(o,n)),e.min=(o,n)=>e.check(ht(o,n)),e.gt=(o,n)=>e.check(wr(o,n)),e.gte=(o,n)=>e.check(ht(o,n)),e.min=(o,n)=>e.check(ht(o,n)),e.lt=(o,n)=>e.check(br(o,n)),e.lte=(o,n)=>e.check(It(o,n)),e.max=(o,n)=>e.check(It(o,n)),e.positive=o=>e.check(wr(BigInt(0),o)),e.negative=o=>e.check(br(BigInt(0),o)),e.nonpositive=o=>e.check(It(BigInt(0),o)),e.nonnegative=o=>e.check(ht(BigInt(0),o)),e.multipleOf=(o,n)=>e.check(xn(o,n));let r=e._zod.bag;e.minValue=r.minimum??null,e.maxValue=r.maximum??null,e.format=r.format??null});function Tz(e){return pu(ks,e)}var Bf=_("ZodBigIntFormat",(e,t)=>{Sc.init(e,t),ks.init(e,t)});function Pz(e){return fu(Bf,e)}function zz(e){return mu(Bf,e)}var jy=_("ZodSymbol",(e,t)=>{Tc.init(e,t),te.init(e,t)});function Ez(e){return hu(jy,e)}var Oy=_("ZodUndefined",(e,t)=>{Pc.init(e,t),te.init(e,t)});function Iz(e){return gu(Oy,e)}var Ny=_("ZodNull",(e,t)=>{zc.init(e,t),te.init(e,t)});function xs(e){return vu(Ny,e)}var Ry=_("ZodAny",(e,t)=>{Ec.init(e,t),te.init(e,t)});function jz(){return _u(Ry)}var Cy=_("ZodUnknown",(e,t)=>{wn.init(e,t),te.init(e,t)});function je(){return kn(Cy)}var Ay=_("ZodNever",(e,t)=>{Ic.init(e,t),te.init(e,t)});function Uu(e){return yu(Ay,e)}var Dy=_("ZodVoid",(e,t)=>{jc.init(e,t),te.init(e,t)});function Oz(e){return $u(Dy,e)}var Zu=_("ZodDate",(e,t)=>{Oc.init(e,t),te.init(e,t),e.min=(o,n)=>e.check(ht(o,n)),e.max=(o,n)=>e.check(It(o,n));let r=e._zod.bag;e.minDate=r.minimum?new Date(r.minimum):null,e.maxDate=r.maximum?new Date(r.maximum):null});function Nz(e){return bu(Zu,e)}var qy=_("ZodArray",(e,t)=>{ho.init(e,t),te.init(e,t),e.element=t.element,e.min=(r,o)=>e.check(Fr(r,o)),e.nonempty=r=>e.check(Fr(1,r)),e.max=(r,o)=>e.check(wo(r,o)),e.length=(r,o)=>e.check(ko(r,o)),e.unwrap=()=>e.element});function ae(e,t){return vs(qy,e,t)}function Rz(e){let t=e._zod.def.shape;return M(Object.keys(t))}var Lu=_("ZodObject",(e,t)=>{Ci.init(e,t),te.init(e,t),j.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>ct(Object.keys(e._zod.def.shape)),e.catchall=r=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:je()}),e.loose=()=>e.clone({...e._zod.def,catchall:je()}),e.strict=()=>e.clone({...e._zod.def,catchall:Uu()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=r=>j.extend(e,r),e.merge=r=>j.merge(e,r),e.pick=r=>j.pick(e,r),e.omit=r=>j.omit(e,r),e.partial=(...r)=>j.partial(tm,e,r[0]),e.required=(...r)=>j.required(rm,e,r[0])});function D(e,t){let r={type:"object",get shape(){return j.assignProp(this,"shape",{...e}),this.shape},...j.normalizeParams(t)};return new Lu(r)}function Cz(e,t){return new Lu({type:"object",get shape(){return j.assignProp(this,"shape",{...e}),this.shape},catchall:Uu(),...j.normalizeParams(t)})}function et(e,t){return new Lu({type:"object",get shape(){return j.assignProp(this,"shape",{...e}),this.shape},catchall:je(),...j.normalizeParams(t)})}var Yf=_("ZodUnion",(e,t)=>{Ai.init(e,t),te.init(e,t),e.options=t.options});function $e(e,t){return new Yf({type:"union",options:e,...j.normalizeParams(t)})}var My=_("ZodDiscriminatedUnion",(e,t)=>{Yf.init(e,t),Nc.init(e,t)});function Vu(e,t,r){return new My({type:"union",options:t,discriminator:e,...j.normalizeParams(r)})}var Uy=_("ZodIntersection",(e,t)=>{Rc.init(e,t),te.init(e,t)});function Ss(e,t){return new Uy({type:"intersection",left:e,right:t})}var Zy=_("ZodTuple",(e,t)=>{Vr.init(e,t),te.init(e,t),e.rest=r=>e.clone({...e._zod.def,rest:r})});function Az(e,t,r){let o=t instanceof W,n=o?r:t,i=o?t:null;return new Zy({type:"tuple",items:e,rest:i,...j.normalizeParams(n)})}var Xf=_("ZodRecord",(e,t)=>{Cc.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function Ie(e,t,r){return new Xf({type:"record",keyType:e,valueType:t,...j.normalizeParams(r)})}function Dz(e,t,r){return new Xf({type:"record",keyType:$e([e,Uu()]),valueType:t,...j.normalizeParams(r)})}var Ly=_("ZodMap",(e,t)=>{Ac.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function qz(e,t,r){return new Ly({type:"map",keyType:e,valueType:t,...j.normalizeParams(r)})}var Vy=_("ZodSet",(e,t)=>{Dc.init(e,t),te.init(e,t),e.min=(...r)=>e.check(Sn(...r)),e.nonempty=r=>e.check(Sn(1,r)),e.max=(...r)=>e.check(bo(...r)),e.size=(...r)=>e.check(is(...r))});function Mz(e,t){return new Vy({type:"set",valueType:e,...j.normalizeParams(t)})}var ys=_("ZodEnum",(e,t)=>{qc.init(e,t),te.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let r=new Set(Object.keys(t.entries));e.extract=(o,n)=>{let i={};for(let s of o)if(r.has(s))i[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new ys({...t,checks:[],...j.normalizeParams(n),entries:i})},e.exclude=(o,n)=>{let i={...t.entries};for(let s of o)if(r.has(s))delete i[s];else throw new Error(`Key ${s} not found in enum`);return new ys({...t,checks:[],...j.normalizeParams(n),entries:i})}});function ct(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(o=>[o,o])):e;return new ys({type:"enum",entries:r,...j.normalizeParams(t)})}function Uz(e,t){return new ys({type:"enum",entries:e,...j.normalizeParams(t)})}var Fy=_("ZodLiteral",(e,t)=>{Mc.init(e,t),te.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function M(e,t){return new Fy({type:"literal",values:Array.isArray(e)?e:[e],...j.normalizeParams(t)})}var Gy=_("ZodFile",(e,t)=>{Uc.init(e,t),te.init(e,t),e.min=(r,o)=>e.check(Sn(r,o)),e.max=(r,o)=>e.check(bo(r,o)),e.mime=(r,o)=>e.check(ps(Array.isArray(r)?r:[r],o))});function Zz(e){return ku(Gy,e)}var Qf=_("ZodTransform",(e,t)=>{go.init(e,t),te.init(e,t),e._zod.parse=(r,o)=>{r.addIssue=i=>{if(typeof i=="string")r.issues.push(j.issue(i,r.value,t));else{let s=i;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(j.issue(s))}};let n=t.transform(r.value,r);return n instanceof Promise?n.then(i=>(r.value=i,r)):(r.value=n,r)}});function em(e){return new Qf({type:"transform",transform:e})}var tm=_("ZodOptional",(e,t)=>{Zc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Oe(e){return new tm({type:"optional",innerType:e})}var Wy=_("ZodNullable",(e,t)=>{Lc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function qu(e){return new Wy({type:"nullable",innerType:e})}function Lz(e){return Oe(qu(e))}var Ky=_("ZodDefault",(e,t)=>{Vc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Hy(e,t){return new Ky({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():t}})}var Jy=_("ZodPrefault",(e,t)=>{Fc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function By(e,t){return new Jy({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():t}})}var rm=_("ZodNonOptional",(e,t)=>{Gc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Yy(e,t){return new rm({type:"nonoptional",innerType:e,...j.normalizeParams(t)})}var Xy=_("ZodSuccess",(e,t)=>{Wc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Vz(e){return new Xy({type:"success",innerType:e})}var Qy=_("ZodCatch",(e,t)=>{Kc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function e$(e,t){return new Qy({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}var t$=_("ZodNaN",(e,t)=>{Hc.init(e,t),te.init(e,t)});function Fz(e){return wu(t$,e)}var nm=_("ZodPipe",(e,t)=>{vo.init(e,t),te.init(e,t),e.in=t.in,e.out=t.out});function Mu(e,t){return new nm({type:"pipe",in:e,out:t})}var r$=_("ZodReadonly",(e,t)=>{Jc.init(e,t),te.init(e,t)});function n$(e){return new r$({type:"readonly",innerType:e})}var o$=_("ZodTemplateLiteral",(e,t)=>{Bc.init(e,t),te.init(e,t)});function Gz(e,t){return new o$({type:"template_literal",parts:e,...j.normalizeParams(t)})}var i$=_("ZodLazy",(e,t)=>{Xc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.getter()});function s$(e){return new i$({type:"lazy",getter:e})}var a$=_("ZodPromise",(e,t)=>{Yc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Wz(e){return new a$({type:"promise",innerType:e})}var Fu=_("ZodCustom",(e,t)=>{Qc.init(e,t),te.init(e,t)});function c$(e){let t=new De({check:"custom"});return t._zod.check=e,t}function om(e,t){return xu(Fu,e??(()=>!0),t)}function u$(e,t={}){return Su(Fu,e,t)}function l$(e){let t=c$(r=>(r.addIssue=o=>{if(typeof o=="string")r.issues.push(j.issue(o,r.value,t._zod.def));else{let n=o;n.fatal&&(n.continue=!1),n.code??(n.code="custom"),n.input??(n.input=r.value),n.inst??(n.inst=t),n.continue??(n.continue=!t._zod.def.abort),r.issues.push(j.issue(n))}},e(r.value,r)));return t}function Kz(e,t={error:`Input not instance of ${e.name}`}){let r=new Fu({type:"custom",check:"custom",fn:o=>o instanceof e,abort:!0,...j.normalizeParams(t)});return r._zod.bag.Class=e,r}var Hz=(...e)=>Tu({Pipe:nm,Boolean:ws,String:$s,Transform:Qf},...e);function Jz(e){let t=s$(()=>$e([$(e),ye(),Ve(),xs(),ae(t),Ie($(),t)]));return t}function Gu(e,t){return Mu(em(e),t)}var Bz={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function Yz(e){Ue({customError:e})}function Xz(){return Ue().customError}var im={};mn(im,{bigint:()=>rE,boolean:()=>tE,date:()=>nE,number:()=>eE,string:()=>Qz});function Qz(e){return af($s,e)}function eE(e){return pf(bs,e)}function tE(e){return ff(ws,e)}function rE(e){return mf(ks,e)}function nE(e){return hf(Zu,e)}Ue(eu());var d$=sm;var v=d$;var cm="2025-11-25";var p$=[cm,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],Kr="io.modelcontextprotocol/related-task",Ku="2.0",Ge=om(e=>e!==null&&(typeof e=="object"||typeof e=="function")),f$=$e([$(),ye().int()]),m$=$(),EV=et({ttl:$e([ye(),xs()]).optional(),pollInterval:ye().optional()}),iE=D({ttl:ye().optional()}),sE=D({taskId:$()}),um=et({progressToken:f$.optional(),[Kr]:sE.optional()}),zt=D({_meta:um.optional()}),Ts=zt.extend({task:iE.optional()}),h$=e=>Ts.safeParse(e).success,We=D({method:$(),params:zt.loose().optional()}),Ot=D({_meta:um.optional()}),Nt=D({method:$(),params:Ot.loose().optional()}),Ke=et({_meta:um.optional()}),Hu=$e([$(),ye().int()]),g$=D({jsonrpc:M(Ku),id:Hu,...We.shape}).strict(),lm=e=>g$.safeParse(e).success,v$=D({jsonrpc:M(Ku),...Nt.shape}).strict(),_$=e=>v$.safeParse(e).success,dm=D({jsonrpc:M(Ku),id:Hu,result:Ke}).strict(),Ps=e=>dm.safeParse(e).success;var V;(function(e){e[e.ConnectionClosed=-32e3]="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"})(V||(V={}));var pm=D({jsonrpc:M(Ku),id:Hu.optional(),error:D({code:ye().int(),message:$(),data:je().optional()})}).strict();var y$=e=>pm.safeParse(e).success;var $$=$e([g$,v$,dm,pm]),IV=$e([dm,pm]),Ju=Ke.strict(),aE=Ot.extend({requestId:Hu.optional(),reason:$().optional()}),Bu=Nt.extend({method:M("notifications/cancelled"),params:aE}),cE=D({src:$(),mimeType:$().optional(),sizes:ae($()).optional(),theme:ct(["light","dark"]).optional()}),zs=D({icons:ae(cE).optional()}),Eo=D({name:$(),title:$().optional()}),b$=Eo.extend({...Eo.shape,...zs.shape,version:$(),websiteUrl:$().optional(),description:$().optional()}),uE=Ss(D({applyDefaults:Ve().optional()}),Ie($(),je())),lE=Gu(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,Ss(D({form:uE.optional(),url:Ge.optional()}),Ie($(),je()).optional())),dE=et({list:Ge.optional(),cancel:Ge.optional(),requests:et({sampling:et({createMessage:Ge.optional()}).optional(),elicitation:et({create:Ge.optional()}).optional()}).optional()}),pE=et({list:Ge.optional(),cancel:Ge.optional(),requests:et({tools:et({call:Ge.optional()}).optional()}).optional()}),fE=D({experimental:Ie($(),Ge).optional(),sampling:D({context:Ge.optional(),tools:Ge.optional()}).optional(),elicitation:lE.optional(),roots:D({listChanged:Ve().optional()}).optional(),tasks:dE.optional()}),mE=zt.extend({protocolVersion:$(),capabilities:fE,clientInfo:b$}),fm=We.extend({method:M("initialize"),params:mE});var hE=D({experimental:Ie($(),Ge).optional(),logging:Ge.optional(),completions:Ge.optional(),prompts:D({listChanged:Ve().optional()}).optional(),resources:D({subscribe:Ve().optional(),listChanged:Ve().optional()}).optional(),tools:D({listChanged:Ve().optional()}).optional(),tasks:pE.optional()}),gE=Ke.extend({protocolVersion:$(),capabilities:hE,serverInfo:b$,instructions:$().optional()}),mm=Nt.extend({method:M("notifications/initialized"),params:Ot.optional()});var Yu=We.extend({method:M("ping"),params:zt.optional()}),vE=D({progress:ye(),total:Oe(ye()),message:Oe($())}),_E=D({...Ot.shape,...vE.shape,progressToken:f$}),Xu=Nt.extend({method:M("notifications/progress"),params:_E}),yE=zt.extend({cursor:m$.optional()}),Es=We.extend({params:yE.optional()}),Is=Ke.extend({nextCursor:m$.optional()}),$E=ct(["working","input_required","completed","failed","cancelled"]),js=D({taskId:$(),status:$E,ttl:$e([ye(),xs()]),createdAt:$(),lastUpdatedAt:$(),pollInterval:Oe(ye()),statusMessage:Oe($())}),Io=Ke.extend({task:js}),bE=Ot.merge(js),Os=Nt.extend({method:M("notifications/tasks/status"),params:bE}),Qu=We.extend({method:M("tasks/get"),params:zt.extend({taskId:$()})}),el=Ke.merge(js),tl=We.extend({method:M("tasks/result"),params:zt.extend({taskId:$()})}),jV=Ke.loose(),rl=Es.extend({method:M("tasks/list")}),nl=Is.extend({tasks:ae(js)}),ol=We.extend({method:M("tasks/cancel"),params:zt.extend({taskId:$()})}),w$=Ke.merge(js),k$=D({uri:$(),mimeType:Oe($()),_meta:Ie($(),je()).optional()}),x$=k$.extend({text:$()}),hm=$().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),S$=k$.extend({blob:hm}),Ns=ct(["user","assistant"]),jo=D({audience:ae(Ns).optional(),priority:ye().min(0).max(1).optional(),lastModified:To.datetime({offset:!0}).optional()}),T$=D({...Eo.shape,...zs.shape,uri:$(),description:Oe($()),mimeType:Oe($()),annotations:jo.optional(),_meta:Oe(et({}))}),wE=D({...Eo.shape,...zs.shape,uriTemplate:$(),description:Oe($()),mimeType:Oe($()),annotations:jo.optional(),_meta:Oe(et({}))}),il=Es.extend({method:M("resources/list")}),kE=Is.extend({resources:ae(T$)}),sl=Es.extend({method:M("resources/templates/list")}),xE=Is.extend({resourceTemplates:ae(wE)}),gm=zt.extend({uri:$()}),SE=gm,al=We.extend({method:M("resources/read"),params:SE}),TE=Ke.extend({contents:ae($e([x$,S$]))}),PE=Nt.extend({method:M("notifications/resources/list_changed"),params:Ot.optional()}),zE=gm,EE=We.extend({method:M("resources/subscribe"),params:zE}),IE=gm,jE=We.extend({method:M("resources/unsubscribe"),params:IE}),OE=Ot.extend({uri:$()}),NE=Nt.extend({method:M("notifications/resources/updated"),params:OE}),RE=D({name:$(),description:Oe($()),required:Oe(Ve())}),CE=D({...Eo.shape,...zs.shape,description:Oe($()),arguments:Oe(ae(RE)),_meta:Oe(et({}))}),cl=Es.extend({method:M("prompts/list")}),AE=Is.extend({prompts:ae(CE)}),DE=zt.extend({name:$(),arguments:Ie($(),$()).optional()}),ul=We.extend({method:M("prompts/get"),params:DE}),vm=D({type:M("text"),text:$(),annotations:jo.optional(),_meta:Ie($(),je()).optional()}),_m=D({type:M("image"),data:hm,mimeType:$(),annotations:jo.optional(),_meta:Ie($(),je()).optional()}),ym=D({type:M("audio"),data:hm,mimeType:$(),annotations:jo.optional(),_meta:Ie($(),je()).optional()}),qE=D({type:M("tool_use"),name:$(),id:$(),input:Ie($(),je()),_meta:Ie($(),je()).optional()}),ME=D({type:M("resource"),resource:$e([x$,S$]),annotations:jo.optional(),_meta:Ie($(),je()).optional()}),UE=T$.extend({type:M("resource_link")}),$m=$e([vm,_m,ym,UE,ME]),ZE=D({role:Ns,content:$m}),LE=Ke.extend({description:$().optional(),messages:ae(ZE)}),VE=Nt.extend({method:M("notifications/prompts/list_changed"),params:Ot.optional()}),FE=D({title:$().optional(),readOnlyHint:Ve().optional(),destructiveHint:Ve().optional(),idempotentHint:Ve().optional(),openWorldHint:Ve().optional()}),GE=D({taskSupport:ct(["required","optional","forbidden"]).optional()}),P$=D({...Eo.shape,...zs.shape,description:$().optional(),inputSchema:D({type:M("object"),properties:Ie($(),Ge).optional(),required:ae($()).optional()}).catchall(je()),outputSchema:D({type:M("object"),properties:Ie($(),Ge).optional(),required:ae($()).optional()}).catchall(je()).optional(),annotations:FE.optional(),execution:GE.optional(),_meta:Ie($(),je()).optional()}),ll=Es.extend({method:M("tools/list")}),WE=Is.extend({tools:ae(P$)}),dl=Ke.extend({content:ae($m).default([]),structuredContent:Ie($(),je()).optional(),isError:Ve().optional()}),OV=dl.or(Ke.extend({toolResult:je()})),KE=Ts.extend({name:$(),arguments:Ie($(),je()).optional()}),Oo=We.extend({method:M("tools/call"),params:KE}),HE=Nt.extend({method:M("notifications/tools/list_changed"),params:Ot.optional()}),NV=D({autoRefresh:Ve().default(!0),debounceMs:ye().int().nonnegative().default(300)}),Rs=ct(["debug","info","notice","warning","error","critical","alert","emergency"]),JE=zt.extend({level:Rs}),bm=We.extend({method:M("logging/setLevel"),params:JE}),BE=Ot.extend({level:Rs,logger:$().optional(),data:je()}),YE=Nt.extend({method:M("notifications/message"),params:BE}),XE=D({name:$().optional()}),QE=D({hints:ae(XE).optional(),costPriority:ye().min(0).max(1).optional(),speedPriority:ye().min(0).max(1).optional(),intelligencePriority:ye().min(0).max(1).optional()}),eI=D({mode:ct(["auto","required","none"]).optional()}),tI=D({type:M("tool_result"),toolUseId:$().describe("The unique identifier for the corresponding tool call."),content:ae($m).default([]),structuredContent:D({}).loose().optional(),isError:Ve().optional(),_meta:Ie($(),je()).optional()}),rI=Vu("type",[vm,_m,ym]),Wu=Vu("type",[vm,_m,ym,qE,tI]),nI=D({role:Ns,content:$e([Wu,ae(Wu)]),_meta:Ie($(),je()).optional()}),oI=Ts.extend({messages:ae(nI),modelPreferences:QE.optional(),systemPrompt:$().optional(),includeContext:ct(["none","thisServer","allServers"]).optional(),temperature:ye().optional(),maxTokens:ye().int(),stopSequences:ae($()).optional(),metadata:Ge.optional(),tools:ae(P$).optional(),toolChoice:eI.optional()}),iI=We.extend({method:M("sampling/createMessage"),params:oI}),wm=Ke.extend({model:$(),stopReason:Oe(ct(["endTurn","stopSequence","maxTokens"]).or($())),role:Ns,content:rI}),km=Ke.extend({model:$(),stopReason:Oe(ct(["endTurn","stopSequence","maxTokens","toolUse"]).or($())),role:Ns,content:$e([Wu,ae(Wu)])}),sI=D({type:M("boolean"),title:$().optional(),description:$().optional(),default:Ve().optional()}),aI=D({type:M("string"),title:$().optional(),description:$().optional(),minLength:ye().optional(),maxLength:ye().optional(),format:ct(["email","uri","date","date-time"]).optional(),default:$().optional()}),cI=D({type:ct(["number","integer"]),title:$().optional(),description:$().optional(),minimum:ye().optional(),maximum:ye().optional(),default:ye().optional()}),uI=D({type:M("string"),title:$().optional(),description:$().optional(),enum:ae($()),default:$().optional()}),lI=D({type:M("string"),title:$().optional(),description:$().optional(),oneOf:ae(D({const:$(),title:$()})),default:$().optional()}),dI=D({type:M("string"),title:$().optional(),description:$().optional(),enum:ae($()),enumNames:ae($()).optional(),default:$().optional()}),pI=$e([uI,lI]),fI=D({type:M("array"),title:$().optional(),description:$().optional(),minItems:ye().optional(),maxItems:ye().optional(),items:D({type:M("string"),enum:ae($())}),default:ae($()).optional()}),mI=D({type:M("array"),title:$().optional(),description:$().optional(),minItems:ye().optional(),maxItems:ye().optional(),items:D({anyOf:ae(D({const:$(),title:$()}))}),default:ae($()).optional()}),hI=$e([fI,mI]),gI=$e([dI,pI,hI]),vI=$e([gI,sI,aI,cI]),_I=Ts.extend({mode:M("form").optional(),message:$(),requestedSchema:D({type:M("object"),properties:Ie($(),vI),required:ae($()).optional()})}),yI=Ts.extend({mode:M("url"),message:$(),elicitationId:$(),url:$().url()}),$I=$e([_I,yI]),bI=We.extend({method:M("elicitation/create"),params:$I}),wI=Ot.extend({elicitationId:$()}),kI=Nt.extend({method:M("notifications/elicitation/complete"),params:wI}),pl=Ke.extend({action:ct(["accept","decline","cancel"]),content:Gu(e=>e===null?void 0:e,Ie($(),$e([$(),ye(),Ve(),ae($())])).optional())}),xI=D({type:M("ref/resource"),uri:$()});var SI=D({type:M("ref/prompt"),name:$()}),TI=zt.extend({ref:$e([SI,xI]),argument:D({name:$(),value:$()}),context:D({arguments:Ie($(),$()).optional()}).optional()}),fl=We.extend({method:M("completion/complete"),params:TI});function z$(e){if(e.params.ref.type!=="ref/prompt")throw new TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function E$(e){if(e.params.ref.type!=="ref/resource")throw new TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var PI=Ke.extend({completion:et({values:ae($()).max(100),total:Oe(ye().int()),hasMore:Oe(Ve())})}),zI=D({uri:$().startsWith("file://"),name:$().optional(),_meta:Ie($(),je()).optional()}),EI=We.extend({method:M("roots/list"),params:zt.optional()}),xm=Ke.extend({roots:ae(zI)}),II=Nt.extend({method:M("notifications/roots/list_changed"),params:Ot.optional()}),RV=$e([Yu,fm,fl,bm,ul,cl,il,sl,al,EE,jE,Oo,ll,Qu,tl,rl,ol]),CV=$e([Bu,Xu,mm,II,Os]),AV=$e([Ju,wm,km,pl,xm,el,nl,Io]),DV=$e([Yu,iI,bI,EI,Qu,tl,rl,ol]),qV=$e([Bu,Xu,YE,NE,PE,HE,VE,Os,kI]),MV=$e([Ju,gE,PI,LE,AE,kE,xE,TE,dl,WE,el,nl,Io]),U=class e extends Error{constructor(t,r,o){super(`MCP error ${t}: ${r}`),this.code=t,this.data=o,this.name="McpError"}static fromError(t,r,o){if(t===V.UrlElicitationRequired&&o){let n=o;if(n.elicitations)return new am(n.elicitations,r)}return new e(t,r,o)}},am=class extends U{constructor(t,r=`URL elicitation${t.length>1?"s":""} required`){super(V.UrlElicitationRequired,r,{elicitations:t})}get elicitations(){return this.data?.elicitations??[]}};function Hr(e){return e==="completed"||e==="failed"||e==="cancelled"}var j$=Symbol("Let zodToJsonSchema decide on which parser to use");var I$={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"},O$=e=>typeof e=="string"?{...I$,name:e}:{...I$,...e};var N$=e=>{let t=O$(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(([o,n])=>[n._def,{def:n._def,path:[...t.basePath,t.definitionPath,o],jsonSchema:void 0}]))}};function Sm(e,t,r,o){o?.errorMessages&&r&&(e.errorMessage={...e.errorMessage,[t]:r})}function ue(e,t,r,o,n){e[t]=r,Sm(e,t,o,n)}var ml=(e,t)=>{let r=0;for(;r<e.length&&r<t.length&&e[r]===t[r];r++);return[(e.length-r).toString(),...t.slice(r)].join("/")};function qe(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?ml(t,e.currentPath):t.join("/")}}function R$(e,t){let r={type:"array"};return e.type?._def&&e.type?._def?.typeName!==z.ZodAny&&(r.items=G(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&ue(r,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&ue(r,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(ue(r,"minItems",e.exactLength.value,e.exactLength.message,t),ue(r,"maxItems",e.exactLength.value,e.exactLength.message,t)),r}function C$(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let o of e.checks)switch(o.kind){case"min":t.target==="jsonSchema7"?o.inclusive?ue(r,"minimum",o.value,o.message,t):ue(r,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(r.exclusiveMinimum=!0),ue(r,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(r,"maximum",o.value,o.message,t):ue(r,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(r.exclusiveMaximum=!0),ue(r,"maximum",o.value,o.message,t));break;case"multipleOf":ue(r,"multipleOf",o.value,o.message,t);break}return r}function A$(){return{type:"boolean"}}function hl(e,t){return G(e.type._def,t)}var D$=(e,t)=>G(e.innerType._def,t);function Tm(e,t,r){let o=r??t.dateStrategy;if(Array.isArray(o))return{anyOf:o.map((n,i)=>Tm(e,t,n))};switch(o){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return jI(e,t)}}var jI=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let o of e.checks)switch(o.kind){case"min":ue(r,"minimum",o.value,o.message,t);break;case"max":ue(r,"maximum",o.value,o.message,t);break}return r};function q$(e,t){return{...G(e.innerType._def,t),default:e.defaultValue()}}function M$(e,t){return t.effectStrategy==="input"?G(e.schema._def,t):qe(t)}function U$(e){return{type:"string",enum:Array.from(e.values)}}var OI=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function Z$(e,t){let r=[G(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),G(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(i=>!!i),o=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,n=[];return r.forEach(i=>{if(OI(i))n.push(...i.allOf),i.unevaluatedProperties===void 0&&(o=void 0);else{let s=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:a,...c}=i;s=c}else o=void 0;n.push(s)}}),n.length?{allOf:n,...o}:void 0}function L$(e,t){let r=typeof e.value;return r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:r==="bigint"?"integer":r,enum:[e.value]}:{type:r==="bigint"?"integer":r,const:e.value}}var Pm,Kt={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:()=>(Pm===void 0&&(Pm=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),Pm),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 gl(e,t){let r={type:"string"};if(e.checks)for(let o of e.checks)switch(o.kind){case"min":ue(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,o.value):o.value,o.message,t);break;case"max":ue(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,o.value):o.value,o.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Ht(r,"email",o.message,t);break;case"format:idn-email":Ht(r,"idn-email",o.message,t);break;case"pattern:zod":ut(r,Kt.email,o.message,t);break}break;case"url":Ht(r,"uri",o.message,t);break;case"uuid":Ht(r,"uuid",o.message,t);break;case"regex":ut(r,o.regex,o.message,t);break;case"cuid":ut(r,Kt.cuid,o.message,t);break;case"cuid2":ut(r,Kt.cuid2,o.message,t);break;case"startsWith":ut(r,RegExp(`^${zm(o.value,t)}`),o.message,t);break;case"endsWith":ut(r,RegExp(`${zm(o.value,t)}$`),o.message,t);break;case"datetime":Ht(r,"date-time",o.message,t);break;case"date":Ht(r,"date",o.message,t);break;case"time":Ht(r,"time",o.message,t);break;case"duration":Ht(r,"duration",o.message,t);break;case"length":ue(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,o.value):o.value,o.message,t),ue(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,o.value):o.value,o.message,t);break;case"includes":{ut(r,RegExp(zm(o.value,t)),o.message,t);break}case"ip":{o.version!=="v6"&&Ht(r,"ipv4",o.message,t),o.version!=="v4"&&Ht(r,"ipv6",o.message,t);break}case"base64url":ut(r,Kt.base64url,o.message,t);break;case"jwt":ut(r,Kt.jwt,o.message,t);break;case"cidr":{o.version!=="v6"&&ut(r,Kt.ipv4Cidr,o.message,t),o.version!=="v4"&&ut(r,Kt.ipv6Cidr,o.message,t);break}case"emoji":ut(r,Kt.emoji(),o.message,t);break;case"ulid":{ut(r,Kt.ulid,o.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Ht(r,"binary",o.message,t);break}case"contentEncoding:base64":{ue(r,"contentEncoding","base64",o.message,t);break}case"pattern:zod":{ut(r,Kt.base64,o.message,t);break}}break}case"nanoid":ut(r,Kt.nanoid,o.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return r}function zm(e,t){return t.patternStrategy==="escape"?RI(e):e}var NI=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function RI(e){let t="";for(let r=0;r<e.length;r++)NI.has(e[r])||(t+="\\"),t+=e[r];return t}function Ht(e,t,r,o){e.format||e.anyOf?.some(n=>n.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&o.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...r&&o.errorMessages&&{errorMessage:{format:r}}})):ue(e,"format",t,r,o)}function ut(e,t,r,o){e.pattern||e.allOf?.some(n=>n.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&o.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:V$(t,o),...r&&o.errorMessages&&{errorMessage:{pattern:r}}})):ue(e,"pattern",V$(t,o),r,o)}function V$(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")},o=r.i?e.source.toLowerCase():e.source,n="",i=!1,s=!1,a=!1;for(let c=0;c<o.length;c++){if(i){n+=o[c],i=!1;continue}if(r.i){if(s){if(o[c].match(/[a-z]/)){a?(n+=o[c],n+=`${o[c-2]}-${o[c]}`.toUpperCase(),a=!1):o[c+1]==="-"&&o[c+2]?.match(/[a-z]/)?(n+=o[c],a=!0):n+=`${o[c]}${o[c].toUpperCase()}`;continue}}else if(o[c].match(/[a-z]/)){n+=`[${o[c]}${o[c].toUpperCase()}]`;continue}}if(r.m){if(o[c]==="^"){n+=`(^|(?<=[\r
44
+ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let l of this.seen.entries()){let d=l[1];if(t===l[0]){s(l);continue}if(o.external){let m=o.external.registry.get(l[0])?.id;if(t!==l[0]&&m){s(l);continue}}if(this.metadataRegistry.get(l[0])?.id){s(l);continue}if(d.cycle){s(l);continue}if(d.count>1&&o.reused==="ref"){s(l);continue}}let a=(l,d)=>{let h=this.seen.get(l),m=h.def??h.schema,p={...m};if(h.ref===null)return;let f=h.ref;if(h.ref=null,f){a(f,d);let v=this.seen.get(f).schema;v.$ref&&d.target==="draft-7"?(m.allOf=m.allOf??[],m.allOf.push(v)):(Object.assign(m,v),Object.assign(m,p))}h.isParent||this.override({zodSchema:l,jsonSchema:m,path:h.path??[]})};for(let l of[...this.seen.entries()].reverse())a(l[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":console.warn(`Invalid target: ${this.target}`),o.external?.uri){let l=o.external.registry.get(t)?.id;if(!l)throw new Error("Schema is missing an `id` property");c.$id=o.external.uri(l)}Object.assign(c,n.def);let u=o.external?.defs??{};for(let l of this.seen.entries()){let d=l[1];d.def&&d.defId&&(u[d.defId]=d.def)}o.external||Object.keys(u).length>0&&(this.target==="draft-2020-12"?c.$defs=u:c.definitions=u);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}};function xo(e,t){if(e instanceof yo){let o=new ys(t),n={};for(let a of e._idmap.entries()){let[c,u]=a;o.process(u)}let i={},s={registry:e,uri:t?.uri,defs:n};for(let a of e._idmap.entries()){let[c,u]=a;i[c]=o.emit(u,{...t,external:s})}if(Object.keys(n).length>0){let a=o.target==="draft-2020-12"?"$defs":"definitions";i.__shared={[a]:n}}return{schemas:i}}let r=new ys(t);return r.process(e),r.emit(e,t)}function Fe(e,t){let r=t??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let n=e._zod.def;switch(n.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 Fe(n.element,r);case"object":{for(let i in n.shape)if(Fe(n.shape[i],r))return!0;return!1}case"union":{for(let i of n.options)if(Fe(i,r))return!0;return!1}case"intersection":return Fe(n.left,r)||Fe(n.right,r);case"tuple":{for(let i of n.items)if(Fe(i,r))return!0;return!!(n.rest&&Fe(n.rest,r))}case"record":return Fe(n.keyType,r)||Fe(n.valueType,r);case"map":return Fe(n.keyType,r)||Fe(n.valueType,r);case"set":return Fe(n.valueType,r);case"promise":case"optional":case"nonoptional":case"nullable":case"readonly":return Fe(n.innerType,r);case"lazy":return Fe(n.getter(),r);case"default":return Fe(n.innerType,r);case"prefault":return Fe(n.innerType,r);case"custom":return!1;case"transform":return!0;case"pipe":return Fe(n.in,r)||Fe(n.out,r);case"success":return!1;case"catch":return!1;default:}throw new Error(`Unknown schema type: ${n.type}`)}var Ty={};var tz=_("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");W.init(e,t),e.def=t,e.parse=(r,o)=>yn(e,r,o,{callee:e.parse}),e.safeParse=(r,o)=>Mr(e,r,o),e.parseAsync=async(r,o)=>bn(e,r,o,{callee:e.parseAsync}),e.safeParseAsync=async(r,o)=>Ur(e,r,o),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(r,o)=>et(e,r,o),e.brand=()=>e,e.register=((r,o)=>(r.add(e,o),e))});var rz=_("ZodMiniObject",(e,t)=>{Ai.init(e,t),tz.init(e,t),N.defineLazy(e,"shape",()=>t.shape)});function xf(e,t){let r={type:"object",get shape(){return N.assignProp(this,"shape",{...e}),this.shape},...N.normalizeParams(t)};return new rz(r)}function Nt(e){return!!e._zod}function Tn(e){let t=Object.values(e);if(t.length===0)return xf({});let r=t.every(Nt),o=t.every(n=>!Nt(n));if(r)return xf(e);if(o)return v_(e);throw new Error("Mixed Zod versions detected in object shape.")}function Gr(e,t){return Nt(e)?Mr(e,t):e.safeParse(t)}async function Nu(e,t){return Nt(e)?await Ur(e,t):await e.safeParseAsync(t)}function Wr(e){if(!e)return;let t;if(Nt(e)?t=e._zod?.def?.shape:t=e.shape,!!t){if(typeof t=="function")try{return t()}catch{return}return t}}function So(e){if(e){if(typeof e=="object"){let t=e,r=e;if(!t._def&&!r._zod){let o=Object.values(e);if(o.length>0&&o.every(n=>typeof n=="object"&&n!==null&&(n._def!==void 0||n._zod!==void 0||typeof n.parse=="function")))return Tn(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}}function Ru(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 Py(e){return e.description}function zy(e){if(Nt(e))return e._zod?.def?.type==="optional";let t=e;return typeof e.isOptional=="function"?e.isOptional():t._def?.typeName==="ZodOptional"}function Cu(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 o=e.value;if(o!==void 0)return o}var cm={};mn(cm,{$brand:()=>Ha,$input:()=>iu,$output:()=>ou,NEVER:()=>Ka,TimePrecision:()=>au,ZodAny:()=>Cy,ZodArray:()=>My,ZodBase64:()=>Hf,ZodBase64URL:()=>Jf,ZodBigInt:()=>xs,ZodBigIntFormat:()=>Xf,ZodBoolean:()=>ks,ZodCIDRv4:()=>Wf,ZodCIDRv6:()=>Kf,ZodCUID:()=>Mf,ZodCUID2:()=>Uf,ZodCatch:()=>eb,ZodCustom:()=>Ku,ZodCustomStringFormat:()=>Oy,ZodDate:()=>Fu,ZodDefault:()=>Hy,ZodDiscriminatedUnion:()=>Uy,ZodE164:()=>Bf,ZodEmail:()=>Cf,ZodEmoji:()=>Df,ZodEnum:()=>bs,ZodError:()=>iz,ZodFile:()=>Wy,ZodGUID:()=>Uu,ZodIPv4:()=>Ff,ZodIPv6:()=>Gf,ZodISODate:()=>Du,ZodISODateTime:()=>Au,ZodISODuration:()=>Mu,ZodISOTime:()=>qu,ZodIntersection:()=>Zy,ZodIssueCode:()=>oE,ZodJWT:()=>Yf,ZodKSUID:()=>Lf,ZodLazy:()=>sb,ZodLiteral:()=>Gy,ZodMap:()=>Ly,ZodNaN:()=>rb,ZodNanoID:()=>qf,ZodNever:()=>Dy,ZodNonOptional:()=>om,ZodNull:()=>Ry,ZodNullable:()=>Ky,ZodNumber:()=>ws,ZodNumberFormat:()=>zo,ZodObject:()=>Gu,ZodOptional:()=>nm,ZodPipe:()=>im,ZodPrefault:()=>By,ZodPromise:()=>cb,ZodReadonly:()=>nb,ZodRealError:()=>Po,ZodRecord:()=>em,ZodSet:()=>Fy,ZodString:()=>$s,ZodStringFormat:()=>Ee,ZodSuccess:()=>Qy,ZodSymbol:()=>jy,ZodTemplateLiteral:()=>ib,ZodTransform:()=>tm,ZodTuple:()=>Vy,ZodType:()=>te,ZodULID:()=>Zf,ZodURL:()=>Af,ZodUUID:()=>Sr,ZodUndefined:()=>Ny,ZodUnion:()=>Qf,ZodUnknown:()=>Ay,ZodVoid:()=>qy,ZodXID:()=>Vf,_ZodString:()=>Rf,_default:()=>Jy,any:()=>Mz,array:()=>ae,base64:()=>Sz,base64url:()=>Tz,bigint:()=>Rz,boolean:()=>Le,catch:()=>tb,check:()=>ub,cidrv4:()=>kz,cidrv6:()=>xz,clone:()=>et,coerce:()=>am,config:()=>Ue,core:()=>Kt,cuid:()=>gz,cuid2:()=>vz,custom:()=>sm,date:()=>Zz,discriminatedUnion:()=>Wu,e164:()=>Pz,email:()=>az,emoji:()=>mz,endsWith:()=>ps,enum:()=>lt,file:()=>Jz,flattenError:()=>lo,float32:()=>Iz,float64:()=>Oz,formatError:()=>po,function:()=>ju,getErrorMap:()=>sE,globalRegistry:()=>Wt,gt:()=>kr,gte:()=>vt,guid:()=>cz,includes:()=>ls,instanceof:()=>tE,int:()=>Nf,int32:()=>jz,int64:()=>Cz,intersection:()=>Ts,ipv4:()=>$z,ipv6:()=>wz,iso:()=>To,json:()=>nE,jwt:()=>zz,keyof:()=>Vz,ksuid:()=>bz,lazy:()=>ab,length:()=>ko,literal:()=>M,locales:()=>_o,looseObject:()=>tt,lowercase:()=>cs,lt:()=>wr,lte:()=>jt,map:()=>Wz,maxLength:()=>wo,maxSize:()=>$o,mime:()=>fs,minLength:()=>Fr,minSize:()=>Sn,multipleOf:()=>xn,nan:()=>Xz,nanoid:()=>hz,nativeEnum:()=>Hz,negative:()=>yf,never:()=>Lu,nonnegative:()=>$f,nonoptional:()=>Xy,nonpositive:()=>bf,normalize:()=>ms,null:()=>Ss,nullable:()=>Zu,nullish:()=>Bz,number:()=>ye,object:()=>D,optional:()=>je,overwrite:()=>xr,parse:()=>Ef,parseAsync:()=>If,partialRecord:()=>Gz,pipe:()=>Vu,positive:()=>_f,prefault:()=>Yy,preprocess:()=>Hu,prettifyError:()=>Ya,promise:()=>eE,property:()=>wf,readonly:()=>ob,record:()=>Ie,refine:()=>lb,regex:()=>as,regexes:()=>Zr,registry:()=>qi,safeParse:()=>Of,safeParseAsync:()=>jf,set:()=>Kz,setErrorMap:()=>iE,size:()=>ss,startsWith:()=>ds,strictObject:()=>Lz,string:()=>b,stringFormat:()=>Ez,stringbool:()=>rE,success:()=>Yz,superRefine:()=>db,symbol:()=>Dz,templateLiteral:()=>Qz,toJSONSchema:()=>xo,toLowerCase:()=>gs,toUpperCase:()=>vs,transform:()=>rm,treeifyError:()=>Ba,trim:()=>hs,tuple:()=>Fz,uint32:()=>Nz,uint64:()=>Az,ulid:()=>_z,undefined:()=>qz,union:()=>be,unknown:()=>Oe,uppercase:()=>us,url:()=>fz,uuid:()=>uz,uuidv4:()=>lz,uuidv6:()=>dz,uuidv7:()=>pz,void:()=>Uz,xid:()=>yz});var To={};mn(To,{ZodISODate:()=>Du,ZodISODateTime:()=>Au,ZodISODuration:()=>Mu,ZodISOTime:()=>qu,date:()=>Tf,datetime:()=>Sf,duration:()=>zf,time:()=>Pf});var Au=_("ZodISODateTime",(e,t)=>{nf.init(e,t),Ee.init(e,t)});function Sf(e){return lf(Au,e)}var Du=_("ZodISODate",(e,t)=>{of.init(e,t),Ee.init(e,t)});function Tf(e){return df(Du,e)}var qu=_("ZodISOTime",(e,t)=>{sf.init(e,t),Ee.init(e,t)});function Pf(e){return pf(qu,e)}var Mu=_("ZodISODuration",(e,t)=>{af.init(e,t),Ee.init(e,t)});function zf(e){return ff(Mu,e)}var Iy=(e,t)=>{ji.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:r=>po(e,r)},flatten:{value:r=>lo(e,r)},addIssue:{value:r=>e.issues.push(r)},addIssues:{value:r=>e.issues.push(...r)},isEmpty:{get(){return e.issues.length===0}}})},iz=_("ZodError",Iy),Po=_("ZodError",Iy,{Parent:Error});var Ef=Xa(Po),If=Qa(Po),Of=ec(Po),jf=tc(Po);var te=_("ZodType",(e,t)=>(W.init(e,t),e.def=t,Object.defineProperty(e,"_def",{value:t}),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map(o=>typeof o=="function"?{_zod:{check:o,def:{check:"custom"},onattach:[]}}:o)]}),e.clone=(r,o)=>et(e,r,o),e.brand=()=>e,e.register=((r,o)=>(r.add(e,o),e)),e.parse=(r,o)=>Ef(e,r,o,{callee:e.parse}),e.safeParse=(r,o)=>Of(e,r,o),e.parseAsync=async(r,o)=>If(e,r,o,{callee:e.parseAsync}),e.safeParseAsync=async(r,o)=>jf(e,r,o),e.spa=e.safeParseAsync,e.refine=(r,o)=>e.check(lb(r,o)),e.superRefine=r=>e.check(db(r)),e.overwrite=r=>e.check(xr(r)),e.optional=()=>je(e),e.nullable=()=>Zu(e),e.nullish=()=>je(Zu(e)),e.nonoptional=r=>Xy(e,r),e.array=()=>ae(e),e.or=r=>be([e,r]),e.and=r=>Ts(e,r),e.transform=r=>Vu(e,rm(r)),e.default=r=>Jy(e,r),e.prefault=r=>Yy(e,r),e.catch=r=>tb(e,r),e.pipe=r=>Vu(e,r),e.readonly=()=>ob(e),e.describe=r=>{let o=e.clone();return Wt.add(o,{description:r}),o},Object.defineProperty(e,"description",{get(){return Wt.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return Wt.get(e);let o=e.clone();return Wt.add(o,r[0]),o},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Rf=_("_ZodString",(e,t)=>{Vr.init(e,t),te.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=(...o)=>e.check(as(...o)),e.includes=(...o)=>e.check(ls(...o)),e.startsWith=(...o)=>e.check(ds(...o)),e.endsWith=(...o)=>e.check(ps(...o)),e.min=(...o)=>e.check(Fr(...o)),e.max=(...o)=>e.check(wo(...o)),e.length=(...o)=>e.check(ko(...o)),e.nonempty=(...o)=>e.check(Fr(1,...o)),e.lowercase=o=>e.check(cs(o)),e.uppercase=o=>e.check(us(o)),e.trim=()=>e.check(hs()),e.normalize=(...o)=>e.check(ms(...o)),e.toLowerCase=()=>e.check(gs()),e.toUpperCase=()=>e.check(vs())}),$s=_("ZodString",(e,t)=>{Vr.init(e,t),Rf.init(e,t),e.email=r=>e.check(Mi(Cf,r)),e.url=r=>e.check(Fi(Af,r)),e.jwt=r=>e.check(is(Yf,r)),e.emoji=r=>e.check(Gi(Df,r)),e.guid=r=>e.check(bo(Uu,r)),e.uuid=r=>e.check(Ui(Sr,r)),e.uuidv4=r=>e.check(Zi(Sr,r)),e.uuidv6=r=>e.check(Vi(Sr,r)),e.uuidv7=r=>e.check(Li(Sr,r)),e.nanoid=r=>e.check(Wi(qf,r)),e.guid=r=>e.check(bo(Uu,r)),e.cuid=r=>e.check(Ki(Mf,r)),e.cuid2=r=>e.check(Hi(Uf,r)),e.ulid=r=>e.check(Ji(Zf,r)),e.base64=r=>e.check(rs(Hf,r)),e.base64url=r=>e.check(ns(Jf,r)),e.xid=r=>e.check(Bi(Vf,r)),e.ksuid=r=>e.check(Yi(Lf,r)),e.ipv4=r=>e.check(Xi(Ff,r)),e.ipv6=r=>e.check(Qi(Gf,r)),e.cidrv4=r=>e.check(es(Wf,r)),e.cidrv6=r=>e.check(ts(Kf,r)),e.e164=r=>e.check(os(Bf,r)),e.datetime=r=>e.check(Sf(r)),e.date=r=>e.check(Tf(r)),e.time=r=>e.check(Pf(r)),e.duration=r=>e.check(zf(r))});function b(e){return su($s,e)}var Ee=_("ZodStringFormat",(e,t)=>{ke.init(e,t),Rf.init(e,t)}),Cf=_("ZodEmail",(e,t)=>{uc.init(e,t),Ee.init(e,t)});function az(e){return Mi(Cf,e)}var Uu=_("ZodGUID",(e,t)=>{ac.init(e,t),Ee.init(e,t)});function cz(e){return bo(Uu,e)}var Sr=_("ZodUUID",(e,t)=>{cc.init(e,t),Ee.init(e,t)});function uz(e){return Ui(Sr,e)}function lz(e){return Zi(Sr,e)}function dz(e){return Vi(Sr,e)}function pz(e){return Li(Sr,e)}var Af=_("ZodURL",(e,t)=>{lc.init(e,t),Ee.init(e,t)});function fz(e){return Fi(Af,e)}var Df=_("ZodEmoji",(e,t)=>{dc.init(e,t),Ee.init(e,t)});function mz(e){return Gi(Df,e)}var qf=_("ZodNanoID",(e,t)=>{pc.init(e,t),Ee.init(e,t)});function hz(e){return Wi(qf,e)}var Mf=_("ZodCUID",(e,t)=>{fc.init(e,t),Ee.init(e,t)});function gz(e){return Ki(Mf,e)}var Uf=_("ZodCUID2",(e,t)=>{mc.init(e,t),Ee.init(e,t)});function vz(e){return Hi(Uf,e)}var Zf=_("ZodULID",(e,t)=>{hc.init(e,t),Ee.init(e,t)});function _z(e){return Ji(Zf,e)}var Vf=_("ZodXID",(e,t)=>{gc.init(e,t),Ee.init(e,t)});function yz(e){return Bi(Vf,e)}var Lf=_("ZodKSUID",(e,t)=>{vc.init(e,t),Ee.init(e,t)});function bz(e){return Yi(Lf,e)}var Ff=_("ZodIPv4",(e,t)=>{_c.init(e,t),Ee.init(e,t)});function $z(e){return Xi(Ff,e)}var Gf=_("ZodIPv6",(e,t)=>{yc.init(e,t),Ee.init(e,t)});function wz(e){return Qi(Gf,e)}var Wf=_("ZodCIDRv4",(e,t)=>{bc.init(e,t),Ee.init(e,t)});function kz(e){return es(Wf,e)}var Kf=_("ZodCIDRv6",(e,t)=>{$c.init(e,t),Ee.init(e,t)});function xz(e){return ts(Kf,e)}var Hf=_("ZodBase64",(e,t)=>{wc.init(e,t),Ee.init(e,t)});function Sz(e){return rs(Hf,e)}var Jf=_("ZodBase64URL",(e,t)=>{kc.init(e,t),Ee.init(e,t)});function Tz(e){return ns(Jf,e)}var Bf=_("ZodE164",(e,t)=>{xc.init(e,t),Ee.init(e,t)});function Pz(e){return os(Bf,e)}var Yf=_("ZodJWT",(e,t)=>{Sc.init(e,t),Ee.init(e,t)});function zz(e){return is(Yf,e)}var Oy=_("ZodCustomStringFormat",(e,t)=>{Tc.init(e,t),Ee.init(e,t)});function Ez(e,t,r={}){return Iu(Oy,e,t,r)}var ws=_("ZodNumber",(e,t)=>{Ri.init(e,t),te.init(e,t),e.gt=(o,n)=>e.check(kr(o,n)),e.gte=(o,n)=>e.check(vt(o,n)),e.min=(o,n)=>e.check(vt(o,n)),e.lt=(o,n)=>e.check(wr(o,n)),e.lte=(o,n)=>e.check(jt(o,n)),e.max=(o,n)=>e.check(jt(o,n)),e.int=o=>e.check(Nf(o)),e.safe=o=>e.check(Nf(o)),e.positive=o=>e.check(kr(0,o)),e.nonnegative=o=>e.check(vt(0,o)),e.negative=o=>e.check(wr(0,o)),e.nonpositive=o=>e.check(jt(0,o)),e.multipleOf=(o,n)=>e.check(xn(o,n)),e.step=(o,n)=>e.check(xn(o,n)),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??.5),e.isFinite=!0,e.format=r.format??null});function ye(e){return cu(ws,e)}var zo=_("ZodNumberFormat",(e,t)=>{Pc.init(e,t),ws.init(e,t)});function Nf(e){return uu(zo,e)}function Iz(e){return lu(zo,e)}function Oz(e){return du(zo,e)}function jz(e){return pu(zo,e)}function Nz(e){return fu(zo,e)}var ks=_("ZodBoolean",(e,t)=>{mo.init(e,t),te.init(e,t)});function Le(e){return mu(ks,e)}var xs=_("ZodBigInt",(e,t)=>{Ci.init(e,t),te.init(e,t),e.gte=(o,n)=>e.check(vt(o,n)),e.min=(o,n)=>e.check(vt(o,n)),e.gt=(o,n)=>e.check(kr(o,n)),e.gte=(o,n)=>e.check(vt(o,n)),e.min=(o,n)=>e.check(vt(o,n)),e.lt=(o,n)=>e.check(wr(o,n)),e.lte=(o,n)=>e.check(jt(o,n)),e.max=(o,n)=>e.check(jt(o,n)),e.positive=o=>e.check(kr(BigInt(0),o)),e.negative=o=>e.check(wr(BigInt(0),o)),e.nonpositive=o=>e.check(jt(BigInt(0),o)),e.nonnegative=o=>e.check(vt(BigInt(0),o)),e.multipleOf=(o,n)=>e.check(xn(o,n));let r=e._zod.bag;e.minValue=r.minimum??null,e.maxValue=r.maximum??null,e.format=r.format??null});function Rz(e){return hu(xs,e)}var Xf=_("ZodBigIntFormat",(e,t)=>{zc.init(e,t),xs.init(e,t)});function Cz(e){return gu(Xf,e)}function Az(e){return vu(Xf,e)}var jy=_("ZodSymbol",(e,t)=>{Ec.init(e,t),te.init(e,t)});function Dz(e){return _u(jy,e)}var Ny=_("ZodUndefined",(e,t)=>{Ic.init(e,t),te.init(e,t)});function qz(e){return yu(Ny,e)}var Ry=_("ZodNull",(e,t)=>{Oc.init(e,t),te.init(e,t)});function Ss(e){return bu(Ry,e)}var Cy=_("ZodAny",(e,t)=>{jc.init(e,t),te.init(e,t)});function Mz(){return $u(Cy)}var Ay=_("ZodUnknown",(e,t)=>{wn.init(e,t),te.init(e,t)});function Oe(){return kn(Ay)}var Dy=_("ZodNever",(e,t)=>{Nc.init(e,t),te.init(e,t)});function Lu(e){return wu(Dy,e)}var qy=_("ZodVoid",(e,t)=>{Rc.init(e,t),te.init(e,t)});function Uz(e){return ku(qy,e)}var Fu=_("ZodDate",(e,t)=>{Cc.init(e,t),te.init(e,t),e.min=(o,n)=>e.check(vt(o,n)),e.max=(o,n)=>e.check(jt(o,n));let r=e._zod.bag;e.minDate=r.minimum?new Date(r.minimum):null,e.maxDate=r.maximum?new Date(r.maximum):null});function Zz(e){return xu(Fu,e)}var My=_("ZodArray",(e,t)=>{ho.init(e,t),te.init(e,t),e.element=t.element,e.min=(r,o)=>e.check(Fr(r,o)),e.nonempty=r=>e.check(Fr(1,r)),e.max=(r,o)=>e.check(wo(r,o)),e.length=(r,o)=>e.check(ko(r,o)),e.unwrap=()=>e.element});function ae(e,t){return _s(My,e,t)}function Vz(e){let t=e._zod.def.shape;return M(Object.keys(t))}var Gu=_("ZodObject",(e,t)=>{Ai.init(e,t),te.init(e,t),N.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>lt(Object.keys(e._zod.def.shape)),e.catchall=r=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:Oe()}),e.loose=()=>e.clone({...e._zod.def,catchall:Oe()}),e.strict=()=>e.clone({...e._zod.def,catchall:Lu()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=r=>N.extend(e,r),e.merge=r=>N.merge(e,r),e.pick=r=>N.pick(e,r),e.omit=r=>N.omit(e,r),e.partial=(...r)=>N.partial(nm,e,r[0]),e.required=(...r)=>N.required(om,e,r[0])});function D(e,t){let r={type:"object",get shape(){return N.assignProp(this,"shape",{...e}),this.shape},...N.normalizeParams(t)};return new Gu(r)}function Lz(e,t){return new Gu({type:"object",get shape(){return N.assignProp(this,"shape",{...e}),this.shape},catchall:Lu(),...N.normalizeParams(t)})}function tt(e,t){return new Gu({type:"object",get shape(){return N.assignProp(this,"shape",{...e}),this.shape},catchall:Oe(),...N.normalizeParams(t)})}var Qf=_("ZodUnion",(e,t)=>{Di.init(e,t),te.init(e,t),e.options=t.options});function be(e,t){return new Qf({type:"union",options:e,...N.normalizeParams(t)})}var Uy=_("ZodDiscriminatedUnion",(e,t)=>{Qf.init(e,t),Ac.init(e,t)});function Wu(e,t,r){return new Uy({type:"union",options:t,discriminator:e,...N.normalizeParams(r)})}var Zy=_("ZodIntersection",(e,t)=>{Dc.init(e,t),te.init(e,t)});function Ts(e,t){return new Zy({type:"intersection",left:e,right:t})}var Vy=_("ZodTuple",(e,t)=>{Lr.init(e,t),te.init(e,t),e.rest=r=>e.clone({...e._zod.def,rest:r})});function Fz(e,t,r){let o=t instanceof W,n=o?r:t,i=o?t:null;return new Vy({type:"tuple",items:e,rest:i,...N.normalizeParams(n)})}var em=_("ZodRecord",(e,t)=>{qc.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function Ie(e,t,r){return new em({type:"record",keyType:e,valueType:t,...N.normalizeParams(r)})}function Gz(e,t,r){return new em({type:"record",keyType:be([e,Lu()]),valueType:t,...N.normalizeParams(r)})}var Ly=_("ZodMap",(e,t)=>{Mc.init(e,t),te.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function Wz(e,t,r){return new Ly({type:"map",keyType:e,valueType:t,...N.normalizeParams(r)})}var Fy=_("ZodSet",(e,t)=>{Uc.init(e,t),te.init(e,t),e.min=(...r)=>e.check(Sn(...r)),e.nonempty=r=>e.check(Sn(1,r)),e.max=(...r)=>e.check($o(...r)),e.size=(...r)=>e.check(ss(...r))});function Kz(e,t){return new Fy({type:"set",valueType:e,...N.normalizeParams(t)})}var bs=_("ZodEnum",(e,t)=>{Zc.init(e,t),te.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let r=new Set(Object.keys(t.entries));e.extract=(o,n)=>{let i={};for(let s of o)if(r.has(s))i[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new bs({...t,checks:[],...N.normalizeParams(n),entries:i})},e.exclude=(o,n)=>{let i={...t.entries};for(let s of o)if(r.has(s))delete i[s];else throw new Error(`Key ${s} not found in enum`);return new bs({...t,checks:[],...N.normalizeParams(n),entries:i})}});function lt(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(o=>[o,o])):e;return new bs({type:"enum",entries:r,...N.normalizeParams(t)})}function Hz(e,t){return new bs({type:"enum",entries:e,...N.normalizeParams(t)})}var Gy=_("ZodLiteral",(e,t)=>{Vc.init(e,t),te.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function M(e,t){return new Gy({type:"literal",values:Array.isArray(e)?e:[e],...N.normalizeParams(t)})}var Wy=_("ZodFile",(e,t)=>{Lc.init(e,t),te.init(e,t),e.min=(r,o)=>e.check(Sn(r,o)),e.max=(r,o)=>e.check($o(r,o)),e.mime=(r,o)=>e.check(fs(Array.isArray(r)?r:[r],o))});function Jz(e){return Tu(Wy,e)}var tm=_("ZodTransform",(e,t)=>{go.init(e,t),te.init(e,t),e._zod.parse=(r,o)=>{r.addIssue=i=>{if(typeof i=="string")r.issues.push(N.issue(i,r.value,t));else{let s=i;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(N.issue(s))}};let n=t.transform(r.value,r);return n instanceof Promise?n.then(i=>(r.value=i,r)):(r.value=n,r)}});function rm(e){return new tm({type:"transform",transform:e})}var nm=_("ZodOptional",(e,t)=>{Fc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function je(e){return new nm({type:"optional",innerType:e})}var Ky=_("ZodNullable",(e,t)=>{Gc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Zu(e){return new Ky({type:"nullable",innerType:e})}function Bz(e){return je(Zu(e))}var Hy=_("ZodDefault",(e,t)=>{Wc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Jy(e,t){return new Hy({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():t}})}var By=_("ZodPrefault",(e,t)=>{Kc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Yy(e,t){return new By({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():t}})}var om=_("ZodNonOptional",(e,t)=>{Hc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Xy(e,t){return new om({type:"nonoptional",innerType:e,...N.normalizeParams(t)})}var Qy=_("ZodSuccess",(e,t)=>{Jc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Yz(e){return new Qy({type:"success",innerType:e})}var eb=_("ZodCatch",(e,t)=>{Bc.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function tb(e,t){return new eb({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}var rb=_("ZodNaN",(e,t)=>{Yc.init(e,t),te.init(e,t)});function Xz(e){return Su(rb,e)}var im=_("ZodPipe",(e,t)=>{vo.init(e,t),te.init(e,t),e.in=t.in,e.out=t.out});function Vu(e,t){return new im({type:"pipe",in:e,out:t})}var nb=_("ZodReadonly",(e,t)=>{Xc.init(e,t),te.init(e,t)});function ob(e){return new nb({type:"readonly",innerType:e})}var ib=_("ZodTemplateLiteral",(e,t)=>{Qc.init(e,t),te.init(e,t)});function Qz(e,t){return new ib({type:"template_literal",parts:e,...N.normalizeParams(t)})}var sb=_("ZodLazy",(e,t)=>{tu.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.getter()});function ab(e){return new sb({type:"lazy",getter:e})}var cb=_("ZodPromise",(e,t)=>{eu.init(e,t),te.init(e,t),e.unwrap=()=>e._zod.def.innerType});function eE(e){return new cb({type:"promise",innerType:e})}var Ku=_("ZodCustom",(e,t)=>{ru.init(e,t),te.init(e,t)});function ub(e){let t=new De({check:"custom"});return t._zod.check=e,t}function sm(e,t){return Pu(Ku,e??(()=>!0),t)}function lb(e,t={}){return zu(Ku,e,t)}function db(e){let t=ub(r=>(r.addIssue=o=>{if(typeof o=="string")r.issues.push(N.issue(o,r.value,t._zod.def));else{let n=o;n.fatal&&(n.continue=!1),n.code??(n.code="custom"),n.input??(n.input=r.value),n.inst??(n.inst=t),n.continue??(n.continue=!t._zod.def.abort),r.issues.push(N.issue(n))}},e(r.value,r)));return t}function tE(e,t={error:`Input not instance of ${e.name}`}){let r=new Ku({type:"custom",check:"custom",fn:o=>o instanceof e,abort:!0,...N.normalizeParams(t)});return r._zod.bag.Class=e,r}var rE=(...e)=>Eu({Pipe:im,Boolean:ks,String:$s,Transform:tm},...e);function nE(e){let t=ab(()=>be([b(e),ye(),Le(),Ss(),ae(t),Ie(b(),t)]));return t}function Hu(e,t){return Vu(rm(e),t)}var oE={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function iE(e){Ue({customError:e})}function sE(){return Ue().customError}var am={};mn(am,{bigint:()=>lE,boolean:()=>uE,date:()=>dE,number:()=>cE,string:()=>aE});function aE(e){return uf($s,e)}function cE(e){return mf(ws,e)}function uE(e){return hf(ks,e)}function lE(e){return gf(xs,e)}function dE(e){return vf(Fu,e)}Ue(nu());var pb=cm;var g=pb;var lm="2025-11-25";var fb=[lm,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],Kr="io.modelcontextprotocol/related-task",Bu="2.0",We=sm(e=>e!==null&&(typeof e=="object"||typeof e=="function")),mb=be([b(),ye().int()]),hb=b(),XL=tt({ttl:be([ye(),Ss()]).optional(),pollInterval:ye().optional()}),fE=D({ttl:ye().optional()}),mE=D({taskId:b()}),dm=tt({progressToken:mb.optional(),[Kr]:mE.optional()}),It=D({_meta:dm.optional()}),Ps=It.extend({task:fE.optional()}),gb=e=>Ps.safeParse(e).success,Ke=D({method:b(),params:It.loose().optional()}),Rt=D({_meta:dm.optional()}),Ct=D({method:b(),params:Rt.loose().optional()}),He=tt({_meta:dm.optional()}),Yu=be([b(),ye().int()]),vb=D({jsonrpc:M(Bu),id:Yu,...Ke.shape}).strict(),pm=e=>vb.safeParse(e).success,_b=D({jsonrpc:M(Bu),...Ct.shape}).strict(),yb=e=>_b.safeParse(e).success,fm=D({jsonrpc:M(Bu),id:Yu,result:He}).strict(),zs=e=>fm.safeParse(e).success;var L;(function(e){e[e.ConnectionClosed=-32e3]="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"})(L||(L={}));var mm=D({jsonrpc:M(Bu),id:Yu.optional(),error:D({code:ye().int(),message:b(),data:Oe().optional()})}).strict();var bb=e=>mm.safeParse(e).success;var $b=be([vb,_b,fm,mm]),QL=be([fm,mm]),Xu=He.strict(),hE=Rt.extend({requestId:Yu.optional(),reason:b().optional()}),Qu=Ct.extend({method:M("notifications/cancelled"),params:hE}),gE=D({src:b(),mimeType:b().optional(),sizes:ae(b()).optional(),theme:lt(["light","dark"]).optional()}),Es=D({icons:ae(gE).optional()}),Eo=D({name:b(),title:b().optional()}),wb=Eo.extend({...Eo.shape,...Es.shape,version:b(),websiteUrl:b().optional(),description:b().optional()}),vE=Ts(D({applyDefaults:Le().optional()}),Ie(b(),Oe())),_E=Hu(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,Ts(D({form:vE.optional(),url:We.optional()}),Ie(b(),Oe()).optional())),yE=tt({list:We.optional(),cancel:We.optional(),requests:tt({sampling:tt({createMessage:We.optional()}).optional(),elicitation:tt({create:We.optional()}).optional()}).optional()}),bE=tt({list:We.optional(),cancel:We.optional(),requests:tt({tools:tt({call:We.optional()}).optional()}).optional()}),$E=D({experimental:Ie(b(),We).optional(),sampling:D({context:We.optional(),tools:We.optional()}).optional(),elicitation:_E.optional(),roots:D({listChanged:Le().optional()}).optional(),tasks:yE.optional()}),wE=It.extend({protocolVersion:b(),capabilities:$E,clientInfo:wb}),hm=Ke.extend({method:M("initialize"),params:wE});var kE=D({experimental:Ie(b(),We).optional(),logging:We.optional(),completions:We.optional(),prompts:D({listChanged:Le().optional()}).optional(),resources:D({subscribe:Le().optional(),listChanged:Le().optional()}).optional(),tools:D({listChanged:Le().optional()}).optional(),tasks:bE.optional()}),xE=He.extend({protocolVersion:b(),capabilities:kE,serverInfo:wb,instructions:b().optional()}),gm=Ct.extend({method:M("notifications/initialized"),params:Rt.optional()});var el=Ke.extend({method:M("ping"),params:It.optional()}),SE=D({progress:ye(),total:je(ye()),message:je(b())}),TE=D({...Rt.shape,...SE.shape,progressToken:mb}),tl=Ct.extend({method:M("notifications/progress"),params:TE}),PE=It.extend({cursor:hb.optional()}),Is=Ke.extend({params:PE.optional()}),Os=He.extend({nextCursor:hb.optional()}),zE=lt(["working","input_required","completed","failed","cancelled"]),js=D({taskId:b(),status:zE,ttl:be([ye(),Ss()]),createdAt:b(),lastUpdatedAt:b(),pollInterval:je(ye()),statusMessage:je(b())}),Io=He.extend({task:js}),EE=Rt.merge(js),Ns=Ct.extend({method:M("notifications/tasks/status"),params:EE}),rl=Ke.extend({method:M("tasks/get"),params:It.extend({taskId:b()})}),nl=He.merge(js),ol=Ke.extend({method:M("tasks/result"),params:It.extend({taskId:b()})}),e9=He.loose(),il=Is.extend({method:M("tasks/list")}),sl=Os.extend({tasks:ae(js)}),al=Ke.extend({method:M("tasks/cancel"),params:It.extend({taskId:b()})}),kb=He.merge(js),xb=D({uri:b(),mimeType:je(b()),_meta:Ie(b(),Oe()).optional()}),Sb=xb.extend({text:b()}),vm=b().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),Tb=xb.extend({blob:vm}),Rs=lt(["user","assistant"]),Oo=D({audience:ae(Rs).optional(),priority:ye().min(0).max(1).optional(),lastModified:To.datetime({offset:!0}).optional()}),Pb=D({...Eo.shape,...Es.shape,uri:b(),description:je(b()),mimeType:je(b()),annotations:Oo.optional(),_meta:je(tt({}))}),IE=D({...Eo.shape,...Es.shape,uriTemplate:b(),description:je(b()),mimeType:je(b()),annotations:Oo.optional(),_meta:je(tt({}))}),cl=Is.extend({method:M("resources/list")}),OE=Os.extend({resources:ae(Pb)}),ul=Is.extend({method:M("resources/templates/list")}),jE=Os.extend({resourceTemplates:ae(IE)}),_m=It.extend({uri:b()}),NE=_m,ll=Ke.extend({method:M("resources/read"),params:NE}),RE=He.extend({contents:ae(be([Sb,Tb]))}),CE=Ct.extend({method:M("notifications/resources/list_changed"),params:Rt.optional()}),AE=_m,DE=Ke.extend({method:M("resources/subscribe"),params:AE}),qE=_m,ME=Ke.extend({method:M("resources/unsubscribe"),params:qE}),UE=Rt.extend({uri:b()}),ZE=Ct.extend({method:M("notifications/resources/updated"),params:UE}),VE=D({name:b(),description:je(b()),required:je(Le())}),LE=D({...Eo.shape,...Es.shape,description:je(b()),arguments:je(ae(VE)),_meta:je(tt({}))}),dl=Is.extend({method:M("prompts/list")}),FE=Os.extend({prompts:ae(LE)}),GE=It.extend({name:b(),arguments:Ie(b(),b()).optional()}),pl=Ke.extend({method:M("prompts/get"),params:GE}),ym=D({type:M("text"),text:b(),annotations:Oo.optional(),_meta:Ie(b(),Oe()).optional()}),bm=D({type:M("image"),data:vm,mimeType:b(),annotations:Oo.optional(),_meta:Ie(b(),Oe()).optional()}),$m=D({type:M("audio"),data:vm,mimeType:b(),annotations:Oo.optional(),_meta:Ie(b(),Oe()).optional()}),WE=D({type:M("tool_use"),name:b(),id:b(),input:Ie(b(),Oe()),_meta:Ie(b(),Oe()).optional()}),KE=D({type:M("resource"),resource:be([Sb,Tb]),annotations:Oo.optional(),_meta:Ie(b(),Oe()).optional()}),HE=Pb.extend({type:M("resource_link")}),wm=be([ym,bm,$m,HE,KE]),JE=D({role:Rs,content:wm}),BE=He.extend({description:b().optional(),messages:ae(JE)}),YE=Ct.extend({method:M("notifications/prompts/list_changed"),params:Rt.optional()}),XE=D({title:b().optional(),readOnlyHint:Le().optional(),destructiveHint:Le().optional(),idempotentHint:Le().optional(),openWorldHint:Le().optional()}),QE=D({taskSupport:lt(["required","optional","forbidden"]).optional()}),zb=D({...Eo.shape,...Es.shape,description:b().optional(),inputSchema:D({type:M("object"),properties:Ie(b(),We).optional(),required:ae(b()).optional()}).catchall(Oe()),outputSchema:D({type:M("object"),properties:Ie(b(),We).optional(),required:ae(b()).optional()}).catchall(Oe()).optional(),annotations:XE.optional(),execution:QE.optional(),_meta:Ie(b(),Oe()).optional()}),fl=Is.extend({method:M("tools/list")}),eI=Os.extend({tools:ae(zb)}),ml=He.extend({content:ae(wm).default([]),structuredContent:Ie(b(),Oe()).optional(),isError:Le().optional()}),t9=ml.or(He.extend({toolResult:Oe()})),tI=Ps.extend({name:b(),arguments:Ie(b(),Oe()).optional()}),jo=Ke.extend({method:M("tools/call"),params:tI}),rI=Ct.extend({method:M("notifications/tools/list_changed"),params:Rt.optional()}),r9=D({autoRefresh:Le().default(!0),debounceMs:ye().int().nonnegative().default(300)}),Cs=lt(["debug","info","notice","warning","error","critical","alert","emergency"]),nI=It.extend({level:Cs}),km=Ke.extend({method:M("logging/setLevel"),params:nI}),oI=Rt.extend({level:Cs,logger:b().optional(),data:Oe()}),iI=Ct.extend({method:M("notifications/message"),params:oI}),sI=D({name:b().optional()}),aI=D({hints:ae(sI).optional(),costPriority:ye().min(0).max(1).optional(),speedPriority:ye().min(0).max(1).optional(),intelligencePriority:ye().min(0).max(1).optional()}),cI=D({mode:lt(["auto","required","none"]).optional()}),uI=D({type:M("tool_result"),toolUseId:b().describe("The unique identifier for the corresponding tool call."),content:ae(wm).default([]),structuredContent:D({}).loose().optional(),isError:Le().optional(),_meta:Ie(b(),Oe()).optional()}),lI=Wu("type",[ym,bm,$m]),Ju=Wu("type",[ym,bm,$m,WE,uI]),dI=D({role:Rs,content:be([Ju,ae(Ju)]),_meta:Ie(b(),Oe()).optional()}),pI=Ps.extend({messages:ae(dI),modelPreferences:aI.optional(),systemPrompt:b().optional(),includeContext:lt(["none","thisServer","allServers"]).optional(),temperature:ye().optional(),maxTokens:ye().int(),stopSequences:ae(b()).optional(),metadata:We.optional(),tools:ae(zb).optional(),toolChoice:cI.optional()}),fI=Ke.extend({method:M("sampling/createMessage"),params:pI}),As=He.extend({model:b(),stopReason:je(lt(["endTurn","stopSequence","maxTokens"]).or(b())),role:Rs,content:lI}),xm=He.extend({model:b(),stopReason:je(lt(["endTurn","stopSequence","maxTokens","toolUse"]).or(b())),role:Rs,content:be([Ju,ae(Ju)])}),mI=D({type:M("boolean"),title:b().optional(),description:b().optional(),default:Le().optional()}),hI=D({type:M("string"),title:b().optional(),description:b().optional(),minLength:ye().optional(),maxLength:ye().optional(),format:lt(["email","uri","date","date-time"]).optional(),default:b().optional()}),gI=D({type:lt(["number","integer"]),title:b().optional(),description:b().optional(),minimum:ye().optional(),maximum:ye().optional(),default:ye().optional()}),vI=D({type:M("string"),title:b().optional(),description:b().optional(),enum:ae(b()),default:b().optional()}),_I=D({type:M("string"),title:b().optional(),description:b().optional(),oneOf:ae(D({const:b(),title:b()})),default:b().optional()}),yI=D({type:M("string"),title:b().optional(),description:b().optional(),enum:ae(b()),enumNames:ae(b()).optional(),default:b().optional()}),bI=be([vI,_I]),$I=D({type:M("array"),title:b().optional(),description:b().optional(),minItems:ye().optional(),maxItems:ye().optional(),items:D({type:M("string"),enum:ae(b())}),default:ae(b()).optional()}),wI=D({type:M("array"),title:b().optional(),description:b().optional(),minItems:ye().optional(),maxItems:ye().optional(),items:D({anyOf:ae(D({const:b(),title:b()}))}),default:ae(b()).optional()}),kI=be([$I,wI]),xI=be([yI,bI,kI]),SI=be([xI,mI,hI,gI]),TI=Ps.extend({mode:M("form").optional(),message:b(),requestedSchema:D({type:M("object"),properties:Ie(b(),SI),required:ae(b()).optional()})}),PI=Ps.extend({mode:M("url"),message:b(),elicitationId:b(),url:b().url()}),zI=be([TI,PI]),EI=Ke.extend({method:M("elicitation/create"),params:zI}),II=Rt.extend({elicitationId:b()}),OI=Ct.extend({method:M("notifications/elicitation/complete"),params:II}),No=He.extend({action:lt(["accept","decline","cancel"]),content:Hu(e=>e===null?void 0:e,Ie(b(),be([b(),ye(),Le(),ae(b())])).optional())}),jI=D({type:M("ref/resource"),uri:b()});var NI=D({type:M("ref/prompt"),name:b()}),RI=It.extend({ref:be([NI,jI]),argument:D({name:b(),value:b()}),context:D({arguments:Ie(b(),b()).optional()}).optional()}),hl=Ke.extend({method:M("completion/complete"),params:RI});function Eb(e){if(e.params.ref.type!=="ref/prompt")throw new TypeError(`Expected CompleteRequestPrompt, but got ${e.params.ref.type}`)}function Ib(e){if(e.params.ref.type!=="ref/resource")throw new TypeError(`Expected CompleteRequestResourceTemplate, but got ${e.params.ref.type}`)}var CI=He.extend({completion:tt({values:ae(b()).max(100),total:je(ye().int()),hasMore:je(Le())})}),AI=D({uri:b().startsWith("file://"),name:b().optional(),_meta:Ie(b(),Oe()).optional()}),DI=Ke.extend({method:M("roots/list"),params:It.optional()}),Sm=He.extend({roots:ae(AI)}),qI=Ct.extend({method:M("notifications/roots/list_changed"),params:Rt.optional()}),n9=be([el,hm,hl,km,pl,dl,cl,ul,ll,DE,ME,jo,fl,rl,ol,il,al]),o9=be([Qu,tl,gm,qI,Ns]),i9=be([Xu,As,xm,No,Sm,nl,sl,Io]),s9=be([el,fI,EI,DI,rl,ol,il,al]),a9=be([Qu,tl,iI,ZE,CE,rI,YE,Ns,OI]),c9=be([Xu,xE,CI,BE,FE,OE,jE,RE,ml,eI,nl,sl,Io]),U=class e extends Error{constructor(t,r,o){super(`MCP error ${t}: ${r}`),this.code=t,this.data=o,this.name="McpError"}static fromError(t,r,o){if(t===L.UrlElicitationRequired&&o){let n=o;if(n.elicitations)return new um(n.elicitations,r)}return new e(t,r,o)}},um=class extends U{constructor(t,r=`URL elicitation${t.length>1?"s":""} required`){super(L.UrlElicitationRequired,r,{elicitations:t})}get elicitations(){return this.data?.elicitations??[]}};function Hr(e){return e==="completed"||e==="failed"||e==="cancelled"}var jb=Symbol("Let zodToJsonSchema decide on which parser to use");var Ob={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"},Nb=e=>typeof e=="string"?{...Ob,name:e}:{...Ob,...e};var Rb=e=>{let t=Nb(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(([o,n])=>[n._def,{def:n._def,path:[...t.basePath,t.definitionPath,o],jsonSchema:void 0}]))}};function Tm(e,t,r,o){o?.errorMessages&&r&&(e.errorMessage={...e.errorMessage,[t]:r})}function ue(e,t,r,o,n){e[t]=r,Tm(e,t,o,n)}var gl=(e,t)=>{let r=0;for(;r<e.length&&r<t.length&&e[r]===t[r];r++);return[(e.length-r).toString(),...t.slice(r)].join("/")};function qe(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?gl(t,e.currentPath):t.join("/")}}function Cb(e,t){let r={type:"array"};return e.type?._def&&e.type?._def?.typeName!==z.ZodAny&&(r.items=G(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&ue(r,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&ue(r,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(ue(r,"minItems",e.exactLength.value,e.exactLength.message,t),ue(r,"maxItems",e.exactLength.value,e.exactLength.message,t)),r}function Ab(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let o of e.checks)switch(o.kind){case"min":t.target==="jsonSchema7"?o.inclusive?ue(r,"minimum",o.value,o.message,t):ue(r,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(r.exclusiveMinimum=!0),ue(r,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(r,"maximum",o.value,o.message,t):ue(r,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(r.exclusiveMaximum=!0),ue(r,"maximum",o.value,o.message,t));break;case"multipleOf":ue(r,"multipleOf",o.value,o.message,t);break}return r}function Db(){return{type:"boolean"}}function vl(e,t){return G(e.type._def,t)}var qb=(e,t)=>G(e.innerType._def,t);function Pm(e,t,r){let o=r??t.dateStrategy;if(Array.isArray(o))return{anyOf:o.map((n,i)=>Pm(e,t,n))};switch(o){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return MI(e,t)}}var MI=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let o of e.checks)switch(o.kind){case"min":ue(r,"minimum",o.value,o.message,t);break;case"max":ue(r,"maximum",o.value,o.message,t);break}return r};function Mb(e,t){return{...G(e.innerType._def,t),default:e.defaultValue()}}function Ub(e,t){return t.effectStrategy==="input"?G(e.schema._def,t):qe(t)}function Zb(e){return{type:"string",enum:Array.from(e.values)}}var UI=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function Vb(e,t){let r=[G(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),G(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(i=>!!i),o=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,n=[];return r.forEach(i=>{if(UI(i))n.push(...i.allOf),i.unevaluatedProperties===void 0&&(o=void 0);else{let s=i;if("additionalProperties"in i&&i.additionalProperties===!1){let{additionalProperties:a,...c}=i;s=c}else o=void 0;n.push(s)}}),n.length?{allOf:n,...o}:void 0}function Lb(e,t){let r=typeof e.value;return r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:r==="bigint"?"integer":r,enum:[e.value]}:{type:r==="bigint"?"integer":r,const:e.value}}var zm,Ht={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:()=>(zm===void 0&&(zm=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),zm),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 _l(e,t){let r={type:"string"};if(e.checks)for(let o of e.checks)switch(o.kind){case"min":ue(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,o.value):o.value,o.message,t);break;case"max":ue(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,o.value):o.value,o.message,t);break;case"email":switch(t.emailStrategy){case"format:email":Jt(r,"email",o.message,t);break;case"format:idn-email":Jt(r,"idn-email",o.message,t);break;case"pattern:zod":dt(r,Ht.email,o.message,t);break}break;case"url":Jt(r,"uri",o.message,t);break;case"uuid":Jt(r,"uuid",o.message,t);break;case"regex":dt(r,o.regex,o.message,t);break;case"cuid":dt(r,Ht.cuid,o.message,t);break;case"cuid2":dt(r,Ht.cuid2,o.message,t);break;case"startsWith":dt(r,RegExp(`^${Em(o.value,t)}`),o.message,t);break;case"endsWith":dt(r,RegExp(`${Em(o.value,t)}$`),o.message,t);break;case"datetime":Jt(r,"date-time",o.message,t);break;case"date":Jt(r,"date",o.message,t);break;case"time":Jt(r,"time",o.message,t);break;case"duration":Jt(r,"duration",o.message,t);break;case"length":ue(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,o.value):o.value,o.message,t),ue(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,o.value):o.value,o.message,t);break;case"includes":{dt(r,RegExp(Em(o.value,t)),o.message,t);break}case"ip":{o.version!=="v6"&&Jt(r,"ipv4",o.message,t),o.version!=="v4"&&Jt(r,"ipv6",o.message,t);break}case"base64url":dt(r,Ht.base64url,o.message,t);break;case"jwt":dt(r,Ht.jwt,o.message,t);break;case"cidr":{o.version!=="v6"&&dt(r,Ht.ipv4Cidr,o.message,t),o.version!=="v4"&&dt(r,Ht.ipv6Cidr,o.message,t);break}case"emoji":dt(r,Ht.emoji(),o.message,t);break;case"ulid":{dt(r,Ht.ulid,o.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{Jt(r,"binary",o.message,t);break}case"contentEncoding:base64":{ue(r,"contentEncoding","base64",o.message,t);break}case"pattern:zod":{dt(r,Ht.base64,o.message,t);break}}break}case"nanoid":dt(r,Ht.nanoid,o.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return r}function Em(e,t){return t.patternStrategy==="escape"?VI(e):e}var ZI=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function VI(e){let t="";for(let r=0;r<e.length;r++)ZI.has(e[r])||(t+="\\"),t+=e[r];return t}function Jt(e,t,r,o){e.format||e.anyOf?.some(n=>n.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&o.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...r&&o.errorMessages&&{errorMessage:{format:r}}})):ue(e,"format",t,r,o)}function dt(e,t,r,o){e.pattern||e.allOf?.some(n=>n.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&o.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:Fb(t,o),...r&&o.errorMessages&&{errorMessage:{pattern:r}}})):ue(e,"pattern",Fb(t,o),r,o)}function Fb(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")},o=r.i?e.source.toLowerCase():e.source,n="",i=!1,s=!1,a=!1;for(let c=0;c<o.length;c++){if(i){n+=o[c],i=!1;continue}if(r.i){if(s){if(o[c].match(/[a-z]/)){a?(n+=o[c],n+=`${o[c-2]}-${o[c]}`.toUpperCase(),a=!1):o[c+1]==="-"&&o[c+2]?.match(/[a-z]/)?(n+=o[c],a=!0):n+=`${o[c]}${o[c].toUpperCase()}`;continue}}else if(o[c].match(/[a-z]/)){n+=`[${o[c]}${o[c].toUpperCase()}]`;continue}}if(r.m){if(o[c]==="^"){n+=`(^|(?<=[\r
45
45
  ]))`;continue}else if(o[c]==="$"){n+=`($|(?=[\r
46
46
  ]))`;continue}}if(r.s&&o[c]==="."){n+=s?`${o[c]}\r
47
47
  `:`[${o[c]}\r
48
- ]`;continue}n+=o[c],o[c]==="\\"?i=!0:s&&o[c]==="]"?s=!1:!s&&o[c]==="["&&(s=!0)}try{new RegExp(n)}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 n}function vl(e,t){if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&e.keyType?._def.typeName===z.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((o,n)=>({...o,[n]:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",n]})??qe(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let r={type:"object",additionalProperties:G(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:o,...n}=gl(e.keyType._def,t);return{...r,propertyNames:n}}else{if(e.keyType?._def.typeName===z.ZodEnum)return{...r,propertyNames:{enum:e.keyType._def.values}};if(e.keyType?._def.typeName===z.ZodBranded&&e.keyType._def.type._def.typeName===z.ZodString&&e.keyType._def.type._def.checks?.length){let{type:o,...n}=hl(e.keyType._def,t);return{...r,propertyNames:n}}}return r}function F$(e,t){if(t.mapStrategy==="record")return vl(e,t);let r=G(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||qe(t),o=G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||qe(t);return{type:"array",maxItems:125,items:{type:"array",items:[r,o],minItems:2,maxItems:2}}}function G$(e){let t=e.values,o=Object.keys(e.values).filter(i=>typeof t[t[i]]!="number").map(i=>t[i]),n=Array.from(new Set(o.map(i=>typeof i)));return{type:n.length===1?n[0]==="string"?"string":"number":["string","number"],enum:o}}function W$(e){return e.target==="openAi"?void 0:{not:qe({...e,currentPath:[...e.currentPath,"not"]})}}function K$(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var Cs={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function J$(e,t){if(t.target==="openApi3")return H$(e,t);let r=e.options instanceof Map?Array.from(e.options.values()):e.options;if(r.every(o=>o._def.typeName in Cs&&(!o._def.checks||!o._def.checks.length))){let o=r.reduce((n,i)=>{let s=Cs[i._def.typeName];return s&&!n.includes(s)?[...n,s]:n},[]);return{type:o.length>1?o:o[0]}}else if(r.every(o=>o._def.typeName==="ZodLiteral"&&!o.description)){let o=r.reduce((n,i)=>{let s=typeof i._def.value;switch(s){case"string":case"number":case"boolean":return[...n,s];case"bigint":return[...n,"integer"];case"object":if(i._def.value===null)return[...n,"null"];case"symbol":case"undefined":case"function":default:return n}},[]);if(o.length===r.length){let n=o.filter((i,s,a)=>a.indexOf(i)===s);return{type:n.length>1?n:n[0],enum:r.reduce((i,s)=>i.includes(s._def.value)?i:[...i,s._def.value],[])}}}else if(r.every(o=>o._def.typeName==="ZodEnum"))return{type:"string",enum:r.reduce((o,n)=>[...o,...n._def.values.filter(i=>!o.includes(i))],[])};return H$(e,t)}var H$=(e,t)=>{let r=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((o,n)=>G(o._def,{...t,currentPath:[...t.currentPath,"anyOf",`${n}`]})).filter(o=>!!o&&(!t.strictUnions||typeof o=="object"&&Object.keys(o).length>0));return r.length?{anyOf:r}:void 0};function B$(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:Cs[e.innerType._def.typeName],nullable:!0}:{type:[Cs[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){let o=G(e.innerType._def,{...t,currentPath:[...t.currentPath]});return o&&"$ref"in o?{allOf:[o],nullable:!0}:o&&{...o,nullable:!0}}let r=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return r&&{anyOf:[r,{type:"null"}]}}function Y$(e,t){let r={type:"number"};if(!e.checks)return r;for(let o of e.checks)switch(o.kind){case"int":r.type="integer",Sm(r,"type",o.message,t);break;case"min":t.target==="jsonSchema7"?o.inclusive?ue(r,"minimum",o.value,o.message,t):ue(r,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(r.exclusiveMinimum=!0),ue(r,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(r,"maximum",o.value,o.message,t):ue(r,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(r.exclusiveMaximum=!0),ue(r,"maximum",o.value,o.message,t));break;case"multipleOf":ue(r,"multipleOf",o.value,o.message,t);break}return r}function X$(e,t){let r=t.target==="openAi",o={type:"object",properties:{}},n=[],i=e.shape();for(let a in i){let c=i[a];if(c===void 0||c._def===void 0)continue;let u=AI(c);u&&r&&(c._def.typeName==="ZodOptional"&&(c=c._def.innerType),c.isNullable()||(c=c.nullable()),u=!1);let l=G(c._def,{...t,currentPath:[...t.currentPath,"properties",a],propertyPath:[...t.currentPath,"properties",a]});l!==void 0&&(o.properties[a]=l,u||n.push(a))}n.length&&(o.required=n);let s=CI(e,t);return s!==void 0&&(o.additionalProperties=s),o}function CI(e,t){if(e.catchall._def.typeName!=="ZodNever")return G(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 AI(e){try{return e.isOptional()}catch{return!0}}var Q$=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return G(e.innerType._def,t);let r=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return r?{anyOf:[{not:qe(t)},r]}:qe(t)};var eb=(e,t)=>{if(t.pipeStrategy==="input")return G(e.in._def,t);if(t.pipeStrategy==="output")return G(e.out._def,t);let r=G(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o=G(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",r?"1":"0"]});return{allOf:[r,o].filter(n=>n!==void 0)}};function tb(e,t){return G(e.type._def,t)}function rb(e,t){let o={type:"array",uniqueItems:!0,items:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&ue(o,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&ue(o,"maxItems",e.maxSize.value,e.maxSize.message,t),o}function nb(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((r,o)=>G(r._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((r,o)=>o===void 0?r:[...r,o],[]),additionalItems:G(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((r,o)=>G(r._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((r,o)=>o===void 0?r:[...r,o],[])}}function ob(e){return{not:qe(e)}}function ib(e){return qe(e)}var sb=(e,t)=>G(e.innerType._def,t);var ab=(e,t,r)=>{switch(t){case z.ZodString:return gl(e,r);case z.ZodNumber:return Y$(e,r);case z.ZodObject:return X$(e,r);case z.ZodBigInt:return C$(e,r);case z.ZodBoolean:return A$();case z.ZodDate:return Tm(e,r);case z.ZodUndefined:return ob(r);case z.ZodNull:return K$(r);case z.ZodArray:return R$(e,r);case z.ZodUnion:case z.ZodDiscriminatedUnion:return J$(e,r);case z.ZodIntersection:return Z$(e,r);case z.ZodTuple:return nb(e,r);case z.ZodRecord:return vl(e,r);case z.ZodLiteral:return L$(e,r);case z.ZodEnum:return U$(e);case z.ZodNativeEnum:return G$(e);case z.ZodNullable:return B$(e,r);case z.ZodOptional:return Q$(e,r);case z.ZodMap:return F$(e,r);case z.ZodSet:return rb(e,r);case z.ZodLazy:return()=>e.getter()._def;case z.ZodPromise:return tb(e,r);case z.ZodNaN:case z.ZodNever:return W$(r);case z.ZodEffects:return M$(e,r);case z.ZodAny:return qe(r);case z.ZodUnknown:return ib(r);case z.ZodDefault:return q$(e,r);case z.ZodBranded:return hl(e,r);case z.ZodReadonly:return sb(e,r);case z.ZodCatch:return D$(e,r);case z.ZodPipeline:return eb(e,r);case z.ZodFunction:case z.ZodVoid:case z.ZodSymbol:return;default:return(o=>{})(t)}};function G(e,t,r=!1){let o=t.seen.get(e);if(t.override){let a=t.override?.(e,t,o,r);if(a!==j$)return a}if(o&&!r){let a=DI(o,t);if(a!==void 0)return a}let n={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,n);let i=ab(e,e.typeName,t),s=typeof i=="function"?G(i(),t):i;if(s&&qI(e,t,s),t.postProcess){let a=t.postProcess(s,e,t);return n.jsonSchema=s,a}return n.jsonSchema=s,s}var DI=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:ml(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((r,o)=>t.currentPath[o]===r)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),qe(t)):t.$refStrategy==="seen"?qe(t):void 0}},qI=(e,t,r)=>(e.description&&(r.description=e.description,t.markdownDescription&&(r.markdownDescription=e.description)),r);var Em=(e,t)=>{let r=N$(t),o=typeof t=="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[u,l])=>({...c,[u]:G(l._def,{...r,currentPath:[...r.basePath,r.definitionPath,u]},!0)??qe(r)}),{}):void 0,n=typeof t=="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=G(e._def,n===void 0?r:{...r,currentPath:[...r.basePath,r.definitionPath,n]},!1)??qe(r),s=typeof t=="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;s!==void 0&&(i.title=s),r.flags.hasReferencedOpenAiAnyType&&(o||(o={}),o[r.openAiAnyTypeName]||(o[r.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:r.$refStrategy==="relative"?"1":[...r.basePath,r.definitionPath,r.openAiAnyTypeName].join("/")}}));let a=n===void 0?o?{...i,[r.definitionPath]:o}:i:{$ref:[...r.$refStrategy==="relative"?[]:r.basePath,r.definitionPath,n].join("/"),[r.definitionPath]:{...o,[n]:i}};return r.target==="jsonSchema7"?a.$schema="http://json-schema.org/draft-07/schema#":(r.target==="jsonSchema2019-09"||r.target==="openAi")&&(a.$schema="https://json-schema.org/draft/2019-09/schema#"),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."),a};function MI(e){return!e||e==="jsonSchema7"||e==="draft-7"?"draft-7":e==="jsonSchema2019-09"||e==="draft-2020-12"?"draft-2020-12":"draft-7"}function Im(e,t){return jt(e)?xo(e,{target:MI(t?.target),io:t?.pipeStrategy??"input"}):Em(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function jm(e){let r=Wr(e)?.method;if(!r)throw new Error("Schema is missing a method literal");let o=Ou(r);if(typeof o!="string")throw new Error("Schema method literal must be a string");return o}function Om(e,t){let r=Gr(e,t);if(!r.success)throw r.error;return r.data}var UI=6e4,_l=class{constructor(t){this._options=t,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(Bu,r=>{this._oncancel(r)}),this.setNotificationHandler(Xu,r=>{this._onprogress(r)}),this.setRequestHandler(Yu,r=>({})),this._taskStore=t?.taskStore,this._taskMessageQueue=t?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(Qu,async(r,o)=>{let n=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!n)throw new U(V.InvalidParams,"Failed to retrieve task: Task not found");return{...n}}),this.setRequestHandler(tl,async(r,o)=>{let n=async()=>{let i=r.params.taskId;if(this._taskMessageQueue){let a;for(;a=await this._taskMessageQueue.dequeue(i,o.sessionId);){if(a.type==="response"||a.type==="error"){let c=a.message,u=c.id,l=this._requestResolvers.get(u);if(l)if(this._requestResolvers.delete(u),a.type==="response")l(c);else{let d=c,h=new U(d.error.code,d.error.message,d.error.data);l(h)}else{let d=a.type==="response"?"Response":"Error";this._onerror(new Error(`${d} handler missing for request ${u}`))}continue}await this._transport?.send(a.message,{relatedRequestId:o.requestId})}}let s=await this._taskStore.getTask(i,o.sessionId);if(!s)throw new U(V.InvalidParams,`Task not found: ${i}`);if(!Hr(s.status))return await this._waitForTaskUpdate(i,o.signal),await n();if(Hr(s.status)){let a=await this._taskStore.getTaskResult(i,o.sessionId);return this._clearTaskQueue(i),{...a,_meta:{...a._meta,[Kr]:{taskId:i}}}}return await n()};return await n()}),this.setRequestHandler(rl,async(r,o)=>{try{let{tasks:n,nextCursor:i}=await this._taskStore.listTasks(r.params?.cursor,o.sessionId);return{tasks:n,nextCursor:i,_meta:{}}}catch(n){throw new U(V.InvalidParams,`Failed to list tasks: ${n instanceof Error?n.message:String(n)}`)}}),this.setRequestHandler(ol,async(r,o)=>{try{let n=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!n)throw new U(V.InvalidParams,`Task not found: ${r.params.taskId}`);if(Hr(n.status))throw new U(V.InvalidParams,`Cannot cancel task in terminal status: ${n.status}`);await this._taskStore.updateTaskStatus(r.params.taskId,"cancelled","Client cancelled task execution.",o.sessionId),this._clearTaskQueue(r.params.taskId);let i=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!i)throw new U(V.InvalidParams,`Task not found after cancellation: ${r.params.taskId}`);return{_meta:{},...i}}catch(n){throw n instanceof U?n:new U(V.InvalidRequest,`Failed to cancel task: ${n instanceof Error?n.message:String(n)}`)}}))}async _oncancel(t){if(!t.params.requestId)return;this._requestHandlerAbortControllers.get(t.params.requestId)?.abort(t.params.reason)}_setupTimeout(t,r,o,n,i=!1){this._timeoutInfo.set(t,{timeoutId:setTimeout(n,r),startTime:Date.now(),timeout:r,maxTotalTimeout:o,resetTimeoutOnProgress:i,onTimeout:n})}_resetTimeout(t){let r=this._timeoutInfo.get(t);if(!r)return!1;let o=Date.now()-r.startTime;if(r.maxTotalTimeout&&o>=r.maxTotalTimeout)throw this._timeoutInfo.delete(t),U.fromError(V.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:r.maxTotalTimeout,totalElapsed:o});return clearTimeout(r.timeoutId),r.timeoutId=setTimeout(r.onTimeout,r.timeout),!0}_cleanupTimeout(t){let r=this._timeoutInfo.get(t);r&&(clearTimeout(r.timeoutId),this._timeoutInfo.delete(t))}async connect(t){this._transport=t;let r=this.transport?.onclose;this._transport.onclose=()=>{r?.(),this._onclose()};let o=this.transport?.onerror;this._transport.onerror=i=>{o?.(i),this._onerror(i)};let n=this._transport?.onmessage;this._transport.onmessage=(i,s)=>{n?.(i,s),Ps(i)||y$(i)?this._onresponse(i):lm(i)?this._onrequest(i,s):_$(i)?this._onnotification(i):this._onerror(new Error(`Unknown message type: ${JSON.stringify(i)}`))},await this._transport.start()}_onclose(){let t=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();let r=U.fromError(V.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let o of t.values())o(r)}_onerror(t){this.onerror?.(t)}_onnotification(t){let r=this._notificationHandlers.get(t.method)??this.fallbackNotificationHandler;r!==void 0&&Promise.resolve().then(()=>r(t)).catch(o=>this._onerror(new Error(`Uncaught error in notification handler: ${o}`)))}_onrequest(t,r){let o=this._requestHandlers.get(t.method)??this.fallbackRequestHandler,n=this._transport,i=t.params?._meta?.[Kr]?.taskId;if(o===void 0){let l={jsonrpc:"2.0",id:t.id,error:{code:V.MethodNotFound,message:"Method not found"}};i&&this._taskMessageQueue?this._enqueueTaskMessage(i,{type:"error",message:l,timestamp:Date.now()},n?.sessionId).catch(d=>this._onerror(new Error(`Failed to enqueue error response: ${d}`))):n?.send(l).catch(d=>this._onerror(new Error(`Failed to send an error response: ${d}`)));return}let s=new AbortController;this._requestHandlerAbortControllers.set(t.id,s);let a=h$(t.params)?t.params.task:void 0,c=this._taskStore?this.requestTaskStore(t,n?.sessionId):void 0,u={signal:s.signal,sessionId:n?.sessionId,_meta:t.params?._meta,sendNotification:async l=>{let d={relatedRequestId:t.id};i&&(d.relatedTask={taskId:i}),await this.notification(l,d)},sendRequest:async(l,d,h)=>{let m={...h,relatedRequestId:t.id};i&&!m.relatedTask&&(m.relatedTask={taskId:i});let p=m.relatedTask?.taskId??i;return p&&c&&await c.updateTaskStatus(p,"input_required"),await this.request(l,d,m)},authInfo:r?.authInfo,requestId:t.id,requestInfo:r?.requestInfo,taskId:i,taskStore:c,taskRequestedTtl:a?.ttl,closeSSEStream:r?.closeSSEStream,closeStandaloneSSEStream:r?.closeStandaloneSSEStream};Promise.resolve().then(()=>{a&&this.assertTaskHandlerCapability(t.method)}).then(()=>o(t,u)).then(async l=>{if(s.signal.aborted)return;let d={result:l,jsonrpc:"2.0",id:t.id};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"response",message:d,timestamp:Date.now()},n?.sessionId):await n?.send(d)},async l=>{if(s.signal.aborted)return;let d={jsonrpc:"2.0",id:t.id,error:{code:Number.isSafeInteger(l.code)?l.code:V.InternalError,message:l.message??"Internal error",...l.data!==void 0&&{data:l.data}}};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"error",message:d,timestamp:Date.now()},n?.sessionId):await n?.send(d)}).catch(l=>this._onerror(new Error(`Failed to send response: ${l}`))).finally(()=>{this._requestHandlerAbortControllers.delete(t.id)})}_onprogress(t){let{progressToken:r,...o}=t.params,n=Number(r),i=this._progressHandlers.get(n);if(!i){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(t)}`));return}let s=this._responseHandlers.get(n),a=this._timeoutInfo.get(n);if(a&&s&&a.resetTimeoutOnProgress)try{this._resetTimeout(n)}catch(c){this._responseHandlers.delete(n),this._progressHandlers.delete(n),this._cleanupTimeout(n),s(c);return}i(o)}_onresponse(t){let r=Number(t.id),o=this._requestResolvers.get(r);if(o){if(this._requestResolvers.delete(r),Ps(t))o(t);else{let s=new U(t.error.code,t.error.message,t.error.data);o(s)}return}let n=this._responseHandlers.get(r);if(n===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(t)}`));return}this._responseHandlers.delete(r),this._cleanupTimeout(r);let i=!1;if(Ps(t)&&t.result&&typeof t.result=="object"){let s=t.result;if(s.task&&typeof s.task=="object"){let a=s.task;typeof a.taskId=="string"&&(i=!0,this._taskProgressTokens.set(a.taskId,r))}}if(i||this._progressHandlers.delete(r),Ps(t))n(t);else{let s=U.fromError(t.error.code,t.error.message,t.error.data);n(s)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(t,r,o){let{task:n}=o??{};if(!n){try{yield{type:"result",result:await this.request(t,r,o)}}catch(s){yield{type:"error",error:s instanceof U?s:new U(V.InternalError,String(s))}}return}let i;try{let s=await this.request(t,Io,o);if(s.task)i=s.task.taskId,yield{type:"taskCreated",task:s.task};else throw new U(V.InternalError,"Task creation did not return a task");for(;;){let a=await this.getTask({taskId:i},o);if(yield{type:"taskStatus",task:a},Hr(a.status)){a.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:i},r,o)}:a.status==="failed"?yield{type:"error",error:new U(V.InternalError,`Task ${i} failed`)}:a.status==="cancelled"&&(yield{type:"error",error:new U(V.InternalError,`Task ${i} was cancelled`)});return}if(a.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:i},r,o)};return}let c=a.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(u=>setTimeout(u,c)),o?.signal?.throwIfAborted()}}catch(s){yield{type:"error",error:s instanceof U?s:new U(V.InternalError,String(s))}}}request(t,r,o){let{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s,task:a,relatedTask:c}=o??{};return new Promise((u,l)=>{let d=w=>{l(w)};if(!this._transport){d(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(t.method),a&&this.assertTaskCapability(t.method)}catch(w){d(w);return}o?.signal?.throwIfAborted();let h=this._requestMessageId++,m={...t,jsonrpc:"2.0",id:h};o?.onprogress&&(this._progressHandlers.set(h,o.onprogress),m.params={...t.params,_meta:{...t.params?._meta||{},progressToken:h}}),a&&(m.params={...m.params,task:a}),c&&(m.params={...m.params,_meta:{...m.params?._meta||{},[Kr]:c}});let p=w=>{this._responseHandlers.delete(h),this._progressHandlers.delete(h),this._cleanupTimeout(h),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:h,reason:String(w)}},{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s}).catch(E=>this._onerror(new Error(`Failed to send cancellation: ${E}`)));let k=w instanceof U?w:new U(V.RequestTimeout,String(w));l(k)};this._responseHandlers.set(h,w=>{if(!o?.signal?.aborted){if(w instanceof Error)return l(w);try{let k=Gr(r,w.result);k.success?u(k.data):l(k.error)}catch(k){l(k)}}}),o?.signal?.addEventListener("abort",()=>{p(o?.signal?.reason)});let f=o?.timeout??UI,g=()=>p(U.fromError(V.RequestTimeout,"Request timed out",{timeout:f}));this._setupTimeout(h,f,o?.maxTotalTimeout,g,o?.resetTimeoutOnProgress??!1);let y=c?.taskId;if(y){let w=k=>{let E=this._responseHandlers.get(h);E?E(k):this._onerror(new Error(`Response handler missing for side-channeled request ${h}`))};this._requestResolvers.set(h,w),this._enqueueTaskMessage(y,{type:"request",message:m,timestamp:Date.now()}).catch(k=>{this._cleanupTimeout(h),l(k)})}else this._transport.send(m,{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s}).catch(w=>{this._cleanupTimeout(h),l(w)})})}async getTask(t,r){return this.request({method:"tasks/get",params:t},el,r)}async getTaskResult(t,r,o){return this.request({method:"tasks/result",params:t},r,o)}async listTasks(t,r){return this.request({method:"tasks/list",params:t},nl,r)}async cancelTask(t,r){return this.request({method:"tasks/cancel",params:t},w$,r)}async notification(t,r){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(t.method);let o=r?.relatedTask?.taskId;if(o){let a={...t,jsonrpc:"2.0",params:{...t.params,_meta:{...t.params?._meta||{},[Kr]:r.relatedTask}}};await this._enqueueTaskMessage(o,{type:"notification",message:a,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(t.method)&&!t.params&&!r?.relatedRequestId&&!r?.relatedTask){if(this._pendingDebouncedNotifications.has(t.method))return;this._pendingDebouncedNotifications.add(t.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(t.method),!this._transport)return;let a={...t,jsonrpc:"2.0"};r?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Kr]:r.relatedTask}}}),this._transport?.send(a,r).catch(c=>this._onerror(c))});return}let s={...t,jsonrpc:"2.0"};r?.relatedTask&&(s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[Kr]:r.relatedTask}}}),await this._transport.send(s,r)}setRequestHandler(t,r){let o=jm(t);this.assertRequestHandlerCapability(o),this._requestHandlers.set(o,(n,i)=>{let s=Om(t,n);return Promise.resolve(r(s,i))})}removeRequestHandler(t){this._requestHandlers.delete(t)}assertCanSetRequestHandler(t){if(this._requestHandlers.has(t))throw new Error(`A request handler for ${t} already exists, which would be overridden`)}setNotificationHandler(t,r){let o=jm(t);this._notificationHandlers.set(o,n=>{let i=Om(t,n);return Promise.resolve(r(i))})}removeNotificationHandler(t){this._notificationHandlers.delete(t)}_cleanupTaskProgressHandler(t){let r=this._taskProgressTokens.get(t);r!==void 0&&(this._progressHandlers.delete(r),this._taskProgressTokens.delete(t))}async _enqueueTaskMessage(t,r,o){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let n=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(t,r,o,n)}async _clearTaskQueue(t,r){if(this._taskMessageQueue){let o=await this._taskMessageQueue.dequeueAll(t,r);for(let n of o)if(n.type==="request"&&lm(n.message)){let i=n.message.id,s=this._requestResolvers.get(i);s?(s(new U(V.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(i)):this._onerror(new Error(`Resolver missing for request ${i} during task ${t} cleanup`))}}}async _waitForTaskUpdate(t,r){let o=this._options?.defaultTaskPollInterval??1e3;try{let n=await this._taskStore?.getTask(t);n?.pollInterval&&(o=n.pollInterval)}catch{}return new Promise((n,i)=>{if(r.aborted){i(new U(V.InvalidRequest,"Request cancelled"));return}let s=setTimeout(n,o);r.addEventListener("abort",()=>{clearTimeout(s),i(new U(V.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(t,r){let o=this._taskStore;if(!o)throw new Error("No task store configured");return{createTask:async n=>{if(!t)throw new Error("No request provided");return await o.createTask(n,t.id,{method:t.method,params:t.params},r)},getTask:async n=>{let i=await o.getTask(n,r);if(!i)throw new U(V.InvalidParams,"Failed to retrieve task: Task not found");return i},storeTaskResult:async(n,i,s)=>{await o.storeTaskResult(n,i,s,r);let a=await o.getTask(n,r);if(a){let c=Os.parse({method:"notifications/tasks/status",params:a});await this.notification(c),Hr(a.status)&&this._cleanupTaskProgressHandler(n)}},getTaskResult:n=>o.getTaskResult(n,r),updateTaskStatus:async(n,i,s)=>{let a=await o.getTask(n,r);if(!a)throw new U(V.InvalidParams,`Task "${n}" not found - it may have been cleaned up`);if(Hr(a.status))throw new U(V.InvalidParams,`Cannot update task "${n}" from terminal status "${a.status}" to "${i}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await o.updateTaskStatus(n,i,s,r);let c=await o.getTask(n,r);if(c){let u=Os.parse({method:"notifications/tasks/status",params:c});await this.notification(u),Hr(c.status)&&this._cleanupTaskProgressHandler(n)}},listTasks:n=>o.listTasks(n,r)}}};function cb(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function ub(e,t){let r={...e};for(let o in t){let n=o,i=t[n];if(i===void 0)continue;let s=r[n];cb(s)&&cb(i)?r[n]={...s,...i}:r[n]=i}return r}var uS=Vt(Ck(),1),lS=Vt(cS(),1);function xM(){let e=new uS.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return(0,lS.default)(e),e}var Od=class{constructor(t){this._ajv=t??xM()}getValidator(t){let r="$id"in t&&typeof t.$id=="string"?this._ajv.getSchema(t.$id)??this._ajv.compile(t):this._ajv.compile(t);return o=>r(o)?{valid:!0,data:o,errorMessage:void 0}:{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(r.errors)}}};var Nd=class{constructor(t){this._server=t}requestStream(t,r,o){return this._server.requestStream(t,r,o)}async getTask(t,r){return this._server.getTask({taskId:t},r)}async getTaskResult(t,r,o){return this._server.getTaskResult({taskId:t},r,o)}async listTasks(t,r){return this._server.listTasks(t?{cursor:t}:void 0,r)}async cancelTask(t,r){return this._server.cancelTask({taskId:t},r)}};function dS(e,t,r){if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw new Error(`${r} does not support task creation for tools/call (required for ${t})`);break;default:break}}function pS(e,t,r){if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw new Error(`${r} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw new Error(`${r} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}var Rd=class extends _l{constructor(t,r){super(r),this._serverInfo=t,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(Rs.options.map((o,n)=>[o,n])),this.isMessageIgnored=(o,n)=>{let i=this._loggingLevels.get(n);return i?this.LOG_LEVEL_SEVERITY.get(o)<this.LOG_LEVEL_SEVERITY.get(i):!1},this._capabilities=r?.capabilities??{},this._instructions=r?.instructions,this._jsonSchemaValidator=r?.jsonSchemaValidator??new Od,this.setRequestHandler(fm,o=>this._oninitialize(o)),this.setNotificationHandler(mm,()=>this.oninitialized?.()),this._capabilities.logging&&this.setRequestHandler(bm,async(o,n)=>{let i=n.sessionId||n.requestInfo?.headers["mcp-session-id"]||void 0,{level:s}=o.params,a=Rs.safeParse(s);return a.success&&this._loggingLevels.set(i,a.data),{}})}get experimental(){return this._experimental||(this._experimental={tasks:new Nd(this)}),this._experimental}registerCapabilities(t){if(this.transport)throw new Error("Cannot register capabilities after connecting to transport");this._capabilities=ub(this._capabilities,t)}setRequestHandler(t,r){let n=Wr(t)?.method;if(!n)throw new Error("Schema is missing a method literal");let i;if(jt(n)){let a=n;i=a._zod?.def?.value??a.value}else{let a=n;i=a._def?.value??a.value}if(typeof i!="string")throw new Error("Schema method literal must be a string");if(i==="tools/call"){let a=async(c,u)=>{let l=Gr(Oo,c);if(!l.success){let p=l.error instanceof Error?l.error.message:String(l.error);throw new U(V.InvalidParams,`Invalid tools/call request: ${p}`)}let{params:d}=l.data,h=await Promise.resolve(r(c,u));if(d.task){let p=Gr(Io,h);if(!p.success){let f=p.error instanceof Error?p.error.message:String(p.error);throw new U(V.InvalidParams,`Invalid task creation result: ${f}`)}return p.data}let m=Gr(dl,h);if(!m.success){let p=m.error instanceof Error?m.error.message:String(m.error);throw new U(V.InvalidParams,`Invalid tools/call result: ${p}`)}return m.data};return super.setRequestHandler(t,a)}return super.setRequestHandler(t,r)}assertCapabilityForMethod(t){switch(t){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw new Error(`Client does not support sampling (required for ${t})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw new Error(`Client does not support elicitation (required for ${t})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw new Error(`Client does not support listing roots (required for ${t})`);break;case"ping":break}}assertNotificationCapability(t){switch(t){case"notifications/message":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw new Error(`Server does not support notifying about resources (required for ${t})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw new Error(`Server does not support notifying of tool list changes (required for ${t})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw new Error(`Server does not support notifying of prompt list changes (required for ${t})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw new Error(`Client does not support URL elicitation (required for ${t})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(t){if(this._capabilities)switch(t){case"completion/complete":if(!this._capabilities.completions)throw new Error(`Server does not support completions (required for ${t})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw new Error(`Server does not support prompts (required for ${t})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw new Error(`Server does not support resources (required for ${t})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw new Error(`Server does not support tools (required for ${t})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw new Error(`Server does not support tasks capability (required for ${t})`);break;case"ping":case"initialize":break}}assertTaskCapability(t){pS(this._clientCapabilities?.tasks?.requests,t,"Client")}assertTaskHandlerCapability(t){this._capabilities&&dS(this._capabilities.tasks?.requests,t,"Server")}async _oninitialize(t){let r=t.params.protocolVersion;return this._clientCapabilities=t.params.capabilities,this._clientVersion=t.params.clientInfo,{protocolVersion:p$.includes(r)?r:cm,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"},Ju)}async createMessage(t,r){if((t.tools||t.toolChoice)&&!this._clientCapabilities?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let o=t.messages[t.messages.length-1],n=Array.isArray(o.content)?o.content:[o.content],i=n.some(u=>u.type==="tool_result"),s=t.messages.length>1?t.messages[t.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(n.some(u=>u.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!c)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let u=new Set(a.filter(d=>d.type==="tool_use").map(d=>d.id)),l=new Set(n.filter(d=>d.type==="tool_result").map(d=>d.toolUseId));if(u.size!==l.size||![...u].every(d=>l.has(d)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return t.tools?this.request({method:"sampling/createMessage",params:t},km,r):this.request({method:"sampling/createMessage",params:t},wm,r)}async elicitInput(t,r){switch(t.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support url elicitation.");let n=t;return this.request({method:"elicitation/create",params:n},pl,r)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw new Error("Client does not support form elicitation.");let n=t.mode==="form"?t:{...t,mode:"form"},i=await this.request({method:"elicitation/create",params:n},pl,r);if(i.action==="accept"&&i.content&&n.requestedSchema)try{let a=this._jsonSchemaValidator.getValidator(n.requestedSchema)(i.content);if(!a.valid)throw new U(V.InvalidParams,`Elicitation response content does not match requested schema: ${a.errorMessage}`)}catch(s){throw s instanceof U?s:new U(V.InternalError,`Error validating elicitation response: ${s instanceof Error?s.message:String(s)}`)}return i}}}createElicitationCompletionNotifier(t,r){if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:t}},r)}async listRoots(t,r){return this.request({method:"roots/list",params:t},xm,r)}async sendLoggingMessage(t,r){if(this._capabilities.logging&&!this.isMessageIgnored(t.level,r))return this.notification({method:"notifications/message",params:t})}async sendResourceUpdated(t){return this.notification({method:"notifications/resources/updated",params:t})}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 mS=Symbol.for("mcp.completable");function r_(e){return!!e&&typeof e=="object"&&mS in e}function hS(e){return e[mS]?.complete}var fS;(function(e){e.Completable="McpCompletable"})(fS||(fS={}));var SM=/^[A-Za-z0-9._-]{1,128}$/;function TM(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"),e.includes(",")&&t.push("Tool name contains commas, which may cause parsing issues"),(e.startsWith("-")||e.endsWith("-"))&&t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts"),(e.startsWith(".")||e.endsWith("."))&&t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts"),!SM.test(e)){let r=e.split("").filter(o=>!/[A-Za-z0-9._-]/.test(o)).filter((o,n,i)=>i.indexOf(o)===n);return t.push(`Tool name contains invalid characters: ${r.map(o=>`"${o}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function PM(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 n_(e){let t=TM(e);return PM(e,t.warnings),t.isValid}var Cd=class{constructor(t){this._mcpServer=t}registerToolTask(t,r,o){let n={taskSupport:"required",...r.execution};if(n.taskSupport==="forbidden")throw new Error(`Cannot register task-based tool '${t}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(t,r.title,r.description,r.inputSchema,r.outputSchema,r.annotations,n,r._meta,o)}};var Ad=class{constructor(t,r){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new Rd(t,r)}get experimental(){return this._experimental||(this._experimental={tasks:new Cd(this)}),this._experimental}async connect(t){return await this.server.connect(t)}async close(){await this.server.close()}setToolRequestHandlers(){this._toolHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(ll)),this.server.assertCanSetRequestHandler(dn(Oo)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(ll,()=>({tools:Object.entries(this._registeredTools).filter(([,t])=>t.enabled).map(([t,r])=>{let o={name:t,title:r.title,description:r.description,inputSchema:(()=>{let n=So(r.inputSchema);return n?Im(n,{strictUnions:!0,pipeStrategy:"input"}):zM})(),annotations:r.annotations,execution:r.execution,_meta:r._meta};if(r.outputSchema){let n=So(r.outputSchema);n&&(o.outputSchema=Im(n,{strictUnions:!0,pipeStrategy:"output"}))}return o})})),this.server.setRequestHandler(Oo,async(t,r)=>{try{let o=this._registeredTools[t.params.name];if(!o)throw new U(V.InvalidParams,`Tool ${t.params.name} not found`);if(!o.enabled)throw new U(V.InvalidParams,`Tool ${t.params.name} disabled`);let n=!!t.params.task,i=o.execution?.taskSupport,s="createTask"in o.handler;if((i==="required"||i==="optional")&&!s)throw new U(V.InternalError,`Tool ${t.params.name} has taskSupport '${i}' but was not registered with registerToolTask`);if(i==="required"&&!n)throw new U(V.MethodNotFound,`Tool ${t.params.name} requires task augmentation (taskSupport: 'required')`);if(i==="optional"&&!n&&s)return await this.handleAutomaticTaskPolling(o,t,r);let a=await this.validateToolInput(o,t.params.arguments,t.params.name),c=await this.executeToolHandler(o,a,r);return n||await this.validateToolOutput(o,c,t.params.name),c}catch(o){if(o instanceof U&&o.code===V.UrlElicitationRequired)throw o;return this.createToolError(o instanceof Error?o.message:String(o))}}),this._toolHandlersInitialized=!0)}createToolError(t){return{content:[{type:"text",text:t}],isError:!0}}async validateToolInput(t,r,o){if(!t.inputSchema)return;let i=So(t.inputSchema)??t.inputSchema,s=await Iu(i,r);if(!s.success){let a="error"in s?s.error:"Unknown error",c=ju(a);throw new U(V.InvalidParams,`Input validation error: Invalid arguments for tool ${o}: ${c}`)}return s.data}async validateToolOutput(t,r,o){if(!t.outputSchema||!("content"in r)||r.isError)return;if(!r.structuredContent)throw new U(V.InvalidParams,`Output validation error: Tool ${o} has an output schema but no structured content was provided`);let n=So(t.outputSchema),i=await Iu(n,r.structuredContent);if(!i.success){let s="error"in i?i.error:"Unknown error",a=ju(s);throw new U(V.InvalidParams,`Output validation error: Invalid structured content for tool ${o}: ${a}`)}}async executeToolHandler(t,r,o){let n=t.handler;if("createTask"in n){if(!o.taskStore)throw new Error("No task store provided.");let s={...o,taskStore:o.taskStore};if(t.inputSchema){let a=n;return await Promise.resolve(a.createTask(r,s))}else{let a=n;return await Promise.resolve(a.createTask(s))}}if(t.inputSchema){let s=n;return await Promise.resolve(s(r,o))}else{let s=n;return await Promise.resolve(s(o))}}async handleAutomaticTaskPolling(t,r,o){if(!o.taskStore)throw new Error("No task store provided for task-capable tool.");let n=await this.validateToolInput(t,r.params.arguments,r.params.name),i=t.handler,s={...o,taskStore:o.taskStore},a=n?await Promise.resolve(i.createTask(n,s)):await Promise.resolve(i.createTask(s)),c=a.task.taskId,u=a.task,l=u.pollInterval??5e3;for(;u.status!=="completed"&&u.status!=="failed"&&u.status!=="cancelled";){await new Promise(h=>setTimeout(h,l));let d=await o.taskStore.getTask(c);if(!d)throw new U(V.InternalError,`Task ${c} not found during polling`);u=d}return await o.taskStore.getTaskResult(c)}setCompletionRequestHandler(){this._completionHandlerInitialized||(this.server.assertCanSetRequestHandler(dn(fl)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(fl,async t=>{switch(t.params.ref.type){case"ref/prompt":return z$(t),this.handlePromptCompletion(t,t.params.ref);case"ref/resource":return E$(t),this.handleResourceCompletion(t,t.params.ref);default:throw new U(V.InvalidParams,`Invalid completion reference: ${t.params.ref}`)}}),this._completionHandlerInitialized=!0)}async handlePromptCompletion(t,r){let o=this._registeredPrompts[r.name];if(!o)throw new U(V.InvalidParams,`Prompt ${r.name} not found`);if(!o.enabled)throw new U(V.InvalidParams,`Prompt ${r.name} disabled`);if(!o.argsSchema)return Ma;let i=Wr(o.argsSchema)?.[t.params.argument.name];if(!r_(i))return Ma;let s=hS(i);if(!s)return Ma;let a=await s(t.params.argument.value,t.params.context);return vS(a)}async handleResourceCompletion(t,r){let o=Object.values(this._registeredResourceTemplates).find(s=>s.resourceTemplate.uriTemplate.toString()===r.uri);if(!o){if(this._registeredResources[r.uri])return Ma;throw new U(V.InvalidParams,`Resource template ${t.params.ref.uri} not found`)}let n=o.resourceTemplate.completeCallback(t.params.argument.name);if(!n)return Ma;let i=await n(t.params.argument.value,t.params.context);return vS(i)}setResourceRequestHandlers(){this._resourceHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(il)),this.server.assertCanSetRequestHandler(dn(sl)),this.server.assertCanSetRequestHandler(dn(al)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(il,async(t,r)=>{let o=Object.entries(this._registeredResources).filter(([i,s])=>s.enabled).map(([i,s])=>({uri:i,name:s.name,...s.metadata})),n=[];for(let i of Object.values(this._registeredResourceTemplates)){if(!i.resourceTemplate.listCallback)continue;let s=await i.resourceTemplate.listCallback(r);for(let a of s.resources)n.push({...i.metadata,...a})}return{resources:[...o,...n]}}),this.server.setRequestHandler(sl,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([r,o])=>({name:r,uriTemplate:o.resourceTemplate.uriTemplate.toString(),...o.metadata}))})),this.server.setRequestHandler(al,async(t,r)=>{let o=new URL(t.params.uri),n=this._registeredResources[o.toString()];if(n){if(!n.enabled)throw new U(V.InvalidParams,`Resource ${o} disabled`);return n.readCallback(o,r)}for(let i of Object.values(this._registeredResourceTemplates)){let s=i.resourceTemplate.uriTemplate.match(o.toString());if(s)return i.readCallback(o,s,r)}throw new U(V.InvalidParams,`Resource ${o} not found`)}),this._resourceHandlersInitialized=!0)}setPromptRequestHandlers(){this._promptHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(cl)),this.server.assertCanSetRequestHandler(dn(ul)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(cl,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,t])=>t.enabled).map(([t,r])=>({name:t,title:r.title,description:r.description,arguments:r.argsSchema?IM(r.argsSchema):void 0}))})),this.server.setRequestHandler(ul,async(t,r)=>{let o=this._registeredPrompts[t.params.name];if(!o)throw new U(V.InvalidParams,`Prompt ${t.params.name} not found`);if(!o.enabled)throw new U(V.InvalidParams,`Prompt ${t.params.name} disabled`);if(o.argsSchema){let n=So(o.argsSchema),i=await Iu(n,t.params.arguments);if(!i.success){let c="error"in i?i.error:"Unknown error",u=ju(c);throw new U(V.InvalidParams,`Invalid arguments for prompt ${t.params.name}: ${u}`)}let s=i.data,a=o.callback;return await Promise.resolve(a(s,r))}else{let n=o.callback;return await Promise.resolve(n(r))}}),this._promptHandlersInitialized=!0)}resource(t,r,...o){let n;typeof o[0]=="object"&&(n=o.shift());let i=o[0];if(typeof r=="string"){if(this._registeredResources[r])throw new Error(`Resource ${r} is already registered`);let s=this._createRegisteredResource(t,void 0,r,n,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),s}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let s=this._createRegisteredResourceTemplate(t,void 0,r,n,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),s}}registerResource(t,r,o,n){if(typeof r=="string"){if(this._registeredResources[r])throw new Error(`Resource ${r} is already registered`);let i=this._createRegisteredResource(t,o.title,r,o,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let i=this._createRegisteredResourceTemplate(t,o.title,r,o,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}_createRegisteredResource(t,r,o,n,i){let s={name:t,title:r,metadata:n,readCallback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({uri:null}),update:a=>{typeof a.uri<"u"&&a.uri!==o&&(delete this._registeredResources[o],a.uri&&(this._registeredResources[a.uri]=s)),typeof a.name<"u"&&(s.name=a.name),typeof a.title<"u"&&(s.title=a.title),typeof a.metadata<"u"&&(s.metadata=a.metadata),typeof a.callback<"u"&&(s.readCallback=a.callback),typeof a.enabled<"u"&&(s.enabled=a.enabled),this.sendResourceListChanged()}};return this._registeredResources[o]=s,s}_createRegisteredResourceTemplate(t,r,o,n,i){let s={resourceTemplate:o,title:r,metadata:n,readCallback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({name:null}),update:u=>{typeof u.name<"u"&&u.name!==t&&(delete this._registeredResourceTemplates[t],u.name&&(this._registeredResourceTemplates[u.name]=s)),typeof u.title<"u"&&(s.title=u.title),typeof u.template<"u"&&(s.resourceTemplate=u.template),typeof u.metadata<"u"&&(s.metadata=u.metadata),typeof u.callback<"u"&&(s.readCallback=u.callback),typeof u.enabled<"u"&&(s.enabled=u.enabled),this.sendResourceListChanged()}};this._registeredResourceTemplates[t]=s;let a=o.uriTemplate.variableNames;return Array.isArray(a)&&a.some(u=>!!o.completeCallback(u))&&this.setCompletionRequestHandler(),s}_createRegisteredPrompt(t,r,o,n,i){let s={title:r,description:o,argsSchema:n===void 0?void 0:Tn(n),callback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({name:null}),update:a=>{typeof a.name<"u"&&a.name!==t&&(delete this._registeredPrompts[t],a.name&&(this._registeredPrompts[a.name]=s)),typeof a.title<"u"&&(s.title=a.title),typeof a.description<"u"&&(s.description=a.description),typeof a.argsSchema<"u"&&(s.argsSchema=Tn(a.argsSchema)),typeof a.callback<"u"&&(s.callback=a.callback),typeof a.enabled<"u"&&(s.enabled=a.enabled),this.sendPromptListChanged()}};return this._registeredPrompts[t]=s,n&&Object.values(n).some(c=>{let u=c instanceof St?c._def?.innerType:c;return r_(u)})&&this.setCompletionRequestHandler(),s}_createRegisteredTool(t,r,o,n,i,s,a,c,u){n_(t);let l={title:r,description:o,inputSchema:gS(n),outputSchema:gS(i),annotations:s,execution:a,_meta:c,handler:u,enabled:!0,disable:()=>l.update({enabled:!1}),enable:()=>l.update({enabled:!0}),remove:()=>l.update({name:null}),update:d=>{typeof d.name<"u"&&d.name!==t&&(typeof d.name=="string"&&n_(d.name),delete this._registeredTools[t],d.name&&(this._registeredTools[d.name]=l)),typeof d.title<"u"&&(l.title=d.title),typeof d.description<"u"&&(l.description=d.description),typeof d.paramsSchema<"u"&&(l.inputSchema=Tn(d.paramsSchema)),typeof d.outputSchema<"u"&&(l.outputSchema=Tn(d.outputSchema)),typeof d.callback<"u"&&(l.handler=d.callback),typeof d.annotations<"u"&&(l.annotations=d.annotations),typeof d._meta<"u"&&(l._meta=d._meta),typeof d.enabled<"u"&&(l.enabled=d.enabled),this.sendToolListChanged()}};return this._registeredTools[t]=l,this.setToolRequestHandlers(),this.sendToolListChanged(),l}tool(t,...r){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let o,n,i,s;if(typeof r[0]=="string"&&(o=r.shift()),r.length>1){let c=r[0];o_(c)?(n=r.shift(),r.length>1&&typeof r[0]=="object"&&r[0]!==null&&!o_(r[0])&&(s=r.shift())):typeof c=="object"&&c!==null&&(s=r.shift())}let a=r[0];return this._createRegisteredTool(t,void 0,o,n,i,s,{taskSupport:"forbidden"},void 0,a)}registerTool(t,r,o){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let{title:n,description:i,inputSchema:s,outputSchema:a,annotations:c,_meta:u}=r;return this._createRegisteredTool(t,n,i,s,a,c,{taskSupport:"forbidden"},u,o)}prompt(t,...r){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let o;typeof r[0]=="string"&&(o=r.shift());let n;r.length>1&&(n=r.shift());let i=r[0],s=this._createRegisteredPrompt(t,void 0,o,n,i);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}registerPrompt(t,r,o){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let{title:n,description:i,argsSchema:s}=r,a=this._createRegisteredPrompt(t,n,i,s,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),a}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(t,r){return this.server.sendLoggingMessage(t,r)}sendResourceListChanged(){this.isConnected()&&this.server.sendResourceListChanged()}sendToolListChanged(){this.isConnected()&&this.server.sendToolListChanged()}sendPromptListChanged(){this.isConnected()&&this.server.sendPromptListChanged()}};var zM={type:"object",properties:{}};function _S(e){return e!==null&&typeof e=="object"&&"parse"in e&&typeof e.parse=="function"&&"safeParse"in e&&typeof e.safeParse=="function"}function EM(e){return"_def"in e||"_zod"in e||_S(e)}function o_(e){return typeof e!="object"||e===null||EM(e)?!1:Object.keys(e).length===0?!0:Object.values(e).some(_S)}function gS(e){if(e)return o_(e)?Tn(e):e}function IM(e){let t=Wr(e);return t?Object.entries(t).map(([r,o])=>{let n=Ty(o),i=Py(o);return{name:r,description:n,required:!i}}):[]}function dn(e){let r=Wr(e)?.method;if(!r)throw new Error("Schema is missing a method literal");let o=Ou(r);if(typeof o=="string")return o;throw new Error("Schema method literal must be a string")}function vS(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var Ma={completion:{values:[],hasMore:!1}};var i_=Vt(require("node:process"),1);var Dd=class{append(t){this._buffer=this._buffer?Buffer.concat([this._buffer,t]):t}readMessage(){if(!this._buffer)return null;let t=this._buffer.indexOf(`
49
- `);if(t===-1)return null;let r=this._buffer.toString("utf8",0,t).replace(/\r$/,"");return this._buffer=this._buffer.subarray(t+1),jM(r)}clear(){this._buffer=void 0}};function jM(e){return $$.parse(JSON.parse(e))}function yS(e){return JSON.stringify(e)+`
50
- `}var qd=class{constructor(t=i_.default.stdin,r=i_.default.stdout){this._stdin=t,this._stdout=r,this._readBuffer=new Dd,this._started=!1,this._ondata=o=>{this._readBuffer.append(o),this.processReadBuffer()},this._onerror=o=>{this.onerror?.(o)}}async start(){if(this._started)throw new 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(){for(;;)try{let t=this._readBuffer.readMessage();if(t===null)break;this.onmessage?.(t)}catch(t){this.onerror?.(t)}}async close(){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(t){return new Promise(r=>{let o=yS(t);this._stdout.write(o)?r():this._stdout.once("drain",r)})}};var $S="2.4.0";var s_={name:"Vantage Cloud Costs Helper",version:$S};async function bS(e,t,r,o,n){t["User-Agent"]=`vantage-mcp-server/${s_.version}`;let i=new URL(n,e);o==="GET"?Object.entries(r).forEach(([u,l])=>{l!=null&&i.searchParams.append(u,Array.isArray(l)?l.join(","):String(l))}):t["Content-Type"]="application/json";let s={method:o,headers:t,body:o!=="GET"?JSON.stringify(r):void 0},a=await fetch(i.toString(),s);if(!a.ok){let u=await a.text();try{let l=JSON.parse(u);if(Array.isArray(l.errors))return{errors:l.errors,ok:!1}}catch{}return{errors:[{message:"Vantage API request failed",status:a.status,endpoint:n,details:u}],ok:!1}}return{data:await a.json(),ok:!0}}var R=class{constructor(t){this.exception=t}};var a_=new Map;function C(e){let t=(r,o)=>{r.tool(e.name,e.description,e.args,{readOnlyHint:e.annotations.readOnly??!1,openWorldHint:e.annotations.openWorld??!1,destructiveHint:e.annotations.destructive??!0},async n=>{try{let i=await e.execute(n,o());return{content:[{type:"text",text:JSON.stringify(i,null,2)}],isError:!1}}catch(i){if(i instanceof R)return{content:[{type:"text",text:JSON.stringify(i.exception,null,2)}],isError:!0};throw i}})};if(a_.has(e.name))throw new Error(`Tool ${e.name} is already registered`);return a_.set(e.name,t),e}function wS(e,t){for(let r of a_.values())r(e,t)}var OM="Invalid date input, must be YYYY-MM-DD format and a reasonable date.";function NM(e){let t="2030-01-01",r="2010-01-01";if(!e||e===""||typeof e!="string"||e<r||e>t)return!1;let o=Date.parse(e);return!(Number.isNaN(o)||o<=Date.parse(r)||o>=Date.parse(t))}function be(e){return v.string().refine(NM,{error:OM}).describe(e)}var RM=`
48
+ ]`;continue}n+=o[c],o[c]==="\\"?i=!0:s&&o[c]==="]"?s=!1:!s&&o[c]==="["&&(s=!0)}try{new RegExp(n)}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 n}function yl(e,t){if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&e.keyType?._def.typeName===z.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((o,n)=>({...o,[n]:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",n]})??qe(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};let r={type:"object",additionalProperties:G(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:o,...n}=_l(e.keyType._def,t);return{...r,propertyNames:n}}else{if(e.keyType?._def.typeName===z.ZodEnum)return{...r,propertyNames:{enum:e.keyType._def.values}};if(e.keyType?._def.typeName===z.ZodBranded&&e.keyType._def.type._def.typeName===z.ZodString&&e.keyType._def.type._def.checks?.length){let{type:o,...n}=vl(e.keyType._def,t);return{...r,propertyNames:n}}}return r}function Gb(e,t){if(t.mapStrategy==="record")return yl(e,t);let r=G(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||qe(t),o=G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||qe(t);return{type:"array",maxItems:125,items:{type:"array",items:[r,o],minItems:2,maxItems:2}}}function Wb(e){let t=e.values,o=Object.keys(e.values).filter(i=>typeof t[t[i]]!="number").map(i=>t[i]),n=Array.from(new Set(o.map(i=>typeof i)));return{type:n.length===1?n[0]==="string"?"string":"number":["string","number"],enum:o}}function Kb(e){return e.target==="openAi"?void 0:{not:qe({...e,currentPath:[...e.currentPath,"not"]})}}function Hb(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}var Ds={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function Bb(e,t){if(t.target==="openApi3")return Jb(e,t);let r=e.options instanceof Map?Array.from(e.options.values()):e.options;if(r.every(o=>o._def.typeName in Ds&&(!o._def.checks||!o._def.checks.length))){let o=r.reduce((n,i)=>{let s=Ds[i._def.typeName];return s&&!n.includes(s)?[...n,s]:n},[]);return{type:o.length>1?o:o[0]}}else if(r.every(o=>o._def.typeName==="ZodLiteral"&&!o.description)){let o=r.reduce((n,i)=>{let s=typeof i._def.value;switch(s){case"string":case"number":case"boolean":return[...n,s];case"bigint":return[...n,"integer"];case"object":if(i._def.value===null)return[...n,"null"];case"symbol":case"undefined":case"function":default:return n}},[]);if(o.length===r.length){let n=o.filter((i,s,a)=>a.indexOf(i)===s);return{type:n.length>1?n:n[0],enum:r.reduce((i,s)=>i.includes(s._def.value)?i:[...i,s._def.value],[])}}}else if(r.every(o=>o._def.typeName==="ZodEnum"))return{type:"string",enum:r.reduce((o,n)=>[...o,...n._def.values.filter(i=>!o.includes(i))],[])};return Jb(e,t)}var Jb=(e,t)=>{let r=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((o,n)=>G(o._def,{...t,currentPath:[...t.currentPath,"anyOf",`${n}`]})).filter(o=>!!o&&(!t.strictUnions||typeof o=="object"&&Object.keys(o).length>0));return r.length?{anyOf:r}:void 0};function Yb(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:Ds[e.innerType._def.typeName],nullable:!0}:{type:[Ds[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){let o=G(e.innerType._def,{...t,currentPath:[...t.currentPath]});return o&&"$ref"in o?{allOf:[o],nullable:!0}:o&&{...o,nullable:!0}}let r=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return r&&{anyOf:[r,{type:"null"}]}}function Xb(e,t){let r={type:"number"};if(!e.checks)return r;for(let o of e.checks)switch(o.kind){case"int":r.type="integer",Tm(r,"type",o.message,t);break;case"min":t.target==="jsonSchema7"?o.inclusive?ue(r,"minimum",o.value,o.message,t):ue(r,"exclusiveMinimum",o.value,o.message,t):(o.inclusive||(r.exclusiveMinimum=!0),ue(r,"minimum",o.value,o.message,t));break;case"max":t.target==="jsonSchema7"?o.inclusive?ue(r,"maximum",o.value,o.message,t):ue(r,"exclusiveMaximum",o.value,o.message,t):(o.inclusive||(r.exclusiveMaximum=!0),ue(r,"maximum",o.value,o.message,t));break;case"multipleOf":ue(r,"multipleOf",o.value,o.message,t);break}return r}function Qb(e,t){let r=t.target==="openAi",o={type:"object",properties:{}},n=[],i=e.shape();for(let a in i){let c=i[a];if(c===void 0||c._def===void 0)continue;let u=FI(c);u&&r&&(c._def.typeName==="ZodOptional"&&(c=c._def.innerType),c.isNullable()||(c=c.nullable()),u=!1);let l=G(c._def,{...t,currentPath:[...t.currentPath,"properties",a],propertyPath:[...t.currentPath,"properties",a]});l!==void 0&&(o.properties[a]=l,u||n.push(a))}n.length&&(o.required=n);let s=LI(e,t);return s!==void 0&&(o.additionalProperties=s),o}function LI(e,t){if(e.catchall._def.typeName!=="ZodNever")return G(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 FI(e){try{return e.isOptional()}catch{return!0}}var e$=(e,t)=>{if(t.currentPath.toString()===t.propertyPath?.toString())return G(e.innerType._def,t);let r=G(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return r?{anyOf:[{not:qe(t)},r]}:qe(t)};var t$=(e,t)=>{if(t.pipeStrategy==="input")return G(e.in._def,t);if(t.pipeStrategy==="output")return G(e.out._def,t);let r=G(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o=G(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",r?"1":"0"]});return{allOf:[r,o].filter(n=>n!==void 0)}};function r$(e,t){return G(e.type._def,t)}function n$(e,t){let o={type:"array",uniqueItems:!0,items:G(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&ue(o,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&ue(o,"maxItems",e.maxSize.value,e.maxSize.message,t),o}function o$(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((r,o)=>G(r._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((r,o)=>o===void 0?r:[...r,o],[]),additionalItems:G(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((r,o)=>G(r._def,{...t,currentPath:[...t.currentPath,"items",`${o}`]})).reduce((r,o)=>o===void 0?r:[...r,o],[])}}function i$(e){return{not:qe(e)}}function s$(e){return qe(e)}var a$=(e,t)=>G(e.innerType._def,t);var c$=(e,t,r)=>{switch(t){case z.ZodString:return _l(e,r);case z.ZodNumber:return Xb(e,r);case z.ZodObject:return Qb(e,r);case z.ZodBigInt:return Ab(e,r);case z.ZodBoolean:return Db();case z.ZodDate:return Pm(e,r);case z.ZodUndefined:return i$(r);case z.ZodNull:return Hb(r);case z.ZodArray:return Cb(e,r);case z.ZodUnion:case z.ZodDiscriminatedUnion:return Bb(e,r);case z.ZodIntersection:return Vb(e,r);case z.ZodTuple:return o$(e,r);case z.ZodRecord:return yl(e,r);case z.ZodLiteral:return Lb(e,r);case z.ZodEnum:return Zb(e);case z.ZodNativeEnum:return Wb(e);case z.ZodNullable:return Yb(e,r);case z.ZodOptional:return e$(e,r);case z.ZodMap:return Gb(e,r);case z.ZodSet:return n$(e,r);case z.ZodLazy:return()=>e.getter()._def;case z.ZodPromise:return r$(e,r);case z.ZodNaN:case z.ZodNever:return Kb(r);case z.ZodEffects:return Ub(e,r);case z.ZodAny:return qe(r);case z.ZodUnknown:return s$(r);case z.ZodDefault:return Mb(e,r);case z.ZodBranded:return vl(e,r);case z.ZodReadonly:return a$(e,r);case z.ZodCatch:return qb(e,r);case z.ZodPipeline:return t$(e,r);case z.ZodFunction:case z.ZodVoid:case z.ZodSymbol:return;default:return(o=>{})(t)}};function G(e,t,r=!1){let o=t.seen.get(e);if(t.override){let a=t.override?.(e,t,o,r);if(a!==jb)return a}if(o&&!r){let a=GI(o,t);if(a!==void 0)return a}let n={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,n);let i=c$(e,e.typeName,t),s=typeof i=="function"?G(i(),t):i;if(s&&WI(e,t,s),t.postProcess){let a=t.postProcess(s,e,t);return n.jsonSchema=s,a}return n.jsonSchema=s,s}var GI=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:gl(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((r,o)=>t.currentPath[o]===r)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),qe(t)):t.$refStrategy==="seen"?qe(t):void 0}},WI=(e,t,r)=>(e.description&&(r.description=e.description,t.markdownDescription&&(r.markdownDescription=e.description)),r);var Im=(e,t)=>{let r=Rb(t),o=typeof t=="object"&&t.definitions?Object.entries(t.definitions).reduce((c,[u,l])=>({...c,[u]:G(l._def,{...r,currentPath:[...r.basePath,r.definitionPath,u]},!0)??qe(r)}),{}):void 0,n=typeof t=="string"?t:t?.nameStrategy==="title"?void 0:t?.name,i=G(e._def,n===void 0?r:{...r,currentPath:[...r.basePath,r.definitionPath,n]},!1)??qe(r),s=typeof t=="object"&&t.name!==void 0&&t.nameStrategy==="title"?t.name:void 0;s!==void 0&&(i.title=s),r.flags.hasReferencedOpenAiAnyType&&(o||(o={}),o[r.openAiAnyTypeName]||(o[r.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:r.$refStrategy==="relative"?"1":[...r.basePath,r.definitionPath,r.openAiAnyTypeName].join("/")}}));let a=n===void 0?o?{...i,[r.definitionPath]:o}:i:{$ref:[...r.$refStrategy==="relative"?[]:r.basePath,r.definitionPath,n].join("/"),[r.definitionPath]:{...o,[n]:i}};return r.target==="jsonSchema7"?a.$schema="http://json-schema.org/draft-07/schema#":(r.target==="jsonSchema2019-09"||r.target==="openAi")&&(a.$schema="https://json-schema.org/draft/2019-09/schema#"),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."),a};function KI(e){return!e||e==="jsonSchema7"||e==="draft-7"?"draft-7":e==="jsonSchema2019-09"||e==="draft-2020-12"?"draft-2020-12":"draft-7"}function Om(e,t){return Nt(e)?xo(e,{target:KI(t?.target),io:t?.pipeStrategy??"input"}):Im(e,{strictUnions:t?.strictUnions??!0,pipeStrategy:t?.pipeStrategy??"input"})}function jm(e){let r=Wr(e)?.method;if(!r)throw new Error("Schema is missing a method literal");let o=Cu(r);if(typeof o!="string")throw new Error("Schema method literal must be a string");return o}function Nm(e,t){let r=Gr(e,t);if(!r.success)throw r.error;return r.data}var HI=6e4,bl=class{constructor(t){this._options=t,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(Qu,r=>{this._oncancel(r)}),this.setNotificationHandler(tl,r=>{this._onprogress(r)}),this.setRequestHandler(el,r=>({})),this._taskStore=t?.taskStore,this._taskMessageQueue=t?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(rl,async(r,o)=>{let n=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!n)throw new U(L.InvalidParams,"Failed to retrieve task: Task not found");return{...n}}),this.setRequestHandler(ol,async(r,o)=>{let n=async()=>{let i=r.params.taskId;if(this._taskMessageQueue){let a;for(;a=await this._taskMessageQueue.dequeue(i,o.sessionId);){if(a.type==="response"||a.type==="error"){let c=a.message,u=c.id,l=this._requestResolvers.get(u);if(l)if(this._requestResolvers.delete(u),a.type==="response")l(c);else{let d=c,h=new U(d.error.code,d.error.message,d.error.data);l(h)}else{let d=a.type==="response"?"Response":"Error";this._onerror(new Error(`${d} handler missing for request ${u}`))}continue}await this._transport?.send(a.message,{relatedRequestId:o.requestId})}}let s=await this._taskStore.getTask(i,o.sessionId);if(!s)throw new U(L.InvalidParams,`Task not found: ${i}`);if(!Hr(s.status))return await this._waitForTaskUpdate(i,o.signal),await n();if(Hr(s.status)){let a=await this._taskStore.getTaskResult(i,o.sessionId);return this._clearTaskQueue(i),{...a,_meta:{...a._meta,[Kr]:{taskId:i}}}}return await n()};return await n()}),this.setRequestHandler(il,async(r,o)=>{try{let{tasks:n,nextCursor:i}=await this._taskStore.listTasks(r.params?.cursor,o.sessionId);return{tasks:n,nextCursor:i,_meta:{}}}catch(n){throw new U(L.InvalidParams,`Failed to list tasks: ${n instanceof Error?n.message:String(n)}`)}}),this.setRequestHandler(al,async(r,o)=>{try{let n=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!n)throw new U(L.InvalidParams,`Task not found: ${r.params.taskId}`);if(Hr(n.status))throw new U(L.InvalidParams,`Cannot cancel task in terminal status: ${n.status}`);await this._taskStore.updateTaskStatus(r.params.taskId,"cancelled","Client cancelled task execution.",o.sessionId),this._clearTaskQueue(r.params.taskId);let i=await this._taskStore.getTask(r.params.taskId,o.sessionId);if(!i)throw new U(L.InvalidParams,`Task not found after cancellation: ${r.params.taskId}`);return{_meta:{},...i}}catch(n){throw n instanceof U?n:new U(L.InvalidRequest,`Failed to cancel task: ${n instanceof Error?n.message:String(n)}`)}}))}async _oncancel(t){if(!t.params.requestId)return;this._requestHandlerAbortControllers.get(t.params.requestId)?.abort(t.params.reason)}_setupTimeout(t,r,o,n,i=!1){this._timeoutInfo.set(t,{timeoutId:setTimeout(n,r),startTime:Date.now(),timeout:r,maxTotalTimeout:o,resetTimeoutOnProgress:i,onTimeout:n})}_resetTimeout(t){let r=this._timeoutInfo.get(t);if(!r)return!1;let o=Date.now()-r.startTime;if(r.maxTotalTimeout&&o>=r.maxTotalTimeout)throw this._timeoutInfo.delete(t),U.fromError(L.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:r.maxTotalTimeout,totalElapsed:o});return clearTimeout(r.timeoutId),r.timeoutId=setTimeout(r.onTimeout,r.timeout),!0}_cleanupTimeout(t){let r=this._timeoutInfo.get(t);r&&(clearTimeout(r.timeoutId),this._timeoutInfo.delete(t))}async connect(t){if(this._transport)throw new Error("Already connected to a transport. Call close() before connecting to a new transport, or use a separate Protocol instance per connection.");this._transport=t;let r=this.transport?.onclose;this._transport.onclose=()=>{r?.(),this._onclose()};let o=this.transport?.onerror;this._transport.onerror=i=>{o?.(i),this._onerror(i)};let n=this._transport?.onmessage;this._transport.onmessage=(i,s)=>{n?.(i,s),zs(i)||bb(i)?this._onresponse(i):pm(i)?this._onrequest(i,s):yb(i)?this._onnotification(i):this._onerror(new Error(`Unknown message type: ${JSON.stringify(i)}`))},await this._transport.start()}_onclose(){let t=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();for(let o of this._requestHandlerAbortControllers.values())o.abort();this._requestHandlerAbortControllers.clear();let r=U.fromError(L.ConnectionClosed,"Connection closed");this._transport=void 0,this.onclose?.();for(let o of t.values())o(r)}_onerror(t){this.onerror?.(t)}_onnotification(t){let r=this._notificationHandlers.get(t.method)??this.fallbackNotificationHandler;r!==void 0&&Promise.resolve().then(()=>r(t)).catch(o=>this._onerror(new Error(`Uncaught error in notification handler: ${o}`)))}_onrequest(t,r){let o=this._requestHandlers.get(t.method)??this.fallbackRequestHandler,n=this._transport,i=t.params?._meta?.[Kr]?.taskId;if(o===void 0){let l={jsonrpc:"2.0",id:t.id,error:{code:L.MethodNotFound,message:"Method not found"}};i&&this._taskMessageQueue?this._enqueueTaskMessage(i,{type:"error",message:l,timestamp:Date.now()},n?.sessionId).catch(d=>this._onerror(new Error(`Failed to enqueue error response: ${d}`))):n?.send(l).catch(d=>this._onerror(new Error(`Failed to send an error response: ${d}`)));return}let s=new AbortController;this._requestHandlerAbortControllers.set(t.id,s);let a=gb(t.params)?t.params.task:void 0,c=this._taskStore?this.requestTaskStore(t,n?.sessionId):void 0,u={signal:s.signal,sessionId:n?.sessionId,_meta:t.params?._meta,sendNotification:async l=>{if(s.signal.aborted)return;let d={relatedRequestId:t.id};i&&(d.relatedTask={taskId:i}),await this.notification(l,d)},sendRequest:async(l,d,h)=>{if(s.signal.aborted)throw new U(L.ConnectionClosed,"Request was cancelled");let m={...h,relatedRequestId:t.id};i&&!m.relatedTask&&(m.relatedTask={taskId:i});let p=m.relatedTask?.taskId??i;return p&&c&&await c.updateTaskStatus(p,"input_required"),await this.request(l,d,m)},authInfo:r?.authInfo,requestId:t.id,requestInfo:r?.requestInfo,taskId:i,taskStore:c,taskRequestedTtl:a?.ttl,closeSSEStream:r?.closeSSEStream,closeStandaloneSSEStream:r?.closeStandaloneSSEStream};Promise.resolve().then(()=>{a&&this.assertTaskHandlerCapability(t.method)}).then(()=>o(t,u)).then(async l=>{if(s.signal.aborted)return;let d={result:l,jsonrpc:"2.0",id:t.id};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"response",message:d,timestamp:Date.now()},n?.sessionId):await n?.send(d)},async l=>{if(s.signal.aborted)return;let d={jsonrpc:"2.0",id:t.id,error:{code:Number.isSafeInteger(l.code)?l.code:L.InternalError,message:l.message??"Internal error",...l.data!==void 0&&{data:l.data}}};i&&this._taskMessageQueue?await this._enqueueTaskMessage(i,{type:"error",message:d,timestamp:Date.now()},n?.sessionId):await n?.send(d)}).catch(l=>this._onerror(new Error(`Failed to send response: ${l}`))).finally(()=>{this._requestHandlerAbortControllers.delete(t.id)})}_onprogress(t){let{progressToken:r,...o}=t.params,n=Number(r),i=this._progressHandlers.get(n);if(!i){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(t)}`));return}let s=this._responseHandlers.get(n),a=this._timeoutInfo.get(n);if(a&&s&&a.resetTimeoutOnProgress)try{this._resetTimeout(n)}catch(c){this._responseHandlers.delete(n),this._progressHandlers.delete(n),this._cleanupTimeout(n),s(c);return}i(o)}_onresponse(t){let r=Number(t.id),o=this._requestResolvers.get(r);if(o){if(this._requestResolvers.delete(r),zs(t))o(t);else{let s=new U(t.error.code,t.error.message,t.error.data);o(s)}return}let n=this._responseHandlers.get(r);if(n===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(t)}`));return}this._responseHandlers.delete(r),this._cleanupTimeout(r);let i=!1;if(zs(t)&&t.result&&typeof t.result=="object"){let s=t.result;if(s.task&&typeof s.task=="object"){let a=s.task;typeof a.taskId=="string"&&(i=!0,this._taskProgressTokens.set(a.taskId,r))}}if(i||this._progressHandlers.delete(r),zs(t))n(t);else{let s=U.fromError(t.error.code,t.error.message,t.error.data);n(s)}}get transport(){return this._transport}async close(){await this._transport?.close()}async*requestStream(t,r,o){let{task:n}=o??{};if(!n){try{yield{type:"result",result:await this.request(t,r,o)}}catch(s){yield{type:"error",error:s instanceof U?s:new U(L.InternalError,String(s))}}return}let i;try{let s=await this.request(t,Io,o);if(s.task)i=s.task.taskId,yield{type:"taskCreated",task:s.task};else throw new U(L.InternalError,"Task creation did not return a task");for(;;){let a=await this.getTask({taskId:i},o);if(yield{type:"taskStatus",task:a},Hr(a.status)){a.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:i},r,o)}:a.status==="failed"?yield{type:"error",error:new U(L.InternalError,`Task ${i} failed`)}:a.status==="cancelled"&&(yield{type:"error",error:new U(L.InternalError,`Task ${i} was cancelled`)});return}if(a.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:i},r,o)};return}let c=a.pollInterval??this._options?.defaultTaskPollInterval??1e3;await new Promise(u=>setTimeout(u,c)),o?.signal?.throwIfAborted()}}catch(s){yield{type:"error",error:s instanceof U?s:new U(L.InternalError,String(s))}}}request(t,r,o){let{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s,task:a,relatedTask:c}=o??{};return new Promise((u,l)=>{let d=w=>{l(w)};if(!this._transport){d(new Error("Not connected"));return}if(this._options?.enforceStrictCapabilities===!0)try{this.assertCapabilityForMethod(t.method),a&&this.assertTaskCapability(t.method)}catch(w){d(w);return}o?.signal?.throwIfAborted();let h=this._requestMessageId++,m={...t,jsonrpc:"2.0",id:h};o?.onprogress&&(this._progressHandlers.set(h,o.onprogress),m.params={...t.params,_meta:{...t.params?._meta||{},progressToken:h}}),a&&(m.params={...m.params,task:a}),c&&(m.params={...m.params,_meta:{...m.params?._meta||{},[Kr]:c}});let p=w=>{this._responseHandlers.delete(h),this._progressHandlers.delete(h),this._cleanupTimeout(h),this._transport?.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:h,reason:String(w)}},{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s}).catch(E=>this._onerror(new Error(`Failed to send cancellation: ${E}`)));let k=w instanceof U?w:new U(L.RequestTimeout,String(w));l(k)};this._responseHandlers.set(h,w=>{if(!o?.signal?.aborted){if(w instanceof Error)return l(w);try{let k=Gr(r,w.result);k.success?u(k.data):l(k.error)}catch(k){l(k)}}}),o?.signal?.addEventListener("abort",()=>{p(o?.signal?.reason)});let f=o?.timeout??HI,v=()=>p(U.fromError(L.RequestTimeout,"Request timed out",{timeout:f}));this._setupTimeout(h,f,o?.maxTotalTimeout,v,o?.resetTimeoutOnProgress??!1);let y=c?.taskId;if(y){let w=k=>{let E=this._responseHandlers.get(h);E?E(k):this._onerror(new Error(`Response handler missing for side-channeled request ${h}`))};this._requestResolvers.set(h,w),this._enqueueTaskMessage(y,{type:"request",message:m,timestamp:Date.now()}).catch(k=>{this._cleanupTimeout(h),l(k)})}else this._transport.send(m,{relatedRequestId:n,resumptionToken:i,onresumptiontoken:s}).catch(w=>{this._cleanupTimeout(h),l(w)})})}async getTask(t,r){return this.request({method:"tasks/get",params:t},nl,r)}async getTaskResult(t,r,o){return this.request({method:"tasks/result",params:t},r,o)}async listTasks(t,r){return this.request({method:"tasks/list",params:t},sl,r)}async cancelTask(t,r){return this.request({method:"tasks/cancel",params:t},kb,r)}async notification(t,r){if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(t.method);let o=r?.relatedTask?.taskId;if(o){let a={...t,jsonrpc:"2.0",params:{...t.params,_meta:{...t.params?._meta||{},[Kr]:r.relatedTask}}};await this._enqueueTaskMessage(o,{type:"notification",message:a,timestamp:Date.now()});return}if((this._options?.debouncedNotificationMethods??[]).includes(t.method)&&!t.params&&!r?.relatedRequestId&&!r?.relatedTask){if(this._pendingDebouncedNotifications.has(t.method))return;this._pendingDebouncedNotifications.add(t.method),Promise.resolve().then(()=>{if(this._pendingDebouncedNotifications.delete(t.method),!this._transport)return;let a={...t,jsonrpc:"2.0"};r?.relatedTask&&(a={...a,params:{...a.params,_meta:{...a.params?._meta||{},[Kr]:r.relatedTask}}}),this._transport?.send(a,r).catch(c=>this._onerror(c))});return}let s={...t,jsonrpc:"2.0"};r?.relatedTask&&(s={...s,params:{...s.params,_meta:{...s.params?._meta||{},[Kr]:r.relatedTask}}}),await this._transport.send(s,r)}setRequestHandler(t,r){let o=jm(t);this.assertRequestHandlerCapability(o),this._requestHandlers.set(o,(n,i)=>{let s=Nm(t,n);return Promise.resolve(r(s,i))})}removeRequestHandler(t){this._requestHandlers.delete(t)}assertCanSetRequestHandler(t){if(this._requestHandlers.has(t))throw new Error(`A request handler for ${t} already exists, which would be overridden`)}setNotificationHandler(t,r){let o=jm(t);this._notificationHandlers.set(o,n=>{let i=Nm(t,n);return Promise.resolve(r(i))})}removeNotificationHandler(t){this._notificationHandlers.delete(t)}_cleanupTaskProgressHandler(t){let r=this._taskProgressTokens.get(t);r!==void 0&&(this._progressHandlers.delete(r),this._taskProgressTokens.delete(t))}async _enqueueTaskMessage(t,r,o){if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let n=this._options?.maxTaskQueueSize;await this._taskMessageQueue.enqueue(t,r,o,n)}async _clearTaskQueue(t,r){if(this._taskMessageQueue){let o=await this._taskMessageQueue.dequeueAll(t,r);for(let n of o)if(n.type==="request"&&pm(n.message)){let i=n.message.id,s=this._requestResolvers.get(i);s?(s(new U(L.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(i)):this._onerror(new Error(`Resolver missing for request ${i} during task ${t} cleanup`))}}}async _waitForTaskUpdate(t,r){let o=this._options?.defaultTaskPollInterval??1e3;try{let n=await this._taskStore?.getTask(t);n?.pollInterval&&(o=n.pollInterval)}catch{}return new Promise((n,i)=>{if(r.aborted){i(new U(L.InvalidRequest,"Request cancelled"));return}let s=setTimeout(n,o);r.addEventListener("abort",()=>{clearTimeout(s),i(new U(L.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(t,r){let o=this._taskStore;if(!o)throw new Error("No task store configured");return{createTask:async n=>{if(!t)throw new Error("No request provided");return await o.createTask(n,t.id,{method:t.method,params:t.params},r)},getTask:async n=>{let i=await o.getTask(n,r);if(!i)throw new U(L.InvalidParams,"Failed to retrieve task: Task not found");return i},storeTaskResult:async(n,i,s)=>{await o.storeTaskResult(n,i,s,r);let a=await o.getTask(n,r);if(a){let c=Ns.parse({method:"notifications/tasks/status",params:a});await this.notification(c),Hr(a.status)&&this._cleanupTaskProgressHandler(n)}},getTaskResult:n=>o.getTaskResult(n,r),updateTaskStatus:async(n,i,s)=>{let a=await o.getTask(n,r);if(!a)throw new U(L.InvalidParams,`Task "${n}" not found - it may have been cleaned up`);if(Hr(a.status))throw new U(L.InvalidParams,`Cannot update task "${n}" from terminal status "${a.status}" to "${i}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await o.updateTaskStatus(n,i,s,r);let c=await o.getTask(n,r);if(c){let u=Ns.parse({method:"notifications/tasks/status",params:c});await this.notification(u),Hr(c.status)&&this._cleanupTaskProgressHandler(n)}},listTasks:n=>o.listTasks(n,r)}}};function u$(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function l$(e,t){let r={...e};for(let o in t){let n=o,i=t[n];if(i===void 0)continue;let s=r[n];u$(s)&&u$(i)?r[n]={...s,...i}:r[n]=i}return r}var lS=Ge(Ak(),1),dS=Ge(uS(),1);function j4(){let e=new lS.default({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return(0,dS.default)(e),e}var Rd=class{constructor(t){this._ajv=t??j4()}getValidator(t){let r="$id"in t&&typeof t.$id=="string"?this._ajv.getSchema(t.$id)??this._ajv.compile(t):this._ajv.compile(t);return o=>r(o)?{valid:!0,data:o,errorMessage:void 0}:{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(r.errors)}}};var Cd=class{constructor(t){this._server=t}requestStream(t,r,o){return this._server.requestStream(t,r,o)}createMessageStream(t,r){let o=this._server.getClientCapabilities();if((t.tools||t.toolChoice)&&!o?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let n=t.messages[t.messages.length-1],i=Array.isArray(n.content)?n.content:[n.content],s=i.some(l=>l.type==="tool_result"),a=t.messages.length>1?t.messages[t.messages.length-2]:void 0,c=a?Array.isArray(a.content)?a.content:[a.content]:[],u=c.some(l=>l.type==="tool_use");if(s){if(i.some(l=>l.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!u)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(u){let l=new Set(c.filter(h=>h.type==="tool_use").map(h=>h.id)),d=new Set(i.filter(h=>h.type==="tool_result").map(h=>h.toolUseId));if(l.size!==d.size||![...l].every(h=>d.has(h)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return this.requestStream({method:"sampling/createMessage",params:t},As,r)}elicitInputStream(t,r){let o=this._server.getClientCapabilities(),n=t.mode??"form";switch(n){case"url":{if(!o?.elicitation?.url)throw new Error("Client does not support url elicitation.");break}case"form":{if(!o?.elicitation?.form)throw new Error("Client does not support form elicitation.");break}}let i=n==="form"&&t.mode===void 0?{...t,mode:"form"}:t;return this.requestStream({method:"elicitation/create",params:i},No,r)}async getTask(t,r){return this._server.getTask({taskId:t},r)}async getTaskResult(t,r,o){return this._server.getTaskResult({taskId:t},r,o)}async listTasks(t,r){return this._server.listTasks(t?{cursor:t}:void 0,r)}async cancelTask(t,r){return this._server.cancelTask({taskId:t},r)}};function pS(e,t,r){if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!e.tools?.call)throw new Error(`${r} does not support task creation for tools/call (required for ${t})`);break;default:break}}function fS(e,t,r){if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!e.sampling?.createMessage)throw new Error(`${r} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!e.elicitation?.create)throw new Error(`${r} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}var Ad=class extends bl{constructor(t,r){super(r),this._serverInfo=t,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(Cs.options.map((o,n)=>[o,n])),this.isMessageIgnored=(o,n)=>{let i=this._loggingLevels.get(n);return i?this.LOG_LEVEL_SEVERITY.get(o)<this.LOG_LEVEL_SEVERITY.get(i):!1},this._capabilities=r?.capabilities??{},this._instructions=r?.instructions,this._jsonSchemaValidator=r?.jsonSchemaValidator??new Rd,this.setRequestHandler(hm,o=>this._oninitialize(o)),this.setNotificationHandler(gm,()=>this.oninitialized?.()),this._capabilities.logging&&this.setRequestHandler(km,async(o,n)=>{let i=n.sessionId||n.requestInfo?.headers["mcp-session-id"]||void 0,{level:s}=o.params,a=Cs.safeParse(s);return a.success&&this._loggingLevels.set(i,a.data),{}})}get experimental(){return this._experimental||(this._experimental={tasks:new Cd(this)}),this._experimental}registerCapabilities(t){if(this.transport)throw new Error("Cannot register capabilities after connecting to transport");this._capabilities=l$(this._capabilities,t)}setRequestHandler(t,r){let n=Wr(t)?.method;if(!n)throw new Error("Schema is missing a method literal");let i;if(Nt(n)){let a=n;i=a._zod?.def?.value??a.value}else{let a=n;i=a._def?.value??a.value}if(typeof i!="string")throw new Error("Schema method literal must be a string");if(i==="tools/call"){let a=async(c,u)=>{let l=Gr(jo,c);if(!l.success){let p=l.error instanceof Error?l.error.message:String(l.error);throw new U(L.InvalidParams,`Invalid tools/call request: ${p}`)}let{params:d}=l.data,h=await Promise.resolve(r(c,u));if(d.task){let p=Gr(Io,h);if(!p.success){let f=p.error instanceof Error?p.error.message:String(p.error);throw new U(L.InvalidParams,`Invalid task creation result: ${f}`)}return p.data}let m=Gr(ml,h);if(!m.success){let p=m.error instanceof Error?m.error.message:String(m.error);throw new U(L.InvalidParams,`Invalid tools/call result: ${p}`)}return m.data};return super.setRequestHandler(t,a)}return super.setRequestHandler(t,r)}assertCapabilityForMethod(t){switch(t){case"sampling/createMessage":if(!this._clientCapabilities?.sampling)throw new Error(`Client does not support sampling (required for ${t})`);break;case"elicitation/create":if(!this._clientCapabilities?.elicitation)throw new Error(`Client does not support elicitation (required for ${t})`);break;case"roots/list":if(!this._clientCapabilities?.roots)throw new Error(`Client does not support listing roots (required for ${t})`);break;case"ping":break}}assertNotificationCapability(t){switch(t){case"notifications/message":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw new Error(`Server does not support notifying about resources (required for ${t})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw new Error(`Server does not support notifying of tool list changes (required for ${t})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw new Error(`Server does not support notifying of prompt list changes (required for ${t})`);break;case"notifications/elicitation/complete":if(!this._clientCapabilities?.elicitation?.url)throw new Error(`Client does not support URL elicitation (required for ${t})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(t){if(this._capabilities)switch(t){case"completion/complete":if(!this._capabilities.completions)throw new Error(`Server does not support completions (required for ${t})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw new Error(`Server does not support prompts (required for ${t})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw new Error(`Server does not support resources (required for ${t})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw new Error(`Server does not support tools (required for ${t})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw new Error(`Server does not support tasks capability (required for ${t})`);break;case"ping":case"initialize":break}}assertTaskCapability(t){fS(this._clientCapabilities?.tasks?.requests,t,"Client")}assertTaskHandlerCapability(t){this._capabilities&&pS(this._capabilities.tasks?.requests,t,"Server")}async _oninitialize(t){let r=t.params.protocolVersion;return this._clientCapabilities=t.params.capabilities,this._clientVersion=t.params.clientInfo,{protocolVersion:fb.includes(r)?r:lm,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"},Xu)}async createMessage(t,r){if((t.tools||t.toolChoice)&&!this._clientCapabilities?.sampling?.tools)throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let o=t.messages[t.messages.length-1],n=Array.isArray(o.content)?o.content:[o.content],i=n.some(u=>u.type==="tool_result"),s=t.messages.length>1?t.messages[t.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(n.some(u=>u.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!c)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(c){let u=new Set(a.filter(d=>d.type==="tool_use").map(d=>d.id)),l=new Set(n.filter(d=>d.type==="tool_result").map(d=>d.toolUseId));if(u.size!==l.size||![...u].every(d=>l.has(d)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return t.tools?this.request({method:"sampling/createMessage",params:t},xm,r):this.request({method:"sampling/createMessage",params:t},As,r)}async elicitInput(t,r){switch(t.mode??"form"){case"url":{if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support url elicitation.");let n=t;return this.request({method:"elicitation/create",params:n},No,r)}case"form":{if(!this._clientCapabilities?.elicitation?.form)throw new Error("Client does not support form elicitation.");let n=t.mode==="form"?t:{...t,mode:"form"},i=await this.request({method:"elicitation/create",params:n},No,r);if(i.action==="accept"&&i.content&&n.requestedSchema)try{let a=this._jsonSchemaValidator.getValidator(n.requestedSchema)(i.content);if(!a.valid)throw new U(L.InvalidParams,`Elicitation response content does not match requested schema: ${a.errorMessage}`)}catch(s){throw s instanceof U?s:new U(L.InternalError,`Error validating elicitation response: ${s instanceof Error?s.message:String(s)}`)}return i}}}createElicitationCompletionNotifier(t,r){if(!this._clientCapabilities?.elicitation?.url)throw new Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:t}},r)}async listRoots(t,r){return this.request({method:"roots/list",params:t},Sm,r)}async sendLoggingMessage(t,r){if(this._capabilities.logging&&!this.isMessageIgnored(t.level,r))return this.notification({method:"notifications/message",params:t})}async sendResourceUpdated(t){return this.notification({method:"notifications/resources/updated",params:t})}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 hS=Symbol.for("mcp.completable");function n_(e){return!!e&&typeof e=="object"&&hS in e}function gS(e){return e[hS]?.complete}var mS;(function(e){e.Completable="McpCompletable"})(mS||(mS={}));var N4=/^[A-Za-z0-9._-]{1,128}$/;function R4(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"),e.includes(",")&&t.push("Tool name contains commas, which may cause parsing issues"),(e.startsWith("-")||e.endsWith("-"))&&t.push("Tool name starts or ends with a dash, which may cause parsing issues in some contexts"),(e.startsWith(".")||e.endsWith("."))&&t.push("Tool name starts or ends with a dot, which may cause parsing issues in some contexts"),!N4.test(e)){let r=e.split("").filter(o=>!/[A-Za-z0-9._-]/.test(o)).filter((o,n,i)=>i.indexOf(o)===n);return t.push(`Tool name contains invalid characters: ${r.map(o=>`"${o}"`).join(", ")}`,"Allowed characters are: A-Z, a-z, 0-9, underscore (_), dash (-), and dot (.)"),{isValid:!1,warnings:t}}return{isValid:!0,warnings:t}}function C4(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 o_(e){let t=R4(e);return C4(e,t.warnings),t.isValid}var Dd=class{constructor(t){this._mcpServer=t}registerToolTask(t,r,o){let n={taskSupport:"required",...r.execution};if(n.taskSupport==="forbidden")throw new Error(`Cannot register task-based tool '${t}' with taskSupport 'forbidden'. Use registerTool() instead.`);return this._mcpServer._createRegisteredTool(t,r.title,r.description,r.inputSchema,r.outputSchema,r.annotations,n,r._meta,o)}};var qd=class{constructor(t,r){this._registeredResources={},this._registeredResourceTemplates={},this._registeredTools={},this._registeredPrompts={},this._toolHandlersInitialized=!1,this._completionHandlerInitialized=!1,this._resourceHandlersInitialized=!1,this._promptHandlersInitialized=!1,this.server=new Ad(t,r)}get experimental(){return this._experimental||(this._experimental={tasks:new Dd(this)}),this._experimental}async connect(t){return await this.server.connect(t)}async close(){await this.server.close()}setToolRequestHandlers(){this._toolHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(fl)),this.server.assertCanSetRequestHandler(dn(jo)),this.server.registerCapabilities({tools:{listChanged:!0}}),this.server.setRequestHandler(fl,()=>({tools:Object.entries(this._registeredTools).filter(([,t])=>t.enabled).map(([t,r])=>{let o={name:t,title:r.title,description:r.description,inputSchema:(()=>{let n=So(r.inputSchema);return n?Om(n,{strictUnions:!0,pipeStrategy:"input"}):A4})(),annotations:r.annotations,execution:r.execution,_meta:r._meta};if(r.outputSchema){let n=So(r.outputSchema);n&&(o.outputSchema=Om(n,{strictUnions:!0,pipeStrategy:"output"}))}return o})})),this.server.setRequestHandler(jo,async(t,r)=>{try{let o=this._registeredTools[t.params.name];if(!o)throw new U(L.InvalidParams,`Tool ${t.params.name} not found`);if(!o.enabled)throw new U(L.InvalidParams,`Tool ${t.params.name} disabled`);let n=!!t.params.task,i=o.execution?.taskSupport,s="createTask"in o.handler;if((i==="required"||i==="optional")&&!s)throw new U(L.InternalError,`Tool ${t.params.name} has taskSupport '${i}' but was not registered with registerToolTask`);if(i==="required"&&!n)throw new U(L.MethodNotFound,`Tool ${t.params.name} requires task augmentation (taskSupport: 'required')`);if(i==="optional"&&!n&&s)return await this.handleAutomaticTaskPolling(o,t,r);let a=await this.validateToolInput(o,t.params.arguments,t.params.name),c=await this.executeToolHandler(o,a,r);return n||await this.validateToolOutput(o,c,t.params.name),c}catch(o){if(o instanceof U&&o.code===L.UrlElicitationRequired)throw o;return this.createToolError(o instanceof Error?o.message:String(o))}}),this._toolHandlersInitialized=!0)}createToolError(t){return{content:[{type:"text",text:t}],isError:!0}}async validateToolInput(t,r,o){if(!t.inputSchema)return;let i=So(t.inputSchema)??t.inputSchema,s=await Nu(i,r);if(!s.success){let a="error"in s?s.error:"Unknown error",c=Ru(a);throw new U(L.InvalidParams,`Input validation error: Invalid arguments for tool ${o}: ${c}`)}return s.data}async validateToolOutput(t,r,o){if(!t.outputSchema||!("content"in r)||r.isError)return;if(!r.structuredContent)throw new U(L.InvalidParams,`Output validation error: Tool ${o} has an output schema but no structured content was provided`);let n=So(t.outputSchema),i=await Nu(n,r.structuredContent);if(!i.success){let s="error"in i?i.error:"Unknown error",a=Ru(s);throw new U(L.InvalidParams,`Output validation error: Invalid structured content for tool ${o}: ${a}`)}}async executeToolHandler(t,r,o){let n=t.handler;if("createTask"in n){if(!o.taskStore)throw new Error("No task store provided.");let s={...o,taskStore:o.taskStore};if(t.inputSchema){let a=n;return await Promise.resolve(a.createTask(r,s))}else{let a=n;return await Promise.resolve(a.createTask(s))}}if(t.inputSchema){let s=n;return await Promise.resolve(s(r,o))}else{let s=n;return await Promise.resolve(s(o))}}async handleAutomaticTaskPolling(t,r,o){if(!o.taskStore)throw new Error("No task store provided for task-capable tool.");let n=await this.validateToolInput(t,r.params.arguments,r.params.name),i=t.handler,s={...o,taskStore:o.taskStore},a=n?await Promise.resolve(i.createTask(n,s)):await Promise.resolve(i.createTask(s)),c=a.task.taskId,u=a.task,l=u.pollInterval??5e3;for(;u.status!=="completed"&&u.status!=="failed"&&u.status!=="cancelled";){await new Promise(h=>setTimeout(h,l));let d=await o.taskStore.getTask(c);if(!d)throw new U(L.InternalError,`Task ${c} not found during polling`);u=d}return await o.taskStore.getTaskResult(c)}setCompletionRequestHandler(){this._completionHandlerInitialized||(this.server.assertCanSetRequestHandler(dn(hl)),this.server.registerCapabilities({completions:{}}),this.server.setRequestHandler(hl,async t=>{switch(t.params.ref.type){case"ref/prompt":return Eb(t),this.handlePromptCompletion(t,t.params.ref);case"ref/resource":return Ib(t),this.handleResourceCompletion(t,t.params.ref);default:throw new U(L.InvalidParams,`Invalid completion reference: ${t.params.ref}`)}}),this._completionHandlerInitialized=!0)}async handlePromptCompletion(t,r){let o=this._registeredPrompts[r.name];if(!o)throw new U(L.InvalidParams,`Prompt ${r.name} not found`);if(!o.enabled)throw new U(L.InvalidParams,`Prompt ${r.name} disabled`);if(!o.argsSchema)return Za;let i=Wr(o.argsSchema)?.[t.params.argument.name];if(!n_(i))return Za;let s=gS(i);if(!s)return Za;let a=await s(t.params.argument.value,t.params.context);return _S(a)}async handleResourceCompletion(t,r){let o=Object.values(this._registeredResourceTemplates).find(s=>s.resourceTemplate.uriTemplate.toString()===r.uri);if(!o){if(this._registeredResources[r.uri])return Za;throw new U(L.InvalidParams,`Resource template ${t.params.ref.uri} not found`)}let n=o.resourceTemplate.completeCallback(t.params.argument.name);if(!n)return Za;let i=await n(t.params.argument.value,t.params.context);return _S(i)}setResourceRequestHandlers(){this._resourceHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(cl)),this.server.assertCanSetRequestHandler(dn(ul)),this.server.assertCanSetRequestHandler(dn(ll)),this.server.registerCapabilities({resources:{listChanged:!0}}),this.server.setRequestHandler(cl,async(t,r)=>{let o=Object.entries(this._registeredResources).filter(([i,s])=>s.enabled).map(([i,s])=>({uri:i,name:s.name,...s.metadata})),n=[];for(let i of Object.values(this._registeredResourceTemplates)){if(!i.resourceTemplate.listCallback)continue;let s=await i.resourceTemplate.listCallback(r);for(let a of s.resources)n.push({...i.metadata,...a})}return{resources:[...o,...n]}}),this.server.setRequestHandler(ul,async()=>({resourceTemplates:Object.entries(this._registeredResourceTemplates).map(([r,o])=>({name:r,uriTemplate:o.resourceTemplate.uriTemplate.toString(),...o.metadata}))})),this.server.setRequestHandler(ll,async(t,r)=>{let o=new URL(t.params.uri),n=this._registeredResources[o.toString()];if(n){if(!n.enabled)throw new U(L.InvalidParams,`Resource ${o} disabled`);return n.readCallback(o,r)}for(let i of Object.values(this._registeredResourceTemplates)){let s=i.resourceTemplate.uriTemplate.match(o.toString());if(s)return i.readCallback(o,s,r)}throw new U(L.InvalidParams,`Resource ${o} not found`)}),this._resourceHandlersInitialized=!0)}setPromptRequestHandlers(){this._promptHandlersInitialized||(this.server.assertCanSetRequestHandler(dn(dl)),this.server.assertCanSetRequestHandler(dn(pl)),this.server.registerCapabilities({prompts:{listChanged:!0}}),this.server.setRequestHandler(dl,()=>({prompts:Object.entries(this._registeredPrompts).filter(([,t])=>t.enabled).map(([t,r])=>({name:t,title:r.title,description:r.description,arguments:r.argsSchema?q4(r.argsSchema):void 0}))})),this.server.setRequestHandler(pl,async(t,r)=>{let o=this._registeredPrompts[t.params.name];if(!o)throw new U(L.InvalidParams,`Prompt ${t.params.name} not found`);if(!o.enabled)throw new U(L.InvalidParams,`Prompt ${t.params.name} disabled`);if(o.argsSchema){let n=So(o.argsSchema),i=await Nu(n,t.params.arguments);if(!i.success){let c="error"in i?i.error:"Unknown error",u=Ru(c);throw new U(L.InvalidParams,`Invalid arguments for prompt ${t.params.name}: ${u}`)}let s=i.data,a=o.callback;return await Promise.resolve(a(s,r))}else{let n=o.callback;return await Promise.resolve(n(r))}}),this._promptHandlersInitialized=!0)}resource(t,r,...o){let n;typeof o[0]=="object"&&(n=o.shift());let i=o[0];if(typeof r=="string"){if(this._registeredResources[r])throw new Error(`Resource ${r} is already registered`);let s=this._createRegisteredResource(t,void 0,r,n,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),s}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let s=this._createRegisteredResourceTemplate(t,void 0,r,n,i);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),s}}registerResource(t,r,o,n){if(typeof r=="string"){if(this._registeredResources[r])throw new Error(`Resource ${r} is already registered`);let i=this._createRegisteredResource(t,o.title,r,o,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}else{if(this._registeredResourceTemplates[t])throw new Error(`Resource template ${t} is already registered`);let i=this._createRegisteredResourceTemplate(t,o.title,r,o,n);return this.setResourceRequestHandlers(),this.sendResourceListChanged(),i}}_createRegisteredResource(t,r,o,n,i){let s={name:t,title:r,metadata:n,readCallback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({uri:null}),update:a=>{typeof a.uri<"u"&&a.uri!==o&&(delete this._registeredResources[o],a.uri&&(this._registeredResources[a.uri]=s)),typeof a.name<"u"&&(s.name=a.name),typeof a.title<"u"&&(s.title=a.title),typeof a.metadata<"u"&&(s.metadata=a.metadata),typeof a.callback<"u"&&(s.readCallback=a.callback),typeof a.enabled<"u"&&(s.enabled=a.enabled),this.sendResourceListChanged()}};return this._registeredResources[o]=s,s}_createRegisteredResourceTemplate(t,r,o,n,i){let s={resourceTemplate:o,title:r,metadata:n,readCallback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({name:null}),update:u=>{typeof u.name<"u"&&u.name!==t&&(delete this._registeredResourceTemplates[t],u.name&&(this._registeredResourceTemplates[u.name]=s)),typeof u.title<"u"&&(s.title=u.title),typeof u.template<"u"&&(s.resourceTemplate=u.template),typeof u.metadata<"u"&&(s.metadata=u.metadata),typeof u.callback<"u"&&(s.readCallback=u.callback),typeof u.enabled<"u"&&(s.enabled=u.enabled),this.sendResourceListChanged()}};this._registeredResourceTemplates[t]=s;let a=o.uriTemplate.variableNames;return Array.isArray(a)&&a.some(u=>!!o.completeCallback(u))&&this.setCompletionRequestHandler(),s}_createRegisteredPrompt(t,r,o,n,i){let s={title:r,description:o,argsSchema:n===void 0?void 0:Tn(n),callback:i,enabled:!0,disable:()=>s.update({enabled:!1}),enable:()=>s.update({enabled:!0}),remove:()=>s.update({name:null}),update:a=>{typeof a.name<"u"&&a.name!==t&&(delete this._registeredPrompts[t],a.name&&(this._registeredPrompts[a.name]=s)),typeof a.title<"u"&&(s.title=a.title),typeof a.description<"u"&&(s.description=a.description),typeof a.argsSchema<"u"&&(s.argsSchema=Tn(a.argsSchema)),typeof a.callback<"u"&&(s.callback=a.callback),typeof a.enabled<"u"&&(s.enabled=a.enabled),this.sendPromptListChanged()}};return this._registeredPrompts[t]=s,n&&Object.values(n).some(c=>{let u=c instanceof Pt?c._def?.innerType:c;return n_(u)})&&this.setCompletionRequestHandler(),s}_createRegisteredTool(t,r,o,n,i,s,a,c,u){o_(t);let l={title:r,description:o,inputSchema:vS(n),outputSchema:vS(i),annotations:s,execution:a,_meta:c,handler:u,enabled:!0,disable:()=>l.update({enabled:!1}),enable:()=>l.update({enabled:!0}),remove:()=>l.update({name:null}),update:d=>{typeof d.name<"u"&&d.name!==t&&(typeof d.name=="string"&&o_(d.name),delete this._registeredTools[t],d.name&&(this._registeredTools[d.name]=l)),typeof d.title<"u"&&(l.title=d.title),typeof d.description<"u"&&(l.description=d.description),typeof d.paramsSchema<"u"&&(l.inputSchema=Tn(d.paramsSchema)),typeof d.outputSchema<"u"&&(l.outputSchema=Tn(d.outputSchema)),typeof d.callback<"u"&&(l.handler=d.callback),typeof d.annotations<"u"&&(l.annotations=d.annotations),typeof d._meta<"u"&&(l._meta=d._meta),typeof d.enabled<"u"&&(l.enabled=d.enabled),this.sendToolListChanged()}};return this._registeredTools[t]=l,this.setToolRequestHandlers(),this.sendToolListChanged(),l}tool(t,...r){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let o,n,i,s;if(typeof r[0]=="string"&&(o=r.shift()),r.length>1){let c=r[0];i_(c)?(n=r.shift(),r.length>1&&typeof r[0]=="object"&&r[0]!==null&&!i_(r[0])&&(s=r.shift())):typeof c=="object"&&c!==null&&(s=r.shift())}let a=r[0];return this._createRegisteredTool(t,void 0,o,n,i,s,{taskSupport:"forbidden"},void 0,a)}registerTool(t,r,o){if(this._registeredTools[t])throw new Error(`Tool ${t} is already registered`);let{title:n,description:i,inputSchema:s,outputSchema:a,annotations:c,_meta:u}=r;return this._createRegisteredTool(t,n,i,s,a,c,{taskSupport:"forbidden"},u,o)}prompt(t,...r){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let o;typeof r[0]=="string"&&(o=r.shift());let n;r.length>1&&(n=r.shift());let i=r[0],s=this._createRegisteredPrompt(t,void 0,o,n,i);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),s}registerPrompt(t,r,o){if(this._registeredPrompts[t])throw new Error(`Prompt ${t} is already registered`);let{title:n,description:i,argsSchema:s}=r,a=this._createRegisteredPrompt(t,n,i,s,o);return this.setPromptRequestHandlers(),this.sendPromptListChanged(),a}isConnected(){return this.server.transport!==void 0}async sendLoggingMessage(t,r){return this.server.sendLoggingMessage(t,r)}sendResourceListChanged(){this.isConnected()&&this.server.sendResourceListChanged()}sendToolListChanged(){this.isConnected()&&this.server.sendToolListChanged()}sendPromptListChanged(){this.isConnected()&&this.server.sendPromptListChanged()}};var A4={type:"object",properties:{}};function yS(e){return e!==null&&typeof e=="object"&&"parse"in e&&typeof e.parse=="function"&&"safeParse"in e&&typeof e.safeParse=="function"}function D4(e){return"_def"in e||"_zod"in e||yS(e)}function i_(e){return typeof e!="object"||e===null||D4(e)?!1:Object.keys(e).length===0?!0:Object.values(e).some(yS)}function vS(e){if(e)return i_(e)?Tn(e):e}function q4(e){let t=Wr(e);return t?Object.entries(t).map(([r,o])=>{let n=Py(o),i=zy(o);return{name:r,description:n,required:!i}}):[]}function dn(e){let r=Wr(e)?.method;if(!r)throw new Error("Schema is missing a method literal");let o=Cu(r);if(typeof o=="string")return o;throw new Error("Schema method literal must be a string")}function _S(e){return{completion:{values:e.slice(0,100),total:e.length,hasMore:e.length>100}}}var Za={completion:{values:[],hasMore:!1}};var s_=Ge(require("node:process"),1);var Md=class{append(t){this._buffer=this._buffer?Buffer.concat([this._buffer,t]):t}readMessage(){if(!this._buffer)return null;let t=this._buffer.indexOf(`
49
+ `);if(t===-1)return null;let r=this._buffer.toString("utf8",0,t).replace(/\r$/,"");return this._buffer=this._buffer.subarray(t+1),M4(r)}clear(){this._buffer=void 0}};function M4(e){return $b.parse(JSON.parse(e))}function bS(e){return JSON.stringify(e)+`
50
+ `}var Ud=class{constructor(t=s_.default.stdin,r=s_.default.stdout){this._stdin=t,this._stdout=r,this._readBuffer=new Md,this._started=!1,this._ondata=o=>{this._readBuffer.append(o),this.processReadBuffer()},this._onerror=o=>{this.onerror?.(o)}}async start(){if(this._started)throw new 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(){for(;;)try{let t=this._readBuffer.readMessage();if(t===null)break;this.onmessage?.(t)}catch(t){this.onerror?.(t)}}async close(){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(t){return new Promise(r=>{let o=bS(t);this._stdout.write(o)?r():this._stdout.once("drain",r)})}};var $S="2.6.0";var a_={name:"Vantage Cloud Costs Helper",version:$S};async function wS(e,t,r,o,n){t["User-Agent"]=`vantage-mcp-server/${a_.version}`;let i=new URL(n,e);o==="GET"?Object.entries(r).forEach(([u,l])=>{l!=null&&i.searchParams.append(u,Array.isArray(l)?l.join(","):String(l))}):t["Content-Type"]="application/json";let s={method:o,headers:t,body:o!=="GET"?JSON.stringify(r):void 0},a=await fetch(i.toString(),s);if(!a.ok){let u=await a.text();try{let l=JSON.parse(u);if(Array.isArray(l.errors))return{errors:l.errors,ok:!1}}catch{}return{errors:[{message:"Vantage API request failed",status:a.status,endpoint:n,details:u}],ok:!1}}return a.status===204?{data:void 0,ok:!0}:{data:await a.json(),ok:!0}}var I=class{constructor(t){this.exception=t}};var c_=new Map;function j(e){let t=(r,o)=>{r.tool(e.name,e.description,e.args,{readOnlyHint:e.annotations.readOnly??!1,openWorldHint:e.annotations.openWorld??!1,destructiveHint:e.annotations.destructive??!0},async n=>{try{let i=await e.execute(n,o());return{content:[{type:"text",text:JSON.stringify(i,null,2)}],isError:!1}}catch(i){if(i instanceof I)return{content:[{type:"text",text:JSON.stringify(i.exception,null,2)}],isError:!0};throw i}})};if(c_.has(e.name))throw new Error(`Tool ${e.name} is already registered`);return c_.set(e.name,t),e}function kS(e,t){for(let r of c_.values())r(e,t)}var U4="Invalid date input, must be YYYY-MM-DD format and a reasonable date.";function Z4(e){let t="2030-01-01",r="2010-01-01";if(!e||e===""||typeof e!="string"||e<r||e>t)return!1;let o=Date.parse(e);return!(Number.isNaN(o)||o<=Date.parse(r)||o>=Date.parse(t))}function $e(e){return g.string().refine(Z4,{error:U4}).describe(e)}var V4=`
51
51
  Creates a budget based on the parameters specified. This is useful if you have been tasked with managing budgets
52
52
  or you are building a cost report with budgets in mind.
53
- `.trim(),CM=v.object({start_at:be("The start date of the period."),end_at:be("The end date of the period.").optional(),amount:v.number().min(0).describe("The amount of the period.")}),XH=C({name:"create-budget",description:RM,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{name:v.string().min(1).describe("The name of the Budget."),workspace_token:v.string().optional().describe("The token of the Workspace to add the Budget to."),cost_report_token:v.string().optional().describe("The CostReport token. Ignored for hierarchical Budgets."),child_budget_tokens:v.array(v.string()).optional().describe("The tokens of any child Budgets when creating a hierarchical Budget."),periods:v.array(CM).optional().describe("The periods for the Budget. The start_at and end_at must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.")},async execute(e,t){let r=await t.callVantageApi("/v2/budgets",e,"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var AM=`
53
+ `.trim(),L4=g.object({start_at:$e("The start date of the period."),end_at:$e("The end date of the period.").optional(),amount:g.number().min(0).describe("The amount of the period.")}),wH=j({name:"create-budget",description:V4,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{name:g.string().min(1).describe("The name of the Budget."),workspace_token:g.string().optional().describe("The token of the Workspace to add the Budget to."),cost_report_token:g.string().optional().describe("The CostReport token. Ignored for hierarchical Budgets."),child_budget_tokens:g.array(g.string()).optional().describe("The tokens of any child Budgets when creating a hierarchical Budget."),periods:g.array(L4).optional().describe("The periods for the Budget. The start_at and end_at must be iso8601 formatted e.g. YYYY-MM-DD. Ignored for hierarchical Budgets.")},async execute(e,t){let r=await t.callVantageApi("/v2/budgets",e,"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var F4=`
54
54
  Creates a cost alert based on the parameters specified. Cost alerts notify you when spending on one or more cost reports exceeds a specified threshold over a given interval.
55
- `.trim(),n3=C({name:"create-cost-alert",description:AM,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:v.string().min(1).max(255).describe("The title of the cost alert."),interval:v.enum(["day","week","month","quarter"]).describe("The interval for the cost alert."),threshold:v.number().gt(0).describe("The threshold amount that triggers the alert. Must be greater than 0."),unit_type:v.enum(["currency","percentage"]).describe("The unit type for the threshold."),workspace_token:v.string().describe("The token of the Workspace to add the cost alert to."),report_tokens:v.array(v.string()).min(1).max(10).describe("The tokens of the cost reports to monitor. Between 1 and 10 report tokens."),email_recipients:v.array(v.string()).optional().describe("Email addresses to notify when the alert triggers."),slack_channels:v.array(v.string()).optional().describe("Slack channels to notify when the alert triggers."),teams_channels:v.array(v.string()).optional().describe("Microsoft Teams channels to notify when the alert triggers."),minimum_threshold:v.number().min(0).optional().describe("Minimum threshold amount. Only applicable for percentage unit_type.")},async execute(e,t){let r=await t.callVantageApi("/v2/cost_alerts",e,"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var DM=`
55
+ `.trim(),PH=j({name:"create-cost-alert",description:F4,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:g.string().min(1).max(255).describe("The title of the cost alert."),interval:g.enum(["day","week","month","quarter"]).describe("The interval for the cost alert."),threshold:g.number().gt(0).describe("The threshold amount that triggers the alert. Must be greater than 0."),unit_type:g.enum(["currency","percentage"]).describe("The unit type for the threshold."),workspace_token:g.string().describe("The token of the Workspace to add the cost alert to."),report_tokens:g.array(g.string()).min(1).max(10).describe("The tokens of the cost reports to monitor. Between 1 and 10 report tokens."),email_recipients:g.array(g.string()).optional().describe("Email addresses to notify when the alert triggers."),slack_channels:g.array(g.string()).optional().describe("Slack channels to notify when the alert triggers."),teams_channels:g.array(g.string()).optional().describe("Microsoft Teams channels to notify when the alert triggers."),minimum_threshold:g.number().min(0).optional().describe("Minimum threshold amount. Only applicable for percentage unit_type.")},async execute(e,t){let r=await t.callVantageApi("/v2/cost_alerts",e,"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var G4=`
56
56
  Create a new Cost Report in Vantage.
57
57
 
58
58
  Cost Reports are saved queries that can be used to track and analyze spending over time. They can be filtered using VQL (Vantage Query Language) and configured with various display options.
@@ -77,7 +77,7 @@ Tag Filtering:
77
77
  - Multiple tag values: (costs.provider = 'aws' AND tags.name = 'environment' AND (tags.value = 'dev' OR tags.value = 'staging'))
78
78
 
79
79
  Use get-myself to find available workspaces and list-cost-providers/list-cost-services to find valid provider and service names for your VQL queries.
80
- `.trim(),qM=v.object({business_metric_token:v.string().min(1).describe("The token of the BusinessMetric to attach to the CostReport."),unit_scale:v.enum(["per_unit","per_hundred","per_thousand","per_million","per_billion"]).default("per_unit").describe("Determines the scale of the BusinessMetric's values within the CostReport."),label_filter:v.array(v.string()).optional().describe("Include only values with these labels in the CostReport.")}),MM=v.object({include_credits:v.boolean().default(!1).describe("Report will include credits."),include_refunds:v.boolean().default(!1).describe("Report will include refunds."),include_discounts:v.boolean().default(!0).describe("Report will include discounts."),include_tax:v.boolean().default(!0).describe("Report will include tax."),amortize:v.boolean().default(!0).describe("Report will amortize."),unallocated:v.boolean().default(!1).describe("Report will show unallocated costs."),aggregate_by:v.enum(["cost","usage"]).default("cost").describe("Report will aggregate by cost or usage."),show_previous_period:v.boolean().default(!0).describe("Report will show previous period costs or usage comparison.")}),UM=["this_month","last_7_days","last_30_days","last_month","last_3_months","last_6_months","custom","last_12_months","last_24_months","last_36_months","next_month","next_3_months","next_6_months","next_12_months","year_to_date","last_3_days","last_14_days"],ZM=["area","line","bar","multi_bar","pie"],LM=v.object({x_axis_dimension:v.array(v.string()).optional().describe("The dimension used to group or label data along the x-axis (e.g., by date, region, or service). NOTE: Only one value is allowed at this time. Defaults to ['date']."),y_axis_dimension:v.string().optional().describe("The metric or measure displayed on the chart\u2019s y-axis. Possible values: 'cost', 'usage'. Defaults to 'cost'.")}),u3=C({name:"create-cost-report",description:DM,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:v.string().min(1).describe("Title for the new Cost Report"),workspace_token:v.string().optional().describe("The token of the Workspace to add the Cost Report to. Ignored if 'folder_token' is set. Required if the API token is associated with multiple Workspaces."),groupings:v.array(v.string()).optional().transform(e=>e?.join(",")).describe("Grouping values for aggregating costs on the report. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>."),filter:v.string().optional().describe("VQL filter to apply to the Cost Report"),saved_filter_tokens:v.array(v.string()).optional().describe("The tokens of the SavedFilters to apply to the CostReport."),business_metric_tokens_with_metadata:v.array(qM).optional().describe("The tokens for any BusinessMetrics to attach to the CostReport, and the unit scale."),folder_token:v.string().optional().describe("The token of the Folder to add the CostReport to. Determines the Workspace the report is assigned to."),settings:MM.optional().describe("Report settings."),previous_period_start_date:be("The previous period start date of the CostReport. ISO 8601 Formatted.").optional(),previous_period_end_date:be("The previous period end date of the CostReport. ISO 8601 Formatted.").optional(),start_date:be("The start date of the CostReport. ISO 8601 Formatted. Incompatible with 'date_interval' parameter.").optional(),end_date:be("The end date of the CostReport. ISO 8601 Formatted. Incompatible with 'date_interval' parameter, required with 'start_date'.").optional(),date_interval:v.enum(UM).optional().describe("The date interval of the CostReport. Incompatible with 'start_date' and 'end_date' parameters. Defaults to 'this_month' if start_date and end_date are not provided."),chart_type:v.enum(ZM).optional().describe("The chart type to use in the CostReport. Defaults to 'line' if not provided."),chart_settings:LM.optional().describe("Report chart settings.")},async execute(e,t){let r=await t.callVantageApi("/v2/cost_reports",{...e,previous_period_end_date:e.previous_period_end_date,end_date:e.end_date},"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var VM=`
80
+ `.trim(),W4=g.object({business_metric_token:g.string().min(1).describe("The token of the BusinessMetric to attach to the CostReport."),unit_scale:g.enum(["per_unit","per_hundred","per_thousand","per_million","per_billion"]).default("per_unit").describe("Determines the scale of the BusinessMetric's values within the CostReport."),label_filter:g.array(g.string()).optional().describe("Include only values with these labels in the CostReport.")}),K4=g.object({include_credits:g.boolean().default(!1).describe("Report will include credits."),include_refunds:g.boolean().default(!1).describe("Report will include refunds."),include_discounts:g.boolean().default(!0).describe("Report will include discounts."),include_tax:g.boolean().default(!0).describe("Report will include tax."),amortize:g.boolean().default(!0).describe("Report will amortize."),unallocated:g.boolean().default(!1).describe("Report will show unallocated costs."),aggregate_by:g.enum(["cost","usage"]).default("cost").describe("Report will aggregate by cost or usage."),show_previous_period:g.boolean().default(!0).describe("Report will show previous period costs or usage comparison.")}),H4=["this_month","last_7_days","last_30_days","last_month","last_3_months","last_6_months","custom","last_12_months","last_24_months","last_36_months","next_month","next_3_months","next_6_months","next_12_months","year_to_date","last_3_days","last_14_days"],J4=["area","line","bar","multi_bar","pie"],B4=g.object({x_axis_dimension:g.array(g.string()).optional().describe("The dimension used to group or label data along the x-axis (e.g., by date, region, or service). NOTE: Only one value is allowed at this time. Defaults to ['date']."),y_axis_dimension:g.string().optional().describe("The metric or measure displayed on the chart\u2019s y-axis. Possible values: 'cost', 'usage'. Defaults to 'cost'.")}),NH=j({name:"create-cost-report",description:G4,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:g.string().min(1).describe("Title for the new Cost Report"),workspace_token:g.string().optional().describe("The token of the Workspace to add the Cost Report to. Ignored if 'folder_token' is set. Required if the API token is associated with multiple Workspaces."),groupings:g.array(g.string()).optional().transform(e=>e?.join(",")).describe("Grouping values for aggregating costs on the report. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>."),filter:g.string().optional().describe("VQL filter to apply to the Cost Report"),saved_filter_tokens:g.array(g.string()).optional().describe("The tokens of the SavedFilters to apply to the CostReport."),business_metric_tokens_with_metadata:g.array(W4).optional().describe("The tokens for any BusinessMetrics to attach to the CostReport, and the unit scale."),folder_token:g.string().optional().describe("The token of the Folder to add the CostReport to. Determines the Workspace the report is assigned to."),settings:K4.optional().describe("Report settings."),previous_period_start_date:$e("The previous period start date of the CostReport. ISO 8601 Formatted.").optional(),previous_period_end_date:$e("The previous period end date of the CostReport. ISO 8601 Formatted.").optional(),start_date:$e("The start date of the CostReport. ISO 8601 Formatted. Incompatible with 'date_interval' parameter.").optional(),end_date:$e("The end date of the CostReport. ISO 8601 Formatted. Incompatible with 'date_interval' parameter, required with 'start_date'.").optional(),date_interval:g.enum(H4).optional().describe("The date interval of the CostReport. Incompatible with 'start_date' and 'end_date' parameters. Defaults to 'this_month' if start_date and end_date are not provided."),chart_type:g.enum(J4).optional().describe("The chart type to use in the CostReport. Defaults to 'line' if not provided."),chart_settings:B4.optional().describe("Report chart settings.")},async execute(e,t){let r=await t.callVantageApi("/v2/cost_reports",{...e,previous_period_end_date:e.previous_period_end_date,end_date:e.end_date},"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var Y4=`
81
81
  Create a new Dashboard in Vantage.
82
82
 
83
83
  Dashboards are collections of widgets that visualize cost data. You can optionally attach widgets (by
@@ -97,10 +97,10 @@ The list of supported widgets is:
97
97
 
98
98
  The token returned in the response can be used to link to the Dashboard in the Vantage Web UI:
99
99
  https://console.vantage.sh/go/<token>
100
- `.trim(),FM=["this_month","last_7_days","last_30_days","last_month","last_3_months","last_6_months","custom","last_12_months","last_24_months","last_36_months","next_month","next_3_months","next_6_months","next_12_months","year_to_date","last_3_days","last_14_days"],GM=v.object({widgetable_token:v.string().describe("The token of the represented Resource."),title:v.string().describe("The title of the Widget (defaults to the title of the Resource).").optional(),settings:v.object({display_type:v.enum(["table","chart"]).describe("The display type of the Widget.")}).optional()}),h3=C({name:"create-dashboard",description:VM,args:{title:v.string().min(1).describe("The title of the dashboard"),workspace_token:v.string().min(1).describe("The token of the Workspace to add the Dashboard to."),widgets:v.array(GM).describe("The widgets to add to the dashboard").optional(),saved_filter_tokens:v.array(v.string()).describe("The tokens of the Saved Filters used in the Dashboard").optional(),date_bin:v.enum(["day","week","month"]).optional().describe("Date binning for returned costs, allowed values: day, week, month"),start_date:be("The start date of the dashboard. ISO 8601 Formatted. Incompatible with 'date_interval' parameter.").optional(),end_date:be("The end date of the dashboard. ISO 8601 Formatted. Incompatible with 'date_interval' parameter, required with 'start_date'.").optional(),date_interval:v.enum(FM).optional().describe("The date interval of the dashboard. Incompatible with 'start_date' and 'end_date' parameters.")},annotations:{destructive:!1,openWorld:!1,readOnly:!1},async execute(e,t){let r=await t.callVantageApi("/v2/dashboards",e,"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var WM=`
100
+ `.trim(),X4=["this_month","last_7_days","last_30_days","last_month","last_3_months","last_6_months","custom","last_12_months","last_24_months","last_36_months","next_month","next_3_months","next_6_months","next_12_months","year_to_date","last_3_days","last_14_days"],Q4=g.object({widgetable_token:g.string().describe("The token of the represented Resource."),title:g.string().describe("The title of the Widget (defaults to the title of the Resource).").optional(),settings:g.object({display_type:g.enum(["table","chart"]).describe("The display type of the Widget.")}).optional()}),MH=j({name:"create-dashboard",description:Y4,args:{title:g.string().min(1).describe("The title of the dashboard"),workspace_token:g.string().min(1).describe("The token of the Workspace to add the Dashboard to."),widgets:g.array(Q4).describe("The widgets to add to the dashboard").optional(),saved_filter_tokens:g.array(g.string()).describe("The tokens of the Saved Filters used in the Dashboard").optional(),date_bin:g.enum(["day","week","month"]).optional().describe("Date binning for returned costs, allowed values: day, week, month"),start_date:$e("The start date of the dashboard. ISO 8601 Formatted. Incompatible with 'date_interval' parameter.").optional(),end_date:$e("The end date of the dashboard. ISO 8601 Formatted. Incompatible with 'date_interval' parameter, required with 'start_date'.").optional(),date_interval:g.enum(X4).optional().describe("The date interval of the dashboard. Incompatible with 'start_date' and 'end_date' parameters.")},annotations:{destructive:!1,openWorld:!1,readOnly:!1},async execute(e,t){let r=await t.callVantageApi("/v2/dashboards",e,"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var eU=`
101
101
  Create a Folder for organizing Cost Reports. Folders can be nested by specifying a parent_folder_token.
102
102
  SavedFilters can be applied to the Folder so that any Cost Report within it inherits those filters.
103
- `.trim(),$3=C({name:"create-folder",description:WM,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:v.string().min(1).describe("The title of the Folder."),parent_folder_token:v.string().optional().describe("The token of the parent Folder to nest this Folder under."),saved_filter_tokens:v.array(v.string()).optional().describe("The tokens of SavedFilters to apply to any Cost Report contained within the Folder."),workspace_token:v.string().optional().describe("The token of the Workspace to add the Folder to. Ignored if 'parent_folder_token' is set. Required if the API token is associated with multiple Workspaces.")},async execute(e,t){let r=await t.callVantageApi("/v2/folders",e,"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var KM=`
103
+ `.trim(),FH=j({name:"create-folder",description:eU,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{title:g.string().min(1).describe("The title of the Folder."),parent_folder_token:g.string().optional().describe("The token of the parent Folder to nest this Folder under."),saved_filter_tokens:g.array(g.string()).optional().describe("The tokens of SavedFilters to apply to any Cost Report contained within the Folder."),workspace_token:g.string().optional().describe("The token of the Workspace to add the Folder to. Ignored if 'parent_folder_token' is set. Required if the API token is associated with multiple Workspaces.")},async execute(e,t){let r=await t.callVantageApi("/v2/folders",e,"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var tU=`
104
104
  Create a Virtual Tag Config in Vantage.
105
105
 
106
106
  Virtual Tag Configs define a derived (virtual) tag key and a set of values determined by VQL filters.
@@ -111,22 +111,33 @@ You can optionally:
111
111
  - backfill_until: backfill the virtual tag values to an earliest month
112
112
  - collapsed_tag_keys: collapse values for specific underlying tag keys (optionally scoped by provider)
113
113
  - values: define named values via VQL filters, optionally linked to Business Metrics and/or cost metrics
114
- `.trim(),HM=v.object({key:v.string().describe("The tag key to collapse values for."),providers:v.array(v.string()).describe("The providers this collapsed tag key applies to.").optional()}),JM=v.object({filter:v.string().describe("The filter VQL for the Value."),name:v.string().describe("The name of the Value.").optional(),business_metric_token:v.string().describe("The token of the associated BusinessMetric.").optional(),cost_metric:v.object({filter:v.string().describe("The filter VQL for the cost metric."),aggregation:v.object({tag:v.string().describe("The tag to aggregate on.")})}).optional()}),T3=C({name:"create-virtual-tag-config",description:KM,args:{key:v.string().min(1).describe("The key of the VirtualTagConfig"),overridable:v.boolean().describe("Whether the VirtualTagConfig can override a provider-supplied tag on a matching Cost."),backfill_until:be("The earliest month the VirtualTagConfig should be backfilled to. ISO 8601 Formatted.").optional(),collapsed_tag_keys:v.array(HM).optional(),values:v.array(JM).optional()},annotations:{destructive:!1,openWorld:!1,readOnly:!1},async execute(e,t){let r=await t.callVantageApi("/v2/virtual_tag_configs",e,"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});var SS=Vt(Rr());var YU=`
114
+ `.trim(),rU=g.object({key:g.string().describe("The tag key to collapse values for."),providers:g.array(g.string()).describe("The providers this collapsed tag key applies to.").optional()}),nU=g.object({filter:g.string().describe("The filter VQL for the Value."),name:g.string().describe("The name of the Value.").optional(),business_metric_token:g.string().describe("The token of the associated BusinessMetric.").optional(),cost_metric:g.object({filter:g.string().describe("The filter VQL for the cost metric."),aggregation:g.object({tag:g.string().describe("The tag to aggregate on.")})}).optional()}),BH=j({name:"create-virtual-tag-config",description:tU,args:{key:g.string().min(1).describe("The key of the VirtualTagConfig"),overridable:g.boolean().describe("Whether the VirtualTagConfig can override a provider-supplied tag on a matching Cost."),backfill_until:$e("The earliest month the VirtualTagConfig should be backfilled to. ISO 8601 Formatted.").optional(),collapsed_tag_keys:g.array(rU).optional(),values:g.array(nU).optional()},annotations:{destructive:!1,openWorld:!1,readOnly:!1},async execute(e,t){let r=await t.callVantageApi("/v2/virtual_tag_configs",e,"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var TS=Ge(ct());var iZ=`
115
+ Deletes a cost report by its token. This action is irreversible.
116
+ `.trim(),sZ={cost_report_token:g.string().describe("Token of the cost report to delete")},HJ=j({name:"delete-cost-report",description:iZ,annotations:{destructive:!0,openWorld:!1,readOnly:!1},args:sZ,async execute(e,t){let r=await t.callVantageApi(`/v2/cost_reports/${(0,TS.pathEncode)(e.cost_report_token)}`,{},"DELETE");if(!r.ok)throw new I({errors:r.errors});return{token:e.cost_report_token}}});var PS=Ge(ct());var aZ=`
117
+ Deletes a Folder. Cost Reports within the Folder will not be deleted.
118
+ `.trim(),QJ=j({name:"delete-folder",description:aZ,annotations:{destructive:!0,openWorld:!1,readOnly:!1},args:{folder_token:g.string().describe("The token of the folder to delete")},async execute(e,t){let r=await t.callVantageApi(`/v2/folders/${(0,PS.pathEncode)(e.folder_token)}`,{},"DELETE");if(!r.ok)throw new I({errors:r.errors});return{token:e.folder_token}}});var zS=Ge(ct());var cZ=`
119
+ Gets a specific anomaly alert by its token.
120
+ `.trim(),uZ={anomaly_alert_token:g.string().describe("The anomaly alert token to retrieve")},oB=j({name:"get-anomaly",description:cZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:uZ,async execute(e,t){let r=await t.callVantageApi(`/v2/anomaly_alerts/${(0,zS.pathEncode)(e.anomaly_alert_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var ES=Ge(ct());var lZ=`
115
121
  Gets a specific cost alert by its token.
116
- `.trim(),XU={cost_alert_token:v.string().describe("The cost alert token to retrieve")},xJ=C({name:"get-cost-alert",description:YU,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:XU,async execute(e,t){let r=await t.callVantageApi(`/v2/cost_alerts/${(0,SS.pathEncode)(e.cost_alert_token)}`,{},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var QU=`
122
+ `.trim(),dZ={cost_alert_token:g.string().describe("The cost alert token to retrieve")},uB=j({name:"get-cost-alert",description:lZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:dZ,async execute(e,t){let r=await t.callVantageApi(`/v2/cost_alerts/${(0,ES.pathEncode)(e.cost_alert_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var pZ=`
117
123
  Get the list of Cost Provider Accounts that the current user has access to in their workspace and their names.
118
124
  This is useful for mapping IDs you have gotten from other endpoints to human-readable names, or if you need to get the
119
125
  ID of a Cost Provider Account to use in places. The account_id in this result can be passed as the account_id in VQL queries.
120
- `.trim(),EJ=C({name:"get-cost-provider-accounts",description:QU,args:{workspace_token:v.string().describe("Workspace token to list cost provider accounts for"),account_id:v.string().optional().describe("Filter by a specific account ID"),provider:v.string().optional().describe("Provider to filter provider accounts to")},annotations:{destructive:!1,openWorld:!1,readOnly:!0},async execute(e,t){let r=await t.callVantageApi("/v2/cost_provider_accounts",{...e,provider:e.provider},"GET");if(!r.ok)throw new R({errors:r.errors});return{cost_provider_accounts:r.data.cost_provider_accounts}}});var PS=Vt(Rr());function eZ(e){let r=new URL(e).searchParams.get("page");return r?Number.parseInt(r,10):0}var TS={nextPage:0,hasNextPage:!1};function X(e){let t=e?.links?.next;if(!t)return TS;let r=eZ(t);return r===0?TS:{nextPage:r,hasNextPage:!0}}var tZ=`
126
+ `.trim(),mB=j({name:"get-cost-provider-accounts",description:pZ,args:{workspace_token:g.string().describe("Workspace token to list cost provider accounts for"),account_id:g.string().optional().describe("Filter by a specific account ID"),provider:g.string().optional().describe("Provider to filter provider accounts to")},annotations:{destructive:!1,openWorld:!1,readOnly:!0},async execute(e,t){let r=await t.callVantageApi("/v2/cost_provider_accounts",{...e,provider:e.provider},"GET");if(!r.ok)throw new I({errors:r.errors});return{cost_provider_accounts:r.data.cost_provider_accounts}}});var OS=Ge(ct());function fZ(e){let r=new URL(e).searchParams.get("page");return r?Number.parseInt(r,10):0}var IS={nextPage:0,hasNextPage:!1};function X(e){let t=e?.links?.next;if(!t)return IS;let r=fZ(t);return r===0?IS:{nextPage:r,hasNextPage:!0}}var mZ=`
121
127
  Given a Cost Report Token, Vantage can forecast the costs for a given time range. Vantage will return costs that are *predicted*, but have not yet been actually incurred.
122
128
  If the user does not set a date, best to pick the next month as the default.
123
129
  The report token can be used to link the user to the report in the Vantage Web UI. Build the link like this: https://console.vantage.sh/go/<CostReportToken>
124
- `.trim(),rZ={cost_report_token:v.string().min(1).describe("Cost report to limit costs to"),page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),start_date:be("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:be("End date to filter costs by, format=YYYY-MM-DD").optional(),provider:v.string().optional().describe("Provider to filter costs by, refer to the list-cost-providers tool"),service:v.string().optional().describe("Service to filter costs by, refer to the list-cost-services tool, must pass a provider when you pass a service")},qJ=C({name:"get-cost-report-forecast",description:tZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:rZ,async execute(e,t){let r={...e,limit:128,provider:e.provider},o=await t.callVantageApi(`/v2/cost_reports/${(0,PS.pathEncode)(e.cost_report_token)}/forecasted_costs`,r,"GET");if(!o.ok)throw new R({errors:o.errors});return{forecasted_costs:o.data.forecasted_costs,pagination:X(o.data)}}});var nZ=`
130
+ `.trim(),hZ={cost_report_token:g.string().min(1).describe("Cost report to limit costs to"),page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),start_date:$e("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:$e("End date to filter costs by, format=YYYY-MM-DD").optional(),provider:g.string().optional().describe("Provider to filter costs by, refer to the list-cost-providers tool"),service:g.string().optional().describe("Service to filter costs by, refer to the list-cost-services tool, must pass a provider when you pass a service")},kB=j({name:"get-cost-report-forecast",description:mZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:hZ,async execute(e,t){let r={...e,limit:128,provider:e.provider},o=await t.callVantageApi(`/v2/cost_reports/${(0,OS.pathEncode)(e.cost_report_token)}/forecasted_costs`,r,"GET");if(!o.ok)throw new I({errors:o.errors});return{forecasted_costs:o.data.forecasted_costs,pagination:X(o.data)}}});var jS=Ge(ct());var gZ=`
131
+ Gets a specific cost report by its token. The token of a report can be used to generate a link to the report in the Vantage Web UI: https://console.vantage.sh/go/<token>
132
+ The same token can be used with the get-cost-report-forecast tool to retrieve forecasted future costs for the report.
133
+ `.trim(),vZ={cost_report_token:g.string().describe("The cost report token to retrieve")},zB=j({name:"get-cost-report",description:gZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:vZ,async execute(e,t){let r=await t.callVantageApi(`/v2/cost_reports/${(0,jS.pathEncode)(e.cost_report_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var NS=Ge(ct());var _Z=`
134
+ Gets a specific Folder by its token.
135
+ `.trim(),NB=j({name:"get-folder",description:_Z,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:{folder_token:g.string().describe("The token of the folder to retrieve")},async execute(e,t){let r=await t.callVantageApi(`/v2/folders/${(0,NS.pathEncode)(e.folder_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var yZ=`
125
136
  Get data that is available to the current auth token.
126
137
  This includes the list of Workspaces they have access to.
127
138
 
128
139
  default_workspace_token: The token of the workspace that is set as the default workspace for the user and can be used for queries unless told otherwise.
129
- `.trim(),oZ={},LJ=C({name:"get-myself",description:nZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:oZ,async execute(e,t){let r=await t.callVantageApi("/v2/me",{},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var zS=Vt(Rr());var iZ=`
140
+ `.trim(),bZ={},DB=j({name:"get-myself",description:yZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:bZ,async execute(e,t){let r=await t.callVantageApi("/v2/me",{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var RS=Ge(ct());var $Z=`
130
141
  Get detailed information about a specific provider resource using its token or UUID.
131
142
 
132
143
  This returns comprehensive details about the resource including:
@@ -138,7 +149,7 @@ This returns comprehensive details about the resource including:
138
149
 
139
150
  The resource_token can be either a Vantage token (starting with prvdr_rsrc) or the resource's UUID/ARN from the cloud provider.
140
151
  Set include_cost to true to get cost information broken down by category.
141
- `.trim(),KJ=C({name:"get-provider-resource",description:iZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:{resource_token:v.string().nonempty().describe("The resource token (prvdr_rsrc_*) or UUID/ARN of the resource"),include_cost:v.boolean().optional().default(!1).describe("Include cost information broken down by category")},async execute(e,t){let r=await t.callVantageApi(`/v2/resources/${(0,zS.pathEncode)(e.resource_token)}`,{include_cost:e.include_cost},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var ES=Vt(Rr());var sZ=`
152
+ `.trim(),VB=j({name:"get-provider-resource",description:$Z,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:{resource_token:g.string().nonempty().describe("The resource token (prvdr_rsrc_*) or UUID/ARN of the resource"),include_cost:g.boolean().optional().default(!1).describe("Include cost information broken down by category")},async execute(e,t){let r=await t.callVantageApi(`/v2/resources/${(0,RS.pathEncode)(e.resource_token)}`,{include_cost:e.include_cost},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var CS=Ge(ct());var wZ=`
142
153
  Get comprehensive details about a specific cost optimization recommendation using its unique token.
143
154
 
144
155
  This tool provides in-depth information about a single recommendation including:
@@ -155,7 +166,7 @@ This tool provides in-depth information about a single recommendation including:
155
166
  Use this tool after getting a recommendation token from list-recommendations to understand exactly what optimization is being suggested and the potential impact.
156
167
 
157
168
  The recommendation token can also be used with get-recommendation-resources to see the specific infrastructure resources involved.
158
- `.trim(),aZ={recommendation_token:v.string().min(1).describe("The token of the recommendation to get details for")},XJ=C({name:"get-recommendation-details",description:sZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:aZ,async execute(e,t){let r=await t.callVantageApi(`/v2/recommendations/${(0,ES.pathEncode)(e.recommendation_token)}`,{},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var l_=Vt(Rr());var cZ=`
169
+ `.trim(),kZ={recommendation_token:g.string().min(1).describe("The token of the recommendation to get details for")},KB=j({name:"get-recommendation-details",description:wZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:kZ,async execute(e,t){let r=await t.callVantageApi(`/v2/recommendations/${(0,CS.pathEncode)(e.recommendation_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var d_=Ge(ct());var xZ=`
159
170
  Get comprehensive details about a specific infrastructure resource within a cost optimization recommendation, including the exact actions recommended for that resource.
160
171
 
161
172
  This tool provides the deepest level of detail about a single resource that's part of a recommendation. The response includes:
@@ -177,7 +188,7 @@ Use this tool when you need to understand exactly what should be done with a spe
177
188
  This is the most granular level of recommendation data available and is essential for making informed decisions about implementing specific optimizations.
178
189
 
179
190
  You must have both the recommendation token (from list-recommendations) and the resource token (from get-recommendation-resources) to use this tool.
180
- `.trim(),uZ={recommendation_token:v.string().min(1).describe("The token of the recommendation"),resource_token:v.string().min(1).describe("The token of the specific resource to get details for")},nB=C({name:"get-recommendation-resource-details",description:cZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:uZ,async execute(e,t){let r=await t.callVantageApi(`/v2/recommendations/${(0,l_.pathEncode)(e.recommendation_token)}/resources/${(0,l_.pathEncode)(e.resource_token)}`,{},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var IS=Vt(Rr());var lZ=`
191
+ `.trim(),SZ={recommendation_token:g.string().min(1).describe("The token of the recommendation"),resource_token:g.string().min(1).describe("The token of the specific resource to get details for")},XB=j({name:"get-recommendation-resource-details",description:xZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:SZ,async execute(e,t){let r=await t.callVantageApi(`/v2/recommendations/${(0,d_.pathEncode)(e.recommendation_token)}/resources/${(0,d_.pathEncode)(e.resource_token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var AS=Ge(ct());var TZ=`
181
192
  Get a paginated list of all infrastructure resources affected by a specific cost optimization recommendation.
182
193
 
183
194
  This tool returns the actual cloud resources (instances, volumes, load balancers, etc.) that are involved in a recommendation. Each resource entry includes:
@@ -196,16 +207,16 @@ Use this tool after getting recommendation details to see exactly which resource
196
207
  Each resource has its own token that can be used with get-recommendation-resource-details to get comprehensive information about that specific resource and what actions are recommended.
197
208
 
198
209
  Use pagination (page parameter) to navigate through large numbers of affected resources.
199
- `.trim(),dZ={recommendation_token:v.string().min(1).describe("The token of the recommendation to get resources for"),page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},lB=C({name:"get-recommendation-resources",description:lZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:dZ,async execute(e,t){let r={page:e.page,limit:128},o=await t.callVantageApi(`/v2/recommendations/${(0,IS.pathEncode)(e.recommendation_token)}/resources`,r,"GET");if(!o.ok)throw new R({errors:o.errors});return{resources:o.data.resources,pagination:X(o.data)}}});var jS=Vt(Rr());var pZ=`
210
+ `.trim(),PZ={recommendation_token:g.string().min(1).describe("The token of the recommendation to get resources for"),page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},i5=j({name:"get-recommendation-resources",description:TZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:PZ,async execute(e,t){let r={page:e.page,limit:128},o=await t.callVantageApi(`/v2/recommendations/${(0,AS.pathEncode)(e.recommendation_token)}/resources`,r,"GET");if(!o.ok)throw new I({errors:o.errors});return{resources:o.data.resources,pagination:X(o.data)}}});var DS=Ge(ct());var zZ=`
200
211
  Gets a specific team with its token.
201
- `.trim(),fZ={token:v.string().describe("The team token to retrieve")},hB=C({name:"get-team",description:pZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:fZ,async execute(e,t){let r=await t.callVantageApi(`/v2/teams/${(0,jS.pathEncode)(e.token)}`,{},"GET");if(!r.ok)throw new R({errors:r.errors});return r.data}});var mZ=`
212
+ `.trim(),EZ={token:g.string().describe("The team token to retrieve")},l5=j({name:"get-team",description:zZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:EZ,async execute(e,t){let r=await t.callVantageApi(`/v2/teams/${(0,DS.pathEncode)(e.token)}`,{},"GET");if(!r.ok)throw new I({errors:r.errors});return r.data}});var IZ=`
202
213
  Return all Teams that the user has access to.
203
- `.trim(),hZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},wB=C({name:"get-teams",description:mZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:hZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/teams",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{teams:o.data.teams,pagination:X(o.data)}}});var gZ=`
214
+ `.trim(),OZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},v5=j({name:"get-teams",description:IZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:OZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/teams",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{teams:o.data.teams,pagination:X(o.data)}}});var jZ=`
204
215
  Return all Users that the user can see in the workspace.
205
- `.trim(),vZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},EB=C({name:"get-users",description:gZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:vZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/users",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{users:o.data.users,pagination:X(o.data)}}});var _Z=`
216
+ `.trim(),NZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},x5=j({name:"get-users",description:jZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:NZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/users",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{users:o.data.users,pagination:X(o.data)}}});var RZ=`
206
217
  Given a token of a Cost Report, look for anomalies in the report. You may optionally pass a Provider, like AWS to filter on. If you do pass a Provider, you can futher filter on a Service, like EC2 or S3.
207
218
  The report token can be used to link the user to the report in the Vantage Web UI. Build the link like this: https://console.vantage.sh/go/<CostReportToken>
208
- `.trim(),yZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),cost_report_token:v.string().optional().describe("Cost report to filter anomalies by"),service:v.string().optional().describe("Service to filter anomalies to"),provider:v.string().optional().describe("Provider to filter anomalies to"),cost_category:v.string().optional().describe("Cost category to filter anomalies to"),start_date:be("Start date to filter anomalies to").optional(),end_date:be("End date to filter anomalies to").optional()},DB=C({name:"list-anomalies",description:_Z,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:yZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/anomaly_alerts",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{anomaly_alerts:o.data.anomaly_alerts,pagination:X(o.data)}}});var $Z=`
219
+ `.trim(),CZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),cost_report_token:g.string().optional().describe("Cost report to filter anomalies by"),service:g.string().optional().describe("Service to filter anomalies to"),provider:g.string().optional().describe("Provider to filter anomalies to"),cost_category:g.string().optional().describe("Cost category to filter anomalies to"),start_date:$e("Start date to filter anomalies to").optional(),end_date:$e("End date to filter anomalies to").optional()},j5=j({name:"list-anomalies",description:RZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:CZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/anomaly_alerts",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{anomaly_alerts:o.data.anomaly_alerts,pagination:X(o.data)}}});var AZ=`
209
220
  List audit logs for actions taken within the Vantage workspace. Audit logs are a chronological record of all changes and activities that occur in your workspace, providing a complete history of who did what, when, and what changed.
210
221
 
211
222
  Audit logs track various types of actions including:
@@ -242,34 +253,34 @@ Common use cases for audit logs include:
242
253
  - Change management (reviewing modifications to reports or configurations)
243
254
  - Activity monitoring (understanding workspace usage patterns)
244
255
  - Distinguishing between human actions and autonomous agent actions (via scoutAction field and finops_agent source filter)
245
- `.trim(),bZ={page:v.number().optional().default(1).describe("The page of results to return, defaults to 1"),limit:v.number().int().min(1).max(1e3).optional().describe("The amount of results to return. The maximum is 1000. Defaults to 100."),user:v.number().int().optional().describe("Filter by personal or service API token that performed the action (user ID)"),workspace_token:v.string().optional().describe("Filter by workspace token"),action:v.string().optional().describe("Filter by action type (e.g., create, update, delete)"),object_name:v.string().optional().describe("Filter by object name"),source:v.string().optional().describe("Filter by source (e.g., console, api, developer, finops_agent). Use 'finops_agent' to filter for actions specifically taken by the Finops Agent."),object_type:v.string().optional().describe("Filter by object type (e.g., virtual_tag, cost_report, recommendation_commitment)."),token:v.string().optional().describe("Filter by audit log token"),object_token:v.string().optional().describe("Filter by object token (auditable_token)"),start_date:v.string().optional().describe("Filter by start date (ISO 8601 format) for the time period"),end_date:v.string().optional().describe("Filter by end date (ISO 8601 format) for the time period")},FB=C({name:"list-audit-logs",description:$Z,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:bZ,async execute(e,t){let r={...e,limit:e.limit??128},o=await t.callVantageApi("/v2/audit_logs",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{audit_logs:o.data.audit_logs,pagination:X(o.data)}}});var wZ=`
256
+ `.trim(),DZ={page:g.number().optional().default(1).describe("The page of results to return, defaults to 1"),limit:g.number().int().min(1).max(1e3).optional().describe("The amount of results to return. The maximum is 1000. Defaults to 100."),user:g.number().int().optional().describe("Filter by personal or service API token that performed the action (user ID)"),workspace_token:g.string().optional().describe("Filter by workspace token"),action:g.string().optional().describe("Filter by action type (e.g., create, update, delete)"),object_name:g.string().optional().describe("Filter by object name"),source:g.string().optional().describe("Filter by source (e.g., console, api, developer, finops_agent). Use 'finops_agent' to filter for actions specifically taken by the Finops Agent."),object_type:g.string().optional().describe("Filter by object type (e.g., virtual_tag, cost_report, recommendation_commitment)."),token:g.string().optional().describe("Filter by audit log token"),object_token:g.string().optional().describe("Filter by object token (auditable_token)"),start_date:g.string().optional().describe("Filter by start date (ISO 8601 format) for the time period"),end_date:g.string().optional().describe("Filter by end date (ISO 8601 format) for the time period")},M5=j({name:"list-audit-logs",description:AZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:DZ,async execute(e,t){let r={...e,limit:e.limit??128},o=await t.callVantageApi("/v2/audit_logs",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{audit_logs:o.data.audit_logs,pagination:X(o.data)}}});var qZ=`
246
257
  List all budgets available in the Vantage account. Budgets help track spending against predefined limits.
247
258
  Use the page value of 1 to start.
248
259
  A budget is built against a Cost Report. The Budget objects returned by this tool will have a "cost_report_token" field that contains the token of the Cost Report. The Cost Report has the "filter" field to know what is the range of providers & services that the budget is tracking.
249
260
  When a user is looking at a Cost Report for a specific date range, they can decide if the providers and services spend is higher than desired by looking at the budgets for that report and the date range of the budget.
250
261
  The token of a budget can be used to link the user to the budget in the Vantage Web UI. Build the link like this: https://console.vantage.sh/go/<BudgetToken>
251
- `.trim(),kZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},YB=C({name:"list-budgets",description:wZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:kZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/budgets",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{budgets:o.data.budgets,pagination:X(o.data)}}});var xZ=`
262
+ `.trim(),MZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},W5=j({name:"list-budgets",description:qZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:MZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/budgets",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{budgets:o.data.budgets,pagination:X(o.data)}}});var UZ=`
252
263
  List all cost alerts available in the Vantage account. Cost alerts notify you when spending exceeds a specified threshold for a given cost report.
253
264
  Use the page value of 1 to start.
254
- `.trim(),SZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},o5=C({name:"list-cost-alerts",description:xZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:SZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/cost_alerts",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{cost_alerts:o.data.cost_alerts,pagination:X(o.data)}}});var TZ=`
265
+ `.trim(),ZZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},Q5=j({name:"list-cost-alerts",description:UZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:ZZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/cost_alerts",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{cost_alerts:o.data.cost_alerts,pagination:X(o.data)}}});var VZ=`
255
266
  List all cost provider integrations available to provide costs data from and their associated accounts.
256
267
  Integrations are the cost providers that Vantage is configured to connect to and pull cost data from.
257
268
  If a user wants to see their providers in the Vantage Web UI, they can visit https://console.vantage.sh/settings/integrations
258
269
 
259
270
  Note that when 'provider' is 'custom_provider', that has a special case. When doing a VQL query for custom provider, use the 'token' you get back. Here is an example, where the token of the custom provider is "accss_crdntl_07171984":
260
271
  (costs.provider = 'custom_provider:accss_crdntl_07171984')
261
- `.trim(),PZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},d5=C({name:"list-cost-integrations",description:TZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:PZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/integrations",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{integrations:o.data.integrations,pagination:X(o.data)}}});var zZ=`
272
+ `.trim(),LZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},s7=j({name:"list-cost-integrations",description:VZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:LZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/integrations",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{integrations:o.data.integrations,pagination:X(o.data)}}});var FZ=`
262
273
  List of cost providers available to query for a given Workspace. Can be used to filter costs down to a specific provider in VQL queries.
263
- `.trim(),EZ={workspace_token:v.string().describe("Workspace token to list cost providers for")},v5=C({name:"list-cost-providers",description:zZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:EZ,async execute(e,t){let r=await t.callVantageApi("/v2/cost_providers",e,"GET");if(!r.ok)throw new R({errors:r.errors});return{providers:r.data.cost_providers,pagination:X(r.data)}}});var IZ=`
274
+ `.trim(),GZ={workspace_token:g.string().describe("Workspace token to list cost providers for")},p7=j({name:"list-cost-providers",description:FZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:GZ,async execute(e,t){let r=await t.callVantageApi("/v2/cost_providers",e,"GET");if(!r.ok)throw new I({errors:r.errors});return{providers:r.data.cost_providers,pagination:X(r.data)}}});var WZ=`
264
275
  List all cost reports available. Cost reports are already created reports authored by a user in Vantage. If the user isn't asking about a specific report, it's better to use the query-costs tool.
265
276
  When you first call this function, use the "Page" parameter of 1.
266
277
  The 'Title' of a report is a good way to know what the report is about.
267
278
  The 'filter' of a report also gives clues to the data it provides.
268
279
  The 'token' of a report is a unique identifier for the report. It can be used to generate a link to the report in the Vantage Web UI. If a user wants to see a report, you can link them like this: https://console.vantage.sh/go/<token>
269
280
  Vantage offers data related to a cost report: Forecasts. The same report token can be used on the get-cost-report-forecast tool and Vantage will forecast future costs.
270
- `.trim(),jZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},x5=C({name:"list-cost-reports",description:IZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:jZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/cost_reports",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{cost_reports:o.data.cost_reports,pagination:X(o.data)}}});var OZ=`
281
+ `.trim(),KZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},y7=j({name:"list-cost-reports",description:WZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:KZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/cost_reports",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{cost_reports:o.data.cost_reports,pagination:X(o.data)}}});var HZ=`
271
282
  List of cost services available to query for a given Workspace. Can be used to filter costs down to a specific service in VQL queries.
272
- `.trim(),NZ={workspace_token:v.string().describe("Workspace token to list cost services for")},E5=C({name:"list-cost-services",description:OZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:NZ,async execute(e,t){let r=await t.callVantageApi("/v2/cost_services",e,"GET");if(!r.ok)throw new R({errors:r.errors});return{cost_services:r.data.cost_services}}});var RZ=`
283
+ `.trim(),JZ={workspace_token:g.string().describe("Workspace token to list cost services for")},x7=j({name:"list-cost-services",description:HZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:JZ,async execute(e,t){let r=await t.callVantageApi("/v2/cost_services",e,"GET");if(!r.ok)throw new I({errors:r.errors});return{cost_services:r.data.cost_services}}});var BZ=`
273
284
  List the cost items inside a report. The Token of a Report must be provided. Use the page value of 1 to start.
274
285
  The report token can be used to link the user to the report in the Vantage Web UI. Build the link like this: https://console.vantage.sh/go/<CostReportToken>
275
286
 
@@ -278,17 +289,17 @@ When DateBin=day you get a record for each service spend on that day. For DateBi
278
289
  with the accrued_at field set to the first day of the week, but the spend item represents spend for a full week.
279
290
  Same with DateBin=month, each record returned covers a month of data. This lets you get answers with processing fewer
280
291
  records. Only use day/week if needed, otherwise DateBin=month is preferred, and month is the value set if you pass no value for DateBin.
281
- `.trim(),CZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),cost_report_token:v.string().describe("The workspace token to scope the query to"),start_date:be("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:be("End date to filter costs by, format=YYYY-MM-DD").optional(),date_bin:v.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),settings_include_credits:v.boolean().optional().default(!1).describe("Results will include credits, defaults to false"),settings_include_refunds:v.boolean().optional().default(!1).describe("Results will include refunds, defaults to false"),settings_include_discounts:v.boolean().optional().default(!0).describe("Results will include discounts, defaults to true"),settings_include_tax:v.boolean().optional().default(!0).describe("Results will include tax, defaults to true"),settings_amortize:v.boolean().optional().default(!0).describe("Results will amortize, defaults to true"),settings_unallocated:v.boolean().optional().default(!1).describe("Results will show unallocated costs, defaults to false"),settings_aggregate_by:v.enum(["cost","usage"]).optional().default("cost").describe("Results will aggregate by cost or usage, defaults to cost"),settings_show_previous_period:v.boolean().optional().default(!0).describe("Results will show previous period costs or usage comparison, defaults to true"),groupings:v.array(v.string()).default(["provider","service","account_id"]).describe("Group the results by specific field(s). Defaults to provider, service, account_id. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>. Let Groupings default unless explicitly asked for.")},D5=C({name:"list-costs",description:RZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:CZ,async execute(e,t){let r={limit:128};Object.keys(e).forEach(i=>{let s=i;if(i.startsWith("settings_")){let a=i.slice(9);r[`settings[${a}]`]=e[s]}else r[i]=e[s]});let o=await t.callVantageApi("/v2/costs",r,"GET");if(!o.ok)throw new R({errors:o.errors});let n;switch(e.date_bin){case"day":n="Costs records represent one day.";break;case"week":n="Costs records represent one week, the accrued_at field is the first day of the week. If your date range is less than one week, this record includes only data for that date range, not the full week.";break;case"month":n="Costs records represent one month, the accrued_at field is the first day of the month. If your date range is less than one month, this record includes only data for that date range, not the full month.";break;default:n="Costs records represent one day.";break}return{costs:o.data.costs,total_cost:o.data.total_cost,notes:n,pagination:X(o.data)}}});var AZ=`
292
+ `.trim(),YZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),cost_report_token:g.string().describe("The workspace token to scope the query to"),start_date:$e("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:$e("End date to filter costs by, format=YYYY-MM-DD").optional(),date_bin:g.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),settings_include_credits:g.boolean().optional().default(!1).describe("Results will include credits, defaults to false"),settings_include_refunds:g.boolean().optional().default(!1).describe("Results will include refunds, defaults to false"),settings_include_discounts:g.boolean().optional().default(!0).describe("Results will include discounts, defaults to true"),settings_include_tax:g.boolean().optional().default(!0).describe("Results will include tax, defaults to true"),settings_amortize:g.boolean().optional().default(!0).describe("Results will amortize, defaults to true"),settings_unallocated:g.boolean().optional().default(!1).describe("Results will show unallocated costs, defaults to false"),settings_aggregate_by:g.enum(["cost","usage"]).optional().default("cost").describe("Results will aggregate by cost or usage, defaults to cost"),settings_show_previous_period:g.boolean().optional().default(!0).describe("Results will show previous period costs or usage comparison, defaults to true"),groupings:g.array(g.string()).default(["provider","service","account_id"]).describe("Group the results by specific field(s). Defaults to provider, service, account_id. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>. Let Groupings default unless explicitly asked for.")},j7=j({name:"list-costs",description:BZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:YZ,async execute(e,t){let r={limit:128};Object.keys(e).forEach(i=>{let s=i;if(i.startsWith("settings_")){let a=i.slice(9);r[`settings[${a}]`]=e[s]}else r[i]=e[s]});let o=await t.callVantageApi("/v2/costs",r,"GET");if(!o.ok)throw new I({errors:o.errors});let n;switch(e.date_bin){case"day":n="Costs records represent one day.";break;case"week":n="Costs records represent one week, the accrued_at field is the first day of the week. If your date range is less than one week, this record includes only data for that date range, not the full week.";break;case"month":n="Costs records represent one month, the accrued_at field is the first day of the month. If your date range is less than one month, this record includes only data for that date range, not the full month.";break;default:n="Costs records represent one day.";break}return{costs:o.data.costs,total_cost:o.data.total_cost,notes:n,pagination:X(o.data)}}});var XZ=`
282
293
  List all dashboards available in the Vantage account. Dashboards provide visualizations of cost data.
283
294
  Use the page value of 1 to start.
284
295
  The token of a dashboard can be used to link the user to the dashboard in the Vantage Web UI. Build the link like this: https://console.vantage.sh/go/<token>
285
- `.trim(),DZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},V5=C({name:"list-dashboards",description:AZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:DZ,async execute(e,t){let r={...e,limit:64},o=await t.callVantageApi("/v2/dashboards",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{dashboards:o.data.dashboards,pagination:X(o.data)}}});var qZ=`
296
+ `.trim(),QZ={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},q7=j({name:"list-dashboards",description:XZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:QZ,async execute(e,t){let r={...e,limit:64},o=await t.callVantageApi("/v2/dashboards",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{dashboards:o.data.dashboards,pagination:X(o.data)}}});var e2=`
286
297
  List all Folders for organizing Cost Reports. Folders can be nested within other Folders via the parent_folder_token field.
287
298
  When you first call this function, use the "page" parameter of 1.
288
299
  The 'title' of a Folder describes its purpose.
289
300
  The 'saved_filter_tokens' field contains tokens of SavedFilters applied to Cost Reports within the Folder.
290
301
  The 'token' of a Folder can be used to generate a link in the Vantage Web UI: https://console.vantage.sh/go/<token>
291
- `.trim(),MZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},B5=C({name:"list-folders",description:qZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:MZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/folders",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{folders:o.data.folders,pagination:X(o.data)}}});var UZ=`
302
+ `.trim(),t2={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},G7=j({name:"list-folders",description:e2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:t2,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/folders",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{folders:o.data.folders,pagination:X(o.data)}}});var r2=`
292
303
  List infrastructure provider resources (instances, volumes, load balancers, etc.) from your cloud accounts.
293
304
  Resources can be fetched either from a specific Resource Report or by using VQL filters.
294
305
 
@@ -365,7 +376,7 @@ Use the page parameter starting with 1 for pagination.
365
376
 
366
377
  Resources include metadata specific to their type (EC2 instances show instance type, EBS volumes show size, etc.).
367
378
  Each resource has a unique token that can be used to get more details or link to the Vantage Web UI.
368
- `.trim(),r7=C({name:"list-provider-resources",description:UZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:{page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),resource_report_token:v.string().optional().describe("The ResourceReport token to get resources from"),filter:v.string().optional().describe("VQL query to filter resources (requires workspace_token)"),workspace_token:v.string().optional().describe("The Workspace token to scope the query to (required when using filter)"),include_cost:v.boolean().optional().default(!1).describe("Include cost information broken down by category for each resource")},async execute(e,t){let r=await t.callVantageApi("/v2/resources",e,"GET");if(!r.ok)throw new R({errors:r.errors});return{resources:r.data.resources,pagination:X(r.data)}}});var ZZ=`
379
+ `.trim(),Y7=j({name:"list-provider-resources",description:r2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:{page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),resource_report_token:g.string().optional().describe("The ResourceReport token to get resources from"),filter:g.string().optional().describe("VQL query to filter resources (requires workspace_token)"),workspace_token:g.string().optional().describe("The Workspace token to scope the query to (required when using filter)"),include_cost:g.boolean().optional().default(!1).describe("Include cost information broken down by category for each resource")},async execute(e,t){let r=await t.callVantageApi("/v2/resources",e,"GET");if(!r.ok)throw new I({errors:r.errors});return{resources:r.data.resources,pagination:X(r.data)}}});var n2=["aws","gcp","azure","kubernetes","datadog"],La={aws:"aws",amazon:"aws","amazon web services":"aws",gcp:"gcp",google:"gcp","google cloud":"gcp",azure:"azure","microsoft azure":"azure",kubernetes:"kubernetes",k8s:"kubernetes",datadog:"datadog"},o2=Object.keys(La).sort((e,t)=>t.length-e.length),i2={az_compute_reserved_instances:"azure:compute:reserved-instances",az_compute_reserved_instances_app_service:"azure:app-service:reserved-instances",az_compute_reserved_instances_cosmos:"azure:cosmosdb:reserved-instances",az_compute_reserved_instances_sql:"azure:sqldb:reserved-instances",az_disks_unattached:"azure:disks:unattached",cloudfront_cloudflare:"aws:cloudfront:excessive-egress",cw_log_retention_policy:"aws:cloudwatch:log-retention",database_savings_plan:"aws:database:savings-plan",datadog_financial_commitments:"datadog:commitment:opportunity",ebs_compute_optimizer_recommender:"aws:ebs:rightsizing",ebs_gp2_to_gp3:"aws:ebs:gp2-to-gp3",ebs_unattached_volume:"aws:ebs:unattached-volume",ec2_compute_optimizer_recommender:"aws:ec2:co-rightsizing",ec2_generational_upgrades:"aws:ec2:generational-upgrade",ec2_rightsizing_recommender:"aws:ec2:rightsizing",ec2_snapshot_recommender:"aws:ec2:snapshot-cleanup",ecs_compute_optimizer_recommender:"aws:ecs:rightsizing",eks_approaching_extended_support_window:"aws:eks:nearing-extended-support",eks_in_extended_support_window:"aws:eks:in-extended-support",elastic_search_reserved_instances:"aws:opensearch:reserved-instances",elasticache_reserved_instances:"aws:elasticache:reserved-instances",es_generational_upgrades:"aws:opensearch:generational-upgrade",gcp_compute_commitment_recommender:"gcp:compute:commitment",gcp_compute_rightsizing_recommender:"gcp:compute:rightsizing",idle_compute_optimizer_recommender:"idle-resource",ip_unattached:"aws:elastic-ip:unattached",kubernetes_recommender:"kubernetes:workload:rightsizing",lambda_compute_optimizer_recommender:"aws:lambda:rightsizing",rds_approaching_extended_support_window:"aws:rds:nearing-extended-support",rds_compute_optimizer_recommender:"aws:rds:rightsizing",rds_generational_upgrades:"aws:rds:generational-upgrade",rds_in_extended_support_window:"aws:rds:in-extended-support",rds_reserved_instances:"aws:rds:reserved-instances",redshift_reserved_instances:"aws:redshift:reserved-instances",s3_bucket_glacier_instant_retrieval:"aws:s3:glacier-instant-retrieval",s3_bucket_intelligent_tiering:"aws:s3:intelligent-tiering",s3_cloudflare:"aws:s3:egress-cloudflare",savings_plan:"aws:compute:savings-plan",unused_financial_commitments:"aws:ec2:unused-reserved-instances",workspace_stranded:"aws:workspaces:stranded",workspace_unused:"aws:workspaces:unused",azure_blob_storage_reserved_instances_recommender:"azure:blob-storage:reserved-instances",azure_compute_savings_recommender:"azure:compute:savings-plan",azure_files_reserved_instances_recommender:"azure:files:reserved-instances",azure_rightsizing_recommender:"azure:vm:rightsizing",azure_sql_paas_db_reserved_instances_recommender:"azure:sql-paas-db:reserved-instances",datadog_metrics_unqueried:"datadog:metrics:unqueried",dynamodb_reserved_capacity_recommender:"aws:dynamodb:reserved-capacity"},s2=e=>{if(typeof e!="string")return e;let t=e.trim().toLowerCase();return La[t]??t},a2=e=>{if(typeof e!="string")return e;let t=e.trim().toLowerCase();if(t=t.replace(/\brecommendations?\b/g,"").trim(),t=t.replace(/\s*:\s*/g,":"),t=t.replace(/\s+/g," ").trim(),!t)return;let r=i2[t];if(r)return r;let o=La[t];if(o)return o;if(t.includes(":")){let[n,...i]=t.split(":"),s=La[n];if(s){let a=i.join(":").trim();return a?`${s}:${a}`:s}return t}for(let n of o2)if(t.startsWith(`${n} `))return La[n];return t||void 0},c2=`
369
380
  List all cost optimization recommendations available in the Vantage account. Recommendations are AI-powered suggestions that help identify opportunities to reduce costs and optimize cloud spending across your infrastructure.
370
381
 
371
382
  Use the page value of 1 to start pagination.
@@ -380,24 +391,24 @@ Recommendations include various types such as:
380
391
  Each recommendation includes:
381
392
  - Potential cost savings amount
382
393
  - Description of what can be optimized
383
- - Category and provider information
394
+ - Provider and service information
384
395
  - Number of resources affected
385
396
  - Current status (open, resolved, dismissed)
386
397
 
387
- Recommendations can be filtered by status (open shows active recommendations, resolved shows implemented ones, dismissed shows ignored ones), cloud provider (aws, azure, gcp), specific workspace, provider account ID, and recommendation category.
398
+ Recommendations can be filtered by status (open shows active recommendations, resolved shows implemented ones, dismissed shows ignored ones), cloud provider (aws, azure, gcp), specific workspace, provider account ID, and recommendation type. Prefer the type parameter when users ask for broad families (e.g. "AWS recommendations" -> type=aws; "EC2 rightsizing" -> type=aws:ec2:rightsizing). The type filter uses case-insensitive fuzzy matching on the recommendation type.
388
399
 
389
400
  The token of each recommendation can be used with other recommendation tools to get detailed information and see specific resources affected.
390
401
 
391
402
  For users to view and manage recommendations in the Vantage Web UI, they can visit https://console.vantage.sh/recommendations
392
- `.trim(),LZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),workspace_token:v.string().optional().describe("Filter recommendations to a specific workspace"),provider:v.string().optional().describe("Filter recommendations by cloud provider (e.g., aws, azure, gcp)"),provider_account_id:v.string().optional().describe("Filter recommendations by provider account ID"),category:v.string().optional().describe("Filter recommendations by category (e.g., ec2_rightsizing_recommender, unused_financial_commitments)"),filter:v.enum(["open","resolved","dismissed"]).optional().describe("Filter recommendations by status: open (default), resolved, or dismissed")},u7=C({name:"list-recommendations",description:ZZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:LZ,async execute(e,t){let r={...e,limit:128,provider:e.provider,category:e.category},o=await t.callVantageApi("/v2/recommendations",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{recommendations:o.data.recommendations,pagination:X(o.data)}}});var OS=Vt(Rr());var VZ=`
403
+ `.trim(),u2={page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),workspace_token:g.string().optional().describe("Filter recommendations to a specific workspace"),provider:g.preprocess(s2,g.enum(n2).optional()).optional().describe("Filter recommendations by cloud provider (aws, gcp, azure, kubernetes, datadog). Aliases like 'Amazon Web Services' and 'Google Cloud' are normalized."),provider_account_id:g.string().optional().describe("Filter recommendations by provider account ID"),type:g.preprocess(a2,g.string().max(255).optional()).optional().describe("Filter recommendations by type with case-insensitive fuzzy matching (e.g., aws, aws:ec2, aws:ec2:rightsizing). Natural language values like 'AWS recommendations' are normalized."),filter:g.enum(["open","resolved","dismissed"]).optional().describe("Filter recommendations by status: open (default), resolved, or dismissed")},oY=j({name:"list-recommendations",description:c2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:u2,async execute(e,t){let r={...e,limit:128,provider:e.provider},o=await t.callVantageApi("/v2/recommendations",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{recommendations:o.data.recommendations,pagination:X(o.data)}}});var qS=Ge(ct());var l2=`
393
404
  Tags can have many values. Use this tool to find the values and service providers that are associated with a tag.
394
- `.trim(),FZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),key:v.string().min(1).describe("Tag key to list values for")},g7=C({name:"list-tag-values",description:VZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:FZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi(`/v2/tags/${(0,OS.pathEncode)(e.key)}/values`,r,"GET");if(!o.ok)throw new R({errors:o.errors});return{tag_values:o.data.tag_values,pagination:X(o.data)}}});var GZ=`
405
+ `.trim(),d2={page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),key:g.string().min(1).describe("Tag key to list values for")},dY=j({name:"list-tag-values",description:l2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:d2,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi(`/v2/tags/${(0,qS.pathEncode)(e.key)}/values`,r,"GET");if(!o.ok)throw new I({errors:o.errors});return{tag_values:o.data.tag_values,pagination:X(o.data)}}});var p2=`
395
406
  List tags that can be used to filter costs and cost reports.
396
407
  Tags are associated with one or more Cost Providers.
397
408
  Tags can be edited in the Vantage Web UI, or have further details displayed there. Link a user to the tag page like this: https://console.vantage.sh/settings/tags?search_query=<tag>
398
- `.trim(),WZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1")},k7=C({name:"list-tags",description:GZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:WZ,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/tags",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{tags:o.data.tags,pagination:X(o.data)}}});var KZ=`
409
+ `.trim(),f2={page:g.number().optional().default(1).describe("The page number to return, defaults to 1")},_Y=j({name:"list-tags",description:p2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:f2,async execute(e,t){let r={...e,limit:128},o=await t.callVantageApi("/v2/tags",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{tags:o.data.tags,pagination:X(o.data)}}});var m2=`
399
410
  Retrieve the unit costs for a given CostReport, with optional paging, date filters, and ordering.
400
- `.trim(),HZ={cost_report_token:v.string().describe("CostReport token to list unit costs for"),page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),start_date:be("First date to filter unit costs from, format=YYYY-MM-DD").optional(),end_date:be("Last date to filter unit costs to, format=YYYY-MM-DD").optional(),date_bin:v.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),order:v.enum(["asc","desc"]).optional().default("desc").describe("Order of the returned costs, defaults to desc")},I7=C({name:"list-unit-costs",description:KZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:HZ,async execute(e,t){let r={...e,limit:64},o=await t.callVantageApi("/v2/unit_costs",r,"GET");if(!o.ok)throw new R({errors:o.errors});return{unit_costs:o.data.unit_costs,pagination:X(o.data)}}});var JZ=`
411
+ `.trim(),h2={cost_report_token:g.string().describe("CostReport token to list unit costs for"),page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),start_date:$e("First date to filter unit costs from, format=YYYY-MM-DD").optional(),end_date:$e("Last date to filter unit costs to, format=YYYY-MM-DD").optional(),date_bin:g.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),order:g.enum(["asc","desc"]).optional().default("desc").describe("Order of the returned costs, defaults to desc")},SY=j({name:"list-unit-costs",description:m2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:h2,async execute(e,t){let r={...e,limit:64},o=await t.callVantageApi("/v2/unit_costs",r,"GET");if(!o.ok)throw new I({errors:o.errors});return{unit_costs:o.data.unit_costs,pagination:X(o.data)}}});var g2=`
401
412
  Query for costs in a Vantage Account. These are independent of a cost reports.
402
413
  Use Vantage VQL to structure a query.
403
414
  Queries must be scoped to a Workspace. Use the get-myself tool to know about available workspaces, and the get-cost-integrations tool to know about available cost providers. If the user didn't tell you a workspace it is best to ask them than to guess it.
@@ -431,8 +442,12 @@ When DateBin=day you get a record for each service spend on that day. For DateBi
431
442
  with the accrued_at field set to the first day of the week, but the spend item represents spend for a full week.
432
443
  Same with DateBin=month, each record returned covers a month of data. This lets you get answers with processing fewer
433
444
  records. Only use day/week if needed, otherwise DateBin=month is preferred, and month is the value set if you pass no value for DateBin.
434
- `.trim(),BZ={page:v.number().optional().default(1).describe("The page number to return, defaults to 1"),filter:v.string().describe("A VQL query to run against your vantage account"),start_date:be("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:be("End date to filter costs by, format=YYYY-MM-DD").optional(),workspace_token:v.string().min(1).describe("The workspace token to scope the query to"),date_bin:v.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),settings_include_credits:v.boolean().optional().default(!1).describe("Results will include credits, defaults to false"),settings_include_refunds:v.boolean().optional().default(!1).describe("Results will include refunds, defaults to false"),settings_include_discounts:v.boolean().optional().default(!0).describe("Results will include discounts, defaults to true"),settings_include_tax:v.boolean().optional().default(!0).describe("Results will include tax, defaults to true"),settings_amortize:v.boolean().optional().default(!0).describe("Results will amortize, defaults to true"),settings_unallocated:v.boolean().optional().default(!1).describe("Results will show unallocated costs, defaults to false"),settings_aggregate_by:v.enum(["cost","usage"]).optional().default("cost").describe("Results will aggregate by cost or usage, defaults to cost"),settings_show_previous_period:v.boolean().optional().default(!0).describe("Results will show previous period costs or usage comparison, defaults to true"),groupings:v.array(v.string()).default(["provider","service","region"]).describe("Group the results by specific field(s). Defaults to provider, service, account_id. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>. Let Groupings default unless explicitly asked for.")},D7=C({name:"query-costs",description:JZ,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:BZ,async execute(e,t){let r={limit:1e3};e.date_bin||(e.date_bin="month"),Object.keys(e).forEach(i=>{let s=i;if(i.startsWith("settings_")){let a=i.slice(9);r[`settings[${a}]`]=e[s]}else r[i]=e[s]});let o=await t.callVantageApi("/v2/costs",r,"GET");if(!o.ok)throw new R({errors:o.errors});let n;switch(e.date_bin){case"day":n="Costs records represent one day.";break;case"week":n="Costs records represent one week, the accrued_at field is the first day of the week. If your date range is less than one week, this record includes only data for that date range, not the full week.";break;case"month":n="Costs records represent one month, the accrued_at field is the first day of the month. If your date range is less than one month, this record includes only data for that date range, not the full month.";break;default:throw new Error("Invalid date bin value")}return{costs:o.data.costs,total_cost:o.data.total_cost,notes:n,pagination:X(o.data)}}});var YZ=`
445
+ `.trim(),v2={page:g.number().optional().default(1).describe("The page number to return, defaults to 1"),filter:g.string().describe("A VQL query to run against your vantage account"),start_date:$e("Start date to filter costs by, format=YYYY-MM-DD").optional(),end_date:$e("End date to filter costs by, format=YYYY-MM-DD").optional(),workspace_token:g.string().min(1).describe("The workspace token to scope the query to"),date_bin:g.enum(["day","week","month"]).optional().describe("Date binning for returned costs, default to month unless user says otherwise, allowed values: day, week, month"),settings_include_credits:g.boolean().optional().default(!1).describe("Results will include credits, defaults to false"),settings_include_refunds:g.boolean().optional().default(!1).describe("Results will include refunds, defaults to false"),settings_include_discounts:g.boolean().optional().default(!0).describe("Results will include discounts, defaults to true"),settings_include_tax:g.boolean().optional().default(!0).describe("Results will include tax, defaults to true"),settings_amortize:g.boolean().optional().default(!0).describe("Results will amortize, defaults to true"),settings_unallocated:g.boolean().optional().default(!1).describe("Results will show unallocated costs, defaults to false"),settings_aggregate_by:g.enum(["cost","usage"]).optional().default("cost").describe("Results will aggregate by cost or usage, defaults to cost"),settings_show_previous_period:g.boolean().optional().default(!0).describe("Results will show previous period costs or usage comparison, defaults to true"),groupings:g.array(g.string()).default(["provider","service","region"]).describe("Group the results by specific field(s). Defaults to provider, service, account_id. Valid groupings: account_id, billing_account_id, charge_type, cost_category, cost_subcategory, provider, region, resource_id, service, tagged, tag:<tag_value>. Let Groupings default unless explicitly asked for.")},jY=j({name:"query-costs",description:g2,annotations:{destructive:!1,openWorld:!1,readOnly:!0},args:v2,async execute(e,t){let r={limit:1e3};e.date_bin||(e.date_bin="month"),Object.keys(e).forEach(i=>{let s=i;if(i.startsWith("settings_")){let a=i.slice(9);r[`settings[${a}]`]=e[s]}else r[i]=e[s]});let o=await t.callVantageApi("/v2/costs",r,"GET");if(!o.ok)throw new I({errors:o.errors});let n;switch(e.date_bin){case"day":n="Costs records represent one day.";break;case"week":n="Costs records represent one week, the accrued_at field is the first day of the week. If your date range is less than one week, this record includes only data for that date range, not the full week.";break;case"month":n="Costs records represent one month, the accrued_at field is the first day of the month. If your date range is less than one month, this record includes only data for that date range, not the full month.";break;default:throw new Error("Invalid date bin value")}return{costs:o.data.costs,total_cost:o.data.total_cost,notes:n,pagination:X(o.data)}}});var _2=`
435
446
  Submit feedback on using the Vantage MCP Server. Ask the user if they'd like to provide feedback any time you sense they might be frustrated.
436
447
  Stop suggesting if they say they're not interested in providing feedback.
437
- `.trim(),XZ={message:v.string().describe("Feedback message regarding using the Vantage MCP Server")},L7=C({name:"submit-user-feedback",description:YZ,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:XZ,async execute(e,t){let r=await t.callVantageApi("/v2/user_feedback",{message:e.message},"POST");if(!r.ok)throw new R({errors:r.errors});return r.data}});async function QZ(){if(!process.env.VANTAGE_TOKEN)throw new Error("VANTAGE_TOKEN environment variable is required.");let e={callVantageApi:async(o,n,i)=>{let s={Authorization:`Bearer ${process.env.VANTAGE_TOKEN}`};return bS(process.env.VANTAGE_API_HOST||"https://api.vantage.sh",s,n,i,o)}},t=new qd,r=new Ad(s_);wS(r,()=>e),await r.connect(t)}QZ().catch(e=>{console.error(e),process.exit(1)});
448
+ `.trim(),y2={message:g.string().describe("Feedback message regarding using the Vantage MCP Server")},DY=j({name:"submit-user-feedback",description:_2,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:y2,async execute(e,t){let r=await t.callVantageApi("/v2/user_feedback",{message:e.message},"POST");if(!r.ok)throw new I({errors:r.errors});return r.data}});var MS=Ge(ct());var b2=`
449
+ Updates an existing anomaly alert by its token. Use this to change the status of an anomaly alert (e.g. to archive or ignore it) and optionally provide feedback.
450
+ `.trim(),VY=j({name:"update-anomaly",description:b2,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{anomaly_alert_token:g.string().describe("The token of the anomaly alert to update."),status:g.enum(["active","archived","ignored"]).describe("The new status of the anomaly alert."),feedback:g.string().optional().describe("Optional comments explaining why the alert is being ignored or archived.")},async execute(e,t){let{anomaly_alert_token:r,...o}=e,n=await t.callVantageApi(`/v2/anomaly_alerts/${(0,MS.pathEncode)(r)}`,o,"PUT");if(!n.ok)throw new I({errors:n.errors});return n.data}});var US=Ge(ct());var $2=`
451
+ Updates a Folder for organizing Cost Reports. You can update its title, move it to a different parent Folder, or change its SavedFilter tokens.
452
+ `.trim(),KY=j({name:"update-folder",description:$2,annotations:{destructive:!1,openWorld:!1,readOnly:!1},args:{folder_token:g.string().describe("The token of the folder to update"),title:g.string().optional().describe("Updated title for the Folder"),parent_folder_token:g.string().optional().describe("Updated parent folder token for nesting"),saved_filter_tokens:g.array(g.string()).optional().describe("Updated tokens of SavedFilters to apply to any Cost Report contained within the Folder")},async execute(e,t){let{folder_token:r,...o}=e,n=await t.callVantageApi(`/v2/folders/${(0,US.pathEncode)(r)}`,o,"PUT");if(!n.ok)throw new I({errors:n.errors});return n.data}});async function w2(){if(!process.env.VANTAGE_TOKEN)throw new Error("VANTAGE_TOKEN environment variable is required.");let e={callVantageApi:async(o,n,i)=>{let s={Authorization:`Bearer ${process.env.VANTAGE_TOKEN}`};return wS(process.env.VANTAGE_API_HOST||"https://api.vantage.sh",s,n,i,o)}},t=new Ud,r=new qd(a_);kS(r,()=>e),await r.connect(t)}w2().catch(e=>{console.error(e),process.exit(1)});
438
453
  //# sourceMappingURL=index.js.map