1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6192],{37957:function(e,t,n){n.d(t,{J:function(){return r},K:function(){return i}});let r=(e,...t)=>t.reduce((e,t)=>({...e,...t,headers:{...e.headers,...t.headers},plugins:[...e.plugins??[],...t.plugins??[]]}),e),i=(e,t)=>new URL(`.${t}`,e.toString().replace(/\/?$/,"/"))},50279:function(e,t,n){n.d(t,{vr:function(){return r.vr},hj:function(){return i.h},he:function(){return s}});var r=n(10724),i=n(76389);let o=e=>new Promise(t=>setTimeout(()=>t(),e));class u extends r.O7{constructor(e,t){super(),this.request=e,this.response=t}}let a=async({req:e,sdkReq:t,usedForceRetry:i,attempt:s,timeoutMs:c,maxRetries:l,retryUnsafeMethod:d,retryClientErrors:f,resolveOn4xx:p,plugins:m,logger:h})=>{let _={attempt:s,req:{method:e.method,url:e.url}},v=new AbortController,y=setTimeout(()=>{v.abort()},c),g=i;try{let o=await n.g.fetch(e,{signal:v.signal});_.res={statusCode:o.status};try{o.data=await o.json()}catch(e){}let a=e=>{throw g=!0,new u(e,o)},s=o;for(let e of m.reverse())if(e.onResponse)try{s=await e.onResponse(t,s,a)}catch(e){if(!(e instanceof u)||!i)throw e}if(!s||!(s instanceof Response))return h?.debug(_,"[API SDK] Fetch completed"),s;if(!(o=s).ok&&!p||o.status>=500)throw new r.vr(t,o);return h?.debug(_,"[API SDK] Fetch completed"),o}catch(y){let n={attempt:s,req:e,timedOut:v.signal.aborted,res:y instanceof r.O7?y.response:void 0};if(y instanceof u)return h?.debug({...n},"[API SDK] Retry triggered by plugin"),await a({req:y.request.toRequest(),sdkReq:y.request,usedForceRetry:g,attempt:s,timeoutMs:c,maxRetries:l,retryUnsafeMethod:d,retryClientErrors:f,resolveOn4xx:p,plugins:m,logger:h});let i=d||"GET"===e.method||"HEAD"===e.method,_=y instanceof r.O7&&y.response&&y.response.status<500;if(s<l&&i&&(!_||f)){let r=Math.min(500*Math.pow(2,s),6e4);return h?.debug({...n,sleepMs:r},"[API SDK] Fetch failed; retrying"),await o(r),await a({req:e,sdkReq:t,usedForceRetry:g,attempt:s+1,timeoutMs:c,maxRetries:l,retryUnsafeMethod:d,retryClientErrors:f,resolveOn4xx:p,plugins:m,logger:h})}if(h?.debug(n,"[API SDK] Fetch failed; not retrying"),v.signal.aborted)throw new r.s4(t);throw y}finally{clearTimeout(y)}},s=async(e,t={})=>{let n=new i.h(e,t),{plugins:r=[]}=t;for(let e of r)e.onRequest&&(n=await e.onRequest(n));let{timeout:o,maxRetries:u,retryUnsafeMethod:s,retryClientErrors:c,resolveOn4xx:l,logger:d}=n.sdkInit,f=n.toRequest();return await a({req:f,sdkReq:n,timeoutMs:o,maxRetries:u,retryUnsafeMethod:s,retryClientErrors:c,resolveOn4xx:l,plugins:r,logger:d,attempt:0,usedForceRetry:!1})}},10724:function(e,t,n){n.d(t,{O7:function(){return r},s4:function(){return i},vr:function(){return o}});class r extends Error{}class i extends r{constructor(e){super(`API call ${e.method} ${e.url.toString()} timed out after ${e.sdkInit.timeout} ms`),this.request=e}}class o extends r{constructor(e,t){super(`API call ${e.method} ${e.url.toString()} responded with status ${t.status} ${t.statusText}`),this.request=e,this.response=t}}},76389:function(e,t,n){n.d(t,{h:function(){return i}});let r=(e,t)=>{let{headers:n,searchParams:r}=e,{headers:i,searchParams:o}=t,u=(n||i)&&{...n,...i},a=(r||o)&&{...r,...o};return{...e,...t,headers:u,searchParams:a}};class i extends Request{constructor(e,t={}){let n=t;t instanceof i&&(n={...n,...t.sdkInit}),e instanceof i&&(n=r(e.sdkInit,n));let{searchParams:o,data:u,timeout:a=3e4,maxRetries:s=3,retryUnsafeMethod:c=!1,retryClientErrors:l=!1,resolveOn4xx:d=!1,logger:f,plugins:p=[],...m}=n;!u||m.method||e instanceof Request||(m.method="POST"),m.headers&&(m.headers=Object.entries(m.headers).reduce((e,[t,n])=>({...e,[t.toLowerCase()]:n}),{})),super(e,m),this.sdkInit={searchParams:o,data:u,timeout:a,maxRetries:s,retryUnsafeMethod:c,retryClientErrors:l,resolveOn4xx:d,plugins:p,logger:f,headers:m.headers}}toRequest(){let{searchParams:e,data:t}=this.sdkInit,n={};t&&"string"==typeof t?n.body=t:t&&(n.body=JSON.stringify(t),n.headers=Array.from(this.headers.entries()).reduce((e,[t,n])=>({...e,[t.toLowerCase()]:n}),{"content-type":"application/json"}));let r=this;if(e&&Object.keys(e).length>0){let t=new URL(this.url);Object.entries(e).forEach(([e,n])=>{null!=n&&t.searchParams.set(e,n)}
1),r=new Request(t,this)}return new Request(r,n)}}},38286:function(e,t,n){n.d(t,{X:function(){return r},w:function(){return i}});let r={},i=(e={})=>{r=e}},25515:function(e,t,n){n.d(t,{IXX:function(){return us},O72:function(){return oG},Dom:function(){return i4},KmV:function(){return uA},k4_:function(){return a},Rxh:function(){return oU},Ryn:function(){return ud},Z_8:function(){return iQ},G0j:function(){return uh},HQ2:function(){return ot}});var r,i,o={};n.r(o),n.d(o,{base64:function(){return ex},base64url:function(){return eO},bigint:function(){return eR},boolean:function(){return eU},browserEmail:function(){return ez},cidrv4:function(){return e$},cidrv6:function(){return eS},cuid:function(){return en},cuid2:function(){return er},date:function(){return eA},datetime:function(){return eF},domain:function(){return eN},duration:function(){return es},e164:function(){return eT},email:function(){return eh},emoji:function(){return eb},extendedDuration:function(){return ec},guid:function(){return el},hex:function(){return eW},hostname:function(){return eI},html5Email:function(){return e_},idnEmail:function(){return eg},integer:function(){return eC},ipv4:function(){return ew},ipv6:function(){return ek},ksuid:function(){return eu},lowercase:function(){return eV},mac:function(){return eZ},md5_base64:function(){return eX},md5_base64url:function(){return eY},md5_hex:function(){return eG},nanoid:function(){return ea},null:function(){return eM},number:function(){return eJ},rfc5322Email:function(){return ev},sha1_base64:function(){return eQ},sha1_base64url:function(){return e0},sha1_hex:function(){return eH},sha256_base64:function(){return e4},sha256_base64url:function(){return e2},sha256_hex:function(){return e1},sha384_base64:function(){return e6},sha384_base64url:function(){return e3},sha384_hex:function(){return e9},sha512_base64:function(){return e7},sha512_base64url:function(){return e8},sha512_hex:function(){return e5},string:function(){return eD},time:function(){return ej},ulid:function(){return ei},undefined:function(){return eL},unicodeEmail:function(){return ey},uppercase:function(){return eB},uuid:function(){return ed},uuid4:function(){return ef},uuid6:function(){return ep},uuid7:function(){return em},xid:function(){return eo}});var u={};n.r(u),n.d(u,{endsWith:function(){return rP},gt:function(){return r_},gte:function(){return rv},includes:function(){return rE},length:function(){return rO},lowercase:function(){return rN},lt:function(){return rm},lte:function(){return rh},maxLength:function(){return rS},maxSize:function(){return rk},mime:function(){return rF},minLength:function(){return rx},minSize:function(){return rZ},multipleOf:function(){return rw},negative:function(){return rg},nonnegative:function(){return rb},nonpositive:function(){return rz},normalize:function(){return rR},overwrite:function(){return rD},positive:function(){return ry},property:function(){return rj},regex:function(){return rI},size:function(){return r$},slugify:function(){return rM},startsWith:function(){return rA},toLowerCase:function(){return rJ},toUpperCase:function(){return rU},trim:function(){return rC},uppercase:function(){return rT}});var a={};n.r(a),n.d(a,{ZodISODate:function(){return iN},ZodISODateTime:function(){return iO},ZodISODuration:function(){return iP},ZodISOTime:function(){return iE},date:function(){return iT},datetime:function(){return iI},duration:function(){return ij},time:function(){return iA}});var s={};function c(e,t,n){function r(n,r){if(n._zod||Object.defineProperty(n,"_zod",{value:{def:r,constr:u,traits:new Set},enumerable:!1}),n._zod.traits.has(e))return;n._zod.traits.add(e),t(n,r);let i=u.prototype,o=Object.keys(i);for(let e=0;e<o.length;e++){let t=o[e];t in n||(n[t]=i[t].bind(n))}}let i=n?.Parent??Object;class o extends i{}function u(e){var t;let i=n?.Parent?new o:this;for(let n of(r(i,e),(t=i._zod).deferred??(t.deferred=[]),i._zod.deferred))n();return i}return Object.defineProperty(o,"name",{value:e}),Object.defineProperty(u,"init",{value:r}),Object.defineProperty(u,Symbol.hasInstance,{value:t=>!!n?.Parent&&t instanceof n.Parent||t?._zod?.traits?.has(e)}),Object.defineProperty(u,"name",{value:e}),u}n.r(s),n.d(s,{ZodAny:function(){return o5},ZodArray:function(){return ua},ZodBase64:function(){return ox},ZodBase64URL:function(){return oI},ZodBigInt:function(){return oX},ZodBigIntFormat:function(){return oH},ZodBoolean:function(){return oK},ZodCIDRv4:function(){return ok},ZodCIDRv6:function(){return o$},ZodCUID:function(){return oa},ZodCUID2:function(){return oc},ZodCatch:function(){return u0},ZodCodec:function(){return u3},ZodCustom:function(){return as},ZodCustomStringFormat:function(){return oj},ZodDate:function(){return uo},ZodDefault:function(){return uW},ZodDiscriminatedUnion:function(){return uy},ZodE164:function(){return oT},ZodEmail:function(){return i1},ZodEmoji:function(){return or},ZodEnum:function(){return uE},ZodFile:function(){return uD},ZodFunction:function(){return au},ZodGUID:function(){return i2},ZodIPv4:function(){return ov},ZodIPv6:function(){return ob},ZodIntersection:function(){return uz},ZodJWT:function(){return oA},ZodKSUID:function(){return oh},ZodLazy:function(){return an},ZodLiteral:function(){return uj},ZodMAC:function(){return og},ZodMap:function(){return uO},ZodNaN:function(){return u4},ZodNanoID:function(){return oo},ZodNever:function(){return ut},ZodNonOptional:function(){return uX},ZodNull:function(){return o6},ZodNullable:function(){return uL},ZodNumber:function(){return oJ},ZodNumberFormat:function(){return oM},ZodObject:function(){return ul},ZodOptional:function(){return uU},ZodPipe:function(){return u9},ZodPrefault:function(){return uK},ZodPromise:function(){return ai},ZodReadonly:function(){return u7},ZodRecord:function(){return uZ},ZodSet:function(){return uN},ZodString:function(){return iH},ZodStringFormat:function(){return i0},ZodSuccess:function(){return uH},ZodSymbol:function(){return o1}
1,ZodTemplateLiteral:function(){return ae},ZodTransform:function(){return uC},ZodTuple:function(){return uw},ZodType:function(){return iX},ZodULID:function(){return od},ZodURL:function(){return oe},ZodUUID:function(){return i6},ZodUndefined:function(){return o2},ZodUnion:function(){return um},ZodUnknown:function(){return o8},ZodVoid:function(){return ur},ZodXID:function(){return op},ZodXor:function(){return u_},_ZodString:function(){return iY},_default:function(){return uq},_function:function(){return aa},any:function(){return o7},array:function(){return us},base64:function(){return oO},base64url:function(){return oN},bigint:function(){return oY},boolean:function(){return oG},catch:function(){return u1},check:function(){return ac},cidrv4:function(){return oZ},cidrv6:function(){return oS},codec:function(){return u5},cuid:function(){return os},cuid2:function(){return ol},custom:function(){return al},date:function(){return uu},describe:function(){return ap},discriminatedUnion:function(){return ug},e164:function(){return oE},email:function(){return i4},emoji:function(){return oi},enum:function(){return uA},file:function(){return uR},float32:function(){return oV},float64:function(){return oB},function:function(){return aa},guid:function(){return i9},hash:function(){return oC},hex:function(){return oR},hostname:function(){return oD},httpUrl:function(){return on},instanceof:function(){return ah},int:function(){return oL},int32:function(){return oW},int64:function(){return oQ},intersection:function(){return ub},ipv4:function(){return oy},ipv6:function(){return ow},json:function(){return av},jwt:function(){return oP},keyof:function(){return uc},ksuid:function(){return o_},lazy:function(){return ar},literal:function(){return uF},looseObject:function(){return up},looseRecord:function(){return ux},mac:function(){return oz},map:function(){return uI},meta:function(){return am},nan:function(){return u2},nanoid:function(){return ou},nativeEnum:function(){return uP},never:function(){return un},nonoptional:function(){return uY},null:function(){return o3},nullable:function(){return uV},nullish:function(){return uB},number:function(){return oU},object:function(){return ud},optional:function(){return uM},partialRecord:function(){return uS},pipe:function(){return u6},prefault:function(){return uG},preprocess:function(){return ay},promise:function(){return ao},readonly:function(){return u8},record:function(){return u$},refine:function(){return ad},set:function(){return uT},strictObject:function(){return uf},string:function(){return iQ},stringFormat:function(){return oF},stringbool:function(){return a_},success:function(){return uQ},superRefine:function(){return af},symbol:function(){return o4},templateLiteral:function(){return at},transform:function(){return uJ},tuple:function(){return uk},uint32:function(){return oq},uint64:function(){return o0},ulid:function(){return of},undefined:function(){return o9},union:function(){return uh},unknown:function(){return ue},url:function(){return ot},uuid:function(){return i3},uuidv4:function(){return i5},uuidv6:function(){return i7},uuidv7:function(){return i8},void:function(){return ui},xid:function(){return om},xor:function(){return uv}}),Object.freeze({status:"aborted"}),Symbol("zod_brand");class l extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class d extends Error{constructor(e){super(`Encountered unidirectional transform during encode: ${e}`),this.name="ZodEncodeError"}}let f={};function p(e){return e&&Object.assign(f,e),f}function m(e){let t=Object.values(e).filter(e=>"number"==typeof e);return Object.entries(e).filter(([e,n])=>-1===t.indexOf(+e)).map(([e,t])=>t)}function h(e,t="|"){return e.map(e=>j(e)).join(t)}function _(e,t){return"bigint"==typeof t?t.toString():t}function v(e){return{get value(){{let t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function y(e){return null==e}function g(e){let t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}let z=Symbol("evaluating");function b(e,t,n){let r;
1Object.defineProperty(e,t,{get(){if(r!==z)return void 0===r&&(r=z,r=n()),r},set(n){Object.defineProperty(e,t,{value:n})},configurable:!0})}function w(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function k(...e){let t={};for(let n of e)Object.assign(t,Object.getOwnPropertyDescriptors(n));return Object.defineProperties({},t)}function Z(e){return JSON.stringify(e)}let $="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function S(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)}let x=v(()=>{if("undefined"!=typeof navigator&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{return Function(""),!0}catch(e){return!1}});function O(e){if(!1===S(e))return!1;let t=e.constructor;if(void 0===t||"function"!=typeof t)return!0;let n=t.prototype;return!1!==S(n)&&!1!==Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")}function I(e){return O(e)?{...e}:Array.isArray(e)?[...e]:e}let N=new Set(["string","number","symbol"]),T=new Set(["string","number","bigint","boolean","symbol","undefined"]);function E(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function A(e,t,n){let r=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(r._zod.parent=e),r}function P(e){if(!e)return{};if("string"==typeof e)return{error:()=>e};if(e?.message!==void 0){if(e?.error!==void 0)throw Error("Cannot specify both `message` and `error` params");e.error=e.message}return(delete e.message,"string"==typeof e.error)?{...e,error:()=>e.error}:e}function j(e){return"bigint"==typeof e?e.toString()+"n":"string"==typeof e?`"${e}"`:`${e}`}let F={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]},D={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function R(e,t=0){if(!0===e.aborted)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function C(e,t){return t.map(t=>(t.path??(t.path=[]),t.path.unshift(e),t))}function J(e){return"string"==typeof e?e:e?.message}function U(e,t,n){let r={...e,path:e.path??[]};if(!e.message){let i=J(e.inst?._zod.def?.error?.(e))??J(t?.error?.(e))??J(n.customError?.(e))??J(n.localeError?.(e))??"Invalid input";r.message=i}return delete r.inst,delete r.continue,t?.reportInput||delete r.input,r}function M(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}function L(e){return Array.isArray(e)?"array":"string"==typeof e?"string":"unknown"}function V(...e){let[t,n,r]=e;return"string"==typeof t?{message:t,code:"custom",input:n,inst:r}:{...t}}let B=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,_,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},W=c("$ZodError",B),q=c("$ZodError",B,{Parent:Error}),K=e=>(t,n,r,i)=>{let o=r?Object.assign(r,{async:!1}):{async:!1},u=t._zod.run({value:n,issues:[]},o);if(u instanceof Promise)throw new l;if(u.issues.length){let t=new(i?.Err??e)(u.issues.map(e=>U(e,o,p())));throw $(t,i?.callee),t}return u.value},G=K(q),X=e=>async(t,n,r,i)=>{let o=r?Object.assign(r,{async:!0}):{async:!0},u=t._zod.run({value:n,issues:[]},o);if(u instanceof Promise&&(u=await u),u.issues.length){let t=new(i?.Err??e)(u.issues.map(e=>U(e,o,p())));throw $(t,i?.callee),t}return u.value},Y=X(q),H=e=>(t,n,r)=>{let i=r?{...r,async:!1}:{async:!1},o=t._zod.run({value:n,issues:[]},i);if(o instanceof Promise)throw new l;return o.issues.length?{success:!1,error:new(e??W)(o.issues.map(e=>U(e,i,p())))}:{success:!0,data:o.value}},Q=H(q),ee=e=>async(t,n,r)=>{let i=r?Object.assign(r,{async:!0}):{async:!0},o=t._zod.run({value:n,issues:[]},i);return o instanceof Promise&&(o=await o),o.issues.length?{success:!1,error:new e(o.issues.map(e=>U(e,i,p())))}:{success:!0,data:o.value}},et=ee(q),en=/^[cC][^\s-]{8,}$/,er=/^[0-9a-z]+$/,ei=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,eo=/^[0-9a-vA-V]{20}$/,eu=/^[A-Za-z0-9]{27}$/,ea=/^[a-zA-Z0-9_-]{21}$/,es=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,ec=/^[-+]?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)?)??$/,el=/^([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})$/,ed=e=>e?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|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,ef=ed(4),ep=ed(6),em=ed(7),eh=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,e_=/^[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])?)*$/,ev=/^(([^<>()\[\]\\.,;:\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,}))$/,ey=/^[^\s@"]{1,64}
1@[^\s@]{1,255}$/u,eg=ey,ez=/^[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])?)*$/;function eb(){return RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")}let ew=/^(?:(?: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])$/,ek=/^(([0-9a-fA-F]{1,4}:){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}|:))$/,eZ=e=>{let t=E(e??":");return RegExp(`^(?:[0-9A-F]{2}${t}){5}[0-9A-F]{2}$|^(?:[0-9a-f]{2}${t}){5}[0-9a-f]{2}$`)},e$=/^((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])$/,eS=/^(([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])$/,ex=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,eO=/^[A-Za-z0-9_-]*$/,eI=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,eN=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,eT=/^\+(?:[0-9]){6,14}[0-9]$/,eE="(?:(?:\\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])))",eA=RegExp(`^${eE}$`);function eP(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return"number"==typeof e.precision?-1===e.precision?`${t}`:0===e.precision?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function ej(e){return RegExp(`^${eP(e)}$`)}function eF(e){let t=eP({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let r=`${t}(?:${n.join("|")})`;return RegExp(`^${eE}T(?:${r})$`)}let eD=e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return RegExp(`^${t}$`)},eR=/^-?\d+n?$/,eC=/^-?\d+$/,eJ=/^-?\d+(?:\.\d+)?/,eU=/^(?:true|false)$/i,eM=/^null$/i,eL=/^undefined$/i,eV=/^[^A-Z]*$/,eB=/^[^a-z]*$/,eW=/^[0-9a-fA-F]*$/;function eq(e,t){return RegExp(`^[A-Za-z0-9+/]{${e}}${t}$`)}function eK(e){return RegExp(`^[A-Za-z0-9_-]{${e}}$`)}let eG=/^[0-9a-fA-F]{32}$/,eX=eq(22,"=="),eY=eK(22),eH=/^[0-9a-fA-F]{40}$/,eQ=eq(27,"="),e0=eK(27),e1=/^[0-9a-fA-F]{64}$/,e4=eq(43,"="),e2=eK(43),e9=/^[0-9a-fA-F]{96}$/,e6=eq(64,""),e3=eK(64),e5=/^[0-9a-fA-F]{128}$/,e7=eq(86,"=="),e8=eK(86),te=c("$ZodCheck",(e,t)=>{var n;e._zod??(e._zod={}),e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),tt={number:"number",bigint:"bigint",object:"date"},tn=c("$ZodCheckLessThan",(e,t)=>{te.init(e,t);let n=tt[typeof t.value];e._zod.onattach.push(e=>{let n=e._zod.bag,r=(t.inclusive?n.maximum:n.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<r&&(t.inclusive?n.maximum=t.value:n.exclusiveMaximum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value<=t.value:r.value<t.value)||r.issues.push({origin:n,code:"too_big",maximum:t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),tr=c("$ZodCheckGreaterThan",(e,t)=>{te.init(e,t);let n=tt[typeof t.value];e._zod.onattach.push(e=>{let n=e._zod.bag,r=(t.inclusive?n.minimum:n.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>r&&(t.inclusive?n.minimum=t.value:n.exclusiveMinimum=t.value)}),e._zod.check=r=>{(t.inclusive?r.value>=t.value:r.value>t.value)||r.issues.push({origin:n,code:"too_small",minimum:t.value,input:r.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),ti=c("$ZodCheckMultipleOf",(e,t)=>{te.init(e,t),e._zod.onattach.push(e=>{var n;(n=e._zod.bag).multipleOf??(n.multipleOf=t.value)}),e._zod.check=n=>{if(typeof n.value!=typeof t.value)throw Error("Cannot mix number and bigint in multiple_of check.");("bigint"==typeof n.value?n.value%t.value===BigInt(0):0===function(e,t){let n=(e.toString().split(".")[1]||"").length,r=t.toString(),i=(r.split(".")[1]||"").length;if(0===i&&/\d?e-\d?/.test(r)){let e=r.match(/\d?e-(\d?)/);e?.[1]&&(i=Number.parseInt(e[1]))}let o=n>i?n:i;return Number.parseInt(e.toFixed(o).replace(".",""))%Number.parseInt(t.toFixed(o).replace(".",""))/10**o}(n.value,t.value))||n.issues.push({origin:typeof n.value,code:"not_multiple_of",divisor:t.value,input:n.value,inst:e,continue:!t.abort})}}),to=c("$ZodCheckNumberFormat",(e,t)=>{te.init(e,t),t.format=t.format||"float64";let n=t.format?.includes("int"),r=n?"int":"number",[i,o]=F[t.format];e._zod.onattach.push(e=>{let r=e._zod.bag;r.format=t.format,r.minimum=i,r.maximum=o,n&&(r.pattern=eC)}),e._zod.check=u=>{let a=u.value;if(n){if(!Number.isInteger(a)){u.issues.push({expected:r,format:t.format,code:"invalid_type",continue:!1,input:a,inst:e});return}if(!Number.isSafeInteger(a)){a>0?u.issues.push({input:a,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,continue:!t.abort}):u.issues.push({input:a,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:r,continue:!t.abort});return}}a<i&&u.issues.push({origin:"number",input:a,code:"too_small",minimum:i,inclusive:!0,inst:e,continue:!t.abort}),a>o&&u.issues.push({origin:"number",input:a,code:"too_big",maximum:o,inst:e})}}),tu=c("$ZodCheckBigIntFormat",(e,t)=>{te.init(e,t);
vendor: 4,113 bytes, line 1
1let[n,r]=D[t.format];e._zod.onattach.push(e=>{let i=e._zod.bag;i.format=t.format,i.minimum=n,i.maximum=r}),e._zod.check=i=>{let o=i.value;o<n&&i.issues.push({origin:"bigint",input:o,code:"too_small",minimum:n,inclusive:!0,inst:e,continue:!t.abort}),o>r&&i.issues.push({origin:"bigint",input:o,code:"too_big",maximum:r,inst:e})}}),ta=c("$ZodCheckMaxSize",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.size}),e._zod.onattach.push(e=>{let n=e._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(e._zod.bag.maximum=t.maximum)}),e._zod.check=n=>{let r=n.value;r.size<=t.maximum||n.issues.push({origin:M(r),code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),ts=c("$ZodCheckMinSize",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.size}),e._zod.onattach.push(e=>{let n=e._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(e._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let r=n.value;r.size>=t.minimum||n.issues.push({origin:M(r),code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),tc=c("$ZodCheckSizeEquals",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.size}),e._zod.onattach.push(e=>{let n=e._zod.bag;n.minimum=t.size,n.maximum=t.size,n.size=t.size}),e._zod.check=n=>{let r=n.value,i=r.size;if(i===t.size)return;let o=i>t.size;n.issues.push({origin:M(r),...o?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),tl=c("$ZodCheckMaxLength",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.length}),e._zod.onattach.push(e=>{let n=e._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<n&&(e._zod.bag.maximum=t.maximum)}),e._zod.check=n=>{let r=n.value;if(r.length<=t.maximum)return;let i=L(r);n.issues.push({origin:i,code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),td=c("$ZodCheckMinLength",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.length}),e._zod.onattach.push(e=>{let n=e._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>n&&(e._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let r=n.value;if(r.length>=t.minimum)return;let i=L(r);n.issues.push({origin:i,code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),tf=c("$ZodCheckLengthEquals",(e,t)=>{var n;te.init(e,t),(n=e._zod.def).when??(n.when=e=>{let t=e.value;return!y(t)&&void 0!==t.length}),e._zod.onattach.push(e=>{let n=e._zod.bag;n.minimum=t.length,n.maximum=t.length,n.length=t.length}),e._zod.check=n=>{let r=n.value,i=r.length;if(i===t.length)return;let o=L(r),u=i>t.length;n.issues.push({origin:o,...u?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),tp=c("$ZodCheckStringFormat",(e,t)=>{var n,r;te.init(e,t),e._zod.onattach.push(e=>{let n=e._zod.bag;n.format=t.format,t.pattern&&(n.patterns??(n.patterns=new Set),n.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.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})}):(r=e._zod).check??(r.check=()=>{})}),tm=c("$ZodCheckRegex",(e,t)=>{tp.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,t.pattern.test(n.value)||n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),th=c("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=eV),tp.init(e,t)}),t_=c("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=eB),tp.init(e,t)}),tv=c("$ZodCheckIncludes",(e,t)=>{te.init(e,t);let n=E(t.includes),r=new RegExp("number"==typeof t.position?`^.{${t.position}}${n}`:n);t.pattern=r,e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(r)}),e._zod.check=n=>
1{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})}}),ty=c("$ZodCheckStartsWith",(e,t)=>{te.init(e,t);let n=RegExp(`^${E(t.prefix)}.*`);t.pattern??(t.pattern=n),e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(n)}),e._zod.check=n=>{n.value.startsWith(t.prefix)||n.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:n.value,inst:e,continue:!t.abort})}}),tg=c("$ZodCheckEndsWith",(e,t)=>{te.init(e,t);let n=RegExp(`.*${E(t.suffix)}$`);t.pattern??(t.pattern=n),e._zod.onattach.push(e=>{let t=e._zod.bag;t.patterns??(t.patterns=new Set),t.patterns.add(n)}),e._zod.check=n=>{n.value.endsWith(t.suffix)||n.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:n.value,inst:e,continue:!t.abort})}});function tz(e,t,n){e.issues.length&&t.issues.push(...C(n,e.issues))}let tb=c("$ZodCheckProperty",(e,t)=>{te.init(e,t),e._zod.check=e=>{let n=t.schema._zod.run({value:e.value[t.property],issues:[]},{});if(n instanceof Promise)return n.then(n=>tz(n,e,t.property));tz(n,e,t.property)}}),tw=c("$ZodCheckMimeType",(e,t)=>{te.init(e,t);let n=new Set(t.mime);e._zod.onattach.push(e=>{e._zod.bag.mime=t.mime}),e._zod.check=r=>{n.has(r.value.type)||r.issues.push({code:"invalid_value",values:t.mime,input:r.value.type,inst:e,continue:!t.abort})}}),tk=c("$ZodCheckOverwrite",(e,t)=>{te.init(e,t),e._zod.check=e=>{e.value=t.tx(e.value)}});class tZ{constructor(e=[]){this.content=[],this.indent=0,this&&(this.args=e)}indented(e){this.indent+=1,e(this),this.indent-=1}write(e){if("function"==typeof e){e(this,{execution:"sync"}),e(this,{execution:"async"});return}let t=e.split("\n").filter(e=>e),n=Math.min(...t.map(e=>e.length-e.trimStart().length));for(let e of t.map(e=>e.slice(n)).map(e=>" ".repeat(2*this.indent)+e))this.content.push(e)}compile(){return Function(...this?.args,[...(this?.content??[""]).map(e=>` ${e}`)].join("\n"))}}let t$={major:4,minor:2,patch:1},tS=c("$ZodType",(e,t)=>{var n;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=t$;let r=[...e._zod.def.checks??[]];for(let t of(e._zod.traits.has("$ZodCheck")&&r.unshift(e),r))for(let n of t._zod.onattach)n(e);if(0===r.length)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let t=(e,t,n)=>{let r,i=R(e);for(let o of t){if(o._zod.def.when){if(!o._zod.def.when(e))continue}else if(i)continue;let t=e.issues.length,u=o._zod.check(e);if(u instanceof Promise&&n?.async===!1)throw new l;if(r||u instanceof Promise)r=(r??Promise.resolve()).then(async()=>{await u,e.issues.length===t||i||(i=R(e,t))});else{if(e.issues.length===t)continue;i||(i=R(e,t))}}return r?r.then(()=>e):e},n=(n,i,o)=>{if(R(n))return n.aborted=!0,n;let u=t(i,r,o);if(u instanceof Promise){if(!1===o.async)throw new l;return u.then(t=>e._zod.parse(t,o))}return e._zod.parse(u,o)};e._zod.run=(i,o)=>{if(o.skipChecks)return e._zod.parse(i,o);if("backward"===o.direction){let t=e._zod.parse({value:i.value,issues:[]},{...o,skipChecks:!0});return t instanceof Promise?t.then(e=>n(e,i,o)):n(t,i,o)}let u=e._zod.parse(i,o);if(u instanceof Promise){if(!1===o.async)throw new l;return u.then(e=>t(e,r,o))}return t(u,r,o)}}e["~standard"]={validate:t=>{try{let n=Q(e,t);return n.success?{value:n.data}:{issues:n.error?.issues}}catch(n){return et(e,t).then(e=>e.success?{value:e.data}:{issues:e.error?.issues})}},vendor:"zod",version:1}}),tx=c("$ZodString",(e,t)=>{tS.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??eD(e._zod.bag),e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=String(n.value)}catch(e){}return"string"==typeof n.value||n.issues.push({expected:"string",code:"invalid_type",input:n.value,inst:e}),n}}),tO=c("$ZodStringFormat",(e,t)=>{tp.init(e,t),tx.init(e,t)}),tI=c("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=el),tO.init(e,t)}),tN=c("$ZodUUID",(e,t)=>{if(t.version){let e={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(void 0===e)throw Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=ed(e))}else t.pattern??(t.pattern=ed());tO.init(e,t)}),tT=c("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=eh),tO.init(e,t)}),tE=c("$ZodURL",(e,t)=>{tO.init(e,t),e._zod.check=n=>{try{let r=n.value.trim(),i=new URL(r);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(i.hostname)||n.issues.push({code:"invalid_format",format:"url",n
1ote:"Invalid hostname",pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(i.protocol.endsWith(":")?i.protocol.slice(0,-1):i.protocol)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort})),t.normalize?n.value=i.href:n.value=r;return}catch(r){n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),tA=c("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=eb()),tO.init(e,t)}),tP=c("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=ea),tO.init(e,t)}),tj=c("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=en),tO.init(e,t)}),tF=c("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=er),tO.init(e,t)}),tD=c("$ZodULID",(e,t)=>{t.pattern??(t.pattern=ei),tO.init(e,t)}),tR=c("$ZodXID",(e,t)=>{t.pattern??(t.pattern=eo),tO.init(e,t)}),tC=c("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=eu),tO.init(e,t)}),tJ=c("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=eF(t)),tO.init(e,t)}),tU=c("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=eA),tO.init(e,t)}),tM=c("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=ej(t)),tO.init(e,t)}),tL=c("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=es),tO.init(e,t)}),tV=c("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=ew),tO.init(e,t),e._zod.bag.format="ipv4"}),tB=c("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=ek),tO.init(e,t),e._zod.bag.format="ipv6",e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:"invalid_format",format:"ipv6",input:n.value,inst:e,continue:!t.abort})}}}),tW=c("$ZodMAC",(e,t)=>{t.pattern??(t.pattern=eZ(t.delimiter)),tO.init(e,t),e._zod.bag.format="mac"}),tq=c("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=e$),tO.init(e,t)}),tK=c("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=eS),tO.init(e,t),e._zod.check=n=>{let r=n.value.split("/");try{if(2!==r.length)throw Error();let[e,t]=r;if(!t)throw Error();let n=Number(t);if(`${n}`!==t||n<0||n>128)throw Error();new URL(`http://[${e}]`)}catch{n.issues.push({code:"invalid_format",format:"cidrv6",input:n.value,inst:e,continue:!t.abort})}}});function tG(e){if(""===e)return!0;if(e.length%4!=0)return!1;try{return atob(e),!0}catch{return!1}}let tX=c("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=ex),tO.init(e,t),e._zod.bag.contentEncoding="base64",e._zod.check=n=>{tG(n.value)||n.issues.push({code:"invalid_format",format:"base64",input:n.value,inst:e,continue:!t.abort})}}),tY=c("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=eO),tO.init(e,t),e._zod.bag.contentEncoding="base64url",e._zod.check=n=>{!function(e){if(!eO.test(e))return!1;let t=e.replace(/[-_]/g,e=>"-"===e?"+":"/");return tG(t.padEnd(4*Math.ceil(t.length/4),"="))}(n.value)&&n.issues.push({code:"invalid_format",format:"base64url",input:n.value,inst:e,continue:!t.abort})}}),tH=c("$ZodE164",(e,t)=>{t.pattern??(t.pattern=eT),tO.init(e,t)}),tQ=c("$ZodJWT",(e,t)=>{tO.init(e,t),e._zod.check=n=>{!function(e,t=null){try{let n=e.split(".");if(3!==n.length)return!1;let[r]=n;if(!r)return!1;let i=JSON.parse(atob(r));if("typ"in i&&i?.typ!=="JWT"||!i.alg||t&&(!("alg"in i)||i.alg!==t))return!1;return!0}catch{return!1}}(n.value,t.alg)&&n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),t0=c("$ZodCustomStringFormat",(e,t)=>{tO.init(e,t),e._zod.check=n=>{t.fn(n.value)||n.issues.push({code:"invalid_format",format:t.format,input:n.value,inst:e,continue:!t.abort})}}),t1=c("$ZodNumber",(e,t)=>{tS.init(e,t),e._zod.pattern=e._zod.bag.pattern??eJ,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=Number(n.value)}catch(e){}let i=n.value;if("number"==typeof i&&!Number.isNaN(i)&&Number.isFinite(i))return n;let o="number"==typeof i?Number.isNaN(i)?"NaN":Number.isFinite(i)?void 0:"Infinity":void 0;return n.issues.push({expected:"number",code:"invalid_type",input:i,inst:e,...o?{received:o}:{}}),n}}),t4=c("$ZodNumberFormat",(e,t)=>{to.init(e,t),t1.init(e,t)}),t2=c("$ZodBoolean",(e,t)=>{tS.init(e,t),e._zod.pattern=eU,e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=!!n.value}catch(e){}let i=n.value;return"boolean"==typeof i||n.issues.push({expected:"boolean",code:"invalid_type",input:i,inst:e}),n}}),t9=c("$ZodBigInt",(e,t)=>{tS.init(e,t),e._zod.pattern=eR,e._zod.parse=(n,r)=>
1{if(t.coerce)try{n.value=BigInt(n.value)}catch(e){}return"bigint"==typeof n.value||n.issues.push({expected:"bigint",code:"invalid_type",input:n.value,inst:e}),n}}),t6=c("$ZodBigIntFormat",(e,t)=>{tu.init(e,t),t9.init(e,t)}),t3=c("$ZodSymbol",(e,t)=>{tS.init(e,t),e._zod.parse=(t,n)=>{let r=t.value;return"symbol"==typeof r||t.issues.push({expected:"symbol",code:"invalid_type",input:r,inst:e}),t}}),t5=c("$ZodUndefined",(e,t)=>{tS.init(e,t),e._zod.pattern=eL,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(t,n)=>{let r=t.value;return void 0===r||t.issues.push({expected:"undefined",code:"invalid_type",input:r,inst:e}),t}}),t7=c("$ZodNull",(e,t)=>{tS.init(e,t),e._zod.pattern=eM,e._zod.values=new Set([null]),e._zod.parse=(t,n)=>{let r=t.value;return null===r||t.issues.push({expected:"null",code:"invalid_type",input:r,inst:e}),t}}),t8=c("$ZodAny",(e,t)=>{tS.init(e,t),e._zod.parse=e=>e}),ne=c("$ZodUnknown",(e,t)=>{tS.init(e,t),e._zod.parse=e=>e}),nt=c("$ZodNever",(e,t)=>{tS.init(e,t),e._zod.parse=(t,n)=>(t.issues.push({expected:"never",code:"invalid_type",input:t.value,inst:e}),t)}),nn=c("$ZodVoid",(e,t)=>{tS.init(e,t),e._zod.parse=(t,n)=>{let r=t.value;return void 0===r||t.issues.push({expected:"void",code:"invalid_type",input:r,inst:e}),t}}),nr=c("$ZodDate",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=new Date(n.value)}catch(e){}let i=n.value,o=i instanceof Date;return o&&!Number.isNaN(i.getTime())||n.issues.push({expected:"date",code:"invalid_type",input:i,...o?{received:"Invalid Date"}:{},inst:e}),n}});function ni(e,t,n){e.issues.length&&t.issues.push(...C(n,e.issues)),t.value[n]=e.value}let no=c("$ZodArray",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!Array.isArray(i))return n.issues.push({expected:"array",code:"invalid_type",input:i,inst:e}),n;n.value=Array(i.length);let o=[];for(let e=0;e<i.length;e++){let u=i[e],a=t.element._zod.run({value:u,issues:[]},r);a instanceof Promise?o.push(a.then(t=>ni(t,n,e))):ni(a,n,e)}return o.length?Promise.all(o).then(()=>n):n}});function nu(e,t,n,r){e.issues.length&&t.issues.push(...C(n,e.issues)),void 0===e.value?n in r&&(t.value[n]=void 0):t.value[n]=e.value}function na(e){var t;let n=Object.keys(e.shape);for(let t of n)if(!e.shape?.[t]?._zod?.traits?.has("$ZodType"))throw Error(`Invalid element at key "${t}": expected a Zod schema`);let r=Object.keys(t=e.shape).filter(e=>"optional"===t[e]._zod.optin&&"optional"===t[e]._zod.optout);return{...e,keys:n,keySet:new Set(n),numKeys:n.length,optionalKeys:new Set(r)}}function ns(e,t,n,r,i,o){let u=[],a=i.keySet,s=i.catchall._zod,c=s.def.type;for(let i in t){if(a.has(i))continue;if("never"===c){u.push(i);continue}let o=s.run({value:t[i],issues:[]},r);o instanceof Promise?e.push(o.then(e=>nu(e,n,i,t))):nu(o,n,i,t)}return(u.length&&n.issues.push({code:"unrecognized_keys",keys:u,input:t,inst:o}),e.length)?Promise.all(e).then(()=>n):n}let nc=c("$ZodObject",(e,t)=>{let n;tS.init(e,t);let r=Object.getOwnPropertyDescriptor(t,"shape");if(!r?.get){let e=t.shape;Object.defineProperty(t,"shape",{get:()=>{let n={...e};return Object.defineProperty(t,"shape",{value:n}),n}})}let i=v(()=>na(t));b(e._zod,"propValues",()=>{let e=t.shape,n={};for(let t in e){let r=e[t]._zod;if(r.values)for(let e of(n[t]??(n[t]=new Set),r.values))n[t].add(e)}return n});let o=t.catchall;e._zod.parse=(t,r)=>{n??(n=i.value);let u=t.value;if(!S(u))return t.issues.push({expected:"object",code:"invalid_type",input:u,inst:e}),t;t.value={};let a=[],s=n.shape;for(let e of n.keys){let n=s[e]._zod.run({value:u[e],issues:[]},r);n instanceof Promise?a.push(n.then(n=>nu(n,t,e,u))):nu(n,t,e,u)}return o?ns(a,u,t,r,i.value,e):a.length?Promise.all(a).then(()=>t):t}}),nl=c("$ZodObjectJIT",(e,t)=>{let n,r;nc.init(e,t);let i=e._zod.parse,o=v(()=>na(t)),u=e=>{let t=new tZ(["shape","payload","ctx"]),n=o.value,r=e=>{let t=Z(e);return`shape[${t}]._zod.run({ value: input[${t}], issues: [] }, ctx)`};t.write("const input = payload.value;");let i=Object.create(null),u=0;for(let e of n.keys)i[e]=`key_${u++}`;for(let e of(t.write("const newResult = {};"),n.keys)){let n=i[e],o=Z(e);t.write(`const ${n} = ${r(e)};`),t.write(` 2 if (${n}.issues.length) { 3 payload.issues = payload.issues.concat(${n}.issues.map(iss => ({ 4 ...iss, 5 path: iss.path ? [${o}, ...iss.path] : [${o}] 6 }))); 7 } 8 9 10 if (${n}.value === undefined) { 11 if (${o} in input) { 12 newResult[${o}] = undefined; 13 } 14 } else { 15 newResult[${o}] = ${n}.value; 16 } 17 18 `)}t.write("payload.value = newResult;"),t.write("return payload;");let a=t.compile();return(t,n)=>a(e,t,n)},a=!f.jitless,s=a&&x.value,c=t.catchall;e._zod.parse=(l,d)=>{r??(r=o.value);let f=l.value;return S(f)?a&&s&&d?.async===!1&&!0!==d.jitless?(n||(n=u(t.shape)),l=n(l,d),c)?ns([],f,l,d,r,e):l:i(l,d):(l.issues.push({expected:"object",code:"invalid_type",input:f,inst:e}),l)}});
18function nd(e,t,n,r){for(let n of e)if(0===n.issues.length)return t.value=n.value,t;let i=e.filter(e=>!R(e));return 1===i.length?(t.value=i[0].value,i[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(e=>e.issues.map(e=>U(e,r,p())))}),t)}let nf=c("$ZodUnion",(e,t)=>{tS.init(e,t),b(e._zod,"optin",()=>t.options.some(e=>"optional"===e._zod.optin)?"optional":void 0),b(e._zod,"optout",()=>t.options.some(e=>"optional"===e._zod.optout)?"optional":void 0),b(e._zod,"values",()=>{if(t.options.every(e=>e._zod.values))return new Set(t.options.flatMap(e=>Array.from(e._zod.values)))}),b(e._zod,"pattern",()=>{if(t.options.every(e=>e._zod.pattern)){let e=t.options.map(e=>e._zod.pattern);return RegExp(`^(${e.map(e=>g(e.source)).join("|")})$`)}});let n=1===t.options.length,r=t.options[0]._zod.run;e._zod.parse=(i,o)=>{if(n)return r(i,o);let u=!1,a=[];for(let e of t.options){let t=e._zod.run({value:i.value,issues:[]},o);if(t instanceof Promise)a.push(t),u=!0;else{if(0===t.issues.length)return t;a.push(t)}}return u?Promise.all(a).then(t=>nd(t,i,e,o)):nd(a,i,e,o)}});function np(e,t,n,r){let i=e.filter(e=>0===e.issues.length);return 1===i.length?t.value=i[0].value:0===i.length?t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(e=>e.issues.map(e=>U(e,r,p())))}):t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:[],inclusive:!1}),t}let nm=c("$ZodXor",(e,t)=>{nf.init(e,t),t.inclusive=!1;let n=1===t.options.length,r=t.options[0]._zod.run;e._zod.parse=(i,o)=>{if(n)return r(i,o);let u=!1,a=[];for(let e of t.options){let t=e._zod.run({value:i.value,issues:[]},o);t instanceof Promise?(a.push(t),u=!0):a.push(t)}return u?Promise.all(a).then(t=>np(t,i,e,o)):np(a,i,e,o)}}),nh=c("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,nf.init(e,t);let n=e._zod.parse;b(e._zod,"propValues",()=>{let e={};for(let n of t.options){let r=n._zod.propValues;if(!r||0===Object.keys(r).length)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(n)}"`);for(let[t,n]of Object.entries(r))for(let r of(e[t]||(e[t]=new Set),n))e[t].add(r)}return e});let r=v(()=>{let e=t.options,n=new Map;for(let r of e){let e=r._zod.propValues?.[t.discriminator];if(!e||0===e.size)throw Error(`Invalid discriminated union option at index "${t.options.indexOf(r)}"`);for(let t of e){if(n.has(t))throw Error(`Duplicate discriminator value "${String(t)}"`);n.set(t,r)}}return n});e._zod.parse=(i,o)=>{let u=i.value;if(!S(u))return i.issues.push({code:"invalid_type",expected:"object",input:u,inst:e}),i;let a=r.value.get(u?.[t.discriminator]);return a?a._zod.run(i,o):t.unionFallback?n(i,o):(i.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:u,path:[t.discriminator],inst:e}),i)}}),n_=c("$ZodIntersection",(e,t)=>{tS.init(e,t),e._zod.parse=(e,n)=>{let r=e.value,i=t.left._zod.run({value:r,issues:[]},n),o=t.right._zod.run({value:r,issues:[]},n);return i instanceof Promise||o instanceof Promise?Promise.all([i,o]).then(([t,n])=>nv(e,t,n)):nv(e,i,o)}});function nv(e,t,n){if(t.issues.length&&e.issues.push(...t.issues),n.issues.length&&e.issues.push(...n.issues),R(e))return e;let r=function e(t,n){if(t===n||t instanceof Date&&n instanceof Date&&+t==+n)return{valid:!0,data:t};if(O(t)&&O(n)){let r=Object.keys(n),i=Object.keys(t).filter(e=>-1!==r.indexOf(e)),o={...t,...n};for(let r of i){let i=e(t[r],n[r]);if(!i.valid)return{valid:!1,mergeErrorPath:[r,...i.mergeErrorPath]};o[r]=i.data}return{valid:!0,data:o}}if(Array.isArray(t)&&Array.isArray(n)){if(t.length!==n.length)return{valid:!1,mergeErrorPath:[]};let r=[];for(let i=0;i<t.length;i++){let o=e(t[i],n[i]);if(!o.valid)return{valid:!1,mergeErrorPath:[i,...o.mergeErrorPath]};r.push(o.data)}return{valid:!0,data:r}}return{valid:!1,mergeErrorPath:[]}}(t.value,n.value);if(!r.valid)throw Error(`Unmergable intersection. Error path: ${JSON.stringify(r.mergeErrorPath)}`);return e.value=r.data,e}let ny=c("$ZodTuple",(e,t)=>{tS.init(e,t);let n=t.items;e._zod.parse=(r,i)=>{let o=r.value;if(!Array.isArray(o))return r.issues.push({input:o,inst:e,expected:"tuple",code:"invalid_type"}),r;r.value=[];let u=[],a=[...n].reverse().findIndex(e=>"optional"!==e._zod.optin),s=-1===a?0:n.length-a;if(!t.rest){let t=o.length>n.length,i=o.length<s-1;if(t||i)return r.issues.push({...t?{code:"too_big",maximum:n.length}:{code:"too_small",minimum:n.length}
18,input:o,inst:e,origin:"array"}),r}let c=-1;for(let e of n){if(++c>=o.length&&c>=s)continue;let t=e._zod.run({value:o[c],issues:[]},i);t instanceof Promise?u.push(t.then(e=>ng(e,r,c))):ng(t,r,c)}if(t.rest)for(let e of o.slice(n.length)){c++;let n=t.rest._zod.run({value:e,issues:[]},i);n instanceof Promise?u.push(n.then(e=>ng(e,r,c))):ng(n,r,c)}return u.length?Promise.all(u).then(()=>r):r}});function ng(e,t,n){e.issues.length&&t.issues.push(...C(n,e.issues)),t.value[n]=e.value}let nz=c("$ZodRecord",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!O(i))return n.issues.push({expected:"record",code:"invalid_type",input:i,inst:e}),n;let o=[],u=t.keyType._zod.values;if(u){let a;n.value={};let s=new Set;for(let e of u)if("string"==typeof e||"number"==typeof e||"symbol"==typeof e){s.add("number"==typeof e?e.toString():e);let u=t.valueType._zod.run({value:i[e],issues:[]},r);u instanceof Promise?o.push(u.then(t=>{t.issues.length&&n.issues.push(...C(e,t.issues)),n.value[e]=t.value})):(u.issues.length&&n.issues.push(...C(e,u.issues)),n.value[e]=u.value)}for(let e in i)s.has(e)||(a=a??[]).push(e);a&&a.length>0&&n.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:a})}else for(let u of(n.value={},Reflect.ownKeys(i))){if("__proto__"===u)continue;let a=t.keyType._zod.run({value:u,issues:[]},r);if(a instanceof Promise)throw Error("Async schemas not supported in object keys currently");if(a.issues.length){"loose"===t.mode?n.value[u]=i[u]:n.issues.push({code:"invalid_key",origin:"record",issues:a.issues.map(e=>U(e,r,p())),input:u,path:[u],inst:e});continue}let s=t.valueType._zod.run({value:i[u],issues:[]},r);s instanceof Promise?o.push(s.then(e=>{e.issues.length&&n.issues.push(...C(u,e.issues)),n.value[a.value]=e.value})):(s.issues.length&&n.issues.push(...C(u,s.issues)),n.value[a.value]=s.value)}return o.length?Promise.all(o).then(()=>n):n}}),nb=c("$ZodMap",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!(i instanceof Map))return n.issues.push({expected:"map",code:"invalid_type",input:i,inst:e}),n;let o=[];for(let[u,a]of(n.value=new Map,i)){let s=t.keyType._zod.run({value:u,issues:[]},r),c=t.valueType._zod.run({value:a,issues:[]},r);s instanceof Promise||c instanceof Promise?o.push(Promise.all([s,c]).then(([t,o])=>{nw(t,o,n,u,i,e,r)})):nw(s,c,n,u,i,e,r)}return o.length?Promise.all(o).then(()=>n):n}});function nw(e,t,n,r,i,o,u){e.issues.length&&(N.has(typeof r)?n.issues.push(...C(r,e.issues)):n.issues.push({code:"invalid_key",origin:"map",input:i,inst:o,issues:e.issues.map(e=>U(e,u,p()))})),t.issues.length&&(N.has(typeof r)?n.issues.push(...C(r,t.issues)):n.issues.push({origin:"map",code:"invalid_element",input:i,inst:o,key:r,issues:t.issues.map(e=>U(e,u,p()))})),n.value.set(e.value,t.value)}let nk=c("$ZodSet",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{let i=n.value;if(!(i instanceof Set))return n.issues.push({input:i,inst:e,expected:"set",code:"invalid_type"}),n;let o=[];for(let e of(n.value=new Set,i)){let i=t.valueType._zod.run({value:e,issues:[]},r);i instanceof Promise?o.push(i.then(e=>nZ(e,n))):nZ(i,n)}return o.length?Promise.all(o).then(()=>n):n}});function nZ(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}let n$=c("$ZodEnum",(e,t)=>{tS.init(e,t);let n=m(t.entries),r=new Set(n);e._zod.values=r,e._zod.pattern=RegExp(`^(${n.filter(e=>N.has(typeof e)).map(e=>"string"==typeof e?E(e):e.toString()).join("|")})$`),e._zod.parse=(t,i)=>{let o=t.value;return r.has(o)||t.issues.push({code:"invalid_value",values:n,input:o,inst:e}),t}}),nS=c("$ZodLiteral",(e,t)=>{if(tS.init(e,t),0===t.values.length)throw Error("Cannot create literal schema with no valid values");let n=new Set(t.values);e._zod.values=n,e._zod.pattern=RegExp(`^(${t.values.map(e=>"string"==typeof e?E(e):e?E(e.toString()):String(e)).join("|")})$`),e._zod.parse=(r,i)=>{let o=r.value;return n.has(o)||r.issues.push({code:"invalid_value",values:t.values,input:o,inst:e}),r}}),nx=c("$ZodFile",(e,t)=>{tS.init(e,t),e._zod.parse=(t,n)=>{let r=t.value;return r instanceof File||t.issues.push({expected:"file",code:"invalid_type",input:r,inst:e}),t}}),nO=c("$ZodTransform",(e,t)=>{tS.init(e,t),e._zod.parse=(n,r)=>{if("backward"===r.direction)throw new d(e.constructor.name);
18let i=t.transform(n.value,n);if(r.async)return(i instanceof Promise?i:Promise.resolve(i)).then(e=>(n.value=e,n));if(i instanceof Promise)throw new l;return n.value=i,n}});function nI(e,t){return e.issues.length&&void 0===t?{issues:[],value:void 0}:e}let nN=c("$ZodOptional",(e,t)=>{tS.init(e,t),e._zod.optin="optional",e._zod.optout="optional",b(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),b(e._zod,"pattern",()=>{let e=t.innerType._zod.pattern;return e?RegExp(`^(${g(e.source)})?$`):void 0}),e._zod.parse=(e,n)=>{if("optional"===t.innerType._zod.optin){let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(t=>nI(t,e.value)):nI(r,e.value)}return void 0===e.value?e:t.innerType._zod.run(e,n)}}),nT=c("$ZodNullable",(e,t)=>{tS.init(e,t),b(e._zod,"optin",()=>t.innerType._zod.optin),b(e._zod,"optout",()=>t.innerType._zod.optout),b(e._zod,"pattern",()=>{let e=t.innerType._zod.pattern;return e?RegExp(`^(${g(e.source)}|null)$`):void 0}),b(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(e,n)=>null===e.value?e:t.innerType._zod.run(e,n)}),nE=c("$ZodDefault",(e,t)=>{tS.init(e,t),e._zod.optin="optional",b(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(e,n)=>{if("backward"===n.direction)return t.innerType._zod.run(e,n);if(void 0===e.value)return e.value=t.defaultValue,e;let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(e=>nA(e,t)):nA(r,t)}});function nA(e,t){return void 0===e.value&&(e.value=t.defaultValue),e}let nP=c("$ZodPrefault",(e,t)=>{tS.init(e,t),e._zod.optin="optional",b(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(e,n)=>("backward"===n.direction||void 0===e.value&&(e.value=t.defaultValue),t.innerType._zod.run(e,n))}),nj=c("$ZodNonOptional",(e,t)=>{tS.init(e,t),b(e._zod,"values",()=>{let e=t.innerType._zod.values;return e?new Set([...e].filter(e=>void 0!==e)):void 0}),e._zod.parse=(n,r)=>{let i=t.innerType._zod.run(n,r);return i instanceof Promise?i.then(t=>nF(t,e)):nF(i,e)}});function nF(e,t){return e.issues.length||void 0!==e.value||e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}let nD=c("$ZodSuccess",(e,t)=>{tS.init(e,t),e._zod.parse=(e,n)=>{if("backward"===n.direction)throw new d("ZodSuccess");let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(t=>(e.value=0===t.issues.length,e)):(e.value=0===r.issues.length,e)}}),nR=c("$ZodCatch",(e,t)=>{tS.init(e,t),b(e._zod,"optin",()=>t.innerType._zod.optin),b(e._zod,"optout",()=>t.innerType._zod.optout),b(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(e,n)=>{if("backward"===n.direction)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(r=>(e.value=r.value,r.issues.length&&(e.value=t.catchValue({...e,error:{issues:r.issues.map(e=>U(e,n,p()))},input:e.value}),e.issues=[]),e)):(e.value=r.value,r.issues.length&&(e.value=t.catchValue({...e,error:{issues:r.issues.map(e=>U(e,n,p()))},input:e.value}),e.issues=[]),e)}}),nC=c("$ZodNaN",(e,t)=>{tS.init(e,t),e._zod.parse=(t,n)=>("number"==typeof t.value&&Number.isNaN(t.value)||t.issues.push({input:t.value,inst:e,expected:"nan",code:"invalid_type"}),t)}),nJ=c("$ZodPipe",(e,t)=>{tS.init(e,t),b(e._zod,"values",()=>t.in._zod.values),b(e._zod,"optin",()=>t.in._zod.optin),b(e._zod,"optout",()=>t.out._zod.optout),b(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(e,n)=>{if("backward"===n.direction){let r=t.out._zod.run(e,n);return r instanceof Promise?r.then(e=>nU(e,t.in,n)):nU(r,t.in,n)}let r=t.in._zod.run(e,n);return r instanceof Promise?r.then(e=>nU(e,t.out,n)):nU(r,t.out,n)}});function nU(e,t,n){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}let nM=c("$ZodCodec",(e,t)=>{tS.init(e,t),b(e._zod,"values",()=>t.in._zod.values),b(e._zod,"optin",()=>t.in._zod.optin),b(e._zod,"optout",()=>t.out._zod.optout),b(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(e,n)=>{if("forward"===(n.direction||"forward")){let r=t.in._zod.run(e,n);return r instanceof Promise?r.then(e=>nL(e,t,n)):nL(r,t,n)}{let r=t.out._zod.run(e,n);return r instanceof Promise?r.then(e=>nL(e,t,n)):nL(r,t,n)}}});function nL(e,t,n){if(e.issues.length)return e.aborted=!0,e;if("forward"===(n.direction||"forward")){let r=t.transform(e.value,e);return r instanceof Promise?r.then(r=>nV(e,r,t.out,n)):nV(e,r,t.out,n)}{let r=t.reverseTransform(e.value,e);return r instanceof Promise?r.then(r=>nV(e,r,t.in,n)):nV(e,r,t.in,n)}}function nV(e,t,n,r){return e.issues.length?(e.aborted=!0,e):n._zod.run({value:t,issues:e.issues},r)}let nB=c("$ZodReadonly",(e,t)=>{tS.init(e,t),b(e._zod,"propValues",()=>t.innerType._zod.propValues),b(e._zod,"values",()=>t.innerType._zod.values),b(e._zod,"optin",()=>t.innerType?._zod?.optin),b(e._zod,"optout",()=>t.innerType?._zod?.optout),e._zod.parse=(e,n)=>{if("backward"===n.direction)return t.innerType._zod.run(e,n);let r=t.innerType._zod.run(e,n);return r instanceof Promise?r.then(nW):nW(r)}});function nW(e){return e.value=Object.freeze(e.value),e}let nq=c("$ZodTemplateLiteral",(e,t)=>{tS.init(e,t);let n=[];for(let e of t.parts)if("object"==typeof e&&null!==e){if(!e._zod.pattern)throw Error(`Invalid template literal part, no pattern found: ${[...e._zod.traits].shift()}`);let t=e._zod.pattern instanceof RegExp?e._zod.pattern.source:e._zod.pattern;if(!t)throw Error(`Invalid template literal part: ${e._zod.traits}`);let r=t.startsWith("^")?1:0,i=t.endsWith("$")?t.length-1:t.length;n.push(t.slice(r,i))}else if(null===e||T.has(typeof e))n.push(E(`${e}`));else throw Error(`Invalid template literal part: ${e}`);e._zod.pattern=RegExp(`^${n.join("")}$`),e._zod.parse=(n,r)=>("string"!=typeof n.value?n.issues.push({input:n.value,inst:e,expected:"template_literal",code:"invalid_type"}):(e._zod.pattern.lastIndex=0,e._zod.pattern.test(n.value)||n.issues.push({input:n.value,inst:e,code:"invalid_format",format:t.format??"template_literal",pattern:e._zod.pattern.source})),n)}),nK=c("$ZodFunction",(e,t)=>(tS.init(e,t),e._def=t,e._zod.def=t,e.implement=t=>{if("function"!=typeof t)throw Error("implement() must be called with a function");return function(...n){let r=Reflect.apply(t,this,e._def.input?G(e._def.input,n):n);return e._def.output?G(e._def.output,r):r}},e.implementAsync=t=>{if("function"!=typeof t)throw Error("implementAsync() must be called with a function");return async function(...n){let r=e._def.input?await Y(e._def.input,n):n,i=await Reflect.apply(t,this,r);return e._def.output?await Y(e._def.output,i):i}},e._zod.parse=(t,n)=>("function"!=typeof t.value?t.issues.push({code:"invalid_type",expected:"function",input:t.value,inst:e}):e._def.output&&"promise"===e._def.output._zod.def.type?t.value=e.implementAsync(t.value):t.value=e.implement(t.value),t),e.input=(...t)=>new e.constructor(Array.isArray(t[0])?{type:"function",input:new ny({type:"tuple",items:t[0],rest:t[1]}),output:e._def.output}:{type:"function",input:t[0],output:e._def.output}),e.output=t=>new e.constructor({type:"function",input:e._def.input,output:t}),e)),nG=c("$ZodPromise",(e,t)=>{tS.init(e,t),e._zod.parse=(e,n)=>Promise.resolve(e.value).then(e=>t.innerType._zod.run({value:e,issues:[]},n))}),nX=c("$ZodLazy",(e,t)=>{tS.init(e,t),b(e._zod,"innerType",()=>t.getter()),b(e._zod,"pattern",()=>e._zod.innerType?._zod?.pattern),b(e._zod,"propValues",()=>e._zod.innerType?._zod?.propValues),b(e._zod,"optin",()=>e._zod.innerType?._zod?.optin??void 0),b(e._zod,"optout",()=>e._zod.innerType?._zod?.optout??void 0),e._zod.parse=(t,n)=>e._zod.innerType._zod.run(t,n)}),nY=c("$ZodCustom",(e,t)=>{te.init(e,t),tS.init(e,t),e._zod.parse=(e,t)=>e,e._zod.check=n=>{let r=n.value,i=t.fn(r);if(i instanceof Promise)return i.then(t=>nH(t,n,r,e));nH(i,n,r,e)}});function nH(e,t,n,r){if(!e){let e={code:"custom",input:n,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(e.params=r._zod.def.params),t.issues.push(V(e))}}let nQ=e=>{let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":"number";case"object":if(Array.isArray(e))return"array";if(null===e)return"null";if(Object.getPrototypeOf(e)!==Object.prototype&&e.constructor)return e.constructor.name}return t};Symbol("ZodOutput"),Symbol("ZodInput");class n0{constructor(){this._map=new WeakMap,this._idmap=new Map}add(e,...t){let n=t[0];if(this._map.set(e,n),n&&"object"==typeof n&&"id"in n){if(this._idmap.has(n.id))throw Error(`ID ${n.id} already exists in the registry`);this._idmap.set(n.id,e)}return this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(e){let t=this._map.get(e);return t&&"object"==typeof t&&"id"in t&&this._idmap.delete(t.id),this._map.delete(e),this}get(e){let t=e._zod.parent;if(t){let n={...this.get(t)??{}};delete n.id;let r={...n,...this._map.get(e)};return Object.keys(r).length?r:void 0}return this._map.get(e)}has(e){return this._map.has(e)}}(r=globalThis).__zod_globalRegistry??(r.__zod_globalRegistry=new n0);let n1=globalThis.__zod_globalRegistry;function n4(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...P(t)})}function n2(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...P(t)})}function n9(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...P(t)})}function n6(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...P(t)})}function n3(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...P(t)})}function n5(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...P(t)})}function n7(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...P(t)})}function n8(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...P(t)})}function re(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...P(t)})}function rt(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...P(t)})}function rn(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...P(t)})}function rr(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...P(t)})}function ri(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...P(t)})}function ro(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...P(t)})}function ru(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...P(t)})}function ra(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...P(t)})}function rs(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...P(t)})}function rc(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...P(t)})}function rl(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...P(t)})}function rd(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...P(t)})}function rf(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...P(t)})}function rp(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...P(t)})}function rm(e,t){return new tn({check:"less_than",...P(t),value:e,inclusive:!1})}function rh(e,t){return new tn({check:"less_than",...P(t),value:e,inclusive:!0})}function r_(e,t){return new tr({check:"greater_than",...P(t),value:e,inclusive:!1})}function rv(e,t){return new tr({check:"greater_than",...P(t),value:e,inclusive:!0})}function ry(e){return r_(0,e)}function rg(e){return rm(0,e)}function rz(e){return rh(0,e)}function rb(e){return rv(0,e)}function rw(e,t){return new ti({check:"multiple_of",...P(t),value:e})}function rk(e,t){return new ta({check:"max_size",...P(t),maximum:e})}function rZ(e,t){return new ts({check:"min_size",...P(t),minimum:e})}function r$(e,t){return new tc({check:"size_equals",...P(t),size:e})}function rS(e,t){return new tl({check:"max_length",...P(t),maximum:e})}function rx(e,t){return new td({check:"min_length",...P(t),minimum:e})}function rO(e,t){return new tf({check:"length_equals",...P(t),length:e})}function rI(e,t){return new tm({check:"string_format",format:"regex",...P(t),pattern:e})}function rN(e){return new th({check:"string_format",format:"lowercase",...P(e)})}
18function rT(e){return new t_({check:"string_format",format:"uppercase",...P(e)})}function rE(e,t){return new tv({check:"string_format",format:"includes",...P(t),includes:e})}function rA(e,t){return new ty({check:"string_format",format:"starts_with",...P(t),prefix:e})}function rP(e,t){return new tg({check:"string_format",format:"ends_with",...P(t),suffix:e})}function rj(e,t,n){return new tb({check:"property",property:e,schema:t,...P(n)})}function rF(e,t){return new tw({check:"mime_type",mime:e,...P(t)})}function rD(e){return new tk({check:"overwrite",tx:e})}function rR(e){return rD(t=>t.normalize(e))}function rC(){return rD(e=>e.trim())}function rJ(){return rD(e=>e.toLowerCase())}function rU(){return rD(e=>e.toUpperCase())}function rM(){return rD(e=>e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,""))}function rL(e,t,n,r={}){let i=P(r),o={...P(r),check:"string_format",type:"string",format:t,fn:"function"==typeof n?n:e=>n.test(e),...i};return n instanceof RegExp&&(o.pattern=n),new e(o)}function rV(e){let t=e?.target??"draft-2020-12";return"draft-4"===t&&(t="draft-04"),"draft-7"===t&&(t="draft-07"),{processors:e.processors??{},metadataRegistry:e?.metadata??n1,target:t,unrepresentable:e?.unrepresentable??"throw",override:e?.override??(()=>{}),io:e?.io??"output",counter:0,seen:new Map,cycles:e?.cycles??"ref",reused:e?.reused??"inline",external:e?.external??void 0}}function rB(e,t,n={path:[],schemaPath:[]}){var r;let i=e._zod.def,o=t.seen.get(e);if(o)return o.count++,n.schemaPath.includes(e)&&(o.cycle=n.path),o.schema;let u={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,u);let a=e._zod.toJSONSchema?.();if(a)u.schema=a;else{let r={...n,schemaPath:[...n.schemaPath,e],path:n.path},o=e._zod.parent;if(o)u.ref=o,rB(o,t,r),t.seen.get(o).isParent=!0;else if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,u.schema,r);else{let n=u.schema,o=t.processors[i.type];if(!o)throw Error(`[toJSONSchema]: Non-representable type encountered: ${i.type}`);o(e,t,n,r)}}let s=t.metadataRegistry.get(e);return s&&Object.assign(u.schema,s),"input"===t.io&&function e(t,n){let r=n??{seen:new Set};if(r.seen.has(t))return!1;r.seen.add(t);let i=t._zod.def;if("transform"===i.type)return!0;if("array"===i.type)return e(i.element,r);if("set"===i.type)return e(i.valueType,r);if("lazy"===i.type)return e(i.getter(),r);if("promise"===i.type||"optional"===i.type||"nonoptional"===i.type||"nullable"===i.type||"readonly"===i.type||"default"===i.type||"prefault"===i.type)return e(i.innerType,r);if("intersection"===i.type)return e(i.left,r)||e(i.right,r);if("record"===i.type||"map"===i.type)return e(i.keyType,r)||e(i.valueType,r);if("pipe"===i.type)return e(i.in,r)||e(i.out,r);if("object"===i.type){for(let t in i.shape)if(e(i.shape[t],r))return!0;return!1}if("union"===i.type){for(let t of i.options)if(e(t,r))return!0;return!1}if("tuple"===i.type){for(let t of i.items)if(e(t,r))return!0;if(i.rest&&e(i.rest,r))return!0}return!1}(e)&&(delete u.schema.examples,delete u.schema.default),"input"===t.io&&u.schema._prefault&&((r=u.schema).default??(r.default=u.schema._prefault)),delete u.schema._prefault,t.seen.get(e).schema}function rW(e,t){let n=e.seen.get(t);if(!n)throw Error("Unprocessed schema. This is a bug in Zod.");let r=t=>{let r="draft-2020-12"===e.target?"$defs":"definitions";if(e.external){let n=e.external.registry.get(t[0])?.id,i=e.external.uri??(e=>e);if(n)return{ref:i(n)};let o=t[1].defId??t[1].schema.id??`schema${e.counter++}`;return t[1].defId=o,{defId:o,ref:`${i("__shared")}#/${r}/${o}`}}if(t[1]===n)return{ref:"#"};let i=`#/${r}/`,o=t[1].schema.id??`__schema${e.counter++}`;return{defId:o,ref:i+o}},i=e=>{if(e[1].schema.$ref)return;let t=e[1],{ref:n,defId:i}=r(e);t.def={...t.schema},i&&(t.defId=i);let o=t.schema;for(let e in o)delete o[e];o.$ref=n};if("throw"===e.cycles)for(let t of e.seen.entries()){let e=t[1];if(e.cycle)throw Error(`Cycle detected: #/${e.cycle?.join("/")}/<root> 19 20Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let n of e.seen.entries()){let r=n[1];if(t===n[0]){i(n);continue}if(e.external){let r=e.external.registry.get(n[0])?.id;if(t!==n[0]&&r){i(n);continue}}if(e.metadataRegistry.get(n[0])?.id||r.cycle||r.count>1&&"ref"===e.reused){i(n);continue}}}function rq(e,t){let n=e.seen.get(t);if(!n)throw Error("Unprocessed schema. This is a bug in Zod.");let r=t=>{let n=e.seen.get(t),i=n.def??n.schema,o={...i};if(null===n.ref)return;let u=n.ref;if(n.ref=null,u){r(u);let t=e.seen.get(u).schema;t.$ref&&("draft-07"===e.target||"draft-04"===e.target||"openapi-3.0"===e.target)?(i.allOf=i.allOf??[],i.allOf.push(t)):(Object.assign(i,t),Object.assign(i,o))}n.isParent||e.override({zodSchema:t,jsonSchema:i,path:n.path??[]})};for(let t of[...e.seen.entries()].reverse())r(t[0]);let i={};
20if("draft-2020-12"===e.target?i.$schema="https://json-schema.org/draft/2020-12/schema":"draft-07"===e.target?i.$schema="http://json-schema.org/draft-07/schema#":"draft-04"===e.target?i.$schema="http://json-schema.org/draft-04/schema#":e.target,e.external?.uri){let n=e.external.registry.get(t)?.id;if(!n)throw Error("Schema is missing an `id` property");i.$id=e.external.uri(n)}Object.assign(i,n.def??n.schema);let o=e.external?.defs??{};for(let t of e.seen.entries()){let e=t[1];e.def&&e.defId&&(o[e.defId]=e.def)}e.external||Object.keys(o).length>0&&("draft-2020-12"===e.target?i.$defs=o:i.definitions=o);try{let e=JSON.parse(JSON.stringify(i));return Object.defineProperty(e,"~standard",{value:{...t["~standard"],jsonSchema:{input:rG(t,"input"),output:rG(t,"output")}},enumerable:!1,writable:!1}),e}catch(e){throw Error("Error converting schema to JSON.")}}let rK=(e,t={})=>n=>{let r=rV({...n,processors:t});return rB(e,r),rW(r,e),rq(r,e)},rG=(e,t)=>n=>{let{libraryOptions:r,target:i}=n??{},o=rV({...r??{},target:i,io:t,processors:{}});return rB(e,o),rW(o,e),rq(o,e)},rX={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},rY=(e,t,n,r)=>{n.type="string";let{minimum:i,maximum:o,format:u,patterns:a,contentEncoding:s}=e._zod.bag;if("number"==typeof i&&(n.minLength=i),"number"==typeof o&&(n.maxLength=o),u&&(n.format=rX[u]??u,""===n.format&&delete n.format),s&&(n.contentEncoding=s),a&&a.size>0){let e=[...a];1===e.length?n.pattern=e[0].source:e.length>1&&(n.allOf=[...e.map(e=>({..."draft-07"===t.target||"draft-04"===t.target||"openapi-3.0"===t.target?{type:"string"}:{},pattern:e.source}))])}},rH=(e,t,n,r)=>{let{minimum:i,maximum:o,format:u,multipleOf:a,exclusiveMaximum:s,exclusiveMinimum:c}=e._zod.bag;"string"==typeof u&&u.includes("int")?n.type="integer":n.type="number","number"==typeof c&&("draft-04"===t.target||"openapi-3.0"===t.target?(n.minimum=c,n.exclusiveMinimum=!0):n.exclusiveMinimum=c),"number"==typeof i&&(n.minimum=i,"number"==typeof c&&"draft-04"!==t.target&&(c>=i?delete n.minimum:delete n.exclusiveMinimum)),"number"==typeof s&&("draft-04"===t.target||"openapi-3.0"===t.target?(n.maximum=s,n.exclusiveMaximum=!0):n.exclusiveMaximum=s),"number"==typeof o&&(n.maximum=o,"number"==typeof s&&"draft-04"!==t.target&&(s<=o?delete n.maximum:delete n.exclusiveMaximum)),"number"==typeof a&&(n.multipleOf=a)},rQ=(e,t,n,r)=>{n.type="boolean"},r0=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("BigInt cannot be represented in JSON Schema")},r1=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Symbols cannot be represented in JSON Schema")},r4=(e,t,n,r)=>{"openapi-3.0"===t.target?(n.type="string",n.nullable=!0,n.enum=[null]):n.type="null"},r2=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Undefined cannot be represented in JSON Schema")},r9=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Void cannot be represented in JSON Schema")},r6=(e,t,n,r)=>{n.not={}},r3=(e,t,n,r)=>{},r5=(e,t,n,r)=>{},r7=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Date cannot be represented in JSON Schema")},r8=(e,t,n,r)=>{let i=m(e._zod.def.entries);i.every(e=>"number"==typeof e)&&(n.type="number"),i.every(e=>"string"==typeof e)&&(n.type="string"),n.enum=i},ie=(e,t,n,r)=>{let i=e._zod.def,o=[];for(let e of i.values)if(void 0===e){if("throw"===t.unrepresentable)throw Error("Literal `undefined` cannot be represented in JSON Schema")}else if("bigint"==typeof e){if("throw"===t.unrepresentable)throw Error("BigInt literals cannot be represented in JSON Schema");o.push(Number(e))}else o.push(e);if(0===o.length);else if(1===o.length){let e=o[0];n.type=null===e?"null":typeof e,"draft-04"===t.target||"openapi-3.0"===t.target?n.enum=[e]:n.const=e}else o.every(e=>"number"==typeof e)&&(n.type="number"),o.every(e=>"string"==typeof e)&&(n.type="string"),o.every(e=>"boolean"==typeof e)&&(n.type="boolean"),o.every(e=>null===e)&&(n.type="null"),n.enum=o},it=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("NaN cannot be represented in JSON Schema")},ir=(e,t,n,r)=>{let i=e._zod.pattern;if(!i)throw Error("Pattern not found in template literal");n.type="string",n.pattern=i.source},ii=(e,t,n,r)=>{let i={type:"string",format:"binary",contentEncoding:"binary"},{minimum:o,maximum:u,mime:a}=e._zod.bag;void 0!==o&&(i.minLength=o),void 0!==u&&(i.maxLength=u),a?1===a.length?(i.contentMediaType=a[0],Object.assign(n,i)):n.anyOf=a.map(e=>({...i,contentMediaType:e})):Object.assign(n,i)},io=(e,t,n,r)=>{n.type="boolean"},iu=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Custom types cannot be represented in JSON Schema")},ia=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Function types cannot be represented in JSON Schema")},is=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Transforms cannot be represented in JSON Schema")},ic=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Map cannot be represented in JSON Schema")},il=(e,t,n,r)=>{if("throw"===t.unrepresentable)throw Error("Set cannot be represented in JSON Schema")},id=(e,t,n,r)=>{let i=e._zod.def,{minimum:o,maximum:u}=e._zod.bag;"number"==typeof o&&(n.minItems=o),"number"==typeof u&&(n.maxItems=u),n.type="array",n.items=rB(i.element,t,{...r,path:[...r.path,"items"]})},ip=(e,t,n,r)=>{let i=e._zod.def;n.type="object",n.properties={};let o=i.shape;for(let e in o)n.properties[e]=rB(o[e],t,{...r,path:[...r.path,"properties",e]});let u=new Set([...new Set(Object.keys(o))].filter(e=>{let n=i.shape[e]._zod;return"input"===t.io?void 0===n.optin:void 0===n.optout}));u.size>0&&(n.required=Array.from(u)),i.catchall?._zod.def.type==="never"?n.additionalProperties=!1:i.catchall?i.catchall&&(n.additionalProperties=rB(i.catchall,t,{...r,path:[...r.path,"additionalProperties"]})):"output"===t.io&&(n.additionalProperties=!1)},im=(e,t,n,r)=>{let i=e._zod.def,o=!1===i.inclusive,u=i.options.map((e,n)=>rB(e,t,{...r,path:[...r.path,o?"oneOf":"anyOf",n]}));o?n.oneOf=u:n.anyOf=u},ih=(e,t,n,r)=>{let i=e._zod.def,o=rB(i.left,t,{...r,path:[...r.path,"allOf",0]}),u=rB(i.right,t,{...r,path:[...r.path,"allOf",1]}),a=[..."allOf"in o&&1===Object.keys(o).length?o.allOf:[o],..."allOf"in u&&1===Object.keys(u).length?u.allOf:[u]];n.allOf=a},i_=(e,t,n,r)=>{let i=e._zod.def;n.type="array";
20let o="draft-2020-12"===t.target?"prefixItems":"items",u="draft-2020-12"===t.target?"items":"openapi-3.0"===t.target?"items":"additionalItems",a=i.items.map((e,n)=>rB(e,t,{...r,path:[...r.path,o,n]})),s=i.rest?rB(i.rest,t,{...r,path:[...r.path,u,..."openapi-3.0"===t.target?[i.items.length]:[]]}):null;"draft-2020-12"===t.target?(n.prefixItems=a,s&&(n.items=s)):"openapi-3.0"===t.target?(n.items={anyOf:a},s&&n.items.anyOf.push(s),n.minItems=a.length,s||(n.maxItems=a.length)):(n.items=a,s&&(n.additionalItems=s));let{minimum:c,maximum:l}=e._zod.bag;"number"==typeof c&&(n.minItems=c),"number"==typeof l&&(n.maxItems=l)},iv=(e,t,n,r)=>{let i=e._zod.def;n.type="object",("draft-07"===t.target||"draft-2020-12"===t.target)&&(n.propertyNames=rB(i.keyType,t,{...r,path:[...r.path,"propertyNames"]})),n.additionalProperties=rB(i.valueType,t,{...r,path:[...r.path,"additionalProperties"]})},iy=(e,t,n,r)=>{let i=e._zod.def,o=rB(i.innerType,t,r),u=t.seen.get(e);"openapi-3.0"===t.target?(u.ref=i.innerType,n.nullable=!0):n.anyOf=[o,{type:"null"}]},ig=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType},iz=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType,n.default=JSON.parse(JSON.stringify(i.defaultValue))},ib=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType,"input"===t.io&&(n._prefault=JSON.parse(JSON.stringify(i.defaultValue)))},iw=(e,t,n,r)=>{let i;let o=e._zod.def;rB(o.innerType,t,r),t.seen.get(e).ref=o.innerType;try{i=o.catchValue(void 0)}catch{throw Error("Dynamic catch values are not supported in JSON Schema")}n.default=i},ik=(e,t,n,r)=>{let i=e._zod.def,o="input"===t.io?"transform"===i.in._zod.def.type?i.out:i.in:i.out;rB(o,t,r),t.seen.get(e).ref=o},iZ=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType,n.readOnly=!0},i$=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType},iS=(e,t,n,r)=>{let i=e._zod.def;rB(i.innerType,t,r),t.seen.get(e).ref=i.innerType},ix=(e,t,n,r)=>{let i=e._zod.innerType;rB(i,t,r),t.seen.get(e).ref=i},iO=c("ZodISODateTime",(e,t)=>{tJ.init(e,t),i0.init(e,t)});function iI(e){return new iO({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...P(e)})}let iN=c("ZodISODate",(e,t)=>{tU.init(e,t),i0.init(e,t)});function iT(e){return new iN({type:"string",format:"date",check:"string_format",...P(e)})}let iE=c("ZodISOTime",(e,t)=>{tM.init(e,t),i0.init(e,t)});function iA(e){return new iE({type:"string",format:"time",check:"string_format",precision:null,...P(e)})}let iP=c("ZodISODuration",(e,t)=>{tL.init(e,t),i0.init(e,t)});function ij(e){return new iP({type:"string",format:"duration",check:"string_format",...P(e)})}let iF=(e,t)=>{W.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:t=>(function(e,t=e=>e.message){let n={_errors:[]},r=e=>{for(let i of e.issues)if("invalid_union"===i.code&&i.errors.length)i.errors.map(e=>r({issues:e}));else if("invalid_key"===i.code)r({issues:i.issues});else if("invalid_element"===i.code)r({issues:i.issues});else if(0===i.path.length)n._errors.push(t(i));else{let e=n,r=0;for(;r<i.path.length;){let n=i.path[r];r===i.path.length-1?(e[n]=e[n]||{_errors:[]},e[n]._errors.push(t(i))):e[n]=e[n]||{_errors:[]},e=e[n],r++}}};return r(e),n})(e,t)},flatten:{value:t=>(function(e,t=e=>e.message){let n={},r=[];for(let i of e.issues)i.path.length>0?(n[i.path[0]]=n[i.path[0]]||[],n[i.path[0]].push(t(i))):r.push(t(i));return{formErrors:r,fieldErrors:n}})(e,t)},addIssue:{value:t=>{e.issues.push(t),e.message=JSON.stringify(e.issues,_,2)}},addIssues:{value:t=>{e.issues.push(...t),e.message=JSON.stringify(e.issues,_,2)}},isEmpty:{get:()=>0===e.issues.length}})};c("ZodError",iF);let iD=c("ZodError",iF,{Parent:Error}),iR=K(iD),iC=X(iD),iJ=H(iD),iU=ee(iD),iM=(e,t,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return K(iD)(e,t,r)},iL=(e,t,n)=>K(iD)(e,t,n),iV=async(e,t,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return X(iD)(e,t,r)},iB=async(e,t,n)=>
20X(iD)(e,t,n),iW=(e,t,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return H(iD)(e,t,r)},iq=(e,t,n)=>H(iD)(e,t,n),iK=async(e,t,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return ee(iD)(e,t,r)},iG=async(e,t,n)=>ee(iD)(e,t,n),iX=c("ZodType",(e,t)=>(tS.init(e,t),Object.assign(e["~standard"],{jsonSchema:{input:rG(e,"input"),output:rG(e,"output")}}),e.toJSONSchema=rK(e,{}),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...n)=>e.clone(k(t,{checks:[...t.checks??[],...n.map(e=>"function"==typeof e?{_zod:{check:e,def:{check:"custom"},onattach:[]}}:e)]})),e.clone=(t,n)=>A(e,t,n),e.brand=()=>e,e.register=(t,n)=>(t.add(e,n),e),e.parse=(t,n)=>iR(e,t,n,{callee:e.parse}),e.safeParse=(t,n)=>iJ(e,t,n),e.parseAsync=async(t,n)=>iC(e,t,n,{callee:e.parseAsync}),e.safeParseAsync=async(t,n)=>iU(e,t,n),e.spa=e.safeParseAsync,e.encode=(t,n)=>iM(e,t,n),e.decode=(t,n)=>iL(e,t,n),e.encodeAsync=async(t,n)=>iV(e,t,n),e.decodeAsync=async(t,n)=>iB(e,t,n),e.safeEncode=(t,n)=>iW(e,t,n),e.safeDecode=(t,n)=>iq(e,t,n),e.safeEncodeAsync=async(t,n)=>iK(e,t,n),e.safeDecodeAsync=async(t,n)=>iG(e,t,n),e.refine=(t,n)=>e.check(ad(t,n)),e.superRefine=t=>e.check(af(t)),e.overwrite=t=>
20e.check(rD(t)),e.optional=()=>uM(e),e.nullable=()=>uV(e),e.nullish=()=>uM(uV(e)),e.nonoptional=t=>uY(e,t),e.array=()=>us(e),e.or=t=>uh([e,t]),e.and=t=>ub(e,t),e.transform=t=>u6(e,uJ(t)),e.default=t=>uq(e,t),e.prefault=t=>uG(e,t),e.catch=t=>u1(e,t),e.pipe=t=>u6(e,t),e.readonly=()=>u8(e),e.describe=t=>{let n=e.clone();return n1.add(n,{description:t}),n},Object.defineProperty(e,"description",{get:()=>n1.get(e)?.description,configurable:!0}),e.meta=(...t)=>{if(0===t.length)return n1.get(e);let n=e.clone();return n1.add(n,t[0]),n},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),iY=c("_ZodString",(e,t)=>{tx.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>rY(e,t,n,r);let n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,e.regex=(...t)=>e.check(rI(...t)),e.includes=(...t)=>e.check(rE(...t)),e.startsWith=(...t)=>e.check(rA(...t)),e.endsWith=(...t)=>e.check(rP(...t)),e.min=(...t)=>e.check(rx(...t)),e.max=(...t)=>e.check(rS(...t)),e.length=(...t)=>e.check(rO(...t)),e.nonempty=(...t)=>e.check(rx(1,...t)),e.lowercase=t=>e.check(rN(t)),e.uppercase=t=>e.check(rT(t)),e.trim=()=>e.check(rC()),e.normalize=(...t)=>e.check(rR(...t)),e.toLowerCase=()=>e.check(rJ()),e.toUpperCase=()=>e.check(rU()),e.slugify=()=>e.check(rM())}),iH=c("ZodString",(e,t)=>{tx.init(e,t),iY.init(e,t),e.email=t=>e.check(n4(i1,t)),e.url=t=>e.check(n7(oe,t)),e.jwt=t=>e.check(rp(oA,t)),e.emoji=t=>e.check(n8(or,t)),e.guid=t=>e.check(n2(i2,t)),e.uuid=t=>e.check(n9(i6,t)),e.uuidv4=t=>e.check(n6(i6,t)),e.uuidv6=t=>e.check(n3(i6,t)),e.uuidv7=t=>e.check(n5(i6,t)),e.nanoid=t=>e.check(re(oo,t)),e.guid=t=>e.check(n2(i2,t)),e.cuid=t=>e.check(rt(oa,t)),e.cuid2=t=>e.check(rn(oc,t)),e.ulid=t=>e.check(rr(od,t)),e.base64=t=>e.check(rl(ox,t)),e.base64url=t=>e.check(rd(oI,t)),e.xid=t=>e.check(ri(op,t)),e.ksuid=t=>e.check(ro(oh,t)),e.ipv4=t=>e.check(ru(ov,t)),e.ipv6=t=>e.check(ra(ob,t)),e.cidrv4=t=>e.check(rs(ok,t)),e.cidrv6=t=>e.check(rc(o$,t)),e.e164=t=>e.check(rf(oT,t)),e.datetime=t=>e.check(iI(t)),e.date=t=>e.check(iT(t)),e.time=t=>e.check(iA(t)),e.duration=t=>e.check(ij(t))});function iQ(e){return new iH({type:"string",...P(e)})}let i0=c("ZodStringFormat",(e,t)=>{tO.init(e,t),iY.init(e,t)}),i1=c("ZodEmail",(e,t)=>{tT.init(e,t),i0.init(e,t)});function i4(e){return n4(i1,e)}let i2=c("ZodGUID",(e,t)=>{tI.init(e,t),i0.init(e,t)});function i9(e){return n2(i2,e)}let i6=c("ZodUUID",(e,t)=>{tN.init(e,t),i0.init(e,t)});function i3(e){return n9(i6,e)}function i5(e){return n6(i6,e)}function i7(e){return n3(i6,e)}function i8(e){return n5(i6,e)}let oe=c("ZodURL",(e,t)=>{tE.init(e,t),i0.init(e,t)});function ot(e){return n7(oe,e)}function on(e){return n7(oe,{protocol:/^https?$/,hostname:eN,...P(e)})}let or=c("ZodEmoji",(e,t)=>{tA.init(e,t),i0.init(e,t)});function oi(e){return n8(or,e)}let oo=c("ZodNanoID",(e,t)=>{tP.init(e,t),i0.init(e,t)});function ou(e){return re(oo,e)}let oa=c("ZodCUID",(e,t)=>{tj.init(e,t),i0.init(e,t)});function os(e){return rt(oa,e)}let oc=c("ZodCUID2",(e,t)=>{tF.init(e,t),i0.init(e,t)});function ol(e){return rn(oc,e)}let od=c("ZodULID",(e,t)=>{tD.init(e,t),i0.init(e,t)});function of(e){return rr(od,e)}let op=c("ZodXID",(e,t)=>{tR.init(e,t),i0.init(e,t)});function om(e){return ri(op,e)}let oh=c("ZodKSUID",(e,t)=>{tC.init(e,t),i0.init(e,t)});function o_(e){return ro(oh,e)}let ov=c("ZodIPv4",(e,t)=>{tV.init(e,t),i0.init(e,t)});function oy(e){return ru(ov,e)}let og=c("ZodMAC",(e,t)=>{tW.init(e,t),i0.init(e,t)});function oz(e){return new og({type:"string",format:"mac",check:"string_format",abort:!1,...P(e)})}let ob=c("ZodIPv6",(e,t)=>{tB.init(e,t),i0.init(e,t)});function ow(e){return ra(ob,e)}let ok=c("ZodCIDRv4",(e,t)=>{tq.init(e,t),i0.init(e,t)});function oZ(e){return rs(ok,e)}let o$=c("ZodCIDRv6",(e,t)=>{tK.init(e,t),i0.init(e,t)});function oS(e){return rc(o$,e)}let ox=c("ZodBase64",(e,t)=>{tX.init(e,t),i0.init(e,t)});function oO(e){return rl(ox,e)}let oI=c("ZodBase64URL",(e,t)=>{tY.init(e,t),i0.init(e,t)});function oN(e){return rd(oI,e)}let oT=c("ZodE164",(e,t)=>{tH.init(e,t),i0.init(e,t)});function oE(e){return rf(oT,e)}let oA=c("ZodJWT",(e,t)=>{tQ.init(e,t),i0.init(e,t)});function oP(e){return rp(oA,e)}
20let oj=c("ZodCustomStringFormat",(e,t)=>{t0.init(e,t),i0.init(e,t)});function oF(e,t,n={}){return rL(oj,e,t,n)}function oD(e){return rL(oj,"hostname",eI,e)}function oR(e){return rL(oj,"hex",eW,e)}function oC(e,t){let n=t?.enc??"hex",r=`${e}_${n}`,i=o[r];if(!i)throw Error(`Unrecognized hash format: ${r}`);return rL(oj,r,i,t)}let oJ=c("ZodNumber",(e,t)=>{t1.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>rH(e,t,n,r),e.gt=(t,n)=>e.check(r_(t,n)),e.gte=(t,n)=>e.check(rv(t,n)),e.min=(t,n)=>e.check(rv(t,n)),e.lt=(t,n)=>e.check(rm(t,n)),e.lte=(t,n)=>e.check(rh(t,n)),e.max=(t,n)=>e.check(rh(t,n)),e.int=t=>e.check(oL(t)),e.safe=t=>e.check(oL(t)),e.positive=t=>e.check(r_(0,t)),e.nonnegative=t=>e.check(rv(0,t)),e.negative=t=>e.check(rm(0,t)),e.nonpositive=t=>e.check(rh(0,t)),e.multipleOf=(t,n)=>e.check(rw(t,n)),e.step=(t,n)=>e.check(rw(t,n)),e.finite=()=>e;let n=e._zod.bag;e.minValue=Math.max(n.minimum??Number.NEGATIVE_INFINITY,n.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(n.maximum??Number.POSITIVE_INFINITY,n.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(n.format??"").includes("int")||Number.isSafeInteger(n.multipleOf??.5),e.isFinite=!0,e.format=n.format??null});function oU(e){return new oJ({type:"number",checks:[],...P(e)})}let oM=c("ZodNumberFormat",(e,t)=>{t4.init(e,t),oJ.init(e,t)});function oL(e){return new oM({type:"number",check:"number_format",abort:!1,format:"safeint",...P(e)})}function oV(e){return new oM({type:"number",check:"number_format",abort:!1,format:"float32",...P(e)})}function oB(e){return new oM({type:"number",check:"number_format",abort:!1,format:"float64",...P(e)})}function oW(e){return new oM({type:"number",check:"number_format",abort:!1,format:"int32",...P(e)})}function oq(e){return new oM({type:"number",check:"number_format",abort:!1,format:"uint32",...P(e)})}let oK=c("ZodBoolean",(e,t)=>{t2.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>rQ(e,t,n,r)});function oG(e){return new oK({type:"boolean",...P(e)})}let oX=c("ZodBigInt",(e,t)=>{t9.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r0(e,t,n,r),e.gte=(t,n)=>e.check(rv(t,n)),e.min=(t,n)=>e.check(rv(t,n)),e.gt=(t,n)=>e.check(r_(t,n)),e.gte=(t,n)=>e.check(rv(t,n)),e.min=(t,n)=>e.check(rv(t,n)),e.lt=(t,n)=>e.check(rm(t,n)),e.lte=(t,n)=>e.check(rh(t,n)),e.max=(t,n)=>e.check(rh(t,n)),e.positive=t=>e.check(r_(BigInt(0),t)),e.negative=t=>e.check(rm(BigInt(0),t)),e.nonpositive=t=>e.check(rh(BigInt(0),t)),e.nonnegative=t=>e.check(rv(BigInt(0),t)),e.multipleOf=(t,n)=>e.check(rw(t,n));let n=e._zod.bag;e.minValue=n.minimum??null,e.maxValue=n.maximum??null,e.format=n.format??null});function oY(e){return new oX({type:"bigint",...P(e)})}let oH=c("ZodBigIntFormat",(e,t)=>{t6.init(e,t),oX.init(e,t)});function oQ(e){return new oH({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...P(e)})}function o0(e){return new oH({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...P(e)})}let o1=c("ZodSymbol",(e,t)=>{t3.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r1(e,t,n,r)});function o4(e){return new o1({type:"symbol",...P(e)})}let o2=c("ZodUndefined",(e,t)=>{t5.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r2(e,t,n,r)});function o9(e){return new o2({type:"undefined",...P(e)})}let o6=c("ZodNull",(e,t)=>{t7.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r4(e,t,n,r)});function o3(e){return new o6({type:"null",...P(e)})}let o5=c("ZodAny",(e,t)=>{t8.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r3(e,t,n,r)});function o7(){return new o5({type:"any"})}let o8=c("ZodUnknown",(e,t)=>{ne.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r5(e,t,n,r)});function ue(){return new o8({type:"unknown"})}let ut=c("ZodNever",(e,t)=>{nt.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r6(e,t,n,r)});function un(e){return new ut({type:"never",...P(e)})}let ur=c("ZodVoid",(e,t)=>{nn.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r9(e,t,n,r)});function ui(e){return new ur({type:"void",...P(e)})}let uo=c("ZodDate",(e,t)=>{nr.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r7(e,t,n,r),e.min=(t,n)=>e.check(rv(t,n)),e.max=(t,n)=>e.check(rh(t,n));let n=e._zod.bag;e.minDate=n.minimum?new Date(n.minimum):null,e.maxDate=n.maximum?new Date(n.maximum):null});function uu(e){return new uo({type:"date",...P(e)})}let ua=c("ZodArray",(e,t)=>{no.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>id(e,t,n,r),e.element=t.element,e.min=(t,n)=>e.check(rx(t,n)),e.nonempty=t=>e.check(rx(1,t)),e.max=(t,n)=>e.check(rS(t,n)),e.length=(t,n)=>e.check(rO(t,n)),e.unwrap=()=>e.element});function us(e,t){return new ua({type:"array",element:e,...P(t)})}function uc(e){return uA(Object.keys(e._zod.def.shape))}let ul=c("ZodObject",(e,t)=>{nl.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ip(e,t,n,r),b(e,"shape",()=>t.shape),e.keyof=()=>uA(Object.keys(e._zod.def.shape)),e.catchall=t=>e.clone({...e._zod.def,catchall:t}),e.passthrough=()=>e.clone({...e._zod.def,catchall:ue()}),e.loose=()=>e.clone({...e._zod.def,catchall:ue()}),e.strict=()=>e.clone({...e._zod.def,catchall:un()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=t=>(function(e,t){if(!O(t))throw Error("Invalid input to extend: expected a plain object");let n=e._zod.def.checks;if(n&&n.length>0)throw Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");let r=k(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t};return w(this,"shape",n),n},checks:[]});return A(e,r)})(e,t),e.safeExtend=t=>(function(e,t){if(!O(t))throw Error("Invalid input to safeExtend: expected a plain object");let n={...e._zod.def,get shape(){let n={...e._zod.def.shape,...t};return w(this,"shape",n),n},checks:e._zod.def.checks};return A(e,n)})(e,t),e.merge=t=>(function(e,t){let n=k(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t._zod.def.shape};return w(this,"shape",n),n},get catchall(){return t._zod.def.catchall},checks:[]});return A(e,n)})(e,t),e.pick=t=>(function(e,t){let n=e._zod.def,r=k(e._zod.def,{get shape(){let e={};for(let r in t){if(!(r in n.shape))throw Error(`Unrecognized key: "${r}"`);t[r]&&(e[r]=n.shape[r])}return w(this,"shape",e),e},checks:[]});return A(e,r)})(e,t),e.omit=t=>(function(e,t){let n=e._zod.def,r=k(e._zod.def,{get shape(){let r={...e._zod.def.shape};for(let e in t){if(!(e in n.shape))throw Error(`Unrecognized key: "${e}"`);t[e]&&delete r[e]}return w(this,"shape",r),r},checks:[]});return A(e,r)})(e,t),e.partial=(...t)=>(function(e,t,n){let r=k(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let t in n){if(!(t in r))throw Error(`Unrecognized key: "${t}"`);n[t]&&(i[t]=e?new e({type:"optional",innerType:r[t]}):r[t])}else for(let t in r)i[t]=e?new e({type:"optional",innerType:r[t]}):r[t];return w(this,"shape",i),i},checks:[]});return A(t,r)})(uU,e,t[0]),e.required=(...t)=>(function(e,t,n){let r=k(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(n)for(let t in n){if(!(t in i))throw Error(`Unrecognized key: "${t}"`);n[t]&&(i[t]=new e({type:"nonoptional",innerType:r[t]}))}else for(let t in r)i[t]=new e({type:"nonoptional",innerType:r[t]});return w(this,"shape",i),i},checks:[]});return A(t,r)})(uX,e,t[0])});function ud(e,t){return new ul({type:"object",shape:e??{},...P(t)})}function uf(e,t){return new ul({type:"object",shape:e,catchall:un(),...P(t)})}function up(e,t){return new ul({type:"object",shape:e,catchall:ue(),...P(t)})}let um=c("ZodUnion",(e,t)=>{nf.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>im(e,t,n,r),e.options=t.options});function uh(e,t){return new um({type:"union",options:e,...P(t)})}let u_=c("ZodXor",(e,t)=>{um.init(e,t),nm.init(e,t),e._zod.processJSONSchema=(t,n,r)=>im(e,t,n,r),e.options=t.options});function uv(e,t){return new u_({type:"union",options:e,inclusive:!1,...P(t)})}let uy=c("ZodDiscriminatedUnion",(e,t)=>{um.init(e,t),nh.init(e,t)});function ug(e,t,n){return new uy({type:"union",options:t,discriminator:e,...P(n)})}let uz=c("ZodIntersection",(e,t)=>{n_.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ih(e,t,n,r)});function ub(e,t){return new uz({type:"intersection",left:e,right:t})}let uw=c("ZodTuple",(e,t)=>{ny.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>i_(e,t,n,r),e.rest=t=>e.clone({...e._zod.def,rest:t})});function uk(e,t,n){let r=t instanceof tS,i=r?n:t;return new uw({type:"tuple",items:e,rest:r?t:null,...P(i)})}let uZ=c("ZodRecord",(e,t)=>{nz.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iv(e,t,n,r),e.keyType=t.keyType,e.valueType=t.valueType});function u$(e,t,n){return new uZ({type:"record",keyType:e,valueType:t,...P(n)})}
20function uS(e,t,n){let r=A(e);return r._zod.values=void 0,new uZ({type:"record",keyType:r,valueType:t,...P(n)})}function ux(e,t,n){return new uZ({type:"record",keyType:e,valueType:t,mode:"loose",...P(n)})}let uO=c("ZodMap",(e,t)=>{nb.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ic(e,t,n,r),e.keyType=t.keyType,e.valueType=t.valueType});function uI(e,t,n){return new uO({type:"map",keyType:e,valueType:t,...P(n)})}let uN=c("ZodSet",(e,t)=>{nk.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>il(e,t,n,r),e.min=(...t)=>e.check(rZ(...t)),e.nonempty=t=>e.check(rZ(1,t)),e.max=(...t)=>e.check(rk(...t)),e.size=(...t)=>e.check(r$(...t))});function uT(e,t){return new uN({type:"set",valueType:e,...P(t)})}let uE=c("ZodEnum",(e,t)=>{n$.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>r8(e,t,n,r),e.enum=t.entries,e.options=Object.values(t.entries);let n=new Set(Object.keys(t.entries));e.extract=(e,r)=>{let i={};for(let r of e)if(n.has(r))i[r]=t.entries[r];else throw Error(`Key ${r} not found in enum`);return new uE({...t,checks:[],...P(r),entries:i})},e.exclude=(e,r)=>{let i={...t.entries};for(let t of e)if(n.has(t))delete i[t];else throw Error(`Key ${t} not found in enum`);return new uE({...t,checks:[],...P(r),entries:i})}});function uA(e,t){return new uE({type:"enum",entries:Array.isArray(e)?Object.fromEntries(e.map(e=>[e,e])):e,...P(t)})}function uP(e,t){return new uE({type:"enum",entries:e,...P(t)})}let uj=c("ZodLiteral",(e,t)=>{nS.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ie(e,t,n,r),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if
20(t.values.length>1)throw Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function uF(e,t){return new uj({type:"literal",values:Array.isArray(e)?e:[e],...P(t)})}let uD=c("ZodFile",(e,t)=>{nx.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ii(e,t,n,r),e.min=(t,n)=>e.check(rZ(t,n)),e.max=(t,n)=>e.check(rk(t,n)),e.mime=(t,n)=>e.check(rF(Array.isArray(t)?t:[t],n))});function uR(e){return new uD({type:"file",...P(e)})}let uC=c("ZodTransform",(e,t)=>{nO.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>is(e,t,n,r),e._zod.parse=(n,r)=>{if("backward"===r.direction)throw new d(e.constructor.name);n.addIssue=r=>{"string"==typeof r?n.issues.push(V(r,n.value,t)):(r.fatal&&(r.continue=!1),r.code??(r.code="custom"),r.input??(r.input=n.value),r.inst??(r.inst=e),n.issues.push(V(r)))};let i=t.transform(n.value,n);return i instanceof Promise?i.then(e=>(n.value=e,n)):(n.value=i,n)}});function uJ(e){return new uC({type:"transform",transform:e})}let uU=c("ZodOptional",(e,t)=>{nN.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iS(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function uM(e){return new uU({type:"optional",innerType:e})}let uL=c("ZodNullable",(e,t)=>{nT.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iy(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function uV(e){return new uL({type:"nullable",innerType:e})}function uB(e){return uM(uV(e))}let uW=c("ZodDefault",(e,t)=>{nE.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iz(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function uq(e,t){return new uW({type:"default",innerType:e,get defaultValue(){return"function"==typeof t?t():I(t)}})}let uK=c("ZodPrefault",(e,t)=>{nP.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ib(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function uG(e,t){return new uK({type:"prefault",innerType:e,get defaultValue(){return"function"==typeof t?t():I(t)}})}let uX=c("ZodNonOptional",(e,t)=>{nj.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ig(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function uY(e,t){return new uX({type:"nonoptional",innerType:e,...P(t)})}let uH=c("ZodSuccess",(e,t)=>{nD.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>io(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function uQ(e){return new uH({type:"success",innerType:e})}let u0=c("ZodCatch",(e,t)=>{nR.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iw(e,t,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function u1(e,t){return new u0({type:"catch",innerType:e,catchValue:"function"==typeof t?t:()=>t})}let u4=c("ZodNaN",(e,t)=>{nC.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>it(e,t,n,r)});function u2(e){return new u4({type:"nan",...P(e)})}let u9=c("ZodPipe",(e,t)=>{nJ.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ik(e,t,n,r),e.in=t.in,e.out=t.out});function u6(e,t){return new u9({type:"pipe",in:e,out:t})}let u3=c("ZodCodec",(e,t)=>{u9.init(e,t),nM.init(e,t)});function u5(e,t,n){return new u3({type:"pipe",in:e,out:t,transform:n.decode,reverseTransform:n.encode})}let u7=c("ZodReadonly",(e,t)=>{nB.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iZ(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function u8(e){return new u7({type:"readonly",innerType:e})}let ae=c("ZodTemplateLiteral",(e,t)=>{nq.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ir(e,t,n,r)});function at(e,t){return new ae({type:"template_literal",parts:e,...P(t)})}let an=c("ZodLazy",(e,t)=>{nX.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ix(e,t,n,r),e.unwrap=()=>e._zod.def.getter()});function ar(e){return new an({type:"lazy",getter:e})}let ai=c("ZodPromise",(e,t)=>{nG.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>i$(e,t,n,r),e.unwrap=()=>e._zod.def.innerType});function ao(e){return new ai({type:"promise",innerType:e})}let au=c("ZodFunction",(e,t)=>{nK.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>ia(e,t,n,r)});function aa(e){return new au({type:"function",input:Array.isArray(e?.input)?uk(e?.input):e?.input??us(ue()),output:e?.output??ue()})}let as=c("ZodCustom",(e,t)=>{nY.init(e,t),iX.init(e,t),e._zod.processJSONSchema=(t,n,r)=>iu(e,t,n,r)});function ac(e){let t=new te({check:"custom"});return t._zod.check=e,t}function al(e,t){return function(e,t,n){let r=P(n);return r.abort??(r.abort=!0),new e({type:"custom",check:"custom",fn:t,...r})}(as,e??(()=>!0),t)}function ad(e,t={}){return new as({type:"custom",check:"custom",fn:e,...P(t)})}function af(e){return function(e){let t=function(e,t){let n=new te({check:"custom",...P(void 0)});return n._zod.check=e,n}(n=>(n.addIssue=e=>{"string"==typeof e?n.issues.push(V(e,n.value,t._zod.def)):(e.fatal&&(e.continue=!1),e.code??(e.code="custom"),e.input??(e.input=n.value),e.inst??(e.inst=t),e.continue??(e.continue=!t._zod.def.abort),n.issues.push(V(e)))}
20,e(n.value,n)));return t}(e)}let ap=function(e){let t=new te({check:"describe"});return t._zod.onattach=[t=>{let n=n1.get(t)??{};n1.add(t,{...n,description:e})}],t._zod.check=()=>{},t},am=function(e){let t=new te({check:"meta"});return t._zod.onattach=[t=>{let n=n1.get(t)??{};n1.add(t,{...n,...e})}],t._zod.check=()=>{},t};function ah(e,t={error:`Input not instance of ${e.name}`}){let n=new as({type:"custom",check:"custom",fn:t=>t instanceof e,abort:!0,...P(t)});return n._zod.bag.Class=e,n}let a_=(...e)=>(function(e,t){let n=P(t),r=n.truthy??["true","1","yes","on","y","enabled"],i=n.falsy??["false","0","no","off","n","disabled"];"sensitive"!==n.case&&(r=r.map(e=>"string"==typeof e?e.toLowerCase():e),i=i.map(e=>"string"==typeof e?e.toLowerCase():e));let o=new Set(r),u=new Set(i),a=e.Codec??nM,s=e.Boolean??t2,c=new a({type:"pipe",in:new(e.String??tx)({type:"string",error:n.error}),out:new s({type:"boolean",error:n.error}),transform:(e,t)=>{let r=e;return"sensitive"!==n.case&&(r=r.toLowerCase()),!!o.has(r)||!u.has(r)&&(t.issues.push({code:"invalid_value",expected:"stringbool",values:[...o,...u],input:t.value,inst:c,continue:!1}),{})},reverseTransform:(e,t)=>!0===e?r[0]||"true":i[0]||"false",error:n.error});return c})({Codec:u3,Boolean:oK,String:iH},...e);function av(e){let t=ar(()=>uh([iQ(e),oU(),oG(),o3(),us(t),u$(iQ(),t)]));return t}function ay(e,t){return u6(uJ(e),t)}i||(i={}),p({localeError:(()=>{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"}},t={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",mac:"MAC address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"};return n=>{switch(n.code){case"invalid_type":return`Invalid input: expected ${n.expected}, received ${nQ(n.input)}`;case"invalid_value":if(1===n.values.length)return`Invalid input: expected ${j(n.values[0])}`;return`Invalid option: expected one of ${h(n.values,"|")}`;case"too_big":{let t=n.inclusive?"<=":"<",r=e[n.origin]??null;if(r)return`Too big: expected ${n.origin??"value"} to have ${t}${n.maximum.toString()} ${r.unit??"elements"}`;return`Too big: expected ${n.origin??"value"} to be ${t}${n.maximum.toString()}`}case"too_small":{let t=n.inclusive?">=":">",r=e[n.origin]??null;if(r)return`Too small: expected ${n.origin} to have ${t}${n.minimum.toString()} ${r.unit}`;return`Too small: expected ${n.origin} to be ${t}${n.minimum.toString()}`}case"invalid_format":if("starts_with"===n.format)return`Invalid string: must start with "${n.prefix}"`;if("ends_with"===n.format)return`Invalid string: must end with "${n.suffix}"`;if("includes"===n.format)return`Invalid string: must include "${n.includes}"`;if("regex"===n.format)return`Invalid string: must match pattern ${n.pattern}`;return`Invalid ${t[n.format]??n.format}`;case"not_multiple_of":return`Invalid number: must be a multiple of ${n.divisor}`;case"unrecognized_keys":return`Unrecognized key${n.keys.length>1?"s":""}: ${h(n.keys,", ")}`;case"invalid_key":return`Invalid key in ${n.origin}`;case"invalid_union":default:return"Invalid input";case"invalid_element":return`Invalid value in ${n.origin}`}}})()})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.