@activepieces/piece-stripe 0.6.13 → 0.6.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/index.js +51 -13
package/src/index.js
CHANGED
|
@@ -1,19 +1,57 @@
|
|
|
1
|
-
"use strict";var S_=Object.create;var Rr=Object.defineProperty;var T_=Object.getOwnPropertyDescriptor;var E_=Object.getOwnPropertyNames;var I_=Object.getPrototypeOf,A_=Object.prototype.hasOwnProperty;var a=(e,t)=>Rr(e,"name",{value:t,configurable:!0});var C=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(r){throw t=0,r}},Mn=(e,t)=>{for(var r in t)Rr(e,r,{get:t[r],enumerable:!0})},Ls=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of E_(t))!A_.call(e,o)&&o!==r&&Rr(e,o,{get:()=>t[o],enumerable:!(n=T_(t,o))||n.enumerable});return e};var Le=(e,t,r)=>(r=e!=null?S_(I_(e)):{},Ls(t||!e||!e.__esModule?Rr(r,"default",{value:e,enumerable:!0}):r,e)),w_=e=>Ls(Rr({},"__esModule",{value:!0}),e);var lc=C((cc,oo)=>{(function(e){"use strict";let t="(0?\\d+|0x[a-f0-9]+)",r={fourOctet:new RegExp(`^${t}\\.${t}\\.${t}\\.${t}$`,"i"),threeOctet:new RegExp(`^${t}\\.${t}\\.${t}$`,"i"),twoOctet:new RegExp(`^${t}\\.${t}$`,"i"),longValue:new RegExp(`^${t}$`,"i")},n=new RegExp("^0[0-7]+$","i"),o=new RegExp("^0x[a-f0-9]+$","i"),i="%[0-9a-z]{1,}",s="(?:[0-9a-f]+::?)+",l={zoneIndex:new RegExp(i,"i"),native:new RegExp(`^(::)?(${s})?([0-9a-f]+)?(::)?(${i})?$`,"i"),deprecatedTransitional:new RegExp(`^(?:::)(${t}\\.${t}\\.${t}\\.${t}(${i})?)$`,"i"),transitional:new RegExp(`^((?:${s})|(?:::)(?:${s})?)${t}\\.${t}\\.${t}\\.${t}(${i})?$`,"i")};function f(d,y){if(d.indexOf("::")!==d.lastIndexOf("::"))return null;let I=0,S=-1,T=(d.match(l.zoneIndex)||[])[0],A,k;for(T&&(T=T.substring(1),d=d.replace(/%.+$/,""));(S=d.indexOf(":",S+1))>=0;)I++;if(d.substr(0,2)==="::"&&I--,d.substr(-2,2)==="::"&&I--,I>y)return null;for(k=y-I,A=":";k--;)A+="0:";return d=d.replace("::",A),d[0]===":"&&(d=d.slice(1)),d[d.length-1]===":"&&(d=d.slice(0,-1)),y=(function(){let G=d.split(":"),Y=[];for(let Te=0;Te<G.length;Te++)Y.push(parseInt(G[Te],16));return Y})(),{parts:y,zoneId:T}}a(f,"expandIPv6");function b(d,y,I,S){if(d.length!==y.length)throw new Error("ipaddr: cannot match CIDR for objects with different lengths");let T=0,A;for(;S>0;){if(A=I-S,A<0&&(A=0),d[T]>>A!==y[T]>>A)return!1;S-=I,T+=1}return!0}a(b,"matchCIDR");function m(d){if(o.test(d))return parseInt(d,16);if(d[0]==="0"&&!isNaN(parseInt(d[1],10))){if(n.test(d))return parseInt(d,8);throw new Error(`ipaddr: cannot parse ${d} as octal`)}return parseInt(d,10)}a(m,"parseIntAuto");function P(d,y){for(;d.length<y;)d=`0${d}`;return d}a(P,"padPart");let h={};h.IPv4=(function(){function d(y){if(y.length!==4)throw new Error("ipaddr: ipv4 octet count should be 4");let I,S;for(I=0;I<y.length;I++)if(S=y[I],!(0<=S&&S<=255))throw new Error("ipaddr: ipv4 octet should fit in 8 bits");this.octets=y}return a(d,"IPv4"),d.prototype.SpecialRanges={unspecified:[[new d([0,0,0,0]),8]],broadcast:[[new d([255,255,255,255]),32]],multicast:[[new d([224,0,0,0]),4]],linkLocal:[[new d([169,254,0,0]),16]],loopback:[[new d([127,0,0,0]),8]],carrierGradeNat:[[new d([100,64,0,0]),10]],private:[[new d([10,0,0,0]),8],[new d([172,16,0,0]),12],[new d([192,168,0,0]),16]],reserved:[[new d([192,0,0,0]),24],[new d([192,0,2,0]),24],[new d([192,88,99,0]),24],[new d([198,18,0,0]),15],[new d([198,51,100,0]),24],[new d([203,0,113,0]),24],[new d([240,0,0,0]),4]],as112:[[new d([192,175,48,0]),24],[new d([192,31,196,0]),24]],amt:[[new d([192,52,193,0]),24]]},d.prototype.kind=function(){return"ipv4"},d.prototype.match=function(y,I){let S;if(I===void 0&&(S=y,y=S[0],I=S[1]),y.kind()!=="ipv4")throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one");return b(this.octets,y.octets,8,I)},d.prototype.prefixLengthFromSubnetMask=function(){let y=0,I=!1,S={0:8,128:7,192:6,224:5,240:4,248:3,252:2,254:1,255:0},T,A,k;for(T=3;T>=0;T-=1)if(A=this.octets[T],A in S){if(k=S[A],I&&k!==0)return null;k!==8&&(I=!0),y+=k}else return null;return 32-y},d.prototype.range=function(){return h.subnetMatch(this,this.SpecialRanges)},d.prototype.toByteArray=function(){return this.octets.slice(0)},d.prototype.toIPv4MappedAddress=function(){return h.IPv6.parse(`::ffff:${this.toString()}`)},d.prototype.toNormalizedString=function(){return this.toString()},d.prototype.toString=function(){return this.octets.join(".")},d})(),h.IPv4.broadcastAddressFromCIDR=function(d){try{let y=this.parseCIDR(d),I=y[0].toByteArray(),S=this.subnetMaskFromPrefixLength(y[1]).toByteArray(),T=[],A=0;for(;A<4;)T.push(parseInt(I[A],10)|parseInt(S[A],10)^255),A++;return new this(T)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},h.IPv4.isIPv4=function(d){return this.parser(d)!==null},h.IPv4.isValid=function(d){try{return new this(this.parser(d)),!0}catch{return!1}},h.IPv4.isValidCIDR=function(d){try{return this.parseCIDR(d),!0}catch{return!1}},h.IPv4.isValidFourPartDecimal=function(d){return!!(h.IPv4.isValid(d)&&d.match(/^(0|[1-9]\d*)(\.(0|[1-9]\d*)){3}$/))},h.IPv4.isValidCIDRFourPartDecimal=function(d){let y=d.match(/^(.+)\/(\d+)$/);return!h.IPv4.isValidCIDR(d)||!y?!1:h.IPv4.isValidFourPartDecimal(y[1])},h.IPv4.networkAddressFromCIDR=function(d){let y,I,S,T,A;try{for(y=this.parseCIDR(d),S=y[0].toByteArray(),A=this.subnetMaskFromPrefixLength(y[1]).toByteArray(),T=[],I=0;I<4;)T.push(parseInt(S[I],10)&parseInt(A[I],10)),I++;return new this(T)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},h.IPv4.parse=function(d){let y=this.parser(d);if(y===null)throw new Error("ipaddr: string is not formatted like an IPv4 Address");return new this(y)},h.IPv4.parseCIDR=function(d){let y;if(y=d.match(/^(.+)\/(\d+)$/)){let I=parseInt(y[2]);if(I>=0&&I<=32){let S=[this.parse(y[1]),I];return Object.defineProperty(S,"toString",{value:a(function(){return this.join("/")},"value")}),S}}throw new Error("ipaddr: string is not formatted like an IPv4 CIDR range")},h.IPv4.parser=function(d){let y,I,S;if(y=d.match(r.fourOctet))return(function(){let T=y.slice(1,6),A=[];for(let k=0;k<T.length;k++)I=T[k],A.push(m(I));return A})();if(y=d.match(r.longValue)){if(S=m(y[1]),S>4294967295||S<0)throw new Error("ipaddr: address outside defined range");return(function(){let T=[],A;for(A=0;A<=24;A+=8)T.push(S>>A&255);return T})().reverse()}else return(y=d.match(r.twoOctet))?(function(){let T=y.slice(1,4),A=[];if(S=m(T[1]),S>16777215||S<0)throw new Error("ipaddr: address outside defined range");return A.push(m(T[0])),A.push(S>>16&255),A.push(S>>8&255),A.push(S&255),A})():(y=d.match(r.threeOctet))?(function(){let T=y.slice(1,5),A=[];if(S=m(T[2]),S>65535||S<0)throw new Error("ipaddr: address outside defined range");return A.push(m(T[0])),A.push(m(T[1])),A.push(S>>8&255),A.push(S&255),A})():null},h.IPv4.subnetMaskFromPrefixLength=function(d){if(d=parseInt(d),d<0||d>32)throw new Error("ipaddr: invalid IPv4 prefix length");let y=[0,0,0,0],I=0,S=Math.floor(d/8);for(;I<S;)y[I]=255,I++;return S<4&&(y[S]=Math.pow(2,d%8)-1<<8-d%8),new this(y)},h.IPv6=(function(){function d(y,I){let S,T;if(y.length===16)for(this.parts=[],S=0;S<=14;S+=2)this.parts.push(y[S]<<8|y[S+1]);else if(y.length===8)this.parts=y;else throw new Error("ipaddr: ipv6 part count should be 8 or 16");for(S=0;S<this.parts.length;S++)if(T=this.parts[S],!(0<=T&&T<=65535))throw new Error("ipaddr: ipv6 part should fit in 16 bits");I&&(this.zoneId=I)}return a(d,"IPv6"),d.prototype.SpecialRanges={unspecified:[new d([0,0,0,0,0,0,0,0]),128],linkLocal:[new d([65152,0,0,0,0,0,0,0]),10],multicast:[new d([65280,0,0,0,0,0,0,0]),8],loopback:[new d([0,0,0,0,0,0,0,1]),128],uniqueLocal:[new d([64512,0,0,0,0,0,0,0]),7],ipv4Mapped:[new d([0,0,0,0,0,65535,0,0]),96],discard:[new d([256,0,0,0,0,0,0,0]),64],rfc6145:[new d([0,0,0,0,65535,0,0,0]),96],rfc6052:[new d([100,65435,0,0,0,0,0,0]),96],"6to4":[new d([8194,0,0,0,0,0,0,0]),16],teredo:[new d([8193,0,0,0,0,0,0,0]),32],benchmarking:[new d([8193,2,0,0,0,0,0,0]),48],amt:[new d([8193,3,0,0,0,0,0,0]),32],as112v6:[[new d([8193,4,274,0,0,0,0,0]),48],[new d([9760,79,32768,0,0,0,0,0]),48]],deprecated:[new d([8193,16,0,0,0,0,0,0]),28],orchid2:[new d([8193,32,0,0,0,0,0,0]),28],droneRemoteIdProtocolEntityTags:[new d([8193,48,0,0,0,0,0,0]),28],reserved:[[new d([8193,0,0,0,0,0,0,0]),23],[new d([8193,3512,0,0,0,0,0,0]),32]]},d.prototype.isIPv4MappedAddress=function(){return this.range()==="ipv4Mapped"},d.prototype.kind=function(){return"ipv6"},d.prototype.match=function(y,I){let S;if(I===void 0&&(S=y,y=S[0],I=S[1]),y.kind()!=="ipv6")throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one");return b(this.parts,y.parts,16,I)},d.prototype.prefixLengthFromSubnetMask=function(){let y=0,I=!1,S={0:16,32768:15,49152:14,57344:13,61440:12,63488:11,64512:10,65024:9,65280:8,65408:7,65472:6,65504:5,65520:4,65528:3,65532:2,65534:1,65535:0},T,A;for(let k=7;k>=0;k-=1)if(T=this.parts[k],T in S){if(A=S[T],I&&A!==0)return null;A!==16&&(I=!0),y+=A}else return null;return 128-y},d.prototype.range=function(){return h.subnetMatch(this,this.SpecialRanges)},d.prototype.toByteArray=function(){let y,I=[],S=this.parts;for(let T=0;T<S.length;T++)y=S[T],I.push(y>>8),I.push(y&255);return I},d.prototype.toFixedLengthString=function(){let y=(function(){let S=[];for(let T=0;T<this.parts.length;T++)S.push(P(this.parts[T].toString(16),4));return S}).call(this).join(":"),I="";return this.zoneId&&(I=`%${this.zoneId}`),y+I},d.prototype.toIPv4Address=function(){if(!this.isIPv4MappedAddress())throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4");let y=this.parts.slice(-2),I=y[0],S=y[1];return new h.IPv4([I>>8,I&255,S>>8,S&255])},d.prototype.toNormalizedString=function(){let y=(function(){let S=[];for(let T=0;T<this.parts.length;T++)S.push(this.parts[T].toString(16));return S}).call(this).join(":"),I="";return this.zoneId&&(I=`%${this.zoneId}`),y+I},d.prototype.toRFC5952String=function(){let y=/((^|:)(0(:|$)){2,})/g,I=this.toNormalizedString(),S=0,T=-1,A;for(;A=y.exec(I);)A[0].length>T&&(S=A.index,T=A[0].length);return T<0?I:`${I.substring(0,S)}::${I.substring(S+T)}`},d.prototype.toString=function(){return this.toRFC5952String()},d})(),h.IPv6.broadcastAddressFromCIDR=function(d){try{let y=this.parseCIDR(d),I=y[0].toByteArray(),S=this.subnetMaskFromPrefixLength(y[1]).toByteArray(),T=[],A=0;for(;A<16;)T.push(parseInt(I[A],10)|parseInt(S[A],10)^255),A++;return new this(T)}catch(y){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${y})`)}},h.IPv6.isIPv6=function(d){return this.parser(d)!==null},h.IPv6.isValid=function(d){if(typeof d=="string"&&d.indexOf(":")===-1)return!1;try{let y=this.parser(d);return new this(y.parts,y.zoneId),!0}catch{return!1}},h.IPv6.isValidCIDR=function(d){if(typeof d=="string"&&d.indexOf(":")===-1)return!1;try{return this.parseCIDR(d),!0}catch{return!1}},h.IPv6.networkAddressFromCIDR=function(d){let y,I,S,T,A;try{for(y=this.parseCIDR(d),S=y[0].toByteArray(),A=this.subnetMaskFromPrefixLength(y[1]).toByteArray(),T=[],I=0;I<16;)T.push(parseInt(S[I],10)&parseInt(A[I],10)),I++;return new this(T)}catch(k){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${k})`)}},h.IPv6.parse=function(d){let y=this.parser(d);if(y.parts===null)throw new Error("ipaddr: string is not formatted like an IPv6 Address");return new this(y.parts,y.zoneId)},h.IPv6.parseCIDR=function(d){let y,I,S;if((I=d.match(/^(.+)\/(\d+)$/))&&(y=parseInt(I[2]),y>=0&&y<=128))return S=[this.parse(I[1]),y],Object.defineProperty(S,"toString",{value:a(function(){return this.join("/")},"value")}),S;throw new Error("ipaddr: string is not formatted like an IPv6 CIDR range")},h.IPv6.parser=function(d){let y,I,S,T,A,k;if(S=d.match(l.deprecatedTransitional))return this.parser(`::ffff:${S[1]}`);if(l.native.test(d))return f(d,8);if((S=d.match(l.transitional))&&(k=S[6]||"",y=S[1],S[1].endsWith("::")||(y=y.slice(0,-1)),y=f(y+k,6),y.parts)){for(A=[parseInt(S[2]),parseInt(S[3]),parseInt(S[4]),parseInt(S[5])],I=0;I<A.length;I++)if(T=A[I],!(0<=T&&T<=255))return null;return y.parts.push(A[0]<<8|A[1]),y.parts.push(A[2]<<8|A[3]),{parts:y.parts,zoneId:y.zoneId}}return null},h.IPv6.subnetMaskFromPrefixLength=function(d){if(d=parseInt(d),d<0||d>128)throw new Error("ipaddr: invalid IPv6 prefix length");let y=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],I=0,S=Math.floor(d/8);for(;I<S;)y[I]=255,I++;return S<16&&(y[S]=Math.pow(2,d%8)-1<<8-d%8),new this(y)},h.fromByteArray=function(d){let y=d.length;if(y===4)return new h.IPv4(d);if(y===16)return new h.IPv6(d);throw new Error("ipaddr: the binary input is neither an IPv6 nor IPv4 address")},h.isValid=function(d){return h.IPv6.isValid(d)||h.IPv4.isValid(d)},h.isValidCIDR=function(d){return h.IPv6.isValidCIDR(d)||h.IPv4.isValidCIDR(d)},h.parse=function(d){if(h.IPv6.isValid(d))return h.IPv6.parse(d);if(h.IPv4.isValid(d))return h.IPv4.parse(d);throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format")},h.parseCIDR=function(d){try{return h.IPv6.parseCIDR(d)}catch{try{return h.IPv4.parseCIDR(d)}catch{throw new Error("ipaddr: the address has neither IPv6 nor IPv4 CIDR format")}}},h.process=function(d){let y=this.parse(d);return y.kind()==="ipv6"&&y.isIPv4MappedAddress()?y.toIPv4Address():y},h.subnetMatch=function(d,y,I){let S,T,A,k;I==null&&(I="unicast");for(T in y)if(Object.prototype.hasOwnProperty.call(y,T)){for(A=y[T],A[0]&&!(A[0]instanceof Array)&&(A=[A]),S=0;S<A.length;S++)if(k=A[S],d.kind()===k[0].kind()&&d.match.apply(d,k))return T}return I},typeof oo<"u"&&oo.exports?oo.exports=h:e.ipaddr=h})(cc)});var fl=C((Bq,ml)=>{var dl=require("stream").Stream,dx=require("util");ml.exports=je;function je(){this.source=null,this.dataSize=0,this.maxDataSize=1024*1024,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}a(je,"DelayedStream");dx.inherits(je,dl);je.create=function(e,t){var r=new this;t=t||{};for(var n in t)r[n]=t[n];r.source=e;var o=e.emit;return e.emit=function(){return r._handleEmit(arguments),o.apply(e,arguments)},e.on("error",function(){}),r.pauseStream&&e.pause(),r};Object.defineProperty(je.prototype,"readable",{configurable:!0,enumerable:!0,get:a(function(){return this.source.readable},"get")});je.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};je.prototype.resume=function(){this._released||this.release(),this.source.resume()};je.prototype.pause=function(){this.source.pause()};je.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};je.prototype.pipe=function(){var e=dl.prototype.pipe.apply(this,arguments);return this.resume(),e};je.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}e[0]==="data"&&(this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded()),this._bufferedEvents.push(e)};je.prototype._checkIfMaxDataSizeExceeded=function(){if(!this._maxDataSizeExceeded&&!(this.dataSize<=this.maxDataSize)){this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}}});var vl=C((Vq,gl)=>{var mx=require("util"),yl=require("stream").Stream,hl=fl();gl.exports=ue;function ue(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2*1024*1024,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}a(ue,"CombinedStream");mx.inherits(ue,yl);ue.create=function(e){var t=new this;e=e||{};for(var r in e)t[r]=e[r];return t};ue.isStreamLike=function(e){return typeof e!="function"&&typeof e!="string"&&typeof e!="boolean"&&typeof e!="number"&&!Buffer.isBuffer(e)};ue.prototype.append=function(e){var t=ue.isStreamLike(e);if(t){if(!(e instanceof hl)){var r=hl.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=r}this._handleErrors(e),this.pauseStreams&&e.pause()}return this._streams.push(e),this};ue.prototype.pipe=function(e,t){return yl.prototype.pipe.call(this,e,t),this.resume(),e};ue.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop){this._pendingNext=!0;return}this._insideLoop=!0;try{do this._pendingNext=!1,this._realGetNext();while(this._pendingNext)}finally{this._insideLoop=!1}};ue.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e>"u"){this.end();return}if(typeof e!="function"){this._pipeNext(e);return}var t=e;t(function(r){var n=ue.isStreamLike(r);n&&(r.on("data",this._checkDataSize.bind(this)),this._handleErrors(r)),this._pipeNext(r)}.bind(this))};ue.prototype._pipeNext=function(e){this._currentStream=e;var t=ue.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this)),e.pipe(this,{end:!1});return}var r=e;this.write(r),this._getNext()};ue.prototype._handleErrors=function(e){var t=this;e.on("error",function(r){t._emitError(r)})};ue.prototype.write=function(e){this.emit("data",e)};ue.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function"&&this._currentStream.pause(),this.emit("pause"))};ue.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function"&&this._currentStream.resume(),this.emit("resume")};ue.prototype.end=function(){this._reset(),this.emit("end")};ue.prototype.destroy=function(){this._reset(),this.emit("close")};ue.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};ue.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}};ue.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach(function(t){t.dataSize&&(e.dataSize+=t.dataSize)}),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)};ue.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var bl=C((Zq,_l)=>{"use strict";_l.exports={"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/xml":{source:"iana",compressible:!0,extensions:["xml"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dat"]},"application/msword":{source:"iana",extensions:["doc"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",extensions:["docx"]},"application/vnd.ms-excel":{source:"iana",extensions:["xls"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",extensions:["xlsx"]},"application/vnd.ms-powerpoint":{source:"iana",extensions:["ppt"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",extensions:["pptx"]},"application/csv":{compressible:!0,extensions:["csv"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/wasm":{source:"iana",compressible:!0,extensions:["wasm"]},"text/plain":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["txt","text","log"]},"text/html":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["html","htm"]},"text/css":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["css"]},"text/csv":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["csv"]},"text/markdown":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["md","markdown"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/yaml":{compressible:!0,extensions:["yaml","yml"]},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/webp":{source:"apache",compressible:!1,extensions:["webp"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tiff","tif"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/heic":{source:"iana",compressible:!1,extensions:["heic"]},"image/avif":{source:"iana",compressible:!1,extensions:["avif"]},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mp3","mpga"]},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/ogg":{source:"iana",compressible:!1,extensions:["ogg","oga"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","m4v"]},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg"]},"video/webm":{source:"iana",compressible:!1,extensions:["webm"]},"video/quicktime":{source:"iana",compressible:!1,extensions:["mov","qt"]},"video/x-msvideo":{source:"iana",compressible:!1,extensions:["avi"]},"font/woff":{source:"iana",compressible:!1,extensions:["woff"]},"font/woff2":{source:"iana",compressible:!1,extensions:["woff2"]},"font/ttf":{source:"iana",compressible:!0,extensions:["ttf"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"multipart/form-data":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/manifest+json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/ics":{compressible:!0,extensions:["ics"]},"text/calendar":{source:"iana",compressible:!0,extensions:["ics","ifb"]},"application/x-ndjson":{compressible:!0,extensions:["ndjson"]}}});var Sl=C(ke=>{"use strict";var co=bl(),fx=require("path").extname,Pl=/^\s*([^;\s]*)(?:;|\s|$)/,hx=/^text\//i;ke.charset=xl;ke.charsets={lookup:xl};ke.contentType=yx;ke.extension=gx;ke.extensions=Object.create(null);ke.lookup=vx;ke.types=Object.create(null);_x(ke.extensions,ke.types);function xl(e){if(!e||typeof e!="string")return!1;var t=Pl.exec(e),r=t&&co[t[1].toLowerCase()];return r&&r.charset?r.charset:t&&hx.test(t[1])?"UTF-8":!1}a(xl,"charset");function yx(e){if(!e||typeof e!="string")return!1;var t=e.indexOf("/")===-1?ke.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var r=ke.charset(t);r&&(t+="; charset="+r.toLowerCase())}return t}a(yx,"contentType");function gx(e){if(!e||typeof e!="string")return!1;var t=Pl.exec(e),r=t&&ke.extensions[t[1].toLowerCase()];return!r||!r.length?!1:r[0]}a(gx,"extension");function vx(e){if(!e||typeof e!="string")return!1;var t=fx("x."+e).toLowerCase().substr(1);return t&&ke.types[t]||!1}a(vx,"lookup");function _x(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys(co).forEach(a(function(o){var i=co[o],s=i.extensions;if(!(!s||!s.length)){e[o]=s;for(var l=0;l<s.length;l++){var f=s[l];if(t[f]){var b=r.indexOf(co[t[f]].source),m=r.indexOf(i.source);if(t[f]!=="application/octet-stream"&&(b>m||b===m&&t[f].substr(0,12)==="application/"))continue}t[f]=o}}},"forEachMimeType"))}a(_x,"populateMaps")});var El=C((Jq,Tl)=>{Tl.exports=bx;function bx(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;t?t(e):setTimeout(e,0)}a(bx,"defer")});var ma=C((Yq,Al)=>{var Il=El();Al.exports=Px;function Px(e){var t=!1;return Il(function(){t=!0}),a(function(n,o){t?e(n,o):Il(a(function(){e(n,o)},"nextTick_callback"))},"async_callback")}a(Px,"async")});var fa=C((ej,wl)=>{wl.exports=xx;function xx(e){Object.keys(e.jobs).forEach(Sx.bind(e)),e.jobs={}}a(xx,"abort");function Sx(e){typeof this.jobs[e]=="function"&&this.jobs[e]()}a(Sx,"clean")});var ha=C((rj,Rl)=>{var kl=ma(),Tx=fa();Rl.exports=Ex;function Ex(e,t,r,n){var o=r.keyedList?r.keyedList[r.index]:r.index;r.jobs[o]=Ix(t,o,e[o],function(i,s){o in r.jobs&&(delete r.jobs[o],i?Tx(r):r.results[o]=s,n(i,r.results))})}a(Ex,"iterate");function Ix(e,t,r,n){var o;return e.length==2?o=e(r,kl(n)):o=e(r,t,kl(n)),o}a(Ix,"runJob")});var ya=C((oj,Ol)=>{Ol.exports=Ax;function Ax(e,t){var r=!Array.isArray(e),n={index:0,keyedList:r||t?Object.keys(e):null,jobs:{},results:r?{}:[],size:r?Object.keys(e).length:e.length};return t&&n.keyedList.sort(r?t:function(o,i){return t(e[o],e[i])}),n}a(Ax,"state")});var ga=C((aj,Cl)=>{var wx=fa(),kx=ma();Cl.exports=Rx;function Rx(e){Object.keys(this.jobs).length&&(this.index=this.size,wx(this),kx(e)(null,this.results))}a(Rx,"terminator")});var Nl=C((uj,$l)=>{var Ox=ha(),Cx=ya(),$x=ga();$l.exports=Nx;function Nx(e,t,r){for(var n=Cx(e);n.index<(n.keyedList||e).length;)Ox(e,t,n,function(o,i){if(o){r(o,i);return}if(Object.keys(n.jobs).length===0){r(null,n.results);return}}),n.index++;return $x.bind(n,r)}a(Nx,"parallel")});var va=C((lj,lo)=>{var Dl=ha(),Dx=ya(),zx=ga();lo.exports=Mx;lo.exports.ascending=zl;lo.exports.descending=Ux;function Mx(e,t,r,n){var o=Dx(e,r);return Dl(e,t,o,a(function i(s,l){if(s){n(s,l);return}if(o.index++,o.index<(o.keyedList||e).length){Dl(e,t,o,i);return}n(null,o.results)},"iteratorHandler")),zx.bind(o,n)}a(Mx,"serialOrdered");function zl(e,t){return e<t?-1:e>t?1:0}a(zl,"ascending");function Ux(e,t){return-1*zl(e,t)}a(Ux,"descending")});var Ul=C((dj,Ml)=>{var Lx=va();Ml.exports=qx;function qx(e,t,r){return Lx(e,t,null,r)}a(qx,"serial")});var ql=C((fj,Ll)=>{Ll.exports={parallel:Nl(),serial:Ul(),serialOrdered:va()}});var _a=C((hj,jl)=>{"use strict";jl.exports=Object});var Bl=C((yj,Fl)=>{"use strict";Fl.exports=Error});var Vl=C((gj,Gl)=>{"use strict";Gl.exports=EvalError});var Zl=C((vj,Hl)=>{"use strict";Hl.exports=RangeError});var Kl=C((_j,Wl)=>{"use strict";Wl.exports=ReferenceError});var Xl=C((bj,Jl)=>{"use strict";Jl.exports=SyntaxError});var vt=C((Pj,Yl)=>{"use strict";Yl.exports=TypeError});var ep=C((xj,Ql)=>{"use strict";Ql.exports=URIError});var rp=C((Sj,tp)=>{"use strict";tp.exports=Math.abs});var op=C((Tj,np)=>{"use strict";np.exports=Math.floor});var ap=C((Ej,ip)=>{"use strict";ip.exports=Math.max});var up=C((Ij,sp)=>{"use strict";sp.exports=Math.min});var lp=C((Aj,cp)=>{"use strict";cp.exports=Math.pow});var dp=C((wj,pp)=>{"use strict";pp.exports=Math.round});var fp=C((kj,mp)=>{"use strict";mp.exports=Number.isNaN||a(function(t){return t!==t},"isNaN")});var yp=C((Oj,hp)=>{"use strict";var jx=fp();hp.exports=a(function(t){return jx(t)||t===0?t:t<0?-1:1},"sign")});var vp=C(($j,gp)=>{"use strict";gp.exports=Object.getOwnPropertyDescriptor});var ba=C((Nj,_p)=>{"use strict";var po=vp();if(po)try{po([],"length")}catch{po=null}_p.exports=po});var Pp=C((Dj,bp)=>{"use strict";var mo=Object.defineProperty||!1;if(mo)try{mo({},"a",{value:1})}catch{mo=!1}bp.exports=mo});var Pa=C((zj,xp)=>{"use strict";xp.exports=a(function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;t[r]=o;for(var i in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var s=Object.getOwnPropertySymbols(t);if(s.length!==1||s[0]!==r||!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var l=Object.getOwnPropertyDescriptor(t,r);if(l.value!==o||l.enumerable!==!0)return!1}return!0},"hasSymbols")});var Ep=C((Uj,Tp)=>{"use strict";var Sp=typeof Symbol<"u"&&Symbol,Fx=Pa();Tp.exports=a(function(){return typeof Sp!="function"||typeof Symbol!="function"||typeof Sp("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Fx()},"hasNativeSymbols")});var xa=C((qj,Ip)=>{"use strict";Ip.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var Sa=C((jj,Ap)=>{"use strict";var Bx=_a();Ap.exports=Bx.getPrototypeOf||null});var Rp=C((Fj,kp)=>{"use strict";var Gx="Function.prototype.bind called on incompatible ",Vx=Object.prototype.toString,Hx=Math.max,Zx="[object Function]",wp=a(function(t,r){for(var n=[],o=0;o<t.length;o+=1)n[o]=t[o];for(var i=0;i<r.length;i+=1)n[i+t.length]=r[i];return n},"concatty"),Wx=a(function(t,r){for(var n=[],o=r||0,i=0;o<t.length;o+=1,i+=1)n[i]=t[o];return n},"slicy"),Kx=a(function(e,t){for(var r="",n=0;n<e.length;n+=1)r+=e[n],n+1<e.length&&(r+=t);return r},"joiny");kp.exports=a(function(t){var r=this;if(typeof r!="function"||Vx.apply(r)!==Zx)throw new TypeError(Gx+r);for(var n=Wx(arguments,1),o,i=a(function(){if(this instanceof o){var m=r.apply(this,wp(n,arguments));return Object(m)===m?m:this}return r.apply(t,wp(n,arguments))},"binder"),s=Hx(0,r.length-n.length),l=[],f=0;f<s;f++)l[f]="$"+f;if(o=Function("binder","return function ("+Kx(l,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var b=a(function(){},"Empty");b.prototype=r.prototype,o.prototype=new b,b.prototype=null}return o},"bind")});var Qt=C((Gj,Op)=>{"use strict";var Jx=Rp();Op.exports=Function.prototype.bind||Jx});var fo=C((Vj,Cp)=>{"use strict";Cp.exports=Function.prototype.call});var Ta=C((Hj,$p)=>{"use strict";$p.exports=Function.prototype.apply});var Dp=C((Zj,Np)=>{"use strict";Np.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var Mp=C((Wj,zp)=>{"use strict";var Xx=Qt(),Yx=Ta(),Qx=fo(),eS=Dp();zp.exports=eS||Xx.call(Qx,Yx)});var Ea=C((Kj,Up)=>{"use strict";var tS=Qt(),rS=vt(),nS=fo(),oS=Mp();Up.exports=a(function(t){if(t.length<1||typeof t[0]!="function")throw new rS("a function is required");return oS(tS,nS,t)},"callBindBasic")});var Gp=C((Xj,Bp)=>{"use strict";var iS=Ea(),Lp=ba(),jp;try{jp=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var Ia=!!jp&&Lp&&Lp(Object.prototype,"__proto__"),Fp=Object,qp=Fp.getPrototypeOf;Bp.exports=Ia&&typeof Ia.get=="function"?iS([Ia.get]):typeof qp=="function"?a(function(t){return qp(t==null?t:Fp(t))},"getDunder"):!1});var Kp=C((Qj,Wp)=>{"use strict";var Vp=xa(),Hp=Sa(),Zp=Gp();Wp.exports=Vp?a(function(t){return Vp(t)},"getProto"):Hp?a(function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return Hp(t)},"getProto"):Zp?a(function(t){return Zp(t)},"getProto"):null});var Aa=C((tF,Jp)=>{"use strict";var aS=Function.prototype.call,sS=Object.prototype.hasOwnProperty,uS=Qt();Jp.exports=uS.call(aS,sS)});var en=C((rF,rd)=>{"use strict";var W,cS=_a(),lS=Bl(),pS=Vl(),dS=Zl(),mS=Kl(),nr=Xl(),rr=vt(),fS=ep(),hS=rp(),yS=op(),gS=ap(),vS=up(),_S=lp(),bS=dp(),PS=yp(),ed=Function,wa=a(function(e){try{return ed('"use strict"; return ('+e+").constructor;")()}catch{}},"getEvalledConstructor"),Xr=ba(),xS=Pp(),ka=a(function(){throw new rr},"throwTypeError"),SS=Xr?(function(){try{return arguments.callee,ka}catch{try{return Xr(arguments,"callee").get}catch{return ka}}})():ka,er=Ep()(),Pe=Kp(),TS=Sa(),ES=xa(),td=Ta(),Yr=fo(),tr={},IS=typeof Uint8Array>"u"||!Pe?W:Pe(Uint8Array),Dt={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?W:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?W:ArrayBuffer,"%ArrayIteratorPrototype%":er&&Pe?Pe([][Symbol.iterator]()):W,"%AsyncFromSyncIteratorPrototype%":W,"%AsyncFunction%":tr,"%AsyncGenerator%":tr,"%AsyncGeneratorFunction%":tr,"%AsyncIteratorPrototype%":tr,"%Atomics%":typeof Atomics>"u"?W:Atomics,"%BigInt%":typeof BigInt>"u"?W:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?W:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?W:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?W:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":lS,"%eval%":eval,"%EvalError%":pS,"%Float16Array%":typeof Float16Array>"u"?W:Float16Array,"%Float32Array%":typeof Float32Array>"u"?W:Float32Array,"%Float64Array%":typeof Float64Array>"u"?W:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?W:FinalizationRegistry,"%Function%":ed,"%GeneratorFunction%":tr,"%Int8Array%":typeof Int8Array>"u"?W:Int8Array,"%Int16Array%":typeof Int16Array>"u"?W:Int16Array,"%Int32Array%":typeof Int32Array>"u"?W:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":er&&Pe?Pe(Pe([][Symbol.iterator]())):W,"%JSON%":typeof JSON=="object"?JSON:W,"%Map%":typeof Map>"u"?W:Map,"%MapIteratorPrototype%":typeof Map>"u"||!er||!Pe?W:Pe(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":cS,"%Object.getOwnPropertyDescriptor%":Xr,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?W:Promise,"%Proxy%":typeof Proxy>"u"?W:Proxy,"%RangeError%":dS,"%ReferenceError%":mS,"%Reflect%":typeof Reflect>"u"?W:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?W:Set,"%SetIteratorPrototype%":typeof Set>"u"||!er||!Pe?W:Pe(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?W:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":er&&Pe?Pe(""[Symbol.iterator]()):W,"%Symbol%":er?Symbol:W,"%SyntaxError%":nr,"%ThrowTypeError%":SS,"%TypedArray%":IS,"%TypeError%":rr,"%Uint8Array%":typeof Uint8Array>"u"?W:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?W:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?W:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?W:Uint32Array,"%URIError%":fS,"%WeakMap%":typeof WeakMap>"u"?W:WeakMap,"%WeakRef%":typeof WeakRef>"u"?W:WeakRef,"%WeakSet%":typeof WeakSet>"u"?W:WeakSet,"%Function.prototype.call%":Yr,"%Function.prototype.apply%":td,"%Object.defineProperty%":xS,"%Object.getPrototypeOf%":TS,"%Math.abs%":hS,"%Math.floor%":yS,"%Math.max%":gS,"%Math.min%":vS,"%Math.pow%":_S,"%Math.round%":bS,"%Math.sign%":PS,"%Reflect.getPrototypeOf%":ES};if(Pe)try{null.error}catch(e){Xp=Pe(Pe(e)),Dt["%Error.prototype%"]=Xp}var Xp,AS=a(function e(t){var r;if(t==="%AsyncFunction%")r=wa("async function () {}");else if(t==="%GeneratorFunction%")r=wa("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=wa("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var o=e("%AsyncGenerator%");o&&Pe&&(r=Pe(o.prototype))}return Dt[t]=r,r},"doEval"),Yp={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Qr=Qt(),ho=Aa(),wS=Qr.call(Yr,Array.prototype.concat),kS=Qr.call(td,Array.prototype.splice),Qp=Qr.call(Yr,String.prototype.replace),yo=Qr.call(Yr,String.prototype.slice),RS=Qr.call(Yr,RegExp.prototype.exec),OS=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,CS=/\\(\\)?/g,$S=a(function(t){var r=yo(t,0,1),n=yo(t,-1);if(r==="%"&&n!=="%")throw new nr("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new nr("invalid intrinsic syntax, expected opening `%`");var o=[];return Qp(t,OS,function(i,s,l,f){o[o.length]=l?Qp(f,CS,"$1"):s||i}),o},"stringToPath"),NS=a(function(t,r){var n=t,o;if(ho(Yp,n)&&(o=Yp[n],n="%"+o[0]+"%"),ho(Dt,n)){var i=Dt[n];if(i===tr&&(i=AS(n)),typeof i>"u"&&!r)throw new rr("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new nr("intrinsic "+t+" does not exist!")},"getBaseIntrinsic");rd.exports=a(function(t,r){if(typeof t!="string"||t.length===0)throw new rr("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new rr('"allowMissing" argument must be a boolean');if(RS(/^%?[^%]*%?$/,t)===null)throw new nr("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=$S(t),o=n.length>0?n[0]:"",i=NS("%"+o+"%",r),s=i.name,l=i.value,f=!1,b=i.alias;b&&(o=b[0],kS(n,wS([0,1],b)));for(var m=1,P=!0;m<n.length;m+=1){var h=n[m],d=yo(h,0,1),y=yo(h,-1);if((d==='"'||d==="'"||d==="`"||y==='"'||y==="'"||y==="`")&&d!==y)throw new nr("property names with quotes must have matching quotes");if((h==="constructor"||!P)&&(f=!0),o+="."+h,s="%"+o+"%",ho(Dt,s))l=Dt[s];else if(l!=null){if(!(h in l)){if(!r)throw new rr("base intrinsic for "+t+" exists, but the property is not available.");return}if(Xr&&m+1>=n.length){var I=Xr(l,h);P=!!I,P&&"get"in I&&!("originalValue"in I.get)?l=I.get:l=l[h]}else P=ho(l,h),l=l[h];P&&!f&&(Dt[s]=l)}}return l},"GetIntrinsic")});var od=C((oF,nd)=>{"use strict";var DS=Pa();nd.exports=a(function(){return DS()&&!!Symbol.toStringTag},"hasToStringTagShams")});var sd=C((aF,ad)=>{"use strict";var zS=en(),id=zS("%Object.defineProperty%",!0),MS=od()(),US=Aa(),LS=vt(),go=MS?Symbol.toStringTag:null;ad.exports=a(function(t,r){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,o=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!="boolean"||typeof o<"u"&&typeof o!="boolean")throw new LS("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");go&&(n||!US(t,go))&&(id?id(t,go,{configurable:!o,enumerable:!1,value:r,writable:!1}):t[go]=r)},"setToStringTag")});var cd=C((uF,ud)=>{"use strict";var qS=Function.prototype.call,jS=Object.prototype.hasOwnProperty,FS=Qt();ud.exports=FS.call(qS,jS)});var pd=C((cF,ld)=>{"use strict";ld.exports=function(e,t){return Object.keys(t).forEach(function(r){e[r]=e[r]||t[r]}),e}});var fd=C((lF,md)=>{"use strict";var $a=vl(),BS=require("util"),Ra=require("path"),GS=require("http"),VS=require("https"),HS=require("url").parse,ZS=require("fs"),WS=require("stream").Stream,KS=require("crypto"),Oa=Sl(),JS=ql(),XS=sd(),_t=cd(),Ca=pd();function dd(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}a(dd,"escapeHeaderParam");function X(e){if(!(this instanceof X))return new X(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],$a.call(this),e=e||{};for(var t in e)this[t]=e[t]}a(X,"FormData");BS.inherits(X,$a);X.LINE_BREAK=`\r
|
|
2
|
-
`;X.DEFAULT_CONTENT_TYPE="application/octet-stream";X.prototype.append=function(e,t,r){r=r||{},typeof r=="string"&&(r={filename:r});var n=$a.prototype.append.bind(this);if((typeof t=="number"||t==null)&&(t=String(t)),Array.isArray(t)){this._error(new Error("Arrays are not supported."));return}var o=this._multiPartHeader(e,t,r),i=this._multiPartFooter();n(o),n(t),n(i),this._trackLength(o,t,r)};X.prototype._trackLength=function(e,t,r){var n=0;r.knownLength!=null?n+=Number(r.knownLength):Buffer.isBuffer(t)?n=t.length:typeof t=="string"&&(n=Buffer.byteLength(t)),this._valueLength+=n,this._overheadLength+=Buffer.byteLength(e)+X.LINE_BREAK.length,!(!t||!t.path&&!(t.readable&&_t(t,"httpVersion"))&&!(t instanceof WS))&&(r.knownLength||this._valuesToMeasure.push(t))};X.prototype._lengthRetriever=function(e,t){_t(e,"fd")?e.end!=null&&e.end!=1/0&&e.start!=null?t(null,e.end+1-(e.start?e.start:0)):ZS.stat(e.path,function(r,n){if(r){t(r);return}var o=n.size-(e.start?e.start:0);t(null,o)}):_t(e,"httpVersion")?t(null,Number(e.headers["content-length"])):_t(e,"httpModule")?(e.on("response",function(r){e.pause(),t(null,Number(r.headers["content-length"]))}),e.resume()):t("Unknown stream")};X.prototype._multiPartHeader=function(e,t,r){if(typeof r.header=="string")return r.header;var n=this._getContentDisposition(t,r),o=this._getContentType(t,r),i="",s={"Content-Disposition":["form-data",'name="'+dd(e)+'"'].concat(n||[]),"Content-Type":[].concat(o||[])};typeof r.header=="object"&&Ca(s,r.header);var l;for(var f in s)if(_t(s,f)){if(l=s[f],l==null)continue;Array.isArray(l)||(l=[l]),l.length&&(i+=f+": "+l.join("; ")+X.LINE_BREAK)}return"--"+this.getBoundary()+X.LINE_BREAK+i+X.LINE_BREAK};X.prototype._getContentDisposition=function(e,t){var r;if(typeof t.filepath=="string"?r=Ra.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e&&(e.name||e.path)?r=Ra.basename(t.filename||e&&(e.name||e.path)):e&&e.readable&&_t(e,"httpVersion")&&(r=Ra.basename(e.client._httpMessage.path||"")),r)return'filename="'+dd(r)+'"'};X.prototype._getContentType=function(e,t){var r=t.contentType;return!r&&e&&e.name&&(r=Oa.lookup(e.name)),!r&&e&&e.path&&(r=Oa.lookup(e.path)),!r&&e&&e.readable&&_t(e,"httpVersion")&&(r=e.headers["content-type"]),!r&&(t.filepath||t.filename)&&(r=Oa.lookup(t.filepath||t.filename)),!r&&e&&typeof e=="object"&&(r=X.DEFAULT_CONTENT_TYPE),r};X.prototype._multiPartFooter=function(){return function(e){var t=X.LINE_BREAK,r=this._streams.length===0;r&&(t+=this._lastBoundary()),e(t)}.bind(this)};X.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+X.LINE_BREAK};X.prototype.getHeaders=function(e){var t,r={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)_t(e,t)&&(r[t.toLowerCase()]=e[t]);return r};X.prototype.setBoundary=function(e){if(typeof e!="string")throw new TypeError("FormData boundary must be a string");this._boundary=e};X.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary};X.prototype.getBuffer=function(){for(var e=new Buffer.alloc(0),t=this.getBoundary(),r=0,n=this._streams.length;r<n;r++)typeof this._streams[r]!="function"&&(Buffer.isBuffer(this._streams[r])?e=Buffer.concat([e,this._streams[r]]):e=Buffer.concat([e,Buffer.from(this._streams[r])]),(typeof this._streams[r]!="string"||this._streams[r].substring(2,t.length+2)!==t)&&(e=Buffer.concat([e,Buffer.from(X.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])};X.prototype._generateBoundary=function(){this._boundary="--------------------------"+KS.randomBytes(12).toString("hex")};X.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;return this._streams.length&&(e+=this._lastBoundary().length),this.hasKnownLength()||this._error(new Error("Cannot calculate proper length in synchronous way.")),e};X.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e};X.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;if(this._streams.length&&(t+=this._lastBoundary().length),!this._valuesToMeasure.length){process.nextTick(e.bind(this,null,t));return}JS.parallel(this._valuesToMeasure,this._lengthRetriever,function(r,n){if(r){e(r);return}n.forEach(function(o){t+=o}),e(null,t)})};X.prototype.submit=function(e,t){var r,n,o={method:"post"};return typeof e=="string"?(e=HS(e),n=Ca({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},o)):(n=Ca(e,o),n.port||(n.port=n.protocol==="https:"?443:80)),n.headers=this.getHeaders(e.headers),n.protocol==="https:"?r=VS.request(n):r=GS.request(n),this.getLength(function(i,s){if(i&&i!=="Unknown stream"){this._error(i);return}if(s&&r.setHeader("Content-Length",s),this.pipe(r),t){var l,f=a(function(b,m){return r.removeListener("error",f),r.removeListener("response",l),t.call(this,b,m)},"callback");l=f.bind(this,null),r.on("error",f),r.on("response",l)}}.bind(this)),r};X.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))};X.prototype.toString=function(){return"[object FormData]"};XS(X.prototype,"FormData");md.exports=X});var fm=C((n4,mm)=>{mm.exports=require("util").inspect});var sn=C((o4,Nm)=>{var Qa=typeof Map=="function"&&Map.prototype,Ga=Object.getOwnPropertyDescriptor&&Qa?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,wo=Qa&&Ga&&typeof Ga.get=="function"?Ga.get:null,hm=Qa&&Map.prototype.forEach,es=typeof Set=="function"&&Set.prototype,Va=Object.getOwnPropertyDescriptor&&es?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,ko=es&&Va&&typeof Va.get=="function"?Va.get:null,ym=es&&Set.prototype.forEach,pT=typeof WeakMap=="function"&&WeakMap.prototype,nn=pT?WeakMap.prototype.has:null,dT=typeof WeakSet=="function"&&WeakSet.prototype,on=dT?WeakSet.prototype.has:null,mT=typeof WeakRef=="function"&&WeakRef.prototype,gm=mT?WeakRef.prototype.deref:null,fT=Boolean.prototype.valueOf,hT=Object.prototype.toString,yT=Function.prototype.toString,gT=String.prototype.match,ts=String.prototype.slice,It=String.prototype.replace,vT=String.prototype.toUpperCase,vm=String.prototype.toLowerCase,Am=RegExp.prototype.test,_m=Array.prototype.concat,We=Array.prototype.join,_T=Array.prototype.slice,bm=Math.floor,Wa=typeof BigInt=="function"?BigInt.prototype.valueOf:null,Ha=Object.getOwnPropertySymbols,Ka=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,lr=typeof Symbol=="function"&&typeof Symbol.iterator=="object",an=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===lr||!0)?Symbol.toStringTag:null,wm=Object.prototype.propertyIsEnumerable,Pm=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function xm(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||Am.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-bm(-e):bm(e);if(n!==e){var o=String(n),i=ts.call(t,o.length+1);return It.call(o,r,"$&_")+"."+It.call(It.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return It.call(t,r,"$&_")}a(xm,"addNumericSeparator");var Ja=fm(),Sm=Ja.custom,Tm=Om(Sm)?Sm:null,km={__proto__:null,double:'"',single:"'"},bT={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};Nm.exports=a(function e(t,r,n,o){var i=r||{};if(st(i,"quoteStyle")&&!st(km,i.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(st(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var s=st(i,"customInspect")?i.customInspect:!0;if(typeof s!="boolean"&&s!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(st(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(st(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var l=i.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return $m(t,i);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var f=String(t);return l?xm(t,f):f}if(typeof t=="bigint"){var b=String(t)+"n";return l?xm(t,b):b}var m=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=m&&m>0&&typeof t=="object")return Xa(t)?"[Array]":"[Object]";var P=UT(i,n);if(typeof o>"u")o=[];else if(Cm(o,t)>=0)return"[Circular]";function h(we,Ue,Oe){if(Ue&&(o=_T.call(o),o.push(Ue)),Oe){var kr={depth:i.depth};return st(i,"quoteStyle")&&(kr.quoteStyle=i.quoteStyle),e(we,kr,n+1,o)}return e(we,i,n+1,o)}if(a(h,"inspect"),typeof t=="function"&&!Em(t)){var d=kT(t),y=Ao(t,h);return"[Function"+(d?": "+d:" (anonymous)")+"]"+(y.length>0?" { "+We.call(y,", ")+" }":"")}if(Om(t)){var I=lr?It.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):Ka.call(t);return typeof t=="object"&&!lr?rn(I):I}if(DT(t)){for(var S="<"+vm.call(String(t.nodeName)),T=t.attributes||[],A=0;A<T.length;A++)S+=" "+T[A].name+"="+Rm(PT(T[A].value),"double",i);return S+=">",t.childNodes&&t.childNodes.length&&(S+="..."),S+="</"+vm.call(String(t.nodeName))+">",S}if(Xa(t)){if(t.length===0)return"[]";var k=Ao(t,h);return P&&!MT(k)?"["+Ya(k,P)+"]":"[ "+We.call(k,", ")+" ]"}if(ST(t)){var G=Ao(t,h);return!("cause"in Error.prototype)&&"cause"in t&&!wm.call(t,"cause")?"{ ["+String(t)+"] "+We.call(_m.call("[cause]: "+h(t.cause),G),", ")+" }":G.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+We.call(G,", ")+" }"}if(typeof t=="object"&&s){if(Tm&&typeof t[Tm]=="function"&&Ja)return Ja(t,{depth:m-n});if(s!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(RT(t)){var Y=[];return hm&&hm.call(t,function(we,Ue){Y.push(h(Ue,t,!0)+" => "+h(we,t))}),Im("Map",wo.call(t),Y,P)}if($T(t)){var Te=[];return ym&&ym.call(t,function(we){Te.push(h(we,t))}),Im("Set",ko.call(t),Te,P)}if(OT(t))return Za("WeakMap");if(NT(t))return Za("WeakSet");if(CT(t))return Za("WeakRef");if(ET(t))return rn(h(Number(t)));if(AT(t))return rn(h(Wa.call(t)));if(IT(t))return rn(fT.call(t));if(TT(t))return rn(h(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(typeof globalThis<"u"&&t===globalThis||typeof global<"u"&&t===global)return"{ [object globalThis] }";if(!xT(t)&&!Em(t)){var ve=Ao(t,h),ae=Pm?Pm(t)===Object.prototype:t instanceof Object||t.constructor===Object,te=t instanceof Object?"":"null prototype",me=!ae&&an&&Object(t)===t&&an in t?ts.call(At(t),8,-1):te?"Object":"",Me=ae||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",et=Me+(me||te?"["+We.call(_m.call([],me||[],te||[]),": ")+"] ":"");return ve.length===0?et+"{}":P?et+"{"+Ya(ve,P)+"}":et+"{ "+We.call(ve,", ")+" }"}return String(t)},"inspect_");function Rm(e,t,r){var n=r.quoteStyle||t,o=km[n];return o+e+o}a(Rm,"wrapQuotes");function PT(e){return It.call(String(e),/"/g,""")}a(PT,"quote");function zt(e){return!an||!(typeof e=="object"&&(an in e||typeof e[an]<"u"))}a(zt,"canTrustToString");function Xa(e){return At(e)==="[object Array]"&&zt(e)}a(Xa,"isArray");function xT(e){return At(e)==="[object Date]"&&zt(e)}a(xT,"isDate");function Em(e){return At(e)==="[object RegExp]"&&zt(e)}a(Em,"isRegExp");function ST(e){return At(e)==="[object Error]"&&zt(e)}a(ST,"isError");function TT(e){return At(e)==="[object String]"&&zt(e)}a(TT,"isString");function ET(e){return At(e)==="[object Number]"&&zt(e)}a(ET,"isNumber");function IT(e){return At(e)==="[object Boolean]"&&zt(e)}a(IT,"isBoolean");function Om(e){if(lr)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!Ka)return!1;try{return Ka.call(e),!0}catch{}return!1}a(Om,"isSymbol");function AT(e){if(!e||typeof e!="object"||!Wa)return!1;try{return Wa.call(e),!0}catch{}return!1}a(AT,"isBigInt");var wT=Object.prototype.hasOwnProperty||function(e){return e in this};function st(e,t){return wT.call(e,t)}a(st,"has");function At(e){return hT.call(e)}a(At,"toStr");function kT(e){if(e.name)return e.name;var t=gT.call(yT.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}a(kT,"nameOf");function Cm(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}a(Cm,"indexOf");function RT(e){if(!wo||!e||typeof e!="object")return!1;try{wo.call(e);try{ko.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}a(RT,"isMap");function OT(e){if(!nn||!e||typeof e!="object")return!1;try{nn.call(e,nn);try{on.call(e,on)}catch{return!0}return e instanceof WeakMap}catch{}return!1}a(OT,"isWeakMap");function CT(e){if(!gm||!e||typeof e!="object")return!1;try{return gm.call(e),!0}catch{}return!1}a(CT,"isWeakRef");function $T(e){if(!ko||!e||typeof e!="object")return!1;try{ko.call(e);try{wo.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}a($T,"isSet");function NT(e){if(!on||!e||typeof e!="object")return!1;try{on.call(e,on);try{nn.call(e,nn)}catch{return!0}return e instanceof WeakSet}catch{}return!1}a(NT,"isWeakSet");function DT(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}a(DT,"isElement");function $m(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return $m(ts.call(e,0,t.maxStringLength),t)+n}var o=bT[t.quoteStyle||"single"];o.lastIndex=0;var i=It.call(It.call(e,o,"\\$1"),/[\x00-\x1f]/g,zT);return Rm(i,"single",t)}a($m,"inspectString");function zT(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+vT.call(t.toString(16))}a(zT,"lowbyte");function rn(e){return"Object("+e+")"}a(rn,"markBoxed");function Za(e){return e+" { ? }"}a(Za,"weakCollectionOf");function Im(e,t,r,n){var o=n?Ya(r,n):We.call(r,", ");return e+" ("+t+") {"+o+"}"}a(Im,"collectionOf");function MT(e){for(var t=0;t<e.length;t++)if(Cm(e[t],`
|
|
3
|
-
`)>=0)return!1;return!0}
|
|
4
|
-
`+t.prev+t.base;return
|
|
5
|
-
`+t.prev}a(Ya,"indentedJoin");function Ao(e,t){var r=Xa(e),n=[];if(r){n.length=e.length;for(var o=0;o<e.length;o++)n[o]=st(e,o)?t(e[o],e):""}var i=typeof Ha=="function"?Ha(e):[],s;if(lr){s={};for(var l=0;l<i.length;l++)s["$"+i[l]]=i[l]}for(var f in e)st(e,f)&&(r&&String(Number(f))===f&&f<e.length||lr&&s["$"+f]instanceof Symbol||(Am.call(/[^\w$]/,f)?n.push(t(f,e)+": "+t(e[f],e)):n.push(f+": "+t(e[f],e))));if(typeof Ha=="function")for(var b=0;b<i.length;b++)wm.call(e,i[b])&&n.push("["+t(i[b])+"]: "+t(e[i[b]],e));return n}a(Ao,"arrObjKeys")});var zm=C((a4,Dm)=>{"use strict";var LT=sn(),qT=vt(),Ro=a(function(e,t,r){for(var n=e,o;(o=n.next)!=null;n=o)if(o.key===t)return n.next=o.next,r||(o.next=e.next,e.next=o),o},"listGetNode"),jT=a(function(e,t){if(e){var r=Ro(e,t);return r&&r.value}},"listGet"),FT=a(function(e,t,r){var n=Ro(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}},"listSet"),BT=a(function(e,t){return e?!!Ro(e,t):!1},"listHas"),GT=a(function(e,t){if(e)return Ro(e,t,!0)},"listDelete");Dm.exports=a(function(){var t,r={assert:a(function(n){if(!r.has(n))throw new qT("Side channel does not contain "+LT(n))},"assert"),delete:a(function(n){var o=GT(t,n);return o&&t&&!t.next&&(t=void 0),!!o},"delete"),get:a(function(n){return jT(t,n)},"get"),has:a(function(n){return BT(t,n)},"has"),set:a(function(n,o){t||(t={next:void 0}),FT(t,n,o)},"set")};return r},"getSideChannelList")});var rs=C((u4,Lm)=>{"use strict";var Mm=en(),Um=Ea(),VT=Um([Mm("%String.prototype.indexOf%")]);Lm.exports=a(function(t,r){var n=Mm(t,!!r);return typeof n=="function"&&VT(t,".prototype.")>-1?Um([n]):n},"callBoundIntrinsic")});var ns=C((l4,jm)=>{"use strict";var HT=en(),un=rs(),ZT=sn(),WT=vt(),qm=HT("%Map%",!0),KT=un("Map.prototype.get",!0),JT=un("Map.prototype.set",!0),XT=un("Map.prototype.has",!0),YT=un("Map.prototype.delete",!0),QT=un("Map.prototype.size",!0);jm.exports=!!qm&&a(function(){var t,r={assert:a(function(n){if(!r.has(n))throw new WT("Side channel does not contain "+ZT(n))},"assert"),delete:a(function(n){if(t){var o=YT(t,n);return QT(t)===0&&(t=void 0),o}return!1},"delete"),get:a(function(n){if(t)return KT(t,n)},"get"),has:a(function(n){return t?XT(t,n):!1},"has"),set:a(function(n,o){t||(t=new qm),JT(t,n,o)},"set")};return r},"getSideChannelMap")});var Bm=C((d4,Fm)=>{"use strict";var eE=en(),Co=rs(),tE=sn(),Oo=ns(),rE=vt(),pr=eE("%WeakMap%",!0),nE=Co("WeakMap.prototype.get",!0),oE=Co("WeakMap.prototype.set",!0),iE=Co("WeakMap.prototype.has",!0),aE=Co("WeakMap.prototype.delete",!0);Fm.exports=pr?a(function(){var t,r,n={assert:a(function(o){if(!n.has(o))throw new rE("Side channel does not contain "+tE(o))},"assert"),delete:a(function(o){if(pr&&o&&(typeof o=="object"||typeof o=="function")){if(t)return aE(t,o)}else if(Oo&&r)return r.delete(o);return!1},"delete"),get:a(function(o){return pr&&o&&(typeof o=="object"||typeof o=="function")&&t?nE(t,o):r&&r.get(o)},"get"),has:a(function(o){return pr&&o&&(typeof o=="object"||typeof o=="function")&&t?iE(t,o):!!r&&r.has(o)},"has"),set:a(function(o,i){pr&&o&&(typeof o=="object"||typeof o=="function")?(t||(t=new pr),oE(t,o,i)):Oo&&(r||(r=Oo()),r.set(o,i))},"set")};return n},"getSideChannelWeakMap"):Oo});var os=C((f4,Gm)=>{"use strict";var sE=vt(),uE=sn(),cE=zm(),lE=ns(),pE=Bm(),dE=pE||lE||cE;Gm.exports=a(function(){var t,r={assert:a(function(n){if(!r.has(n))throw new sE("Side channel does not contain "+uE(n))},"assert"),delete:a(function(n){return!!t&&t.delete(n)},"delete"),get:a(function(n){return t&&t.get(n)},"get"),has:a(function(n){return!!t&&t.has(n)},"has"),set:a(function(n,o){t||(t=dE()),t.set(n,o)},"set")};return r},"getSideChannel")});var $o=C((y4,Vm)=>{"use strict";var mE=String.prototype.replace,fE=/%20/g,is={RFC1738:"RFC1738",RFC3986:"RFC3986"};Vm.exports={default:is.RFC3986,formatters:{RFC1738:a(function(e){return mE.call(e,fE,"+")},"RFC1738"),RFC3986:a(function(e){return String(e)},"RFC3986")},RFC1738:is.RFC1738,RFC3986:is.RFC3986}});var cs=C((v4,Hm)=>{"use strict";var hE=$o(),yE=os(),as=Object.prototype.hasOwnProperty,Mt=Array.isArray,No=yE(),dr=a(function(t,r){return No.set(t,r),t},"markOverflow"),Ut=a(function(t){return No.has(t)},"isOverflow"),cn=a(function(t){return No.get(t)},"getMaxIndex"),us=a(function(t,r){No.set(t,r)},"setMaxIndex"),Ke=(function(){for(var e=[],t=0;t<256;++t)e[e.length]="%"+((t<16?"0":"")+t.toString(16)).toUpperCase();return e})(),gE=a(function(t){for(;t.length>1;){var r=t.pop(),n=r.obj[r.prop];if(Mt(n)){for(var o=[],i=0;i<n.length;++i)typeof n[i]<"u"&&(o[o.length]=n[i]);r.obj[r.prop]=o}}},"compactQueue"),ln=a(function(t,r){for(var n=r&&r.plainObjects?{__proto__:null}:{},o=0;o<t.length;++o)typeof t[o]<"u"&&(n[o]=t[o]);return n},"arrayToObject"),vE=a(function e(t,r,n){if(!r)return t;if(typeof r!="object"&&typeof r!="function"){if(Mt(t)){var o=t.length;if(n&&typeof n.arrayLimit=="number"&&o>n.arrayLimit)return dr(ln(t.concat(r),n),o);t[o]=r}else if(t&&typeof t=="object")if(Ut(t)){var i=cn(t)+1;t[i]=r,us(t,i)}else(n&&(n.plainObjects||n.allowPrototypes)||!as.call(Object.prototype,r))&&(t[r]=!0);else return[t,r];return t}if(!t||typeof t!="object"){if(Ut(r)){for(var s=Object.keys(r),l=n&&n.plainObjects?{__proto__:null,0:t}:{0:t},f=0;f<s.length;f++){var b=parseInt(s[f],10);l[b+1]=r[s[f]]}return dr(l,cn(r)+1)}var m=[t].concat(r);return n&&typeof n.arrayLimit=="number"&&m.length>n.arrayLimit?dr(ln(m,n),m.length-1):m}var P=t;return Mt(t)&&!Mt(r)&&(P=ln(t,n)),Mt(t)&&Mt(r)?(r.forEach(function(h,d){if(as.call(t,d)){var y=t[d];y&&typeof y=="object"&&h&&typeof h=="object"?t[d]=e(y,h,n):t[t.length]=h}else t[d]=h}),t):Object.keys(r).reduce(function(h,d){var y=r[d];if(as.call(h,d)?h[d]=e(h[d],y,n):h[d]=y,Ut(r)&&!Ut(h)&&dr(h,cn(r)),Ut(h)){var I=parseInt(d,10);String(I)===d&&I>=0&&I>cn(h)&&us(h,I)}return h},P)},"merge"),_E=a(function(t,r){return Object.keys(r).reduce(function(n,o){return n[o]=r[o],n},t)},"assignSingleSource"),bE=a(function(e,t,r){var n=e.replace(/\+/g," ");if(r==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},"decode"),ss=1024,PE=a(function(t,r,n,o,i){if(t.length===0)return t;var s=t;if(typeof t=="symbol"?s=Symbol.prototype.toString.call(t):typeof t!="string"&&(s=String(t)),n==="iso-8859-1")return escape(s).replace(/%u[0-9a-f]{4}/gi,function(d){return"%26%23"+parseInt(d.slice(2),16)+"%3B"});for(var l="",f=0;f<s.length;f+=ss){for(var b=s.length>=ss?s.slice(f,f+ss):s,m=[],P=0;P<b.length;++P){var h=b.charCodeAt(P);if(h===45||h===46||h===95||h===126||h>=48&&h<=57||h>=65&&h<=90||h>=97&&h<=122||i===hE.RFC1738&&(h===40||h===41)){m[m.length]=b.charAt(P);continue}if(h<128){m[m.length]=Ke[h];continue}if(h<2048){m[m.length]=Ke[192|h>>6]+Ke[128|h&63];continue}if(h<55296||h>=57344){m[m.length]=Ke[224|h>>12]+Ke[128|h>>6&63]+Ke[128|h&63];continue}P+=1,h=65536+((h&1023)<<10|b.charCodeAt(P)&1023),m[m.length]=Ke[240|h>>18]+Ke[128|h>>12&63]+Ke[128|h>>6&63]+Ke[128|h&63]}l+=m.join("")}return l},"encode"),xE=a(function(t){for(var r=[{obj:{o:t},prop:"o"}],n=[],o=0;o<r.length;++o)for(var i=r[o],s=i.obj[i.prop],l=Object.keys(s),f=0;f<l.length;++f){var b=l[f],m=s[b];typeof m=="object"&&m!==null&&n.indexOf(m)===-1&&(r[r.length]={obj:s,prop:b},n[n.length]=m)}return gE(r),t},"compact"),SE=a(function(t){return Object.prototype.toString.call(t)==="[object RegExp]"},"isRegExp"),TE=a(function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},"isBuffer"),EE=a(function(t,r,n,o){if(Ut(t)){var i=cn(t)+1;return t[i]=r,us(t,i),t}var s=[].concat(t,r);return s.length>n?dr(ln(s,{plainObjects:o}),s.length-1):s},"combine"),IE=a(function(t,r){if(Mt(t)){for(var n=[],o=0;o<t.length;o+=1)n[n.length]=r(t[o]);return n}return r(t)},"maybeMap");Hm.exports={arrayToObject:ln,assign:_E,combine:EE,compact:xE,decode:bE,encode:PE,isBuffer:TE,isOverflow:Ut,isRegExp:SE,markOverflow:dr,maybeMap:IE,merge:vE}});var Ym=C((b4,Xm)=>{"use strict";var Wm=os(),Do=cs(),pn=$o(),AE=Object.prototype.hasOwnProperty,Km={brackets:a(function(t){return t+"[]"},"brackets"),comma:"comma",indices:a(function(t,r){return t+"["+r+"]"},"indices"),repeat:a(function(t){return t},"repeat")},Je=Array.isArray,wE=Array.prototype.push,Jm=a(function(e,t){wE.apply(e,Je(t)?t:[t])},"pushToArray"),kE=Date.prototype.toISOString,Zm=pn.default,_e={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Do.encode,encodeValuesOnly:!1,filter:void 0,format:Zm,formatter:pn.formatters[Zm],indices:!1,serializeDate:a(function(t){return kE.call(t)},"serializeDate"),skipNulls:!1,strictNullHandling:!1},RE=a(function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},"isNonNullishPrimitive"),ls={},OE=a(function e(t,r,n,o,i,s,l,f,b,m,P,h,d,y,I,S,T,A){for(var k=t,G=A,Y=0,Te=!1;(G=G.get(ls))!==void 0&&!Te;){var ve=G.get(t);if(Y+=1,typeof ve<"u"){if(ve===Y)throw new RangeError("Cyclic object value");Te=!0}typeof G.get(ls)>"u"&&(Y=0)}if(typeof m=="function"?k=m(r,k):k instanceof Date?k=d(k):n==="comma"&&Je(k)&&(k=Do.maybeMap(k,function(Ei){return Ei instanceof Date?d(Ei):Ei})),k===null){if(s)return b&&!S?b(r,_e.encoder,T,"key",y):r;k=""}if(RE(k)||Do.isBuffer(k)){if(b){var ae=S?r:b(r,_e.encoder,T,"key",y);return[I(ae)+"="+I(b(k,_e.encoder,T,"value",y))]}return[I(r)+"="+I(String(k))]}var te=[];if(typeof k>"u")return te;var me;if(n==="comma"&&Je(k))S&&b&&(k=Do.maybeMap(k,b)),me=[{value:k.length>0?k.join(",")||null:void 0}];else if(Je(m))me=m;else{var Me=Object.keys(k);me=P?Me.sort(P):Me}var et=f?String(r).replace(/\./g,"%2E"):String(r),we=o&&Je(k)&&k.length===1?et+"[]":et;if(i&&Je(k)&&k.length===0)return we+"[]";for(var Ue=0;Ue<me.length;++Ue){var Oe=me[Ue],kr=typeof Oe=="object"&&Oe&&typeof Oe.value<"u"?Oe.value:k[Oe];if(!(l&&kr===null)){var Ti=h&&f?String(Oe).replace(/\./g,"%2E"):String(Oe),x_=Je(k)?typeof n=="function"?n(we,Ti):we:we+(h?"."+Ti:"["+Ti+"]");A.set(t,Y);var Us=Wm();Us.set(ls,A),Jm(te,e(kr,x_,n,o,i,s,l,f,n==="comma"&&S&&Je(k)?null:b,m,P,h,d,y,I,S,T,Us))}}return te},"stringify"),CE=a(function(t){if(!t)return _e;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.encodeDotInKeys<"u"&&typeof t.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(t.encoder!==null&&typeof t.encoder<"u"&&typeof t.encoder!="function")throw new TypeError("Encoder has to be a function.");var r=t.charset||_e.charset;if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=pn.default;if(typeof t.format<"u"){if(!AE.call(pn.formatters,t.format))throw new TypeError("Unknown format option provided.");n=t.format}var o=pn.formatters[n],i=_e.filter;(typeof t.filter=="function"||Je(t.filter))&&(i=t.filter);var s;if(t.arrayFormat in Km?s=t.arrayFormat:"indices"in t?s=t.indices?"indices":"repeat":s=_e.arrayFormat,"commaRoundTrip"in t&&typeof t.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var l=typeof t.allowDots>"u"?t.encodeDotInKeys===!0?!0:_e.allowDots:!!t.allowDots;return{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:_e.addQueryPrefix,allowDots:l,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:_e.allowEmptyArrays,arrayFormat:s,charset:r,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:_e.charsetSentinel,commaRoundTrip:!!t.commaRoundTrip,delimiter:typeof t.delimiter>"u"?_e.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:_e.encode,encodeDotInKeys:typeof t.encodeDotInKeys=="boolean"?t.encodeDotInKeys:_e.encodeDotInKeys,encoder:typeof t.encoder=="function"?t.encoder:_e.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:_e.encodeValuesOnly,filter:i,format:n,formatter:o,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:_e.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:_e.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:_e.strictNullHandling}},"normalizeStringifyOptions");Xm.exports=function(e,t){var r=e,n=CE(t),o,i;typeof n.filter=="function"?(i=n.filter,r=i("",r)):Je(n.filter)&&(i=n.filter,o=i);var s=[];if(typeof r!="object"||r===null)return"";var l=Km[n.arrayFormat],f=l==="comma"&&n.commaRoundTrip;o||(o=Object.keys(r)),n.sort&&o.sort(n.sort);for(var b=Wm(),m=0;m<o.length;++m){var P=o[m],h=r[P];n.skipNulls&&h===null||Jm(s,OE(h,P,l,f,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,b))}var d=s.join(n.delimiter),y=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?y+="utf8=%26%2310003%3B&":y+="utf8=%E2%9C%93&"),d.length>0?y+d:""}});var tf=C((x4,ef)=>{"use strict";var Xe=cs(),zo=Object.prototype.hasOwnProperty,ps=Array.isArray,le={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:Xe.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1,throwOnLimitExceeded:!1},$E=a(function(e){return e.replace(/&#(\d+);/g,function(t,r){return String.fromCharCode(parseInt(r,10))})},"interpretNumericEntities"),Qm=a(function(e,t,r){if(e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1)return e.split(",");if(t.throwOnLimitExceeded&&r>=t.arrayLimit)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");return e},"parseArrayValue"),NE="utf8=%26%2310003%3B",DE="utf8=%E2%9C%93",zE=a(function(t,r){var n={__proto__:null},o=r.ignoreQueryPrefix?t.replace(/^\?/,""):t;o=o.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var i=r.parameterLimit===1/0?void 0:r.parameterLimit,s=o.split(r.delimiter,r.throwOnLimitExceeded?i+1:i);if(r.throwOnLimitExceeded&&s.length>i)throw new RangeError("Parameter limit exceeded. Only "+i+" parameter"+(i===1?"":"s")+" allowed.");var l=-1,f,b=r.charset;if(r.charsetSentinel)for(f=0;f<s.length;++f)s[f].indexOf("utf8=")===0&&(s[f]===DE?b="utf-8":s[f]===NE&&(b="iso-8859-1"),l=f,f=s.length);for(f=0;f<s.length;++f)if(f!==l){var m=s[f],P=m.indexOf("]="),h=P===-1?m.indexOf("="):P+1,d,y;if(h===-1?(d=r.decoder(m,le.decoder,b,"key"),y=r.strictNullHandling?null:""):(d=r.decoder(m.slice(0,h),le.decoder,b,"key"),d!==null&&(y=Xe.maybeMap(Qm(m.slice(h+1),r,ps(n[d])?n[d].length:0),function(S){return r.decoder(S,le.decoder,b,"value")}))),y&&r.interpretNumericEntities&&b==="iso-8859-1"&&(y=$E(String(y))),m.indexOf("[]=")>-1&&(y=ps(y)?[y]:y),r.comma&&ps(y)&&y.length>r.arrayLimit){if(r.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(r.arrayLimit===1?"":"s")+" allowed in an array.");y=Xe.combine([],y,r.arrayLimit,r.plainObjects)}if(d!==null){var I=zo.call(n,d);I&&r.duplicates==="combine"?n[d]=Xe.combine(n[d],y,r.arrayLimit,r.plainObjects):(!I||r.duplicates==="last")&&(n[d]=y)}}return n},"parseQueryStringValues"),ME=a(function(e,t,r,n){var o=0;if(e.length>0&&e[e.length-1]==="[]"){var i=e.slice(0,-1).join("");o=Array.isArray(t)&&t[i]?t[i].length:0}for(var s=n?t:Qm(t,r,o),l=e.length-1;l>=0;--l){var f,b=e[l];if(b==="[]"&&r.parseArrays)Xe.isOverflow(s)?f=s:f=r.allowEmptyArrays&&(s===""||r.strictNullHandling&&s===null)?[]:Xe.combine([],s,r.arrayLimit,r.plainObjects);else{f=r.plainObjects?{__proto__:null}:{};var m=b.charAt(0)==="["&&b.charAt(b.length-1)==="]"?b.slice(1,-1):b,P=r.decodeDotInKeys?m.replace(/%2E/g,"."):m,h=parseInt(P,10),d=!isNaN(h)&&b!==P&&String(h)===P&&h>=0&&r.parseArrays;if(!r.parseArrays&&P==="")f={0:s};else if(d&&h<r.arrayLimit)f=[],f[h]=s;else{if(d&&r.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(r.arrayLimit===1?"":"s")+" allowed in an array.");d?(f[h]=s,Xe.markOverflow(f,h)):P!=="__proto__"&&(f[P]=s)}}s=f}return s},"parseObject"),UE=a(function(t,r){var n=r.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t;if(r.depth<=0)return!r.plainObjects&&zo.call(Object.prototype,n)&&!r.allowPrototypes?void 0:[n];var o=/(\[[^[\]]*])/,i=/(\[[^[\]]*])/g,s=o.exec(n),l=s?n.slice(0,s.index):n,f=[];if(l){if(!r.plainObjects&&zo.call(Object.prototype,l)&&!r.allowPrototypes)return;f[f.length]=l}for(var b=0;(s=i.exec(n))!==null&&b<r.depth;){b+=1;var m=s[1].slice(1,-1);if(!r.plainObjects&&zo.call(Object.prototype,m)&&!r.allowPrototypes)return;f[f.length]=s[1]}if(s){if(r.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+r.depth+" and strictDepth is true");f[f.length]="["+n.slice(s.index)+"]"}return f},"splitKeyIntoSegments"),LE=a(function(t,r,n,o){if(t){var i=UE(t,n);if(i)return ME(i,r,n,o)}},"parseQueryStringKeys"),qE=a(function(t){if(!t)return le;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.decodeDotInKeys<"u"&&typeof t.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(t.decoder!==null&&typeof t.decoder<"u"&&typeof t.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof t.throwOnLimitExceeded<"u"&&typeof t.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var r=typeof t.charset>"u"?le.charset:t.charset,n=typeof t.duplicates>"u"?le.duplicates:t.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var o=typeof t.allowDots>"u"?t.decodeDotInKeys===!0?!0:le.allowDots:!!t.allowDots;return{allowDots:o,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:le.allowEmptyArrays,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:le.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:le.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:le.arrayLimit,charset:r,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:le.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:le.comma,decodeDotInKeys:typeof t.decodeDotInKeys=="boolean"?t.decodeDotInKeys:le.decodeDotInKeys,decoder:typeof t.decoder=="function"?t.decoder:le.decoder,delimiter:typeof t.delimiter=="string"||Xe.isRegExp(t.delimiter)?t.delimiter:le.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:le.depth,duplicates:n,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:le.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:le.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:le.plainObjects,strictDepth:typeof t.strictDepth=="boolean"?!!t.strictDepth:le.strictDepth,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:le.strictNullHandling,throwOnLimitExceeded:typeof t.throwOnLimitExceeded=="boolean"?t.throwOnLimitExceeded:!1}},"normalizeParseOptions");ef.exports=function(e,t){var r=qE(t);if(e===""||e===null||typeof e>"u")return r.plainObjects?{__proto__:null}:{};for(var n=typeof e=="string"?zE(e,r):e,o=r.plainObjects?{__proto__:null}:{},i=Object.keys(n),s=0;s<i.length;++s){var l=i[s],f=LE(l,n[l],r,typeof e=="string");o=Xe.merge(o,f,r)}return r.allowSparse===!0?o:Xe.compact(o)}});var nf=C((T4,rf)=>{"use strict";var jE=Ym(),FE=tf(),BE=$o();rf.exports={formats:BE,parse:FE,stringify:jE}});var WI={};Mn(WI,{stripe:()=>ZI,stripeAuth:()=>g});module.exports=w_(WI);var k_=Object.freeze({status:"aborted"});function $(e,t,r){function n(l,f){if(l._zod||Object.defineProperty(l,"_zod",{value:{def:f,constr:s,traits:new Set},enumerable:!1}),l._zod.traits.has(e))return;l._zod.traits.add(e),t(l,f);let b=s.prototype,m=Object.keys(b);for(let P=0;P<m.length;P++){let h=m[P];h in l||(l[h]=b[h].bind(l))}}a(n,"init");let o=r?.Parent??Object;class i extends o{static{a(this,"Definition")}}Object.defineProperty(i,"name",{value:e});function s(l){var f;let b=r?.Parent?new i:this;n(b,l),(f=b._zod).deferred??(f.deferred=[]);for(let m of b._zod.deferred)m();return b}return a(s,"_"),Object.defineProperty(s,"init",{value:n}),Object.defineProperty(s,Symbol.hasInstance,{value:a(l=>r?.Parent&&l instanceof r.Parent?!0:l?._zod?.traits?.has(e),"value")}),Object.defineProperty(s,"name",{value:e}),s}a($,"$constructor");var Ve=class extends Error{static{a(this,"$ZodAsyncError")}constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},Un=class extends Error{static{a(this,"$ZodEncodeError")}constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},Ii={};function tt(e){return e&&Object.assign(Ii,e),Ii}a(tt,"config");function wi(e){let t=Object.values(e).filter(n=>typeof n=="number");return Object.entries(e).filter(([n,o])=>t.indexOf(+n)===-1).map(([n,o])=>o)}a(wi,"getEnumValues");function js(e,t){return typeof t=="bigint"?t.toString():t}a(js,"jsonStringifyReplacer");function qn(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}a(qn,"cached");function Fs(e){return e==null}a(Fs,"nullish");function jn(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}a(jn,"cleanRegex");var qs=Symbol("evaluating");function fe(e,t,r){let n;Object.defineProperty(e,t,{get(){if(n!==qs)return n===void 0&&(n=qs,n=r()),n},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}a(fe,"defineLazy");var ki="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Or(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}a(Or,"isObject");var R_=qn(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function Bs(e){if(Or(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let r=t.prototype;return!(Or(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}a(Bs,"isPlainObject");var Gs=new Set(["string","number","symbol"]);function Gt(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}a(Gt,"escapeRegex");function Fn(e,t,r){let n=new e._zod.constr(t??e._zod.def);return(!t||r?.parent)&&(n._zod.parent=e),n}a(Fn,"clone");function re(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:a(()=>t,"error")};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:a(()=>t.error,"error")}:t}a(re,"normalizeParams");function Vs(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}a(Vs,"optionalKeys");var Hs={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]};function Vt(e,t=0){if(e.aborted===!0)return!0;for(let r=t;r<e.issues.length;r++)if(e.issues[r]?.continue!==!0)return!0;return!1}a(Vt,"aborted");function ct(e,t){return t.map(r=>{var n;return(n=r).path??(n.path=[]),r.path.unshift(e),r})}a(ct,"prefixIssues");function Ln(e){return typeof e=="string"?e:e?.message}a(Ln,"unwrapMessage");function lt(e,t,r){let n={...e,path:e.path??[]};if(!e.message){let o=Ln(e.inst?._zod.def?.error?.(e))??Ln(t?.error?.(e))??Ln(r.customError?.(e))??Ln(r.localeError?.(e))??"Invalid input";n.message=o}return delete n.inst,delete n.continue,t?.reportInput||delete n.input,n}a(lt,"finalizeIssue");function Zs(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}a(Zs,"getLengthableOrigin");function Ri(...e){let[t,r,n]=e;return typeof t=="string"?{message:t,code:"custom",input:r,inst:n}:{...t}}a(Ri,"issue");var Ws=a((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,js,2),Object.defineProperty(e,"toString",{value:a(()=>e.message,"value"),enumerable:!1})},"initializer"),Ks=$("$ZodError",Ws),Cr=$("$ZodError",Ws,{Parent:Error});var C_=a(e=>(t,r,n,o)=>{let i=n?Object.assign(n,{async:!1}):{async:!1},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise)throw new Ve;if(s.issues.length){let l=new(o?.Err??e)(s.issues.map(f=>lt(f,i,tt())));throw ki(l,o?.callee),l}return s.value},"_parse"),Bn=C_(Cr),$_=a(e=>async(t,r,n,o)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},s=t._zod.run({value:r,issues:[]},i);if(s instanceof Promise&&(s=await s),s.issues.length){let l=new(o?.Err??e)(s.issues.map(f=>lt(f,i,tt())));throw ki(l,o?.callee),l}return s.value},"_parseAsync"),Gn=$_(Cr),N_=a(e=>(t,r,n)=>{let o=n?{...n,async:!1}:{async:!1},i=t._zod.run({value:r,issues:[]},o);if(i instanceof Promise)throw new Ve;return i.issues.length?{success:!1,error:new(e??Ks)(i.issues.map(s=>lt(s,o,tt())))}:{success:!0,data:i.value}},"_safeParse"),$r=N_(Cr),D_=a(e=>async(t,r,n)=>{let o=n?Object.assign(n,{async:!0}):{async:!0},i=t._zod.run({value:r,issues:[]},o);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(s=>lt(s,o,tt())))}:{success:!0,data:i.value}},"_safeParseAsync"),Nr=D_(Cr);var z_="(?:(?:\\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])))",M_=new RegExp(`^${z_}$`);var Js=a(e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},"string"),Xs=/^-?\d+n?$/,Ys=/^-?\d+$/,Oi=/^-?\d+(?:\.\d+)?$/,Qs=/^(?:true|false)$/i;var pt=$("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),U_={number:"number",bigint:"bigint",object:"date"};var eu=$("$ZodCheckGreaterThan",(e,t)=>{pt.init(e,t);let r=U_[typeof t.value];e._zod.onattach.push(n=>{let o=n._zod.bag,i=(t.inclusive?o.minimum:o.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?o.minimum=t.value:o.exclusiveMinimum=t.value)}),e._zod.check=n=>{(t.inclusive?n.value>=t.value:n.value>t.value)||n.issues.push({origin:r,code:"too_small",minimum:typeof t.value=="object"?t.value.getTime():t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}});var tu=$("$ZodCheckNumberFormat",(e,t)=>{pt.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),n=r?"int":"number",[o,i]=Hs[t.format];e._zod.onattach.push(s=>{let l=s._zod.bag;l.format=t.format,l.minimum=o,l.maximum=i,r&&(l.pattern=Ys)}),e._zod.check=s=>{let l=s.value;if(r){if(!Number.isInteger(l)){s.issues.push({expected:n,format:t.format,code:"invalid_type",continue:!1,input:l,inst:e});return}if(!Number.isSafeInteger(l)){l>0?s.issues.push({input:l,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,inclusive:!0,continue:!t.abort}):s.issues.push({input:l,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,inclusive:!0,continue:!t.abort});return}}l<o&&s.issues.push({origin:"number",input:l,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort}),l>i&&s.issues.push({origin:"number",input:l,code:"too_big",maximum:i,inclusive:!0,inst:e,continue:!t.abort})}});var ru=$("$ZodCheckMinLength",(e,t)=>{var r;pt.init(e,t),(r=e._zod.def).when??(r.when=n=>{let o=n.value;return!Fs(o)&&o.length!==void 0}),e._zod.onattach.push(n=>{let o=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>o&&(n._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let o=n.value;if(o.length>=t.minimum)return;let s=Zs(o);n.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:o,inst:e,continue:!t.abort})}});var Ci=$("$ZodCheckStringFormat",(e,t)=>{var r,n;pt.init(e,t),e._zod.onattach.push(o=>{let i=o._zod.bag;i.format=t.format,t.pattern&&(i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern))}),t.pattern?(r=e._zod).check??(r.check=o=>{t.pattern.lastIndex=0,!t.pattern.test(o.value)&&o.issues.push({origin:"string",code:"invalid_format",format:t.format,input:o.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(n=e._zod).check??(n.check=()=>{})}),nu=$("$ZodCheckRegex",(e,t)=>{Ci.init(e,t),e._zod.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:"regex",input:r.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}});var iu={major:4,minor:3,patch:6};var se=$("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=iu;let n=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&n.unshift(e);for(let o of n)for(let i of o._zod.onattach)i(e);if(n.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let o=a((s,l,f)=>{let b=Vt(s),m;for(let P of l){if(P._zod.def.when){if(!P._zod.def.when(s))continue}else if(b)continue;let h=s.issues.length,d=P._zod.check(s);if(d instanceof Promise&&f?.async===!1)throw new Ve;if(m||d instanceof Promise)m=(m??Promise.resolve()).then(async()=>{await d,s.issues.length!==h&&(b||(b=Vt(s,h)))});else{if(s.issues.length===h)continue;b||(b=Vt(s,h))}}return m?m.then(()=>s):s},"runChecks"),i=a((s,l,f)=>{if(Vt(s))return s.aborted=!0,s;let b=o(l,n,f);if(b instanceof Promise){if(f.async===!1)throw new Ve;return b.then(m=>e._zod.parse(m,f))}return e._zod.parse(b,f)},"handleCanaryResult");e._zod.run=(s,l)=>{if(l.skipChecks)return e._zod.parse(s,l);if(l.direction==="backward"){let b=e._zod.parse({value:s.value,issues:[]},{...l,skipChecks:!0});return b instanceof Promise?b.then(m=>i(m,s,l)):i(b,s,l)}let f=e._zod.parse(s,l);if(f instanceof Promise){if(l.async===!1)throw new Ve;return f.then(b=>o(b,n,l))}return o(f,n,l)}}fe(e,"~standard",()=>({validate:a(o=>{try{let i=$r(e,o);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return Nr(e,o).then(s=>s.success?{value:s.data}:{issues:s.error?.issues})}},"validate"),vendor:"zod",version:1}))}),Zn=$("$ZodString",(e,t)=>{se.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Js(e._zod.bag),e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=String(r.value)}catch{}return typeof r.value=="string"||r.issues.push({expected:"string",code:"invalid_type",input:r.value,inst:e}),r}}),$i=$("$ZodStringFormat",(e,t)=>{Ci.init(e,t),Zn.init(e,t)});var lu=$("$ZodURL",(e,t)=>{$i.init(e,t),e._zod.check=r=>{try{let n=r.value.trim(),o=new URL(n);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(o.hostname)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:r.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(o.protocol.endsWith(":")?o.protocol.slice(0,-1):o.protocol)||r.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:r.value,inst:e,continue:!t.abort})),t.normalize?r.value=o.href:r.value=n;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}});var Ni=$("$ZodNumber",(e,t)=>{se.init(e,t),e._zod.pattern=e._zod.bag.pattern??Oi,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=Number(r.value)}catch{}let o=r.value;if(typeof o=="number"&&!Number.isNaN(o)&&Number.isFinite(o))return r;let i=typeof o=="number"?Number.isNaN(o)?"NaN":Number.isFinite(o)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:o,inst:e,...i?{received:i}:{}}),r}}),pu=$("$ZodNumberFormat",(e,t)=>{tu.init(e,t),Ni.init(e,t)}),Di=$("$ZodBoolean",(e,t)=>{se.init(e,t),e._zod.pattern=Qs,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=!!r.value}catch{}let o=r.value;return typeof o=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:o,inst:e}),r}}),du=$("$ZodBigInt",(e,t)=>{se.init(e,t),e._zod.pattern=Xs,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=BigInt(r.value)}catch{}return typeof r.value=="bigint"||r.issues.push({expected:"bigint",code:"invalid_type",input:r.value,inst:e}),r}});var mu=$("$ZodAny",(e,t)=>{se.init(e,t),e._zod.parse=r=>r}),fu=$("$ZodUnknown",(e,t)=>{se.init(e,t),e._zod.parse=r=>r});var hu=$("$ZodVoid",(e,t)=>{se.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;return typeof o>"u"||r.issues.push({expected:"void",code:"invalid_type",input:o,inst:e}),r}}),yu=$("$ZodDate",(e,t)=>{se.init(e,t),e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=new Date(r.value)}catch{}let o=r.value,i=o instanceof Date;return i&&!Number.isNaN(o.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:o,...i?{received:"Invalid Date"}:{},inst:e}),r}});function au(e,t,r){e.issues.length&&t.issues.push(...ct(r,e.issues)),t.value[r]=e.value}a(au,"handleArrayResult");var gu=$("$ZodArray",(e,t)=>{se.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;if(!Array.isArray(o))return r.issues.push({expected:"array",code:"invalid_type",input:o,inst:e}),r;r.value=Array(o.length);let i=[];for(let s=0;s<o.length;s++){let l=o[s],f=t.element._zod.run({value:l,issues:[]},n);f instanceof Promise?i.push(f.then(b=>au(b,r,s))):au(f,r,s)}return i.length?Promise.all(i).then(()=>r):r}});function Hn(e,t,r,n,o){if(e.issues.length){if(o&&!(r in n))return;t.issues.push(...ct(r,e.issues))}e.value===void 0?r in n&&(t.value[r]=void 0):t.value[r]=e.value}a(Hn,"handlePropertyResult");function L_(e){let t=Object.keys(e.shape);for(let n of t)if(!e.shape?.[n]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${n}": expected a Zod schema`);let r=Vs(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(r)}}a(L_,"normalizeDef");function q_(e,t,r,n,o,i){let s=[],l=o.keySet,f=o.catchall._zod,b=f.def.type,m=f.optout==="optional";for(let P in t){if(l.has(P))continue;if(b==="never"){s.push(P);continue}let h=f.run({value:t[P],issues:[]},n);h instanceof Promise?e.push(h.then(d=>Hn(d,r,P,t,m))):Hn(h,r,P,t,m)}return s.length&&r.issues.push({code:"unrecognized_keys",keys:s,input:t,inst:i}),e.length?Promise.all(e).then(()=>r):r}a(q_,"handleCatchall");var vu=$("$ZodObject",(e,t)=>{if(se.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){let l=t.shape;Object.defineProperty(t,"shape",{get:a(()=>{let f={...l};return Object.defineProperty(t,"shape",{value:f}),f},"get")})}let n=qn(()=>L_(t));fe(e._zod,"propValues",()=>{let l=t.shape,f={};for(let b in l){let m=l[b]._zod;if(m.values){f[b]??(f[b]=new Set);for(let P of m.values)f[b].add(P)}}return f});let o=Or,i=t.catchall,s;e._zod.parse=(l,f)=>{s??(s=n.value);let b=l.value;if(!o(b))return l.issues.push({expected:"object",code:"invalid_type",input:b,inst:e}),l;l.value={};let m=[],P=s.shape;for(let h of s.keys){let d=P[h],y=d._zod.optout==="optional",I=d._zod.run({value:b[h],issues:[]},f);I instanceof Promise?m.push(I.then(S=>Hn(S,l,h,b,y))):Hn(I,l,h,b,y)}return i?q_(m,b,l,f,n.value,e):m.length?Promise.all(m).then(()=>l):l}});function su(e,t,r,n){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let o=e.filter(i=>!Vt(i));return o.length===1?(t.value=o[0].value,o[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map(i=>i.issues.map(s=>lt(s,n,tt())))}),t)}a(su,"handleUnionResults");var zi=$("$ZodUnion",(e,t)=>{se.init(e,t),fe(e._zod,"optin",()=>t.options.some(o=>o._zod.optin==="optional")?"optional":void 0),fe(e._zod,"optout",()=>t.options.some(o=>o._zod.optout==="optional")?"optional":void 0),fe(e._zod,"values",()=>{if(t.options.every(o=>o._zod.values))return new Set(t.options.flatMap(o=>Array.from(o._zod.values)))}),fe(e._zod,"pattern",()=>{if(t.options.every(o=>o._zod.pattern)){let o=t.options.map(i=>i._zod.pattern);return new RegExp(`^(${o.map(i=>jn(i.source)).join("|")})$`)}});let r=t.options.length===1,n=t.options[0]._zod.run;e._zod.parse=(o,i)=>{if(r)return n(o,i);let s=!1,l=[];for(let f of t.options){let b=f._zod.run({value:o.value,issues:[]},i);if(b instanceof Promise)l.push(b),s=!0;else{if(b.issues.length===0)return b;l.push(b)}}return s?Promise.all(l).then(f=>su(f,o,e,i)):su(l,o,e,i)}});var _u=$("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,zi.init(e,t);let r=e._zod.parse;fe(e._zod,"propValues",()=>{let o={};for(let i of t.options){let s=i._zod.propValues;if(!s||Object.keys(s).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[l,f]of Object.entries(s)){o[l]||(o[l]=new Set);for(let b of f)o[l].add(b)}}return o});let n=qn(()=>{let o=t.options,i=new Map;for(let s of o){let l=s._zod.propValues?.[t.discriminator];if(!l||l.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(s)}"`);for(let f of l){if(i.has(f))throw new Error(`Duplicate discriminator value "${String(f)}"`);i.set(f,s)}}return i});e._zod.parse=(o,i)=>{let s=o.value;if(!Or(s))return o.issues.push({code:"invalid_type",expected:"object",input:s,inst:e}),o;let l=n.value.get(s?.[t.discriminator]);return l?l._zod.run(o,i):t.unionFallback?r(o,i):(o.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:s,path:[t.discriminator],inst:e}),o)}});var bu=$("$ZodRecord",(e,t)=>{se.init(e,t),e._zod.parse=(r,n)=>{let o=r.value;if(!Bs(o))return r.issues.push({expected:"record",code:"invalid_type",input:o,inst:e}),r;let i=[],s=t.keyType._zod.values;if(s){r.value={};let l=new Set;for(let b of s)if(typeof b=="string"||typeof b=="number"||typeof b=="symbol"){l.add(typeof b=="number"?b.toString():b);let m=t.valueType._zod.run({value:o[b],issues:[]},n);m instanceof Promise?i.push(m.then(P=>{P.issues.length&&r.issues.push(...ct(b,P.issues)),r.value[b]=P.value})):(m.issues.length&&r.issues.push(...ct(b,m.issues)),r.value[b]=m.value)}let f;for(let b in o)l.has(b)||(f=f??[],f.push(b));f&&f.length>0&&r.issues.push({code:"unrecognized_keys",input:o,inst:e,keys:f})}else{r.value={};for(let l of Reflect.ownKeys(o)){if(l==="__proto__")continue;let f=t.keyType._zod.run({value:l,issues:[]},n);if(f instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof l=="string"&&Oi.test(l)&&f.issues.length){let P=t.keyType._zod.run({value:Number(l),issues:[]},n);if(P instanceof Promise)throw new Error("Async schemas not supported in object keys currently");P.issues.length===0&&(f=P)}if(f.issues.length){t.mode==="loose"?r.value[l]=o[l]:r.issues.push({code:"invalid_key",origin:"record",issues:f.issues.map(P=>lt(P,n,tt())),input:l,path:[l],inst:e});continue}let m=t.valueType._zod.run({value:o[l],issues:[]},n);m instanceof Promise?i.push(m.then(P=>{P.issues.length&&r.issues.push(...ct(l,P.issues)),r.value[f.value]=P.value})):(m.issues.length&&r.issues.push(...ct(l,m.issues)),r.value[f.value]=m.value)}}return i.length?Promise.all(i).then(()=>r):r}});var Pu=$("$ZodEnum",(e,t)=>{se.init(e,t);let r=wi(t.entries),n=new Set(r);e._zod.values=n,e._zod.pattern=new RegExp(`^(${r.filter(o=>Gs.has(typeof o)).map(o=>typeof o=="string"?Gt(o):o.toString()).join("|")})$`),e._zod.parse=(o,i)=>{let s=o.value;return n.has(s)||o.issues.push({code:"invalid_value",values:r,input:s,inst:e}),o}}),xu=$("$ZodLiteral",(e,t)=>{if(se.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");let r=new Set(t.values);e._zod.values=r,e._zod.pattern=new RegExp(`^(${t.values.map(n=>typeof n=="string"?Gt(n):n?Gt(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,o)=>{let i=n.value;return r.has(i)||n.issues.push({code:"invalid_value",values:t.values,input:i,inst:e}),n}});var Su=$("$ZodTransform",(e,t)=>{se.init(e,t),e._zod.parse=(r,n)=>{if(n.direction==="backward")throw new Un(e.constructor.name);let o=t.transform(r.value,r);if(n.async)return(o instanceof Promise?o:Promise.resolve(o)).then(s=>(r.value=s,r));if(o instanceof Promise)throw new Ve;return r.value=o,r}});function uu(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}a(uu,"handleOptionalResult");var Tu=$("$ZodOptional",(e,t)=>{se.init(e,t),e._zod.optin="optional",e._zod.optout="optional",fe(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),fe(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${jn(r.source)})?$`):void 0}),e._zod.parse=(r,n)=>{if(t.innerType._zod.optin==="optional"){let o=t.innerType._zod.run(r,n);return o instanceof Promise?o.then(i=>uu(i,r.value)):uu(o,r.value)}return r.value===void 0?r:t.innerType._zod.run(r,n)}});var Eu=$("$ZodNullable",(e,t)=>{se.init(e,t),fe(e._zod,"optin",()=>t.innerType._zod.optin),fe(e._zod,"optout",()=>t.innerType._zod.optout),fe(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${jn(r.source)}|null)$`):void 0}),fe(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(r,n)=>r.value===null?r:t.innerType._zod.run(r,n)});var Iu=$("$ZodPipe",(e,t)=>{se.init(e,t),fe(e._zod,"values",()=>t.in._zod.values),fe(e._zod,"optin",()=>t.in._zod.optin),fe(e._zod,"optout",()=>t.out._zod.optout),fe(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(r,n)=>{if(n.direction==="backward"){let i=t.out._zod.run(r,n);return i instanceof Promise?i.then(s=>Vn(s,t.in,n)):Vn(i,t.in,n)}let o=t.in._zod.run(r,n);return o instanceof Promise?o.then(i=>Vn(i,t.out,n)):Vn(o,t.out,n)}});function Vn(e,t,r){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},r)}a(Vn,"handlePipeResult");var Au=$("$ZodCustom",(e,t)=>{pt.init(e,t),se.init(e,t),e._zod.parse=(r,n)=>r,e._zod.check=r=>{let n=r.value,o=t.fn(n);if(o instanceof Promise)return o.then(i=>cu(i,r,n,e));cu(o,r,n,e)}});function cu(e,t,r,n){if(!e){let o={code:"custom",input:r,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};n._zod.def.params&&(o.params=n._zod.def.params),t.issues.push(Ri(o))}}a(cu,"handleRefineResult");var ku;var Mi=class{static{a(this,"$ZodRegistry")}constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...r){let n=r[0];return this._map.set(t,n),n&&typeof n=="object"&&"id"in n&&this._idmap.set(n.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let r=this._map.get(t);return r&&typeof r=="object"&&"id"in r&&this._idmap.delete(r.id),this._map.delete(t),this}get(t){let r=t._zod.parent;if(r){let n={...this.get(r)??{}};delete n.id;let o={...n,...this._map.get(t)};return Object.keys(o).length?o:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function Ru(){return new Mi}a(Ru,"registry");(ku=globalThis).__zod_globalRegistry??(ku.__zod_globalRegistry=Ru());var Ui=globalThis.__zod_globalRegistry;function Ou(e,t){return new e({type:"string",...re(t)})}a(Ou,"_string");function Cu(e,t){return new e({type:"string",coerce:!0,...re(t)})}a(Cu,"_coercedString");function $u(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...re(t)})}a($u,"_url");function Nu(e,t){return new e({type:"number",checks:[],...re(t)})}a(Nu,"_number");function Du(e,t){return new e({type:"number",coerce:!0,checks:[],...re(t)})}a(Du,"_coercedNumber");function zu(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...re(t)})}a(zu,"_int");function Mu(e,t){return new e({type:"boolean",...re(t)})}a(Mu,"_boolean");function Uu(e,t){return new e({type:"boolean",coerce:!0,...re(t)})}a(Uu,"_coercedBoolean");function Lu(e,t){return new e({type:"bigint",coerce:!0,...re(t)})}a(Lu,"_coercedBigint");function qu(e){return new e({type:"any"})}a(qu,"_any");function ju(e){return new e({type:"unknown"})}a(ju,"_unknown");function Fu(e,t){return new e({type:"void",...re(t)})}a(Fu,"_void");function Bu(e,t){return new e({type:"date",coerce:!0,...re(t)})}a(Bu,"_coercedDate");function Wn(e,t){return new eu({check:"greater_than",...re(t),value:e,inclusive:!0})}a(Wn,"_gte");function qe(e,t){return new ru({check:"min_length",...re(t),minimum:e})}a(qe,"_minLength");function dt(e,t){return new nu({check:"string_format",format:"regex",...re(t),pattern:e})}a(dt,"_regex");function Gu(e,t,r){let n=re(r);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}a(Gu,"_custom");var he=$("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");se.init(e,t),e.def=t,e.type=t.type,e.parse=(r,n)=>Bn(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>$r(e,r,n),e.parseAsync=async(r,n)=>Gn(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>Nr(e,r,n),e.check=(...r)=>e.clone({...t,checks:[...t.checks??[],...r.map(n=>typeof n=="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]},{parent:!0}),e.with=e.check,e.clone=(r,n)=>Fn(e,r,n),e.brand=()=>e,e.register=((r,n)=>(r.add(e,n),e)),e.apply=r=>r(e)}),Jn=$("ZodMiniString",(e,t)=>{Zn.init(e,t),he.init(e,t)});function p(e){return Ou(Jn,e)}a(p,"string");var Vu=$("ZodMiniStringFormat",(e,t)=>{$i.init(e,t),Jn.init(e,t)});var Q_=$("ZodMiniURL",(e,t)=>{lu.init(e,t),Vu.init(e,t)});function Hu(e){return $u(Q_,e)}a(Hu,"url");var Xn=$("ZodMiniNumber",(e,t)=>{Ni.init(e,t),he.init(e,t)});function be(e){return Nu(Xn,e)}a(be,"number");var eb=$("ZodMiniNumberFormat",(e,t)=>{pu.init(e,t),Xn.init(e,t)});function Zu(e){return zu(eb,e)}a(Zu,"int");var Li=$("ZodMiniBoolean",(e,t)=>{Di.init(e,t),he.init(e,t)});function J(e){return Mu(Li,e)}a(J,"boolean");var Wu=$("ZodMiniBigInt",(e,t)=>{du.init(e,t),he.init(e,t)});var tb=$("ZodMiniAny",(e,t)=>{mu.init(e,t),he.init(e,t)});function zr(){return qu(tb)}a(zr,"any");var rb=$("ZodMiniUnknown",(e,t)=>{fu.init(e,t),he.init(e,t)});function F(){return ju(rb)}a(F,"unknown");var nb=$("ZodMiniVoid",(e,t)=>{hu.init(e,t),he.init(e,t)});function Ku(e){return Fu(nb,e)}a(Ku,"_void");var Ju=$("ZodMiniDate",(e,t)=>{yu.init(e,t),he.init(e,t)});var ob=$("ZodMiniArray",(e,t)=>{gu.init(e,t),he.init(e,t)});function U(e,t){return new ob({type:"array",element:e,...re(t)})}a(U,"array");var ib=$("ZodMiniObject",(e,t)=>{vu.init(e,t),he.init(e,t),fe(e,"shape",()=>t.shape)});function E(e,t){let r={type:"object",shape:e??{},...re(t)};return new ib(r)}a(E,"object");var ab=$("ZodMiniUnion",(e,t)=>{zi.init(e,t),he.init(e,t)});function Z(e,t){return new ab({type:"union",options:e,...re(t)})}a(Z,"union");var sb=$("ZodMiniDiscriminatedUnion",(e,t)=>{_u.init(e,t),he.init(e,t)});function mt(e,t,r){return new sb({type:"union",options:t,discriminator:e,...re(r)})}a(mt,"discriminatedUnion");var ub=$("ZodMiniRecord",(e,t)=>{bu.init(e,t),he.init(e,t)});function B(e,t,r){return new ub({type:"record",keyType:e,valueType:t,...re(r)})}a(B,"record");var cb=$("ZodMiniEnum",(e,t)=>{Pu.init(e,t),he.init(e,t),e.options=Object.values(t.entries)});function z(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new cb({type:"enum",entries:r,...re(t)})}a(z,"_enum");var lb=$("ZodMiniLiteral",(e,t)=>{xu.init(e,t),he.init(e,t)});function D(e,t){return new lb({type:"literal",values:Array.isArray(e)?e:[e],...re(t)})}a(D,"literal");var pb=$("ZodMiniTransform",(e,t)=>{Su.init(e,t),he.init(e,t)});function ft(e){return new pb({type:"transform",transform:e})}a(ft,"transform");var db=$("ZodMiniOptional",(e,t)=>{Tu.init(e,t),he.init(e,t)});function w(e){return new db({type:"optional",innerType:e})}a(w,"optional");var mb=$("ZodMiniNullable",(e,t)=>{Eu.init(e,t),he.init(e,t)});function Mr(e){return new mb({type:"nullable",innerType:e})}a(Mr,"nullable");var fb=$("ZodMiniPipe",(e,t)=>{Iu.init(e,t),he.init(e,t)});function ht(e,t){return new fb({type:"pipe",in:e,out:t})}a(ht,"pipe");var hb=$("ZodMiniCustom",(e,t)=>{Au.init(e,t),he.init(e,t)});function Yn(e,t){return Gu(hb,e??(()=>!0),t)}a(Yn,"custom");var Ur={};Mn(Ur,{bigint:()=>Pb,boolean:()=>bb,date:()=>xb,number:()=>_b,string:()=>vb});function vb(e){return Cu(Jn,e)}a(vb,"string");function _b(e){return Du(Xn,e)}a(_b,"number");function bb(e){return Uu(Li,e)}a(bb,"boolean");function Pb(e){return Lu(Wu,e)}a(Pb,"bigint");function xb(e){return Bu(Ju,e)}a(xb,"date");var ji=E({retryOnFailure:E({defaultValue:w(J()),hide:w(J())}),continueOnFailure:E({defaultValue:w(J()),hide:w(J())})}),qi=class{constructor(t,r,n,o,i,s,l,f,b,m,P,h,d){this.name=t;this.displayName=r;this.description=n;this.props=o;this.propertyGroups=i;this.run=s;this.test=l;this.requireAuth=f;this.errorHandlingOptions=b;this.outputSchema=m;this.audience=P;this.aiMetadata=h;this.classification=d}static{a(this,"IAction")}},x=a(e=>new qi(e.name,e.displayName,e.description,e.props,e.propertyGroups,e.run,e.test??e.run,e.requireAuth??!0,e.errorHandlingOptions??{continueOnFailure:{defaultValue:!1},retryOnFailure:{defaultValue:!1}},e.outputSchema,e.audience,e.aiMetadata,e.classification),"createAction");var K=E({displayName:p(),description:w(p()),advanced:w(J()),width:w(z(["half","full"])),icon:w(p()),placeholder:w(p())}),V=a((e,t)=>E({type:D(t),required:J(),defaultValue:w(zr())}),"TPropertyValue");var Ce=E({...K.shape,...V(p(),"SHORT_TEXT").shape}),rt=E({...K.shape,...V(p(),"LONG_TEXT").shape});var Yu=E({label:p(),value:F(),description:w(p()),icon:w(p())}),Qn=E({disabled:w(J()),placeholder:w(p()),options:U(Yu)});var Tb=z(["cards"]),$e=E({...K.shape,options:Qn,display:w(Tb),...V(F(),"STATIC_DROPDOWN").shape}),nt=E({...K.shape,options:Qn,...V(U(F()),"STATIC_MULTI_SELECT_DROPDOWN").shape});var Fi=E({...K.shape,...V(F(),"DROPDOWN").shape,refreshers:U(p())}),Lr=E({...K.shape,...V(U(F()),"MULTI_SELECT_DROPDOWN").shape,refreshers:U(p())});var ot=E({...K.shape,reveals:w(U(p())),...V(J(),"CHECKBOX").shape});var it=E({...K.shape,display:w(z(["stepper"])),min:w(be()),max:w(be()),step:w(be()),...V(be(),"NUMBER").shape});var qr=E({...K.shape,streaming:w(J()),...V(F(),"FILE").shape});var jr=E({...K.shape,...V(p(),"DATE_TIME").shape});var Qu=B(p(),Z([Ce,rt,$e,Lr,nt,ot,it,qr,jr])),Fr=E({...K.shape,properties:Qu,...V(U(F()),"ARRAY").shape});var ec=z(["any_time","last_24_hours","last_7_days","last_30_days","last_90_days","this_month","custom"]),tc=E({preset:w(ec),after:w(p()),before:w(p())}),Bi=E({...K.shape,display:w(z(["dropdown"])),...V(tc,"DATE_RANGE").shape});var Br=E({...K.shape,...V(Z([B(p(),F())]),"JSON").shape});var rc=Z([Ce,$e,Br,Fr,nt]),Eb=B(p(),rc),Gi=E({refreshers:U(p()),...K.shape,...V(F(),"DYNAMIC").shape});var eo=E({...K.shape,...V(Ku(),"MARKDOWN").shape});var Gr=(r=>(r.ARCHIVE="ARCHIVE",r.REGISTRY="REGISTRY",r))(Gr||{}),Ht=(r=>(r.CUSTOM="CUSTOM",r.OFFICIAL="OFFICIAL",r))(Ht||{}),Zt=(T=>(T.ARTIFICIAL_INTELLIGENCE="ARTIFICIAL_INTELLIGENCE",T.COMMUNICATION="COMMUNICATION",T.COMMERCE="COMMERCE",T.CORE="CORE",T.UNIVERSAL_AI="UNIVERSAL_AI",T.FLOW_CONTROL="FLOW_CONTROL",T.BUSINESS_INTELLIGENCE="BUSINESS_INTELLIGENCE",T.ACCOUNTING="ACCOUNTING",T.PRODUCTIVITY="PRODUCTIVITY",T.CONTENT_AND_FILES="CONTENT_AND_FILES",T.DEVELOPER_TOOLS="DEVELOPER_TOOLS",T.CUSTOMER_SUPPORT="CUSTOMER_SUPPORT",T.FORMS_AND_SURVEYS="FORMS_AND_SURVEYS",T.HUMAN_RESOURCES="HUMAN_RESOURCES",T.PAYMENT_PROCESSING="PAYMENT_PROCESSING",T.MARKETING="MARKETING",T.SALES_AND_CRM="SALES_AND_CRM",T))(Zt||{});var Vr=(r=>(r.AUTHORIZATION_CODE="authorization_code",r.CLIENT_CREDENTIALS="client_credentials",r))(Vr||{}),Vi="both_client_credentials_and_authorization_code";var ye=(o=>(o.POLLING="POLLING",o.WEBHOOK="WEBHOOK",o.APP_WEBHOOK="APP_WEBHOOK",o.MANUAL="MANUAL",o))(ye||{}),Hr=(i=>(i.NONE="NONE",i.HEADER_PRESENT="HEADER_PRESENT",i.QUERY_PRESENT="QUERY_PRESENT",i.BODY_PARAM_PRESENT="BODY_PARAM_PRESENT",i.HEAD_REQUEST="HEAD_REQUEST",i))(Hr||{}),Ib=E({strategy:z(Hr),paramName:w(p())}),Zr=(r=>(r.SIMULATION="SIMULATION",r.TEST_FUNCTION="TEST_FUNCTION",r))(Zr||{});var to=(r=>(r.WEBSOCKET="WEBSOCKET",r.NONE="NONE",r))(to||{}),nc=E({status:w(be()),body:w(F()),headers:w(B(p(),p()))}),oc=E({type:D("DELAY"),resumeDateTime:p(),requestIdToReply:w(p()),handlerId:w(p()),streamStepProgress:w(z(to))}),ic=E({type:D("WEBHOOK"),requestId:p(),requestIdToReply:w(p()),response:nc,handlerId:w(p()),streamStepProgress:w(z(to))}),Ab=Z([oc,ic]);var wb=E({body:F(),rawBody:w(F()),headers:B(p(),p()),queryParams:B(p(),p())});function Ne(e){return e==null}a(Ne,"isNil");function H(e){return e==null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:!1}a(H,"isEmpty");function ro(e,t){if(e==null)throw new Error(`${t} is null or undefined`)}a(ro,"assertNotNullOrUndefined");var Hi=Le(require("crypto"),1);var kb=128,yt,Wt,Rb=a(e=>{if(e<0)throw new RangeError("Wrong ID size");try{!yt||yt.length<e?(yt=Buffer.allocUnsafe(e*kb),Hi.default.randomFillSync(yt),Wt=0):Wt+e>yt.length&&(Hi.default.randomFillSync(yt),Wt=0)}catch(t){throw yt=void 0,t}Wt+=e},"fillPool"),Ob=a(e=>(Rb(e|=0),yt.subarray(Wt-e,Wt)),"random"),Cb=a((e,t,r)=>{let n=(2<<31-Math.clz32(e.length-1|1))-1,o=Math.ceil(1.6*n*t/e.length);return(i=t)=>{if(i<=0)return"";let s="";for(;;){let l=r(o),f=o;for(;f--;)if(s+=e[l[f]&n]||"",s.length===i)return s}}},"customRandom"),sc=a((e,t=21)=>Cb(e,t,Ob),"customAlphabet");var $b="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",uc=21,Cz=p().check(dt(new RegExp(`^[0-9a-zA-Z]{${uc}}$`))),Nb=sc($b,uc);var gt=ht(ft(e=>e instanceof Date?e.toISOString():e),p()),De={id:p(),created:gt,updated:gt},ie=a(e=>w(Mr(e)),"Nullable");function Zi(e){return w(Mr(z(e)))}a(Zi,"NullableEnum");var Dz=ht(ft(e=>e==="true"||e===!0?!0:e==="false"||e===!1?!1:void 0),w(J())),no=a(e=>ht(ft(t=>Array.isArray(t)?t:t!==void 0?[t]:void 0),w(U(e))),"OptionalArrayFromQuery");var Uz=B(p(),F());var Wr=(m=>(m.OPENAI="openai",m.OPENROUTER="openrouter",m.ANTHROPIC="anthropic",m.AZURE="azure",m.GOOGLE="google",m.ACTIVEPIECES="activepieces",m.CLOUDFLARE_GATEWAY="cloudflare-gateway",m.CUSTOM="custom",m.BEDROCK="bedrock",m.MISTRAL="mistral",m))(Wr||{});var Jz=p().check(dt(/^#[0-9A-Fa-f]{6}$/));var Yz=E({filename:p(),data:F(),type:D("file"),mimetype:w(p())});var Db=Le(lc());var iM=E({...De,name:p(),permissions:U(p()),platformId:ie(p()),type:p(),userCount:w(be())});var pc=(n=>(n.AGENT_DECIDE="agent-decide",n.CHOOSE_YOURSELF="choose-yourself",n.LEAVE_EMPTY="leave-empty",n))(pc||{}),Wi=(r=>(r.FILE="FILE",r.TABLE="TABLE",r))(Wi||{}),Ki=(n=>(n.SSE="sse",n.STREAMABLE_HTTP="streamable-http",n.SIMPLE_HTTP="http",n))(Ki||{});var Ji=(n=>(n.TEXT="text",n.NUMBER="number",n.BOOLEAN="boolean",n))(Ji||{});var Xi=(r=>(r.IN_PROGRESS="in-progress",r.COMPLETED="completed",r))(Xi||{});var zb=E({mode:z(pc),value:F()}),Mb=E({auth:w(p()),fields:B(p(),zb)}),Ub=E({pieceName:p(),pieceVersion:p(),actionName:p(),predefinedInput:w(Mb)}),Lb=E({type:D("PIECE"),toolName:p().check(qe(1)),pieceMetadata:Ub}),qb=E({type:D("none")}),jb=E({type:D("access_token"),accessToken:p()}),Fb=E({type:D("api_key"),apiKey:p(),apiKeyHeader:p()}),Bb=E({type:D("headers"),headers:B(p(),p())}),Gb=mt("type",[qb,jb,Fb,Bb]),dc=E({type:D("FLOW"),toolName:p().check(qe(1)),externalFlowId:p(),flowDisplayName:w(p())}),mc=E({type:D("MCP"),toolName:p().check(qe(1)),serverUrl:Hu(),protocol:z(Ki),auth:Gb}),fc=E({type:D("KNOWLEDGE_BASE"),toolName:p().check(qe(1)),sourceType:z(Wi),sourceId:p(),sourceName:p()}),Vb=mt("type",[Lb,dc,mc,fc]),Hb=E({displayName:p(),description:w(p()),type:z(Ji)}),hc=E({type:D("MARKDOWN"),markdown:p()}),Kt={type:D("TOOL_CALL"),input:ie(B(p(),F())),output:w(F()),toolName:p(),status:z(Xi),toolCallId:p(),startTime:p(),endTime:w(p())},zM=E(Kt),yc=mt("toolCallType",[E({...Kt,toolCallType:D("PIECE"),pieceName:p(),pieceVersion:p(),actionName:p()}),E({...Kt,toolCallType:D("FLOW"),displayName:p(),externalFlowId:p()}),E({...Kt,toolCallType:D("MCP"),displayName:p(),serverUrl:p()}),E({...Kt,toolCallType:D("KNOWLEDGE_BASE"),displayName:p(),sourceType:p()}),E({...Kt,toolCallType:D("UNKNOWN"),displayName:p()})]),Zb=Z([hc,yc]);var Yi=(r=>(r.IMAGE="image",r.TEXT="text",r))(Yi||{}),at=E({apiKey:p()}),Wb=at,Kb=E({apiKey:p(),apiKeyHash:p()}),Jb=at,Xb=at,Yb=at,Qb=at,eP=at,tP=at,rP=at,Pc=E({accessKeyId:p().check(qe(1)),secretAccessKey:p().check(qe(1))}),nP=E({}),oP=E({}),iP=E({}),aP=E({}),sP=E({}),uP=E({}),xc=E({modelId:p(),modelName:p(),modelType:z(Yi)}),Sc=E({apiKeyHeader:p(),baseUrl:p(),models:U(xc),defaultHeaders:w(B(p(),p()))}),Tc=E({accountId:p(),gatewayId:p(),models:U(xc),vertexProject:w(p()),vertexRegion:w(p())}),Ec=E({resourceName:p(),apiVersion:ht(ft(e=>typeof e=="string"&&e.trim().length===0?void 0:e),w(p()))}),Ic=E({region:p().check(qe(1))}),cP=Z([Wb,Yb,Qb,eP,tP,Xb,Jb,Kb,Pc,rP]),Ac=Z([Sc,Tc,Ec,Ic,nP,iP,aP,sP,oP,uP]),lP=E({id:p(),name:p(),type:z(Yi)}),pP=E({id:p(),name:p(),provider:z(Wr),config:Ac,enabledForChat:J()}),dP=E({provider:z(Wr),config:Ac,auth:cP,platformId:p()});var qM={openai:"openai",anthropic:"anthropic","google-ai-studio":"google","google-vertex-ai":"google"},gc=["gpt-5.5","gpt-5.4-mini","gpt-5.4-nano","gpt-4.1","gpt-4.1-mini"],mP=["claude-sonnet-4-6","claude-opus-4-7","claude-haiku-4-5"],fP=["claude-sonnet-4.6","claude-opus-4.7","claude-haiku-4.5"],vc=["gemini-2.5-pro","gemini-2.5-flash","gemini-3.1-pro-preview","gemini-3-flash-preview"],hP=["grok-4.20","grok-4.1-fast"],yP={openai:gc,anthropic:mP,google:vc,activepieces:[...fP.map(e=>`anthropic/${e}`),...gc.map(e=>`openai/${e}`),...vc.map(e=>`google/${e}`),...hP.map(e=>`x-ai/${e}`)]};var _c=128e3,gP={openai:128e3,anthropic:2e5,google:1048576,bedrock:2e5,azure:128e3,openrouter:128e3,activepieces:2e5,mistral:128e3};function vP({provider:e}){return e?gP[e]??_c:_c}a(vP,"getMaxContextTokens");var bc={openai:"text-embedding-3-small",google:"text-embedding-004",azure:"text-embedding-3-small",activepieces:"text-embedding-3-small",openrouter:"openai/text-embedding-3-small"},_P={anthropic:"native",google:"native",openrouter:"plugin",activepieces:"plugin"},bP=new Set(["anthropic","mistral"]);function He(e){return{chatModels:yP[e],maxContextTokens:vP({provider:e}),defaultEmbeddingModel:bc[e],supportsEmbedding:bc[e]!==void 0,supportsImageGeneration:!bP.has(e),webSearch:_P[e]}}a(He,"buildProviderCapabilities");var PP={openai:He("openai"),anthropic:He("anthropic"),openrouter:He("openrouter"),azure:He("azure"),google:He("google"),"cloudflare-gateway":He("cloudflare-gateway"),custom:He("custom"),bedrock:He("bedrock"),mistral:He("mistral"),activepieces:He("activepieces")};var xP=E({base64Url:p(),fileName:p(),extension:w(p())}),SP=E({mimeType:p(),url:p(),fileName:w(p())}),Qi=Z([xP,SP]);var TP=Z([E({type:D("file"),value:Qi}),E({type:D("markdown"),value:p(),files:w(U(Qi))})]),EP=E({sessionId:p(),message:p(),files:w(U(p()))});var kc=(r=>(r.ON_NEW_RECORD="ON_NEW_RECORD",r.ON_UPDATE_RECORD="ON_UPDATE_RECORD",r))(kc||{}),Rc=(r=>(r.ENABLED="ENABLED",r.DISABLED="DISABLED",r))(Rc||{}),ea=(n=>(n.RECORD_CREATED="RECORD_CREATED",n.RECORD_UPDATED="RECORD_UPDATED",n.RECORD_DELETED="RECORD_DELETED",n))(ea||{});var IP=Z([E({...De,name:p(),externalId:p(),type:D("STATIC_DROPDOWN"),tableId:p(),projectId:p(),data:E({options:U(E({value:p()}))})}),E({...De,name:p(),externalId:p(),type:Z([D("TEXT"),D("NUMBER"),D("DATE"),D("DATETIME")]),tableId:p(),projectId:p()})]),AP=E({...De,name:p(),folderId:ie(p()),projectId:p(),externalId:p(),status:Zi(Rc),trigger:Zi(kc)}),wP=E({...De,tableId:p(),projectId:p(),cells:B(p(),E({updated:p(),created:p(),value:F(),fieldName:p()}))}),kP=E({events:U(z(ea)),webhookUrl:p(),flowId:p()}),RP=E({fields:U(E({id:p(),name:p()})),rows:U(B(p(),p())),name:p()}),OP=E({projectId:p(),limit:w(Ur.number()),cursor:w(p()),name:w(p()),externalIds:no(p()),folderId:w(p()),folderIds:no(p())}),CP=E({records:U(U(E({fieldId:p(),value:Cc()}))),tableId:p()}),$P=E({cells:w(U(E({fieldId:p(),value:Cc()}))),tableId:p(),agentUpdate:w(J())}),Oc=mt("operator",[$t("eq"),$t("neq"),$t("gt"),$t("gte"),$t("lt"),$t("lte"),$t("co"),wc("exists"),wc("not_exists")]),NP=E({tableId:p(),limit:w(Ur.number()),cursor:w(p()),filters:no(Oc)});function Cc(){return ht(ft(e=>e==null?e:String(e)),Mr(p()))}a(Cc,"coerceToString");function $t(e){return E({fieldId:p(),operator:D(e),value:p()})}a($t,"valueFilter");function wc(e){return E({fieldId:p(),operator:D(e)})}a(wc,"existenceFilter");var DP=E({status:w(be()),body:w(F()),headers:w(B(p(),p()))}),zP=E({...De,deleted:ie(gt),ownerId:p(),displayName:p(),platformId:p(),externalId:ie(p())});var $c=E({name:p(),description:w(p()),type:p(),required:J()}),MP=E({pieceName:p(),triggerName:p(),input:E({toolName:p(),toolDescription:p(),inputSchema:U($c),returnsResponse:J()})});var Nc="^[0-9]+\\.[0-9]+\\.[0-9]+$",i0=new RegExp(Nc),LP="^([~^])?[0-9]+\\.[0-9]+\\.[0-9]+$",a0=p().check(dt(new RegExp(Nc))),s0=p().check(dt(new RegExp(LP))),qP=E({packageType:D("ARCHIVE"),pieceType:z(Ht),pieceName:p(),pieceVersion:p(),archiveId:p(),platformId:p()}),Dc=E({packageType:D("REGISTRY"),pieceType:D("OFFICIAL"),pieceName:p(),pieceVersion:p()}),zc=E({packageType:D("REGISTRY"),pieceType:D("CUSTOM"),pieceName:p(),pieceVersion:p(),platformId:p()}),u0=Z([Dc,zc]),c0=Z([qP,Dc,zc]);var jP=mt("type",[E({type:D("CRON_EXPRESSION"),cronExpression:p(),timezone:p()}),E({type:D("INTERVAL"),intervalMs:Zu().check(Wn(6e4))})]),l0=E({...De,type:z(ye),projectId:p(),flowId:p(),triggerName:p(),schedule:ie(jP),flowVersionId:p(),pieceName:p(),pieceVersion:p(),deleted:ie(p()),simulate:J()}),Mc=(S=>(S.UNKNOWN="UNKNOWN",S.FLOW_RUN_LOG="FLOW_RUN_LOG",S.FLOW_RUN_LOG_SLICE="FLOW_RUN_LOG_SLICE",S.PACKAGE_ARCHIVE="PACKAGE_ARCHIVE",S.FLOW_STEP_FILE="FLOW_STEP_FILE",S.SAMPLE_DATA="SAMPLE_DATA",S.TRIGGER_PAYLOAD="TRIGGER_PAYLOAD",S.SAMPLE_DATA_INPUT="SAMPLE_DATA_INPUT",S.TRIGGER_EVENT_FILE="TRIGGER_EVENT_FILE",S.PROJECT_RELEASE="PROJECT_RELEASE",S.FLOW_VERSION_BACKUP="FLOW_VERSION_BACKUP",S.PLATFORM_ASSET="PLATFORM_ASSET",S.USER_PROFILE_PICTURE="USER_PROFILE_PICTURE",S.WEBHOOK_PAYLOAD="WEBHOOK_PAYLOAD",S.KNOWLEDGE_BASE="KNOWLEDGE_BASE",S.FLOW_BUNDLE="FLOW_BUNDLE",S))(Mc||{}),Uc=(r=>(r.NONE="NONE",r.ZSTD="ZSTD",r))(Uc||{}),Lc=(r=>(r.S3="S3",r.DB="DB",r))(Lc||{}),p0=E({...De,projectId:ie(p()),platformId:ie(p()),type:z(Mc),compression:z(Uc),data:w(F()),location:z(Lc),size:ie(be()),fileName:ie(p()),s3Key:ie(p()),metadata:ie(B(p(),p()))}),qc=(n=>(n.ADMIN="ADMIN",n.MEMBER="MEMBER",n.OPERATOR="OPERATOR",n))(qc||{}),jc=(r=>(r.ACTIVE="ACTIVE",r.INACTIVE="INACTIVE",r))(jc||{}),d0=E({id:p(),email:p(),firstName:p(),status:z(jc),externalId:ie(p()),platformId:ie(p()),platformRole:z(qc),lastName:p(),created:gt,updated:gt,lastActiveDate:ie(gt),imageUrl:ie(p())});var ta=E({...K.shape,...V(B(p(),F()),"OBJECT").shape});var ra=E({...K.shape,formatProperty:w(p()),...V(p(),"RICH_TEXT").shape});var Vc=E({...K.shape,...V(p(),"COLOR").shape});var na=Z([Ce,rt,ra,eo,ot,$e,nt,Fi,Lr,Gi,it,Fr,ta,Br,jr,Bi,qr,Vc]),u={ShortText(e){return{...e,valueSchema:void 0,type:"SHORT_TEXT"}},Checkbox(e){return{...e,valueSchema:void 0,type:"CHECKBOX"}},LongText(e){return{...e,valueSchema:void 0,type:"LONG_TEXT"}},RichText(e){return{...e,valueSchema:void 0,type:"RICH_TEXT"}},MarkDown(e){return{displayName:"Markdown",required:!1,description:e.value,type:"MARKDOWN",valueSchema:void 0,variant:e.variant??"INFO"}},Number(e){return{...e,valueSchema:void 0,type:"NUMBER"}},Json(e){return{...e,valueSchema:void 0,type:"JSON"}},Array(e){return{...e,valueSchema:void 0,type:"ARRAY"}},Object(e){return{...e,valueSchema:void 0,type:"OBJECT"}},Dropdown(e){return{...e,valueSchema:void 0,type:"DROPDOWN"}},StaticDropdown(e){return{...e,valueSchema:void 0,type:"STATIC_DROPDOWN"}},MultiSelectDropdown(e){return{...e,valueSchema:void 0,type:"MULTI_SELECT_DROPDOWN"}},DynamicProperties(e){return{...e,valueSchema:void 0,type:"DYNAMIC"}},StaticMultiSelectDropdown(e){return{...e,valueSchema:void 0,type:"STATIC_MULTI_SELECT_DROPDOWN"}},DateTime(e){return{...e,valueSchema:void 0,type:"DATE_TIME"}},DateRange(e){return{...e,valueSchema:void 0,type:"DATE_RANGE"}},File(e){return{...e,valueSchema:void 0,type:"FILE"}},Custom(e){let t=e.code.toString();return{...e,code:t,valueSchema:void 0,type:"CUSTOM"}},Color(e){return{...e,valueSchema:void 0,type:"COLOR"}}};var Ze=E({displayName:p(),description:w(p()),hasConnectionIdentifier:w(J())});var Hc=E({username:p(),password:p()}),oa=E({...Ze.shape,username:E({displayName:p(),description:w(p())}),password:E({displayName:p(),description:w(p())}),...V(Hc,"BASIC_AUTH").shape});var VP=B(p(),Z([Ce,rt,it,ot,$e])),ia=E({...Ze.shape,props:VP,...V(F(),"CUSTOM_AUTH").shape});var Nt=E({...Ze.shape,...V(E({auth:p()}),"SECRET_TEXT").shape});var HP=B(p(),Z([Ce,rt,Nt,it,ot,$e,nt,eo])),Zc=E({...Ze.shape,props:HP,...V(F(),"OIDC").shape});var aa=(r=>(r.HEADER="HEADER",r.BODY="BODY",r))(aa||{}),Wc=Z([Ce,Nt,$e]),Kc=B(p(),Wc),ZP=E({props:w(B(p(),Wc)),authUrl:p(),tokenUrl:p(),scope:U(p()),prompt:w(Z([D("none"),D("consent"),D("login"),D("omit")])),pkce:w(J()),pkceMethod:w(Z([D("plain"),D("S256")])),authorizationMethod:w(z(aa)),grantType:w(Z([z(Vr),D(Vi)])),extra:w(B(p(),p()))}),Jc=E({access_token:p(),props:w(Kc),data:B(p(),zr())}),sa=E({...Ze.shape,...ZP.shape,...V(Jc,"OAUTH2").shape});var Jt=Z([oa,ia,Zc,sa,Nt]),Kr="Connection",ua={SecretText(e){return{...e,valueSchema:void 0,type:"SECRET_TEXT"}},OAuth2(e){return{...e,valueSchema:void 0,type:"OAUTH2",displayName:e.displayName||Kr}},BasicAuth(e){return{...e,valueSchema:void 0,type:"BASIC_AUTH",displayName:e.displayName||Kr,required:!0}},CustomAuth(e){return{...e,valueSchema:void 0,type:"CUSTOM_AUTH",displayName:e.displayName||Kr}},OIDC(e){return{...e,valueSchema:void 0,type:"OIDC",displayName:e.displayName||Kr}},None(){}};var K1={OAUTH2:"OAUTH2",CLOUD_OAUTH2:"OAUTH2",PLATFORM_OAUTH2:"OAUTH2",BASIC_AUTH:"BASIC_AUTH",CUSTOM_AUTH:"CUSTOM_AUTH",OIDC:"OIDC",SECRET_TEXT:"SECRET_TEXT",NO_AUTH:void 0};var WP=E({...K.shape,...V(F(),"CUSTOM").shape,code:p()});var KP=Z([na,Jt]),ca=B(p(),KP),yU=B(p(),na);var Xc=Z([E({strategy:D("CRON"),cronExpression:p()}),E({strategy:D("NONE")})]),Xt=class{constructor(t,r,n,o,i,s,l,f,b,m,P,h,d,y,I,S,T,A,k,G,Y){this.name=t;this.displayName=r;this.description=n;this.requireAuth=o;this.props=i;this.type=s;this.handshakeConfiguration=l;this.onHandshake=f;this.renewConfiguration=b;this.onRenew=m;this.onEnable=P;this.onDisable=h;this.onStart=d;this.run=y;this.test=I;this.sampleData=S;this.testStrategy=T;this.outputSchema=A;this.aiMetadata=k;this.classification=G;this.propertyGroups=Y}static{a(this,"ITrigger")}},ee=a(e=>{switch(e.type){case"WEBHOOK":return new Xt(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,e.handshakeConfiguration??{strategy:"NONE"},e.onHandshake??(async()=>({status:200})),e.renewConfiguration??{strategy:"NONE"},e.onRenew??(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,e.test?"TEST_FUNCTION":"SIMULATION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"POLLING":return new Xt(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"MANUAL":return new Xt(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"APP_WEBHOOK":return new Xt(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,Ne(e.sampleData)&&Ne(e.test)?"SIMULATION":"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups)}},"createTrigger");var Yc="2",io="0.82.0";var la=class{constructor(t,r,n,o,i,s,l,f,b=io,m,P="",h){this.displayName=t;this.logoUrl=r;this.authors=n;this.events=o;this.categories=l;this.auth=f;this.minimumSupportedRelease=b;this.maximumSupportedRelease=m;this.description=P;this.deprecated=h;this._actions={};this._triggers={};this.getContextInfo=a(()=>({version:Yc}),"getContextInfo");(!XP(b)||YP(b,io))&&(this.minimumSupportedRelease=io),i.forEach(d=>this._actions[d.name]=d),s.forEach(d=>this._triggers[d.name]=d)}static{a(this,"Piece")}metadata(){return{displayName:this.displayName,logoUrl:this.logoUrl,actions:this._actions,triggers:this._triggers,categories:this.categories,description:this.description,authors:this.authors,auth:JP(this.auth),minimumSupportedRelease:this.minimumSupportedRelease,maximumSupportedRelease:this.maximumSupportedRelease,deprecated:this.deprecated,contextInfo:this.getContextInfo?.()}}getAction(t){return this._actions[t]}getTrigger(t){return this._triggers[t]}actions(){return this._actions}triggers(){return this._triggers}},el=a(e=>{if(e.auth&&Array.isArray(e.auth)&&!e.auth.every((r,n,o)=>n===o.findIndex(i=>i.type===r.type)))throw new Error("Auth properties must be unique by type");return new la(e.displayName,e.logoUrl,e.authors??[],e.events,e.actions,e.triggers,e.categories??[],e.auth,e.minimumSupportedRelease,e.maximumSupportedRelease,e.description,e.deprecated)},"createPiece");function JP(e){if(e!==void 0)return Array.isArray(e)?e.map(Qc):Qc(e)}a(JP,"withConnectionIdentifierFlag");function Qc(e){return{...e,hasConnectionIdentifier:e.getConnectionIdentifier!==void 0}}a(Qc,"flagConnectionIdentifier");function XP(e){return/^\d+\.\d+\.\d+$/.test(e)}a(XP,"isValidSimpleSemver");function YP(e,t){let[r,n,o]=e.split(".").map(Number),[i,s,l]=t.split(".").map(Number);return r!==i?r<i:n!==s?n<s:o<l}a(YP,"isSemverLessThan");var QP=w(B(p(),B(p(),p()))),tl=E({id:w(p()),name:p(),displayName:p(),logoUrl:p(),description:p(),authors:U(p()),platformId:w(p()),directoryPath:w(p()),auth:w(Z([Jt,U(Jt)])),version:p(),categories:w(U(z(Zt))),minimumSupportedRelease:w(p()),maximumSupportedRelease:w(p()),deprecated:w(J()),i18n:QP}),ex=z(["human","ai","both"]),rl=E({description:w(p()),idempotent:w(J())}),nl=z(["READ","SEARCH","WRITE","DESTRUCTIVE"]);var tx=z(["tabs","section","summary","builder","footer"]),ol=E({key:p(),display:tx,label:w(p()),description:w(p()),icon:w(p()),props:U(p())}),il=E({name:p(),displayName:p(),description:p(),props:ca,propertyGroups:w(U(ol)),requireAuth:J(),errorHandlingOptions:w(ji),outputSchema:w(Yn()),audience:w(ex),aiMetadata:w(rl),classification:w(nl)}),al=E({name:p(),displayName:p(),description:p(),props:ca,propertyGroups:w(U(ol)),errorHandlingOptions:w(ji),type:z(ye),sampleData:F(),handshakeConfiguration:w(Yn()),renewConfiguration:w(Xc),testStrategy:z(Zr),outputSchema:w(Yn()),aiMetadata:w(rl),classification:w(nl)}),rx=E({...tl.shape,actions:B(p(),il),triggers:B(p(),al)}),nx=E({...tl.shape,actions:be(),triggers:be(),suggestedActions:w(U(il)),suggestedTriggers:w(U(al))}),sl=E({projectUsage:be(),pieceType:z(Ht),packageType:z(Gr),platformId:w(p()),archiveId:w(p())}),vL=E({...rx.shape,...sl.shape}),_L=E({...nx.shape,...sl.shape}),bL=E({name:p(),version:p()});var ox=Le(require("path")),ix=Le(require("fs/promises"));var Yt=require("node:stream");var ao=class{constructor(t,r){this.baseUrl=t;this.authenticationConverter=r}static{a(this,"BaseHttpClient")}getUrl(t){let r=new URL(`${this.baseUrl}${t.url}`),n=`${r.origin}${r.pathname}`,o=new URLSearchParams;return r.searchParams.forEach((i,s)=>{o.append(s,i)}),{urlWithoutQueryParams:n,queryParams:o}}getHeaders(t){let r={Accept:"application/json"};return t.authentication&&this.populateAuthentication(t.authentication,r),t.body&&(t.headers?.["Content-Type"]==="text/csv"?r["Content-Type"]="text/csv":r["Content-Type"]="application/json"),t.headers&&(r={...r,...t.headers}),r}populateAuthentication(t,r){this.authenticationConverter.convert(t,r)}};var so=class{static{a(this,"DelegatingAuthenticationConverter")}constructor(t=new pa,r=new da){this.converters={BEARER_TOKEN:t,BASIC:r}}convert(t,r){return this.converters[t.type].convert(t,r)}},pa=class{static{a(this,"BearerTokenAuthenticationConverter")}convert(t,r){return r.Authorization=`Bearer ${t.token}`,r}},da=class{static{a(this,"BasicTokenAuthenticationConverter")}convert(t,r){let n=`${t.username}:${t.password}`,o=Buffer.from(n).toString("base64");return r.Authorization=`Basic ${o}`,r}};var Jr=class extends Error{constructor(r,n){let o=n.status||500,i=Buffer.isBuffer(n.responseBody)?n.responseBody.toString():n.responseBody;super(JSON.stringify({response:{status:o,body:i},request:{body:r}}));this.requestBody=r;this.status=o,this.responseBody=i}static{a(this,"HttpError")}errorMessage(){return{response:{status:this.status,body:this.responseBody},request:{body:this.requestBody}}}get response(){return{status:this.status,body:this.responseBody}}get request(){return{body:this.requestBody}}};function ul({error:e,requestBody:t}){return e instanceof Jr?e.errorMessage():{response:{status:0,body:e instanceof Error?e.message:String(e)},request:{body:t}}}a(ul,"toFailsafeOutput");var R=(s=>(s.GET="GET",s.POST="POST",s.PATCH="PATCH",s.PUT="PUT",s.DELETE="DELETE",s.HEAD="HEAD",s))(R||{});var uo=class extends ao{static{a(this,"FetchHttpClient")}constructor(t="",r=new so){super(t,r)}async sendRequest(t,r){process.env.NODE_TLS_REJECT_UNAUTHORIZED="0";let{urlWithoutQueryParams:n,queryParams:o}=this.getUrl(t),i=this.getHeaders(t),s=t.queryParams??{};for(let[k,G]of Object.entries(s))o.append(k,G);let l=o.toString(),f=l?`${n}?${l}`:n,b=t.responseType??"json",m=t.followRedirects??!0,P=t.retries??0,{body:h,extraHeaders:d,isStream:y}=ax(t.method)?sx(t.body,i):{body:void 0,extraHeaders:{},isStream:!1},I=cx({...i,...d}),S=await ux(async()=>{let k=new AbortController,G=t.timeout&&t.timeout>0?setTimeout(()=>k.abort(),t.timeout):void 0;try{let Y={method:t.method.toString(),headers:I,body:h,redirect:m?"follow":"manual",signal:k.signal};return y&&(Y.duplex="half"),r?.dispatcher!==void 0&&(Y.dispatcher=r.dispatcher),await fetch(f,Y)}finally{G!==void 0&&clearTimeout(G)}},y?0:P),T=m?300:400;if(S.status<200||S.status>=T){let k=await cl(S,b==="stream"?"text":b),G=new Jr(t.body,{status:S.status,responseBody:k});throw console.error("[HttpClient#(sanitized error message)] Request failed:",G),G}let A=await cl(S,b);return{status:S.status,headers:lx(S.headers),body:A}}};function ax(e){return e!=="GET"&&e!=="HEAD"}a(ax,"acceptsRequestBody");function sx(e,t){if(pl(e))return{body:void 0,extraHeaders:{},isStream:!1};if(px(e)){let n=new Yt.PassThrough;return e.on("error",o=>n.destroy(o)),e.pipe(n),{body:n,extraHeaders:e.getHeaders(),isStream:!0}}return e instanceof Yt.Readable?{body:e,extraHeaders:{},isStream:!0}:typeof e=="string"||Buffer.isBuffer(e)||e instanceof URLSearchParams||e instanceof ArrayBuffer||typeof FormData<"u"&&e instanceof FormData||typeof Blob<"u"&&e instanceof Blob?{body:e,extraHeaders:{},isStream:!1}:(t["Content-Type"]??t["content-type"]??"").includes("application/x-www-form-urlencoded")?{body:new URLSearchParams(e).toString(),extraHeaders:{},isStream:!1}:{body:JSON.stringify(e),extraHeaders:{},isStream:!1}}a(sx,"serializeBody");async function cl(e,t){switch(t){case"arraybuffer":return Buffer.from(await e.arrayBuffer());case"stream":return pl(e.body)?Yt.Readable.from([]):Yt.Readable.fromWeb(e.body);case"blob":return await e.blob();case"text":return await e.text();default:{let r=await e.text();if(r.length===0)return;try{return JSON.parse(r)}catch{return r}}}}a(cl,"parseResponseBody");async function ux(e,t){let r;for(let n=0;n<=t;n++)try{let o=await e();if(o.status>=500&&n<t){await ll(n);continue}return o}catch(o){if(r=o,n<t){await ll(n);continue}throw o}throw r}a(ux,"sendWithRetries");function ll(e){let t=Math.min(1e3*2**e,3e4);return new Promise(r=>setTimeout(r,t))}a(ll,"backoff");function cx(e){let t={};for(let[r,n]of Object.entries(e))n!==void 0&&(t[r.toLowerCase()]=Array.isArray(n)?n.join(", "):n);return t}a(cx,"normalizeHeaders");function lx(e){let t={};return e.forEach((r,n)=>{t[n]=r}),t}a(lx,"toHttpHeaders");function px(e){return typeof e=="object"&&e!==null&&typeof e.getHeaders=="function"&&typeof e.pipe=="function"&&typeof e.on=="function"}a(px,"isNodeFormData");function pl(e){return e==null}a(pl,"isNil");var v=new uo;var YS=Le(require("fs")),hd=Le(fd());var QS={"application/json":"json","application/pdf":"pdf","application/xml":"xml","text/xml":"xml","application/zip":"zip","application/gzip":"gz","application/x-tar":"tar","application/octet-stream":"bin","application/msword":"doc","application/vnd.openxmlformats-officedocument.wordprocessingml.document":"docx","application/vnd.ms-excel":"xls","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"xlsx","application/vnd.ms-powerpoint":"ppt","application/vnd.openxmlformats-officedocument.presentationml.presentation":"pptx","application/rtf":"rtf","application/javascript":"js","application/x-www-form-urlencoded":"bin","text/plain":"txt","text/html":"html","text/css":"css","text/csv":"csv","text/calendar":"ics","text/markdown":"md","image/png":"png","image/jpeg":"jpeg","image/jpg":"jpg","image/gif":"gif","image/webp":"webp","image/svg+xml":"svg","image/bmp":"bmp","image/tiff":"tiff","image/x-icon":"ico","image/vnd.microsoft.icon":"ico","image/heic":"heic","audio/mpeg":"mp3","audio/mp4":"m4a","audio/wav":"wav","audio/x-wav":"wav","audio/ogg":"ogg","audio/webm":"weba","video/mp4":"mp4","video/mpeg":"mpeg","video/webm":"webm","video/quicktime":"mov","video/x-msvideo":"avi","font/woff":"woff","font/woff2":"woff2","font/ttf":"ttf","font/otf":"otf"};function eT(e){let t=e.split(";")[0].trim().toLowerCase();return QS[t]??""}a(eT,"contentTypeToExtension");var tT=a(({baseUrl:e,relativePath:t})=>{let r=e.endsWith("/")?e:`${e}/`,n=t.startsWith("/")?t.slice(1):t;return`${r}${n}`},"joinBaseUrlWithRelativePath"),rT=a((e,t)=>{let r="https://api.example.com";try{let n=t?e(t):void 0;return(n?.endsWith("/")?n.slice(0,-1):n)??r}catch{return r}},"getBaseUrlForDescription");function yd({auth:e,baseUrl:t,authMapping:r,description:n,displayName:o,name:i,props:s,extraProps:l,authLocation:f="headers",classification:b="WRITE"}){return x({audience:"human",name:i||"custom_api_call",classification:b,displayName:o||"Custom API Call",description:n||"Make a custom API call to a specific endpoint",auth:e,requireAuth:!!e,props:{url:u.DynamicProperties({auth:e,displayName:"",required:!0,refreshers:[],props:a(async({auth:m})=>({url:u.ShortText({displayName:"URL",description:`You can either use the full URL or the relative path to the base URL
|
|
6
|
-
i.e ${rT(t,m)}/resource or /resource`,required:!0,defaultValue:m?t(m):"",...s?.url??{}})}),"props")}),method:u.StaticDropdown({displayName:"Method",required:!0,options:{options:Object.values(R).map(m=>({label:m,value:m}))},...s?.method??{}}),headers:u.Object({displayName:"Headers",description:"Authorization headers are injected automatically from your connection.",required:!0,...s?.headers??{}}),queryParams:u.Object({displayName:"Query Parameters",required:!0,...s?.queryParams??{}}),body_type:u.StaticDropdown({displayName:"Body Type",required:!1,defaultValue:"none",options:{disabled:!1,options:[{label:"None",value:"none"},{label:"JSON",value:"json"},{label:"Form Data",value:"form_data"},{label:"Raw",value:"raw"}]}}),body:u.DynamicProperties({auth:e,displayName:"Body",refreshers:["body_type"],required:!1,props:a(async({body_type:m})=>{if(!m)return{};let P=m,h={};switch(P){case"none":break;case"json":h.data=u.Json({displayName:"JSON Body",required:!0,...s?.body??{}});break;case"raw":h.data=u.LongText({displayName:"Raw Body",required:!0});break;case"form_data":h.data=u.Array({displayName:"Form Data",required:!0,properties:{fieldName:u.ShortText({displayName:"Field Name",required:!0}),fieldType:u.StaticDropdown({displayName:"Field Type",required:!0,options:{disabled:!1,options:[{label:"Text",value:"text"},{label:"File",value:"file"}]}}),textFieldValue:u.LongText({displayName:"Text Field Value",required:!1}),fileFieldValue:u.File({displayName:"File Field Value",required:!1})}});break}return h},"props")}),response_is_binary:u.Checkbox({displayName:"Response is Binary ?",description:"Enable for files like PDFs, images, etc.",required:!1,defaultValue:!1}),failsafe:u.Checkbox({displayName:"No Error on Failure",required:!1,...s?.failsafe??{}}),timeout:u.Number({displayName:"Timeout (in seconds)",required:!1,...s?.timeout??{}}),followRedirects:u.Checkbox({displayName:"Follow redirects",required:!1,defaultValue:!1}),...l},run:a(async m=>{let{method:P,url:h,headers:d,queryParams:y,body:I,body_type:S,failsafe:T,timeout:A,response_is_binary:k,followRedirects:G}=m.propsValue;ro(P,"Method"),ro(h,"URL");let Y=Ne(r)?{}:await r(m.auth,m.propsValue),Te=h.url,ve=Te.startsWith("http://")||Te.startsWith("https://")?Te:tT({baseUrl:t(m.auth),relativePath:Te}),ae={method:P,url:ve,headers:{...d??{},...f==="headers"||!Ne(f)?Y:{}},queryParams:{...f==="queryParams"?Y:{},...y??{}},timeout:A?A*1e3:0,followRedirects:G};if(k&&(ae.responseType="arraybuffer"),I)if(S&&S!=="none"){let te=I.data;if(S==="form_data"){let me=te,Me=new hd.default;for(let{fieldName:et,fieldType:we,textFieldValue:Ue,fileFieldValue:Oe}of me)we==="text"&&!H(Ue)?Me.append(et,Ue):we==="file"&&!H(Oe)&&Me.append(et,Oe.data,{filename:Oe?.filename});ae.body=Me,ae.headers={...ae.headers,...Me.getHeaders()}}else ae.body=te}else S||(ae.body=I);try{let te=await v.sendRequest(ae);return await nT(m.files,te.body,te.status,te.headers,k)}catch(te){if(T)return ul({error:te,requestBody:ae.body});throw te}},"run")})}a(yd,"createCustomApiCallAction");var nT=a(async(e,t,r,n,o)=>{let i;if(o&&oT(t)){let s=Array.isArray(n?.["content-type"])?n["content-type"][0]:n?.["content-type"],l=eT(s??"")||"txt",f;t instanceof ArrayBuffer?f=Buffer.from(new Uint8Array(t)):Buffer.isBuffer(t)?f=t:f=Buffer.from(t),i=await e.write({fileName:`output.${l}`,data:f})}else i=t;return{status:r,headers:n,body:i}},"handleBinaryResponse"),oT=a(e=>e instanceof ArrayBuffer||Buffer.isBuffer(e),"isBinaryBody");function ce(e,t){return{fields:[{key:"data",label:"Data",labelKey:t,listItems:e},{key:"has_more",label:"Has More",format:"boolean"},{key:"url",label:"URL"}]}}a(ce,"listSchema");function or(e,t){return{fields:[{key:"data",label:"Results",labelKey:t,listItems:e},{key:"has_more",label:"Has More",format:"boolean"},{key:"next_page",label:"Next Page"},{key:"url",label:"URL"}]}}a(or,"searchSchema");var vd=[{key:"line1",label:"Line 1"},{key:"line2",label:"Line 2"},{key:"city",label:"City"},{key:"state",label:"State"},{key:"postal_code",label:"Postal Code"},{key:"country",label:"Country"}],iT=[{key:"brand",label:"Brand"},{key:"last4",label:"Last 4"},{key:"exp_month",label:"Expiry Month",format:"number"},{key:"exp_year",label:"Expiry Year",format:"number"},{key:"funding",label:"Funding"},{key:"country",label:"Country"},{key:"display_brand",label:"Display Brand"}],_d=[{key:"name",label:"Name"},{key:"email",label:"Email",format:"email"},{key:"phone",label:"Phone"},{key:"address",label:"Address",children:vd}],Na=[{key:"id",label:"Customer ID"},{key:"email",label:"Email",format:"email"},{key:"name",label:"Name"},{key:"description",label:"Description"},{key:"phone",label:"Phone"},{key:"address",label:"Address",children:vd},{key:"balance",label:"Balance",format:"number"},{key:"currency",label:"Currency"},{key:"delinquent",label:"Delinquent",format:"boolean"},{key:"invoice_prefix",label:"Invoice Prefix"},{key:"tax_exempt",label:"Tax Exempt"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Da=[{key:"id",label:"Product ID"},{key:"name",label:"Name"},{key:"description",label:"Description"},{key:"active",label:"Active",format:"boolean"},{key:"default_price",label:"Default Price"},{key:"images",label:"Images"},{key:"url",label:"URL",format:"url"},{key:"unit_label",label:"Unit Label"},{key:"type",label:"Type"},{key:"created",label:"Created",format:"datetime"},{key:"updated",label:"Updated",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],vo=[{key:"id",label:"Price ID"},{key:"active",label:"Active",format:"boolean"},{key:"currency",label:"Currency"},{key:"product",label:"Product"},{key:"nickname",label:"Nickname"},{key:"unit_amount",label:"Unit Amount",format:"number"},{key:"unit_amount_decimal",label:"Unit Amount Decimal"},{key:"type",label:"Type"},{key:"billing_scheme",label:"Billing Scheme"},{key:"tax_behavior",label:"Tax Behavior"},{key:"lookup_key",label:"Lookup Key"},{key:"recurring",label:"Recurring",children:[{key:"interval",label:"Interval"},{key:"interval_count",label:"Interval Count",format:"number"},{key:"trial_period_days",label:"Trial Period Days",format:"number"},{key:"usage_type",label:"Usage Type"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],za=[{key:"id",label:"Coupon ID"},{key:"name",label:"Name"},{key:"amount_off",label:"Amount Off",format:"number"},{key:"percent_off",label:"Percent Off",format:"number"},{key:"currency",label:"Currency"},{key:"duration",label:"Duration"},{key:"duration_in_months",label:"Duration In Months",format:"number"},{key:"max_redemptions",label:"Max Redemptions",format:"number"},{key:"times_redeemed",label:"Times Redeemed",format:"number"},{key:"redeem_by",label:"Redeem By",format:"datetime"},{key:"valid",label:"Valid",format:"boolean"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],bd=[{key:"id",label:"Promotion Code ID"},{key:"code",label:"Code"},{key:"active",label:"Active",format:"boolean"},{key:"customer",label:"Customer"},{key:"coupon",label:"Coupon",children:za},{key:"expires_at",label:"Expires At",format:"datetime"},{key:"max_redemptions",label:"Max Redemptions",format:"number"},{key:"times_redeemed",label:"Times Redeemed",format:"number"},{key:"restrictions",label:"Restrictions",children:[{key:"first_time_transaction",label:"First Time Transaction",format:"boolean"},{key:"minimum_amount",label:"Minimum Amount",format:"number"},{key:"minimum_amount_currency",label:"Minimum Amount Currency"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Pd=[{key:"id",label:"Tax Rate ID"},{key:"display_name",label:"Display Name"},{key:"description",label:"Description"},{key:"active",label:"Active",format:"boolean"},{key:"percentage",label:"Percentage",format:"number"},{key:"effective_percentage",label:"Effective Percentage",format:"number"},{key:"inclusive",label:"Inclusive",format:"boolean"},{key:"country",label:"Country"},{key:"state",label:"State"},{key:"jurisdiction",label:"Jurisdiction"},{key:"tax_type",label:"Tax Type"},{key:"rate_type",label:"Rate Type"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],xd=[{key:"id",label:"Payment Method ID"},{key:"type",label:"Type"},{key:"customer",label:"Customer"},{key:"billing_details",label:"Billing Details",children:_d},{key:"card",label:"Card",children:iT},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ma=[{key:"id",label:"Payment Intent ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_received",label:"Amount Received",format:"number"},{key:"amount_capturable",label:"Amount Capturable",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"customer",label:"Customer"},{key:"description",label:"Description"},{key:"payment_method",label:"Payment Method"},{key:"latest_charge",label:"Latest Charge"},{key:"capture_method",label:"Capture Method"},{key:"confirmation_method",label:"Confirmation Method"},{key:"client_secret",label:"Client Secret"},{key:"receipt_email",label:"Receipt Email",format:"email"},{key:"setup_future_usage",label:"Setup Future Usage"},{key:"cancellation_reason",label:"Cancellation Reason"},{key:"canceled_at",label:"Canceled At",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ua=[{key:"id",label:"Charge ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_captured",label:"Amount Captured",format:"number"},{key:"amount_refunded",label:"Amount Refunded",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"paid",label:"Paid",format:"boolean"},{key:"captured",label:"Captured",format:"boolean"},{key:"refunded",label:"Refunded",format:"boolean"},{key:"disputed",label:"Disputed",format:"boolean"},{key:"customer",label:"Customer"},{key:"description",label:"Description"},{key:"payment_intent",label:"Payment Intent"},{key:"payment_method",label:"Payment Method"},{key:"balance_transaction",label:"Balance Transaction"},{key:"receipt_url",label:"Receipt URL",format:"url"},{key:"receipt_email",label:"Receipt Email",format:"email"},{key:"receipt_number",label:"Receipt Number"},{key:"calculated_statement_descriptor",label:"Statement Descriptor"},{key:"billing_details",label:"Billing Details",children:_d},{key:"payment_method_details",label:"Payment Method Details",children:[{key:"type",label:"Type"},{key:"card",label:"Card",children:[{key:"brand",label:"Brand"},{key:"last4",label:"Last 4"},{key:"exp_month",label:"Expiry Month",format:"number"},{key:"exp_year",label:"Expiry Year",format:"number"},{key:"funding",label:"Funding"},{key:"country",label:"Country"},{key:"network",label:"Network"}]}]},{key:"outcome",label:"Outcome",children:[{key:"network_status",label:"Network Status"},{key:"risk_level",label:"Risk Level"},{key:"risk_score",label:"Risk Score",format:"number"},{key:"seller_message",label:"Seller Message"},{key:"type",label:"Type"}]},{key:"failure_code",label:"Failure Code"},{key:"failure_message",label:"Failure Message"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],aT=[{key:"id",label:"Balance Transaction ID"},{key:"amount",label:"Amount",format:"number"},{key:"net",label:"Net",format:"number"},{key:"fee",label:"Fee",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"description",label:"Description"},{key:"reporting_category",label:"Reporting Category"},{key:"source",label:"Source"},{key:"available_on",label:"Available On",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"fee_details",label:"Fee Details",labelKey:"description",listItems:[{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"type",label:"Type"},{key:"description",label:"Description"}]}],Sd=[{key:"id",label:"Refund ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"charge",label:"Charge"},{key:"payment_intent",label:"Payment Intent"},{key:"payment_method",label:"Payment Method"},{key:"balance_transaction",label:"Balance Transaction"},{key:"reason",label:"Reason"},{key:"receipt_number",label:"Receipt Number"},{key:"created",label:"Created",format:"datetime"},{key:"metadata",label:"Metadata",dynamicKey:!0}],sT=[{key:"id",label:"Invoice Item ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"invoice",label:"Invoice"},{key:"description",label:"Description"},{key:"quantity",label:"Quantity",format:"number"},{key:"date",label:"Date",format:"datetime"},{key:"discountable",label:"Discountable",format:"boolean"},{key:"proration",label:"Proration",format:"boolean"},{key:"period",label:"Period",children:[{key:"start",label:"Start",format:"datetime"},{key:"end",label:"End",format:"datetime"}]},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Td=[{key:"id",label:"Credit Note ID"},{key:"number",label:"Number"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"reason",label:"Reason"},{key:"customer",label:"Customer"},{key:"invoice",label:"Invoice"},{key:"memo",label:"Memo"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"subtotal_excluding_tax",label:"Subtotal Excluding Tax",format:"number"},{key:"total",label:"Total",format:"number"},{key:"total_excluding_tax",label:"Total Excluding Tax",format:"number"},{key:"discount_amount",label:"Discount Amount",format:"number"},{key:"pre_payment_amount",label:"Pre-Payment Amount",format:"number"},{key:"post_payment_amount",label:"Post-Payment Amount",format:"number"},{key:"pdf",label:"PDF",format:"url"},{key:"created",label:"Created",format:"datetime"},{key:"effective_at",label:"Effective At",format:"datetime"},{key:"voided_at",label:"Voided At",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ed=[{key:"id",label:"Checkout Session ID"},{key:"status",label:"Status"},{key:"payment_status",label:"Payment Status"},{key:"mode",label:"Mode"},{key:"url",label:"URL",format:"url"},{key:"success_url",label:"Success URL",format:"url"},{key:"cancel_url",label:"Cancel URL",format:"url"},{key:"amount_subtotal",label:"Amount Subtotal",format:"number"},{key:"amount_total",label:"Amount Total",format:"number"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"customer_email",label:"Customer Email",format:"email"},{key:"payment_intent",label:"Payment Intent"},{key:"subscription",label:"Subscription"},{key:"invoice",label:"Invoice"},{key:"payment_link",label:"Payment Link"},{key:"client_reference_id",label:"Client Reference ID"},{key:"total_details",label:"Total Details",children:[{key:"amount_discount",label:"Amount Discount",format:"number"},{key:"amount_shipping",label:"Amount Shipping",format:"number"},{key:"amount_tax",label:"Amount Tax",format:"number"}]},{key:"expires_at",label:"Expires At",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Id=[{key:"id",label:"Payment Link ID"},{key:"active",label:"Active",format:"boolean"},{key:"url",label:"URL",format:"url"},{key:"currency",label:"Currency"},{key:"allow_promotion_codes",label:"Allow Promotion Codes",format:"boolean"},{key:"billing_address_collection",label:"Billing Address Collection"},{key:"customer_creation",label:"Customer Creation"},{key:"payment_method_collection",label:"Payment Method Collection"},{key:"submit_type",label:"Submit Type"},{key:"application_fee_amount",label:"Application Fee Amount",format:"number"},{key:"application_fee_percent",label:"Application Fee Percent",format:"number"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ad=[{key:"id",label:"Dispute ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"reason",label:"Reason"},{key:"charge",label:"Charge"},{key:"payment_intent",label:"Payment Intent"},{key:"balance_transaction",label:"Balance Transaction"},{key:"is_charge_refundable",label:"Is Charge Refundable",format:"boolean"},{key:"evidence_details",label:"Evidence Details",children:[{key:"due_by",label:"Due By",format:"datetime"},{key:"has_evidence",label:"Has Evidence",format:"boolean"},{key:"past_due",label:"Past Due",format:"boolean"},{key:"submission_count",label:"Submission Count",format:"number"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],wd=[{key:"id",label:"Payout ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"method",label:"Method"},{key:"automatic",label:"Automatic",format:"boolean"},{key:"arrival_date",label:"Arrival Date",format:"datetime"},{key:"balance_transaction",label:"Balance Transaction"},{key:"destination",label:"Destination"},{key:"description",label:"Description"},{key:"statement_descriptor",label:"Statement Descriptor"},{key:"source_type",label:"Source Type"},{key:"failure_code",label:"Failure Code"},{key:"failure_message",label:"Failure Message"},{key:"reconciliation_status",label:"Reconciliation Status"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],uT=[{key:"id",label:"Transfer ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_reversed",label:"Amount Reversed",format:"number"},{key:"currency",label:"Currency"},{key:"description",label:"Description"},{key:"destination",label:"Destination"},{key:"source_transaction",label:"Source Transaction"},{key:"transfer_group",label:"Transfer Group"},{key:"reversed",label:"Reversed",format:"boolean"},{key:"balance_transaction",label:"Balance Transaction"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],kd=[{key:"id",label:"Event ID"},{key:"type",label:"Type"},{key:"api_version",label:"API Version"},{key:"created",label:"Created",format:"datetime"},{key:"pending_webhooks",label:"Pending Webhooks",format:"number"},{key:"request",label:"Request",children:[{key:"id",label:"Request ID"},{key:"idempotency_key",label:"Idempotency Key"}]},{key:"data",label:"Data",children:[{key:"object",label:"Object"}]},{key:"livemode",label:"Live Mode",format:"boolean"}],Rd=[{key:"id",label:"Subscription Item ID"},{key:"quantity",label:"Quantity",format:"number"},{key:"subscription",label:"Subscription"},{key:"current_period_start",label:"Current Period Start",format:"datetime"},{key:"current_period_end",label:"Current Period End",format:"datetime"},{key:"price",label:"Price",children:vo},{key:"created",label:"Created",format:"datetime"},{key:"metadata",label:"Metadata",dynamicKey:!0}],La=[{key:"id",label:"Subscription ID"},{key:"status",label:"Status"},{key:"customer",label:"Customer"},{key:"currency",label:"Currency"},{key:"description",label:"Description"},{key:"collection_method",label:"Collection Method"},{key:"latest_invoice",label:"Latest Invoice"},{key:"default_payment_method",label:"Default Payment Method"},{key:"quantity",label:"Quantity",format:"number"},{key:"start_date",label:"Start Date",format:"datetime"},{key:"billing_cycle_anchor",label:"Billing Cycle Anchor",format:"datetime"},{key:"cancel_at",label:"Cancel At",format:"datetime"},{key:"canceled_at",label:"Canceled At",format:"datetime"},{key:"cancel_at_period_end",label:"Cancel At Period End",format:"boolean"},{key:"ended_at",label:"Ended At",format:"datetime"},{key:"trial_start",label:"Trial Start",format:"datetime"},{key:"trial_end",label:"Trial End",format:"datetime"},{key:"items",label:"Items",children:[{key:"data",label:"Data",labelKey:"id",listItems:Rd}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Od=[{key:"id",label:"Line ID"},{key:"description",label:"Description"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"quantity",label:"Quantity",format:"number"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"invoice",label:"Invoice"},{key:"period",label:"Period",children:[{key:"start",label:"Start",format:"datetime"},{key:"end",label:"End",format:"datetime"}]},{key:"discountable",label:"Discountable",format:"boolean"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],qa=[{key:"id",label:"Invoice ID"},{key:"number",label:"Number"},{key:"status",label:"Status"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"customer_email",label:"Customer Email",format:"email"},{key:"customer_name",label:"Customer Name"},{key:"customer_phone",label:"Customer Phone"},{key:"description",label:"Description"},{key:"collection_method",label:"Collection Method"},{key:"billing_reason",label:"Billing Reason"},{key:"amount_due",label:"Amount Due",format:"number"},{key:"amount_paid",label:"Amount Paid",format:"number"},{key:"amount_remaining",label:"Amount Remaining",format:"number"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"total",label:"Total",format:"number"},{key:"attempt_count",label:"Attempt Count",format:"number"},{key:"attempted",label:"Attempted",format:"boolean"},{key:"auto_advance",label:"Auto Advance",format:"boolean"},{key:"due_date",label:"Due Date",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"period_start",label:"Period Start",format:"datetime"},{key:"period_end",label:"Period End",format:"datetime"},{key:"effective_at",label:"Effective At",format:"datetime"},{key:"hosted_invoice_url",label:"Hosted Invoice URL",format:"url"},{key:"invoice_pdf",label:"Invoice PDF",format:"url"},{key:"receipt_number",label:"Receipt Number"},{key:"starting_balance",label:"Starting Balance",format:"number"},{key:"ending_balance",label:"Ending Balance",format:"number"},{key:"status_transitions",label:"Status Transitions",children:[{key:"finalized_at",label:"Finalized At",format:"datetime"},{key:"paid_at",label:"Paid At",format:"datetime"},{key:"marked_uncollectible_at",label:"Marked Uncollectible At",format:"datetime"},{key:"voided_at",label:"Voided At",format:"datetime"}]},{key:"lines",label:"Lines",children:[{key:"data",label:"Data",labelKey:"description",listItems:Od}]},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],gd=[{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"}],Re={fields:Na},bt={fields:Da},Pt={fields:vo},_o={fields:za},bo={fields:bd},Po={fields:Pd},ir={fields:xd},Ie={fields:Ma},ar={fields:Ua},xt={fields:Sd},Cd={fields:sT},ge={fields:qa},xe={fields:La},sr={fields:Td},ze={fields:Id},ur={fields:Ed},St={fields:Ad},xo={fields:wd},$d={fields:kd},Nd={fields:[{key:"available",label:"Available",labelKey:"currency",listItems:gd},{key:"pending",label:"Pending",labelKey:"currency",listItems:gd},{key:"livemode",label:"Live Mode",format:"boolean"}]},Dd=ce(Na,"email"),zd=ce(Da,"name"),Md=ce(vo,"id"),Ud=ce(za,"name"),Ld=ce(bd,"code"),qd=ce(Pd,"display_name"),jd=ce(xd,"id"),Fd=ce(Ma,"id"),Bd=ce(Ua,"id"),Gd=ce(Sd,"id"),Vd=ce(qa,"number"),Hd=ce(Od,"description"),Zd=ce(La,"id"),Wd=ce(Rd,"id"),Kd=ce(Td,"number"),Jd=ce(Id,"id"),Xd=ce(Ed,"id"),Yd=ce(Ad,"id"),Qd=ce(wd,"id"),em=ce(uT,"id"),tm=ce(kd,"type"),rm=ce(aT,"id"),nm=or(Ua,"id"),So=or(Na,"email"),om=or(qa,"number"),im=or(Ma,"id"),am=or(vo,"id"),sm=or(Da,"name"),To={fields:[{key:"success",label:"Success",format:"boolean"},{key:"count",label:"Count",format:"number"},{key:"total_fetched",label:"Total Fetched",format:"number"},{key:"requests_made",label:"Requests Made",format:"number"},{key:"has_more_available",label:"Has More Available",format:"boolean"},{key:"subscriptions",label:"Subscriptions",labelKey:"id",listItems:La}]};var um=x({name:"create_customer",classification:"WRITE",auth:g,displayName:"Create Customer",description:"Create a customer in stripe",audience:"human",aiMetadata:{description:"Creates a new customer record in Stripe from an email and name, with optional contact and address fields. Use when onboarding a new payer before charging, invoicing, or subscribing them. Not idempotent: each call creates a distinct customer even with identical input.",idempotent:!1},props:{email:u.ShortText({displayName:"Email",description:void 0,required:!0}),name:u.ShortText({displayName:"Name",required:!0}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Re,async run(e){let t={email:e.propsValue.email,name:e.propsValue.name,description:e.propsValue.description,phone:e.propsValue.phone,address:{line1:e.propsValue.line1,postal_code:e.propsValue.postal_code,city:e.propsValue.city,state:e.propsValue.state,country:e.propsValue.country}};return(await v.sendRequest({method:"POST",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:{email:t.email,name:t.name,description:t.description,phone:t.phone,address:t.address}})).body}});var cm=x({name:"create_invoice",classification:"WRITE",auth:g,displayName:"Create Invoice",description:"Create an Invoice in stripe",audience:"human",aiMetadata:{description:"Creates a draft invoice in Stripe for an existing customer in the given currency. Use to bill a customer for pending invoice items. Requires a valid Stripe customer ID; not idempotent, as each call creates a separate invoice.",idempotent:!1},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"Stripe Customer ID",required:!0}),currency:u.ShortText({displayName:"Currency",description:"Currency for the invoice (e.g., USD)",required:!0}),description:u.LongText({displayName:"Description",description:"Description for the invoice",required:!1})},outputSchema:ge,async run(e){let t={customer:e.propsValue.customer_id,currency:e.propsValue.currency,description:e.propsValue.description};return(await v.sendRequest({method:"POST",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:{customer:t.customer,currency:t.currency,description:t.description}})).body}});var lm=x({name:"retrieve_customer",classification:"READ",auth:g,displayName:"Retrieve Customer",description:"Retrieve a customer in stripe by id",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe customer by its customer ID (e.g., cus_...). Use when you already have the exact ID and need the current record; for lookup by email use Search Customer instead. Read-only and idempotent.",idempotent:!0},props:{id:u.ShortText({displayName:"ID",description:void 0,required:!0})},outputSchema:Re,async run(e){let t={id:e.propsValue.id};return(await v.sendRequest({method:"GET",url:`https://api.stripe.com/v1/customers/${t.id}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var vr=Le(require("crypto"),1),ys=require("events");var Io=Le(require("crypto"),1);var Tt=class{static{a(this,"CryptoProvider")}computeHMACSignature(t,r){throw new Error("computeHMACSignature not implemented.")}computeHMACSignatureAsync(t,r){throw new Error("computeHMACSignatureAsync not implemented.")}computeSHA256Async(t){throw new Error("computeSHA256 not implemented.")}},cr=class extends Error{static{a(this,"CryptoProviderOnlySupportsAsyncError")}};var Eo=class extends Tt{static{a(this,"NodeCryptoProvider")}computeHMACSignature(t,r){return Io.createHmac("sha256",r).update(t,"utf8").digest("hex")}async computeHMACSignatureAsync(t,r){return await this.computeHMACSignature(t,r)}async computeSHA256Async(t){return new Uint8Array(await Io.createHash("sha256").update(t).digest())}};var Fa=Le(require("http"),1),Ba=Le(require("https"),1);var Ee=class e{static{a(this,"HttpClient")}getClientName(){throw new Error("getClientName not implemented.")}makeRequest(t,r,n,o,i,s,l,f){throw new Error("makeRequest not implemented.")}static makeTimeoutError(){let t=new TypeError(e.TIMEOUT_ERROR_CODE);return t.code=e.TIMEOUT_ERROR_CODE,t}};Ee.CONNECTION_CLOSED_ERROR_CODES=["ECONNRESET","EPIPE"];Ee.TIMEOUT_ERROR_CODE="ETIMEDOUT";var Et=class{static{a(this,"HttpClientResponse")}constructor(t,r){this._statusCode=t,this._headers=r}getStatusCode(){return this._statusCode}getHeaders(){return this._headers}getRawResponse(){throw new Error("getRawResponse not implemented.")}toStream(t){throw new Error("toStream not implemented.")}toJSON(){throw new Error("toJSON not implemented.")}};var pm=Fa.default||Fa,dm=Ba.default||Ba,cT=new pm.Agent({keepAlive:!0}),lT=new dm.Agent({keepAlive:!0}),tn=class extends Ee{static{a(this,"NodeHttpClient")}constructor(t){super(),this._agent=t}getClientName(){return"node"}makeRequest(t,r,n,o,i,s,l,f){let b=l==="http",m=this._agent;return m||(m=b?cT:lT),new Promise((h,d)=>{let y=(b?pm:dm).request({host:t,port:r,path:n,method:o,agent:m,headers:i,ciphers:"DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:!MD5"});y.setTimeout(f,()=>{y.destroy(Ee.makeTimeoutError())}),y.on("response",I=>{h(new ja(I))}),y.on("error",I=>{d(I)}),y.once("socket",I=>{I.connecting?I.once(b?"connect":"secureConnect",()=>{y.write(s),y.end()}):(y.write(s),y.end())})})}},ja=class extends Et{static{a(this,"NodeHttpClientResponse")}constructor(t){super(t.statusCode,t.headers||{}),this._res=t}getRawResponse(){return this._res}toStream(t){return this._res.once("end",()=>t()),this._res}toJSON(){return new Promise((t,r)=>{let n="";this._res.setEncoding("utf8"),this._res.on("data",o=>{n+=o}),this._res.once("end",()=>{try{t(JSON.parse(n))}catch(o){r(o)}})})}};var of=Le(nf(),1);var ds=["apiKey","idempotencyKey","stripeAccount","apiVersion","maxNetworkRetries","timeout","host","authenticator","stripeContext","additionalHeaders","streaming"];function af(e){return e&&typeof e=="object"&&ds.some(t=>Object.prototype.hasOwnProperty.call(e,t))}a(af,"isOptionsHash");function wt(e,t){return of.stringify(e,{serializeDate:a(r=>Math.floor(r.getTime()/1e3).toString(),"serializeDate"),arrayFormat:t=="v2"?"repeat":"indices"}).replace(/%5B/g,"[").replace(/%5D/g,"]")}a(wt,"queryStringifyRequestData");var Uo=(()=>{let e={"\n":"\\n",'"':'\\"',"\u2028":"\\u2028","\u2029":"\\u2029"};return t=>{let r=t.replace(/["\n\r\u2028\u2029]/g,n=>e[n]);return n=>r.replace(/\{([\s\S]+?)\}/g,(o,i)=>{let s=n[i];return GE(s)?encodeURIComponent(s):""})}})();function GE(e){return["number","string","boolean"].includes(typeof e)}a(GE,"isValidEncodeUriComponentType");function sf(e){let t=e.match(/\{\w+\}/g);return t?t.map(r=>r.replace(/[{}]/g,"")):[]}a(sf,"extractUrlParams");function mr(e){if(!Array.isArray(e)||!e[0]||typeof e[0]!="object")return{};if(!af(e[0]))return e.shift();let t=Object.keys(e[0]),r=t.filter(n=>ds.includes(n));return r.length>0&&r.length!==t.length&&mn(`Options found in arguments (${r.join(", ")}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options.`),{}}a(mr,"getDataFromArgs");function Lo(e){let t={host:null,headers:{},settings:{},streaming:!1};if(e.length>0){let r=e[e.length-1];if(typeof r=="string")t.authenticator=Mo(e.pop());else if(af(r)){let n=Object.assign({},e.pop()),o=Object.keys(n).filter(i=>!ds.includes(i));if(o.length&&mn(`Invalid options found (${o.join(", ")}); ignoring.`),n.apiKey&&(t.authenticator=Mo(n.apiKey)),n.idempotencyKey&&(t.headers["Idempotency-Key"]=n.idempotencyKey),n.stripeAccount&&(t.headers["Stripe-Account"]=n.stripeAccount),n.stripeContext){if(t.headers["Stripe-Account"])throw new Error("Can't specify both stripeAccount and stripeContext.");t.headers["Stripe-Context"]=n.stripeContext}if(n.apiVersion&&(t.headers["Stripe-Version"]=n.apiVersion),Number.isInteger(n.maxNetworkRetries)&&(t.settings.maxNetworkRetries=n.maxNetworkRetries),Number.isInteger(n.timeout)&&(t.settings.timeout=n.timeout),n.host&&(t.host=n.host),n.authenticator){if(n.apiKey)throw new Error("Can't specify both apiKey and authenticator.");if(typeof n.authenticator!="function")throw new Error("The authenticator must be a function receiving a request as the first parameter.");t.authenticator=n.authenticator}n.additionalHeaders&&(t.headers=n.additionalHeaders),n.streaming&&(t.streaming=!0)}}return t}a(Lo,"getOptionsFromArgs");function uf(e){let t=this,r=Object.prototype.hasOwnProperty.call(e,"constructor")?e.constructor:function(...n){t.apply(this,n)};return Object.assign(r,t),r.prototype=Object.create(t.prototype),Object.assign(r.prototype,e),r}a(uf,"protoExtend");function qo(e){if(typeof e!="object")throw new Error("Argument must be an object");return Object.keys(e).reduce((t,r)=>(e[r]!=null&&(t[r]=e[r]),t),{})}a(qo,"removeNullish");function cf(e){return e&&typeof e=="object"?Object.keys(e).reduce((t,r)=>(t[VE(r)]=e[r],t),{}):e}a(cf,"normalizeHeaders");function VE(e){return e.split("-").map(t=>t.charAt(0).toUpperCase()+t.substr(1).toLowerCase()).join("-")}a(VE,"normalizeHeader");function dn(e,t){return t?e.then(r=>{setTimeout(()=>{t(null,r)},0)},r=>{setTimeout(()=>{t(r,null)},0)}):e}a(dn,"callbackifyPromiseWithTimeout");function lf(e){return e==="OAuth"?"oauth":e[0].toLowerCase()+e.substring(1)}a(lf,"pascalToCamelCase");function mn(e){return typeof process.emitWarning!="function"?console.warn(`Stripe: ${e}`):process.emitWarning(e,"Stripe")}a(mn,"emitWarning");function HE(e){let t=typeof e;return(t==="function"||t==="object")&&!!e}a(HE,"isObject");function pf(e){let t={},r=a((n,o)=>{Object.entries(n).forEach(([i,s])=>{let l=o?`${o}[${i}]`:i;if(HE(s)){if(!(s instanceof Uint8Array)&&!Object.prototype.hasOwnProperty.call(s,"data"))return r(s,l);t[l]=s}else t[l]=String(s)})},"step");return r(e,null),t}a(pf,"flattenAndStringify");function jo(e,t,r){if(!Number.isInteger(t)){if(r!==void 0)return r;throw new Error(`${e} must be an integer`)}return t}a(jo,"validateInteger");function df(){return typeof process>"u"?{}:{lang_version:process.version,platform:process.platform}}a(df,"determineProcessUserAgentProperties");function Mo(e){let t=a(r=>(r.headers.Authorization="Bearer "+e,Promise.resolve()),"authenticator");return t._apiKey=e,t}a(Mo,"createApiKeyAuthenticator");function mf(e){let t=e.reduce((o,i)=>o+i.length,0),r=new Uint8Array(t),n=0;return e.forEach(o=>{r.set(o,n),n+=o.length}),r}a(mf,"concat");function ZE(e,t){return this[e]instanceof Date?Math.floor(this[e].getTime()/1e3).toString():t}a(ZE,"dateTimeReplacer");function ff(e){return JSON.stringify(e,ZE)}a(ff,"jsonStringifyRequestData");function fr(e){return e&&e.startsWith("/v2")?"v2":"v1"}a(fr,"getAPIMode");function Fo(e){return Array.isArray(e)?e.join(", "):String(e)}a(Fo,"parseHttpHeaderAsString");function hf(e){let t=Array.isArray(e)?e[0]:e;return Number(t)}a(hf,"parseHttpHeaderAsNumber");function yf(e){return Object.entries(e).map(([t,r])=>[t,Fo(r)])}a(yf,"parseHeadersForFetch");var Bo=class e extends Ee{static{a(this,"FetchHttpClient")}constructor(t){if(super(),!t){if(!globalThis.fetch)throw new Error("fetch() function not provided and is not defined in the global scope. You must provide a fetch implementation.");t=globalThis.fetch}globalThis.AbortController?this._fetchFn=e.makeFetchWithAbortTimeout(t):this._fetchFn=e.makeFetchWithRaceTimeout(t)}static makeFetchWithRaceTimeout(t){return(r,n,o)=>{let i,s=new Promise((f,b)=>{i=setTimeout(()=>{i=null,b(Ee.makeTimeoutError())},o)}),l=t(r,n);return Promise.race([l,s]).finally(()=>{i&&clearTimeout(i)})}}static makeFetchWithAbortTimeout(t){return async(r,n,o)=>{let i=new AbortController,s=setTimeout(()=>{s=null,i.abort(Ee.makeTimeoutError())},o);try{return await t(r,Object.assign(Object.assign({},n),{signal:i.signal}))}catch(l){throw l.name==="AbortError"?Ee.makeTimeoutError():l}finally{s&&clearTimeout(s)}}}getClientName(){return"fetch"}async makeRequest(t,r,n,o,i,s,l,f){let b=l==="http",m=new URL(n,`${b?"http":"https"}://${t}`);m.port=r;let P=o=="POST"||o=="PUT"||o=="PATCH",h=s||(P?"":void 0),d=await this._fetchFn(m.toString(),{method:o,headers:yf(i),body:typeof h=="object"?JSON.stringify(h):h},f);return new ms(d)}},ms=class e extends Et{static{a(this,"FetchHttpClientResponse")}constructor(t){super(t.status,e._transformHeadersToObject(t.headers)),this._res=t}getRawResponse(){return this._res}toStream(t){return t(),this._res.body}toJSON(){return this._res.json()}static _transformHeadersToObject(t){let r={};for(let n of t){if(!Array.isArray(n)||n.length!=2)throw new Error("Response objects produced by the fetch function given to FetchHttpClient do not have an iterable headers map. Response#headers should be an iterable object.");r[n[0]]=n[1]}return r}};var Go=class extends Tt{static{a(this,"SubtleCryptoProvider")}constructor(t){super(),this.subtleCrypto=t||crypto.subtle}computeHMACSignature(t,r){throw new cr("SubtleCryptoProvider cannot be used in a synchronous context.")}async computeHMACSignatureAsync(t,r){let n=new TextEncoder,o=await this.subtleCrypto.importKey("raw",n.encode(r),{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),i=await this.subtleCrypto.sign("hmac",o,n.encode(t)),s=new Uint8Array(i),l=new Array(s.length);for(let f=0;f<s.length;f++)l[f]=fs[s[f]];return l.join("")}async computeSHA256Async(t){return new Uint8Array(await this.subtleCrypto.digest("SHA-256",t))}},fs=new Array(256);for(let e=0;e<fs.length;e++)fs[e]=e.toString(16).padStart(2,"0");var Vo=class{static{a(this,"PlatformFunctions")}constructor(){this._fetchFn=null,this._agent=null}getUname(){throw new Error("getUname not implemented.")}uuid4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let r=Math.random()*16|0;return(t==="x"?r:r&3|8).toString(16)})}secureCompare(t,r){if(t.length!==r.length)return!1;let n=t.length,o=0;for(let i=0;i<n;++i)o|=t.charCodeAt(i)^r.charCodeAt(i);return o===0}createEmitter(){throw new Error("createEmitter not implemented.")}tryBufferData(t){throw new Error("tryBufferData not implemented.")}createNodeHttpClient(t){throw new Error("createNodeHttpClient not implemented.")}createFetchHttpClient(t){return new Bo(t)}createDefaultHttpClient(){throw new Error("createDefaultHttpClient not implemented.")}createNodeCryptoProvider(){throw new Error("createNodeCryptoProvider not implemented.")}createSubtleCryptoProvider(t){return new Go(t)}createDefaultCryptoProvider(){throw new Error("createDefaultCryptoProvider not implemented.")}};var Xo={};Mn(Xo,{StripeAPIError:()=>hr,StripeAuthenticationError:()=>yr,StripeCardError:()=>Ho,StripeConnectionError:()=>yn,StripeError:()=>pe,StripeIdempotencyError:()=>Zo,StripeInvalidGrantError:()=>Wo,StripeInvalidRequestError:()=>fn,StripePermissionError:()=>hn,StripeRateLimitError:()=>gr,StripeSignatureVerificationError:()=>Fe,StripeUnknownError:()=>Ko,TemporarySessionExpiredError:()=>Jo,generateV1Error:()=>gn,generateV2Error:()=>hs});var gn=a(e=>{switch(e.type){case"card_error":return new Ho(e);case"invalid_request_error":return new fn(e);case"api_error":return new hr(e);case"authentication_error":return new yr(e);case"rate_limit_error":return new gr(e);case"idempotency_error":return new Zo(e);case"invalid_grant":return new Wo(e);default:return new Ko(e)}},"generateV1Error"),hs=a(e=>e.type==="temporary_session_expired"?new Jo(e):e.code==="invalid_fields"?new fn(e):gn(e),"generateV2Error"),pe=class extends Error{static{a(this,"StripeError")}constructor(t={},r=null){var n;super(t.message),this.type=r||this.constructor.name,this.raw=t,this.rawType=t.type,this.code=t.code,this.doc_url=t.doc_url,this.param=t.param,this.detail=t.detail,this.headers=t.headers,this.requestId=t.requestId,this.statusCode=t.statusCode,this.message=(n=t.message)!==null&&n!==void 0?n:"",this.userMessage=t.user_message,this.charge=t.charge,this.decline_code=t.decline_code,this.payment_intent=t.payment_intent,this.payment_method=t.payment_method,this.payment_method_type=t.payment_method_type,this.setup_intent=t.setup_intent,this.source=t.source}};pe.generate=gn;var Ho=class extends pe{static{a(this,"StripeCardError")}constructor(t={}){super(t,"StripeCardError")}},fn=class extends pe{static{a(this,"StripeInvalidRequestError")}constructor(t={}){super(t,"StripeInvalidRequestError")}},hr=class extends pe{static{a(this,"StripeAPIError")}constructor(t={}){super(t,"StripeAPIError")}},yr=class extends pe{static{a(this,"StripeAuthenticationError")}constructor(t={}){super(t,"StripeAuthenticationError")}},hn=class extends pe{static{a(this,"StripePermissionError")}constructor(t={}){super(t,"StripePermissionError")}},gr=class extends pe{static{a(this,"StripeRateLimitError")}constructor(t={}){super(t,"StripeRateLimitError")}},yn=class extends pe{static{a(this,"StripeConnectionError")}constructor(t={}){super(t,"StripeConnectionError")}},Fe=class extends pe{static{a(this,"StripeSignatureVerificationError")}constructor(t,r,n={}){super(n,"StripeSignatureVerificationError"),this.header=t,this.payload=r}},Zo=class extends pe{static{a(this,"StripeIdempotencyError")}constructor(t={}){super(t,"StripeIdempotencyError")}},Wo=class extends pe{static{a(this,"StripeInvalidGrantError")}constructor(t={}){super(t,"StripeInvalidGrantError")}},Ko=class extends pe{static{a(this,"StripeUnknownError")}constructor(t={}){super(t,"StripeUnknownError")}},Jo=class extends pe{static{a(this,"TemporarySessionExpiredError")}constructor(t={}){super(t,"TemporarySessionExpiredError")}};var gf=require("child_process");var gs=class extends pe{static{a(this,"StreamProcessingError")}},Yo=class extends Vo{static{a(this,"NodePlatformFunctions")}constructor(){super(),this._exec=gf.exec,this._UNAME_CACHE=null}uuid4(){return vr.randomUUID?vr.randomUUID():super.uuid4()}getUname(){return this._UNAME_CACHE||(this._UNAME_CACHE=new Promise((t,r)=>{try{this._exec("uname -a",(n,o)=>{if(n)return t(null);t(o)})}catch{t(null)}})),this._UNAME_CACHE}secureCompare(t,r){if(!t||!r)throw new Error("secureCompare must receive two arguments");if(t.length!==r.length)return!1;if(vr.timingSafeEqual){let n=new TextEncoder,o=n.encode(t),i=n.encode(r);return vr.timingSafeEqual(o,i)}return super.secureCompare(t,r)}createEmitter(){return new ys.EventEmitter}tryBufferData(t){if(!(t.file.data instanceof ys.EventEmitter))return Promise.resolve(t);let r=[];return new Promise((n,o)=>{t.file.data.on("data",i=>{r.push(i)}).once("end",()=>{let i=Object.assign({},t);i.file.data=mf(r),n(i)}).on("error",i=>{o(new gs({message:"An error occurred while attempting to process the file for upload.",detail:i}))})})}createNodeHttpClient(t){return new tn(t)}createDefaultHttpClient(){return new tn}createNodeCryptoProvider(){return new Eo}createDefaultCryptoProvider(){return this.createNodeCryptoProvider()}};var WE=60,Qo=class e{static{a(this,"RequestSender")}constructor(t,r){this._stripe=t,this._maxBufferedRequestMetric=r}_addHeadersDirectlyToObject(t,r){t.requestId=r["request-id"],t.stripeAccount=t.stripeAccount||r["stripe-account"],t.apiVersion=t.apiVersion||r["stripe-version"],t.idempotencyKey=t.idempotencyKey||r["idempotency-key"]}_makeResponseEvent(t,r,n){let o=Date.now(),i=o-t.request_start_time;return qo({api_version:n["stripe-version"],account:n["stripe-account"],idempotency_key:n["idempotency-key"],method:t.method,path:t.path,status:r,request_id:this._getRequestId(n),elapsed:i,request_start_time:t.request_start_time,request_end_time:o})}_getRequestId(t){return t["request-id"]}_streamingResponseHandler(t,r,n){return o=>{let i=o.getHeaders(),s=a(()=>{let f=this._makeResponseEvent(t,o.getStatusCode(),i);this._stripe._emitter.emit("response",f),this._recordRequestMetrics(this._getRequestId(i),f.elapsed,r)},"streamCompleteCallback"),l=o.toStream(s);return this._addHeadersDirectlyToObject(l,i),n(null,l)}}_jsonResponseHandler(t,r,n,o){return i=>{let s=i.getHeaders(),l=this._getRequestId(s),f=i.getStatusCode(),b=this._makeResponseEvent(t,f,s);this._stripe._emitter.emit("response",b),i.toJSON().then(m=>{if(m.error){let P;throw typeof m.error=="string"&&(m.error={type:m.error,message:m.error_description}),m.error.headers=s,m.error.statusCode=f,m.error.requestId=l,f===401?P=new yr(m.error):f===403?P=new hn(m.error):f===429?P=new gr(m.error):r==="v2"?P=hs(m.error):P=gn(m.error),P}return m},m=>{throw new hr({message:"Invalid JSON received from the Stripe API",exception:m,requestId:s["request-id"]})}).then(m=>{this._recordRequestMetrics(l,b.elapsed,n);let P=i.getRawResponse();this._addHeadersDirectlyToObject(P,s),Object.defineProperty(m,"lastResponse",{enumerable:!1,writable:!1,value:P}),o(null,m)},m=>o(m,null))}}static _generateConnectionErrorMessage(t){return`An error occurred with our connection to Stripe.${t>0?` Request was retried ${t} times.`:""}`}static _shouldRetry(t,r,n,o){return o&&r===0&&Ee.CONNECTION_CLOSED_ERROR_CODES.includes(o.code)?!0:r>=n?!1:t?t.getHeaders()["stripe-should-retry"]==="false"?!1:t.getHeaders()["stripe-should-retry"]==="true"||t.getStatusCode()===409||t.getStatusCode()>=500:!0}_getSleepTimeInMS(t,r=null){let n=this._stripe.getInitialNetworkRetryDelay(),o=this._stripe.getMaxNetworkRetryDelay(),i=Math.min(n*Math.pow(2,t-1),o);return i*=.5*(1+Math.random()),i=Math.max(n,i),Number.isInteger(r)&&r<=WE&&(i=Math.max(i,r)),i*1e3}_getMaxNetworkRetries(t={}){return t.maxNetworkRetries!==void 0&&Number.isInteger(t.maxNetworkRetries)?t.maxNetworkRetries:this._stripe.getMaxNetworkRetries()}_defaultIdempotencyKey(t,r,n){let o=this._getMaxNetworkRetries(r),i=a(()=>`stripe-node-retry-${this._stripe._platformFunctions.uuid4()}`,"genKey");if(n==="v2"){if(t==="POST"||t==="DELETE")return i()}else if(n==="v1"&&t==="POST"&&o>0)return i();return null}_makeHeaders({contentType:t,contentLength:r,apiVersion:n,clientUserAgent:o,method:i,userSuppliedHeaders:s,userSuppliedSettings:l,stripeAccount:f,stripeContext:b,apiMode:m}){let P={Accept:"application/json","Content-Type":t,"User-Agent":this._getUserAgentString(m),"X-Stripe-Client-User-Agent":o,"X-Stripe-Client-Telemetry":this._getTelemetryHeader(),"Stripe-Version":n,"Stripe-Account":f,"Stripe-Context":b,"Idempotency-Key":this._defaultIdempotencyKey(i,l,m)},h=i=="POST"||i=="PUT"||i=="PATCH";return(h||r)&&(h||mn(`${i} method had non-zero contentLength but no payload is expected for this verb`),P["Content-Length"]=r),Object.assign(qo(P),cf(s))}_getUserAgentString(t){let r=this._stripe.getConstant("PACKAGE_VERSION"),n=this._stripe._appInfo?this._stripe.getAppInfoAsString():"";return`Stripe/${t} NodeBindings/${r} ${n}`.trim()}_getTelemetryHeader(){if(this._stripe.getTelemetryEnabled()&&this._stripe._prevRequestMetrics.length>0){let t=this._stripe._prevRequestMetrics.shift();return JSON.stringify({last_request_metrics:t})}}_recordRequestMetrics(t,r,n){if(this._stripe.getTelemetryEnabled()&&t)if(this._stripe._prevRequestMetrics.length>this._maxBufferedRequestMetric)mn("Request metrics buffer is full, dropping telemetry message.");else{let o={request_id:t,request_duration_ms:r};n&&n.length>0&&(o.usage=n),this._stripe._prevRequestMetrics.push(o)}}_rawRequest(t,r,n,o){return new Promise((s,l)=>{let f;try{let d=t.toUpperCase();if(d!=="POST"&&n&&Object.keys(n).length!==0)throw new Error("rawRequest only supports params on POST requests. Please pass null and add your parameters to path.");let y=[].slice.call([n,o]),I=mr(y),S=d==="POST"?Object.assign({},I):null,T=Lo(y),A=T.headers,k=T.authenticator;f={requestMethod:d,requestPath:r,bodyData:S,queryData:{},authenticator:k,headers:A,host:T.host,streaming:!!T.streaming,settings:{},usage:["raw_request"]}}catch(d){l(d);return}function b(d,y){d?l(d):s(y)}a(b,"requestCallback");let{headers:m,settings:P}=f,h=f.authenticator;this._request(f.requestMethod,f.host,r,f.bodyData,h,{headers:m,settings:P,streaming:f.streaming},f.usage,b)})}_request(t,r,n,o,i,s,l=[],f,b=null){var m;let P;i=(m=i??this._stripe._authenticator)!==null&&m!==void 0?m:null;let h=fr(n),d=a((S,T,A,k,G)=>setTimeout(S,this._getSleepTimeInMS(k,G),T,A,k+1),"retryRequest"),y=a((S,T,A)=>{let k=s.settings&&s.settings.timeout&&Number.isInteger(s.settings.timeout)&&s.settings.timeout>=0?s.settings.timeout:this._stripe.getApiField("timeout"),G={host:r||this._stripe.getApiField("host"),port:this._stripe.getApiField("port"),path:n,method:t,headers:Object.assign({},T),body:P,protocol:this._stripe.getApiField("protocol")};i(G).then(()=>{let Y=this._stripe.getApiField("httpClient").makeRequest(G.host,G.port,G.path,G.method,G.headers,G.body,G.protocol,k),Te=Date.now(),ve=qo({api_version:S,account:Fo(T["Stripe-Account"]),idempotency_key:Fo(T["Idempotency-Key"]),method:t,path:n,request_start_time:Te}),ae=A||0,te=this._getMaxNetworkRetries(s.settings||{});this._stripe._emitter.emit("request",ve),Y.then(me=>e._shouldRetry(me,ae,te)?d(y,S,T,ae,hf(me.getHeaders()["retry-after"])):s.streaming&&me.getStatusCode()<400?this._streamingResponseHandler(ve,l,f)(me):this._jsonResponseHandler(ve,h,l,f)(me)).catch(me=>{if(e._shouldRetry(null,ae,te,me))return d(y,S,T,ae,null);{let Me=me.code&&me.code===Ee.TIMEOUT_ERROR_CODE;return f(new yn({message:Me?`Request aborted due to timeout being reached (${k}ms)`:e._generateConnectionErrorMessage(ae),detail:me}))}})}).catch(Y=>{throw new pe({message:"Unable to authenticate the request",exception:Y})})},"makeRequest"),I=a((S,T)=>{if(S)return f(S);P=T,this._stripe.getClientUserAgent(A=>{let k=this._stripe.getApiField("version"),G=this._makeHeaders({contentType:h=="v2"?"application/json":"application/x-www-form-urlencoded",contentLength:P.length,apiVersion:k,clientUserAgent:A,method:t,userSuppliedHeaders:s.headers,userSuppliedSettings:s.settings,stripeAccount:h=="v2"?null:this._stripe.getApiField("stripeAccount"),stripeContext:h=="v2"?this._stripe.getApiField("stripeContext"):null,apiMode:h});y(k,G,0)})},"prepareAndMakeRequest");if(b)b(t,o,s.headers,I);else{let S;h=="v2"?S=o?ff(o):"":S=wt(o||{},h),I(null,S)}}};var ei=class{static{a(this,"V1Iterator")}constructor(t,r,n,o){this.index=0,this.pagePromise=t,this.promiseCache={currentPromise:null},this.requestArgs=r,this.spec=n,this.stripeResource=o}async iterate(t){if(!(t&&t.data&&typeof t.data.length=="number"))throw Error("Unexpected: Stripe API response does not have a well-formed `data` array.");let r=_f(this.requestArgs);if(this.index<t.data.length){let n=r?t.data.length-1-this.index:this.index,o=t.data[n];return this.index+=1,{value:o,done:!1}}else if(t.has_more){this.index=0,this.pagePromise=this.getNextPage(t);let n=await this.pagePromise;return this.iterate(n)}return{done:!0,value:void 0}}getNextPage(t){throw new Error("Unimplemented")}async _next(){return this.iterate(await this.pagePromise)}next(){if(this.promiseCache.currentPromise)return this.promiseCache.currentPromise;let t=(async()=>{let r=await this._next();return this.promiseCache.currentPromise=null,r})();return this.promiseCache.currentPromise=t,t}},_s=class extends ei{static{a(this,"V1ListIterator")}getNextPage(t){let r=_f(this.requestArgs),n=YE(t,r);return this.stripeResource._makeRequest(this.requestArgs,this.spec,{[r?"ending_before":"starting_after"]:n})}},bs=class extends ei{static{a(this,"V1SearchIterator")}getNextPage(t){if(!t.next_page)throw Error("Unexpected: Stripe API response does not have a well-formed `next_page` field, but `has_more` was true.");return this.stripeResource._makeRequest(this.requestArgs,this.spec,{page:t.next_page})}},Ps=class{static{a(this,"V2ListIterator")}constructor(t,r,n,o){this.currentPageIterator=(async()=>(await t).data[Symbol.iterator]())(),this.nextPageUrl=(async()=>(await t).next_page_url||null)(),this.requestArgs=r,this.spec=n,this.stripeResource=o}async turnPage(){let t=await this.nextPageUrl;if(!t)return null;this.spec.fullPath=t;let r=await this.stripeResource._makeRequest([],this.spec,{});return this.nextPageUrl=Promise.resolve(r.next_page_url),this.currentPageIterator=Promise.resolve(r.data[Symbol.iterator]()),this.currentPageIterator}async next(){{let n=(await this.currentPageIterator).next();if(!n.done)return{done:!1,value:n.value}}let t=await this.turnPage();if(!t)return{done:!0,value:void 0};let r=t.next();return r.done?{done:!0,value:void 0}:{done:!1,value:r.value}}},vf=a((e,t,r,n)=>{let o=fr(r.fullPath||r.path);return o!=="v2"&&r.methodType==="search"?vs(new bs(n,t,r,e)):o!=="v2"&&r.methodType==="list"?vs(new _s(n,t,r,e)):o==="v2"&&r.methodType==="list"?vs(new Ps(n,t,r,e)):null},"makeAutoPaginationMethods"),vs=a(e=>{let t=QE((...o)=>e.next(...o)),r=eI(t),n={autoPagingEach:t,autoPagingToArray:r,next:a(()=>e.next(),"next"),return:a(()=>({}),"return"),[KE()]:()=>n};return n},"makeAutoPaginationMethodsFromIterator");function KE(){return typeof Symbol<"u"&&Symbol.asyncIterator?Symbol.asyncIterator:"@@asyncIterator"}a(KE,"getAsyncIteratorSymbol");function JE(e){if(e.length<2)return null;let t=e[1];if(typeof t!="function")throw Error(`The second argument to autoPagingEach, if present, must be a callback function; received ${typeof t}`);return t}a(JE,"getDoneCallback");function XE(e){if(e.length===0)return;let t=e[0];if(typeof t!="function")throw Error(`The first argument to autoPagingEach, if present, must be a callback function; received ${typeof t}`);if(t.length===2)return t;if(t.length>2)throw Error(`The \`onItem\` callback function passed to autoPagingEach must accept at most two arguments; got ${t}`);return a(function(n,o){let i=t(n);o(i)},"_onItem")}a(XE,"getItemCallback");function YE(e,t){let r=t?0:e.data.length-1,n=e.data[r],o=n&&n.id;if(!o)throw Error("Unexpected: No `id` found on the last item while auto-paging a list.");return o}a(YE,"getLastId");function QE(e){return a(function(){let r=[].slice.call(arguments),n=XE(r),o=JE(r);if(r.length>2)throw Error(`autoPagingEach takes up to two arguments; received ${r}`);let i=tI(e,n);return dn(i,o)},"autoPagingEach")}a(QE,"makeAutoPagingEach");function eI(e){return a(function(r,n){let o=r&&r.limit;if(!o)throw Error("You must pass a `limit` option to autoPagingToArray, e.g., `autoPagingToArray({limit: 1000});`.");if(o>1e4)throw Error("You cannot specify a limit of more than 10,000 items to fetch in `autoPagingToArray`; use `autoPagingEach` to iterate through longer lists.");let i=new Promise((s,l)=>{let f=[];e(b=>{if(f.push(b),f.length>=o)return!1}).then(()=>{s(f)}).catch(l)});return dn(i,n)},"autoPagingToArray")}a(eI,"makeAutoPagingToArray");function tI(e,t){return new Promise((r,n)=>{function o(i){if(i.done){r();return}let s=i.value;return new Promise(l=>{t(s,l)}).then(l=>l===!1?o({done:!0,value:void 0}):e().then(o))}a(o,"handleIteration"),e().then(o).catch(n)})}a(tI,"wrapAsyncIteratorWithCallback");function _f(e){let t=[].slice.call(e);return!!mr(t).ending_before}a(_f,"isReverseIteration");function bf(e){if(e.path!==void 0&&e.fullPath!==void 0)throw new Error(`Method spec specified both a 'path' (${e.path}) and a 'fullPath' (${e.fullPath}).`);return function(...t){let r=typeof t[t.length-1]=="function"&&t.pop();e.urlParams=sf(e.fullPath||this.createResourcePathWithSymbols(e.path||""));let n=dn(this._makeRequest(t,e,{}),r);return Object.assign(n,vf(this,t,e,n)),n}}a(bf,"stripeMethod");c.extend=uf;c.method=bf;c.MAX_BUFFERED_REQUEST_METRICS=100;function c(e,t){if(this._stripe=e,t)throw new Error("Support for curried url params was dropped in stripe-node v7.0.0. Instead, pass two ids.");this.basePath=Uo(this.basePath||e.getApiField("basePath")),this.resourcePath=this.path,this.path=Uo(this.path),this.initialize(...arguments)}a(c,"StripeResource");c.prototype={_stripe:null,path:"",resourcePath:"",basePath:null,initialize(){},requestDataProcessor:null,validateRequest:null,createFullPath(e,t){let r=[this.basePath(t),this.path(t)];if(typeof e=="function"){let n=e(t);n&&r.push(n)}else r.push(e);return this._joinUrlParts(r)},createResourcePathWithSymbols(e){return e?`/${this._joinUrlParts([this.resourcePath,e])}`:`/${this.resourcePath}`},_joinUrlParts(e){return e.join("/").replace(/\/{2,}/g,"/")},_getRequestOpts(e,t,r){var n;let o=(t.method||"GET").toUpperCase(),i=t.usage||[],s=t.urlParams||[],l=t.encode||(ve=>ve),f=!!t.fullPath,b=Uo(f?t.fullPath:t.path||""),m=f?t.fullPath:this.createResourcePathWithSymbols(t.path),P=[].slice.call(e),h=s.reduce((ve,ae)=>{let te=P.shift();if(typeof te!="string")throw new Error(`Stripe: Argument "${ae}" must be a string, but got: ${te} (on API request to \`${o} ${m}\`)`);return ve[ae]=te,ve},{}),d=mr(P),y=l(Object.assign({},d,r)),I=Lo(P),S=I.host||t.host,T=!!t.streaming||!!I.streaming;if(P.filter(ve=>ve!=null).length)throw new Error(`Stripe: Unknown arguments (${P}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options. (on API request to ${o} \`${m}\`)`);let A=f?b(h):this.createFullPath(b,h),k=Object.assign(I.headers,t.headers);t.validator&&t.validator(y,{headers:k});let G=t.method==="GET"||t.method==="DELETE";return{requestMethod:o,requestPath:A,bodyData:G?null:y,queryData:G?y:{},authenticator:(n=I.authenticator)!==null&&n!==void 0?n:null,headers:k,host:S??null,streaming:T,settings:I.settings,usage:i}},_makeRequest(e,t,r){return new Promise((n,o)=>{var i;let s;try{s=this._getRequestOpts(e,t,r)}catch(h){o(h);return}function l(h,d){h?o(h):n(t.transformResponseData?t.transformResponseData(d):d)}a(l,"requestCallback");let f=Object.keys(s.queryData).length===0,b=[s.requestPath,f?"":"?",wt(s.queryData,fr(s.requestPath))].join(""),{headers:m,settings:P}=s;this._stripe._requestSender._request(s.requestMethod,s.host,b,s.bodyData,s.authenticator,{headers:m,settings:P,streaming:s.streaming},s.usage,l,(i=this.requestDataProcessor)===null||i===void 0?void 0:i.bind(this))})}};function Pf(e){let t={DEFAULT_TOLERANCE:300,signature:null,constructEvent(m,P,h,d,y,I){try{if(!this.signature)throw new Error("ERR: missing signature helper, unable to verify");this.signature.verifyHeader(m,P,h,d||t.DEFAULT_TOLERANCE,y,I)}catch(T){throw T instanceof cr&&(T.message+="\nUse `await constructEventAsync(...)` instead of `constructEvent(...)`"),T}return m instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(m)):JSON.parse(m)},async constructEventAsync(m,P,h,d,y,I){if(!this.signature)throw new Error("ERR: missing signature helper, unable to verify");return await this.signature.verifyHeaderAsync(m,P,h,d||t.DEFAULT_TOLERANCE,y,I),m instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(m)):JSON.parse(m)},generateTestHeaderString:a(function(m){let P=b(m),h=P.signature||P.cryptoProvider.computeHMACSignature(P.payloadString,P.secret);return P.generateHeaderString(h)},"generateTestHeaderString"),generateTestHeaderStringAsync:a(async function(m){let P=b(m),h=P.signature||await P.cryptoProvider.computeHMACSignatureAsync(P.payloadString,P.secret);return P.generateHeaderString(h)},"generateTestHeaderStringAsync")},r={EXPECTED_SCHEME:"v1",verifyHeader(m,P,h,d,y,I){let{decodedHeader:S,decodedPayload:T,details:A,suspectPayloadType:k}=o(m,P,this.EXPECTED_SCHEME),G=/\s/.test(h);y=y||f();let Y=y.computeHMACSignature(n(T,A),h);return i(T,S,A,Y,d,k,G,I),!0},async verifyHeaderAsync(m,P,h,d,y,I){let{decodedHeader:S,decodedPayload:T,details:A,suspectPayloadType:k}=o(m,P,this.EXPECTED_SCHEME),G=/\s/.test(h);y=y||f();let Y=await y.computeHMACSignatureAsync(n(T,A),h);return i(T,S,A,Y,d,k,G,I)}};function n(m,P){return`${P.timestamp}.${m}`}a(n,"makeHMACContent");function o(m,P,h){if(!m)throw new Fe(P,m,{message:"No webhook payload was provided."});let d=typeof m!="string"&&!(m instanceof Uint8Array),y=new TextDecoder("utf8"),I=m instanceof Uint8Array?y.decode(m):m;if(Array.isArray(P))throw new Error("Unexpected: An array was passed as a header, which should not be possible for the stripe-signature header.");if(P==null||P=="")throw new Fe(P,m,{message:"No stripe-signature header value was provided."});let S=P instanceof Uint8Array?y.decode(P):P,T=s(S,h);if(!T||T.timestamp===-1)throw new Fe(S,I,{message:"Unable to extract timestamp and signatures from header"});if(!T.signatures.length)throw new Fe(S,I,{message:"No signatures found with expected scheme"});return{decodedPayload:I,decodedHeader:S,details:T,suspectPayloadType:d}}a(o,"parseEventDetails");function i(m,P,h,d,y,I,S,T){let A=!!h.signatures.filter(e.secureCompare.bind(e,d)).length,k=`
|
|
7
|
-
|
|
1
|
+
"use strict";var Iw=Object.create;var cn=Object.defineProperty;var Aw=Object.getOwnPropertyDescriptor;var kw=Object.getOwnPropertyNames;var ww=Object.getPrototypeOf,Ow=Object.prototype.hasOwnProperty;var s=(e,t)=>cn(e,"name",{value:t,configurable:!0});var U=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(o){throw t=0,o}},Ye=(e,t)=>{for(var o in t)cn(e,o,{get:t[o],enumerable:!0})},zy=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of kw(t))!Ow.call(e,r)&&r!==o&&cn(e,r,{get:()=>t[r],enumerable:!(n=Aw(t,r))||n.enumerable});return e};var pt=(e,t,o)=>(o=e!=null?Iw(ww(e)):{},zy(t||!e||!e.__esModule?cn(o,"default",{value:e,enumerable:!0}):o,e)),Rw=e=>zy(cn({},"__esModule",{value:!0}),e);var Kg=U((Wg,qc)=>{(function(e){"use strict";let t="(0?\\d+|0x[a-f0-9]+)",o={fourOctet:new RegExp(`^${t}\\.${t}\\.${t}\\.${t}$`,"i"),threeOctet:new RegExp(`^${t}\\.${t}\\.${t}$`,"i"),twoOctet:new RegExp(`^${t}\\.${t}$`,"i"),longValue:new RegExp(`^${t}$`,"i")},n=new RegExp("^0[0-7]+$","i"),r=new RegExp("^0x[a-f0-9]+$","i"),i="%[0-9a-z]{1,}",a="(?:[0-9a-f]+::?)+",c={zoneIndex:new RegExp(i,"i"),native:new RegExp(`^(::)?(${a})?([0-9a-f]+)?(::)?(${i})?$`,"i"),deprecatedTransitional:new RegExp(`^(?:::)(${t}\\.${t}\\.${t}\\.${t}(${i})?)$`,"i"),transitional:new RegExp(`^((?:${a})|(?:::)(?:${a})?)${t}\\.${t}\\.${t}\\.${t}(${i})?$`,"i")};function p(f,v){if(f.indexOf("::")!==f.lastIndexOf("::"))return null;let I=0,T=-1,x=(f.match(c.zoneIndex)||[])[0],k,R;for(x&&(x=x.substring(1),f=f.replace(/%.+$/,""));(T=f.indexOf(":",T+1))>=0;)I++;if(f.substr(0,2)==="::"&&I--,f.substr(-2,2)==="::"&&I--,I>v)return null;for(R=v-I,k=":";R--;)k+="0:";return f=f.replace("::",k),f[0]===":"&&(f=f.slice(1)),f[f.length-1]===":"&&(f=f.slice(0,-1)),v=(function(){let q=f.split(":"),Q=[];for(let we=0;we<q.length;we++)Q.push(parseInt(q[we],16));return Q})(),{parts:v,zoneId:x}}s(p,"expandIPv6");function m(f,v,I,T){if(f.length!==v.length)throw new Error("ipaddr: cannot match CIDR for objects with different lengths");let x=0,k;for(;T>0;){if(k=I-T,k<0&&(k=0),f[x]>>k!==v[x]>>k)return!1;T-=I,x+=1}return!0}s(m,"matchCIDR");function l(f){if(r.test(f))return parseInt(f,16);if(f[0]==="0"&&!isNaN(parseInt(f[1],10))){if(n.test(f))return parseInt(f,8);throw new Error(`ipaddr: cannot parse ${f} as octal`)}return parseInt(f,10)}s(l,"parseIntAuto");function g(f,v){for(;f.length<v;)f=`0${f}`;return f}s(g,"padPart");let h={};h.IPv4=(function(){function f(v){if(v.length!==4)throw new Error("ipaddr: ipv4 octet count should be 4");let I,T;for(I=0;I<v.length;I++)if(T=v[I],!(0<=T&&T<=255))throw new Error("ipaddr: ipv4 octet should fit in 8 bits");this.octets=v}return s(f,"IPv4"),f.prototype.SpecialRanges={unspecified:[[new f([0,0,0,0]),8]],broadcast:[[new f([255,255,255,255]),32]],multicast:[[new f([224,0,0,0]),4]],linkLocal:[[new f([169,254,0,0]),16]],loopback:[[new f([127,0,0,0]),8]],carrierGradeNat:[[new f([100,64,0,0]),10]],private:[[new f([10,0,0,0]),8],[new f([172,16,0,0]),12],[new f([192,168,0,0]),16]],reserved:[[new f([192,0,0,0]),24],[new f([192,0,2,0]),24],[new f([192,88,99,0]),24],[new f([198,18,0,0]),15],[new f([198,51,100,0]),24],[new f([203,0,113,0]),24],[new f([240,0,0,0]),4]],as112:[[new f([192,175,48,0]),24],[new f([192,31,196,0]),24]],amt:[[new f([192,52,193,0]),24]]},f.prototype.kind=function(){return"ipv4"},f.prototype.match=function(v,I){let T;if(I===void 0&&(T=v,v=T[0],I=T[1]),v.kind()!=="ipv4")throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one");return m(this.octets,v.octets,8,I)},f.prototype.prefixLengthFromSubnetMask=function(){let v=0,I=!1,T={0:8,128:7,192:6,224:5,240:4,248:3,252:2,254:1,255:0},x,k,R;for(x=3;x>=0;x-=1)if(k=this.octets[x],k in T){if(R=T[k],I&&R!==0)return null;R!==8&&(I=!0),v+=R}else return null;return 32-v},f.prototype.range=function(){return h.subnetMatch(this,this.SpecialRanges)},f.prototype.toByteArray=function(){return this.octets.slice(0)},f.prototype.toIPv4MappedAddress=function(){return h.IPv6.parse(`::ffff:${this.toString()}`)},f.prototype.toNormalizedString=function(){return this.toString()},f.prototype.toString=function(){return this.octets.join(".")},f})(),h.IPv4.broadcastAddressFromCIDR=function(f){try{let v=this.parseCIDR(f),I=v[0].toByteArray(),T=this.subnetMaskFromPrefixLength(v[1]).toByteArray(),x=[],k=0;for(;k<4;)x.push(parseInt(I[k],10)|parseInt(T[k],10)^255),k++;return new this(x)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},h.IPv4.isIPv4=function(f){return this.parser(f)!==null},h.IPv4.isValid=function(f){try{return new this(this.parser(f)),!0}catch{return!1}},h.IPv4.isValidCIDR=function(f){try{return this.parseCIDR(f),!0}catch{return!1}},h.IPv4.isValidFourPartDecimal=function(f){return!!(h.IPv4.isValid(f)&&f.match(/^(0|[1-9]\d*)(\.(0|[1-9]\d*)){3}$/))},h.IPv4.isValidCIDRFourPartDecimal=function(f){let v=f.match(/^(.+)\/(\d+)$/);return!h.IPv4.isValidCIDR(f)||!v?!1:h.IPv4.isValidFourPartDecimal(v[1])},h.IPv4.networkAddressFromCIDR=function(f){let v,I,T,x,k;try{for(v=this.parseCIDR(f),T=v[0].toByteArray(),k=this.subnetMaskFromPrefixLength(v[1]).toByteArray(),x=[],I=0;I<4;)x.push(parseInt(T[I],10)&parseInt(k[I],10)),I++;return new this(x)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},h.IPv4.parse=function(f){let v=this.parser(f);if(v===null)throw new Error("ipaddr: string is not formatted like an IPv4 Address");return new this(v)},h.IPv4.parseCIDR=function(f){let v;if(v=f.match(/^(.+)\/(\d+)$/)){let I=parseInt(v[2]);if(I>=0&&I<=32){let T=[this.parse(v[1]),I];return Object.defineProperty(T,"toString",{value:s(function(){return this.join("/")},"value")}),T}}throw new Error("ipaddr: string is not formatted like an IPv4 CIDR range")},h.IPv4.parser=function(f){let v,I,T;if(v=f.match(o.fourOctet))return(function(){let x=v.slice(1,6),k=[];for(let R=0;R<x.length;R++)I=x[R],k.push(l(I));return k})();if(v=f.match(o.longValue)){if(T=l(v[1]),T>4294967295||T<0)throw new Error("ipaddr: address outside defined range");return(function(){let x=[],k;for(k=0;k<=24;k+=8)x.push(T>>k&255);return x})().reverse()}else return(v=f.match(o.twoOctet))?(function(){let x=v.slice(1,4),k=[];if(T=l(x[1]),T>16777215||T<0)throw new Error("ipaddr: address outside defined range");return k.push(l(x[0])),k.push(T>>16&255),k.push(T>>8&255),k.push(T&255),k})():(v=f.match(o.threeOctet))?(function(){let x=v.slice(1,5),k=[];if(T=l(x[2]),T>65535||T<0)throw new Error("ipaddr: address outside defined range");return k.push(l(x[0])),k.push(l(x[1])),k.push(T>>8&255),k.push(T&255),k})():null},h.IPv4.subnetMaskFromPrefixLength=function(f){if(f=parseInt(f),f<0||f>32)throw new Error("ipaddr: invalid IPv4 prefix length");let v=[0,0,0,0],I=0,T=Math.floor(f/8);for(;I<T;)v[I]=255,I++;return T<4&&(v[T]=Math.pow(2,f%8)-1<<8-f%8),new this(v)},h.IPv6=(function(){function f(v,I){let T,x;if(v.length===16)for(this.parts=[],T=0;T<=14;T+=2)this.parts.push(v[T]<<8|v[T+1]);else if(v.length===8)this.parts=v;else throw new Error("ipaddr: ipv6 part count should be 8 or 16");for(T=0;T<this.parts.length;T++)if(x=this.parts[T],!(0<=x&&x<=65535))throw new Error("ipaddr: ipv6 part should fit in 16 bits");I&&(this.zoneId=I)}return s(f,"IPv6"),f.prototype.SpecialRanges={unspecified:[new f([0,0,0,0,0,0,0,0]),128],linkLocal:[new f([65152,0,0,0,0,0,0,0]),10],multicast:[new f([65280,0,0,0,0,0,0,0]),8],loopback:[new f([0,0,0,0,0,0,0,1]),128],uniqueLocal:[new f([64512,0,0,0,0,0,0,0]),7],ipv4Mapped:[new f([0,0,0,0,0,65535,0,0]),96],discard:[new f([256,0,0,0,0,0,0,0]),64],rfc6145:[new f([0,0,0,0,65535,0,0,0]),96],rfc6052:[new f([100,65435,0,0,0,0,0,0]),96],"6to4":[new f([8194,0,0,0,0,0,0,0]),16],teredo:[new f([8193,0,0,0,0,0,0,0]),32],benchmarking:[new f([8193,2,0,0,0,0,0,0]),48],amt:[new f([8193,3,0,0,0,0,0,0]),32],as112v6:[[new f([8193,4,274,0,0,0,0,0]),48],[new f([9760,79,32768,0,0,0,0,0]),48]],deprecated:[new f([8193,16,0,0,0,0,0,0]),28],orchid2:[new f([8193,32,0,0,0,0,0,0]),28],droneRemoteIdProtocolEntityTags:[new f([8193,48,0,0,0,0,0,0]),28],reserved:[[new f([8193,0,0,0,0,0,0,0]),23],[new f([8193,3512,0,0,0,0,0,0]),32]]},f.prototype.isIPv4MappedAddress=function(){return this.range()==="ipv4Mapped"},f.prototype.kind=function(){return"ipv6"},f.prototype.match=function(v,I){let T;if(I===void 0&&(T=v,v=T[0],I=T[1]),v.kind()!=="ipv6")throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one");return m(this.parts,v.parts,16,I)},f.prototype.prefixLengthFromSubnetMask=function(){let v=0,I=!1,T={0:16,32768:15,49152:14,57344:13,61440:12,63488:11,64512:10,65024:9,65280:8,65408:7,65472:6,65504:5,65520:4,65528:3,65532:2,65534:1,65535:0},x,k;for(let R=7;R>=0;R-=1)if(x=this.parts[R],x in T){if(k=T[x],I&&k!==0)return null;k!==16&&(I=!0),v+=k}else return null;return 128-v},f.prototype.range=function(){return h.subnetMatch(this,this.SpecialRanges)},f.prototype.toByteArray=function(){let v,I=[],T=this.parts;for(let x=0;x<T.length;x++)v=T[x],I.push(v>>8),I.push(v&255);return I},f.prototype.toFixedLengthString=function(){let v=(function(){let T=[];for(let x=0;x<this.parts.length;x++)T.push(g(this.parts[x].toString(16),4));return T}).call(this).join(":"),I="";return this.zoneId&&(I=`%${this.zoneId}`),v+I},f.prototype.toIPv4Address=function(){if(!this.isIPv4MappedAddress())throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4");let v=this.parts.slice(-2),I=v[0],T=v[1];return new h.IPv4([I>>8,I&255,T>>8,T&255])},f.prototype.toNormalizedString=function(){let v=(function(){let T=[];for(let x=0;x<this.parts.length;x++)T.push(this.parts[x].toString(16));return T}).call(this).join(":"),I="";return this.zoneId&&(I=`%${this.zoneId}`),v+I},f.prototype.toRFC5952String=function(){let v=/((^|:)(0(:|$)){2,})/g,I=this.toNormalizedString(),T=0,x=-1,k;for(;k=v.exec(I);)k[0].length>x&&(T=k.index,x=k[0].length);return x<0?I:`${I.substring(0,T)}::${I.substring(T+x)}`},f.prototype.toString=function(){return this.toRFC5952String()},f})(),h.IPv6.broadcastAddressFromCIDR=function(f){try{let v=this.parseCIDR(f),I=v[0].toByteArray(),T=this.subnetMaskFromPrefixLength(v[1]).toByteArray(),x=[],k=0;for(;k<16;)x.push(parseInt(I[k],10)|parseInt(T[k],10)^255),k++;return new this(x)}catch(v){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${v})`)}},h.IPv6.isIPv6=function(f){return this.parser(f)!==null},h.IPv6.isValid=function(f){if(typeof f=="string"&&f.indexOf(":")===-1)return!1;try{let v=this.parser(f);return new this(v.parts,v.zoneId),!0}catch{return!1}},h.IPv6.isValidCIDR=function(f){if(typeof f=="string"&&f.indexOf(":")===-1)return!1;try{return this.parseCIDR(f),!0}catch{return!1}},h.IPv6.networkAddressFromCIDR=function(f){let v,I,T,x,k;try{for(v=this.parseCIDR(f),T=v[0].toByteArray(),k=this.subnetMaskFromPrefixLength(v[1]).toByteArray(),x=[],I=0;I<16;)x.push(parseInt(T[I],10)&parseInt(k[I],10)),I++;return new this(x)}catch(R){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${R})`)}},h.IPv6.parse=function(f){let v=this.parser(f);if(v.parts===null)throw new Error("ipaddr: string is not formatted like an IPv6 Address");return new this(v.parts,v.zoneId)},h.IPv6.parseCIDR=function(f){let v,I,T;if((I=f.match(/^(.+)\/(\d+)$/))&&(v=parseInt(I[2]),v>=0&&v<=128))return T=[this.parse(I[1]),v],Object.defineProperty(T,"toString",{value:s(function(){return this.join("/")},"value")}),T;throw new Error("ipaddr: string is not formatted like an IPv6 CIDR range")},h.IPv6.parser=function(f){let v,I,T,x,k,R;if(T=f.match(c.deprecatedTransitional))return this.parser(`::ffff:${T[1]}`);if(c.native.test(f))return p(f,8);if((T=f.match(c.transitional))&&(R=T[6]||"",v=T[1],T[1].endsWith("::")||(v=v.slice(0,-1)),v=p(v+R,6),v.parts)){for(k=[parseInt(T[2]),parseInt(T[3]),parseInt(T[4]),parseInt(T[5])],I=0;I<k.length;I++)if(x=k[I],!(0<=x&&x<=255))return null;return v.parts.push(k[0]<<8|k[1]),v.parts.push(k[2]<<8|k[3]),{parts:v.parts,zoneId:v.zoneId}}return null},h.IPv6.subnetMaskFromPrefixLength=function(f){if(f=parseInt(f),f<0||f>128)throw new Error("ipaddr: invalid IPv6 prefix length");let v=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],I=0,T=Math.floor(f/8);for(;I<T;)v[I]=255,I++;return T<16&&(v[T]=Math.pow(2,f%8)-1<<8-f%8),new this(v)},h.fromByteArray=function(f){let v=f.length;if(v===4)return new h.IPv4(f);if(v===16)return new h.IPv6(f);throw new Error("ipaddr: the binary input is neither an IPv6 nor IPv4 address")},h.isValid=function(f){return h.IPv6.isValid(f)||h.IPv4.isValid(f)},h.isValidCIDR=function(f){return h.IPv6.isValidCIDR(f)||h.IPv4.isValidCIDR(f)},h.parse=function(f){if(h.IPv6.isValid(f))return h.IPv6.parse(f);if(h.IPv4.isValid(f))return h.IPv4.parse(f);throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format")},h.parseCIDR=function(f){try{return h.IPv6.parseCIDR(f)}catch{try{return h.IPv4.parseCIDR(f)}catch{throw new Error("ipaddr: the address has neither IPv6 nor IPv4 CIDR format")}}},h.process=function(f){let v=this.parse(f);return v.kind()==="ipv6"&&v.isIPv4MappedAddress()?v.toIPv4Address():v},h.subnetMatch=function(f,v,I){let T,x,k,R;I==null&&(I="unicast");for(x in v)if(Object.prototype.hasOwnProperty.call(v,x)){for(k=v[x],k[0]&&!(k[0]instanceof Array)&&(k=[k]),T=0;T<k.length;T++)if(R=k[T],f.kind()===R[0].kind()&&f.match.apply(f,R))return x}return I},typeof qc<"u"&&qc.exports?qc.exports=h:e.ipaddr=h})(Wg)});var vb=U((v2,gb)=>{var yb=require("stream").Stream,PN=require("util");gb.exports=ht;function ht(){this.source=null,this.dataSize=0,this.maxDataSize=1024*1024,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}s(ht,"DelayedStream");PN.inherits(ht,yb);ht.create=function(e,t){var o=new this;t=t||{};for(var n in t)o[n]=t[n];o.source=e;var r=e.emit;return e.emit=function(){return o._handleEmit(arguments),r.apply(e,arguments)},e.on("error",function(){}),o.pauseStream&&e.pause(),o};Object.defineProperty(ht.prototype,"readable",{configurable:!0,enumerable:!0,get:s(function(){return this.source.readable},"get")});ht.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};ht.prototype.resume=function(){this._released||this.release(),this.source.resume()};ht.prototype.pause=function(){this.source.pause()};ht.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};ht.prototype.pipe=function(){var e=yb.prototype.pipe.apply(this,arguments);return this.resume(),e};ht.prototype._handleEmit=function(e){if(this._released){this.emit.apply(this,e);return}e[0]==="data"&&(this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded()),this._bufferedEvents.push(e)};ht.prototype._checkIfMaxDataSizeExceeded=function(){if(!this._maxDataSizeExceeded&&!(this.dataSize<=this.maxDataSize)){this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}}});var xb=U((b2,Pb)=>{var xN=require("util"),bb=require("stream").Stream,_b=vb();Pb.exports=ye;function ye(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2*1024*1024,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}s(ye,"CombinedStream");xN.inherits(ye,bb);ye.create=function(e){var t=new this;e=e||{};for(var o in e)t[o]=e[o];return t};ye.isStreamLike=function(e){return typeof e!="function"&&typeof e!="string"&&typeof e!="boolean"&&typeof e!="number"&&!Buffer.isBuffer(e)};ye.prototype.append=function(e){var t=ye.isStreamLike(e);if(t){if(!(e instanceof _b)){var o=_b.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=o}this._handleErrors(e),this.pauseStreams&&e.pause()}return this._streams.push(e),this};ye.prototype.pipe=function(e,t){return bb.prototype.pipe.call(this,e,t),this.resume(),e};ye.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop){this._pendingNext=!0;return}this._insideLoop=!0;try{do this._pendingNext=!1,this._realGetNext();while(this._pendingNext)}finally{this._insideLoop=!1}};ye.prototype._realGetNext=function(){var e=this._streams.shift();if(typeof e>"u"){this.end();return}if(typeof e!="function"){this._pipeNext(e);return}var t=e;t(function(o){var n=ye.isStreamLike(o);n&&(o.on("data",this._checkDataSize.bind(this)),this._handleErrors(o)),this._pipeNext(o)}.bind(this))};ye.prototype._pipeNext=function(e){this._currentStream=e;var t=ye.isStreamLike(e);if(t){e.on("end",this._getNext.bind(this)),e.pipe(this,{end:!1});return}var o=e;this.write(o),this._getNext()};ye.prototype._handleErrors=function(e){var t=this;e.on("error",function(o){t._emitError(o)})};ye.prototype.write=function(e){this.emit("data",e)};ye.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function"&&this._currentStream.pause(),this.emit("pause"))};ye.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&typeof this._currentStream.resume=="function"&&this._currentStream.resume(),this.emit("resume")};ye.prototype.end=function(){this._reset(),this.emit("end")};ye.prototype.destroy=function(){this._reset(),this.emit("close")};ye.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};ye.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}};ye.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach(function(t){t.dataSize&&(e.dataSize+=t.dataSize)}),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)};ye.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var Tb=U((x2,Sb)=>{"use strict";Sb.exports={"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/xml":{source:"iana",compressible:!0,extensions:["xml"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dat"]},"application/msword":{source:"iana",extensions:["doc"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",extensions:["docx"]},"application/vnd.ms-excel":{source:"iana",extensions:["xls"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",extensions:["xlsx"]},"application/vnd.ms-powerpoint":{source:"iana",extensions:["ppt"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",extensions:["pptx"]},"application/csv":{compressible:!0,extensions:["csv"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/wasm":{source:"iana",compressible:!0,extensions:["wasm"]},"text/plain":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["txt","text","log"]},"text/html":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["html","htm"]},"text/css":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["css"]},"text/csv":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["csv"]},"text/markdown":{source:"iana",compressible:!0,charset:"UTF-8",extensions:["md","markdown"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/yaml":{compressible:!0,extensions:["yaml","yml"]},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/webp":{source:"apache",compressible:!1,extensions:["webp"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tiff","tif"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/heic":{source:"iana",compressible:!1,extensions:["heic"]},"image/avif":{source:"iana",compressible:!1,extensions:["avif"]},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mp3","mpga"]},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/ogg":{source:"iana",compressible:!1,extensions:["ogg","oga"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","m4v"]},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg"]},"video/webm":{source:"iana",compressible:!1,extensions:["webm"]},"video/quicktime":{source:"iana",compressible:!1,extensions:["mov","qt"]},"video/x-msvideo":{source:"iana",compressible:!1,extensions:["avi"]},"font/woff":{source:"iana",compressible:!1,extensions:["woff"]},"font/woff2":{source:"iana",compressible:!1,extensions:["woff2"]},"font/ttf":{source:"iana",compressible:!0,extensions:["ttf"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"multipart/form-data":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/manifest+json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/ics":{compressible:!0,extensions:["ics"]},"text/calendar":{source:"iana",compressible:!0,extensions:["ics","ifb"]},"application/x-ndjson":{compressible:!0,extensions:["ndjson"]}}});var Ab=U(Ke=>{"use strict";var Eu=Tb(),SN=require("path").extname,Eb=/^\s*([^;\s]*)(?:;|\s|$)/,TN=/^text\//i;Ke.charset=Ib;Ke.charsets={lookup:Ib};Ke.contentType=EN;Ke.extension=IN;Ke.extensions=Object.create(null);Ke.lookup=AN;Ke.types=Object.create(null);kN(Ke.extensions,Ke.types);function Ib(e){if(!e||typeof e!="string")return!1;var t=Eb.exec(e),o=t&&Eu[t[1].toLowerCase()];return o&&o.charset?o.charset:t&&TN.test(t[1])?"UTF-8":!1}s(Ib,"charset");function EN(e){if(!e||typeof e!="string")return!1;var t=e.indexOf("/")===-1?Ke.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var o=Ke.charset(t);o&&(t+="; charset="+o.toLowerCase())}return t}s(EN,"contentType");function IN(e){if(!e||typeof e!="string")return!1;var t=Eb.exec(e),o=t&&Ke.extensions[t[1].toLowerCase()];return!o||!o.length?!1:o[0]}s(IN,"extension");function AN(e){if(!e||typeof e!="string")return!1;var t=SN("x."+e).toLowerCase().substr(1);return t&&Ke.types[t]||!1}s(AN,"lookup");function kN(e,t){var o=["nginx","apache",void 0,"iana"];Object.keys(Eu).forEach(s(function(r){var i=Eu[r],a=i.extensions;if(!(!a||!a.length)){e[r]=a;for(var c=0;c<a.length;c++){var p=a[c];if(t[p]){var m=o.indexOf(Eu[t[p]].source),l=o.indexOf(i.source);if(t[p]!=="application/octet-stream"&&(m>l||m===l&&t[p].substr(0,12)==="application/"))continue}t[p]=r}}},"forEachMimeType"))}s(kN,"populateMaps")});var wb=U((E2,kb)=>{kb.exports=wN;function wN(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;t?t(e):setTimeout(e,0)}s(wN,"defer")});var ph=U((A2,Rb)=>{var Ob=wb();Rb.exports=ON;function ON(e){var t=!1;return Ob(function(){t=!0}),s(function(n,r){t?e(n,r):Ob(s(function(){e(n,r)},"nextTick_callback"))},"async_callback")}s(ON,"async")});var lh=U((w2,Cb)=>{Cb.exports=RN;function RN(e){Object.keys(e.jobs).forEach(CN.bind(e)),e.jobs={}}s(RN,"abort");function CN(e){typeof this.jobs[e]=="function"&&this.jobs[e]()}s(CN,"clean")});var dh=U((R2,Nb)=>{var $b=ph(),$N=lh();Nb.exports=NN;function NN(e,t,o,n){var r=o.keyedList?o.keyedList[o.index]:o.index;o.jobs[r]=DN(t,r,e[r],function(i,a){r in o.jobs&&(delete o.jobs[r],i?$N(o):o.results[r]=a,n(i,o.results))})}s(NN,"iterate");function DN(e,t,o,n){var r;return e.length==2?r=e(o,$b(n)):r=e(o,t,$b(n)),r}s(DN,"runJob")});var mh=U(($2,Db)=>{Db.exports=zN;function zN(e,t){var o=!Array.isArray(e),n={index:0,keyedList:o||t?Object.keys(e):null,jobs:{},results:o?{}:[],size:o?Object.keys(e).length:e.length};return t&&n.keyedList.sort(o?t:function(r,i){return t(e[r],e[i])}),n}s(zN,"state")});var fh=U((D2,zb)=>{var MN=lh(),LN=ph();zb.exports=UN;function UN(e){Object.keys(this.jobs).length&&(this.index=this.size,MN(this),LN(e)(null,this.results))}s(UN,"terminator")});var Lb=U((M2,Mb)=>{var qN=dh(),jN=mh(),FN=fh();Mb.exports=BN;function BN(e,t,o){for(var n=jN(e);n.index<(n.keyedList||e).length;)qN(e,t,n,function(r,i){if(r){o(r,i);return}if(Object.keys(n.jobs).length===0){o(null,n.results);return}}),n.index++;return FN.bind(n,o)}s(BN,"parallel")});var hh=U((U2,Iu)=>{var Ub=dh(),ZN=mh(),VN=fh();Iu.exports=GN;Iu.exports.ascending=qb;Iu.exports.descending=HN;function GN(e,t,o,n){var r=ZN(e,o);return Ub(e,t,r,s(function i(a,c){if(a){n(a,c);return}if(r.index++,r.index<(r.keyedList||e).length){Ub(e,t,r,i);return}n(null,r.results)},"iteratorHandler")),VN.bind(r,n)}s(GN,"serialOrdered");function qb(e,t){return e<t?-1:e>t?1:0}s(qb,"ascending");function HN(e,t){return-1*qb(e,t)}s(HN,"descending")});var Fb=U((j2,jb)=>{var WN=hh();jb.exports=KN;function KN(e,t,o){return WN(e,t,null,o)}s(KN,"serial")});var Zb=U((B2,Bb)=>{Bb.exports={parallel:Lb(),serial:Fb(),serialOrdered:hh()}});var yh=U((Z2,Vb)=>{"use strict";Vb.exports=Object});var Hb=U((V2,Gb)=>{"use strict";Gb.exports=Error});var Kb=U((G2,Wb)=>{"use strict";Wb.exports=EvalError});var Xb=U((H2,Jb)=>{"use strict";Jb.exports=RangeError});var Qb=U((W2,Yb)=>{"use strict";Yb.exports=ReferenceError});var tP=U((K2,eP)=>{"use strict";eP.exports=SyntaxError});var tr=U((J2,rP)=>{"use strict";rP.exports=TypeError});var nP=U((X2,oP)=>{"use strict";oP.exports=URIError});var aP=U((Y2,iP)=>{"use strict";iP.exports=Math.abs});var cP=U((Q2,sP)=>{"use strict";sP.exports=Math.floor});var pP=U((eH,uP)=>{"use strict";uP.exports=Math.max});var dP=U((tH,lP)=>{"use strict";lP.exports=Math.min});var fP=U((rH,mP)=>{"use strict";mP.exports=Math.pow});var yP=U((oH,hP)=>{"use strict";hP.exports=Math.round});var vP=U((nH,gP)=>{"use strict";gP.exports=Number.isNaN||s(function(t){return t!==t},"isNaN")});var bP=U((aH,_P)=>{"use strict";var JN=vP();_P.exports=s(function(t){return JN(t)||t===0?t:t<0?-1:1},"sign")});var xP=U((cH,PP)=>{"use strict";PP.exports=Object.getOwnPropertyDescriptor});var gh=U((uH,SP)=>{"use strict";var Au=xP();if(Au)try{Au([],"length")}catch{Au=null}SP.exports=Au});var EP=U((pH,TP)=>{"use strict";var ku=Object.defineProperty||!1;if(ku)try{ku({},"a",{value:1})}catch{ku=!1}TP.exports=ku});var vh=U((lH,IP)=>{"use strict";IP.exports=s(function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},o=Symbol("test"),n=Object(o);if(typeof o=="string"||Object.prototype.toString.call(o)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var r=42;t[o]=r;for(var i in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var a=Object.getOwnPropertySymbols(t);if(a.length!==1||a[0]!==o||!Object.prototype.propertyIsEnumerable.call(t,o))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var c=Object.getOwnPropertyDescriptor(t,o);if(c.value!==r||c.enumerable!==!0)return!1}return!0},"hasSymbols")});var wP=U((mH,kP)=>{"use strict";var AP=typeof Symbol<"u"&&Symbol,XN=vh();kP.exports=s(function(){return typeof AP!="function"||typeof Symbol!="function"||typeof AP("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:XN()},"hasNativeSymbols")});var _h=U((hH,OP)=>{"use strict";OP.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var bh=U((yH,RP)=>{"use strict";var YN=yh();RP.exports=YN.getPrototypeOf||null});var NP=U((gH,$P)=>{"use strict";var QN="Function.prototype.bind called on incompatible ",eD=Object.prototype.toString,tD=Math.max,rD="[object Function]",CP=s(function(t,o){for(var n=[],r=0;r<t.length;r+=1)n[r]=t[r];for(var i=0;i<o.length;i+=1)n[i+t.length]=o[i];return n},"concatty"),oD=s(function(t,o){for(var n=[],r=o||0,i=0;r<t.length;r+=1,i+=1)n[i]=t[r];return n},"slicy"),nD=s(function(e,t){for(var o="",n=0;n<e.length;n+=1)o+=e[n],n+1<e.length&&(o+=t);return o},"joiny");$P.exports=s(function(t){var o=this;if(typeof o!="function"||eD.apply(o)!==rD)throw new TypeError(QN+o);for(var n=oD(arguments,1),r,i=s(function(){if(this instanceof r){var l=o.apply(this,CP(n,arguments));return Object(l)===l?l:this}return o.apply(t,CP(n,arguments))},"binder"),a=tD(0,o.length-n.length),c=[],p=0;p<a;p++)c[p]="$"+p;if(r=Function("binder","return function ("+nD(c,",")+"){ return binder.apply(this,arguments); }")(i),o.prototype){var m=s(function(){},"Empty");m.prototype=o.prototype,r.prototype=new m,m.prototype=null}return r},"bind")});var Oo=U((_H,DP)=>{"use strict";var iD=NP();DP.exports=Function.prototype.bind||iD});var wu=U((bH,zP)=>{"use strict";zP.exports=Function.prototype.call});var Ph=U((PH,MP)=>{"use strict";MP.exports=Function.prototype.apply});var UP=U((xH,LP)=>{"use strict";LP.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var jP=U((SH,qP)=>{"use strict";var aD=Oo(),sD=Ph(),cD=wu(),uD=UP();qP.exports=uD||aD.call(cD,sD)});var xh=U((TH,FP)=>{"use strict";var pD=Oo(),lD=tr(),dD=wu(),mD=jP();FP.exports=s(function(t){if(t.length<1||typeof t[0]!="function")throw new lD("a function is required");return mD(pD,dD,t)},"callBindBasic")});var WP=U((IH,HP)=>{"use strict";var fD=xh(),BP=gh(),VP;try{VP=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var Sh=!!VP&&BP&&BP(Object.prototype,"__proto__"),GP=Object,ZP=GP.getPrototypeOf;HP.exports=Sh&&typeof Sh.get=="function"?fD([Sh.get]):typeof ZP=="function"?s(function(t){return ZP(t==null?t:GP(t))},"getDunder"):!1});var QP=U((kH,YP)=>{"use strict";var KP=_h(),JP=bh(),XP=WP();YP.exports=KP?s(function(t){return KP(t)},"getProto"):JP?s(function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return JP(t)},"getProto"):XP?s(function(t){return XP(t)},"getProto"):null});var Th=U((OH,ex)=>{"use strict";var hD=Function.prototype.call,yD=Object.prototype.hasOwnProperty,gD=Oo();ex.exports=gD.call(hD,yD)});var ra=U((RH,ax)=>{"use strict";var ee,vD=yh(),_D=Hb(),bD=Kb(),PD=Xb(),xD=Qb(),No=tP(),$o=tr(),SD=nP(),TD=aP(),ED=cP(),ID=pP(),AD=dP(),kD=fP(),wD=yP(),OD=bP(),nx=Function,Eh=s(function(e){try{return nx('"use strict"; return ('+e+").constructor;")()}catch{}},"getEvalledConstructor"),Qi=gh(),RD=EP(),Ih=s(function(){throw new $o},"throwTypeError"),CD=Qi?(function(){try{return arguments.callee,Ih}catch{try{return Qi(arguments,"callee").get}catch{return Ih}}})():Ih,Ro=wP()(),$e=QP(),$D=bh(),ND=_h(),ix=Ph(),ea=wu(),Co={},DD=typeof Uint8Array>"u"||!$e?ee:$e(Uint8Array),Lr={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?ee:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?ee:ArrayBuffer,"%ArrayIteratorPrototype%":Ro&&$e?$e([][Symbol.iterator]()):ee,"%AsyncFromSyncIteratorPrototype%":ee,"%AsyncFunction%":Co,"%AsyncGenerator%":Co,"%AsyncGeneratorFunction%":Co,"%AsyncIteratorPrototype%":Co,"%Atomics%":typeof Atomics>"u"?ee:Atomics,"%BigInt%":typeof BigInt>"u"?ee:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?ee:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?ee:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?ee:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":_D,"%eval%":eval,"%EvalError%":bD,"%Float16Array%":typeof Float16Array>"u"?ee:Float16Array,"%Float32Array%":typeof Float32Array>"u"?ee:Float32Array,"%Float64Array%":typeof Float64Array>"u"?ee:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?ee:FinalizationRegistry,"%Function%":nx,"%GeneratorFunction%":Co,"%Int8Array%":typeof Int8Array>"u"?ee:Int8Array,"%Int16Array%":typeof Int16Array>"u"?ee:Int16Array,"%Int32Array%":typeof Int32Array>"u"?ee:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Ro&&$e?$e($e([][Symbol.iterator]())):ee,"%JSON%":typeof JSON=="object"?JSON:ee,"%Map%":typeof Map>"u"?ee:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Ro||!$e?ee:$e(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":vD,"%Object.getOwnPropertyDescriptor%":Qi,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?ee:Promise,"%Proxy%":typeof Proxy>"u"?ee:Proxy,"%RangeError%":PD,"%ReferenceError%":xD,"%Reflect%":typeof Reflect>"u"?ee:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?ee:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Ro||!$e?ee:$e(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?ee:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Ro&&$e?$e(""[Symbol.iterator]()):ee,"%Symbol%":Ro?Symbol:ee,"%SyntaxError%":No,"%ThrowTypeError%":CD,"%TypedArray%":DD,"%TypeError%":$o,"%Uint8Array%":typeof Uint8Array>"u"?ee:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?ee:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?ee:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?ee:Uint32Array,"%URIError%":SD,"%WeakMap%":typeof WeakMap>"u"?ee:WeakMap,"%WeakRef%":typeof WeakRef>"u"?ee:WeakRef,"%WeakSet%":typeof WeakSet>"u"?ee:WeakSet,"%Function.prototype.call%":ea,"%Function.prototype.apply%":ix,"%Object.defineProperty%":RD,"%Object.getPrototypeOf%":$D,"%Math.abs%":TD,"%Math.floor%":ED,"%Math.max%":ID,"%Math.min%":AD,"%Math.pow%":kD,"%Math.round%":wD,"%Math.sign%":OD,"%Reflect.getPrototypeOf%":ND};if($e)try{null.error}catch(e){tx=$e($e(e)),Lr["%Error.prototype%"]=tx}var tx,zD=s(function e(t){var o;if(t==="%AsyncFunction%")o=Eh("async function () {}");else if(t==="%GeneratorFunction%")o=Eh("function* () {}");else if(t==="%AsyncGeneratorFunction%")o=Eh("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(o=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var r=e("%AsyncGenerator%");r&&$e&&(o=$e(r.prototype))}return Lr[t]=o,o},"doEval"),rx={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},ta=Oo(),Ou=Th(),MD=ta.call(ea,Array.prototype.concat),LD=ta.call(ix,Array.prototype.splice),ox=ta.call(ea,String.prototype.replace),Ru=ta.call(ea,String.prototype.slice),UD=ta.call(ea,RegExp.prototype.exec),qD=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,jD=/\\(\\)?/g,FD=s(function(t){var o=Ru(t,0,1),n=Ru(t,-1);if(o==="%"&&n!=="%")throw new No("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&o!=="%")throw new No("invalid intrinsic syntax, expected opening `%`");var r=[];return ox(t,qD,function(i,a,c,p){r[r.length]=c?ox(p,jD,"$1"):a||i}),r},"stringToPath"),BD=s(function(t,o){var n=t,r;if(Ou(rx,n)&&(r=rx[n],n="%"+r[0]+"%"),Ou(Lr,n)){var i=Lr[n];if(i===Co&&(i=zD(n)),typeof i>"u"&&!o)throw new $o("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:i}}throw new No("intrinsic "+t+" does not exist!")},"getBaseIntrinsic");ax.exports=s(function(t,o){if(typeof t!="string"||t.length===0)throw new $o("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof o!="boolean")throw new $o('"allowMissing" argument must be a boolean');if(UD(/^%?[^%]*%?$/,t)===null)throw new No("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=FD(t),r=n.length>0?n[0]:"",i=BD("%"+r+"%",o),a=i.name,c=i.value,p=!1,m=i.alias;m&&(r=m[0],LD(n,MD([0,1],m)));for(var l=1,g=!0;l<n.length;l+=1){var h=n[l],f=Ru(h,0,1),v=Ru(h,-1);if((f==='"'||f==="'"||f==="`"||v==='"'||v==="'"||v==="`")&&f!==v)throw new No("property names with quotes must have matching quotes");if((h==="constructor"||!g)&&(p=!0),r+="."+h,a="%"+r+"%",Ou(Lr,a))c=Lr[a];else if(c!=null){if(!(h in c)){if(!o)throw new $o("base intrinsic for "+t+" exists, but the property is not available.");return}if(Qi&&l+1>=n.length){var I=Qi(c,h);g=!!I,g&&"get"in I&&!("originalValue"in I.get)?c=I.get:c=c[h]}else g=Ou(c,h),c=c[h];g&&!p&&(Lr[a]=c)}}return c},"GetIntrinsic")});var cx=U(($H,sx)=>{"use strict";var ZD=vh();sx.exports=s(function(){return ZD()&&!!Symbol.toStringTag},"hasToStringTagShams")});var lx=U((DH,px)=>{"use strict";var VD=ra(),ux=VD("%Object.defineProperty%",!0),GD=cx()(),HD=Th(),WD=tr(),Cu=GD?Symbol.toStringTag:null;px.exports=s(function(t,o){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,r=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!="boolean"||typeof r<"u"&&typeof r!="boolean")throw new WD("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");Cu&&(n||!HD(t,Cu))&&(ux?ux(t,Cu,{configurable:!r,enumerable:!1,value:o,writable:!1}):t[Cu]=o)},"setToStringTag")});var mx=U((MH,dx)=>{"use strict";var KD=Function.prototype.call,JD=Object.prototype.hasOwnProperty,XD=Oo();dx.exports=XD.call(KD,JD)});var hx=U((LH,fx)=>{"use strict";fx.exports=function(e,t){return Object.keys(t).forEach(function(o){e[o]=e[o]||t[o]}),e}});var vx=U((UH,gx)=>{"use strict";var Oh=xb(),YD=require("util"),Ah=require("path"),QD=require("http"),ez=require("https"),tz=require("url").parse,rz=require("fs"),oz=require("stream").Stream,nz=require("crypto"),kh=Ab(),iz=Zb(),az=lx(),rr=mx(),wh=hx();function yx(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}s(yx,"escapeHeaderParam");function oe(e){if(!(this instanceof oe))return new oe(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],Oh.call(this),e=e||{};for(var t in e)this[t]=e[t]}s(oe,"FormData");YD.inherits(oe,Oh);oe.LINE_BREAK=`\r
|
|
2
|
+
`;oe.DEFAULT_CONTENT_TYPE="application/octet-stream";oe.prototype.append=function(e,t,o){o=o||{},typeof o=="string"&&(o={filename:o});var n=Oh.prototype.append.bind(this);if((typeof t=="number"||t==null)&&(t=String(t)),Array.isArray(t)){this._error(new Error("Arrays are not supported."));return}var r=this._multiPartHeader(e,t,o),i=this._multiPartFooter();n(r),n(t),n(i),this._trackLength(r,t,o)};oe.prototype._trackLength=function(e,t,o){var n=0;o.knownLength!=null?n+=Number(o.knownLength):Buffer.isBuffer(t)?n=t.length:typeof t=="string"&&(n=Buffer.byteLength(t)),this._valueLength+=n,this._overheadLength+=Buffer.byteLength(e)+oe.LINE_BREAK.length,!(!t||!t.path&&!(t.readable&&rr(t,"httpVersion"))&&!(t instanceof oz))&&(o.knownLength||this._valuesToMeasure.push(t))};oe.prototype._lengthRetriever=function(e,t){rr(e,"fd")?e.end!=null&&e.end!=1/0&&e.start!=null?t(null,e.end+1-(e.start?e.start:0)):rz.stat(e.path,function(o,n){if(o){t(o);return}var r=n.size-(e.start?e.start:0);t(null,r)}):rr(e,"httpVersion")?t(null,Number(e.headers["content-length"])):rr(e,"httpModule")?(e.on("response",function(o){e.pause(),t(null,Number(o.headers["content-length"]))}),e.resume()):t("Unknown stream")};oe.prototype._multiPartHeader=function(e,t,o){if(typeof o.header=="string")return o.header;var n=this._getContentDisposition(t,o),r=this._getContentType(t,o),i="",a={"Content-Disposition":["form-data",'name="'+yx(e)+'"'].concat(n||[]),"Content-Type":[].concat(r||[])};typeof o.header=="object"&&wh(a,o.header);var c;for(var p in a)if(rr(a,p)){if(c=a[p],c==null)continue;Array.isArray(c)||(c=[c]),c.length&&(i+=p+": "+c.join("; ")+oe.LINE_BREAK)}return"--"+this.getBoundary()+oe.LINE_BREAK+i+oe.LINE_BREAK};oe.prototype._getContentDisposition=function(e,t){var o;if(typeof t.filepath=="string"?o=Ah.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e&&(e.name||e.path)?o=Ah.basename(t.filename||e&&(e.name||e.path)):e&&e.readable&&rr(e,"httpVersion")&&(o=Ah.basename(e.client._httpMessage.path||"")),o)return'filename="'+yx(o)+'"'};oe.prototype._getContentType=function(e,t){var o=t.contentType;return!o&&e&&e.name&&(o=kh.lookup(e.name)),!o&&e&&e.path&&(o=kh.lookup(e.path)),!o&&e&&e.readable&&rr(e,"httpVersion")&&(o=e.headers["content-type"]),!o&&(t.filepath||t.filename)&&(o=kh.lookup(t.filepath||t.filename)),!o&&e&&typeof e=="object"&&(o=oe.DEFAULT_CONTENT_TYPE),o};oe.prototype._multiPartFooter=function(){return function(e){var t=oe.LINE_BREAK,o=this._streams.length===0;o&&(t+=this._lastBoundary()),e(t)}.bind(this)};oe.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+oe.LINE_BREAK};oe.prototype.getHeaders=function(e){var t,o={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)rr(e,t)&&(o[t.toLowerCase()]=e[t]);return o};oe.prototype.setBoundary=function(e){if(typeof e!="string")throw new TypeError("FormData boundary must be a string");this._boundary=e};oe.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary};oe.prototype.getBuffer=function(){for(var e=new Buffer.alloc(0),t=this.getBoundary(),o=0,n=this._streams.length;o<n;o++)typeof this._streams[o]!="function"&&(Buffer.isBuffer(this._streams[o])?e=Buffer.concat([e,this._streams[o]]):e=Buffer.concat([e,Buffer.from(this._streams[o])]),(typeof this._streams[o]!="string"||this._streams[o].substring(2,t.length+2)!==t)&&(e=Buffer.concat([e,Buffer.from(oe.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])};oe.prototype._generateBoundary=function(){this._boundary="--------------------------"+nz.randomBytes(12).toString("hex")};oe.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;return this._streams.length&&(e+=this._lastBoundary().length),this.hasKnownLength()||this._error(new Error("Cannot calculate proper length in synchronous way.")),e};oe.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e};oe.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;if(this._streams.length&&(t+=this._lastBoundary().length),!this._valuesToMeasure.length){process.nextTick(e.bind(this,null,t));return}iz.parallel(this._valuesToMeasure,this._lengthRetriever,function(o,n){if(o){e(o);return}n.forEach(function(r){t+=r}),e(null,t)})};oe.prototype.submit=function(e,t){var o,n,r={method:"post"};return typeof e=="string"?(e=tz(e),n=wh({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},r)):(n=wh(e,r),n.port||(n.port=n.protocol==="https:"?443:80)),n.headers=this.getHeaders(e.headers),n.protocol==="https:"?o=ez.request(n):o=QD.request(n),this.getLength(function(i,a){if(i&&i!=="Unknown stream"){this._error(i);return}if(a&&o.setHeader("Content-Length",a),this.pipe(o),t){var c,p=s(function(m,l){return o.removeListener("error",p),o.removeListener("response",c),t.call(this,m,l)},"callback");c=p.bind(this,null),o.on("error",p),o.on("response",c)}}.bind(this)),o};oe.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))};oe.prototype.toString=function(){return"[object FormData]"};az(oe.prototype,"FormData");gx.exports=oe});var vS=U((CW,gS)=>{gS.exports=require("util").inspect});var ca=U(($W,LS)=>{var Jh=typeof Map=="function"&&Map.prototype,jh=Object.getOwnPropertyDescriptor&&Jh?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Bu=Jh&&jh&&typeof jh.get=="function"?jh.get:null,_S=Jh&&Map.prototype.forEach,Xh=typeof Set=="function"&&Set.prototype,Fh=Object.getOwnPropertyDescriptor&&Xh?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Zu=Xh&&Fh&&typeof Fh.get=="function"?Fh.get:null,bS=Xh&&Set.prototype.forEach,bz=typeof WeakMap=="function"&&WeakMap.prototype,ia=bz?WeakMap.prototype.has:null,Pz=typeof WeakSet=="function"&&WeakSet.prototype,aa=Pz?WeakSet.prototype.has:null,xz=typeof WeakRef=="function"&&WeakRef.prototype,PS=xz?WeakRef.prototype.deref:null,Sz=Boolean.prototype.valueOf,Tz=Object.prototype.toString,Ez=Function.prototype.toString,Iz=String.prototype.match,Yh=String.prototype.slice,ur=String.prototype.replace,Az=String.prototype.toUpperCase,xS=String.prototype.toLowerCase,RS=RegExp.prototype.test,SS=Array.prototype.concat,Pt=Array.prototype.join,kz=Array.prototype.slice,TS=Math.floor,Vh=typeof BigInt=="function"?BigInt.prototype.valueOf:null,Bh=Object.getOwnPropertySymbols,Gh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,jo=typeof Symbol=="function"&&typeof Symbol.iterator=="object",sa=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===jo||!0)?Symbol.toStringTag:null,CS=Object.prototype.propertyIsEnumerable,ES=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function IS(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||RS.call(/e/,t))return t;var o=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-TS(-e):TS(e);if(n!==e){var r=String(n),i=Yh.call(t,r.length+1);return ur.call(r,o,"$&_")+"."+ur.call(ur.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return ur.call(t,o,"$&_")}s(IS,"addNumericSeparator");var Hh=vS(),AS=Hh.custom,kS=DS(AS)?AS:null,$S={__proto__:null,double:'"',single:"'"},wz={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};LS.exports=s(function e(t,o,n,r){var i=o||{};if(Mt(i,"quoteStyle")&&!Mt($S,i.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(Mt(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var a=Mt(i,"customInspect")?i.customInspect:!0;if(typeof a!="boolean"&&a!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(Mt(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(Mt(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var c=i.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return MS(t,i);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var p=String(t);return c?IS(t,p):p}if(typeof t=="bigint"){var m=String(t)+"n";return c?IS(t,m):m}var l=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=l&&l>0&&typeof t=="object")return Wh(t)?"[Array]":"[Object]";var g=Hz(i,n);if(typeof r>"u")r=[];else if(zS(r,t)>=0)return"[Circular]";function h(Ze,ut,Xe){if(ut&&(r=kz.call(r),r.push(ut)),Xe){var sn={depth:i.depth};return Mt(i,"quoteStyle")&&(sn.quoteStyle=i.quoteStyle),e(Ze,sn,n+1,r)}return e(Ze,i,n+1,r)}if(s(h,"inspect"),typeof t=="function"&&!wS(t)){var f=Lz(t),v=Fu(t,h);return"[Function"+(f?": "+f:" (anonymous)")+"]"+(v.length>0?" { "+Pt.call(v,", ")+" }":"")}if(DS(t)){var I=jo?ur.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):Gh.call(t);return typeof t=="object"&&!jo?na(I):I}if(Zz(t)){for(var T="<"+xS.call(String(t.nodeName)),x=t.attributes||[],k=0;k<x.length;k++)T+=" "+x[k].name+"="+NS(Oz(x[k].value),"double",i);return T+=">",t.childNodes&&t.childNodes.length&&(T+="..."),T+="</"+xS.call(String(t.nodeName))+">",T}if(Wh(t)){if(t.length===0)return"[]";var R=Fu(t,h);return g&&!Gz(R)?"["+Kh(R,g)+"]":"[ "+Pt.call(R,", ")+" ]"}if(Cz(t)){var q=Fu(t,h);return!("cause"in Error.prototype)&&"cause"in t&&!CS.call(t,"cause")?"{ ["+String(t)+"] "+Pt.call(SS.call("[cause]: "+h(t.cause),q),", ")+" }":q.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+Pt.call(q,", ")+" }"}if(typeof t=="object"&&a){if(kS&&typeof t[kS]=="function"&&Hh)return Hh(t,{depth:l-n});if(a!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(Uz(t)){var Q=[];return _S&&_S.call(t,function(Ze,ut){Q.push(h(ut,t,!0)+" => "+h(Ze,t))}),OS("Map",Bu.call(t),Q,g)}if(Fz(t)){var we=[];return bS&&bS.call(t,function(Ze){we.push(h(Ze,t))}),OS("Set",Zu.call(t),we,g)}if(qz(t))return Zh("WeakMap");if(Bz(t))return Zh("WeakSet");if(jz(t))return Zh("WeakRef");if(Nz(t))return na(h(Number(t)));if(zz(t))return na(h(Vh.call(t)));if(Dz(t))return na(Sz.call(t));if($z(t))return na(h(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(typeof globalThis<"u"&&t===globalThis||typeof global<"u"&&t===global)return"{ [object globalThis] }";if(!Rz(t)&&!wS(t)){var Pe=Fu(t,h),he=ES?ES(t)===Object.prototype:t instanceof Object||t.constructor===Object,pe=t instanceof Object?"":"null prototype",xe=!he&&sa&&Object(t)===t&&sa in t?Yh.call(pr(t),8,-1):pe?"Object":"",ct=he||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",At=ct+(xe||pe?"["+Pt.call(SS.call([],xe||[],pe||[]),": ")+"] ":"");return Pe.length===0?At+"{}":g?At+"{"+Kh(Pe,g)+"}":At+"{ "+Pt.call(Pe,", ")+" }"}return String(t)},"inspect_");function NS(e,t,o){var n=o.quoteStyle||t,r=$S[n];return r+e+r}s(NS,"wrapQuotes");function Oz(e){return ur.call(String(e),/"/g,""")}s(Oz,"quote");function Ur(e){return!sa||!(typeof e=="object"&&(sa in e||typeof e[sa]<"u"))}s(Ur,"canTrustToString");function Wh(e){return pr(e)==="[object Array]"&&Ur(e)}s(Wh,"isArray");function Rz(e){return pr(e)==="[object Date]"&&Ur(e)}s(Rz,"isDate");function wS(e){return pr(e)==="[object RegExp]"&&Ur(e)}s(wS,"isRegExp");function Cz(e){return pr(e)==="[object Error]"&&Ur(e)}s(Cz,"isError");function $z(e){return pr(e)==="[object String]"&&Ur(e)}s($z,"isString");function Nz(e){return pr(e)==="[object Number]"&&Ur(e)}s(Nz,"isNumber");function Dz(e){return pr(e)==="[object Boolean]"&&Ur(e)}s(Dz,"isBoolean");function DS(e){if(jo)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!Gh)return!1;try{return Gh.call(e),!0}catch{}return!1}s(DS,"isSymbol");function zz(e){if(!e||typeof e!="object"||!Vh)return!1;try{return Vh.call(e),!0}catch{}return!1}s(zz,"isBigInt");var Mz=Object.prototype.hasOwnProperty||function(e){return e in this};function Mt(e,t){return Mz.call(e,t)}s(Mt,"has");function pr(e){return Tz.call(e)}s(pr,"toStr");function Lz(e){if(e.name)return e.name;var t=Iz.call(Ez.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}s(Lz,"nameOf");function zS(e,t){if(e.indexOf)return e.indexOf(t);for(var o=0,n=e.length;o<n;o++)if(e[o]===t)return o;return-1}s(zS,"indexOf");function Uz(e){if(!Bu||!e||typeof e!="object")return!1;try{Bu.call(e);try{Zu.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}s(Uz,"isMap");function qz(e){if(!ia||!e||typeof e!="object")return!1;try{ia.call(e,ia);try{aa.call(e,aa)}catch{return!0}return e instanceof WeakMap}catch{}return!1}s(qz,"isWeakMap");function jz(e){if(!PS||!e||typeof e!="object")return!1;try{return PS.call(e),!0}catch{}return!1}s(jz,"isWeakRef");function Fz(e){if(!Zu||!e||typeof e!="object")return!1;try{Zu.call(e);try{Bu.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}s(Fz,"isSet");function Bz(e){if(!aa||!e||typeof e!="object")return!1;try{aa.call(e,aa);try{ia.call(e,ia)}catch{return!0}return e instanceof WeakSet}catch{}return!1}s(Bz,"isWeakSet");function Zz(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}s(Zz,"isElement");function MS(e,t){if(e.length>t.maxStringLength){var o=e.length-t.maxStringLength,n="... "+o+" more character"+(o>1?"s":"");return MS(Yh.call(e,0,t.maxStringLength),t)+n}var r=wz[t.quoteStyle||"single"];r.lastIndex=0;var i=ur.call(ur.call(e,r,"\\$1"),/[\x00-\x1f]/g,Vz);return NS(i,"single",t)}s(MS,"inspectString");function Vz(e){var t=e.charCodeAt(0),o={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return o?"\\"+o:"\\x"+(t<16?"0":"")+Az.call(t.toString(16))}s(Vz,"lowbyte");function na(e){return"Object("+e+")"}s(na,"markBoxed");function Zh(e){return e+" { ? }"}s(Zh,"weakCollectionOf");function OS(e,t,o,n){var r=n?Kh(o,n):Pt.call(o,", ");return e+" ("+t+") {"+r+"}"}s(OS,"collectionOf");function Gz(e){for(var t=0;t<e.length;t++)if(zS(e[t],`
|
|
3
|
+
`)>=0)return!1;return!0}s(Gz,"singleLineValues");function Hz(e,t){var o;if(e.indent===" ")o=" ";else if(typeof e.indent=="number"&&e.indent>0)o=Pt.call(Array(e.indent+1)," ");else return null;return{base:o,prev:Pt.call(Array(t+1),o)}}s(Hz,"getIndent");function Kh(e,t){if(e.length===0)return"";var o=`
|
|
4
|
+
`+t.prev+t.base;return o+Pt.call(e,","+o)+`
|
|
5
|
+
`+t.prev}s(Kh,"indentedJoin");function Fu(e,t){var o=Wh(e),n=[];if(o){n.length=e.length;for(var r=0;r<e.length;r++)n[r]=Mt(e,r)?t(e[r],e):""}var i=typeof Bh=="function"?Bh(e):[],a;if(jo){a={};for(var c=0;c<i.length;c++)a["$"+i[c]]=i[c]}for(var p in e)Mt(e,p)&&(o&&String(Number(p))===p&&p<e.length||jo&&a["$"+p]instanceof Symbol||(RS.call(/[^\w$]/,p)?n.push(t(p,e)+": "+t(e[p],e)):n.push(p+": "+t(e[p],e))));if(typeof Bh=="function")for(var m=0;m<i.length;m++)CS.call(e,i[m])&&n.push("["+t(i[m])+"]: "+t(e[i[m]],e));return n}s(Fu,"arrObjKeys")});var qS=U((DW,US)=>{"use strict";var Wz=ca(),Kz=tr(),Vu=s(function(e,t,o){for(var n=e,r;(r=n.next)!=null;n=r)if(r.key===t)return n.next=r.next,o||(r.next=e.next,e.next=r),r},"listGetNode"),Jz=s(function(e,t){if(e){var o=Vu(e,t);return o&&o.value}},"listGet"),Xz=s(function(e,t,o){var n=Vu(e,t);n?n.value=o:e.next={key:t,next:e.next,value:o}},"listSet"),Yz=s(function(e,t){return e?!!Vu(e,t):!1},"listHas"),Qz=s(function(e,t){if(e)return Vu(e,t,!0)},"listDelete");US.exports=s(function(){var t,o={assert:s(function(n){if(!o.has(n))throw new Kz("Side channel does not contain "+Wz(n))},"assert"),delete:s(function(n){var r=Qz(t,n);return r&&t&&!t.next&&(t=void 0),!!r},"delete"),get:s(function(n){return Jz(t,n)},"get"),has:s(function(n){return Yz(t,n)},"has"),set:s(function(n,r){t||(t={next:void 0}),Xz(t,n,r)},"set")};return o},"getSideChannelList")});var Qh=U((MW,BS)=>{"use strict";var jS=ra(),FS=xh(),eM=FS([jS("%String.prototype.indexOf%")]);BS.exports=s(function(t,o){var n=jS(t,!!o);return typeof n=="function"&&eM(t,".prototype.")>-1?FS([n]):n},"callBoundIntrinsic")});var ey=U((UW,VS)=>{"use strict";var tM=ra(),ua=Qh(),rM=ca(),oM=tr(),ZS=tM("%Map%",!0),nM=ua("Map.prototype.get",!0),iM=ua("Map.prototype.set",!0),aM=ua("Map.prototype.has",!0),sM=ua("Map.prototype.delete",!0),cM=ua("Map.prototype.size",!0);VS.exports=!!ZS&&s(function(){var t,o={assert:s(function(n){if(!o.has(n))throw new oM("Side channel does not contain "+rM(n))},"assert"),delete:s(function(n){if(t){var r=sM(t,n);return cM(t)===0&&(t=void 0),r}return!1},"delete"),get:s(function(n){if(t)return nM(t,n)},"get"),has:s(function(n){return t?aM(t,n):!1},"has"),set:s(function(n,r){t||(t=new ZS),iM(t,n,r)},"set")};return o},"getSideChannelMap")});var HS=U((jW,GS)=>{"use strict";var uM=ra(),Hu=Qh(),pM=ca(),Gu=ey(),lM=tr(),Fo=uM("%WeakMap%",!0),dM=Hu("WeakMap.prototype.get",!0),mM=Hu("WeakMap.prototype.set",!0),fM=Hu("WeakMap.prototype.has",!0),hM=Hu("WeakMap.prototype.delete",!0);GS.exports=Fo?s(function(){var t,o,n={assert:s(function(r){if(!n.has(r))throw new lM("Side channel does not contain "+pM(r))},"assert"),delete:s(function(r){if(Fo&&r&&(typeof r=="object"||typeof r=="function")){if(t)return hM(t,r)}else if(Gu&&o)return o.delete(r);return!1},"delete"),get:s(function(r){return Fo&&r&&(typeof r=="object"||typeof r=="function")&&t?dM(t,r):o&&o.get(r)},"get"),has:s(function(r){return Fo&&r&&(typeof r=="object"||typeof r=="function")&&t?fM(t,r):!!o&&o.has(r)},"has"),set:s(function(r,i){Fo&&r&&(typeof r=="object"||typeof r=="function")?(t||(t=new Fo),mM(t,r,i)):Gu&&(o||(o=Gu()),o.set(r,i))},"set")};return n},"getSideChannelWeakMap"):Gu});var ty=U((BW,WS)=>{"use strict";var yM=tr(),gM=ca(),vM=qS(),_M=ey(),bM=HS(),PM=bM||_M||vM;WS.exports=s(function(){var t,o={assert:s(function(n){if(!o.has(n))throw new yM("Side channel does not contain "+gM(n))},"assert"),delete:s(function(n){return!!t&&t.delete(n)},"delete"),get:s(function(n){return t&&t.get(n)},"get"),has:s(function(n){return!!t&&t.has(n)},"has"),set:s(function(n,r){t||(t=PM()),t.set(n,r)},"set")};return o},"getSideChannel")});var Wu=U((VW,KS)=>{"use strict";var xM=String.prototype.replace,SM=/%20/g,ry={RFC1738:"RFC1738",RFC3986:"RFC3986"};KS.exports={default:ry.RFC3986,formatters:{RFC1738:s(function(e){return xM.call(e,SM,"+")},"RFC1738"),RFC3986:s(function(e){return String(e)},"RFC3986")},RFC1738:ry.RFC1738,RFC3986:ry.RFC3986}});var ay=U((HW,JS)=>{"use strict";var TM=Wu(),EM=ty(),oy=Object.prototype.hasOwnProperty,qr=Array.isArray,Ku=EM(),Bo=s(function(t,o){return Ku.set(t,o),t},"markOverflow"),jr=s(function(t){return Ku.has(t)},"isOverflow"),pa=s(function(t){return Ku.get(t)},"getMaxIndex"),iy=s(function(t,o){Ku.set(t,o)},"setMaxIndex"),xt=(function(){for(var e=[],t=0;t<256;++t)e[e.length]="%"+((t<16?"0":"")+t.toString(16)).toUpperCase();return e})(),IM=s(function(t){for(;t.length>1;){var o=t.pop(),n=o.obj[o.prop];if(qr(n)){for(var r=[],i=0;i<n.length;++i)typeof n[i]<"u"&&(r[r.length]=n[i]);o.obj[o.prop]=r}}},"compactQueue"),la=s(function(t,o){for(var n=o&&o.plainObjects?{__proto__:null}:{},r=0;r<t.length;++r)typeof t[r]<"u"&&(n[r]=t[r]);return n},"arrayToObject"),AM=s(function e(t,o,n){if(!o)return t;if(typeof o!="object"&&typeof o!="function"){if(qr(t)){var r=t.length;if(n&&typeof n.arrayLimit=="number"&&r>n.arrayLimit)return Bo(la(t.concat(o),n),r);t[r]=o}else if(t&&typeof t=="object")if(jr(t)){var i=pa(t)+1;t[i]=o,iy(t,i)}else(n&&(n.plainObjects||n.allowPrototypes)||!oy.call(Object.prototype,o))&&(t[o]=!0);else return[t,o];return t}if(!t||typeof t!="object"){if(jr(o)){for(var a=Object.keys(o),c=n&&n.plainObjects?{__proto__:null,0:t}:{0:t},p=0;p<a.length;p++){var m=parseInt(a[p],10);c[m+1]=o[a[p]]}return Bo(c,pa(o)+1)}var l=[t].concat(o);return n&&typeof n.arrayLimit=="number"&&l.length>n.arrayLimit?Bo(la(l,n),l.length-1):l}var g=t;return qr(t)&&!qr(o)&&(g=la(t,n)),qr(t)&&qr(o)?(o.forEach(function(h,f){if(oy.call(t,f)){var v=t[f];v&&typeof v=="object"&&h&&typeof h=="object"?t[f]=e(v,h,n):t[t.length]=h}else t[f]=h}),t):Object.keys(o).reduce(function(h,f){var v=o[f];if(oy.call(h,f)?h[f]=e(h[f],v,n):h[f]=v,jr(o)&&!jr(h)&&Bo(h,pa(o)),jr(h)){var I=parseInt(f,10);String(I)===f&&I>=0&&I>pa(h)&&iy(h,I)}return h},g)},"merge"),kM=s(function(t,o){return Object.keys(o).reduce(function(n,r){return n[r]=o[r],n},t)},"assignSingleSource"),wM=s(function(e,t,o){var n=e.replace(/\+/g," ");if(o==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},"decode"),ny=1024,OM=s(function(t,o,n,r,i){if(t.length===0)return t;var a=t;if(typeof t=="symbol"?a=Symbol.prototype.toString.call(t):typeof t!="string"&&(a=String(t)),n==="iso-8859-1")return escape(a).replace(/%u[0-9a-f]{4}/gi,function(f){return"%26%23"+parseInt(f.slice(2),16)+"%3B"});for(var c="",p=0;p<a.length;p+=ny){for(var m=a.length>=ny?a.slice(p,p+ny):a,l=[],g=0;g<m.length;++g){var h=m.charCodeAt(g);if(h===45||h===46||h===95||h===126||h>=48&&h<=57||h>=65&&h<=90||h>=97&&h<=122||i===TM.RFC1738&&(h===40||h===41)){l[l.length]=m.charAt(g);continue}if(h<128){l[l.length]=xt[h];continue}if(h<2048){l[l.length]=xt[192|h>>6]+xt[128|h&63];continue}if(h<55296||h>=57344){l[l.length]=xt[224|h>>12]+xt[128|h>>6&63]+xt[128|h&63];continue}g+=1,h=65536+((h&1023)<<10|m.charCodeAt(g)&1023),l[l.length]=xt[240|h>>18]+xt[128|h>>12&63]+xt[128|h>>6&63]+xt[128|h&63]}c+=l.join("")}return c},"encode"),RM=s(function(t){for(var o=[{obj:{o:t},prop:"o"}],n=[],r=0;r<o.length;++r)for(var i=o[r],a=i.obj[i.prop],c=Object.keys(a),p=0;p<c.length;++p){var m=c[p],l=a[m];typeof l=="object"&&l!==null&&n.indexOf(l)===-1&&(o[o.length]={obj:a,prop:m},n[n.length]=l)}return IM(o),t},"compact"),CM=s(function(t){return Object.prototype.toString.call(t)==="[object RegExp]"},"isRegExp"),$M=s(function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},"isBuffer"),NM=s(function(t,o,n,r){if(jr(t)){var i=pa(t)+1;return t[i]=o,iy(t,i),t}var a=[].concat(t,o);return a.length>n?Bo(la(a,{plainObjects:r}),a.length-1):a},"combine"),DM=s(function(t,o){if(qr(t)){for(var n=[],r=0;r<t.length;r+=1)n[n.length]=o(t[r]);return n}return o(t)},"maybeMap");JS.exports={arrayToObject:la,assign:kM,combine:NM,compact:RM,decode:wM,encode:OM,isBuffer:$M,isOverflow:jr,isRegExp:CM,markOverflow:Bo,maybeMap:DM,merge:AM}});var rT=U((KW,tT)=>{"use strict";var YS=ty(),Ju=ay(),da=Wu(),zM=Object.prototype.hasOwnProperty,QS={brackets:s(function(t){return t+"[]"},"brackets"),comma:"comma",indices:s(function(t,o){return t+"["+o+"]"},"indices"),repeat:s(function(t){return t},"repeat")},St=Array.isArray,MM=Array.prototype.push,eT=s(function(e,t){MM.apply(e,St(t)?t:[t])},"pushToArray"),LM=Date.prototype.toISOString,XS=da.default,ke={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Ju.encode,encodeValuesOnly:!1,filter:void 0,format:XS,formatter:da.formatters[XS],indices:!1,serializeDate:s(function(t){return LM.call(t)},"serializeDate"),skipNulls:!1,strictNullHandling:!1},UM=s(function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},"isNonNullishPrimitive"),sy={},qM=s(function e(t,o,n,r,i,a,c,p,m,l,g,h,f,v,I,T,x,k){for(var R=t,q=k,Q=0,we=!1;(q=q.get(sy))!==void 0&&!we;){var Pe=q.get(t);if(Q+=1,typeof Pe<"u"){if(Pe===Q)throw new RangeError("Cyclic object value");we=!0}typeof q.get(sy)>"u"&&(Q=0)}if(typeof l=="function"?R=l(o,R):R instanceof Date?R=f(R):n==="comma"&&St(R)&&(R=Ju.maybeMap(R,function(qp){return qp instanceof Date?f(qp):qp})),R===null){if(a)return m&&!T?m(o,ke.encoder,x,"key",v):o;R=""}if(UM(R)||Ju.isBuffer(R)){if(m){var he=T?o:m(o,ke.encoder,x,"key",v);return[I(he)+"="+I(m(R,ke.encoder,x,"value",v))]}return[I(o)+"="+I(String(R))]}var pe=[];if(typeof R>"u")return pe;var xe;if(n==="comma"&&St(R))T&&m&&(R=Ju.maybeMap(R,m)),xe=[{value:R.length>0?R.join(",")||null:void 0}];else if(St(l))xe=l;else{var ct=Object.keys(R);xe=g?ct.sort(g):ct}var At=p?String(o).replace(/\./g,"%2E"):String(o),Ze=r&&St(R)&&R.length===1?At+"[]":At;if(i&&St(R)&&R.length===0)return Ze+"[]";for(var ut=0;ut<xe.length;++ut){var Xe=xe[ut],sn=typeof Xe=="object"&&Xe&&typeof Xe.value<"u"?Xe.value:R[Xe];if(!(c&&sn===null)){var Up=h&&p?String(Xe).replace(/\./g,"%2E"):String(Xe),Ew=St(R)?typeof n=="function"?n(Ze,Up):Ze:Ze+(h?"."+Up:"["+Up+"]");k.set(t,Q);var Dy=YS();Dy.set(sy,k),eT(pe,e(sn,Ew,n,r,i,a,c,p,n==="comma"&&T&&St(R)?null:m,l,g,h,f,v,I,T,x,Dy))}}return pe},"stringify"),jM=s(function(t){if(!t)return ke;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.encodeDotInKeys<"u"&&typeof t.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(t.encoder!==null&&typeof t.encoder<"u"&&typeof t.encoder!="function")throw new TypeError("Encoder has to be a function.");var o=t.charset||ke.charset;if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=da.default;if(typeof t.format<"u"){if(!zM.call(da.formatters,t.format))throw new TypeError("Unknown format option provided.");n=t.format}var r=da.formatters[n],i=ke.filter;(typeof t.filter=="function"||St(t.filter))&&(i=t.filter);var a;if(t.arrayFormat in QS?a=t.arrayFormat:"indices"in t?a=t.indices?"indices":"repeat":a=ke.arrayFormat,"commaRoundTrip"in t&&typeof t.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var c=typeof t.allowDots>"u"?t.encodeDotInKeys===!0?!0:ke.allowDots:!!t.allowDots;return{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:ke.addQueryPrefix,allowDots:c,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:ke.allowEmptyArrays,arrayFormat:a,charset:o,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:ke.charsetSentinel,commaRoundTrip:!!t.commaRoundTrip,delimiter:typeof t.delimiter>"u"?ke.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:ke.encode,encodeDotInKeys:typeof t.encodeDotInKeys=="boolean"?t.encodeDotInKeys:ke.encodeDotInKeys,encoder:typeof t.encoder=="function"?t.encoder:ke.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:ke.encodeValuesOnly,filter:i,format:n,formatter:r,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:ke.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:ke.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:ke.strictNullHandling}},"normalizeStringifyOptions");tT.exports=function(e,t){var o=e,n=jM(t),r,i;typeof n.filter=="function"?(i=n.filter,o=i("",o)):St(n.filter)&&(i=n.filter,r=i);var a=[];if(typeof o!="object"||o===null)return"";var c=QS[n.arrayFormat],p=c==="comma"&&n.commaRoundTrip;r||(r=Object.keys(o)),n.sort&&r.sort(n.sort);for(var m=YS(),l=0;l<r.length;++l){var g=r[l],h=o[g];n.skipNulls&&h===null||eT(a,qM(h,g,c,p,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,m))}var f=a.join(n.delimiter),v=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?v+="utf8=%26%2310003%3B&":v+="utf8=%E2%9C%93&"),f.length>0?v+f:""}});var iT=U((XW,nT)=>{"use strict";var Tt=ay(),Xu=Object.prototype.hasOwnProperty,cy=Array.isArray,ve={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:Tt.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1,throwOnLimitExceeded:!1},FM=s(function(e){return e.replace(/&#(\d+);/g,function(t,o){return String.fromCharCode(parseInt(o,10))})},"interpretNumericEntities"),oT=s(function(e,t,o){if(e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1)return e.split(",");if(t.throwOnLimitExceeded&&o>=t.arrayLimit)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");return e},"parseArrayValue"),BM="utf8=%26%2310003%3B",ZM="utf8=%E2%9C%93",VM=s(function(t,o){var n={__proto__:null},r=o.ignoreQueryPrefix?t.replace(/^\?/,""):t;r=r.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var i=o.parameterLimit===1/0?void 0:o.parameterLimit,a=r.split(o.delimiter,o.throwOnLimitExceeded?i+1:i);if(o.throwOnLimitExceeded&&a.length>i)throw new RangeError("Parameter limit exceeded. Only "+i+" parameter"+(i===1?"":"s")+" allowed.");var c=-1,p,m=o.charset;if(o.charsetSentinel)for(p=0;p<a.length;++p)a[p].indexOf("utf8=")===0&&(a[p]===ZM?m="utf-8":a[p]===BM&&(m="iso-8859-1"),c=p,p=a.length);for(p=0;p<a.length;++p)if(p!==c){var l=a[p],g=l.indexOf("]="),h=g===-1?l.indexOf("="):g+1,f,v;if(h===-1?(f=o.decoder(l,ve.decoder,m,"key"),v=o.strictNullHandling?null:""):(f=o.decoder(l.slice(0,h),ve.decoder,m,"key"),f!==null&&(v=Tt.maybeMap(oT(l.slice(h+1),o,cy(n[f])?n[f].length:0),function(T){return o.decoder(T,ve.decoder,m,"value")}))),v&&o.interpretNumericEntities&&m==="iso-8859-1"&&(v=FM(String(v))),l.indexOf("[]=")>-1&&(v=cy(v)?[v]:v),o.comma&&cy(v)&&v.length>o.arrayLimit){if(o.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+o.arrayLimit+" element"+(o.arrayLimit===1?"":"s")+" allowed in an array.");v=Tt.combine([],v,o.arrayLimit,o.plainObjects)}if(f!==null){var I=Xu.call(n,f);I&&o.duplicates==="combine"?n[f]=Tt.combine(n[f],v,o.arrayLimit,o.plainObjects):(!I||o.duplicates==="last")&&(n[f]=v)}}return n},"parseQueryStringValues"),GM=s(function(e,t,o,n){var r=0;if(e.length>0&&e[e.length-1]==="[]"){var i=e.slice(0,-1).join("");r=Array.isArray(t)&&t[i]?t[i].length:0}for(var a=n?t:oT(t,o,r),c=e.length-1;c>=0;--c){var p,m=e[c];if(m==="[]"&&o.parseArrays)Tt.isOverflow(a)?p=a:p=o.allowEmptyArrays&&(a===""||o.strictNullHandling&&a===null)?[]:Tt.combine([],a,o.arrayLimit,o.plainObjects);else{p=o.plainObjects?{__proto__:null}:{};var l=m.charAt(0)==="["&&m.charAt(m.length-1)==="]"?m.slice(1,-1):m,g=o.decodeDotInKeys?l.replace(/%2E/g,"."):l,h=parseInt(g,10),f=!isNaN(h)&&m!==g&&String(h)===g&&h>=0&&o.parseArrays;if(!o.parseArrays&&g==="")p={0:a};else if(f&&h<o.arrayLimit)p=[],p[h]=a;else{if(f&&o.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+o.arrayLimit+" element"+(o.arrayLimit===1?"":"s")+" allowed in an array.");f?(p[h]=a,Tt.markOverflow(p,h)):g!=="__proto__"&&(p[g]=a)}}a=p}return a},"parseObject"),HM=s(function(t,o){var n=o.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t;if(o.depth<=0)return!o.plainObjects&&Xu.call(Object.prototype,n)&&!o.allowPrototypes?void 0:[n];var r=/(\[[^[\]]*])/,i=/(\[[^[\]]*])/g,a=r.exec(n),c=a?n.slice(0,a.index):n,p=[];if(c){if(!o.plainObjects&&Xu.call(Object.prototype,c)&&!o.allowPrototypes)return;p[p.length]=c}for(var m=0;(a=i.exec(n))!==null&&m<o.depth;){m+=1;var l=a[1].slice(1,-1);if(!o.plainObjects&&Xu.call(Object.prototype,l)&&!o.allowPrototypes)return;p[p.length]=a[1]}if(a){if(o.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+o.depth+" and strictDepth is true");p[p.length]="["+n.slice(a.index)+"]"}return p},"splitKeyIntoSegments"),WM=s(function(t,o,n,r){if(t){var i=HM(t,n);if(i)return GM(i,o,n,r)}},"parseQueryStringKeys"),KM=s(function(t){if(!t)return ve;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.decodeDotInKeys<"u"&&typeof t.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(t.decoder!==null&&typeof t.decoder<"u"&&typeof t.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof t.throwOnLimitExceeded<"u"&&typeof t.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var o=typeof t.charset>"u"?ve.charset:t.charset,n=typeof t.duplicates>"u"?ve.duplicates:t.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var r=typeof t.allowDots>"u"?t.decodeDotInKeys===!0?!0:ve.allowDots:!!t.allowDots;return{allowDots:r,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:ve.allowEmptyArrays,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:ve.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:ve.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:ve.arrayLimit,charset:o,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:ve.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:ve.comma,decodeDotInKeys:typeof t.decodeDotInKeys=="boolean"?t.decodeDotInKeys:ve.decodeDotInKeys,decoder:typeof t.decoder=="function"?t.decoder:ve.decoder,delimiter:typeof t.delimiter=="string"||Tt.isRegExp(t.delimiter)?t.delimiter:ve.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:ve.depth,duplicates:n,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:ve.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:ve.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:ve.plainObjects,strictDepth:typeof t.strictDepth=="boolean"?!!t.strictDepth:ve.strictDepth,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:ve.strictNullHandling,throwOnLimitExceeded:typeof t.throwOnLimitExceeded=="boolean"?t.throwOnLimitExceeded:!1}},"normalizeParseOptions");nT.exports=function(e,t){var o=KM(t);if(e===""||e===null||typeof e>"u")return o.plainObjects?{__proto__:null}:{};for(var n=typeof e=="string"?VM(e,o):e,r=o.plainObjects?{__proto__:null}:{},i=Object.keys(n),a=0;a<i.length;++a){var c=i[a],p=WM(c,n[c],o,typeof e=="string");r=Tt.merge(r,p,o)}return o.allowSparse===!0?r:Tt.compact(r)}});var sT=U((QW,aT)=>{"use strict";var JM=rT(),XM=iT(),YM=Wu();aT.exports={formats:YM,parse:XM,stringify:JM}});var o1={};Ye(o1,{stripe:()=>r1,stripeAuth:()=>_});module.exports=Rw(o1);var et={};Ye(et,{$ZodAny:()=>Sn,$ZodArray:()=>An,$ZodAsyncError:()=>lt,$ZodBase64:()=>Is,$ZodBase64URL:()=>As,$ZodBigInt:()=>ao,$ZodBigIntFormat:()=>Rs,$ZodBoolean:()=>br,$ZodCIDRv4:()=>Ts,$ZodCIDRv6:()=>Es,$ZodCUID:()=>ds,$ZodCUID2:()=>ms,$ZodCatch:()=>Hs,$ZodCheck:()=>ae,$ZodCheckBigIntFormat:()=>Il,$ZodCheckEndsWith:()=>Ll,$ZodCheckGreaterThan:()=>ts,$ZodCheckIncludes:()=>zl,$ZodCheckLengthEquals:()=>Cl,$ZodCheckLessThan:()=>es,$ZodCheckLowerCase:()=>Nl,$ZodCheckMaxLength:()=>Ol,$ZodCheckMaxSize:()=>Al,$ZodCheckMimeType:()=>ql,$ZodCheckMinLength:()=>Rl,$ZodCheckMinSize:()=>kl,$ZodCheckMultipleOf:()=>Tl,$ZodCheckNumberFormat:()=>El,$ZodCheckOverwrite:()=>jl,$ZodCheckProperty:()=>Ul,$ZodCheckRegex:()=>$l,$ZodCheckSizeEquals:()=>wl,$ZodCheckStartsWith:()=>Ml,$ZodCheckStringFormat:()=>no,$ZodCheckUpperCase:()=>Dl,$ZodCodec:()=>co,$ZodCustom:()=>zn,$ZodCustomStringFormat:()=>Os,$ZodDate:()=>In,$ZodDefault:()=>Bs,$ZodDiscriminatedUnion:()=>kn,$ZodE164:()=>ks,$ZodEmail:()=>us,$ZodEmoji:()=>ps,$ZodEncodeError:()=>Ut,$ZodEnum:()=>Rn,$ZodError:()=>gn,$ZodExactOptional:()=>Fs,$ZodFile:()=>js,$ZodFunction:()=>Xs,$ZodGUID:()=>ss,$ZodIPv4:()=>Ps,$ZodIPv6:()=>xs,$ZodISODate:()=>vs,$ZodISODateTime:()=>gs,$ZodISODuration:()=>bs,$ZodISOTime:()=>_s,$ZodIntersection:()=>Ls,$ZodJWT:()=>ws,$ZodKSUID:()=>ys,$ZodLazy:()=>Qs,$ZodLiteral:()=>Cn,$ZodMAC:()=>Ss,$ZodMap:()=>Us,$ZodNaN:()=>Ws,$ZodNanoID:()=>ls,$ZodNever:()=>Ds,$ZodNonOptional:()=>Vs,$ZodNull:()=>Ns,$ZodNullable:()=>Nn,$ZodNumber:()=>io,$ZodNumberFormat:()=>xn,$ZodObject:()=>zs,$ZodObjectJIT:()=>Vl,$ZodOptional:()=>so,$ZodPipe:()=>Dn,$ZodPrefault:()=>Zs,$ZodPromise:()=>Ys,$ZodReadonly:()=>Ks,$ZodRealError:()=>Ge,$ZodRecord:()=>On,$ZodRegistry:()=>ec,$ZodSet:()=>qs,$ZodString:()=>wt,$ZodStringFormat:()=>ne,$ZodSuccess:()=>Gs,$ZodSymbol:()=>Cs,$ZodTemplateLiteral:()=>Js,$ZodTransform:()=>$n,$ZodTuple:()=>wn,$ZodType:()=>Z,$ZodULID:()=>fs,$ZodURL:()=>Pn,$ZodUUID:()=>cs,$ZodUndefined:()=>$s,$ZodUnion:()=>Pr,$ZodUnknown:()=>Tn,$ZodVoid:()=>En,$ZodXID:()=>hs,$ZodXor:()=>Ms,$brand:()=>pn,$constructor:()=>S,$input:()=>rc,$output:()=>tc,Doc:()=>bn,JSONSchema:()=>wg,JSONSchemaGenerator:()=>Rc,NEVER:()=>La,TimePrecision:()=>nc,_any:()=>yi,_array:()=>Ld,_base64:()=>ai,_base64url:()=>si,_bigint:()=>mc,_boolean:()=>mi,_catch:()=>MR,_check:()=>kg,_cidrv4:()=>ni,_cidrv6:()=>ii,_coercedBigint:()=>hi,_coercedBoolean:()=>fi,_coercedDate:()=>_i,_coercedNumber:()=>li,_coercedString:()=>Bn,_cuid:()=>Xn,_cuid2:()=>Yn,_custom:()=>Ei,_date:()=>bc,_decode:()=>Va,_decodeAsync:()=>Ha,_default:()=>NR,_discriminatedUnion:()=>xR,_e164:()=>ci,_email:()=>Zn,_emoji:()=>Kn,_encode:()=>Za,_encodeAsync:()=>Ga,_endsWith:()=>Ar,_enum:()=>kR,_file:()=>xc,_float32:()=>uc,_float64:()=>pc,_gt:()=>mt,_gte:()=>Ae,_guid:()=>lo,_includes:()=>Er,_int:()=>di,_int32:()=>lc,_int64:()=>fc,_intersection:()=>SR,_ipv4:()=>ri,_ipv6:()=>oi,_isoDate:()=>ac,_isoDateTime:()=>ic,_isoDuration:()=>cc,_isoTime:()=>sc,_jwt:()=>ui,_ksuid:()=>ti,_lazy:()=>jR,_length:()=>Gt,_literal:()=>OR,_lowercase:()=>Sr,_lt:()=>dt,_lte:()=>je,_mac:()=>oc,_map:()=>IR,_max:()=>je,_maxLength:()=>Vt,_maxSize:()=>Rt,_mime:()=>kr,_min:()=>Ae,_minLength:()=>Se,_minSize:()=>ft,_multipleOf:()=>Ot,_nan:()=>Pc,_nanoid:()=>Jn,_nativeEnum:()=>wR,_negative:()=>Pi,_never:()=>_c,_nonnegative:()=>Si,_nonoptional:()=>DR,_nonpositive:()=>xi,_normalize:()=>wr,_null:()=>vc,_nullable:()=>$R,_number:()=>pi,_optional:()=>CR,_overwrite:()=>it,_parse:()=>Yr,_parseAsync:()=>Qr,_pipe:()=>LR,_positive:()=>bi,_promise:()=>FR,_property:()=>Ti,_readonly:()=>UR,_record:()=>ER,_refine:()=>Sc,_regex:()=>ze,_safeDecode:()=>Ka,_safeDecodeAsync:()=>Xa,_safeEncode:()=>Wa,_safeEncodeAsync:()=>Ja,_safeParse:()=>eo,_safeParseAsync:()=>ro,_set:()=>AR,_size:()=>Zt,_slugify:()=>mo,_startsWith:()=>Ir,_string:()=>Fn,_stringFormat:()=>$r,_stringbool:()=>Ac,_success:()=>zR,_superRefine:()=>Tc,_symbol:()=>yc,_templateLiteral:()=>qR,_toLowerCase:()=>Rr,_toUpperCase:()=>Cr,_transform:()=>RR,_trim:()=>Or,_tuple:()=>TR,_uint32:()=>dc,_uint64:()=>hc,_ulid:()=>Qn,_undefined:()=>gc,_union:()=>bR,_unknown:()=>gi,_uppercase:()=>Tr,_url:()=>xr,_uuid:()=>Vn,_uuidv4:()=>Gn,_uuidv6:()=>Hn,_uuidv7:()=>Wn,_void:()=>vi,_xid:()=>ei,_xor:()=>PR,clone:()=>Oe,config:()=>me,createStandardJSONSchemaMethod:()=>fo,createToJSONSchemaMethod:()=>Ud,decode:()=>Ky,decodeAsync:()=>Xy,describe:()=>Ec,encode:()=>Wy,encodeAsync:()=>Jy,extractDefs:()=>Wt,finalize:()=>Kt,flattenError:()=>Jr,formatError:()=>Xr,globalConfig:()=>un,globalRegistry:()=>Re,initializeContext:()=>Ht,isValidBase64:()=>Zl,isValidBase64URL:()=>_g,isValidJWT:()=>bg,locales:()=>po,meta:()=>Ic,parse:()=>gr,parseAsync:()=>vr,prettifyError:()=>Ba,process:()=>ie,regexes:()=>He,registry:()=>jn,safeDecode:()=>Qy,safeDecodeAsync:()=>tg,safeEncode:()=>Yy,safeEncodeAsync:()=>eg,safeParse:()=>to,safeParseAsync:()=>oo,toDotPath:()=>Hy,toJSONSchema:()=>Ii,treeifyError:()=>Fa,util:()=>D,version:()=>Fl});var La=Object.freeze({status:"aborted"});function S(e,t,o){function n(c,p){if(c._zod||Object.defineProperty(c,"_zod",{value:{def:p,constr:a,traits:new Set},enumerable:!1}),c._zod.traits.has(e))return;c._zod.traits.add(e),t(c,p);let m=a.prototype,l=Object.keys(m);for(let g=0;g<l.length;g++){let h=l[g];h in c||(c[h]=m[h].bind(c))}}s(n,"init");let r=o?.Parent??Object;class i extends r{static{s(this,"Definition")}}Object.defineProperty(i,"name",{value:e});function a(c){var p;let m=o?.Parent?new i:this;n(m,c),(p=m._zod).deferred??(p.deferred=[]);for(let l of m._zod.deferred)l();return m}return s(a,"_"),Object.defineProperty(a,"init",{value:n}),Object.defineProperty(a,Symbol.hasInstance,{value:s(c=>o?.Parent&&c instanceof o.Parent?!0:c?._zod?.traits?.has(e),"value")}),Object.defineProperty(a,"name",{value:e}),a}s(S,"$constructor");var pn=Symbol("zod_brand"),lt=class extends Error{static{s(this,"$ZodAsyncError")}constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},Ut=class extends Error{static{s(this,"$ZodEncodeError")}constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},un={};function me(e){return e&&Object.assign(un,e),un}s(me,"config");var D={};Ye(D,{BIGINT_FORMAT_RANGES:()=>Kp,Class:()=>Fp,NUMBER_FORMAT_RANGES:()=>Wp,aborted:()=>Bt,allowsEval:()=>Vp,assert:()=>zw,assertEqual:()=>Cw,assertIs:()=>Nw,assertNever:()=>Dw,assertNotEqual:()=>$w,assignProp:()=>jt,base64ToUint8Array:()=>Zy,base64urlToUint8Array:()=>Hw,cached:()=>Wr,captureStackTrace:()=>qa,cleanEnum:()=>Gw,cleanRegex:()=>mn,clone:()=>Oe,cloneDef:()=>Lw,createTransparentProxy:()=>Zw,defineLazy:()=>J,esc:()=>Ua,escapeRegex:()=>nt,extend:()=>qy,finalizeIssue:()=>Ve,floatSafeRemainder:()=>Bp,getElementAtPath:()=>Uw,getEnumValues:()=>dn,getLengthableOrigin:()=>yn,getParsedType:()=>Bw,getSizableOrigin:()=>hn,hexToUint8Array:()=>Kw,isObject:()=>yr,isPlainObject:()=>Ft,issue:()=>Kr,joinValues:()=>w,jsonStringifyReplacer:()=>Hr,merge:()=>Vw,mergeDefs:()=>kt,normalizeParams:()=>$,nullish:()=>qt,numKeys:()=>Fw,objectClone:()=>Mw,omit:()=>Uy,optionalKeys:()=>Hp,parsedType:()=>z,partial:()=>Fy,pick:()=>Ly,prefixIssues:()=>Qe,primitiveTypes:()=>Gp,promiseAllObject:()=>qw,propertyKeyTypes:()=>fn,randomString:()=>jw,required:()=>By,safeExtend:()=>jy,shallowClone:()=>ja,slugify:()=>Zp,stringifyPrimitive:()=>N,uint8ArrayToBase64:()=>Vy,uint8ArrayToBase64url:()=>Ww,uint8ArrayToHex:()=>Jw,unwrapMessage:()=>ln});function Cw(e){return e}s(Cw,"assertEqual");function $w(e){return e}s($w,"assertNotEqual");function Nw(e){}s(Nw,"assertIs");function Dw(e){throw new Error("Unexpected value in exhaustive check")}s(Dw,"assertNever");function zw(e){}s(zw,"assert");function dn(e){let t=Object.values(e).filter(n=>typeof n=="number");return Object.entries(e).filter(([n,r])=>t.indexOf(+n)===-1).map(([n,r])=>r)}s(dn,"getEnumValues");function w(e,t="|"){return e.map(o=>N(o)).join(t)}s(w,"joinValues");function Hr(e,t){return typeof t=="bigint"?t.toString():t}s(Hr,"jsonStringifyReplacer");function Wr(e){return{get value(){{let o=e();return Object.defineProperty(this,"value",{value:o}),o}throw new Error("cached value already set")}}}s(Wr,"cached");function qt(e){return e==null}s(qt,"nullish");function mn(e){let t=e.startsWith("^")?1:0,o=e.endsWith("$")?e.length-1:e.length;return e.slice(t,o)}s(mn,"cleanRegex");function Bp(e,t){let o=(e.toString().split(".")[1]||"").length,n=t.toString(),r=(n.split(".")[1]||"").length;if(r===0&&/\d?e-\d?/.test(n)){let p=n.match(/\d?e-(\d?)/);p?.[1]&&(r=Number.parseInt(p[1]))}let i=o>r?o:r,a=Number.parseInt(e.toFixed(i).replace(".","")),c=Number.parseInt(t.toFixed(i).replace(".",""));return a%c/10**i}s(Bp,"floatSafeRemainder");var My=Symbol("evaluating");function J(e,t,o){let n;Object.defineProperty(e,t,{get(){if(n!==My)return n===void 0&&(n=My,n=o()),n},set(r){Object.defineProperty(e,t,{value:r})},configurable:!0})}s(J,"defineLazy");function Mw(e){return Object.create(Object.getPrototypeOf(e),Object.getOwnPropertyDescriptors(e))}s(Mw,"objectClone");function jt(e,t,o){Object.defineProperty(e,t,{value:o,writable:!0,enumerable:!0,configurable:!0})}s(jt,"assignProp");function kt(...e){let t={};for(let o of e){let n=Object.getOwnPropertyDescriptors(o);Object.assign(t,n)}return Object.defineProperties({},t)}s(kt,"mergeDefs");function Lw(e){return kt(e._zod.def)}s(Lw,"cloneDef");function Uw(e,t){return t?t.reduce((o,n)=>o?.[n],e):e}s(Uw,"getElementAtPath");function qw(e){let t=Object.keys(e),o=t.map(n=>e[n]);return Promise.all(o).then(n=>{let r={};for(let i=0;i<t.length;i++)r[t[i]]=n[i];return r})}s(qw,"promiseAllObject");function jw(e=10){let t="abcdefghijklmnopqrstuvwxyz",o="";for(let n=0;n<e;n++)o+=t[Math.floor(Math.random()*t.length)];return o}s(jw,"randomString");function Ua(e){return JSON.stringify(e)}s(Ua,"esc");function Zp(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}s(Zp,"slugify");var qa="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function yr(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}s(yr,"isObject");var Vp=Wr(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function Ft(e){if(yr(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let o=t.prototype;return!(yr(o)===!1||Object.prototype.hasOwnProperty.call(o,"isPrototypeOf")===!1)}s(Ft,"isPlainObject");function ja(e){return Ft(e)?{...e}:Array.isArray(e)?[...e]:e}s(ja,"shallowClone");function Fw(e){let t=0;for(let o in e)Object.prototype.hasOwnProperty.call(e,o)&&t++;return t}s(Fw,"numKeys");var Bw=s(e=>{let t=typeof e;switch(t){case"undefined":return"undefined";case"string":return"string";case"number":return Number.isNaN(e)?"nan":"number";case"boolean":return"boolean";case"function":return"function";case"bigint":return"bigint";case"symbol":return"symbol";case"object":return Array.isArray(e)?"array":e===null?"null":e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?"promise":typeof Map<"u"&&e instanceof Map?"map":typeof Set<"u"&&e instanceof Set?"set":typeof Date<"u"&&e instanceof Date?"date":typeof File<"u"&&e instanceof File?"file":"object";default:throw new Error(`Unknown data type: ${t}`)}},"getParsedType"),fn=new Set(["string","number","symbol"]),Gp=new Set(["string","number","bigint","boolean","symbol","undefined"]);function nt(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}s(nt,"escapeRegex");function Oe(e,t,o){let n=new e._zod.constr(t??e._zod.def);return(!t||o?.parent)&&(n._zod.parent=e),n}s(Oe,"clone");function $(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:s(()=>t,"error")};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:s(()=>t.error,"error")}:t}s($,"normalizeParams");function Zw(e){let t;return new Proxy({},{get(o,n,r){return t??(t=e()),Reflect.get(t,n,r)},set(o,n,r,i){return t??(t=e()),Reflect.set(t,n,r,i)},has(o,n){return t??(t=e()),Reflect.has(t,n)},deleteProperty(o,n){return t??(t=e()),Reflect.deleteProperty(t,n)},ownKeys(o){return t??(t=e()),Reflect.ownKeys(t)},getOwnPropertyDescriptor(o,n){return t??(t=e()),Reflect.getOwnPropertyDescriptor(t,n)},defineProperty(o,n,r){return t??(t=e()),Reflect.defineProperty(t,n,r)}})}s(Zw,"createTransparentProxy");function N(e){return typeof e=="bigint"?e.toString()+"n":typeof e=="string"?`"${e}"`:`${e}`}s(N,"stringifyPrimitive");function Hp(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}s(Hp,"optionalKeys");var Wp={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]},Kp={int64:[BigInt("-9223372036854775808"),BigInt("9223372036854775807")],uint64:[BigInt(0),BigInt("18446744073709551615")]};function Ly(e,t){let o=e._zod.def,n=o.checks;if(n&&n.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");let i=kt(e._zod.def,{get shape(){let a={};for(let c in t){if(!(c in o.shape))throw new Error(`Unrecognized key: "${c}"`);t[c]&&(a[c]=o.shape[c])}return jt(this,"shape",a),a},checks:[]});return Oe(e,i)}s(Ly,"pick");function Uy(e,t){let o=e._zod.def,n=o.checks;if(n&&n.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");let i=kt(e._zod.def,{get shape(){let a={...e._zod.def.shape};for(let c in t){if(!(c in o.shape))throw new Error(`Unrecognized key: "${c}"`);t[c]&&delete a[c]}return jt(this,"shape",a),a},checks:[]});return Oe(e,i)}s(Uy,"omit");function qy(e,t){if(!Ft(t))throw new Error("Invalid input to extend: expected a plain object");let o=e._zod.def.checks;if(o&&o.length>0){let i=e._zod.def.shape;for(let a in t)if(Object.getOwnPropertyDescriptor(i,a)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}let r=kt(e._zod.def,{get shape(){let i={...e._zod.def.shape,...t};return jt(this,"shape",i),i}});return Oe(e,r)}s(qy,"extend");function jy(e,t){if(!Ft(t))throw new Error("Invalid input to safeExtend: expected a plain object");let o=kt(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t};return jt(this,"shape",n),n}});return Oe(e,o)}s(jy,"safeExtend");function Vw(e,t){let o=kt(e._zod.def,{get shape(){let n={...e._zod.def.shape,...t._zod.def.shape};return jt(this,"shape",n),n},get catchall(){return t._zod.def.catchall},checks:[]});return Oe(e,o)}s(Vw,"merge");function Fy(e,t,o){let r=t._zod.def.checks;if(r&&r.length>0)throw new Error(".partial() cannot be used on object schemas containing refinements");let a=kt(t._zod.def,{get shape(){let c=t._zod.def.shape,p={...c};if(o)for(let m in o){if(!(m in c))throw new Error(`Unrecognized key: "${m}"`);o[m]&&(p[m]=e?new e({type:"optional",innerType:c[m]}):c[m])}else for(let m in c)p[m]=e?new e({type:"optional",innerType:c[m]}):c[m];return jt(this,"shape",p),p},checks:[]});return Oe(t,a)}s(Fy,"partial");function By(e,t,o){let n=kt(t._zod.def,{get shape(){let r=t._zod.def.shape,i={...r};if(o)for(let a in o){if(!(a in i))throw new Error(`Unrecognized key: "${a}"`);o[a]&&(i[a]=new e({type:"nonoptional",innerType:r[a]}))}else for(let a in r)i[a]=new e({type:"nonoptional",innerType:r[a]});return jt(this,"shape",i),i}});return Oe(t,n)}s(By,"required");function Bt(e,t=0){if(e.aborted===!0)return!0;for(let o=t;o<e.issues.length;o++)if(e.issues[o]?.continue!==!0)return!0;return!1}s(Bt,"aborted");function Qe(e,t){return t.map(o=>{var n;return(n=o).path??(n.path=[]),o.path.unshift(e),o})}s(Qe,"prefixIssues");function ln(e){return typeof e=="string"?e:e?.message}s(ln,"unwrapMessage");function Ve(e,t,o){let n={...e,path:e.path??[]};if(!e.message){let r=ln(e.inst?._zod.def?.error?.(e))??ln(t?.error?.(e))??ln(o.customError?.(e))??ln(o.localeError?.(e))??"Invalid input";n.message=r}return delete n.inst,delete n.continue,t?.reportInput||delete n.input,n}s(Ve,"finalizeIssue");function hn(e){return e instanceof Set?"set":e instanceof Map?"map":e instanceof File?"file":"unknown"}s(hn,"getSizableOrigin");function yn(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}s(yn,"getLengthableOrigin");function z(e){let t=typeof e;switch(t){case"number":return Number.isNaN(e)?"nan":"number";case"object":{if(e===null)return"null";if(Array.isArray(e))return"array";let o=e;if(o&&Object.getPrototypeOf(o)!==Object.prototype&&"constructor"in o&&o.constructor)return o.constructor.name}}return t}s(z,"parsedType");function Kr(...e){let[t,o,n]=e;return typeof t=="string"?{message:t,code:"custom",input:o,inst:n}:{...t}}s(Kr,"issue");function Gw(e){return Object.entries(e).filter(([t,o])=>Number.isNaN(Number.parseInt(t,10))).map(t=>t[1])}s(Gw,"cleanEnum");function Zy(e){let t=atob(e),o=new Uint8Array(t.length);for(let n=0;n<t.length;n++)o[n]=t.charCodeAt(n);return o}s(Zy,"base64ToUint8Array");function Vy(e){let t="";for(let o=0;o<e.length;o++)t+=String.fromCharCode(e[o]);return btoa(t)}s(Vy,"uint8ArrayToBase64");function Hw(e){let t=e.replace(/-/g,"+").replace(/_/g,"/"),o="=".repeat((4-t.length%4)%4);return Zy(t+o)}s(Hw,"base64urlToUint8Array");function Ww(e){return Vy(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}s(Ww,"uint8ArrayToBase64url");function Kw(e){let t=e.replace(/^0x/,"");if(t.length%2!==0)throw new Error("Invalid hex string length");let o=new Uint8Array(t.length/2);for(let n=0;n<t.length;n+=2)o[n/2]=Number.parseInt(t.slice(n,n+2),16);return o}s(Kw,"hexToUint8Array");function Jw(e){return Array.from(e).map(t=>t.toString(16).padStart(2,"0")).join("")}s(Jw,"uint8ArrayToHex");var Fp=class{static{s(this,"Class")}constructor(...t){}};var Gy=s((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,Hr,2),Object.defineProperty(e,"toString",{value:s(()=>e.message,"value"),enumerable:!1})},"initializer"),gn=S("$ZodError",Gy),Ge=S("$ZodError",Gy,{Parent:Error});function Jr(e,t=o=>o.message){let o={},n=[];for(let r of e.issues)r.path.length>0?(o[r.path[0]]=o[r.path[0]]||[],o[r.path[0]].push(t(r))):n.push(t(r));return{formErrors:n,fieldErrors:o}}s(Jr,"flattenError");function Xr(e,t=o=>o.message){let o={_errors:[]},n=s(r=>{for(let i of r.issues)if(i.code==="invalid_union"&&i.errors.length)i.errors.map(a=>n({issues:a}));else if(i.code==="invalid_key")n({issues:i.issues});else if(i.code==="invalid_element")n({issues:i.issues});else if(i.path.length===0)o._errors.push(t(i));else{let a=o,c=0;for(;c<i.path.length;){let p=i.path[c];c===i.path.length-1?(a[p]=a[p]||{_errors:[]},a[p]._errors.push(t(i))):a[p]=a[p]||{_errors:[]},a=a[p],c++}}},"processError");return n(e),o}s(Xr,"formatError");function Fa(e,t=o=>o.message){let o={errors:[]},n=s((r,i=[])=>{var a,c;for(let p of r.issues)if(p.code==="invalid_union"&&p.errors.length)p.errors.map(m=>n({issues:m},p.path));else if(p.code==="invalid_key")n({issues:p.issues},p.path);else if(p.code==="invalid_element")n({issues:p.issues},p.path);else{let m=[...i,...p.path];if(m.length===0){o.errors.push(t(p));continue}let l=o,g=0;for(;g<m.length;){let h=m[g],f=g===m.length-1;typeof h=="string"?(l.properties??(l.properties={}),(a=l.properties)[h]??(a[h]={errors:[]}),l=l.properties[h]):(l.items??(l.items=[]),(c=l.items)[h]??(c[h]={errors:[]}),l=l.items[h]),f&&l.errors.push(t(p)),g++}}},"processError");return n(e),o}s(Fa,"treeifyError");function Hy(e){let t=[],o=e.map(n=>typeof n=="object"?n.key:n);for(let n of o)typeof n=="number"?t.push(`[${n}]`):typeof n=="symbol"?t.push(`[${JSON.stringify(String(n))}]`):/[^\w$]/.test(n)?t.push(`[${JSON.stringify(n)}]`):(t.length&&t.push("."),t.push(n));return t.join("")}s(Hy,"toDotPath");function Ba(e){let t=[],o=[...e.issues].sort((n,r)=>(n.path??[]).length-(r.path??[]).length);for(let n of o)t.push(`\u2716 ${n.message}`),n.path?.length&&t.push(` \u2192 at ${Hy(n.path)}`);return t.join(`
|
|
6
|
+
`)}s(Ba,"prettifyError");var Yr=s(e=>(t,o,n,r)=>{let i=n?Object.assign(n,{async:!1}):{async:!1},a=t._zod.run({value:o,issues:[]},i);if(a instanceof Promise)throw new lt;if(a.issues.length){let c=new(r?.Err??e)(a.issues.map(p=>Ve(p,i,me())));throw qa(c,r?.callee),c}return a.value},"_parse"),gr=Yr(Ge),Qr=s(e=>async(t,o,n,r)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},a=t._zod.run({value:o,issues:[]},i);if(a instanceof Promise&&(a=await a),a.issues.length){let c=new(r?.Err??e)(a.issues.map(p=>Ve(p,i,me())));throw qa(c,r?.callee),c}return a.value},"_parseAsync"),vr=Qr(Ge),eo=s(e=>(t,o,n)=>{let r=n?{...n,async:!1}:{async:!1},i=t._zod.run({value:o,issues:[]},r);if(i instanceof Promise)throw new lt;return i.issues.length?{success:!1,error:new(e??gn)(i.issues.map(a=>Ve(a,r,me())))}:{success:!0,data:i.value}},"_safeParse"),to=eo(Ge),ro=s(e=>async(t,o,n)=>{let r=n?Object.assign(n,{async:!0}):{async:!0},i=t._zod.run({value:o,issues:[]},r);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(a=>Ve(a,r,me())))}:{success:!0,data:i.value}},"_safeParseAsync"),oo=ro(Ge),Za=s(e=>(t,o,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return Yr(e)(t,o,r)},"_encode"),Wy=Za(Ge),Va=s(e=>(t,o,n)=>Yr(e)(t,o,n),"_decode"),Ky=Va(Ge),Ga=s(e=>async(t,o,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return Qr(e)(t,o,r)},"_encodeAsync"),Jy=Ga(Ge),Ha=s(e=>async(t,o,n)=>Qr(e)(t,o,n),"_decodeAsync"),Xy=Ha(Ge),Wa=s(e=>(t,o,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return eo(e)(t,o,r)},"_safeEncode"),Yy=Wa(Ge),Ka=s(e=>(t,o,n)=>eo(e)(t,o,n),"_safeDecode"),Qy=Ka(Ge),Ja=s(e=>async(t,o,n)=>{let r=n?Object.assign(n,{direction:"backward"}):{direction:"backward"};return ro(e)(t,o,r)},"_safeEncodeAsync"),eg=Ja(Ge),Xa=s(e=>async(t,o,n)=>ro(e)(t,o,n),"_safeDecodeAsync"),tg=Xa(Ge);var He={};Ye(He,{base64:()=>ll,base64url:()=>Ya,bigint:()=>gl,boolean:()=>_l,browserEmail:()=>iO,cidrv4:()=>ul,cidrv6:()=>pl,cuid:()=>Jp,cuid2:()=>Xp,date:()=>ml,datetime:()=>hl,domain:()=>cO,duration:()=>rl,e164:()=>dl,email:()=>nl,emoji:()=>il,extendedDuration:()=>Yw,guid:()=>ol,hex:()=>uO,hostname:()=>sO,html5Email:()=>rO,idnEmail:()=>nO,integer:()=>vl,ipv4:()=>al,ipv6:()=>sl,ksuid:()=>el,lowercase:()=>xl,mac:()=>cl,md5_base64:()=>lO,md5_base64url:()=>dO,md5_hex:()=>pO,nanoid:()=>tl,null:()=>bl,number:()=>Qa,rfc5322Email:()=>oO,sha1_base64:()=>fO,sha1_base64url:()=>hO,sha1_hex:()=>mO,sha256_base64:()=>gO,sha256_base64url:()=>vO,sha256_hex:()=>yO,sha384_base64:()=>bO,sha384_base64url:()=>PO,sha384_hex:()=>_O,sha512_base64:()=>SO,sha512_base64url:()=>TO,sha512_hex:()=>xO,string:()=>yl,time:()=>fl,ulid:()=>Yp,undefined:()=>Pl,unicodeEmail:()=>rg,uppercase:()=>Sl,uuid:()=>_r,uuid4:()=>Qw,uuid6:()=>eO,uuid7:()=>tO,xid:()=>Qp});var Jp=/^[cC][^\s-]{8,}$/,Xp=/^[0-9a-z]+$/,Yp=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,Qp=/^[0-9a-vA-V]{20}$/,el=/^[A-Za-z0-9]{27}$/,tl=/^[a-zA-Z0-9_-]{21}$/,rl=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,Yw=/^[-+]?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)?)??$/,ol=/^([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})$/,_r=s(e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,"uuid"),Qw=_r(4),eO=_r(6),tO=_r(7),nl=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,rO=/^[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])?)*$/,oO=/^(([^<>()\[\]\\.,;:\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,}))$/,rg=/^[^\s@"]{1,64}@[^\s@]{1,255}$/u,nO=rg,iO=/^[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])?)*$/,aO="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function il(){return new RegExp(aO,"u")}s(il,"emoji");var al=/^(?:(?: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])$/,sl=/^(([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}|:))$/,cl=s(e=>{let t=nt(e??":");return new RegExp(`^(?:[0-9A-F]{2}${t}){5}[0-9A-F]{2}$|^(?:[0-9a-f]{2}${t}){5}[0-9a-f]{2}$`)},"mac"),ul=/^((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])$/,pl=/^(([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])$/,ll=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,Ya=/^[A-Za-z0-9_-]*$/,sO=/^(?=.{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])?)*\.?$/,cO=/^([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/,dl=/^\+[1-9]\d{6,14}$/,og="(?:(?:\\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])))",ml=new RegExp(`^${og}$`);function ng(e){let t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}s(ng,"timeSource");function fl(e){return new RegExp(`^${ng(e)}$`)}s(fl,"time");function hl(e){let t=ng({precision:e.precision}),o=["Z"];e.local&&o.push(""),e.offset&&o.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");let n=`${t}(?:${o.join("|")})`;return new RegExp(`^${og}T(?:${n})$`)}s(hl,"datetime");var yl=s(e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},"string"),gl=/^-?\d+n?$/,vl=/^-?\d+$/,Qa=/^-?\d+(?:\.\d+)?$/,_l=/^(?:true|false)$/i,bl=/^null$/i;var Pl=/^undefined$/i;var xl=/^[^A-Z]*$/,Sl=/^[^a-z]*$/,uO=/^[0-9a-fA-F]*$/;function vn(e,t){return new RegExp(`^[A-Za-z0-9+/]{${e}}${t}$`)}s(vn,"fixedBase64");function _n(e){return new RegExp(`^[A-Za-z0-9_-]{${e}}$`)}s(_n,"fixedBase64url");var pO=/^[0-9a-fA-F]{32}$/,lO=vn(22,"=="),dO=_n(22),mO=/^[0-9a-fA-F]{40}$/,fO=vn(27,"="),hO=_n(27),yO=/^[0-9a-fA-F]{64}$/,gO=vn(43,"="),vO=_n(43),_O=/^[0-9a-fA-F]{96}$/,bO=vn(64,""),PO=_n(64),xO=/^[0-9a-fA-F]{128}$/,SO=vn(86,"=="),TO=_n(86);var ae=S("$ZodCheck",(e,t)=>{var o;e._zod??(e._zod={}),e._zod.def=t,(o=e._zod).onattach??(o.onattach=[])}),ag={number:"number",bigint:"bigint",object:"date"},es=S("$ZodCheckLessThan",(e,t)=>{ae.init(e,t);let o=ag[typeof t.value];e._zod.onattach.push(n=>{let r=n._zod.bag,i=(t.inclusive?r.maximum:r.exclusiveMaximum)??Number.POSITIVE_INFINITY;t.value<i&&(t.inclusive?r.maximum=t.value:r.exclusiveMaximum=t.value)}),e._zod.check=n=>{(t.inclusive?n.value<=t.value:n.value<t.value)||n.issues.push({origin:o,code:"too_big",maximum:typeof t.value=="object"?t.value.getTime():t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),ts=S("$ZodCheckGreaterThan",(e,t)=>{ae.init(e,t);let o=ag[typeof t.value];e._zod.onattach.push(n=>{let r=n._zod.bag,i=(t.inclusive?r.minimum:r.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>i&&(t.inclusive?r.minimum=t.value:r.exclusiveMinimum=t.value)}),e._zod.check=n=>{(t.inclusive?n.value>=t.value:n.value>t.value)||n.issues.push({origin:o,code:"too_small",minimum:typeof t.value=="object"?t.value.getTime():t.value,input:n.value,inclusive:t.inclusive,inst:e,continue:!t.abort})}}),Tl=S("$ZodCheckMultipleOf",(e,t)=>{ae.init(e,t),e._zod.onattach.push(o=>{var n;(n=o._zod.bag).multipleOf??(n.multipleOf=t.value)}),e._zod.check=o=>{if(typeof o.value!=typeof t.value)throw new Error("Cannot mix number and bigint in multiple_of check.");(typeof o.value=="bigint"?o.value%t.value===BigInt(0):Bp(o.value,t.value)===0)||o.issues.push({origin:typeof o.value,code:"not_multiple_of",divisor:t.value,input:o.value,inst:e,continue:!t.abort})}}),El=S("$ZodCheckNumberFormat",(e,t)=>{ae.init(e,t),t.format=t.format||"float64";let o=t.format?.includes("int"),n=o?"int":"number",[r,i]=Wp[t.format];e._zod.onattach.push(a=>{let c=a._zod.bag;c.format=t.format,c.minimum=r,c.maximum=i,o&&(c.pattern=vl)}),e._zod.check=a=>{let c=a.value;if(o){if(!Number.isInteger(c)){a.issues.push({expected:n,format:t.format,code:"invalid_type",continue:!1,input:c,inst:e});return}if(!Number.isSafeInteger(c)){c>0?a.issues.push({input:c,code:"too_big",maximum:Number.MAX_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,inclusive:!0,continue:!t.abort}):a.issues.push({input:c,code:"too_small",minimum:Number.MIN_SAFE_INTEGER,note:"Integers must be within the safe integer range.",inst:e,origin:n,inclusive:!0,continue:!t.abort});return}}c<r&&a.issues.push({origin:"number",input:c,code:"too_small",minimum:r,inclusive:!0,inst:e,continue:!t.abort}),c>i&&a.issues.push({origin:"number",input:c,code:"too_big",maximum:i,inclusive:!0,inst:e,continue:!t.abort})}}),Il=S("$ZodCheckBigIntFormat",(e,t)=>{ae.init(e,t);let[o,n]=Kp[t.format];e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,i.minimum=o,i.maximum=n}),e._zod.check=r=>{let i=r.value;i<o&&r.issues.push({origin:"bigint",input:i,code:"too_small",minimum:o,inclusive:!0,inst:e,continue:!t.abort}),i>n&&r.issues.push({origin:"bigint",input:i,code:"too_big",maximum:n,inclusive:!0,inst:e,continue:!t.abort})}}),Al=S("$ZodCheckMaxSize",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.size!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(n._zod.bag.maximum=t.maximum)}),e._zod.check=n=>{let r=n.value;r.size<=t.maximum||n.issues.push({origin:hn(r),code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),kl=S("$ZodCheckMinSize",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.size!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(n._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let r=n.value;r.size>=t.minimum||n.issues.push({origin:hn(r),code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),wl=S("$ZodCheckSizeEquals",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.size!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag;r.minimum=t.size,r.maximum=t.size,r.size=t.size}),e._zod.check=n=>{let r=n.value,i=r.size;if(i===t.size)return;let a=i>t.size;n.issues.push({origin:hn(r),...a?{code:"too_big",maximum:t.size}:{code:"too_small",minimum:t.size},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),Ol=S("$ZodCheckMaxLength",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.length!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<r&&(n._zod.bag.maximum=t.maximum)}),e._zod.check=n=>{let r=n.value;if(r.length<=t.maximum)return;let a=yn(r);n.issues.push({origin:a,code:"too_big",maximum:t.maximum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),Rl=S("$ZodCheckMinLength",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.length!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>r&&(n._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let r=n.value;if(r.length>=t.minimum)return;let a=yn(r);n.issues.push({origin:a,code:"too_small",minimum:t.minimum,inclusive:!0,input:r,inst:e,continue:!t.abort})}}),Cl=S("$ZodCheckLengthEquals",(e,t)=>{var o;ae.init(e,t),(o=e._zod.def).when??(o.when=n=>{let r=n.value;return!qt(r)&&r.length!==void 0}),e._zod.onattach.push(n=>{let r=n._zod.bag;r.minimum=t.length,r.maximum=t.length,r.length=t.length}),e._zod.check=n=>{let r=n.value,i=r.length;if(i===t.length)return;let a=yn(r),c=i>t.length;n.issues.push({origin:a,...c?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:n.value,inst:e,continue:!t.abort})}}),no=S("$ZodCheckStringFormat",(e,t)=>{var o,n;ae.init(e,t),e._zod.onattach.push(r=>{let i=r._zod.bag;i.format=t.format,t.pattern&&(i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern))}),t.pattern?(o=e._zod).check??(o.check=r=>{t.pattern.lastIndex=0,!t.pattern.test(r.value)&&r.issues.push({origin:"string",code:"invalid_format",format:t.format,input:r.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(n=e._zod).check??(n.check=()=>{})}),$l=S("$ZodCheckRegex",(e,t)=>{no.init(e,t),e._zod.check=o=>{t.pattern.lastIndex=0,!t.pattern.test(o.value)&&o.issues.push({origin:"string",code:"invalid_format",format:"regex",input:o.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Nl=S("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=xl),no.init(e,t)}),Dl=S("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=Sl),no.init(e,t)}),zl=S("$ZodCheckIncludes",(e,t)=>{ae.init(e,t);let o=nt(t.includes),n=new RegExp(typeof t.position=="number"?`^.{${t.position}}${o}`:o);t.pattern=n,e._zod.onattach.push(r=>{let i=r._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(n)}),e._zod.check=r=>{r.value.includes(t.includes,t.position)||r.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:r.value,inst:e,continue:!t.abort})}}),Ml=S("$ZodCheckStartsWith",(e,t)=>{ae.init(e,t);let o=new RegExp(`^${nt(t.prefix)}.*`);t.pattern??(t.pattern=o),e._zod.onattach.push(n=>{let r=n._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(o)}),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})}}),Ll=S("$ZodCheckEndsWith",(e,t)=>{ae.init(e,t);let o=new RegExp(`.*${nt(t.suffix)}$`);t.pattern??(t.pattern=o),e._zod.onattach.push(n=>{let r=n._zod.bag;r.patterns??(r.patterns=new Set),r.patterns.add(o)}),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 ig(e,t,o){e.issues.length&&t.issues.push(...Qe(o,e.issues))}s(ig,"handleCheckPropertyResult");var Ul=S("$ZodCheckProperty",(e,t)=>{ae.init(e,t),e._zod.check=o=>{let n=t.schema._zod.run({value:o.value[t.property],issues:[]},{});if(n instanceof Promise)return n.then(r=>ig(r,o,t.property));ig(n,o,t.property)}}),ql=S("$ZodCheckMimeType",(e,t)=>{ae.init(e,t);let o=new Set(t.mime);e._zod.onattach.push(n=>{n._zod.bag.mime=t.mime}),e._zod.check=n=>{o.has(n.value.type)||n.issues.push({code:"invalid_value",values:t.mime,input:n.value.type,inst:e,continue:!t.abort})}}),jl=S("$ZodCheckOverwrite",(e,t)=>{ae.init(e,t),e._zod.check=o=>{o.value=t.tx(o.value)}});var bn=class{static{s(this,"Doc")}constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}let n=t.split(`
|
|
7
|
+
`).filter(a=>a),r=Math.min(...n.map(a=>a.length-a.trimStart().length)),i=n.map(a=>a.slice(r)).map(a=>" ".repeat(this.indent*2)+a);for(let a of i)this.content.push(a)}compile(){let t=Function,o=this?.args,r=[...(this?.content??[""]).map(i=>` ${i}`)];return new t(...o,r.join(`
|
|
8
|
+
`))}};var Fl={major:4,minor:3,patch:6};var Z=S("$ZodType",(e,t)=>{var o;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Fl;let n=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&n.unshift(e);for(let r of n)for(let i of r._zod.onattach)i(e);if(n.length===0)(o=e._zod).deferred??(o.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let r=s((a,c,p)=>{let m=Bt(a),l;for(let g of c){if(g._zod.def.when){if(!g._zod.def.when(a))continue}else if(m)continue;let h=a.issues.length,f=g._zod.check(a);if(f instanceof Promise&&p?.async===!1)throw new lt;if(l||f instanceof Promise)l=(l??Promise.resolve()).then(async()=>{await f,a.issues.length!==h&&(m||(m=Bt(a,h)))});else{if(a.issues.length===h)continue;m||(m=Bt(a,h))}}return l?l.then(()=>a):a},"runChecks"),i=s((a,c,p)=>{if(Bt(a))return a.aborted=!0,a;let m=r(c,n,p);if(m instanceof Promise){if(p.async===!1)throw new lt;return m.then(l=>e._zod.parse(l,p))}return e._zod.parse(m,p)},"handleCanaryResult");e._zod.run=(a,c)=>{if(c.skipChecks)return e._zod.parse(a,c);if(c.direction==="backward"){let m=e._zod.parse({value:a.value,issues:[]},{...c,skipChecks:!0});return m instanceof Promise?m.then(l=>i(l,a,c)):i(m,a,c)}let p=e._zod.parse(a,c);if(p instanceof Promise){if(c.async===!1)throw new lt;return p.then(m=>r(m,n,c))}return r(p,n,c)}}J(e,"~standard",()=>({validate:s(r=>{try{let i=to(e,r);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return oo(e,r).then(a=>a.success?{value:a.data}:{issues:a.error?.issues})}},"validate"),vendor:"zod",version:1}))}),wt=S("$ZodString",(e,t)=>{Z.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??yl(e._zod.bag),e._zod.parse=(o,n)=>{if(t.coerce)try{o.value=String(o.value)}catch{}return typeof o.value=="string"||o.issues.push({expected:"string",code:"invalid_type",input:o.value,inst:e}),o}}),ne=S("$ZodStringFormat",(e,t)=>{no.init(e,t),wt.init(e,t)}),ss=S("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=ol),ne.init(e,t)}),cs=S("$ZodUUID",(e,t)=>{if(t.version){let n={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(n===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=_r(n))}else t.pattern??(t.pattern=_r());ne.init(e,t)}),us=S("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=nl),ne.init(e,t)}),Pn=S("$ZodURL",(e,t)=>{ne.init(e,t),e._zod.check=o=>{try{let n=o.value.trim(),r=new URL(n);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(r.hostname)||o.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:o.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(r.protocol.endsWith(":")?r.protocol.slice(0,-1):r.protocol)||o.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:o.value,inst:e,continue:!t.abort})),t.normalize?o.value=r.href:o.value=n;return}catch{o.issues.push({code:"invalid_format",format:"url",input:o.value,inst:e,continue:!t.abort})}}}),ps=S("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=il()),ne.init(e,t)}),ls=S("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=tl),ne.init(e,t)}),ds=S("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=Jp),ne.init(e,t)}),ms=S("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=Xp),ne.init(e,t)}),fs=S("$ZodULID",(e,t)=>{t.pattern??(t.pattern=Yp),ne.init(e,t)}),hs=S("$ZodXID",(e,t)=>{t.pattern??(t.pattern=Qp),ne.init(e,t)}),ys=S("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=el),ne.init(e,t)}),gs=S("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=hl(t)),ne.init(e,t)}),vs=S("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=ml),ne.init(e,t)}),_s=S("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=fl(t)),ne.init(e,t)}),bs=S("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=rl),ne.init(e,t)}),Ps=S("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=al),ne.init(e,t),e._zod.bag.format="ipv4"}),xs=S("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=sl),ne.init(e,t),e._zod.bag.format="ipv6",e._zod.check=o=>{try{new URL(`http://[${o.value}]`)}catch{o.issues.push({code:"invalid_format",format:"ipv6",input:o.value,inst:e,continue:!t.abort})}}}),Ss=S("$ZodMAC",(e,t)=>{t.pattern??(t.pattern=cl(t.delimiter)),ne.init(e,t),e._zod.bag.format="mac"}),Ts=S("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=ul),ne.init(e,t)}),Es=S("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=pl),ne.init(e,t),e._zod.check=o=>{let n=o.value.split("/");try{if(n.length!==2)throw new Error;let[r,i]=n;if(!i)throw new Error;let a=Number(i);if(`${a}`!==i)throw new Error;if(a<0||a>128)throw new Error;new URL(`http://[${r}]`)}catch{o.issues.push({code:"invalid_format",format:"cidrv6",input:o.value,inst:e,continue:!t.abort})}}});function Zl(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}s(Zl,"isValidBase64");var Is=S("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=ll),ne.init(e,t),e._zod.bag.contentEncoding="base64",e._zod.check=o=>{Zl(o.value)||o.issues.push({code:"invalid_format",format:"base64",input:o.value,inst:e,continue:!t.abort})}});function _g(e){if(!Ya.test(e))return!1;let t=e.replace(/[-_]/g,n=>n==="-"?"+":"/"),o=t.padEnd(Math.ceil(t.length/4)*4,"=");return Zl(o)}s(_g,"isValidBase64URL");var As=S("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=Ya),ne.init(e,t),e._zod.bag.contentEncoding="base64url",e._zod.check=o=>{_g(o.value)||o.issues.push({code:"invalid_format",format:"base64url",input:o.value,inst:e,continue:!t.abort})}}),ks=S("$ZodE164",(e,t)=>{t.pattern??(t.pattern=dl),ne.init(e,t)});function bg(e,t=null){try{let o=e.split(".");if(o.length!==3)return!1;let[n]=o;if(!n)return!1;let r=JSON.parse(atob(n));return!("typ"in r&&r?.typ!=="JWT"||!r.alg||t&&(!("alg"in r)||r.alg!==t))}catch{return!1}}s(bg,"isValidJWT");var ws=S("$ZodJWT",(e,t)=>{ne.init(e,t),e._zod.check=o=>{bg(o.value,t.alg)||o.issues.push({code:"invalid_format",format:"jwt",input:o.value,inst:e,continue:!t.abort})}}),Os=S("$ZodCustomStringFormat",(e,t)=>{ne.init(e,t),e._zod.check=o=>{t.fn(o.value)||o.issues.push({code:"invalid_format",format:t.format,input:o.value,inst:e,continue:!t.abort})}}),io=S("$ZodNumber",(e,t)=>{Z.init(e,t),e._zod.pattern=e._zod.bag.pattern??Qa,e._zod.parse=(o,n)=>{if(t.coerce)try{o.value=Number(o.value)}catch{}let r=o.value;if(typeof r=="number"&&!Number.isNaN(r)&&Number.isFinite(r))return o;let i=typeof r=="number"?Number.isNaN(r)?"NaN":Number.isFinite(r)?void 0:"Infinity":void 0;return o.issues.push({expected:"number",code:"invalid_type",input:r,inst:e,...i?{received:i}:{}}),o}}),xn=S("$ZodNumberFormat",(e,t)=>{El.init(e,t),io.init(e,t)}),br=S("$ZodBoolean",(e,t)=>{Z.init(e,t),e._zod.pattern=_l,e._zod.parse=(o,n)=>{if(t.coerce)try{o.value=!!o.value}catch{}let r=o.value;return typeof r=="boolean"||o.issues.push({expected:"boolean",code:"invalid_type",input:r,inst:e}),o}}),ao=S("$ZodBigInt",(e,t)=>{Z.init(e,t),e._zod.pattern=gl,e._zod.parse=(o,n)=>{if(t.coerce)try{o.value=BigInt(o.value)}catch{}return typeof o.value=="bigint"||o.issues.push({expected:"bigint",code:"invalid_type",input:o.value,inst:e}),o}}),Rs=S("$ZodBigIntFormat",(e,t)=>{Il.init(e,t),ao.init(e,t)}),Cs=S("$ZodSymbol",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;return typeof r=="symbol"||o.issues.push({expected:"symbol",code:"invalid_type",input:r,inst:e}),o}}),$s=S("$ZodUndefined",(e,t)=>{Z.init(e,t),e._zod.pattern=Pl,e._zod.values=new Set([void 0]),e._zod.optin="optional",e._zod.optout="optional",e._zod.parse=(o,n)=>{let r=o.value;return typeof r>"u"||o.issues.push({expected:"undefined",code:"invalid_type",input:r,inst:e}),o}}),Ns=S("$ZodNull",(e,t)=>{Z.init(e,t),e._zod.pattern=bl,e._zod.values=new Set([null]),e._zod.parse=(o,n)=>{let r=o.value;return r===null||o.issues.push({expected:"null",code:"invalid_type",input:r,inst:e}),o}}),Sn=S("$ZodAny",(e,t)=>{Z.init(e,t),e._zod.parse=o=>o}),Tn=S("$ZodUnknown",(e,t)=>{Z.init(e,t),e._zod.parse=o=>o}),Ds=S("$ZodNever",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>(o.issues.push({expected:"never",code:"invalid_type",input:o.value,inst:e}),o)}),En=S("$ZodVoid",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;return typeof r>"u"||o.issues.push({expected:"void",code:"invalid_type",input:r,inst:e}),o}}),In=S("$ZodDate",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{if(t.coerce)try{o.value=new Date(o.value)}catch{}let r=o.value,i=r instanceof Date;return i&&!Number.isNaN(r.getTime())||o.issues.push({expected:"date",code:"invalid_type",input:r,...i?{received:"Invalid Date"}:{},inst:e}),o}});function cg(e,t,o){e.issues.length&&t.issues.push(...Qe(o,e.issues)),t.value[o]=e.value}s(cg,"handleArrayResult");var An=S("$ZodArray",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;if(!Array.isArray(r))return o.issues.push({expected:"array",code:"invalid_type",input:r,inst:e}),o;o.value=Array(r.length);let i=[];for(let a=0;a<r.length;a++){let c=r[a],p=t.element._zod.run({value:c,issues:[]},n);p instanceof Promise?i.push(p.then(m=>cg(m,o,a))):cg(p,o,a)}return i.length?Promise.all(i).then(()=>o):o}});function as(e,t,o,n,r){if(e.issues.length){if(r&&!(o in n))return;t.issues.push(...Qe(o,e.issues))}e.value===void 0?o in n&&(t.value[o]=void 0):t.value[o]=e.value}s(as,"handlePropertyResult");function Pg(e){let t=Object.keys(e.shape);for(let n of t)if(!e.shape?.[n]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${n}": expected a Zod schema`);let o=Hp(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(o)}}s(Pg,"normalizeDef");function xg(e,t,o,n,r,i){let a=[],c=r.keySet,p=r.catchall._zod,m=p.def.type,l=p.optout==="optional";for(let g in t){if(c.has(g))continue;if(m==="never"){a.push(g);continue}let h=p.run({value:t[g],issues:[]},n);h instanceof Promise?e.push(h.then(f=>as(f,o,g,t,l))):as(h,o,g,t,l)}return a.length&&o.issues.push({code:"unrecognized_keys",keys:a,input:t,inst:i}),e.length?Promise.all(e).then(()=>o):o}s(xg,"handleCatchall");var zs=S("$ZodObject",(e,t)=>{if(Z.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){let c=t.shape;Object.defineProperty(t,"shape",{get:s(()=>{let p={...c};return Object.defineProperty(t,"shape",{value:p}),p},"get")})}let n=Wr(()=>Pg(t));J(e._zod,"propValues",()=>{let c=t.shape,p={};for(let m in c){let l=c[m]._zod;if(l.values){p[m]??(p[m]=new Set);for(let g of l.values)p[m].add(g)}}return p});let r=yr,i=t.catchall,a;e._zod.parse=(c,p)=>{a??(a=n.value);let m=c.value;if(!r(m))return c.issues.push({expected:"object",code:"invalid_type",input:m,inst:e}),c;c.value={};let l=[],g=a.shape;for(let h of a.keys){let f=g[h],v=f._zod.optout==="optional",I=f._zod.run({value:m[h],issues:[]},p);I instanceof Promise?l.push(I.then(T=>as(T,c,h,m,v))):as(I,c,h,m,v)}return i?xg(l,m,c,p,n.value,e):l.length?Promise.all(l).then(()=>c):c}}),Vl=S("$ZodObjectJIT",(e,t)=>{zs.init(e,t);let o=e._zod.parse,n=Wr(()=>Pg(t)),r=s(h=>{let f=new bn(["shape","payload","ctx"]),v=n.value,I=s(R=>{let q=Ua(R);return`shape[${q}]._zod.run({ value: input[${q}], issues: [] }, ctx)`},"parseStr");f.write("const input = payload.value;");let T=Object.create(null),x=0;for(let R of v.keys)T[R]=`key_${x++}`;f.write("const newResult = {};");for(let R of v.keys){let q=T[R],Q=Ua(R),Pe=h[R]?._zod?.optout==="optional";f.write(`const ${q} = ${I(R)};`),Pe?f.write(`
|
|
9
|
+
if (${q}.issues.length) {
|
|
10
|
+
if (${Q} in input) {
|
|
11
|
+
payload.issues = payload.issues.concat(${q}.issues.map(iss => ({
|
|
12
|
+
...iss,
|
|
13
|
+
path: iss.path ? [${Q}, ...iss.path] : [${Q}]
|
|
14
|
+
})));
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
if (${q}.value === undefined) {
|
|
19
|
+
if (${Q} in input) {
|
|
20
|
+
newResult[${Q}] = undefined;
|
|
21
|
+
}
|
|
22
|
+
} else {
|
|
23
|
+
newResult[${Q}] = ${q}.value;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
`):f.write(`
|
|
27
|
+
if (${q}.issues.length) {
|
|
28
|
+
payload.issues = payload.issues.concat(${q}.issues.map(iss => ({
|
|
29
|
+
...iss,
|
|
30
|
+
path: iss.path ? [${Q}, ...iss.path] : [${Q}]
|
|
31
|
+
})));
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
if (${q}.value === undefined) {
|
|
35
|
+
if (${Q} in input) {
|
|
36
|
+
newResult[${Q}] = undefined;
|
|
37
|
+
}
|
|
38
|
+
} else {
|
|
39
|
+
newResult[${Q}] = ${q}.value;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
`)}f.write("payload.value = newResult;"),f.write("return payload;");let k=f.compile();return(R,q)=>k(h,R,q)},"generateFastpass"),i,a=yr,c=!un.jitless,m=c&&Vp.value,l=t.catchall,g;e._zod.parse=(h,f)=>{g??(g=n.value);let v=h.value;return a(v)?c&&m&&f?.async===!1&&f.jitless!==!0?(i||(i=r(t.shape)),h=i(h,f),l?xg([],v,h,f,g,e):h):o(h,f):(h.issues.push({expected:"object",code:"invalid_type",input:v,inst:e}),h)}});function ug(e,t,o,n){for(let i of e)if(i.issues.length===0)return t.value=i.value,t;let r=e.filter(i=>!Bt(i));return r.length===1?(t.value=r[0].value,r[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:o,errors:e.map(i=>i.issues.map(a=>Ve(a,n,me())))}),t)}s(ug,"handleUnionResults");var Pr=S("$ZodUnion",(e,t)=>{Z.init(e,t),J(e._zod,"optin",()=>t.options.some(r=>r._zod.optin==="optional")?"optional":void 0),J(e._zod,"optout",()=>t.options.some(r=>r._zod.optout==="optional")?"optional":void 0),J(e._zod,"values",()=>{if(t.options.every(r=>r._zod.values))return new Set(t.options.flatMap(r=>Array.from(r._zod.values)))}),J(e._zod,"pattern",()=>{if(t.options.every(r=>r._zod.pattern)){let r=t.options.map(i=>i._zod.pattern);return new RegExp(`^(${r.map(i=>mn(i.source)).join("|")})$`)}});let o=t.options.length===1,n=t.options[0]._zod.run;e._zod.parse=(r,i)=>{if(o)return n(r,i);let a=!1,c=[];for(let p of t.options){let m=p._zod.run({value:r.value,issues:[]},i);if(m instanceof Promise)c.push(m),a=!0;else{if(m.issues.length===0)return m;c.push(m)}}return a?Promise.all(c).then(p=>ug(p,r,e,i)):ug(c,r,e,i)}});function pg(e,t,o,n){let r=e.filter(i=>i.issues.length===0);return r.length===1?(t.value=r[0].value,t):(r.length===0?t.issues.push({code:"invalid_union",input:t.value,inst:o,errors:e.map(i=>i.issues.map(a=>Ve(a,n,me())))}):t.issues.push({code:"invalid_union",input:t.value,inst:o,errors:[],inclusive:!1}),t)}s(pg,"handleExclusiveUnionResults");var Ms=S("$ZodXor",(e,t)=>{Pr.init(e,t),t.inclusive=!1;let o=t.options.length===1,n=t.options[0]._zod.run;e._zod.parse=(r,i)=>{if(o)return n(r,i);let a=!1,c=[];for(let p of t.options){let m=p._zod.run({value:r.value,issues:[]},i);m instanceof Promise?(c.push(m),a=!0):c.push(m)}return a?Promise.all(c).then(p=>pg(p,r,e,i)):pg(c,r,e,i)}}),kn=S("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,Pr.init(e,t);let o=e._zod.parse;J(e._zod,"propValues",()=>{let r={};for(let i of t.options){let a=i._zod.propValues;if(!a||Object.keys(a).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(i)}"`);for(let[c,p]of Object.entries(a)){r[c]||(r[c]=new Set);for(let m of p)r[c].add(m)}}return r});let n=Wr(()=>{let r=t.options,i=new Map;for(let a of r){let c=a._zod.propValues?.[t.discriminator];if(!c||c.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(a)}"`);for(let p of c){if(i.has(p))throw new Error(`Duplicate discriminator value "${String(p)}"`);i.set(p,a)}}return i});e._zod.parse=(r,i)=>{let a=r.value;if(!yr(a))return r.issues.push({code:"invalid_type",expected:"object",input:a,inst:e}),r;let c=n.value.get(a?.[t.discriminator]);return c?c._zod.run(r,i):t.unionFallback?o(r,i):(r.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:a,path:[t.discriminator],inst:e}),r)}}),Ls=S("$ZodIntersection",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value,i=t.left._zod.run({value:r,issues:[]},n),a=t.right._zod.run({value:r,issues:[]},n);return i instanceof Promise||a instanceof Promise?Promise.all([i,a]).then(([p,m])=>lg(o,p,m)):lg(o,i,a)}});function Bl(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(Ft(e)&&Ft(t)){let o=Object.keys(t),n=Object.keys(e).filter(i=>o.indexOf(i)!==-1),r={...e,...t};for(let i of n){let a=Bl(e[i],t[i]);if(!a.valid)return{valid:!1,mergeErrorPath:[i,...a.mergeErrorPath]};r[i]=a.data}return{valid:!0,data:r}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};let o=[];for(let n=0;n<e.length;n++){let r=e[n],i=t[n],a=Bl(r,i);if(!a.valid)return{valid:!1,mergeErrorPath:[n,...a.mergeErrorPath]};o.push(a.data)}return{valid:!0,data:o}}return{valid:!1,mergeErrorPath:[]}}s(Bl,"mergeValues");function lg(e,t,o){let n=new Map,r;for(let c of t.issues)if(c.code==="unrecognized_keys"){r??(r=c);for(let p of c.keys)n.has(p)||n.set(p,{}),n.get(p).l=!0}else e.issues.push(c);for(let c of o.issues)if(c.code==="unrecognized_keys")for(let p of c.keys)n.has(p)||n.set(p,{}),n.get(p).r=!0;else e.issues.push(c);let i=[...n].filter(([,c])=>c.l&&c.r).map(([c])=>c);if(i.length&&r&&e.issues.push({...r,keys:i}),Bt(e))return e;let a=Bl(t.value,o.value);if(!a.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(a.mergeErrorPath)}`);return e.value=a.data,e}s(lg,"handleIntersectionResults");var wn=S("$ZodTuple",(e,t)=>{Z.init(e,t);let o=t.items;e._zod.parse=(n,r)=>{let i=n.value;if(!Array.isArray(i))return n.issues.push({input:i,inst:e,expected:"tuple",code:"invalid_type"}),n;n.value=[];let a=[],c=[...o].reverse().findIndex(l=>l._zod.optin!=="optional"),p=c===-1?0:o.length-c;if(!t.rest){let l=i.length>o.length,g=i.length<p-1;if(l||g)return n.issues.push({...l?{code:"too_big",maximum:o.length,inclusive:!0}:{code:"too_small",minimum:o.length},input:i,inst:e,origin:"array"}),n}let m=-1;for(let l of o){if(m++,m>=i.length&&m>=p)continue;let g=l._zod.run({value:i[m],issues:[]},r);g instanceof Promise?a.push(g.then(h=>rs(h,n,m))):rs(g,n,m)}if(t.rest){let l=i.slice(o.length);for(let g of l){m++;let h=t.rest._zod.run({value:g,issues:[]},r);h instanceof Promise?a.push(h.then(f=>rs(f,n,m))):rs(h,n,m)}}return a.length?Promise.all(a).then(()=>n):n}});function rs(e,t,o){e.issues.length&&t.issues.push(...Qe(o,e.issues)),t.value[o]=e.value}s(rs,"handleTupleResult");var On=S("$ZodRecord",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;if(!Ft(r))return o.issues.push({expected:"record",code:"invalid_type",input:r,inst:e}),o;let i=[],a=t.keyType._zod.values;if(a){o.value={};let c=new Set;for(let m of a)if(typeof m=="string"||typeof m=="number"||typeof m=="symbol"){c.add(typeof m=="number"?m.toString():m);let l=t.valueType._zod.run({value:r[m],issues:[]},n);l instanceof Promise?i.push(l.then(g=>{g.issues.length&&o.issues.push(...Qe(m,g.issues)),o.value[m]=g.value})):(l.issues.length&&o.issues.push(...Qe(m,l.issues)),o.value[m]=l.value)}let p;for(let m in r)c.has(m)||(p=p??[],p.push(m));p&&p.length>0&&o.issues.push({code:"unrecognized_keys",input:r,inst:e,keys:p})}else{o.value={};for(let c of Reflect.ownKeys(r)){if(c==="__proto__")continue;let p=t.keyType._zod.run({value:c,issues:[]},n);if(p instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof c=="string"&&Qa.test(c)&&p.issues.length){let g=t.keyType._zod.run({value:Number(c),issues:[]},n);if(g instanceof Promise)throw new Error("Async schemas not supported in object keys currently");g.issues.length===0&&(p=g)}if(p.issues.length){t.mode==="loose"?o.value[c]=r[c]:o.issues.push({code:"invalid_key",origin:"record",issues:p.issues.map(g=>Ve(g,n,me())),input:c,path:[c],inst:e});continue}let l=t.valueType._zod.run({value:r[c],issues:[]},n);l instanceof Promise?i.push(l.then(g=>{g.issues.length&&o.issues.push(...Qe(c,g.issues)),o.value[p.value]=g.value})):(l.issues.length&&o.issues.push(...Qe(c,l.issues)),o.value[p.value]=l.value)}}return i.length?Promise.all(i).then(()=>o):o}}),Us=S("$ZodMap",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;if(!(r instanceof Map))return o.issues.push({expected:"map",code:"invalid_type",input:r,inst:e}),o;let i=[];o.value=new Map;for(let[a,c]of r){let p=t.keyType._zod.run({value:a,issues:[]},n),m=t.valueType._zod.run({value:c,issues:[]},n);p instanceof Promise||m instanceof Promise?i.push(Promise.all([p,m]).then(([l,g])=>{dg(l,g,o,a,r,e,n)})):dg(p,m,o,a,r,e,n)}return i.length?Promise.all(i).then(()=>o):o}});function dg(e,t,o,n,r,i,a){e.issues.length&&(fn.has(typeof n)?o.issues.push(...Qe(n,e.issues)):o.issues.push({code:"invalid_key",origin:"map",input:r,inst:i,issues:e.issues.map(c=>Ve(c,a,me()))})),t.issues.length&&(fn.has(typeof n)?o.issues.push(...Qe(n,t.issues)):o.issues.push({origin:"map",code:"invalid_element",input:r,inst:i,key:n,issues:t.issues.map(c=>Ve(c,a,me()))})),o.value.set(e.value,t.value)}s(dg,"handleMapResult");var qs=S("$ZodSet",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;if(!(r instanceof Set))return o.issues.push({input:r,inst:e,expected:"set",code:"invalid_type"}),o;let i=[];o.value=new Set;for(let a of r){let c=t.valueType._zod.run({value:a,issues:[]},n);c instanceof Promise?i.push(c.then(p=>mg(p,o))):mg(c,o)}return i.length?Promise.all(i).then(()=>o):o}});function mg(e,t){e.issues.length&&t.issues.push(...e.issues),t.value.add(e.value)}s(mg,"handleSetResult");var Rn=S("$ZodEnum",(e,t)=>{Z.init(e,t);let o=dn(t.entries),n=new Set(o);e._zod.values=n,e._zod.pattern=new RegExp(`^(${o.filter(r=>fn.has(typeof r)).map(r=>typeof r=="string"?nt(r):r.toString()).join("|")})$`),e._zod.parse=(r,i)=>{let a=r.value;return n.has(a)||r.issues.push({code:"invalid_value",values:o,input:a,inst:e}),r}}),Cn=S("$ZodLiteral",(e,t)=>{if(Z.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");let o=new Set(t.values);e._zod.values=o,e._zod.pattern=new RegExp(`^(${t.values.map(n=>typeof n=="string"?nt(n):n?nt(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,r)=>{let i=n.value;return o.has(i)||n.issues.push({code:"invalid_value",values:t.values,input:i,inst:e}),n}}),js=S("$ZodFile",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{let r=o.value;return r instanceof File||o.issues.push({expected:"file",code:"invalid_type",input:r,inst:e}),o}}),$n=S("$ZodTransform",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{if(n.direction==="backward")throw new Ut(e.constructor.name);let r=t.transform(o.value,o);if(n.async)return(r instanceof Promise?r:Promise.resolve(r)).then(a=>(o.value=a,o));if(r instanceof Promise)throw new lt;return o.value=r,o}});function fg(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}s(fg,"handleOptionalResult");var so=S("$ZodOptional",(e,t)=>{Z.init(e,t),e._zod.optin="optional",e._zod.optout="optional",J(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),J(e._zod,"pattern",()=>{let o=t.innerType._zod.pattern;return o?new RegExp(`^(${mn(o.source)})?$`):void 0}),e._zod.parse=(o,n)=>{if(t.innerType._zod.optin==="optional"){let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(i=>fg(i,o.value)):fg(r,o.value)}return o.value===void 0?o:t.innerType._zod.run(o,n)}}),Fs=S("$ZodExactOptional",(e,t)=>{so.init(e,t),J(e._zod,"values",()=>t.innerType._zod.values),J(e._zod,"pattern",()=>t.innerType._zod.pattern),e._zod.parse=(o,n)=>t.innerType._zod.run(o,n)}),Nn=S("$ZodNullable",(e,t)=>{Z.init(e,t),J(e._zod,"optin",()=>t.innerType._zod.optin),J(e._zod,"optout",()=>t.innerType._zod.optout),J(e._zod,"pattern",()=>{let o=t.innerType._zod.pattern;return o?new RegExp(`^(${mn(o.source)}|null)$`):void 0}),J(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(o,n)=>o.value===null?o:t.innerType._zod.run(o,n)}),Bs=S("$ZodDefault",(e,t)=>{Z.init(e,t),e._zod.optin="optional",J(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(o,n)=>{if(n.direction==="backward")return t.innerType._zod.run(o,n);if(o.value===void 0)return o.value=t.defaultValue,o;let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(i=>hg(i,t)):hg(r,t)}});function hg(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}s(hg,"handleDefaultResult");var Zs=S("$ZodPrefault",(e,t)=>{Z.init(e,t),e._zod.optin="optional",J(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(o,n)=>(n.direction==="backward"||o.value===void 0&&(o.value=t.defaultValue),t.innerType._zod.run(o,n))}),Vs=S("$ZodNonOptional",(e,t)=>{Z.init(e,t),J(e._zod,"values",()=>{let o=t.innerType._zod.values;return o?new Set([...o].filter(n=>n!==void 0)):void 0}),e._zod.parse=(o,n)=>{let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(i=>yg(i,e)):yg(r,e)}});function yg(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}s(yg,"handleNonOptionalResult");var Gs=S("$ZodSuccess",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>{if(n.direction==="backward")throw new Ut("ZodSuccess");let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(i=>(o.value=i.issues.length===0,o)):(o.value=r.issues.length===0,o)}}),Hs=S("$ZodCatch",(e,t)=>{Z.init(e,t),J(e._zod,"optin",()=>t.innerType._zod.optin),J(e._zod,"optout",()=>t.innerType._zod.optout),J(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(o,n)=>{if(n.direction==="backward")return t.innerType._zod.run(o,n);let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(i=>(o.value=i.value,i.issues.length&&(o.value=t.catchValue({...o,error:{issues:i.issues.map(a=>Ve(a,n,me()))},input:o.value}),o.issues=[]),o)):(o.value=r.value,r.issues.length&&(o.value=t.catchValue({...o,error:{issues:r.issues.map(i=>Ve(i,n,me()))},input:o.value}),o.issues=[]),o)}}),Ws=S("$ZodNaN",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>((typeof o.value!="number"||!Number.isNaN(o.value))&&o.issues.push({input:o.value,inst:e,expected:"nan",code:"invalid_type"}),o)}),Dn=S("$ZodPipe",(e,t)=>{Z.init(e,t),J(e._zod,"values",()=>t.in._zod.values),J(e._zod,"optin",()=>t.in._zod.optin),J(e._zod,"optout",()=>t.out._zod.optout),J(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(o,n)=>{if(n.direction==="backward"){let i=t.out._zod.run(o,n);return i instanceof Promise?i.then(a=>os(a,t.in,n)):os(i,t.in,n)}let r=t.in._zod.run(o,n);return r instanceof Promise?r.then(i=>os(i,t.out,n)):os(r,t.out,n)}});function os(e,t,o){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},o)}s(os,"handlePipeResult");var co=S("$ZodCodec",(e,t)=>{Z.init(e,t),J(e._zod,"values",()=>t.in._zod.values),J(e._zod,"optin",()=>t.in._zod.optin),J(e._zod,"optout",()=>t.out._zod.optout),J(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(o,n)=>{if((n.direction||"forward")==="forward"){let i=t.in._zod.run(o,n);return i instanceof Promise?i.then(a=>ns(a,t,n)):ns(i,t,n)}else{let i=t.out._zod.run(o,n);return i instanceof Promise?i.then(a=>ns(a,t,n)):ns(i,t,n)}}});function ns(e,t,o){if(e.issues.length)return e.aborted=!0,e;if((o.direction||"forward")==="forward"){let r=t.transform(e.value,e);return r instanceof Promise?r.then(i=>is(e,i,t.out,o)):is(e,r,t.out,o)}else{let r=t.reverseTransform(e.value,e);return r instanceof Promise?r.then(i=>is(e,i,t.in,o)):is(e,r,t.in,o)}}s(ns,"handleCodecAResult");function is(e,t,o,n){return e.issues.length?(e.aborted=!0,e):o._zod.run({value:t,issues:e.issues},n)}s(is,"handleCodecTxResult");var Ks=S("$ZodReadonly",(e,t)=>{Z.init(e,t),J(e._zod,"propValues",()=>t.innerType._zod.propValues),J(e._zod,"values",()=>t.innerType._zod.values),J(e._zod,"optin",()=>t.innerType?._zod?.optin),J(e._zod,"optout",()=>t.innerType?._zod?.optout),e._zod.parse=(o,n)=>{if(n.direction==="backward")return t.innerType._zod.run(o,n);let r=t.innerType._zod.run(o,n);return r instanceof Promise?r.then(gg):gg(r)}});function gg(e){return e.value=Object.freeze(e.value),e}s(gg,"handleReadonlyResult");var Js=S("$ZodTemplateLiteral",(e,t)=>{Z.init(e,t);let o=[];for(let n of t.parts)if(typeof n=="object"&&n!==null){if(!n._zod.pattern)throw new Error(`Invalid template literal part, no pattern found: ${[...n._zod.traits].shift()}`);let r=n._zod.pattern instanceof RegExp?n._zod.pattern.source:n._zod.pattern;if(!r)throw new Error(`Invalid template literal part: ${n._zod.traits}`);let i=r.startsWith("^")?1:0,a=r.endsWith("$")?r.length-1:r.length;o.push(r.slice(i,a))}else if(n===null||Gp.has(typeof n))o.push(nt(`${n}`));else throw new Error(`Invalid template literal part: ${n}`);e._zod.pattern=new RegExp(`^${o.join("")}$`),e._zod.parse=(n,r)=>typeof n.value!="string"?(n.issues.push({input:n.value,inst:e,expected:"string",code:"invalid_type"}),n):(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)}),Xs=S("$ZodFunction",(e,t)=>(Z.init(e,t),e._def=t,e._zod.def=t,e.implement=o=>{if(typeof o!="function")throw new Error("implement() must be called with a function");return function(...n){let r=e._def.input?gr(e._def.input,n):n,i=Reflect.apply(o,this,r);return e._def.output?gr(e._def.output,i):i}},e.implementAsync=o=>{if(typeof o!="function")throw new Error("implementAsync() must be called with a function");return async function(...n){let r=e._def.input?await vr(e._def.input,n):n,i=await Reflect.apply(o,this,r);return e._def.output?await vr(e._def.output,i):i}},e._zod.parse=(o,n)=>typeof o.value!="function"?(o.issues.push({code:"invalid_type",expected:"function",input:o.value,inst:e}),o):(e._def.output&&e._def.output._zod.def.type==="promise"?o.value=e.implementAsync(o.value):o.value=e.implement(o.value),o),e.input=(...o)=>{let n=e.constructor;return Array.isArray(o[0])?new n({type:"function",input:new wn({type:"tuple",items:o[0],rest:o[1]}),output:e._def.output}):new n({type:"function",input:o[0],output:e._def.output})},e.output=o=>{let n=e.constructor;return new n({type:"function",input:e._def.input,output:o})},e)),Ys=S("$ZodPromise",(e,t)=>{Z.init(e,t),e._zod.parse=(o,n)=>Promise.resolve(o.value).then(r=>t.innerType._zod.run({value:r,issues:[]},n))}),Qs=S("$ZodLazy",(e,t)=>{Z.init(e,t),J(e._zod,"innerType",()=>t.getter()),J(e._zod,"pattern",()=>e._zod.innerType?._zod?.pattern),J(e._zod,"propValues",()=>e._zod.innerType?._zod?.propValues),J(e._zod,"optin",()=>e._zod.innerType?._zod?.optin??void 0),J(e._zod,"optout",()=>e._zod.innerType?._zod?.optout??void 0),e._zod.parse=(o,n)=>e._zod.innerType._zod.run(o,n)}),zn=S("$ZodCustom",(e,t)=>{ae.init(e,t),Z.init(e,t),e._zod.parse=(o,n)=>o,e._zod.check=o=>{let n=o.value,r=t.fn(n);if(r instanceof Promise)return r.then(i=>vg(i,o,n,e));vg(r,o,n,e)}});function vg(e,t,o,n){if(!e){let r={code:"custom",input:o,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};n._zod.def.params&&(r.params=n._zod.def.params),t.issues.push(Kr(r))}}s(vg,"handleRefineResult");var po={};Ye(po,{ar:()=>Gl,az:()=>Hl,be:()=>Wl,bg:()=>Kl,ca:()=>Jl,cs:()=>Xl,da:()=>Yl,de:()=>Ql,en:()=>Mn,eo:()=>ed,es:()=>td,fa:()=>rd,fi:()=>od,fr:()=>nd,frCA:()=>id,he:()=>ad,hu:()=>sd,hy:()=>cd,id:()=>ud,is:()=>pd,it:()=>ld,ja:()=>dd,ka:()=>md,kh:()=>fd,km:()=>Ln,ko:()=>hd,lt:()=>yd,mk:()=>gd,ms:()=>vd,nl:()=>_d,no:()=>bd,ota:()=>Pd,pl:()=>Sd,ps:()=>xd,pt:()=>Td,ru:()=>Ed,sl:()=>Id,sv:()=>Ad,ta:()=>kd,th:()=>wd,tr:()=>Od,ua:()=>Rd,uk:()=>qn,ur:()=>Cd,uz:()=>$d,vi:()=>Nd,yo:()=>Md,zhCN:()=>Dd,zhTW:()=>zd});var IO=s(()=>{let e={string:{unit:"\u062D\u0631\u0641",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},file:{unit:"\u0628\u0627\u064A\u062A",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},array:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"},set:{unit:"\u0639\u0646\u0635\u0631",verb:"\u0623\u0646 \u064A\u062D\u0648\u064A"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0645\u062F\u062E\u0644",email:"\u0628\u0631\u064A\u062F \u0625\u0644\u0643\u062A\u0631\u0648\u0646\u064A",url:"\u0631\u0627\u0628\u0637",emoji:"\u0625\u064A\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u064A\u062E \u0648\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",date:"\u062A\u0627\u0631\u064A\u062E \u0628\u0645\u0639\u064A\u0627\u0631 ISO",time:"\u0648\u0642\u062A \u0628\u0645\u0639\u064A\u0627\u0631 ISO",duration:"\u0645\u062F\u0629 \u0628\u0645\u0639\u064A\u0627\u0631 ISO",ipv4:"\u0639\u0646\u0648\u0627\u0646 IPv4",ipv6:"\u0639\u0646\u0648\u0627\u0646 IPv6",cidrv4:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv4",cidrv6:"\u0645\u062F\u0649 \u0639\u0646\u0627\u0648\u064A\u0646 \u0628\u0635\u064A\u063A\u0629 IPv6",base64:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64-encoded",base64url:"\u0646\u064E\u0635 \u0628\u062A\u0631\u0645\u064A\u0632 base64url-encoded",json_string:"\u0646\u064E\u0635 \u0639\u0644\u0649 \u0647\u064A\u0626\u0629 JSON",e164:"\u0631\u0642\u0645 \u0647\u0627\u062A\u0641 \u0628\u0645\u0639\u064A\u0627\u0631 E.164",jwt:"JWT",template_literal:"\u0645\u062F\u062E\u0644"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 instanceof ${r.expected}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${c}`:`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${i}\u060C \u0648\u0644\u0643\u0646 \u062A\u0645 \u0625\u062F\u062E\u0627\u0644 ${c}`}case"invalid_value":return r.values.length===1?`\u0645\u062F\u062E\u0644\u0627\u062A \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644\u0629: \u064A\u0641\u062A\u0631\u0636 \u0625\u062F\u062E\u0627\u0644 ${N(r.values[0])}`:`\u0627\u062E\u062A\u064A\u0627\u0631 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062A\u0648\u0642\u0639 \u0627\u0646\u062A\u0642\u0627\u0621 \u0623\u062D\u062F \u0647\u0630\u0647 \u0627\u0644\u062E\u064A\u0627\u0631\u0627\u062A: ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?` \u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"}`:`\u0623\u0643\u0628\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0623\u0646 \u062A\u0643\u0648\u0646 ${r.origin??"\u0627\u0644\u0642\u064A\u0645\u0629"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()} ${a.unit}`:`\u0623\u0635\u063A\u0631 \u0645\u0646 \u0627\u0644\u0644\u0627\u0632\u0645: \u064A\u0641\u062A\u0631\u0636 \u0644\u0640 ${r.origin} \u0623\u0646 \u064A\u0643\u0648\u0646 ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0628\u062F\u0623 \u0628\u0640 "${r.prefix}"`:i.format==="ends_with"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0646\u062A\u0647\u064A \u0628\u0640 "${i.suffix}"`:i.format==="includes"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u062A\u0636\u0645\u0651\u064E\u0646 "${i.includes}"`:i.format==="regex"?`\u0646\u064E\u0635 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0637\u0627\u0628\u0642 \u0627\u0644\u0646\u0645\u0637 ${i.pattern}`:`${o[i.format]??r.format} \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644`}case"not_multiple_of":return`\u0631\u0642\u0645 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644: \u064A\u062C\u0628 \u0623\u0646 \u064A\u0643\u0648\u0646 \u0645\u0646 \u0645\u0636\u0627\u0639\u0641\u0627\u062A ${r.divisor}`;case"unrecognized_keys":return`\u0645\u0639\u0631\u0641${r.keys.length>1?"\u0627\u062A":""} \u063A\u0631\u064A\u0628${r.keys.length>1?"\u0629":""}: ${w(r.keys,"\u060C ")}`;case"invalid_key":return`\u0645\u0639\u0631\u0641 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;case"invalid_union":return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644";case"invalid_element":return`\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644 \u0641\u064A ${r.origin}`;default:return"\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0645\u0642\u0628\u0648\u0644"}}},"error");function Gl(){return{localeError:IO()}}s(Gl,"default");var AO=s(()=>{let e={string:{unit:"simvol",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"element",verb:"olmal\u0131d\u0131r"},set:{unit:"element",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded string",base64url:"base64url-encoded string",json_string:"JSON string",e164:"E.164 number",jwt:"JWT",template_literal:"input"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n instanceof ${r.expected}, daxil olan ${c}`:`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${i}, daxil olan ${c}`}case"invalid_value":return r.values.length===1?`Yanl\u0131\u015F d\u0259y\u0259r: g\xF6zl\u0259nil\u0259n ${N(r.values[0])}`:`Yanl\u0131\u015F se\xE7im: a\u015Fa\u011F\u0131dak\u0131lardan biri olmal\u0131d\u0131r: ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()} ${a.unit??"element"}`:`\xC7ox b\xF6y\xFCk: g\xF6zl\u0259nil\u0259n ${r.origin??"d\u0259y\u0259r"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\xC7ox ki\xE7ik: g\xF6zl\u0259nil\u0259n ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Yanl\u0131\u015F m\u0259tn: "${i.prefix}" il\u0259 ba\u015Flamal\u0131d\u0131r`:i.format==="ends_with"?`Yanl\u0131\u015F m\u0259tn: "${i.suffix}" il\u0259 bitm\u0259lidir`:i.format==="includes"?`Yanl\u0131\u015F m\u0259tn: "${i.includes}" daxil olmal\u0131d\u0131r`:i.format==="regex"?`Yanl\u0131\u015F m\u0259tn: ${i.pattern} \u015Fablonuna uy\u011Fun olmal\u0131d\u0131r`:`Yanl\u0131\u015F ${o[i.format]??r.format}`}case"not_multiple_of":return`Yanl\u0131\u015F \u0259d\u0259d: ${r.divisor} il\u0259 b\xF6l\xFCn\u0259 bil\u0259n olmal\u0131d\u0131r`;case"unrecognized_keys":return`Tan\u0131nmayan a\xE7ar${r.keys.length>1?"lar":""}: ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} daxilind\u0259 yanl\u0131\u015F a\xE7ar`;case"invalid_union":return"Yanl\u0131\u015F d\u0259y\u0259r";case"invalid_element":return`${r.origin} daxilind\u0259 yanl\u0131\u015F d\u0259y\u0259r`;default:return"Yanl\u0131\u015F d\u0259y\u0259r"}}},"error");function Hl(){return{localeError:AO()}}s(Hl,"default");function Sg(e,t,o,n){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?n:i===1?t:i>=2&&i<=4?o:n}s(Sg,"getBelarusianPlural");var kO=s(()=>{let e={string:{unit:{one:"\u0441\u0456\u043C\u0432\u0430\u043B",few:"\u0441\u0456\u043C\u0432\u0430\u043B\u044B",many:"\u0441\u0456\u043C\u0432\u0430\u043B\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u044B",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u044B",many:"\u0431\u0430\u0439\u0442\u0430\u045E"},verb:"\u043C\u0435\u0446\u044C"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0443\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0430\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0456 \u0447\u0430\u0441",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0447\u0430\u0441",duration:"ISO \u043F\u0440\u0430\u0446\u044F\u0433\u043B\u0430\u0441\u0446\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0430\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0430\u0441",cidrv4:"IPv4 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u044B\u044F\u043F\u0430\u0437\u043E\u043D",base64:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64",base64url:"\u0440\u0430\u0434\u043E\u043A \u0443 \u0444\u0430\u0440\u043C\u0430\u0446\u0435 base64url",json_string:"JSON \u0440\u0430\u0434\u043E\u043A",e164:"\u043D\u0443\u043C\u0430\u0440 E.164",jwt:"JWT",template_literal:"\u0443\u0432\u043E\u0434"},n={nan:"NaN",number:"\u043B\u0456\u043A",array:"\u043C\u0430\u0441\u0456\u045E"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F instanceof ${r.expected}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${c}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u045E\u0441\u044F ${i}, \u0430\u0442\u0440\u044B\u043C\u0430\u043D\u0430 ${c}`}case"invalid_value":return r.values.length===1?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F ${N(r.values[0])}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0432\u0430\u0440\u044B\u044F\u043D\u0442: \u0447\u0430\u043A\u0430\u045E\u0441\u044F \u0430\u0434\u0437\u0456\u043D \u0437 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let c=Number(r.maximum),p=Sg(c,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.maximum.toString()} ${p}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u0432\u044F\u043B\u0456\u043A\u0456: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435"} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let c=Number(r.minimum),p=Sg(c,a.unit.one,a.unit.few,a.unit.many);return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 ${a.verb} ${i}${r.minimum.toString()} ${p}`}return`\u0417\u0430\u043D\u0430\u0434\u0442\u0430 \u043C\u0430\u043B\u044B: \u0447\u0430\u043A\u0430\u043B\u0430\u0441\u044F, \u0448\u0442\u043E ${r.origin} \u043F\u0430\u0432\u0456\u043D\u043D\u0430 \u0431\u044B\u0446\u044C ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u043F\u0430\u0447\u044B\u043D\u0430\u0446\u0446\u0430 \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u0430\u043A\u0430\u043D\u0447\u0432\u0430\u0446\u0446\u0430 \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0437\u043C\u044F\u0448\u0447\u0430\u0446\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u0440\u0430\u0434\u043E\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0430\u0434\u043F\u0430\u0432\u044F\u0434\u0430\u0446\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043B\u0456\u043A: \u043F\u0430\u0432\u0456\u043D\u0435\u043D \u0431\u044B\u0446\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u0430\u0437\u043D\u0430\u043D\u044B ${r.keys.length>1?"\u043A\u043B\u044E\u0447\u044B":"\u043A\u043B\u044E\u0447"}: ${w(r.keys,", ")}`;case"invalid_key":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434";case"invalid_element":return`\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u0430\u0435 \u0437\u043D\u0430\u0447\u044D\u043D\u043D\u0435 \u045E ${r.origin}`;default:return"\u041D\u044F\u043F\u0440\u0430\u0432\u0456\u043B\u044C\u043D\u044B \u045E\u0432\u043E\u0434"}}},"error");function Wl(){return{localeError:kO()}}s(Wl,"default");var wO=s(()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},file:{unit:"\u0431\u0430\u0439\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430",verb:"\u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0432\u0445\u043E\u0434",email:"\u0438\u043C\u0435\u0439\u043B \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0436\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u043F\u0440\u043E\u0434\u044A\u043B\u0436\u0438\u0442\u0435\u043B\u043D\u043E\u0441\u0442",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"base64-\u043A\u043E\u0434\u0438\u0440\u0430\u043D \u043D\u0438\u0437",base64url:"base64url-\u043A\u043E\u0434\u0438\u0440\u0430\u043D \u043D\u0438\u0437",json_string:"JSON \u043D\u0438\u0437",e164:"E.164 \u043D\u043E\u043C\u0435\u0440",jwt:"JWT",template_literal:"\u0432\u0445\u043E\u0434"},n={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0438\u0432"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D instanceof ${r.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D ${c}`:`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D ${i}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D ${c}`}case"invalid_value":return r.values.length===1?`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434: \u043E\u0447\u0430\u043A\u0432\u0430\u043D ${N(r.values[0])}`:`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430 \u043E\u043F\u0446\u0438\u044F: \u043E\u0447\u0430\u043A\u0432\u0430\u043D\u043E \u0435\u0434\u043D\u043E \u043E\u0442 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0422\u0432\u044A\u0440\u0434\u0435 \u0433\u043E\u043B\u044F\u043C\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${r.origin??"\u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442"} \u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430 ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0430"}`:`\u0422\u0432\u044A\u0440\u0434\u0435 \u0433\u043E\u043B\u044F\u043C\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${r.origin??"\u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442"} \u0434\u0430 \u0431\u044A\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0422\u0432\u044A\u0440\u0434\u0435 \u043C\u0430\u043B\u043A\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${r.origin} \u0434\u0430 \u0441\u044A\u0434\u044A\u0440\u0436\u0430 ${i}${r.minimum.toString()} ${a.unit}`:`\u0422\u0432\u044A\u0440\u0434\u0435 \u043C\u0430\u043B\u043A\u043E: \u043E\u0447\u0430\u043A\u0432\u0430 \u0441\u0435 ${r.origin} \u0434\u0430 \u0431\u044A\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;if(i.format==="starts_with")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u0432\u0430 \u0441 "${i.prefix}"`;if(i.format==="ends_with")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0437\u0430\u0432\u044A\u0440\u0448\u0432\u0430 \u0441 "${i.suffix}"`;if(i.format==="includes")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0432\u043A\u043B\u044E\u0447\u0432\u0430 "${i.includes}"`;if(i.format==="regex")return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043D\u0438\u0437: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0441\u044A\u0432\u043F\u0430\u0434\u0430 \u0441 ${i.pattern}`;let a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D";return i.format==="emoji"&&(a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E"),i.format==="datetime"&&(a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E"),i.format==="date"&&(a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430"),i.format==="time"&&(a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E"),i.format==="duration"&&(a="\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430"),`${a} ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u043E \u0447\u0438\u0441\u043B\u043E: \u0442\u0440\u044F\u0431\u0432\u0430 \u0434\u0430 \u0431\u044A\u0434\u0435 \u043A\u0440\u0430\u0442\u043D\u043E \u043D\u0430 ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0437\u043F\u043E\u0437\u043D\u0430\u0442${r.keys.length>1?"\u0438":""} \u043A\u043B\u044E\u0447${r.keys.length>1?"\u043E\u0432\u0435":""}: ${w(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u043A\u043B\u044E\u0447 \u0432 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434";case"invalid_element":return`\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0430 \u0441\u0442\u043E\u0439\u043D\u043E\u0441\u0442 \u0432 ${r.origin}`;default:return"\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u0435\u043D \u0432\u0445\u043E\u0434"}}},"error");function Kl(){return{localeError:wO()}}s(Kl,"default");var OO=s(()=>{let e={string:{unit:"car\xE0cters",verb:"contenir"},file:{unit:"bytes",verb:"contenir"},array:{unit:"elements",verb:"contenir"},set:{unit:"elements",verb:"contenir"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"entrada",email:"adre\xE7a electr\xF2nica",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i hora ISO",date:"data ISO",time:"hora ISO",duration:"durada ISO",ipv4:"adre\xE7a IPv4",ipv6:"adre\xE7a IPv6",cidrv4:"rang IPv4",cidrv6:"rang IPv6",base64:"cadena codificada en base64",base64url:"cadena codificada en base64url",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Tipus inv\xE0lid: s'esperava instanceof ${r.expected}, s'ha rebut ${c}`:`Tipus inv\xE0lid: s'esperava ${i}, s'ha rebut ${c}`}case"invalid_value":return r.values.length===1?`Valor inv\xE0lid: s'esperava ${N(r.values[0])}`:`Opci\xF3 inv\xE0lida: s'esperava una de ${w(r.values," o ")}`;case"too_big":{let i=r.inclusive?"com a m\xE0xim":"menys de",a=t(r.origin);return a?`Massa gran: s'esperava que ${r.origin??"el valor"} contingu\xE9s ${i} ${r.maximum.toString()} ${a.unit??"elements"}`:`Massa gran: s'esperava que ${r.origin??"el valor"} fos ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"com a m\xEDnim":"m\xE9s de",a=t(r.origin);return a?`Massa petit: s'esperava que ${r.origin} contingu\xE9s ${i} ${r.minimum.toString()} ${a.unit}`:`Massa petit: s'esperava que ${r.origin} fos ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Format inv\xE0lid: ha de comen\xE7ar amb "${i.prefix}"`:i.format==="ends_with"?`Format inv\xE0lid: ha d'acabar amb "${i.suffix}"`:i.format==="includes"?`Format inv\xE0lid: ha d'incloure "${i.includes}"`:i.format==="regex"?`Format inv\xE0lid: ha de coincidir amb el patr\xF3 ${i.pattern}`:`Format inv\xE0lid per a ${o[i.format]??r.format}`}case"not_multiple_of":return`N\xFAmero inv\xE0lid: ha de ser m\xFAltiple de ${r.divisor}`;case"unrecognized_keys":return`Clau${r.keys.length>1?"s":""} no reconeguda${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Clau inv\xE0lida a ${r.origin}`;case"invalid_union":return"Entrada inv\xE0lida";case"invalid_element":return`Element inv\xE0lid a ${r.origin}`;default:return"Entrada inv\xE0lida"}}},"error");function Jl(){return{localeError:OO()}}s(Jl,"default");var RO=s(()=>{let e={string:{unit:"znak\u016F",verb:"m\xEDt"},file:{unit:"bajt\u016F",verb:"m\xEDt"},array:{unit:"prvk\u016F",verb:"m\xEDt"},set:{unit:"prvk\u016F",verb:"m\xEDt"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"regul\xE1rn\xED v\xFDraz",email:"e-mailov\xE1 adresa",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"datum a \u010Das ve form\xE1tu ISO",date:"datum ve form\xE1tu ISO",time:"\u010Das ve form\xE1tu ISO",duration:"doba trv\xE1n\xED ISO",ipv4:"IPv4 adresa",ipv6:"IPv6 adresa",cidrv4:"rozsah IPv4",cidrv6:"rozsah IPv6",base64:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64",base64url:"\u0159et\u011Bzec zak\xF3dovan\xFD ve form\xE1tu base64url",json_string:"\u0159et\u011Bzec ve form\xE1tu JSON",e164:"\u010D\xEDslo E.164",jwt:"JWT",template_literal:"vstup"},n={nan:"NaN",number:"\u010D\xEDslo",string:"\u0159et\u011Bzec",function:"funkce",array:"pole"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no instanceof ${r.expected}, obdr\u017Eeno ${c}`:`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${i}, obdr\u017Eeno ${c}`}case"invalid_value":return r.values.length===1?`Neplatn\xFD vstup: o\u010Dek\xE1v\xE1no ${N(r.values[0])}`:`Neplatn\xE1 mo\u017Enost: o\u010Dek\xE1v\xE1na jedna z hodnot ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.maximum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 velk\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED m\xEDt ${i}${r.minimum.toString()} ${a.unit??"prvk\u016F"}`:`Hodnota je p\u0159\xEDli\u0161 mal\xE1: ${r.origin??"hodnota"} mus\xED b\xFDt ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED za\u010D\xEDnat na "${i.prefix}"`:i.format==="ends_with"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED kon\u010Dit na "${i.suffix}"`:i.format==="includes"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED obsahovat "${i.includes}"`:i.format==="regex"?`Neplatn\xFD \u0159et\u011Bzec: mus\xED odpov\xEDdat vzoru ${i.pattern}`:`Neplatn\xFD form\xE1t ${o[i.format]??r.format}`}case"not_multiple_of":return`Neplatn\xE9 \u010D\xEDslo: mus\xED b\xFDt n\xE1sobkem ${r.divisor}`;case"unrecognized_keys":return`Nezn\xE1m\xE9 kl\xED\u010De: ${w(r.keys,", ")}`;case"invalid_key":return`Neplatn\xFD kl\xED\u010D v ${r.origin}`;case"invalid_union":return"Neplatn\xFD vstup";case"invalid_element":return`Neplatn\xE1 hodnota v ${r.origin}`;default:return"Neplatn\xFD vstup"}}},"error");function Xl(){return{localeError:RO()}}s(Xl,"default");var CO=s(()=>{let e={string:{unit:"tegn",verb:"havde"},file:{unit:"bytes",verb:"havde"},array:{unit:"elementer",verb:"indeholdt"},set:{unit:"elementer",verb:"indeholdt"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"e-mailadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkesl\xE6t",date:"ISO-dato",time:"ISO-klokkesl\xE6t",duration:"ISO-varighed",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodet streng",base64url:"base64url-kodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"},n={nan:"NaN",string:"streng",number:"tal",boolean:"boolean",array:"liste",object:"objekt",set:"s\xE6t",file:"fil"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ugyldigt input: forventede instanceof ${r.expected}, fik ${c}`:`Ugyldigt input: forventede ${i}, fik ${c}`}case"invalid_value":return r.values.length===1?`Ugyldig v\xE6rdi: forventede ${N(r.values[0])}`:`Ugyldigt valg: forventede en af f\xF8lgende ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin),c=n[r.origin]??r.origin;return a?`For stor: forventede ${c??"value"} ${a.verb} ${i} ${r.maximum.toString()} ${a.unit??"elementer"}`:`For stor: forventede ${c??"value"} havde ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin),c=n[r.origin]??r.origin;return a?`For lille: forventede ${c} ${a.verb} ${i} ${r.minimum.toString()} ${a.unit}`:`For lille: forventede ${c} havde ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ugyldig streng: skal starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: skal ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: skal indeholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: skal matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??r.format}`}case"not_multiple_of":return`Ugyldigt tal: skal v\xE6re deleligt med ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ukendte n\xF8gler":"Ukendt n\xF8gle"}: ${w(r.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8gle i ${r.origin}`;case"invalid_union":return"Ugyldigt input: matcher ingen af de tilladte typer";case"invalid_element":return`Ugyldig v\xE6rdi i ${r.origin}`;default:return"Ugyldigt input"}}},"error");function Yl(){return{localeError:CO()}}s(Yl,"default");var $O=s(()=>{let e={string:{unit:"Zeichen",verb:"zu haben"},file:{unit:"Bytes",verb:"zu haben"},array:{unit:"Elemente",verb:"zu haben"},set:{unit:"Elemente",verb:"zu haben"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"Eingabe",email:"E-Mail-Adresse",url:"URL",emoji:"Emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-Datum und -Uhrzeit",date:"ISO-Datum",time:"ISO-Uhrzeit",duration:"ISO-Dauer",ipv4:"IPv4-Adresse",ipv6:"IPv6-Adresse",cidrv4:"IPv4-Bereich",cidrv6:"IPv6-Bereich",base64:"Base64-codierter String",base64url:"Base64-URL-codierter String",json_string:"JSON-String",e164:"E.164-Nummer",jwt:"JWT",template_literal:"Eingabe"},n={nan:"NaN",number:"Zahl",array:"Array"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ung\xFCltige Eingabe: erwartet instanceof ${r.expected}, erhalten ${c}`:`Ung\xFCltige Eingabe: erwartet ${i}, erhalten ${c}`}case"invalid_value":return r.values.length===1?`Ung\xFCltige Eingabe: erwartet ${N(r.values[0])}`:`Ung\xFCltige Option: erwartet eine von ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ${a.unit??"Elemente"} hat`:`Zu gro\xDF: erwartet, dass ${r.origin??"Wert"} ${i}${r.maximum.toString()} ist`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ${a.unit} hat`:`Zu klein: erwartet, dass ${r.origin} ${i}${r.minimum.toString()} ist`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ung\xFCltiger String: muss mit "${i.prefix}" beginnen`:i.format==="ends_with"?`Ung\xFCltiger String: muss mit "${i.suffix}" enden`:i.format==="includes"?`Ung\xFCltiger String: muss "${i.includes}" enthalten`:i.format==="regex"?`Ung\xFCltiger String: muss dem Muster ${i.pattern} entsprechen`:`Ung\xFCltig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ung\xFCltige Zahl: muss ein Vielfaches von ${r.divisor} sein`;case"unrecognized_keys":return`${r.keys.length>1?"Unbekannte Schl\xFCssel":"Unbekannter Schl\xFCssel"}: ${w(r.keys,", ")}`;case"invalid_key":return`Ung\xFCltiger Schl\xFCssel in ${r.origin}`;case"invalid_union":return"Ung\xFCltige Eingabe";case"invalid_element":return`Ung\xFCltiger Wert in ${r.origin}`;default:return"Ung\xFCltige Eingabe"}}},"error");function Ql(){return{localeError:$O()}}s(Ql,"default");var NO=s(()=>{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"},map:{unit:"entries",verb:"to have"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"email address",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datetime",date:"ISO date",time:"ISO time",duration:"ISO duration",ipv4:"IPv4 address",ipv6:"IPv6 address",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"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return`Invalid input: expected ${i}, received ${c}`}case"invalid_value":return r.values.length===1?`Invalid input: expected ${N(r.values[0])}`:`Invalid option: expected one of ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Too big: expected ${r.origin??"value"} to have ${i}${r.maximum.toString()} ${a.unit??"elements"}`:`Too big: expected ${r.origin??"value"} to be ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Too small: expected ${r.origin} to have ${i}${r.minimum.toString()} ${a.unit}`:`Too small: expected ${r.origin} to be ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Invalid string: must start with "${i.prefix}"`:i.format==="ends_with"?`Invalid string: must end with "${i.suffix}"`:i.format==="includes"?`Invalid string: must include "${i.includes}"`:i.format==="regex"?`Invalid string: must match pattern ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`Invalid number: must be a multiple of ${r.divisor}`;case"unrecognized_keys":return`Unrecognized key${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Invalid key in ${r.origin}`;case"invalid_union":return"Invalid input";case"invalid_element":return`Invalid value in ${r.origin}`;default:return"Invalid input"}}},"error");function Mn(){return{localeError:NO()}}s(Mn,"default");var DO=s(()=>{let e={string:{unit:"karaktrojn",verb:"havi"},file:{unit:"bajtojn",verb:"havi"},array:{unit:"elementojn",verb:"havi"},set:{unit:"elementojn",verb:"havi"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"enigo",email:"retadreso",url:"URL",emoji:"emo\u011Dio",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datotempo",date:"ISO-dato",time:"ISO-tempo",duration:"ISO-da\u016Dro",ipv4:"IPv4-adreso",ipv6:"IPv6-adreso",cidrv4:"IPv4-rango",cidrv6:"IPv6-rango",base64:"64-ume kodita karaktraro",base64url:"URL-64-ume kodita karaktraro",json_string:"JSON-karaktraro",e164:"E.164-nombro",jwt:"JWT",template_literal:"enigo"},n={nan:"NaN",number:"nombro",array:"tabelo",null:"senvalora"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Nevalida enigo: atendi\u011Dis instanceof ${r.expected}, ricevi\u011Dis ${c}`:`Nevalida enigo: atendi\u011Dis ${i}, ricevi\u011Dis ${c}`}case"invalid_value":return r.values.length===1?`Nevalida enigo: atendi\u011Dis ${N(r.values[0])}`:`Nevalida opcio: atendi\u011Dis unu el ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Tro granda: atendi\u011Dis ke ${r.origin??"valoro"} havu ${i}${r.maximum.toString()} ${a.unit??"elementojn"}`:`Tro granda: atendi\u011Dis ke ${r.origin??"valoro"} havu ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Tro malgranda: atendi\u011Dis ke ${r.origin} havu ${i}${r.minimum.toString()} ${a.unit}`:`Tro malgranda: atendi\u011Dis ke ${r.origin} estu ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Nevalida karaktraro: devas komenci\u011Di per "${i.prefix}"`:i.format==="ends_with"?`Nevalida karaktraro: devas fini\u011Di per "${i.suffix}"`:i.format==="includes"?`Nevalida karaktraro: devas inkluzivi "${i.includes}"`:i.format==="regex"?`Nevalida karaktraro: devas kongrui kun la modelo ${i.pattern}`:`Nevalida ${o[i.format]??r.format}`}case"not_multiple_of":return`Nevalida nombro: devas esti oblo de ${r.divisor}`;case"unrecognized_keys":return`Nekonata${r.keys.length>1?"j":""} \u015Dlosilo${r.keys.length>1?"j":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Nevalida \u015Dlosilo en ${r.origin}`;case"invalid_union":return"Nevalida enigo";case"invalid_element":return`Nevalida valoro en ${r.origin}`;default:return"Nevalida enigo"}}},"error");function ed(){return{localeError:DO()}}s(ed,"default");var zO=s(()=>{let e={string:{unit:"caracteres",verb:"tener"},file:{unit:"bytes",verb:"tener"},array:{unit:"elementos",verb:"tener"},set:{unit:"elementos",verb:"tener"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"entrada",email:"direcci\xF3n de correo electr\xF3nico",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"fecha y hora ISO",date:"fecha ISO",time:"hora ISO",duration:"duraci\xF3n ISO",ipv4:"direcci\xF3n IPv4",ipv6:"direcci\xF3n IPv6",cidrv4:"rango IPv4",cidrv6:"rango IPv6",base64:"cadena codificada en base64",base64url:"URL codificada en base64",json_string:"cadena JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"},n={nan:"NaN",string:"texto",number:"n\xFAmero",boolean:"booleano",array:"arreglo",object:"objeto",set:"conjunto",file:"archivo",date:"fecha",bigint:"n\xFAmero grande",symbol:"s\xEDmbolo",undefined:"indefinido",null:"nulo",function:"funci\xF3n",map:"mapa",record:"registro",tuple:"tupla",enum:"enumeraci\xF3n",union:"uni\xF3n",literal:"literal",promise:"promesa",void:"vac\xEDo",never:"nunca",unknown:"desconocido",any:"cualquiera"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Entrada inv\xE1lida: se esperaba instanceof ${r.expected}, recibido ${c}`:`Entrada inv\xE1lida: se esperaba ${i}, recibido ${c}`}case"invalid_value":return r.values.length===1?`Entrada inv\xE1lida: se esperaba ${N(r.values[0])}`:`Opci\xF3n inv\xE1lida: se esperaba una de ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin),c=n[r.origin]??r.origin;return a?`Demasiado grande: se esperaba que ${c??"valor"} tuviera ${i}${r.maximum.toString()} ${a.unit??"elementos"}`:`Demasiado grande: se esperaba que ${c??"valor"} fuera ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin),c=n[r.origin]??r.origin;return a?`Demasiado peque\xF1o: se esperaba que ${c} tuviera ${i}${r.minimum.toString()} ${a.unit}`:`Demasiado peque\xF1o: se esperaba que ${c} fuera ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cadena inv\xE1lida: debe comenzar con "${i.prefix}"`:i.format==="ends_with"?`Cadena inv\xE1lida: debe terminar en "${i.suffix}"`:i.format==="includes"?`Cadena inv\xE1lida: debe incluir "${i.includes}"`:i.format==="regex"?`Cadena inv\xE1lida: debe coincidir con el patr\xF3n ${i.pattern}`:`Inv\xE1lido ${o[i.format]??r.format}`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: debe ser m\xFAltiplo de ${r.divisor}`;case"unrecognized_keys":return`Llave${r.keys.length>1?"s":""} desconocida${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Llave inv\xE1lida en ${n[r.origin]??r.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido en ${n[r.origin]??r.origin}`;default:return"Entrada inv\xE1lida"}}},"error");function td(){return{localeError:zO()}}s(td,"default");var MO=s(()=>{let e={string:{unit:"\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},file:{unit:"\u0628\u0627\u06CC\u062A",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},array:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"},set:{unit:"\u0622\u06CC\u062A\u0645",verb:"\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0648\u0631\u0648\u062F\u06CC",email:"\u0622\u062F\u0631\u0633 \u0627\u06CC\u0645\u06CC\u0644",url:"URL",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u062A\u0627\u0631\u06CC\u062E \u0648 \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",date:"\u062A\u0627\u0631\u06CC\u062E \u0627\u06CC\u0632\u0648",time:"\u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",duration:"\u0645\u062F\u062A \u0632\u0645\u0627\u0646 \u0627\u06CC\u0632\u0648",ipv4:"IPv4 \u0622\u062F\u0631\u0633",ipv6:"IPv6 \u0622\u062F\u0631\u0633",cidrv4:"IPv4 \u062F\u0627\u0645\u0646\u0647",cidrv6:"IPv6 \u062F\u0627\u0645\u0646\u0647",base64:"base64-encoded \u0631\u0634\u062A\u0647",base64url:"base64url-encoded \u0631\u0634\u062A\u0647",json_string:"JSON \u0631\u0634\u062A\u0647",e164:"E.164 \u0639\u062F\u062F",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u06CC"},n={nan:"NaN",number:"\u0639\u062F\u062F",array:"\u0622\u0631\u0627\u06CC\u0647"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A instanceof ${r.expected} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${c} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`:`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${i} \u0645\u06CC\u200C\u0628\u0648\u062F\u060C ${c} \u062F\u0631\u06CC\u0627\u0641\u062A \u0634\u062F`}case"invalid_value":return r.values.length===1?`\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A ${N(r.values[0])} \u0645\u06CC\u200C\u0628\u0648\u062F`:`\u06AF\u0632\u06CC\u0646\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0645\u06CC\u200C\u0628\u0627\u06CC\u0633\u062A \u06CC\u06A9\u06CC \u0627\u0632 ${w(r.values,"|")} \u0645\u06CC\u200C\u0628\u0648\u062F`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631"} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u0628\u0632\u0631\u06AF: ${r.origin??"\u0645\u0642\u062F\u0627\u0631"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0628\u0627\u0634\u062F`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0628\u0627\u0634\u062F`:`\u062E\u06CC\u0644\u06CC \u06A9\u0648\u0686\u06A9: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0628\u0627\u0634\u062F`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.prefix}" \u0634\u0631\u0648\u0639 \u0634\u0648\u062F`:i.format==="ends_with"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 "${i.suffix}" \u062A\u0645\u0627\u0645 \u0634\u0648\u062F`:i.format==="includes"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0634\u0627\u0645\u0644 "${i.includes}" \u0628\u0627\u0634\u062F`:i.format==="regex"?`\u0631\u0634\u062A\u0647 \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0628\u0627 \u0627\u0644\u06AF\u0648\u06CC ${i.pattern} \u0645\u0637\u0627\u0628\u0642\u062A \u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F`:`${o[i.format]??r.format} \u0646\u0627\u0645\u0639\u062A\u0628\u0631`}case"not_multiple_of":return`\u0639\u062F\u062F \u0646\u0627\u0645\u0639\u062A\u0628\u0631: \u0628\u0627\u06CC\u062F \u0645\u0636\u0631\u0628 ${r.divisor} \u0628\u0627\u0634\u062F`;case"unrecognized_keys":return`\u06A9\u0644\u06CC\u062F${r.keys.length>1?"\u0647\u0627\u06CC":""} \u0646\u0627\u0634\u0646\u0627\u0633: ${w(r.keys,", ")}`;case"invalid_key":return`\u06A9\u0644\u06CC\u062F \u0646\u0627\u0634\u0646\u0627\u0633 \u062F\u0631 ${r.origin}`;case"invalid_union":return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631";case"invalid_element":return`\u0645\u0642\u062F\u0627\u0631 \u0646\u0627\u0645\u0639\u062A\u0628\u0631 \u062F\u0631 ${r.origin}`;default:return"\u0648\u0631\u0648\u062F\u06CC \u0646\u0627\u0645\u0639\u062A\u0628\u0631"}}},"error");function rd(){return{localeError:MO()}}s(rd,"default");var LO=s(()=>{let e={string:{unit:"merkki\xE4",subject:"merkkijonon"},file:{unit:"tavua",subject:"tiedoston"},array:{unit:"alkiota",subject:"listan"},set:{unit:"alkiota",subject:"joukon"},number:{unit:"",subject:"luvun"},bigint:{unit:"",subject:"suuren kokonaisluvun"},int:{unit:"",subject:"kokonaisluvun"},date:{unit:"",subject:"p\xE4iv\xE4m\xE4\xE4r\xE4n"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"s\xE4\xE4nn\xF6llinen lauseke",email:"s\xE4hk\xF6postiosoite",url:"URL-osoite",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-aikaleima",date:"ISO-p\xE4iv\xE4m\xE4\xE4r\xE4",time:"ISO-aika",duration:"ISO-kesto",ipv4:"IPv4-osoite",ipv6:"IPv6-osoite",cidrv4:"IPv4-alue",cidrv6:"IPv6-alue",base64:"base64-koodattu merkkijono",base64url:"base64url-koodattu merkkijono",json_string:"JSON-merkkijono",e164:"E.164-luku",jwt:"JWT",template_literal:"templaattimerkkijono"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Virheellinen tyyppi: odotettiin instanceof ${r.expected}, oli ${c}`:`Virheellinen tyyppi: odotettiin ${i}, oli ${c}`}case"invalid_value":return r.values.length===1?`Virheellinen sy\xF6te: t\xE4ytyy olla ${N(r.values[0])}`:`Virheellinen valinta: t\xE4ytyy olla yksi seuraavista: ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Liian suuri: ${a.subject} t\xE4ytyy olla ${i}${r.maximum.toString()} ${a.unit}`.trim():`Liian suuri: arvon t\xE4ytyy olla ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Liian pieni: ${a.subject} t\xE4ytyy olla ${i}${r.minimum.toString()} ${a.unit}`.trim():`Liian pieni: arvon t\xE4ytyy olla ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Virheellinen sy\xF6te: t\xE4ytyy alkaa "${i.prefix}"`:i.format==="ends_with"?`Virheellinen sy\xF6te: t\xE4ytyy loppua "${i.suffix}"`:i.format==="includes"?`Virheellinen sy\xF6te: t\xE4ytyy sis\xE4lt\xE4\xE4 "${i.includes}"`:i.format==="regex"?`Virheellinen sy\xF6te: t\xE4ytyy vastata s\xE4\xE4nn\xF6llist\xE4 lauseketta ${i.pattern}`:`Virheellinen ${o[i.format]??r.format}`}case"not_multiple_of":return`Virheellinen luku: t\xE4ytyy olla luvun ${r.divisor} monikerta`;case"unrecognized_keys":return`${r.keys.length>1?"Tuntemattomat avaimet":"Tuntematon avain"}: ${w(r.keys,", ")}`;case"invalid_key":return"Virheellinen avain tietueessa";case"invalid_union":return"Virheellinen unioni";case"invalid_element":return"Virheellinen arvo joukossa";default:return"Virheellinen sy\xF6te"}}},"error");function od(){return{localeError:LO()}}s(od,"default");var UO=s(()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"entr\xE9e",email:"adresse e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date et heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"},n={nan:"NaN",number:"nombre",array:"tableau"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Entr\xE9e invalide : instanceof ${r.expected} attendu, ${c} re\xE7u`:`Entr\xE9e invalide : ${i} attendu, ${c} re\xE7u`}case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : ${N(r.values[0])} attendu`:`Option invalide : une valeur parmi ${w(r.values,"|")} attendue`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Trop grand : ${r.origin??"valeur"} doit ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\xE9l\xE9ment(s)"}`:`Trop grand : ${r.origin??"valeur"} doit \xEAtre ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Trop petit : ${r.origin} doit ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : ${r.origin} doit \xEAtre ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au mod\xE8le ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${w(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}},"error");function nd(){return{localeError:UO()}}s(nd,"default");var qO=s(()=>{let e={string:{unit:"caract\xE8res",verb:"avoir"},file:{unit:"octets",verb:"avoir"},array:{unit:"\xE9l\xE9ments",verb:"avoir"},set:{unit:"\xE9l\xE9ments",verb:"avoir"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"entr\xE9e",email:"adresse courriel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"date-heure ISO",date:"date ISO",time:"heure ISO",duration:"dur\xE9e ISO",ipv4:"adresse IPv4",ipv6:"adresse IPv6",cidrv4:"plage IPv4",cidrv6:"plage IPv6",base64:"cha\xEEne encod\xE9e en base64",base64url:"cha\xEEne encod\xE9e en base64url",json_string:"cha\xEEne JSON",e164:"num\xE9ro E.164",jwt:"JWT",template_literal:"entr\xE9e"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Entr\xE9e invalide : attendu instanceof ${r.expected}, re\xE7u ${c}`:`Entr\xE9e invalide : attendu ${i}, re\xE7u ${c}`}case"invalid_value":return r.values.length===1?`Entr\xE9e invalide : attendu ${N(r.values[0])}`:`Option invalide : attendu l'une des valeurs suivantes ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u2264":"<",a=t(r.origin);return a?`Trop grand : attendu que ${r.origin??"la valeur"} ait ${i}${r.maximum.toString()} ${a.unit}`:`Trop grand : attendu que ${r.origin??"la valeur"} soit ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u2265":">",a=t(r.origin);return a?`Trop petit : attendu que ${r.origin} ait ${i}${r.minimum.toString()} ${a.unit}`:`Trop petit : attendu que ${r.origin} soit ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Cha\xEEne invalide : doit commencer par "${i.prefix}"`:i.format==="ends_with"?`Cha\xEEne invalide : doit se terminer par "${i.suffix}"`:i.format==="includes"?`Cha\xEEne invalide : doit inclure "${i.includes}"`:i.format==="regex"?`Cha\xEEne invalide : doit correspondre au motif ${i.pattern}`:`${o[i.format]??r.format} invalide`}case"not_multiple_of":return`Nombre invalide : doit \xEAtre un multiple de ${r.divisor}`;case"unrecognized_keys":return`Cl\xE9${r.keys.length>1?"s":""} non reconnue${r.keys.length>1?"s":""} : ${w(r.keys,", ")}`;case"invalid_key":return`Cl\xE9 invalide dans ${r.origin}`;case"invalid_union":return"Entr\xE9e invalide";case"invalid_element":return`Valeur invalide dans ${r.origin}`;default:return"Entr\xE9e invalide"}}},"error");function id(){return{localeError:qO()}}s(id,"default");var jO=s(()=>{let e={string:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA",gender:"f"},number:{label:"\u05DE\u05E1\u05E4\u05E8",gender:"m"},boolean:{label:"\u05E2\u05E8\u05DA \u05D1\u05D5\u05DC\u05D9\u05D0\u05E0\u05D9",gender:"m"},bigint:{label:"BigInt",gender:"m"},date:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA",gender:"m"},array:{label:"\u05DE\u05E2\u05E8\u05DA",gender:"m"},object:{label:"\u05D0\u05D5\u05D1\u05D9\u05D9\u05E7\u05D8",gender:"m"},null:{label:"\u05E2\u05E8\u05DA \u05E8\u05D9\u05E7 (null)",gender:"m"},undefined:{label:"\u05E2\u05E8\u05DA \u05DC\u05D0 \u05DE\u05D5\u05D2\u05D3\u05E8 (undefined)",gender:"m"},symbol:{label:"\u05E1\u05D9\u05DE\u05D1\u05D5\u05DC (Symbol)",gender:"m"},function:{label:"\u05E4\u05D5\u05E0\u05E7\u05E6\u05D9\u05D4",gender:"f"},map:{label:"\u05DE\u05E4\u05D4 (Map)",gender:"f"},set:{label:"\u05E7\u05D1\u05D5\u05E6\u05D4 (Set)",gender:"f"},file:{label:"\u05E7\u05D5\u05D1\u05E5",gender:"m"},promise:{label:"Promise",gender:"m"},NaN:{label:"NaN",gender:"m"},unknown:{label:"\u05E2\u05E8\u05DA \u05DC\u05D0 \u05D9\u05D3\u05D5\u05E2",gender:"m"},value:{label:"\u05E2\u05E8\u05DA",gender:"m"}},t={string:{unit:"\u05EA\u05D5\u05D5\u05D9\u05DD",shortLabel:"\u05E7\u05E6\u05E8",longLabel:"\u05D0\u05E8\u05D5\u05DA"},file:{unit:"\u05D1\u05D9\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},array:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},set:{unit:"\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"},number:{unit:"",shortLabel:"\u05E7\u05D8\u05DF",longLabel:"\u05D2\u05D3\u05D5\u05DC"}},o=s(m=>m?e[m]:void 0,"typeEntry"),n=s(m=>{let l=o(m);return l?l.label:m??e.unknown.label},"typeLabel"),r=s(m=>`\u05D4${n(m)}`,"withDefinite"),i=s(m=>(o(m)?.gender??"m")==="f"?"\u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05D9\u05D5\u05EA":"\u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA","verbFor"),a=s(m=>m?t[m]??null:null,"getSizing"),c={regex:{label:"\u05E7\u05DC\u05D8",gender:"m"},email:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05D0\u05D9\u05DE\u05D9\u05D9\u05DC",gender:"f"},url:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA \u05E8\u05E9\u05EA",gender:"f"},emoji:{label:"\u05D0\u05D9\u05DE\u05D5\u05D2'\u05D9",gender:"m"},uuid:{label:"UUID",gender:"m"},nanoid:{label:"nanoid",gender:"m"},guid:{label:"GUID",gender:"m"},cuid:{label:"cuid",gender:"m"},cuid2:{label:"cuid2",gender:"m"},ulid:{label:"ULID",gender:"m"},xid:{label:"XID",gender:"m"},ksuid:{label:"KSUID",gender:"m"},datetime:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA \u05D5\u05D6\u05DE\u05DF ISO",gender:"m"},date:{label:"\u05EA\u05D0\u05E8\u05D9\u05DA ISO",gender:"m"},time:{label:"\u05D6\u05DE\u05DF ISO",gender:"m"},duration:{label:"\u05DE\u05E9\u05DA \u05D6\u05DE\u05DF ISO",gender:"m"},ipv4:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv4",gender:"f"},ipv6:{label:"\u05DB\u05EA\u05D5\u05D1\u05EA IPv6",gender:"f"},cidrv4:{label:"\u05D8\u05D5\u05D5\u05D7 IPv4",gender:"m"},cidrv6:{label:"\u05D8\u05D5\u05D5\u05D7 IPv6",gender:"m"},base64:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64",gender:"f"},base64url:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D1\u05D1\u05E1\u05D9\u05E1 64 \u05DC\u05DB\u05EA\u05D5\u05D1\u05D5\u05EA \u05E8\u05E9\u05EA",gender:"f"},json_string:{label:"\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA JSON",gender:"f"},e164:{label:"\u05DE\u05E1\u05E4\u05E8 E.164",gender:"m"},jwt:{label:"JWT",gender:"m"},ends_with:{label:"\u05E7\u05DC\u05D8",gender:"m"},includes:{label:"\u05E7\u05DC\u05D8",gender:"m"},lowercase:{label:"\u05E7\u05DC\u05D8",gender:"m"},starts_with:{label:"\u05E7\u05DC\u05D8",gender:"m"},uppercase:{label:"\u05E7\u05DC\u05D8",gender:"m"}},p={nan:"NaN"};return m=>{switch(m.code){case"invalid_type":{let l=m.expected,g=p[l??""]??n(l),h=z(m.input),f=p[h]??e[h]?.label??h;return/^[A-Z]/.test(m.expected)?`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA instanceof ${m.expected}, \u05D4\u05EA\u05E7\u05D1\u05DC ${f}`:`\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${g}, \u05D4\u05EA\u05E7\u05D1\u05DC ${f}`}case"invalid_value":{if(m.values.length===1)return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05E2\u05E8\u05DA \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA ${N(m.values[0])}`;let l=m.values.map(f=>N(f));if(m.values.length===2)return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA \u05D4\u05DE\u05EA\u05D0\u05D9\u05DE\u05D5\u05EA \u05D4\u05DF ${l[0]} \u05D0\u05D5 ${l[1]}`;let g=l[l.length-1];return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D4\u05D0\u05E4\u05E9\u05E8\u05D5\u05D9\u05D5\u05EA \u05D4\u05DE\u05EA\u05D0\u05D9\u05DE\u05D5\u05EA \u05D4\u05DF ${l.slice(0,-1).join(", ")} \u05D0\u05D5 ${g}`}case"too_big":{let l=a(m.origin),g=r(m.origin??"value");if(m.origin==="string")return`${l?.longLabel??"\u05D0\u05E8\u05D5\u05DA"} \u05DE\u05D3\u05D9: ${g} \u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05DB\u05D9\u05DC ${m.maximum.toString()} ${l?.unit??""} ${m.inclusive?"\u05D0\u05D5 \u05E4\u05D7\u05D5\u05EA":"\u05DC\u05DB\u05DC \u05D4\u05D9\u05D5\u05EA\u05E8"}`.trim();if(m.origin==="number"){let v=m.inclusive?`\u05E7\u05D8\u05DF \u05D0\u05D5 \u05E9\u05D5\u05D5\u05D4 \u05DC-${m.maximum}`:`\u05E7\u05D8\u05DF \u05DE-${m.maximum}`;return`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${g} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${v}`}if(m.origin==="array"||m.origin==="set"){let v=m.origin==="set"?"\u05E6\u05E8\u05D9\u05DB\u05D4":"\u05E6\u05E8\u05D9\u05DA",I=m.inclusive?`${m.maximum} ${l?.unit??""} \u05D0\u05D5 \u05E4\u05D7\u05D5\u05EA`:`\u05E4\u05D7\u05D5\u05EA \u05DE-${m.maximum} ${l?.unit??""}`;return`\u05D2\u05D3\u05D5\u05DC \u05DE\u05D3\u05D9: ${g} ${v} \u05DC\u05D4\u05DB\u05D9\u05DC ${I}`.trim()}let h=m.inclusive?"<=":"<",f=i(m.origin??"value");return l?.unit?`${l.longLabel} \u05DE\u05D3\u05D9: ${g} ${f} ${h}${m.maximum.toString()} ${l.unit}`:`${l?.longLabel??"\u05D2\u05D3\u05D5\u05DC"} \u05DE\u05D3\u05D9: ${g} ${f} ${h}${m.maximum.toString()}`}case"too_small":{let l=a(m.origin),g=r(m.origin??"value");if(m.origin==="string")return`${l?.shortLabel??"\u05E7\u05E6\u05E8"} \u05DE\u05D3\u05D9: ${g} \u05E6\u05E8\u05D9\u05DB\u05D4 \u05DC\u05D4\u05DB\u05D9\u05DC ${m.minimum.toString()} ${l?.unit??""} ${m.inclusive?"\u05D0\u05D5 \u05D9\u05D5\u05EA\u05E8":"\u05DC\u05E4\u05D7\u05D5\u05EA"}`.trim();if(m.origin==="number"){let v=m.inclusive?`\u05D2\u05D3\u05D5\u05DC \u05D0\u05D5 \u05E9\u05D5\u05D5\u05D4 \u05DC-${m.minimum}`:`\u05D2\u05D3\u05D5\u05DC \u05DE-${m.minimum}`;return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${g} \u05E6\u05E8\u05D9\u05DA \u05DC\u05D4\u05D9\u05D5\u05EA ${v}`}if(m.origin==="array"||m.origin==="set"){let v=m.origin==="set"?"\u05E6\u05E8\u05D9\u05DB\u05D4":"\u05E6\u05E8\u05D9\u05DA";if(m.minimum===1&&m.inclusive){let T=(m.origin==="set","\u05DC\u05E4\u05D7\u05D5\u05EA \u05E4\u05E8\u05D9\u05D8 \u05D0\u05D7\u05D3");return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${g} ${v} \u05DC\u05D4\u05DB\u05D9\u05DC ${T}`}let I=m.inclusive?`${m.minimum} ${l?.unit??""} \u05D0\u05D5 \u05D9\u05D5\u05EA\u05E8`:`\u05D9\u05D5\u05EA\u05E8 \u05DE-${m.minimum} ${l?.unit??""}`;return`\u05E7\u05D8\u05DF \u05DE\u05D3\u05D9: ${g} ${v} \u05DC\u05D4\u05DB\u05D9\u05DC ${I}`.trim()}let h=m.inclusive?">=":">",f=i(m.origin??"value");return l?.unit?`${l.shortLabel} \u05DE\u05D3\u05D9: ${g} ${f} ${h}${m.minimum.toString()} ${l.unit}`:`${l?.shortLabel??"\u05E7\u05D8\u05DF"} \u05DE\u05D3\u05D9: ${g} ${f} ${h}${m.minimum.toString()}`}case"invalid_format":{let l=m;if(l.format==="starts_with")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D7\u05D9\u05DC \u05D1 "${l.prefix}"`;if(l.format==="ends_with")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05E1\u05EA\u05D9\u05D9\u05DD \u05D1 "${l.suffix}"`;if(l.format==="includes")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05DB\u05DC\u05D5\u05DC "${l.includes}"`;if(l.format==="regex")return`\u05D4\u05DE\u05D7\u05E8\u05D5\u05D6\u05EA \u05D7\u05D9\u05D9\u05D1\u05EA \u05DC\u05D4\u05EA\u05D0\u05D9\u05DD \u05DC\u05EA\u05D1\u05E0\u05D9\u05EA ${l.pattern}`;let g=c[l.format],h=g?.label??l.format,v=(g?.gender??"m")==="f"?"\u05EA\u05E7\u05D9\u05E0\u05D4":"\u05EA\u05E7\u05D9\u05DF";return`${h} \u05DC\u05D0 ${v}`}case"not_multiple_of":return`\u05DE\u05E1\u05E4\u05E8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF: \u05D7\u05D9\u05D9\u05D1 \u05DC\u05D4\u05D9\u05D5\u05EA \u05DE\u05DB\u05E4\u05DC\u05D4 \u05E9\u05DC ${m.divisor}`;case"unrecognized_keys":return`\u05DE\u05E4\u05EA\u05D7${m.keys.length>1?"\u05D5\u05EA":""} \u05DC\u05D0 \u05DE\u05D6\u05D5\u05D4${m.keys.length>1?"\u05D9\u05DD":"\u05D4"}: ${w(m.keys,", ")}`;case"invalid_key":return"\u05E9\u05D3\u05D4 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1\u05D0\u05D5\u05D1\u05D9\u05D9\u05E7\u05D8";case"invalid_union":return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF";case"invalid_element":return`\u05E2\u05E8\u05DA \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF \u05D1${r(m.origin??"array")}`;default:return"\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF"}}},"error");function ad(){return{localeError:jO()}}s(ad,"default");var FO=s(()=>{let e={string:{unit:"karakter",verb:"legyen"},file:{unit:"byte",verb:"legyen"},array:{unit:"elem",verb:"legyen"},set:{unit:"elem",verb:"legyen"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"bemenet",email:"email c\xEDm",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO id\u0151b\xE9lyeg",date:"ISO d\xE1tum",time:"ISO id\u0151",duration:"ISO id\u0151intervallum",ipv4:"IPv4 c\xEDm",ipv6:"IPv6 c\xEDm",cidrv4:"IPv4 tartom\xE1ny",cidrv6:"IPv6 tartom\xE1ny",base64:"base64-k\xF3dolt string",base64url:"base64url-k\xF3dolt string",json_string:"JSON string",e164:"E.164 sz\xE1m",jwt:"JWT",template_literal:"bemenet"},n={nan:"NaN",number:"sz\xE1m",array:"t\xF6mb"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k instanceof ${r.expected}, a kapott \xE9rt\xE9k ${c}`:`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${i}, a kapott \xE9rt\xE9k ${c}`}case"invalid_value":return r.values.length===1?`\xC9rv\xE9nytelen bemenet: a v\xE1rt \xE9rt\xE9k ${N(r.values[0])}`:`\xC9rv\xE9nytelen opci\xF3: valamelyik \xE9rt\xE9k v\xE1rt ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xFAl nagy: ${r.origin??"\xE9rt\xE9k"} m\xE9rete t\xFAl nagy ${i}${r.maximum.toString()} ${a.unit??"elem"}`:`T\xFAl nagy: a bemeneti \xE9rt\xE9k ${r.origin??"\xE9rt\xE9k"} t\xFAl nagy: ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} m\xE9rete t\xFAl kicsi ${i}${r.minimum.toString()} ${a.unit}`:`T\xFAl kicsi: a bemeneti \xE9rt\xE9k ${r.origin} t\xFAl kicsi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\xC9rv\xE9nytelen string: "${i.prefix}" \xE9rt\xE9kkel kell kezd\u0151dnie`:i.format==="ends_with"?`\xC9rv\xE9nytelen string: "${i.suffix}" \xE9rt\xE9kkel kell v\xE9gz\u0151dnie`:i.format==="includes"?`\xC9rv\xE9nytelen string: "${i.includes}" \xE9rt\xE9ket kell tartalmaznia`:i.format==="regex"?`\xC9rv\xE9nytelen string: ${i.pattern} mint\xE1nak kell megfelelnie`:`\xC9rv\xE9nytelen ${o[i.format]??r.format}`}case"not_multiple_of":return`\xC9rv\xE9nytelen sz\xE1m: ${r.divisor} t\xF6bbsz\xF6r\xF6s\xE9nek kell lennie`;case"unrecognized_keys":return`Ismeretlen kulcs${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`\xC9rv\xE9nytelen kulcs ${r.origin}`;case"invalid_union":return"\xC9rv\xE9nytelen bemenet";case"invalid_element":return`\xC9rv\xE9nytelen \xE9rt\xE9k: ${r.origin}`;default:return"\xC9rv\xE9nytelen bemenet"}}},"error");function sd(){return{localeError:FO()}}s(sd,"default");function Tg(e,t,o){return Math.abs(e)===1?t:o}s(Tg,"getArmenianPlural");function uo(e){if(!e)return"";let t=["\u0561","\u0565","\u0568","\u056B","\u0578","\u0578\u0582","\u0585"],o=e[e.length-1];return e+(t.includes(o)?"\u0576":"\u0568")}s(uo,"withDefiniteArticle");var BO=s(()=>{let e={string:{unit:{one:"\u0576\u0577\u0561\u0576",many:"\u0576\u0577\u0561\u0576\u0576\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},file:{unit:{one:"\u0562\u0561\u0575\u0569",many:"\u0562\u0561\u0575\u0569\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},array:{unit:{one:"\u057F\u0561\u0580\u0580",many:"\u057F\u0561\u0580\u0580\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"},set:{unit:{one:"\u057F\u0561\u0580\u0580",many:"\u057F\u0561\u0580\u0580\u0565\u0580"},verb:"\u0578\u0582\u0576\u0565\u0576\u0561\u056C"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0574\u0578\u0582\u057F\u0584",email:"\u0567\u056C. \u0570\u0561\u057D\u0581\u0565",url:"URL",emoji:"\u0567\u0574\u0578\u057B\u056B",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0561\u0574\u057D\u0561\u0569\u056B\u057E \u0587 \u056A\u0561\u0574",date:"ISO \u0561\u0574\u057D\u0561\u0569\u056B\u057E",time:"ISO \u056A\u0561\u0574",duration:"ISO \u057F\u0587\u0578\u0572\u0578\u0582\u0569\u0575\u0578\u0582\u0576",ipv4:"IPv4 \u0570\u0561\u057D\u0581\u0565",ipv6:"IPv6 \u0570\u0561\u057D\u0581\u0565",cidrv4:"IPv4 \u0574\u056B\u057B\u0561\u056F\u0561\u0575\u0584",cidrv6:"IPv6 \u0574\u056B\u057B\u0561\u056F\u0561\u0575\u0584",base64:"base64 \u0571\u0587\u0561\u0579\u0561\u0583\u0578\u057E \u057F\u0578\u0572",base64url:"base64url \u0571\u0587\u0561\u0579\u0561\u0583\u0578\u057E \u057F\u0578\u0572",json_string:"JSON \u057F\u0578\u0572",e164:"E.164 \u0570\u0561\u0574\u0561\u0580",jwt:"JWT",template_literal:"\u0574\u0578\u0582\u057F\u0584"},n={nan:"NaN",number:"\u0569\u056B\u057E",array:"\u0566\u0561\u0576\u0563\u057E\u0561\u056E"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 instanceof ${r.expected}, \u057D\u057F\u0561\u0581\u057E\u0565\u056C \u0567 ${c}`:`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 ${i}, \u057D\u057F\u0561\u0581\u057E\u0565\u056C \u0567 ${c}`}case"invalid_value":return r.values.length===1?`\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 ${N(r.values[1])}`:`\u054D\u056D\u0561\u056C \u057F\u0561\u0580\u0562\u0565\u0580\u0561\u056F\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567\u0580 \u0570\u0565\u057F\u0587\u0575\u0561\u056C\u0576\u0565\u0580\u056B\u0581 \u0574\u0565\u056F\u0568\u055D ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let c=Number(r.maximum),p=Tg(c,a.unit.one,a.unit.many);return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0574\u0565\u056E \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${uo(r.origin??"\u0561\u0580\u056A\u0565\u0584")} \u056F\u0578\u0582\u0576\u0565\u0576\u0561 ${i}${r.maximum.toString()} ${p}`}return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0574\u0565\u056E \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${uo(r.origin??"\u0561\u0580\u056A\u0565\u0584")} \u056C\u056B\u0576\u056B ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let c=Number(r.minimum),p=Tg(c,a.unit.one,a.unit.many);return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0583\u0578\u0584\u0580 \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${uo(r.origin)} \u056F\u0578\u0582\u0576\u0565\u0576\u0561 ${i}${r.minimum.toString()} ${p}`}return`\u0549\u0561\u0583\u0561\u0566\u0561\u0576\u0581 \u0583\u0578\u0584\u0580 \u0561\u0580\u056A\u0565\u0584\u2024 \u057D\u057A\u0561\u057D\u057E\u0578\u0582\u0574 \u0567, \u0578\u0580 ${uo(r.origin)} \u056C\u056B\u0576\u056B ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u057D\u056F\u057D\u057E\u056B "${i.prefix}"-\u0578\u057E`:i.format==="ends_with"?`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0561\u057E\u0561\u0580\u057F\u057E\u056B "${i.suffix}"-\u0578\u057E`:i.format==="includes"?`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u057A\u0561\u0580\u0578\u0582\u0576\u0561\u056F\u056B "${i.includes}"`:i.format==="regex"?`\u054D\u056D\u0561\u056C \u057F\u0578\u0572\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0570\u0561\u0574\u0561\u057A\u0561\u057F\u0561\u057D\u056D\u0561\u0576\u056B ${i.pattern} \u0571\u0587\u0561\u0579\u0561\u0583\u056B\u0576`:`\u054D\u056D\u0561\u056C ${o[i.format]??r.format}`}case"not_multiple_of":return`\u054D\u056D\u0561\u056C \u0569\u056B\u057E\u2024 \u057A\u0565\u057F\u0584 \u0567 \u0562\u0561\u0566\u0574\u0561\u057A\u0561\u057F\u056B\u056F \u056C\u056B\u0576\u056B ${r.divisor}-\u056B`;case"unrecognized_keys":return`\u0549\u0573\u0561\u0576\u0561\u0579\u057E\u0561\u056E \u0562\u0561\u0576\u0561\u056C\u056B${r.keys.length>1?"\u0576\u0565\u0580":""}. ${w(r.keys,", ")}`;case"invalid_key":return`\u054D\u056D\u0561\u056C \u0562\u0561\u0576\u0561\u056C\u056B ${uo(r.origin)}-\u0578\u0582\u0574`;case"invalid_union":return"\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574";case"invalid_element":return`\u054D\u056D\u0561\u056C \u0561\u0580\u056A\u0565\u0584 ${uo(r.origin)}-\u0578\u0582\u0574`;default:return"\u054D\u056D\u0561\u056C \u0574\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0578\u0582\u0574"}}},"error");function cd(){return{localeError:BO()}}s(cd,"default");var ZO=s(()=>{let e={string:{unit:"karakter",verb:"memiliki"},file:{unit:"byte",verb:"memiliki"},array:{unit:"item",verb:"memiliki"},set:{unit:"item",verb:"memiliki"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"alamat email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tanggal dan waktu format ISO",date:"tanggal format ISO",time:"jam format ISO",duration:"durasi format ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"rentang alamat IPv4",cidrv6:"rentang alamat IPv6",base64:"string dengan enkode base64",base64url:"string dengan enkode base64url",json_string:"string JSON",e164:"angka E.164",jwt:"JWT",template_literal:"input"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Input tidak valid: diharapkan instanceof ${r.expected}, diterima ${c}`:`Input tidak valid: diharapkan ${i}, diterima ${c}`}case"invalid_value":return r.values.length===1?`Input tidak valid: diharapkan ${N(r.values[0])}`:`Pilihan tidak valid: diharapkan salah satu dari ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: diharapkan ${r.origin??"value"} memiliki ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: diharapkan ${r.origin??"value"} menjadi ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: diharapkan ${r.origin} memiliki ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: diharapkan ${r.origin} menjadi ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak valid: harus dimulai dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak valid: harus berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak valid: harus menyertakan "${i.includes}"`:i.format==="regex"?`String tidak valid: harus sesuai pola ${i.pattern}`:`${o[i.format]??r.format} tidak valid`}case"not_multiple_of":return`Angka tidak valid: harus kelipatan dari ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali ${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Kunci tidak valid di ${r.origin}`;case"invalid_union":return"Input tidak valid";case"invalid_element":return`Nilai tidak valid di ${r.origin}`;default:return"Input tidak valid"}}},"error");function ud(){return{localeError:ZO()}}s(ud,"default");var VO=s(()=>{let e={string:{unit:"stafi",verb:"a\xF0 hafa"},file:{unit:"b\xE6ti",verb:"a\xF0 hafa"},array:{unit:"hluti",verb:"a\xF0 hafa"},set:{unit:"hluti",verb:"a\xF0 hafa"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"gildi",email:"netfang",url:"vefsl\xF3\xF0",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dagsetning og t\xEDmi",date:"ISO dagsetning",time:"ISO t\xEDmi",duration:"ISO t\xEDmalengd",ipv4:"IPv4 address",ipv6:"IPv6 address",cidrv4:"IPv4 range",cidrv6:"IPv6 range",base64:"base64-encoded strengur",base64url:"base64url-encoded strengur",json_string:"JSON strengur",e164:"E.164 t\xF6lugildi",jwt:"JWT",template_literal:"gildi"},n={nan:"NaN",number:"n\xFAmer",array:"fylki"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Rangt gildi: \xDE\xFA sl\xF3st inn ${c} \xFEar sem \xE1 a\xF0 vera instanceof ${r.expected}`:`Rangt gildi: \xDE\xFA sl\xF3st inn ${c} \xFEar sem \xE1 a\xF0 vera ${i}`}case"invalid_value":return r.values.length===1?`Rangt gildi: gert r\xE1\xF0 fyrir ${N(r.values[0])}`:`\xD3gilt val: m\xE1 vera eitt af eftirfarandi ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${r.origin??"gildi"} hafi ${i}${r.maximum.toString()} ${a.unit??"hluti"}`:`Of st\xF3rt: gert er r\xE1\xF0 fyrir a\xF0 ${r.origin??"gildi"} s\xE9 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${r.origin} hafi ${i}${r.minimum.toString()} ${a.unit}`:`Of l\xEDti\xF0: gert er r\xE1\xF0 fyrir a\xF0 ${r.origin} s\xE9 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 byrja \xE1 "${i.prefix}"`:i.format==="ends_with"?`\xD3gildur strengur: ver\xF0ur a\xF0 enda \xE1 "${i.suffix}"`:i.format==="includes"?`\xD3gildur strengur: ver\xF0ur a\xF0 innihalda "${i.includes}"`:i.format==="regex"?`\xD3gildur strengur: ver\xF0ur a\xF0 fylgja mynstri ${i.pattern}`:`Rangt ${o[i.format]??r.format}`}case"not_multiple_of":return`R\xF6ng tala: ver\xF0ur a\xF0 vera margfeldi af ${r.divisor}`;case"unrecognized_keys":return`\xD3\xFEekkt ${r.keys.length>1?"ir lyklar":"ur lykill"}: ${w(r.keys,", ")}`;case"invalid_key":return`Rangur lykill \xED ${r.origin}`;case"invalid_union":return"Rangt gildi";case"invalid_element":return`Rangt gildi \xED ${r.origin}`;default:return"Rangt gildi"}}},"error");function pd(){return{localeError:VO()}}s(pd,"default");var GO=s(()=>{let e={string:{unit:"caratteri",verb:"avere"},file:{unit:"byte",verb:"avere"},array:{unit:"elementi",verb:"avere"},set:{unit:"elementi",verb:"avere"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"indirizzo email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e ora ISO",date:"data ISO",time:"ora ISO",duration:"durata ISO",ipv4:"indirizzo IPv4",ipv6:"indirizzo IPv6",cidrv4:"intervallo IPv4",cidrv6:"intervallo IPv6",base64:"stringa codificata in base64",base64url:"URL codificata in base64",json_string:"stringa JSON",e164:"numero E.164",jwt:"JWT",template_literal:"input"},n={nan:"NaN",number:"numero",array:"vettore"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Input non valido: atteso instanceof ${r.expected}, ricevuto ${c}`:`Input non valido: atteso ${i}, ricevuto ${c}`}case"invalid_value":return r.values.length===1?`Input non valido: atteso ${N(r.values[0])}`:`Opzione non valida: atteso uno tra ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Troppo grande: ${r.origin??"valore"} deve avere ${i}${r.maximum.toString()} ${a.unit??"elementi"}`:`Troppo grande: ${r.origin??"valore"} deve essere ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Troppo piccolo: ${r.origin} deve avere ${i}${r.minimum.toString()} ${a.unit}`:`Troppo piccolo: ${r.origin} deve essere ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Stringa non valida: deve iniziare con "${i.prefix}"`:i.format==="ends_with"?`Stringa non valida: deve terminare con "${i.suffix}"`:i.format==="includes"?`Stringa non valida: deve includere "${i.includes}"`:i.format==="regex"?`Stringa non valida: deve corrispondere al pattern ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`Numero non valido: deve essere un multiplo di ${r.divisor}`;case"unrecognized_keys":return`Chiav${r.keys.length>1?"i":"e"} non riconosciut${r.keys.length>1?"e":"a"}: ${w(r.keys,", ")}`;case"invalid_key":return`Chiave non valida in ${r.origin}`;case"invalid_union":return"Input non valido";case"invalid_element":return`Valore non valido in ${r.origin}`;default:return"Input non valido"}}},"error");function ld(){return{localeError:GO()}}s(ld,"default");var HO=s(()=>{let e={string:{unit:"\u6587\u5B57",verb:"\u3067\u3042\u308B"},file:{unit:"\u30D0\u30A4\u30C8",verb:"\u3067\u3042\u308B"},array:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"},set:{unit:"\u8981\u7D20",verb:"\u3067\u3042\u308B"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u5165\u529B\u5024",email:"\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9",url:"URL",emoji:"\u7D75\u6587\u5B57",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u6642",date:"ISO\u65E5\u4ED8",time:"ISO\u6642\u523B",duration:"ISO\u671F\u9593",ipv4:"IPv4\u30A2\u30C9\u30EC\u30B9",ipv6:"IPv6\u30A2\u30C9\u30EC\u30B9",cidrv4:"IPv4\u7BC4\u56F2",cidrv6:"IPv6\u7BC4\u56F2",base64:"base64\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",base64url:"base64url\u30A8\u30F3\u30B3\u30FC\u30C9\u6587\u5B57\u5217",json_string:"JSON\u6587\u5B57\u5217",e164:"E.164\u756A\u53F7",jwt:"JWT",template_literal:"\u5165\u529B\u5024"},n={nan:"NaN",number:"\u6570\u5024",array:"\u914D\u5217"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u7121\u52B9\u306A\u5165\u529B: instanceof ${r.expected}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${c}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u5165\u529B: ${i}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F\u304C\u3001${c}\u304C\u5165\u529B\u3055\u308C\u307E\u3057\u305F`}case"invalid_value":return r.values.length===1?`\u7121\u52B9\u306A\u5165\u529B: ${N(r.values[0])}\u304C\u671F\u5F85\u3055\u308C\u307E\u3057\u305F`:`\u7121\u52B9\u306A\u9078\u629E: ${w(r.values,"\u3001")}\u306E\u3044\u305A\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"too_big":{let i=r.inclusive?"\u4EE5\u4E0B\u3067\u3042\u308B":"\u3088\u308A\u5C0F\u3055\u3044",a=t(r.origin);return a?`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${a.unit??"\u8981\u7D20"}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5927\u304D\u3059\u304E\u308B\u5024: ${r.origin??"\u5024"}\u306F${r.maximum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"too_small":{let i=r.inclusive?"\u4EE5\u4E0A\u3067\u3042\u308B":"\u3088\u308A\u5927\u304D\u3044",a=t(r.origin);return a?`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${a.unit}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u5C0F\u3055\u3059\u304E\u308B\u5024: ${r.origin}\u306F${r.minimum.toString()}${i}\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.prefix}"\u3067\u59CB\u307E\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="ends_with"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.suffix}"\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="includes"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: "${i.includes}"\u3092\u542B\u3080\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:i.format==="regex"?`\u7121\u52B9\u306A\u6587\u5B57\u5217: \u30D1\u30BF\u30FC\u30F3${i.pattern}\u306B\u4E00\u81F4\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`:`\u7121\u52B9\u306A${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u52B9\u306A\u6570\u5024: ${r.divisor}\u306E\u500D\u6570\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059`;case"unrecognized_keys":return`\u8A8D\u8B58\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC${r.keys.length>1?"\u7FA4":""}: ${w(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u30AD\u30FC`;case"invalid_union":return"\u7121\u52B9\u306A\u5165\u529B";case"invalid_element":return`${r.origin}\u5185\u306E\u7121\u52B9\u306A\u5024`;default:return"\u7121\u52B9\u306A\u5165\u529B"}}},"error");function dd(){return{localeError:HO()}}s(dd,"default");var WO=s(()=>{let e={string:{unit:"\u10E1\u10D8\u10DB\u10D1\u10DD\u10DA\u10DD",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},file:{unit:"\u10D1\u10D0\u10D8\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},array:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"},set:{unit:"\u10D4\u10DA\u10D4\u10DB\u10D4\u10DC\u10E2\u10D8",verb:"\u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0",email:"\u10D4\u10DA-\u10E4\u10DD\u10E1\u10E2\u10D8\u10E1 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",url:"URL",emoji:"\u10D4\u10DB\u10DD\u10EF\u10D8",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8-\u10D3\u10E0\u10DD",date:"\u10D7\u10D0\u10E0\u10D8\u10E6\u10D8",time:"\u10D3\u10E0\u10DD",duration:"\u10EE\u10D0\u10DC\u10D2\u10E0\u10EB\u10DA\u10D8\u10D5\u10DD\u10D1\u10D0",ipv4:"IPv4 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",ipv6:"IPv6 \u10DB\u10D8\u10E1\u10D0\u10DB\u10D0\u10E0\u10D7\u10D8",cidrv4:"IPv4 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",cidrv6:"IPv6 \u10D3\u10D8\u10D0\u10DE\u10D0\u10D6\u10DD\u10DC\u10D8",base64:"base64-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",base64url:"base64url-\u10D9\u10DD\u10D3\u10D8\u10E0\u10D4\u10D1\u10E3\u10DA\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",json_string:"JSON \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",e164:"E.164 \u10DC\u10DD\u10DB\u10D4\u10E0\u10D8",jwt:"JWT",template_literal:"\u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"},n={nan:"NaN",number:"\u10E0\u10D8\u10EA\u10EE\u10D5\u10D8",string:"\u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8",boolean:"\u10D1\u10E3\u10DA\u10D4\u10D0\u10DC\u10D8",function:"\u10E4\u10E3\u10DC\u10E5\u10EA\u10D8\u10D0",array:"\u10DB\u10D0\u10E1\u10D8\u10D5\u10D8"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 instanceof ${r.expected}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${c}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${i}, \u10DB\u10D8\u10E6\u10D4\u10D1\u10E3\u10DA\u10D8 ${c}`}case"invalid_value":return r.values.length===1?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${N(r.values[0])}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D5\u10D0\u10E0\u10D8\u10D0\u10DC\u10E2\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8\u10D0 \u10D4\u10E0\u10D7-\u10D4\u10E0\u10D7\u10D8 ${w(r.values,"|")}-\u10D3\u10D0\u10DC`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${r.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10D3\u10D8\u10D3\u10D8: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${r.origin??"\u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0"} \u10D8\u10E7\u10DD\u10E1 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`\u10D6\u10D4\u10D3\u10DB\u10D4\u10E2\u10D0\u10D3 \u10DE\u10D0\u10E2\u10D0\u10E0\u10D0: \u10DB\u10DD\u10E1\u10D0\u10DA\u10DD\u10D3\u10DC\u10D4\u10DA\u10D8 ${r.origin} \u10D8\u10E7\u10DD\u10E1 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10EC\u10E7\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${i.prefix}"-\u10D8\u10D7`:i.format==="ends_with"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10DB\u10D7\u10D0\u10D5\u10E0\u10D3\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 "${i.suffix}"-\u10D8\u10D7`:i.format==="includes"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D8\u10EA\u10D0\u10D5\u10D3\u10D4\u10E1 "${i.includes}"-\u10E1`:i.format==="regex"?`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E1\u10E2\u10E0\u10D8\u10DC\u10D2\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10E8\u10D4\u10D4\u10E1\u10D0\u10D1\u10D0\u10DB\u10D4\u10D1\u10DD\u10D3\u10D4\u10E1 \u10E8\u10D0\u10D1\u10DA\u10DD\u10DC\u10E1 ${i.pattern}`:`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E0\u10D8\u10EA\u10EE\u10D5\u10D8: \u10E3\u10DC\u10D3\u10D0 \u10D8\u10E7\u10DD\u10E1 ${r.divisor}-\u10D8\u10E1 \u10EF\u10D4\u10E0\u10D0\u10D3\u10D8`;case"unrecognized_keys":return`\u10E3\u10EA\u10DC\u10DD\u10D1\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1${r.keys.length>1?"\u10D4\u10D1\u10D8":"\u10D8"}: ${w(r.keys,", ")}`;case"invalid_key":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10D2\u10D0\u10E1\u10D0\u10E6\u10D4\u10D1\u10D8 ${r.origin}-\u10E8\u10D8`;case"invalid_union":return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0";case"invalid_element":return`\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10DB\u10DC\u10D8\u10E8\u10D5\u10DC\u10D4\u10DA\u10DD\u10D1\u10D0 ${r.origin}-\u10E8\u10D8`;default:return"\u10D0\u10E0\u10D0\u10E1\u10EC\u10DD\u10E0\u10D8 \u10E8\u10D4\u10E7\u10D5\u10D0\u10DC\u10D0"}}},"error");function md(){return{localeError:WO()}}s(md,"default");var KO=s(()=>{let e={string:{unit:"\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},file:{unit:"\u1794\u17C3",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},array:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"},set:{unit:"\u1792\u17B6\u178F\u17BB",verb:"\u1782\u17BD\u179A\u1798\u17B6\u1793"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B",email:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793\u17A2\u17CA\u17B8\u1798\u17C2\u179B",url:"URL",emoji:"\u179F\u1789\u17D2\u1789\u17B6\u17A2\u17B6\u179A\u1798\u17D2\u1798\u178E\u17CD",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 \u1793\u17B7\u1784\u1798\u17C9\u17C4\u1784 ISO",date:"\u1780\u17B6\u179B\u1794\u179A\u17B7\u1785\u17D2\u1786\u17C1\u1791 ISO",time:"\u1798\u17C9\u17C4\u1784 ISO",duration:"\u179A\u1799\u17C8\u1796\u17C1\u179B ISO",ipv4:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",ipv6:"\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",cidrv4:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv4",cidrv6:"\u178A\u17C2\u1793\u17A2\u17B6\u179F\u1799\u178A\u17D2\u178B\u17B6\u1793 IPv6",base64:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64",base64url:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u17A2\u17CA\u17B7\u1780\u17BC\u178A base64url",json_string:"\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A JSON",e164:"\u179B\u17C1\u1781 E.164",jwt:"JWT",template_literal:"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B"},n={nan:"NaN",number:"\u179B\u17C1\u1781",array:"\u17A2\u17B6\u179A\u17C1 (Array)",null:"\u1782\u17D2\u1798\u17B6\u1793\u178F\u1798\u17D2\u179B\u17C3 (null)"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A instanceof ${r.expected} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${c}`:`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${i} \u1794\u17C9\u17BB\u1793\u17D2\u178F\u17C2\u1791\u1791\u17BD\u179B\u1794\u17B6\u1793 ${c}`}case"invalid_value":return r.values.length===1?`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${N(r.values[0])}`:`\u1787\u1798\u17D2\u179A\u17BE\u179F\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1787\u17B6\u1798\u17BD\u1799\u1780\u17D2\u1793\u17BB\u1784\u1785\u17C6\u178E\u17C4\u1798 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()} ${a.unit??"\u1792\u17B6\u178F\u17BB"}`:`\u1792\u17C6\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin??"\u178F\u1798\u17D2\u179B\u17C3"} ${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()} ${a.unit}`:`\u178F\u17BC\u1785\u1796\u17C1\u1780\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1780\u17B6\u179A ${r.origin} ${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798\u178A\u17C4\u1799 "${i.prefix}"`:i.format==="ends_with"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1794\u1789\u17D2\u1785\u1794\u17CB\u178A\u17C4\u1799 "${i.suffix}"`:i.format==="includes"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u1798\u17B6\u1793 "${i.includes}"`:i.format==="regex"?`\u1781\u17D2\u179F\u17C2\u17A2\u1780\u17D2\u179F\u179A\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1795\u17D2\u1782\u17BC\u1795\u17D2\u1782\u1784\u1793\u17B9\u1784\u1791\u1798\u17D2\u179A\u1784\u17CB\u178A\u17C2\u179B\u1794\u17B6\u1793\u1780\u17C6\u178E\u178F\u17CB ${i.pattern}`:`\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u179B\u17C1\u1781\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u17D6 \u178F\u17D2\u179A\u17BC\u179C\u178F\u17C2\u1787\u17B6\u1796\u17A0\u17BB\u1782\u17BB\u178E\u1793\u17C3 ${r.divisor}`;case"unrecognized_keys":return`\u179A\u1780\u1783\u17BE\u1789\u179F\u17C4\u1798\u17B7\u1793\u179F\u17D2\u1782\u17B6\u179B\u17CB\u17D6 ${w(r.keys,", ")}`;case"invalid_key":return`\u179F\u17C4\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;case"invalid_union":return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C";case"invalid_element":return`\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C\u1793\u17C5\u1780\u17D2\u1793\u17BB\u1784 ${r.origin}`;default:return"\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u1798\u17B7\u1793\u178F\u17D2\u179A\u17B9\u1798\u178F\u17D2\u179A\u17BC\u179C"}}},"error");function Ln(){return{localeError:KO()}}s(Ln,"default");function fd(){return Ln()}s(fd,"default");var JO=s(()=>{let e={string:{unit:"\uBB38\uC790",verb:"to have"},file:{unit:"\uBC14\uC774\uD2B8",verb:"to have"},array:{unit:"\uAC1C",verb:"to have"},set:{unit:"\uAC1C",verb:"to have"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\uC785\uB825",email:"\uC774\uBA54\uC77C \uC8FC\uC18C",url:"URL",emoji:"\uC774\uBAA8\uC9C0",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \uB0A0\uC9DC\uC2DC\uAC04",date:"ISO \uB0A0\uC9DC",time:"ISO \uC2DC\uAC04",duration:"ISO \uAE30\uAC04",ipv4:"IPv4 \uC8FC\uC18C",ipv6:"IPv6 \uC8FC\uC18C",cidrv4:"IPv4 \uBC94\uC704",cidrv6:"IPv6 \uBC94\uC704",base64:"base64 \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",base64url:"base64url \uC778\uCF54\uB529 \uBB38\uC790\uC5F4",json_string:"JSON \uBB38\uC790\uC5F4",e164:"E.164 \uBC88\uD638",jwt:"JWT",template_literal:"\uC785\uB825"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 instanceof ${r.expected}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${c}\uC785\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC785\uB825: \uC608\uC0C1 \uD0C0\uC785\uC740 ${i}, \uBC1B\uC740 \uD0C0\uC785\uC740 ${c}\uC785\uB2C8\uB2E4`}case"invalid_value":return r.values.length===1?`\uC798\uBABB\uB41C \uC785\uB825: \uAC12\uC740 ${N(r.values[0])} \uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C \uC635\uC158: ${w(r.values,"\uB610\uB294 ")} \uC911 \uD558\uB098\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"too_big":{let i=r.inclusive?"\uC774\uD558":"\uBBF8\uB9CC",a=i==="\uBBF8\uB9CC"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",c=t(r.origin),p=c?.unit??"\uC694\uC18C";return c?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()}${p} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uD07D\uB2C8\uB2E4: ${r.maximum.toString()} ${i}${a}`}case"too_small":{let i=r.inclusive?"\uC774\uC0C1":"\uCD08\uACFC",a=i==="\uC774\uC0C1"?"\uC774\uC5B4\uC57C \uD569\uB2C8\uB2E4":"\uC5EC\uC57C \uD569\uB2C8\uB2E4",c=t(r.origin),p=c?.unit??"\uC694\uC18C";return c?`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()}${p} ${i}${a}`:`${r.origin??"\uAC12"}\uC774 \uB108\uBB34 \uC791\uC2B5\uB2C8\uB2E4: ${r.minimum.toString()} ${i}${a}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.prefix}"(\uC73C)\uB85C \uC2DC\uC791\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="ends_with"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.suffix}"(\uC73C)\uB85C \uB05D\uB098\uC57C \uD569\uB2C8\uB2E4`:i.format==="includes"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: "${i.includes}"\uC744(\uB97C) \uD3EC\uD568\uD574\uC57C \uD569\uB2C8\uB2E4`:i.format==="regex"?`\uC798\uBABB\uB41C \uBB38\uC790\uC5F4: \uC815\uADDC\uC2DD ${i.pattern} \uD328\uD134\uACFC \uC77C\uCE58\uD574\uC57C \uD569\uB2C8\uB2E4`:`\uC798\uBABB\uB41C ${o[i.format]??r.format}`}case"not_multiple_of":return`\uC798\uBABB\uB41C \uC22B\uC790: ${r.divisor}\uC758 \uBC30\uC218\uC5EC\uC57C \uD569\uB2C8\uB2E4`;case"unrecognized_keys":return`\uC778\uC2DD\uD560 \uC218 \uC5C6\uB294 \uD0A4: ${w(r.keys,", ")}`;case"invalid_key":return`\uC798\uBABB\uB41C \uD0A4: ${r.origin}`;case"invalid_union":return"\uC798\uBABB\uB41C \uC785\uB825";case"invalid_element":return`\uC798\uBABB\uB41C \uAC12: ${r.origin}`;default:return"\uC798\uBABB\uB41C \uC785\uB825"}}},"error");function hd(){return{localeError:JO()}}s(hd,"default");var Un=s(e=>e.charAt(0).toUpperCase()+e.slice(1),"capitalizeFirstCharacter");function Eg(e){let t=Math.abs(e),o=t%10,n=t%100;return n>=11&&n<=19||o===0?"many":o===1?"one":"few"}s(Eg,"getUnitTypeFromNumber");var XO=s(()=>{let e={string:{unit:{one:"simbolis",few:"simboliai",many:"simboli\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne ilgesn\u0117 kaip",notInclusive:"turi b\u016Bti trumpesn\u0117 kaip"},bigger:{inclusive:"turi b\u016Bti ne trumpesn\u0117 kaip",notInclusive:"turi b\u016Bti ilgesn\u0117 kaip"}}},file:{unit:{one:"baitas",few:"baitai",many:"bait\u0173"},verb:{smaller:{inclusive:"turi b\u016Bti ne didesnis kaip",notInclusive:"turi b\u016Bti ma\u017Eesnis kaip"},bigger:{inclusive:"turi b\u016Bti ne ma\u017Eesnis kaip",notInclusive:"turi b\u016Bti didesnis kaip"}}},array:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}},set:{unit:{one:"element\u0105",few:"elementus",many:"element\u0173"},verb:{smaller:{inclusive:"turi tur\u0117ti ne daugiau kaip",notInclusive:"turi tur\u0117ti ma\u017Eiau kaip"},bigger:{inclusive:"turi tur\u0117ti ne ma\u017Eiau kaip",notInclusive:"turi tur\u0117ti daugiau kaip"}}}};function t(r,i,a,c){let p=e[r]??null;return p===null?p:{unit:p.unit[i],verb:p.verb[c][a?"inclusive":"notInclusive"]}}s(t,"getSizing");let o={regex:"\u012Fvestis",email:"el. pa\u0161to adresas",url:"URL",emoji:"jaustukas",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO data ir laikas",date:"ISO data",time:"ISO laikas",duration:"ISO trukm\u0117",ipv4:"IPv4 adresas",ipv6:"IPv6 adresas",cidrv4:"IPv4 tinklo prefiksas (CIDR)",cidrv6:"IPv6 tinklo prefiksas (CIDR)",base64:"base64 u\u017Ekoduota eilut\u0117",base64url:"base64url u\u017Ekoduota eilut\u0117",json_string:"JSON eilut\u0117",e164:"E.164 numeris",jwt:"JWT",template_literal:"\u012Fvestis"},n={nan:"NaN",number:"skai\u010Dius",bigint:"sveikasis skai\u010Dius",string:"eilut\u0117",boolean:"login\u0117 reik\u0161m\u0117",undefined:"neapibr\u0117\u017Eta reik\u0161m\u0117",function:"funkcija",symbol:"simbolis",array:"masyvas",object:"objektas",null:"nulin\u0117 reik\u0161m\u0117"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Gautas tipas ${c}, o tik\u0117tasi - instanceof ${r.expected}`:`Gautas tipas ${c}, o tik\u0117tasi - ${i}`}case"invalid_value":return r.values.length===1?`Privalo b\u016Bti ${N(r.values[0])}`:`Privalo b\u016Bti vienas i\u0161 ${w(r.values,"|")} pasirinkim\u0173`;case"too_big":{let i=n[r.origin]??r.origin,a=t(r.origin,Eg(Number(r.maximum)),r.inclusive??!1,"smaller");if(a?.verb)return`${Un(i??r.origin??"reik\u0161m\u0117")} ${a.verb} ${r.maximum.toString()} ${a.unit??"element\u0173"}`;let c=r.inclusive?"ne didesnis kaip":"ma\u017Eesnis kaip";return`${Un(i??r.origin??"reik\u0161m\u0117")} turi b\u016Bti ${c} ${r.maximum.toString()} ${a?.unit}`}case"too_small":{let i=n[r.origin]??r.origin,a=t(r.origin,Eg(Number(r.minimum)),r.inclusive??!1,"bigger");if(a?.verb)return`${Un(i??r.origin??"reik\u0161m\u0117")} ${a.verb} ${r.minimum.toString()} ${a.unit??"element\u0173"}`;let c=r.inclusive?"ne ma\u017Eesnis kaip":"didesnis kaip";return`${Un(i??r.origin??"reik\u0161m\u0117")} turi b\u016Bti ${c} ${r.minimum.toString()} ${a?.unit}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Eilut\u0117 privalo prasid\u0117ti "${i.prefix}"`:i.format==="ends_with"?`Eilut\u0117 privalo pasibaigti "${i.suffix}"`:i.format==="includes"?`Eilut\u0117 privalo \u012Ftraukti "${i.includes}"`:i.format==="regex"?`Eilut\u0117 privalo atitikti ${i.pattern}`:`Neteisingas ${o[i.format]??r.format}`}case"not_multiple_of":return`Skai\u010Dius privalo b\u016Bti ${r.divisor} kartotinis.`;case"unrecognized_keys":return`Neatpa\u017Eint${r.keys.length>1?"i":"as"} rakt${r.keys.length>1?"ai":"as"}: ${w(r.keys,", ")}`;case"invalid_key":return"Rastas klaidingas raktas";case"invalid_union":return"Klaidinga \u012Fvestis";case"invalid_element":{let i=n[r.origin]??r.origin;return`${Un(i??r.origin??"reik\u0161m\u0117")} turi klaiding\u0105 \u012Fvest\u012F`}default:return"Klaidinga \u012Fvestis"}}},"error");function yd(){return{localeError:XO()}}s(yd,"default");var YO=s(()=>{let e={string:{unit:"\u0437\u043D\u0430\u0446\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},file:{unit:"\u0431\u0430\u0458\u0442\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},array:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"},set:{unit:"\u0441\u0442\u0430\u0432\u043A\u0438",verb:"\u0434\u0430 \u0438\u043C\u0430\u0430\u0442"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0432\u043D\u0435\u0441",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u043D\u0430 \u0435-\u043F\u043E\u0448\u0442\u0430",url:"URL",emoji:"\u0435\u043C\u043E\u045F\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0443\u043C \u0438 \u0432\u0440\u0435\u043C\u0435",date:"ISO \u0434\u0430\u0442\u0443\u043C",time:"ISO \u0432\u0440\u0435\u043C\u0435",duration:"ISO \u0432\u0440\u0435\u043C\u0435\u0442\u0440\u0430\u0435\u045A\u0435",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441\u0430",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441\u0430",cidrv4:"IPv4 \u043E\u043F\u0441\u0435\u0433",cidrv6:"IPv6 \u043E\u043F\u0441\u0435\u0433",base64:"base64-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",base64url:"base64url-\u0435\u043D\u043A\u043E\u0434\u0438\u0440\u0430\u043D\u0430 \u043D\u0438\u0437\u0430",json_string:"JSON \u043D\u0438\u0437\u0430",e164:"E.164 \u0431\u0440\u043E\u0458",jwt:"JWT",template_literal:"\u0432\u043D\u0435\u0441"},n={nan:"NaN",number:"\u0431\u0440\u043E\u0458",array:"\u043D\u0438\u0437\u0430"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 instanceof ${r.expected}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${c}`:`\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${i}, \u043F\u0440\u0438\u043C\u0435\u043D\u043E ${c}`}case"invalid_value":return r.values.length===1?`Invalid input: expected ${N(r.values[0])}`:`\u0413\u0440\u0435\u0448\u0430\u043D\u0430 \u043E\u043F\u0446\u0438\u0458\u0430: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 \u0435\u0434\u043D\u0430 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0438"}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u0433\u043E\u043B\u0435\u043C: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin??"\u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442\u0430"} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0438\u043C\u0430 ${i}${r.minimum.toString()} ${a.unit}`:`\u041F\u0440\u0435\u043C\u043D\u043E\u0433\u0443 \u043C\u0430\u043B: \u0441\u0435 \u043E\u0447\u0435\u043A\u0443\u0432\u0430 ${r.origin} \u0434\u0430 \u0431\u0438\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u043F\u043E\u0447\u043D\u0443\u0432\u0430 \u0441\u043E "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0437\u0430\u0432\u0440\u0448\u0443\u0432\u0430 \u0441\u043E "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0432\u043A\u043B\u0443\u0447\u0443\u0432\u0430 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0430\u0436\u0435\u0447\u043A\u0430 \u043D\u0438\u0437\u0430: \u043C\u043E\u0440\u0430 \u0434\u0430 \u043E\u0434\u0433\u043E\u0430\u0440\u0430 \u043D\u0430 \u043F\u0430\u0442\u0435\u0440\u043D\u043E\u0442 ${i.pattern}`:`Invalid ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0413\u0440\u0435\u0448\u0435\u043D \u0431\u0440\u043E\u0458: \u043C\u043E\u0440\u0430 \u0434\u0430 \u0431\u0438\u0434\u0435 \u0434\u0435\u043B\u0438\u0432 \u0441\u043E ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D\u0438 \u043A\u043B\u0443\u0447\u0435\u0432\u0438":"\u041D\u0435\u043F\u0440\u0435\u043F\u043E\u0437\u043D\u0430\u0435\u043D \u043A\u043B\u0443\u0447"}: ${w(r.keys,", ")}`;case"invalid_key":return`\u0413\u0440\u0435\u0448\u0435\u043D \u043A\u043B\u0443\u0447 \u0432\u043E ${r.origin}`;case"invalid_union":return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441";case"invalid_element":return`\u0413\u0440\u0435\u0448\u043D\u0430 \u0432\u0440\u0435\u0434\u043D\u043E\u0441\u0442 \u0432\u043E ${r.origin}`;default:return"\u0413\u0440\u0435\u0448\u0435\u043D \u0432\u043D\u0435\u0441"}}},"error");function gd(){return{localeError:YO()}}s(gd,"default");var QO=s(()=>{let e={string:{unit:"aksara",verb:"mempunyai"},file:{unit:"bait",verb:"mempunyai"},array:{unit:"elemen",verb:"mempunyai"},set:{unit:"elemen",verb:"mempunyai"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"alamat e-mel",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"tarikh masa ISO",date:"tarikh ISO",time:"masa ISO",duration:"tempoh ISO",ipv4:"alamat IPv4",ipv6:"alamat IPv6",cidrv4:"julat IPv4",cidrv6:"julat IPv6",base64:"string dikodkan base64",base64url:"string dikodkan base64url",json_string:"string JSON",e164:"nombor E.164",jwt:"JWT",template_literal:"input"},n={nan:"NaN",number:"nombor"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Input tidak sah: dijangka instanceof ${r.expected}, diterima ${c}`:`Input tidak sah: dijangka ${i}, diterima ${c}`}case"invalid_value":return r.values.length===1?`Input tidak sah: dijangka ${N(r.values[0])}`:`Pilihan tidak sah: dijangka salah satu daripada ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Terlalu besar: dijangka ${r.origin??"nilai"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"elemen"}`:`Terlalu besar: dijangka ${r.origin??"nilai"} adalah ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Terlalu kecil: dijangka ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Terlalu kecil: dijangka ${r.origin} adalah ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`String tidak sah: mesti bermula dengan "${i.prefix}"`:i.format==="ends_with"?`String tidak sah: mesti berakhir dengan "${i.suffix}"`:i.format==="includes"?`String tidak sah: mesti mengandungi "${i.includes}"`:i.format==="regex"?`String tidak sah: mesti sepadan dengan corak ${i.pattern}`:`${o[i.format]??r.format} tidak sah`}case"not_multiple_of":return`Nombor tidak sah: perlu gandaan ${r.divisor}`;case"unrecognized_keys":return`Kunci tidak dikenali: ${w(r.keys,", ")}`;case"invalid_key":return`Kunci tidak sah dalam ${r.origin}`;case"invalid_union":return"Input tidak sah";case"invalid_element":return`Nilai tidak sah dalam ${r.origin}`;default:return"Input tidak sah"}}},"error");function vd(){return{localeError:QO()}}s(vd,"default");var eR=s(()=>{let e={string:{unit:"tekens",verb:"heeft"},file:{unit:"bytes",verb:"heeft"},array:{unit:"elementen",verb:"heeft"},set:{unit:"elementen",verb:"heeft"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"invoer",email:"emailadres",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum en tijd",date:"ISO datum",time:"ISO tijd",duration:"ISO duur",ipv4:"IPv4-adres",ipv6:"IPv6-adres",cidrv4:"IPv4-bereik",cidrv6:"IPv6-bereik",base64:"base64-gecodeerde tekst",base64url:"base64 URL-gecodeerde tekst",json_string:"JSON string",e164:"E.164-nummer",jwt:"JWT",template_literal:"invoer"},n={nan:"NaN",number:"getal"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ongeldige invoer: verwacht instanceof ${r.expected}, ontving ${c}`:`Ongeldige invoer: verwacht ${i}, ontving ${c}`}case"invalid_value":return r.values.length===1?`Ongeldige invoer: verwacht ${N(r.values[0])}`:`Ongeldige optie: verwacht \xE9\xE9n van ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin),c=r.origin==="date"?"laat":r.origin==="string"?"lang":"groot";return a?`Te ${c}: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} ${a.unit??"elementen"} ${a.verb}`:`Te ${c}: verwacht dat ${r.origin??"waarde"} ${i}${r.maximum.toString()} is`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin),c=r.origin==="date"?"vroeg":r.origin==="string"?"kort":"klein";return a?`Te ${c}: verwacht dat ${r.origin} ${i}${r.minimum.toString()} ${a.unit} ${a.verb}`:`Te ${c}: verwacht dat ${r.origin} ${i}${r.minimum.toString()} is`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ongeldige tekst: moet met "${i.prefix}" beginnen`:i.format==="ends_with"?`Ongeldige tekst: moet op "${i.suffix}" eindigen`:i.format==="includes"?`Ongeldige tekst: moet "${i.includes}" bevatten`:i.format==="regex"?`Ongeldige tekst: moet overeenkomen met patroon ${i.pattern}`:`Ongeldig: ${o[i.format]??r.format}`}case"not_multiple_of":return`Ongeldig getal: moet een veelvoud van ${r.divisor} zijn`;case"unrecognized_keys":return`Onbekende key${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Ongeldige key in ${r.origin}`;case"invalid_union":return"Ongeldige invoer";case"invalid_element":return`Ongeldige waarde in ${r.origin}`;default:return"Ongeldige invoer"}}},"error");function _d(){return{localeError:eR()}}s(_d,"default");var tR=s(()=>{let e={string:{unit:"tegn",verb:"\xE5 ha"},file:{unit:"bytes",verb:"\xE5 ha"},array:{unit:"elementer",verb:"\xE5 inneholde"},set:{unit:"elementer",verb:"\xE5 inneholde"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"input",email:"e-postadresse",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO dato- og klokkeslett",date:"ISO-dato",time:"ISO-klokkeslett",duration:"ISO-varighet",ipv4:"IPv4-omr\xE5de",ipv6:"IPv6-omr\xE5de",cidrv4:"IPv4-spekter",cidrv6:"IPv6-spekter",base64:"base64-enkodet streng",base64url:"base64url-enkodet streng",json_string:"JSON-streng",e164:"E.164-nummer",jwt:"JWT",template_literal:"input"},n={nan:"NaN",number:"tall",array:"liste"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ugyldig input: forventet instanceof ${r.expected}, fikk ${c}`:`Ugyldig input: forventet ${i}, fikk ${c}`}case"invalid_value":return r.values.length===1?`Ugyldig verdi: forventet ${N(r.values[0])}`:`Ugyldig valg: forventet en av ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()} ${a.unit??"elementer"}`:`For stor(t): forventet ${r.origin??"value"} til \xE5 ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()} ${a.unit}`:`For lite(n): forventet ${r.origin} til \xE5 ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ugyldig streng: m\xE5 starte med "${i.prefix}"`:i.format==="ends_with"?`Ugyldig streng: m\xE5 ende med "${i.suffix}"`:i.format==="includes"?`Ugyldig streng: m\xE5 inneholde "${i.includes}"`:i.format==="regex"?`Ugyldig streng: m\xE5 matche m\xF8nsteret ${i.pattern}`:`Ugyldig ${o[i.format]??r.format}`}case"not_multiple_of":return`Ugyldig tall: m\xE5 v\xE6re et multiplum av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ukjente n\xF8kler":"Ukjent n\xF8kkel"}: ${w(r.keys,", ")}`;case"invalid_key":return`Ugyldig n\xF8kkel i ${r.origin}`;case"invalid_union":return"Ugyldig input";case"invalid_element":return`Ugyldig verdi i ${r.origin}`;default:return"Ugyldig input"}}},"error");function bd(){return{localeError:tR()}}s(bd,"default");var rR=s(()=>{let e={string:{unit:"harf",verb:"olmal\u0131d\u0131r"},file:{unit:"bayt",verb:"olmal\u0131d\u0131r"},array:{unit:"unsur",verb:"olmal\u0131d\u0131r"},set:{unit:"unsur",verb:"olmal\u0131d\u0131r"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"giren",email:"epostag\xE2h",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO heng\xE2m\u0131",date:"ISO tarihi",time:"ISO zaman\u0131",duration:"ISO m\xFCddeti",ipv4:"IPv4 ni\u015F\xE2n\u0131",ipv6:"IPv6 ni\u015F\xE2n\u0131",cidrv4:"IPv4 menzili",cidrv6:"IPv6 menzili",base64:"base64-\u015Fifreli metin",base64url:"base64url-\u015Fifreli metin",json_string:"JSON metin",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"giren"},n={nan:"NaN",number:"numara",array:"saf",null:"gayb"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`F\xE2sit giren: umulan instanceof ${r.expected}, al\u0131nan ${c}`:`F\xE2sit giren: umulan ${i}, al\u0131nan ${c}`}case"invalid_value":return r.values.length===1?`F\xE2sit giren: umulan ${N(r.values[0])}`:`F\xE2sit tercih: m\xFBteberler ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} ${a.unit??"elements"} sahip olmal\u0131yd\u0131.`:`Fazla b\xFCy\xFCk: ${r.origin??"value"}, ${i}${r.maximum.toString()} olmal\u0131yd\u0131.`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} ${a.unit} sahip olmal\u0131yd\u0131.`:`Fazla k\xFC\xE7\xFCk: ${r.origin}, ${i}${r.minimum.toString()} olmal\u0131yd\u0131.`}case"invalid_format":{let i=r;return i.format==="starts_with"?`F\xE2sit metin: "${i.prefix}" ile ba\u015Flamal\u0131.`:i.format==="ends_with"?`F\xE2sit metin: "${i.suffix}" ile bitmeli.`:i.format==="includes"?`F\xE2sit metin: "${i.includes}" ihtiv\xE2 etmeli.`:i.format==="regex"?`F\xE2sit metin: ${i.pattern} nak\u015F\u0131na uymal\u0131.`:`F\xE2sit ${o[i.format]??r.format}`}case"not_multiple_of":return`F\xE2sit say\u0131: ${r.divisor} kat\u0131 olmal\u0131yd\u0131.`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar ${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} i\xE7in tan\u0131nmayan anahtar var.`;case"invalid_union":return"Giren tan\u0131namad\u0131.";case"invalid_element":return`${r.origin} i\xE7in tan\u0131nmayan k\u0131ymet var.`;default:return"K\u0131ymet tan\u0131namad\u0131."}}},"error");function Pd(){return{localeError:rR()}}s(Pd,"default");var oR=s(()=>{let e={string:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},file:{unit:"\u0628\u0627\u06CC\u067C\u0633",verb:"\u0648\u0644\u0631\u064A"},array:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"},set:{unit:"\u062A\u0648\u06A9\u064A",verb:"\u0648\u0644\u0631\u064A"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0648\u0631\u0648\u062F\u064A",email:"\u0628\u0631\u06CC\u069A\u0646\u0627\u0644\u06CC\u06A9",url:"\u06CC\u0648 \u0622\u0631 \u0627\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u064A",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0646\u06CC\u067C\u0647 \u0627\u0648 \u0648\u062E\u062A",date:"\u0646\u06D0\u067C\u0647",time:"\u0648\u062E\u062A",duration:"\u0645\u0648\u062F\u0647",ipv4:"\u062F IPv4 \u067E\u062A\u0647",ipv6:"\u062F IPv6 \u067E\u062A\u0647",cidrv4:"\u062F IPv4 \u0633\u0627\u062D\u0647",cidrv6:"\u062F IPv6 \u0633\u0627\u062D\u0647",base64:"base64-encoded \u0645\u062A\u0646",base64url:"base64url-encoded \u0645\u062A\u0646",json_string:"JSON \u0645\u062A\u0646",e164:"\u062F E.164 \u0634\u0645\u06D0\u0631\u0647",jwt:"JWT",template_literal:"\u0648\u0631\u0648\u062F\u064A"},n={nan:"NaN",number:"\u0639\u062F\u062F",array:"\u0627\u0631\u06D0"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F instanceof ${r.expected} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${c} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`:`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${i} \u0648\u0627\u06CC, \u0645\u06AB\u0631 ${c} \u062A\u0631\u0644\u0627\u0633\u0647 \u0634\u0648`}case"invalid_value":return r.values.length===1?`\u0646\u0627\u0633\u0645 \u0648\u0631\u0648\u062F\u064A: \u0628\u0627\u06CC\u062F ${N(r.values[0])} \u0648\u0627\u06CC`:`\u0646\u0627\u0633\u0645 \u0627\u0646\u062A\u062E\u0627\u0628: \u0628\u0627\u06CC\u062F \u06CC\u0648 \u0644\u0647 ${w(r.values,"|")} \u0685\u062E\u0647 \u0648\u0627\u06CC`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0635\u0631\u0648\u0646\u0647"} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u0644\u0648\u06CC: ${r.origin??"\u0627\u0631\u0632\u069A\u062A"} \u0628\u0627\u06CC\u062F ${i}${r.maximum.toString()} \u0648\u064A`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} ${a.unit} \u0648\u0644\u0631\u064A`:`\u0689\u06CC\u0631 \u06A9\u0648\u0686\u0646\u06CC: ${r.origin} \u0628\u0627\u06CC\u062F ${i}${r.minimum.toString()} \u0648\u064A`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.prefix}" \u0633\u0631\u0647 \u067E\u06CC\u0644 \u0634\u064A`:i.format==="ends_with"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F "${i.suffix}" \u0633\u0631\u0647 \u067E\u0627\u06CC \u062A\u0647 \u0648\u0631\u0633\u064A\u0696\u064A`:i.format==="includes"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F "${i.includes}" \u0648\u0644\u0631\u064A`:i.format==="regex"?`\u0646\u0627\u0633\u0645 \u0645\u062A\u0646: \u0628\u0627\u06CC\u062F \u062F ${i.pattern} \u0633\u0631\u0647 \u0645\u0637\u0627\u0628\u0642\u062A \u0648\u0644\u0631\u064A`:`${o[i.format]??r.format} \u0646\u0627\u0633\u0645 \u062F\u06CC`}case"not_multiple_of":return`\u0646\u0627\u0633\u0645 \u0639\u062F\u062F: \u0628\u0627\u06CC\u062F \u062F ${r.divisor} \u0645\u0636\u0631\u0628 \u0648\u064A`;case"unrecognized_keys":return`\u0646\u0627\u0633\u0645 ${r.keys.length>1?"\u06A9\u0644\u06CC\u0689\u0648\u0646\u0647":"\u06A9\u0644\u06CC\u0689"}: ${w(r.keys,", ")}`;case"invalid_key":return`\u0646\u0627\u0633\u0645 \u06A9\u0644\u06CC\u0689 \u067E\u0647 ${r.origin} \u06A9\u06D0`;case"invalid_union":return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A";case"invalid_element":return`\u0646\u0627\u0633\u0645 \u0639\u0646\u0635\u0631 \u067E\u0647 ${r.origin} \u06A9\u06D0`;default:return"\u0646\u0627\u0633\u0645\u0647 \u0648\u0631\u0648\u062F\u064A"}}},"error");function xd(){return{localeError:oR()}}s(xd,"default");var nR=s(()=>{let e={string:{unit:"znak\xF3w",verb:"mie\u0107"},file:{unit:"bajt\xF3w",verb:"mie\u0107"},array:{unit:"element\xF3w",verb:"mie\u0107"},set:{unit:"element\xF3w",verb:"mie\u0107"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"wyra\u017Cenie",email:"adres email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data i godzina w formacie ISO",date:"data w formacie ISO",time:"godzina w formacie ISO",duration:"czas trwania ISO",ipv4:"adres IPv4",ipv6:"adres IPv6",cidrv4:"zakres IPv4",cidrv6:"zakres IPv6",base64:"ci\u0105g znak\xF3w zakodowany w formacie base64",base64url:"ci\u0105g znak\xF3w zakodowany w formacie base64url",json_string:"ci\u0105g znak\xF3w w formacie JSON",e164:"liczba E.164",jwt:"JWT",template_literal:"wej\u015Bcie"},n={nan:"NaN",number:"liczba",array:"tablica"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano instanceof ${r.expected}, otrzymano ${c}`:`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${i}, otrzymano ${c}`}case"invalid_value":return r.values.length===1?`Nieprawid\u0142owe dane wej\u015Bciowe: oczekiwano ${N(r.values[0])}`:`Nieprawid\u0142owa opcja: oczekiwano jednej z warto\u015Bci ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Za du\u017Ca warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.maximum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt du\u017C(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Za ma\u0142a warto\u015B\u0107: oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie mie\u0107 ${i}${r.minimum.toString()} ${a.unit??"element\xF3w"}`:`Zbyt ma\u0142(y/a/e): oczekiwano, \u017Ce ${r.origin??"warto\u015B\u0107"} b\u0119dzie wynosi\u0107 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zaczyna\u0107 si\u0119 od "${i.prefix}"`:i.format==="ends_with"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi ko\u0144czy\u0107 si\u0119 na "${i.suffix}"`:i.format==="includes"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi zawiera\u0107 "${i.includes}"`:i.format==="regex"?`Nieprawid\u0142owy ci\u0105g znak\xF3w: musi odpowiada\u0107 wzorcowi ${i.pattern}`:`Nieprawid\u0142ow(y/a/e) ${o[i.format]??r.format}`}case"not_multiple_of":return`Nieprawid\u0142owa liczba: musi by\u0107 wielokrotno\u015Bci\u0105 ${r.divisor}`;case"unrecognized_keys":return`Nierozpoznane klucze${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Nieprawid\u0142owy klucz w ${r.origin}`;case"invalid_union":return"Nieprawid\u0142owe dane wej\u015Bciowe";case"invalid_element":return`Nieprawid\u0142owa warto\u015B\u0107 w ${r.origin}`;default:return"Nieprawid\u0142owe dane wej\u015Bciowe"}}},"error");function Sd(){return{localeError:nR()}}s(Sd,"default");var iR=s(()=>{let e={string:{unit:"caracteres",verb:"ter"},file:{unit:"bytes",verb:"ter"},array:{unit:"itens",verb:"ter"},set:{unit:"itens",verb:"ter"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"padr\xE3o",email:"endere\xE7o de e-mail",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"data e hora ISO",date:"data ISO",time:"hora ISO",duration:"dura\xE7\xE3o ISO",ipv4:"endere\xE7o IPv4",ipv6:"endere\xE7o IPv6",cidrv4:"faixa de IPv4",cidrv6:"faixa de IPv6",base64:"texto codificado em base64",base64url:"URL codificada em base64",json_string:"texto JSON",e164:"n\xFAmero E.164",jwt:"JWT",template_literal:"entrada"},n={nan:"NaN",number:"n\xFAmero",null:"nulo"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Tipo inv\xE1lido: esperado instanceof ${r.expected}, recebido ${c}`:`Tipo inv\xE1lido: esperado ${i}, recebido ${c}`}case"invalid_value":return r.values.length===1?`Entrada inv\xE1lida: esperado ${N(r.values[0])}`:`Op\xE7\xE3o inv\xE1lida: esperada uma das ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Muito grande: esperado que ${r.origin??"valor"} tivesse ${i}${r.maximum.toString()} ${a.unit??"elementos"}`:`Muito grande: esperado que ${r.origin??"valor"} fosse ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Muito pequeno: esperado que ${r.origin} tivesse ${i}${r.minimum.toString()} ${a.unit}`:`Muito pequeno: esperado que ${r.origin} fosse ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Texto inv\xE1lido: deve come\xE7ar com "${i.prefix}"`:i.format==="ends_with"?`Texto inv\xE1lido: deve terminar com "${i.suffix}"`:i.format==="includes"?`Texto inv\xE1lido: deve incluir "${i.includes}"`:i.format==="regex"?`Texto inv\xE1lido: deve corresponder ao padr\xE3o ${i.pattern}`:`${o[i.format]??r.format} inv\xE1lido`}case"not_multiple_of":return`N\xFAmero inv\xE1lido: deve ser m\xFAltiplo de ${r.divisor}`;case"unrecognized_keys":return`Chave${r.keys.length>1?"s":""} desconhecida${r.keys.length>1?"s":""}: ${w(r.keys,", ")}`;case"invalid_key":return`Chave inv\xE1lida em ${r.origin}`;case"invalid_union":return"Entrada inv\xE1lida";case"invalid_element":return`Valor inv\xE1lido em ${r.origin}`;default:return"Campo inv\xE1lido"}}},"error");function Td(){return{localeError:iR()}}s(Td,"default");function Ig(e,t,o,n){let r=Math.abs(e),i=r%10,a=r%100;return a>=11&&a<=19?n:i===1?t:i>=2&&i<=4?o:n}s(Ig,"getRussianPlural");var aR=s(()=>{let e={string:{unit:{one:"\u0441\u0438\u043C\u0432\u043E\u043B",few:"\u0441\u0438\u043C\u0432\u043E\u043B\u0430",many:"\u0441\u0438\u043C\u0432\u043E\u043B\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},file:{unit:{one:"\u0431\u0430\u0439\u0442",few:"\u0431\u0430\u0439\u0442\u0430",many:"\u0431\u0430\u0439\u0442"},verb:"\u0438\u043C\u0435\u0442\u044C"},array:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"},set:{unit:{one:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442",few:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u0430",many:"\u044D\u043B\u0435\u043C\u0435\u043D\u0442\u043E\u0432"},verb:"\u0438\u043C\u0435\u0442\u044C"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0432\u0432\u043E\u0434",email:"email \u0430\u0434\u0440\u0435\u0441",url:"URL",emoji:"\u044D\u043C\u043E\u0434\u0437\u0438",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0434\u0430\u0442\u0430 \u0438 \u0432\u0440\u0435\u043C\u044F",date:"ISO \u0434\u0430\u0442\u0430",time:"ISO \u0432\u0440\u0435\u043C\u044F",duration:"ISO \u0434\u043B\u0438\u0442\u0435\u043B\u044C\u043D\u043E\u0441\u0442\u044C",ipv4:"IPv4 \u0430\u0434\u0440\u0435\u0441",ipv6:"IPv6 \u0430\u0434\u0440\u0435\u0441",cidrv4:"IPv4 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",cidrv6:"IPv6 \u0434\u0438\u0430\u043F\u0430\u0437\u043E\u043D",base64:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64",base64url:"\u0441\u0442\u0440\u043E\u043A\u0430 \u0432 \u0444\u043E\u0440\u043C\u0430\u0442\u0435 base64url",json_string:"JSON \u0441\u0442\u0440\u043E\u043A\u0430",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0432\u043E\u0434"},n={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0441\u0438\u0432"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C instanceof ${r.expected}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${c}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${i}, \u043F\u043E\u043B\u0443\u0447\u0435\u043D\u043E ${c}`}case"invalid_value":return r.values.length===1?`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0432\u043E\u0434: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C ${N(r.values[0])}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u0432\u0430\u0440\u0438\u0430\u043D\u0442: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u043E\u0434\u043D\u043E \u0438\u0437 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);if(a){let c=Number(r.maximum),p=Ig(c,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.maximum.toString()} ${p}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u0431\u043E\u043B\u044C\u0448\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435"} \u0431\u0443\u0434\u0435\u0442 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);if(a){let c=Number(r.minimum),p=Ig(c,a.unit.one,a.unit.few,a.unit.many);return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 \u0438\u043C\u0435\u0442\u044C ${i}${r.minimum.toString()} ${p}`}return`\u0421\u043B\u0438\u0448\u043A\u043E\u043C \u043C\u0430\u043B\u0435\u043D\u044C\u043A\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435: \u043E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C, \u0447\u0442\u043E ${r.origin} \u0431\u0443\u0434\u0435\u0442 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0430\u0447\u0438\u043D\u0430\u0442\u044C\u0441\u044F \u0441 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0437\u0430\u043A\u0430\u043D\u0447\u0438\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u0432\u0435\u0440\u043D\u0430\u044F \u0441\u0442\u0440\u043E\u043A\u0430: \u0434\u043E\u043B\u0436\u043D\u0430 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u043E\u0432\u0430\u0442\u044C \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0447\u0438\u0441\u043B\u043E: \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043A\u0440\u0430\u0442\u043D\u044B\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u0430\u0441\u043F\u043E\u0437\u043D\u0430\u043D\u043D${r.keys.length>1?"\u044B\u0435":"\u044B\u0439"} \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0438":""}: ${w(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u0432 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435";case"invalid_element":return`\u041D\u0435\u0432\u0435\u0440\u043D\u043E\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435 \u0432 ${r.origin}`;default:return"\u041D\u0435\u0432\u0435\u0440\u043D\u044B\u0435 \u0432\u0445\u043E\u0434\u043D\u044B\u0435 \u0434\u0430\u043D\u043D\u044B\u0435"}}},"error");function Ed(){return{localeError:aR()}}s(Ed,"default");var sR=s(()=>{let e={string:{unit:"znakov",verb:"imeti"},file:{unit:"bajtov",verb:"imeti"},array:{unit:"elementov",verb:"imeti"},set:{unit:"elementov",verb:"imeti"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"vnos",email:"e-po\u0161tni naslov",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO datum in \u010Das",date:"ISO datum",time:"ISO \u010Das",duration:"ISO trajanje",ipv4:"IPv4 naslov",ipv6:"IPv6 naslov",cidrv4:"obseg IPv4",cidrv6:"obseg IPv6",base64:"base64 kodiran niz",base64url:"base64url kodiran niz",json_string:"JSON niz",e164:"E.164 \u0161tevilka",jwt:"JWT",template_literal:"vnos"},n={nan:"NaN",number:"\u0161tevilo",array:"tabela"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Neveljaven vnos: pri\u010Dakovano instanceof ${r.expected}, prejeto ${c}`:`Neveljaven vnos: pri\u010Dakovano ${i}, prejeto ${c}`}case"invalid_value":return r.values.length===1?`Neveljaven vnos: pri\u010Dakovano ${N(r.values[0])}`:`Neveljavna mo\u017Enost: pri\u010Dakovano eno izmed ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} imelo ${i}${r.maximum.toString()} ${a.unit??"elementov"}`:`Preveliko: pri\u010Dakovano, da bo ${r.origin??"vrednost"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Premajhno: pri\u010Dakovano, da bo ${r.origin} imelo ${i}${r.minimum.toString()} ${a.unit}`:`Premajhno: pri\u010Dakovano, da bo ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Neveljaven niz: mora se za\u010Deti z "${i.prefix}"`:i.format==="ends_with"?`Neveljaven niz: mora se kon\u010Dati z "${i.suffix}"`:i.format==="includes"?`Neveljaven niz: mora vsebovati "${i.includes}"`:i.format==="regex"?`Neveljaven niz: mora ustrezati vzorcu ${i.pattern}`:`Neveljaven ${o[i.format]??r.format}`}case"not_multiple_of":return`Neveljavno \u0161tevilo: mora biti ve\u010Dkratnik ${r.divisor}`;case"unrecognized_keys":return`Neprepoznan${r.keys.length>1?"i klju\u010Di":" klju\u010D"}: ${w(r.keys,", ")}`;case"invalid_key":return`Neveljaven klju\u010D v ${r.origin}`;case"invalid_union":return"Neveljaven vnos";case"invalid_element":return`Neveljavna vrednost v ${r.origin}`;default:return"Neveljaven vnos"}}},"error");function Id(){return{localeError:sR()}}s(Id,"default");var cR=s(()=>{let e={string:{unit:"tecken",verb:"att ha"},file:{unit:"bytes",verb:"att ha"},array:{unit:"objekt",verb:"att inneh\xE5lla"},set:{unit:"objekt",verb:"att inneh\xE5lla"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"regulj\xE4rt uttryck",email:"e-postadress",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO-datum och tid",date:"ISO-datum",time:"ISO-tid",duration:"ISO-varaktighet",ipv4:"IPv4-intervall",ipv6:"IPv6-intervall",cidrv4:"IPv4-spektrum",cidrv6:"IPv6-spektrum",base64:"base64-kodad str\xE4ng",base64url:"base64url-kodad str\xE4ng",json_string:"JSON-str\xE4ng",e164:"E.164-nummer",jwt:"JWT",template_literal:"mall-literal"},n={nan:"NaN",number:"antal",array:"lista"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ogiltig inmatning: f\xF6rv\xE4ntat instanceof ${r.expected}, fick ${c}`:`Ogiltig inmatning: f\xF6rv\xE4ntat ${i}, fick ${c}`}case"invalid_value":return r.values.length===1?`Ogiltig inmatning: f\xF6rv\xE4ntat ${N(r.values[0])}`:`Ogiltigt val: f\xF6rv\xE4ntade en av ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`F\xF6r stor(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()} ${a.unit??"element"}`:`F\xF6r stor(t): f\xF6rv\xE4ntat ${r.origin??"v\xE4rdet"} att ha ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()} ${a.unit}`:`F\xF6r lite(t): f\xF6rv\xE4ntade ${r.origin??"v\xE4rdet"} att ha ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ogiltig str\xE4ng: m\xE5ste b\xF6rja med "${i.prefix}"`:i.format==="ends_with"?`Ogiltig str\xE4ng: m\xE5ste sluta med "${i.suffix}"`:i.format==="includes"?`Ogiltig str\xE4ng: m\xE5ste inneh\xE5lla "${i.includes}"`:i.format==="regex"?`Ogiltig str\xE4ng: m\xE5ste matcha m\xF6nstret "${i.pattern}"`:`Ogiltig(t) ${o[i.format]??r.format}`}case"not_multiple_of":return`Ogiltigt tal: m\xE5ste vara en multipel av ${r.divisor}`;case"unrecognized_keys":return`${r.keys.length>1?"Ok\xE4nda nycklar":"Ok\xE4nd nyckel"}: ${w(r.keys,", ")}`;case"invalid_key":return`Ogiltig nyckel i ${r.origin??"v\xE4rdet"}`;case"invalid_union":return"Ogiltig input";case"invalid_element":return`Ogiltigt v\xE4rde i ${r.origin??"v\xE4rdet"}`;default:return"Ogiltig input"}}},"error");function Ad(){return{localeError:cR()}}s(Ad,"default");var uR=s(()=>{let e={string:{unit:"\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},file:{unit:"\u0BAA\u0BC8\u0B9F\u0BCD\u0B9F\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},array:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"},set:{unit:"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD",verb:"\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1",email:"\u0BAE\u0BBF\u0BA9\u0BCD\u0BA9\u0B9E\u0BCD\u0B9A\u0BB2\u0BCD \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u0BA4\u0BC7\u0BA4\u0BBF \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",date:"ISO \u0BA4\u0BC7\u0BA4\u0BBF",time:"ISO \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD",duration:"ISO \u0B95\u0BBE\u0BB2 \u0B85\u0BB3\u0BB5\u0BC1",ipv4:"IPv4 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",ipv6:"IPv6 \u0BAE\u0BC1\u0B95\u0BB5\u0BB0\u0BBF",cidrv4:"IPv4 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",cidrv6:"IPv6 \u0BB5\u0BB0\u0BAE\u0BCD\u0BAA\u0BC1",base64:"base64-encoded \u0B9A\u0BB0\u0BAE\u0BCD",base64url:"base64url-encoded \u0B9A\u0BB0\u0BAE\u0BCD",json_string:"JSON \u0B9A\u0BB0\u0BAE\u0BCD",e164:"E.164 \u0B8E\u0BA3\u0BCD",jwt:"JWT",template_literal:"input"},n={nan:"NaN",number:"\u0B8E\u0BA3\u0BCD",array:"\u0B85\u0BA3\u0BBF",null:"\u0BB5\u0BC6\u0BB1\u0BC1\u0BAE\u0BC8"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 instanceof ${r.expected}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${c}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${i}, \u0BAA\u0BC6\u0BB1\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${c}`}case"invalid_value":return r.values.length===1?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${N(r.values[0])}`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0BB0\u0BC1\u0BAA\u0BCD\u0BAA\u0BAE\u0BCD: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${w(r.values,"|")} \u0B87\u0BB2\u0BCD \u0B92\u0BA9\u0BCD\u0BB1\u0BC1`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} ${a.unit??"\u0B89\u0BB1\u0BC1\u0BAA\u0BCD\u0BAA\u0BC1\u0B95\u0BB3\u0BCD"} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95 \u0BAA\u0BC6\u0BB0\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin??"\u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1"} ${i}${r.maximum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} ${a.unit} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BAE\u0BBF\u0B95\u0B9A\u0BCD \u0B9A\u0BBF\u0BB1\u0BBF\u0BAF\u0BA4\u0BC1: \u0B8E\u0BA4\u0BBF\u0BB0\u0BCD\u0BAA\u0BBE\u0BB0\u0BCD\u0B95\u0BCD\u0B95\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BA4\u0BC1 ${r.origin} ${i}${r.minimum.toString()} \u0B86\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.prefix}" \u0B87\u0BB2\u0BCD \u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="ends_with"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.suffix}" \u0B87\u0BB2\u0BCD \u0BAE\u0BC1\u0B9F\u0BBF\u0BB5\u0B9F\u0BC8\u0BAF \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="includes"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: "${i.includes}" \u0B90 \u0B89\u0BB3\u0BCD\u0BB3\u0B9F\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:i.format==="regex"?`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B9A\u0BB0\u0BAE\u0BCD: ${i.pattern} \u0BAE\u0BC1\u0BB1\u0BC8\u0BAA\u0BBE\u0B9F\u0BCD\u0B9F\u0BC1\u0B9F\u0BA9\u0BCD \u0BAA\u0BCA\u0BB0\u0BC1\u0BA8\u0BCD\u0BA4 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`:`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B8E\u0BA3\u0BCD: ${r.divisor} \u0B87\u0BA9\u0BCD \u0BAA\u0BB2\u0BAE\u0BBE\u0B95 \u0B87\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD`;case"unrecognized_keys":return`\u0B85\u0B9F\u0BC8\u0BAF\u0BBE\u0BB3\u0BAE\u0BCD \u0BA4\u0BC6\u0BB0\u0BBF\u0BAF\u0BBE\u0BA4 \u0BB5\u0BBF\u0B9A\u0BC8${r.keys.length>1?"\u0B95\u0BB3\u0BCD":""}: ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BB5\u0BBF\u0B9A\u0BC8`;case"invalid_union":return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1";case"invalid_element":return`${r.origin} \u0B87\u0BB2\u0BCD \u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0BAE\u0BA4\u0BBF\u0BAA\u0BCD\u0BAA\u0BC1`;default:return"\u0BA4\u0BB5\u0BB1\u0BBE\u0BA9 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1"}}},"error");function kd(){return{localeError:uR()}}s(kd,"default");var pR=s(()=>{let e={string:{unit:"\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},file:{unit:"\u0E44\u0E1A\u0E15\u0E4C",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},array:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"},set:{unit:"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23",verb:"\u0E04\u0E27\u0E23\u0E21\u0E35"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19",email:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48\u0E2D\u0E35\u0E40\u0E21\u0E25",url:"URL",emoji:"\u0E2D\u0E34\u0E42\u0E21\u0E08\u0E34",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",date:"\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E41\u0E1A\u0E1A ISO",time:"\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",duration:"\u0E0A\u0E48\u0E27\u0E07\u0E40\u0E27\u0E25\u0E32\u0E41\u0E1A\u0E1A ISO",ipv4:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv4",ipv6:"\u0E17\u0E35\u0E48\u0E2D\u0E22\u0E39\u0E48 IPv6",cidrv4:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv4",cidrv6:"\u0E0A\u0E48\u0E27\u0E07 IP \u0E41\u0E1A\u0E1A IPv6",base64:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64",base64url:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A Base64 \u0E2A\u0E33\u0E2B\u0E23\u0E31\u0E1A URL",json_string:"\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E41\u0E1A\u0E1A JSON",e164:"\u0E40\u0E1A\u0E2D\u0E23\u0E4C\u0E42\u0E17\u0E23\u0E28\u0E31\u0E1E\u0E17\u0E4C\u0E23\u0E30\u0E2B\u0E27\u0E48\u0E32\u0E07\u0E1B\u0E23\u0E30\u0E40\u0E17\u0E28 (E.164)",jwt:"\u0E42\u0E17\u0E40\u0E04\u0E19 JWT",template_literal:"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E1B\u0E49\u0E2D\u0E19"},n={nan:"NaN",number:"\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02",array:"\u0E2D\u0E32\u0E23\u0E4C\u0E40\u0E23\u0E22\u0E4C (Array)",null:"\u0E44\u0E21\u0E48\u0E21\u0E35\u0E04\u0E48\u0E32 (null)"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 instanceof ${r.expected} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${c}`:`\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${i} \u0E41\u0E15\u0E48\u0E44\u0E14\u0E49\u0E23\u0E31\u0E1A ${c}`}case"invalid_value":return r.values.length===1?`\u0E04\u0E48\u0E32\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19 ${N(r.values[0])}`:`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E04\u0E27\u0E23\u0E40\u0E1B\u0E47\u0E19\u0E2B\u0E19\u0E36\u0E48\u0E07\u0E43\u0E19 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"\u0E44\u0E21\u0E48\u0E40\u0E01\u0E34\u0E19":"\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()} ${a.unit??"\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23"}`:`\u0E40\u0E01\u0E34\u0E19\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin??"\u0E04\u0E48\u0E32"} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?"\u0E2D\u0E22\u0E48\u0E32\u0E07\u0E19\u0E49\u0E2D\u0E22":"\u0E21\u0E32\u0E01\u0E01\u0E27\u0E48\u0E32",a=t(r.origin);return a?`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()} ${a.unit}`:`\u0E19\u0E49\u0E2D\u0E22\u0E01\u0E27\u0E48\u0E32\u0E01\u0E33\u0E2B\u0E19\u0E14: ${r.origin} \u0E04\u0E27\u0E23\u0E21\u0E35${i} ${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E02\u0E36\u0E49\u0E19\u0E15\u0E49\u0E19\u0E14\u0E49\u0E27\u0E22 "${i.prefix}"`:i.format==="ends_with"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E25\u0E07\u0E17\u0E49\u0E32\u0E22\u0E14\u0E49\u0E27\u0E22 "${i.suffix}"`:i.format==="includes"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21\u0E15\u0E49\u0E2D\u0E07\u0E21\u0E35 "${i.includes}" \u0E2D\u0E22\u0E39\u0E48\u0E43\u0E19\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21`:i.format==="regex"?`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14 ${i.pattern}`:`\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: ${o[i.format]??r.format}`}case"not_multiple_of":return`\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E15\u0E49\u0E2D\u0E07\u0E40\u0E1B\u0E47\u0E19\u0E08\u0E33\u0E19\u0E27\u0E19\u0E17\u0E35\u0E48\u0E2B\u0E32\u0E23\u0E14\u0E49\u0E27\u0E22 ${r.divisor} \u0E44\u0E14\u0E49\u0E25\u0E07\u0E15\u0E31\u0E27`;case"unrecognized_keys":return`\u0E1E\u0E1A\u0E04\u0E35\u0E22\u0E4C\u0E17\u0E35\u0E48\u0E44\u0E21\u0E48\u0E23\u0E39\u0E49\u0E08\u0E31\u0E01: ${w(r.keys,", ")}`;case"invalid_key":return`\u0E04\u0E35\u0E22\u0E4C\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;case"invalid_union":return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07: \u0E44\u0E21\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E1A\u0E23\u0E39\u0E1B\u0E41\u0E1A\u0E1A\u0E22\u0E39\u0E40\u0E19\u0E35\u0E22\u0E19\u0E17\u0E35\u0E48\u0E01\u0E33\u0E2B\u0E19\u0E14\u0E44\u0E27\u0E49";case"invalid_element":return`\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07\u0E43\u0E19 ${r.origin}`;default:return"\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07"}}},"error");function wd(){return{localeError:pR()}}s(wd,"default");var lR=s(()=>{let e={string:{unit:"karakter",verb:"olmal\u0131"},file:{unit:"bayt",verb:"olmal\u0131"},array:{unit:"\xF6\u011Fe",verb:"olmal\u0131"},set:{unit:"\xF6\u011Fe",verb:"olmal\u0131"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"girdi",email:"e-posta adresi",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO tarih ve saat",date:"ISO tarih",time:"ISO saat",duration:"ISO s\xFCre",ipv4:"IPv4 adresi",ipv6:"IPv6 adresi",cidrv4:"IPv4 aral\u0131\u011F\u0131",cidrv6:"IPv6 aral\u0131\u011F\u0131",base64:"base64 ile \u015Fifrelenmi\u015F metin",base64url:"base64url ile \u015Fifrelenmi\u015F metin",json_string:"JSON dizesi",e164:"E.164 say\u0131s\u0131",jwt:"JWT",template_literal:"\u015Eablon dizesi"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Ge\xE7ersiz de\u011Fer: beklenen instanceof ${r.expected}, al\u0131nan ${c}`:`Ge\xE7ersiz de\u011Fer: beklenen ${i}, al\u0131nan ${c}`}case"invalid_value":return r.values.length===1?`Ge\xE7ersiz de\u011Fer: beklenen ${N(r.values[0])}`:`Ge\xE7ersiz se\xE7enek: a\u015Fa\u011F\u0131dakilerden biri olmal\u0131: ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\xC7ok b\xFCy\xFCk: beklenen ${r.origin??"de\u011Fer"} ${i}${r.maximum.toString()} ${a.unit??"\xF6\u011Fe"}`:`\xC7ok b\xFCy\xFCk: beklenen ${r.origin??"de\u011Fer"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\xC7ok k\xFC\xE7\xFCk: beklenen ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\xC7ok k\xFC\xE7\xFCk: beklenen ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Ge\xE7ersiz metin: "${i.prefix}" ile ba\u015Flamal\u0131`:i.format==="ends_with"?`Ge\xE7ersiz metin: "${i.suffix}" ile bitmeli`:i.format==="includes"?`Ge\xE7ersiz metin: "${i.includes}" i\xE7ermeli`:i.format==="regex"?`Ge\xE7ersiz metin: ${i.pattern} desenine uymal\u0131`:`Ge\xE7ersiz ${o[i.format]??r.format}`}case"not_multiple_of":return`Ge\xE7ersiz say\u0131: ${r.divisor} ile tam b\xF6l\xFCnebilmeli`;case"unrecognized_keys":return`Tan\u0131nmayan anahtar${r.keys.length>1?"lar":""}: ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} i\xE7inde ge\xE7ersiz anahtar`;case"invalid_union":return"Ge\xE7ersiz de\u011Fer";case"invalid_element":return`${r.origin} i\xE7inde ge\xE7ersiz de\u011Fer`;default:return"Ge\xE7ersiz de\u011Fer"}}},"error");function Od(){return{localeError:lR()}}s(Od,"default");var dR=s(()=>{let e={string:{unit:"\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},file:{unit:"\u0431\u0430\u0439\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},array:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"},set:{unit:"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432",verb:"\u043C\u0430\u0442\u0438\u043C\u0435"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456",email:"\u0430\u0434\u0440\u0435\u0441\u0430 \u0435\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u043E\u0457 \u043F\u043E\u0448\u0442\u0438",url:"URL",emoji:"\u0435\u043C\u043E\u0434\u0437\u0456",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"\u0434\u0430\u0442\u0430 \u0442\u0430 \u0447\u0430\u0441 ISO",date:"\u0434\u0430\u0442\u0430 ISO",time:"\u0447\u0430\u0441 ISO",duration:"\u0442\u0440\u0438\u0432\u0430\u043B\u0456\u0441\u0442\u044C ISO",ipv4:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv4",ipv6:"\u0430\u0434\u0440\u0435\u0441\u0430 IPv6",cidrv4:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv4",cidrv6:"\u0434\u0456\u0430\u043F\u0430\u0437\u043E\u043D IPv6",base64:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64",base64url:"\u0440\u044F\u0434\u043E\u043A \u0443 \u043A\u043E\u0434\u0443\u0432\u0430\u043D\u043D\u0456 base64url",json_string:"\u0440\u044F\u0434\u043E\u043A JSON",e164:"\u043D\u043E\u043C\u0435\u0440 E.164",jwt:"JWT",template_literal:"\u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"},n={nan:"NaN",number:"\u0447\u0438\u0441\u043B\u043E",array:"\u043C\u0430\u0441\u0438\u0432"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F instanceof ${r.expected}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${c}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${i}, \u043E\u0442\u0440\u0438\u043C\u0430\u043D\u043E ${c}`}case"invalid_value":return r.values.length===1?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F ${N(r.values[0])}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0430 \u043E\u043F\u0446\u0456\u044F: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F \u043E\u0434\u043D\u0435 \u0437 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"\u0435\u043B\u0435\u043C\u0435\u043D\u0442\u0456\u0432"}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u0432\u0435\u043B\u0438\u043A\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin??"\u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F"} \u0431\u0443\u0434\u0435 ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`\u0417\u0430\u043D\u0430\u0434\u0442\u043E \u043C\u0430\u043B\u0435: \u043E\u0447\u0456\u043A\u0443\u0454\u0442\u044C\u0441\u044F, \u0449\u043E ${r.origin} \u0431\u0443\u0434\u0435 ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043F\u043E\u0447\u0438\u043D\u0430\u0442\u0438\u0441\u044F \u0437 "${i.prefix}"`:i.format==="ends_with"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0437\u0430\u043A\u0456\u043D\u0447\u0443\u0432\u0430\u0442\u0438\u0441\u044F \u043D\u0430 "${i.suffix}"`:i.format==="includes"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u043C\u0456\u0441\u0442\u0438\u0442\u0438 "${i.includes}"`:i.format==="regex"?`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u0440\u044F\u0434\u043E\u043A: \u043F\u043E\u0432\u0438\u043D\u0435\u043D \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u0430\u0442\u0438 \u0448\u0430\u0431\u043B\u043E\u043D\u0443 ${i.pattern}`:`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0447\u0438\u0441\u043B\u043E: \u043F\u043E\u0432\u0438\u043D\u043D\u043E \u0431\u0443\u0442\u0438 \u043A\u0440\u0430\u0442\u043D\u0438\u043C ${r.divisor}`;case"unrecognized_keys":return`\u041D\u0435\u0440\u043E\u0437\u043F\u0456\u0437\u043D\u0430\u043D\u0438\u0439 \u043A\u043B\u044E\u0447${r.keys.length>1?"\u0456":""}: ${w(r.keys,", ")}`;case"invalid_key":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0438\u0439 \u043A\u043B\u044E\u0447 \u0443 ${r.origin}`;case"invalid_union":return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456";case"invalid_element":return`\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u043D\u044F \u0443 ${r.origin}`;default:return"\u041D\u0435\u043F\u0440\u0430\u0432\u0438\u043B\u044C\u043D\u0456 \u0432\u0445\u0456\u0434\u043D\u0456 \u0434\u0430\u043D\u0456"}}},"error");function qn(){return{localeError:dR()}}s(qn,"default");function Rd(){return qn()}s(Rd,"default");var mR=s(()=>{let e={string:{unit:"\u062D\u0631\u0648\u0641",verb:"\u06C1\u0648\u0646\u0627"},file:{unit:"\u0628\u0627\u0626\u0679\u0633",verb:"\u06C1\u0648\u0646\u0627"},array:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"},set:{unit:"\u0622\u0626\u0679\u0645\u0632",verb:"\u06C1\u0648\u0646\u0627"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0627\u0646 \u067E\u0679",email:"\u0627\u06CC \u0645\u06CC\u0644 \u0627\u06CC\u0688\u0631\u06CC\u0633",url:"\u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644",emoji:"\u0627\u06CC\u0645\u0648\u062C\u06CC",uuid:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",uuidv4:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 4",uuidv6:"\u06CC\u0648 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC \u0648\u06CC 6",nanoid:"\u0646\u06CC\u0646\u0648 \u0622\u0626\u06CC \u0688\u06CC",guid:"\u062C\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",cuid2:"\u0633\u06CC \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC 2",ulid:"\u06CC\u0648 \u0627\u06CC\u0644 \u0622\u0626\u06CC \u0688\u06CC",xid:"\u0627\u06CC\u06A9\u0633 \u0622\u0626\u06CC \u0688\u06CC",ksuid:"\u06A9\u06D2 \u0627\u06CC\u0633 \u06CC\u0648 \u0622\u0626\u06CC \u0688\u06CC",datetime:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0688\u06CC\u0679 \u0679\u0627\u0626\u0645",date:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u062A\u0627\u0631\u06CC\u062E",time:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0648\u0642\u062A",duration:"\u0622\u0626\u06CC \u0627\u06CC\u0633 \u0627\u0648 \u0645\u062F\u062A",ipv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0627\u06CC\u0688\u0631\u06CC\u0633",ipv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0627\u06CC\u0688\u0631\u06CC\u0633",cidrv4:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 4 \u0631\u06CC\u0646\u062C",cidrv6:"\u0622\u0626\u06CC \u067E\u06CC \u0648\u06CC 6 \u0631\u06CC\u0646\u062C",base64:"\u0628\u06CC\u0633 64 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",base64url:"\u0628\u06CC\u0633 64 \u06CC\u0648 \u0622\u0631 \u0627\u06CC\u0644 \u0627\u0646 \u06A9\u0648\u0688\u0688 \u0633\u0679\u0631\u0646\u06AF",json_string:"\u062C\u06D2 \u0627\u06CC\u0633 \u0627\u0648 \u0627\u06CC\u0646 \u0633\u0679\u0631\u0646\u06AF",e164:"\u0627\u06CC 164 \u0646\u0645\u0628\u0631",jwt:"\u062C\u06D2 \u0688\u0628\u0644\u06CC\u0648 \u0679\u06CC",template_literal:"\u0627\u0646 \u067E\u0679"},n={nan:"NaN",number:"\u0646\u0645\u0628\u0631",array:"\u0622\u0631\u06D2",null:"\u0646\u0644"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: instanceof ${r.expected} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${c} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`:`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${i} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627\u060C ${c} \u0645\u0648\u0635\u0648\u0644 \u06C1\u0648\u0627`}case"invalid_value":return r.values.length===1?`\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679: ${N(r.values[0])} \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`:`\u063A\u0644\u0637 \u0622\u067E\u0634\u0646: ${w(r.values,"|")} \u0645\u06CC\u06BA \u0633\u06D2 \u0627\u06CC\u06A9 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u06D2 ${i}${r.maximum.toString()} ${a.unit??"\u0639\u0646\u0627\u0635\u0631"} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0628\u0691\u0627: ${r.origin??"\u0648\u06CC\u0644\u06CC\u0648"} \u06A9\u0627 ${i}${r.maximum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u06D2 ${i}${r.minimum.toString()} ${a.unit} \u06C1\u0648\u0646\u06D2 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u06D2`:`\u0628\u06C1\u062A \u0686\u06BE\u0648\u0679\u0627: ${r.origin} \u06A9\u0627 ${i}${r.minimum.toString()} \u06C1\u0648\u0646\u0627 \u0645\u062A\u0648\u0642\u0639 \u062A\u06BE\u0627`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.prefix}" \u0633\u06D2 \u0634\u0631\u0648\u0639 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="ends_with"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.suffix}" \u067E\u0631 \u062E\u062A\u0645 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="includes"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: "${i.includes}" \u0634\u0627\u0645\u0644 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:i.format==="regex"?`\u063A\u0644\u0637 \u0633\u0679\u0631\u0646\u06AF: \u067E\u06CC\u0679\u0631\u0646 ${i.pattern} \u0633\u06D2 \u0645\u06CC\u0686 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`:`\u063A\u0644\u0637 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u063A\u0644\u0637 \u0646\u0645\u0628\u0631: ${r.divisor} \u06A9\u0627 \u0645\u0636\u0627\u0639\u0641 \u06C1\u0648\u0646\u0627 \u0686\u0627\u06C1\u06CC\u06D2`;case"unrecognized_keys":return`\u063A\u06CC\u0631 \u062A\u0633\u0644\u06CC\u0645 \u0634\u062F\u06C1 \u06A9\u06CC${r.keys.length>1?"\u0632":""}: ${w(r.keys,"\u060C ")}`;case"invalid_key":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u06A9\u06CC`;case"invalid_union":return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679";case"invalid_element":return`${r.origin} \u0645\u06CC\u06BA \u063A\u0644\u0637 \u0648\u06CC\u0644\u06CC\u0648`;default:return"\u063A\u0644\u0637 \u0627\u0646 \u067E\u0679"}}},"error");function Cd(){return{localeError:mR()}}s(Cd,"default");var fR=s(()=>{let e={string:{unit:"belgi",verb:"bo\u2018lishi kerak"},file:{unit:"bayt",verb:"bo\u2018lishi kerak"},array:{unit:"element",verb:"bo\u2018lishi kerak"},set:{unit:"element",verb:"bo\u2018lishi kerak"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"kirish",email:"elektron pochta manzili",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 sana va vaqti",date:"ISO sana",time:"ISO vaqt",duration:"ISO davomiylik",ipv4:"IPv4 manzil",ipv6:"IPv6 manzil",mac:"MAC manzil",cidrv4:"IPv4 diapazon",cidrv6:"IPv6 diapazon",base64:"base64 kodlangan satr",base64url:"base64url kodlangan satr",json_string:"JSON satr",e164:"E.164 raqam",jwt:"JWT",template_literal:"kirish"},n={nan:"NaN",number:"raqam",array:"massiv"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`Noto\u2018g\u2018ri kirish: kutilgan instanceof ${r.expected}, qabul qilingan ${c}`:`Noto\u2018g\u2018ri kirish: kutilgan ${i}, qabul qilingan ${c}`}case"invalid_value":return r.values.length===1?`Noto\u2018g\u2018ri kirish: kutilgan ${N(r.values[0])}`:`Noto\u2018g\u2018ri variant: quyidagilardan biri kutilgan ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Juda katta: kutilgan ${r.origin??"qiymat"} ${i}${r.maximum.toString()} ${a.unit} ${a.verb}`:`Juda katta: kutilgan ${r.origin??"qiymat"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Juda kichik: kutilgan ${r.origin} ${i}${r.minimum.toString()} ${a.unit} ${a.verb}`:`Juda kichik: kutilgan ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Noto\u2018g\u2018ri satr: "${i.prefix}" bilan boshlanishi kerak`:i.format==="ends_with"?`Noto\u2018g\u2018ri satr: "${i.suffix}" bilan tugashi kerak`:i.format==="includes"?`Noto\u2018g\u2018ri satr: "${i.includes}" ni o\u2018z ichiga olishi kerak`:i.format==="regex"?`Noto\u2018g\u2018ri satr: ${i.pattern} shabloniga mos kelishi kerak`:`Noto\u2018g\u2018ri ${o[i.format]??r.format}`}case"not_multiple_of":return`Noto\u2018g\u2018ri raqam: ${r.divisor} ning karralisi bo\u2018lishi kerak`;case"unrecognized_keys":return`Noma\u2019lum kalit${r.keys.length>1?"lar":""}: ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} dagi kalit noto\u2018g\u2018ri`;case"invalid_union":return"Noto\u2018g\u2018ri kirish";case"invalid_element":return`${r.origin} da noto\u2018g\u2018ri qiymat`;default:return"Noto\u2018g\u2018ri kirish"}}},"error");function $d(){return{localeError:fR()}}s($d,"default");var hR=s(()=>{let e={string:{unit:"k\xFD t\u1EF1",verb:"c\xF3"},file:{unit:"byte",verb:"c\xF3"},array:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"},set:{unit:"ph\u1EA7n t\u1EED",verb:"c\xF3"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u0111\u1EA7u v\xE0o",email:"\u0111\u1ECBa ch\u1EC9 email",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ng\xE0y gi\u1EDD ISO",date:"ng\xE0y ISO",time:"gi\u1EDD ISO",duration:"kho\u1EA3ng th\u1EDDi gian ISO",ipv4:"\u0111\u1ECBa ch\u1EC9 IPv4",ipv6:"\u0111\u1ECBa ch\u1EC9 IPv6",cidrv4:"d\u1EA3i IPv4",cidrv6:"d\u1EA3i IPv6",base64:"chu\u1ED7i m\xE3 h\xF3a base64",base64url:"chu\u1ED7i m\xE3 h\xF3a base64url",json_string:"chu\u1ED7i JSON",e164:"s\u1ED1 E.164",jwt:"JWT",template_literal:"\u0111\u1EA7u v\xE0o"},n={nan:"NaN",number:"s\u1ED1",array:"m\u1EA3ng"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i instanceof ${r.expected}, nh\u1EADn \u0111\u01B0\u1EE3c ${c}`:`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${i}, nh\u1EADn \u0111\u01B0\u1EE3c ${c}`}case"invalid_value":return r.values.length===1?`\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i ${N(r.values[0])}`:`T\xF9y ch\u1ECDn kh\xF4ng h\u1EE3p l\u1EC7: mong \u0111\u1EE3i m\u1ED9t trong c\xE1c gi\xE1 tr\u1ECB ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${a.verb} ${i}${r.maximum.toString()} ${a.unit??"ph\u1EA7n t\u1EED"}`:`Qu\xE1 l\u1EDBn: mong \u0111\u1EE3i ${r.origin??"gi\xE1 tr\u1ECB"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${a.verb} ${i}${r.minimum.toString()} ${a.unit}`:`Qu\xE1 nh\u1ECF: mong \u0111\u1EE3i ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i b\u1EAFt \u0111\u1EA7u b\u1EB1ng "${i.prefix}"`:i.format==="ends_with"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i k\u1EBFt th\xFAc b\u1EB1ng "${i.suffix}"`:i.format==="includes"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i bao g\u1ED3m "${i.includes}"`:i.format==="regex"?`Chu\u1ED7i kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i kh\u1EDBp v\u1EDBi m\u1EABu ${i.pattern}`:`${o[i.format]??r.format} kh\xF4ng h\u1EE3p l\u1EC7`}case"not_multiple_of":return`S\u1ED1 kh\xF4ng h\u1EE3p l\u1EC7: ph\u1EA3i l\xE0 b\u1ED9i s\u1ED1 c\u1EE7a ${r.divisor}`;case"unrecognized_keys":return`Kh\xF3a kh\xF4ng \u0111\u01B0\u1EE3c nh\u1EADn d\u1EA1ng: ${w(r.keys,", ")}`;case"invalid_key":return`Kh\xF3a kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;case"invalid_union":return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7";case"invalid_element":return`Gi\xE1 tr\u1ECB kh\xF4ng h\u1EE3p l\u1EC7 trong ${r.origin}`;default:return"\u0110\u1EA7u v\xE0o kh\xF4ng h\u1EE3p l\u1EC7"}}},"error");function Nd(){return{localeError:hR()}}s(Nd,"default");var yR=s(()=>{let e={string:{unit:"\u5B57\u7B26",verb:"\u5305\u542B"},file:{unit:"\u5B57\u8282",verb:"\u5305\u542B"},array:{unit:"\u9879",verb:"\u5305\u542B"},set:{unit:"\u9879",verb:"\u5305\u542B"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u8F93\u5165",email:"\u7535\u5B50\u90AE\u4EF6",url:"URL",emoji:"\u8868\u60C5\u7B26\u53F7",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO\u65E5\u671F\u65F6\u95F4",date:"ISO\u65E5\u671F",time:"ISO\u65F6\u95F4",duration:"ISO\u65F6\u957F",ipv4:"IPv4\u5730\u5740",ipv6:"IPv6\u5730\u5740",cidrv4:"IPv4\u7F51\u6BB5",cidrv6:"IPv6\u7F51\u6BB5",base64:"base64\u7F16\u7801\u5B57\u7B26\u4E32",base64url:"base64url\u7F16\u7801\u5B57\u7B26\u4E32",json_string:"JSON\u5B57\u7B26\u4E32",e164:"E.164\u53F7\u7801",jwt:"JWT",template_literal:"\u8F93\u5165"},n={nan:"NaN",number:"\u6570\u5B57",array:"\u6570\u7EC4",null:"\u7A7A\u503C(null)"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B instanceof ${r.expected}\uFF0C\u5B9E\u9645\u63A5\u6536 ${c}`:`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${i}\uFF0C\u5B9E\u9645\u63A5\u6536 ${c}`}case"invalid_value":return r.values.length===1?`\u65E0\u6548\u8F93\u5165\uFF1A\u671F\u671B ${N(r.values[0])}`:`\u65E0\u6548\u9009\u9879\uFF1A\u671F\u671B\u4EE5\u4E0B\u4E4B\u4E00 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()} ${a.unit??"\u4E2A\u5143\u7D20"}`:`\u6570\u503C\u8FC7\u5927\uFF1A\u671F\u671B ${r.origin??"\u503C"} ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()} ${a.unit}`:`\u6570\u503C\u8FC7\u5C0F\uFF1A\u671F\u671B ${r.origin} ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.prefix}" \u5F00\u5934`:i.format==="ends_with"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u4EE5 "${i.suffix}" \u7ED3\u5C3E`:i.format==="includes"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u65E0\u6548\u5B57\u7B26\u4E32\uFF1A\u5FC5\u987B\u6EE1\u8DB3\u6B63\u5219\u8868\u8FBE\u5F0F ${i.pattern}`:`\u65E0\u6548${o[i.format]??r.format}`}case"not_multiple_of":return`\u65E0\u6548\u6570\u5B57\uFF1A\u5FC5\u987B\u662F ${r.divisor} \u7684\u500D\u6570`;case"unrecognized_keys":return`\u51FA\u73B0\u672A\u77E5\u7684\u952E(key): ${w(r.keys,", ")}`;case"invalid_key":return`${r.origin} \u4E2D\u7684\u952E(key)\u65E0\u6548`;case"invalid_union":return"\u65E0\u6548\u8F93\u5165";case"invalid_element":return`${r.origin} \u4E2D\u5305\u542B\u65E0\u6548\u503C(value)`;default:return"\u65E0\u6548\u8F93\u5165"}}},"error");function Dd(){return{localeError:yR()}}s(Dd,"default");var gR=s(()=>{let e={string:{unit:"\u5B57\u5143",verb:"\u64C1\u6709"},file:{unit:"\u4F4D\u5143\u7D44",verb:"\u64C1\u6709"},array:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"},set:{unit:"\u9805\u76EE",verb:"\u64C1\u6709"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u8F38\u5165",email:"\u90F5\u4EF6\u5730\u5740",url:"URL",emoji:"emoji",uuid:"UUID",uuidv4:"UUIDv4",uuidv6:"UUIDv6",nanoid:"nanoid",guid:"GUID",cuid:"cuid",cuid2:"cuid2",ulid:"ULID",xid:"XID",ksuid:"KSUID",datetime:"ISO \u65E5\u671F\u6642\u9593",date:"ISO \u65E5\u671F",time:"ISO \u6642\u9593",duration:"ISO \u671F\u9593",ipv4:"IPv4 \u4F4D\u5740",ipv6:"IPv6 \u4F4D\u5740",cidrv4:"IPv4 \u7BC4\u570D",cidrv6:"IPv6 \u7BC4\u570D",base64:"base64 \u7DE8\u78BC\u5B57\u4E32",base64url:"base64url \u7DE8\u78BC\u5B57\u4E32",json_string:"JSON \u5B57\u4E32",e164:"E.164 \u6578\u503C",jwt:"JWT",template_literal:"\u8F38\u5165"},n={nan:"NaN"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA instanceof ${r.expected}\uFF0C\u4F46\u6536\u5230 ${c}`:`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${i}\uFF0C\u4F46\u6536\u5230 ${c}`}case"invalid_value":return r.values.length===1?`\u7121\u6548\u7684\u8F38\u5165\u503C\uFF1A\u9810\u671F\u70BA ${N(r.values[0])}`:`\u7121\u6548\u7684\u9078\u9805\uFF1A\u9810\u671F\u70BA\u4EE5\u4E0B\u5176\u4E2D\u4E4B\u4E00 ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()} ${a.unit??"\u500B\u5143\u7D20"}`:`\u6578\u503C\u904E\u5927\uFF1A\u9810\u671F ${r.origin??"\u503C"} \u61C9\u70BA ${i}${r.maximum.toString()}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()} ${a.unit}`:`\u6578\u503C\u904E\u5C0F\uFF1A\u9810\u671F ${r.origin} \u61C9\u70BA ${i}${r.minimum.toString()}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.prefix}" \u958B\u982D`:i.format==="ends_with"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u4EE5 "${i.suffix}" \u7D50\u5C3E`:i.format==="includes"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u5305\u542B "${i.includes}"`:i.format==="regex"?`\u7121\u6548\u7684\u5B57\u4E32\uFF1A\u5FC5\u9808\u7B26\u5408\u683C\u5F0F ${i.pattern}`:`\u7121\u6548\u7684 ${o[i.format]??r.format}`}case"not_multiple_of":return`\u7121\u6548\u7684\u6578\u5B57\uFF1A\u5FC5\u9808\u70BA ${r.divisor} \u7684\u500D\u6578`;case"unrecognized_keys":return`\u7121\u6CD5\u8B58\u5225\u7684\u9375\u503C${r.keys.length>1?"\u5011":""}\uFF1A${w(r.keys,"\u3001")}`;case"invalid_key":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u9375\u503C`;case"invalid_union":return"\u7121\u6548\u7684\u8F38\u5165\u503C";case"invalid_element":return`${r.origin} \u4E2D\u6709\u7121\u6548\u7684\u503C`;default:return"\u7121\u6548\u7684\u8F38\u5165\u503C"}}},"error");function zd(){return{localeError:gR()}}s(zd,"default");var vR=s(()=>{let e={string:{unit:"\xE0mi",verb:"n\xED"},file:{unit:"bytes",verb:"n\xED"},array:{unit:"nkan",verb:"n\xED"},set:{unit:"nkan",verb:"n\xED"}};function t(r){return e[r]??null}s(t,"getSizing");let o={regex:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9",email:"\xE0d\xEDr\u1EB9\u0301s\xEC \xECm\u1EB9\u0301l\xEC",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:"\xE0k\xF3k\xF2 ISO",date:"\u1ECDj\u1ECD\u0301 ISO",time:"\xE0k\xF3k\xF2 ISO",duration:"\xE0k\xF3k\xF2 t\xF3 p\xE9 ISO",ipv4:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv4",ipv6:"\xE0d\xEDr\u1EB9\u0301s\xEC IPv6",cidrv4:"\xE0gb\xE8gb\xE8 IPv4",cidrv6:"\xE0gb\xE8gb\xE8 IPv6",base64:"\u1ECD\u0300r\u1ECD\u0300 t\xED a k\u1ECD\u0301 n\xED base64",base64url:"\u1ECD\u0300r\u1ECD\u0300 base64url",json_string:"\u1ECD\u0300r\u1ECD\u0300 JSON",e164:"n\u1ECD\u0301mb\xE0 E.164",jwt:"JWT",template_literal:"\u1EB9\u0300r\u1ECD \xECb\xE1w\u1ECDl\xE9"},n={nan:"NaN",number:"n\u1ECD\u0301mb\xE0",array:"akop\u1ECD"};return r=>{switch(r.code){case"invalid_type":{let i=n[r.expected]??r.expected,a=z(r.input),c=n[a]??a;return/^[A-Z]/.test(r.expected)?`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi instanceof ${r.expected}, \xE0m\u1ECD\u0300 a r\xED ${c}`:`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${i}, \xE0m\u1ECD\u0300 a r\xED ${c}`}case"invalid_value":return r.values.length===1?`\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e: a n\xED l\xE1ti fi ${N(r.values[0])}`:`\xC0\u1E63\xE0y\xE0n a\u1E63\xEC\u1E63e: yan \u1ECD\u0300kan l\xE1ra ${w(r.values,"|")}`;case"too_big":{let i=r.inclusive?"<=":"<",a=t(r.origin);return a?`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin??"iye"} ${a.verb} ${i}${r.maximum} ${a.unit}`:`T\xF3 p\u1ECD\u0300 j\xF9: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.maximum}`}case"too_small":{let i=r.inclusive?">=":">",a=t(r.origin);return a?`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 p\xE9 ${r.origin} ${a.verb} ${i}${r.minimum} ${a.unit}`:`K\xE9r\xE9 ju: a n\xED l\xE1ti j\u1EB9\u0301 ${i}${r.minimum}`}case"invalid_format":{let i=r;return i.format==="starts_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\u1EB9\u0300r\u1EB9\u0300 p\u1EB9\u0300l\xFA "${i.prefix}"`:i.format==="ends_with"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 par\xED p\u1EB9\u0300l\xFA "${i.suffix}"`:i.format==="includes"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 n\xED "${i.includes}"`:i.format==="regex"?`\u1ECC\u0300r\u1ECD\u0300 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 b\xE1 \xE0p\u1EB9\u1EB9r\u1EB9 mu ${i.pattern}`:`A\u1E63\xEC\u1E63e: ${o[i.format]??r.format}`}case"not_multiple_of":return`N\u1ECD\u0301mb\xE0 a\u1E63\xEC\u1E63e: gb\u1ECD\u0301d\u1ECD\u0300 j\u1EB9\u0301 \xE8y\xE0 p\xEDp\xEDn ti ${r.divisor}`;case"unrecognized_keys":return`B\u1ECDt\xECn\xEC \xE0\xECm\u1ECD\u0300: ${w(r.keys,", ")}`;case"invalid_key":return`B\u1ECDt\xECn\xEC a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;case"invalid_union":return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e";case"invalid_element":return`Iye a\u1E63\xEC\u1E63e n\xEDn\xFA ${r.origin}`;default:return"\xCCb\xE1w\u1ECDl\xE9 a\u1E63\xEC\u1E63e"}}},"error");function Md(){return{localeError:vR()}}s(Md,"default");var Ag,tc=Symbol("ZodOutput"),rc=Symbol("ZodInput"),ec=class{static{s(this,"$ZodRegistry")}constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...o){let n=o[0];return this._map.set(t,n),n&&typeof n=="object"&&"id"in n&&this._idmap.set(n.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){let o=this._map.get(t);return o&&typeof o=="object"&&"id"in o&&this._idmap.delete(o.id),this._map.delete(t),this}get(t){let o=t._zod.parent;if(o){let n={...this.get(o)??{}};delete n.id;let r={...n,...this._map.get(t)};return Object.keys(r).length?r:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function jn(){return new ec}s(jn,"registry");(Ag=globalThis).__zod_globalRegistry??(Ag.__zod_globalRegistry=jn());var Re=globalThis.__zod_globalRegistry;function Fn(e,t){return new e({type:"string",...$(t)})}s(Fn,"_string");function Bn(e,t){return new e({type:"string",coerce:!0,...$(t)})}s(Bn,"_coercedString");function Zn(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...$(t)})}s(Zn,"_email");function lo(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...$(t)})}s(lo,"_guid");function Vn(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...$(t)})}s(Vn,"_uuid");function Gn(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...$(t)})}s(Gn,"_uuidv4");function Hn(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...$(t)})}s(Hn,"_uuidv6");function Wn(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...$(t)})}s(Wn,"_uuidv7");function xr(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...$(t)})}s(xr,"_url");function Kn(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...$(t)})}s(Kn,"_emoji");function Jn(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...$(t)})}s(Jn,"_nanoid");function Xn(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...$(t)})}s(Xn,"_cuid");function Yn(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...$(t)})}s(Yn,"_cuid2");function Qn(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...$(t)})}s(Qn,"_ulid");function ei(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...$(t)})}s(ei,"_xid");function ti(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...$(t)})}s(ti,"_ksuid");function ri(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...$(t)})}s(ri,"_ipv4");function oi(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...$(t)})}s(oi,"_ipv6");function oc(e,t){return new e({type:"string",format:"mac",check:"string_format",abort:!1,...$(t)})}s(oc,"_mac");function ni(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...$(t)})}s(ni,"_cidrv4");function ii(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...$(t)})}s(ii,"_cidrv6");function ai(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...$(t)})}s(ai,"_base64");function si(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...$(t)})}s(si,"_base64url");function ci(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...$(t)})}s(ci,"_e164");function ui(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...$(t)})}s(ui,"_jwt");var nc={Any:null,Minute:-1,Second:0,Millisecond:3,Microsecond:6};function ic(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...$(t)})}s(ic,"_isoDateTime");function ac(e,t){return new e({type:"string",format:"date",check:"string_format",...$(t)})}s(ac,"_isoDate");function sc(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...$(t)})}s(sc,"_isoTime");function cc(e,t){return new e({type:"string",format:"duration",check:"string_format",...$(t)})}s(cc,"_isoDuration");function pi(e,t){return new e({type:"number",checks:[],...$(t)})}s(pi,"_number");function li(e,t){return new e({type:"number",coerce:!0,checks:[],...$(t)})}s(li,"_coercedNumber");function di(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...$(t)})}s(di,"_int");function uc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float32",...$(t)})}s(uc,"_float32");function pc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"float64",...$(t)})}s(pc,"_float64");function lc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"int32",...$(t)})}s(lc,"_int32");function dc(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"uint32",...$(t)})}s(dc,"_uint32");function mi(e,t){return new e({type:"boolean",...$(t)})}s(mi,"_boolean");function fi(e,t){return new e({type:"boolean",coerce:!0,...$(t)})}s(fi,"_coercedBoolean");function mc(e,t){return new e({type:"bigint",...$(t)})}s(mc,"_bigint");function hi(e,t){return new e({type:"bigint",coerce:!0,...$(t)})}s(hi,"_coercedBigint");function fc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"int64",...$(t)})}s(fc,"_int64");function hc(e,t){return new e({type:"bigint",check:"bigint_format",abort:!1,format:"uint64",...$(t)})}s(hc,"_uint64");function yc(e,t){return new e({type:"symbol",...$(t)})}s(yc,"_symbol");function gc(e,t){return new e({type:"undefined",...$(t)})}s(gc,"_undefined");function vc(e,t){return new e({type:"null",...$(t)})}s(vc,"_null");function yi(e){return new e({type:"any"})}s(yi,"_any");function gi(e){return new e({type:"unknown"})}s(gi,"_unknown");function _c(e,t){return new e({type:"never",...$(t)})}s(_c,"_never");function vi(e,t){return new e({type:"void",...$(t)})}s(vi,"_void");function bc(e,t){return new e({type:"date",...$(t)})}s(bc,"_date");function _i(e,t){return new e({type:"date",coerce:!0,...$(t)})}s(_i,"_coercedDate");function Pc(e,t){return new e({type:"nan",...$(t)})}s(Pc,"_nan");function dt(e,t){return new es({check:"less_than",...$(t),value:e,inclusive:!1})}s(dt,"_lt");function je(e,t){return new es({check:"less_than",...$(t),value:e,inclusive:!0})}s(je,"_lte");function mt(e,t){return new ts({check:"greater_than",...$(t),value:e,inclusive:!1})}s(mt,"_gt");function Ae(e,t){return new ts({check:"greater_than",...$(t),value:e,inclusive:!0})}s(Ae,"_gte");function bi(e){return mt(0,e)}s(bi,"_positive");function Pi(e){return dt(0,e)}s(Pi,"_negative");function xi(e){return je(0,e)}s(xi,"_nonpositive");function Si(e){return Ae(0,e)}s(Si,"_nonnegative");function Ot(e,t){return new Tl({check:"multiple_of",...$(t),value:e})}s(Ot,"_multipleOf");function Rt(e,t){return new Al({check:"max_size",...$(t),maximum:e})}s(Rt,"_maxSize");function ft(e,t){return new kl({check:"min_size",...$(t),minimum:e})}s(ft,"_minSize");function Zt(e,t){return new wl({check:"size_equals",...$(t),size:e})}s(Zt,"_size");function Vt(e,t){return new Ol({check:"max_length",...$(t),maximum:e})}s(Vt,"_maxLength");function Se(e,t){return new Rl({check:"min_length",...$(t),minimum:e})}s(Se,"_minLength");function Gt(e,t){return new Cl({check:"length_equals",...$(t),length:e})}s(Gt,"_length");function ze(e,t){return new $l({check:"string_format",format:"regex",...$(t),pattern:e})}s(ze,"_regex");function Sr(e){return new Nl({check:"string_format",format:"lowercase",...$(e)})}s(Sr,"_lowercase");function Tr(e){return new Dl({check:"string_format",format:"uppercase",...$(e)})}s(Tr,"_uppercase");function Er(e,t){return new zl({check:"string_format",format:"includes",...$(t),includes:e})}s(Er,"_includes");function Ir(e,t){return new Ml({check:"string_format",format:"starts_with",...$(t),prefix:e})}s(Ir,"_startsWith");function Ar(e,t){return new Ll({check:"string_format",format:"ends_with",...$(t),suffix:e})}s(Ar,"_endsWith");function Ti(e,t,o){return new Ul({check:"property",property:e,schema:t,...$(o)})}s(Ti,"_property");function kr(e,t){return new ql({check:"mime_type",mime:e,...$(t)})}s(kr,"_mime");function it(e){return new jl({check:"overwrite",tx:e})}s(it,"_overwrite");function wr(e){return it(t=>t.normalize(e))}s(wr,"_normalize");function Or(){return it(e=>e.trim())}s(Or,"_trim");function Rr(){return it(e=>e.toLowerCase())}s(Rr,"_toLowerCase");function Cr(){return it(e=>e.toUpperCase())}s(Cr,"_toUpperCase");function mo(){return it(e=>Zp(e))}s(mo,"_slugify");function Ld(e,t,o){return new e({type:"array",element:t,...$(o)})}s(Ld,"_array");function bR(e,t,o){return new e({type:"union",options:t,...$(o)})}s(bR,"_union");function PR(e,t,o){return new e({type:"union",options:t,inclusive:!1,...$(o)})}s(PR,"_xor");function xR(e,t,o,n){return new e({type:"union",options:o,discriminator:t,...$(n)})}s(xR,"_discriminatedUnion");function SR(e,t,o){return new e({type:"intersection",left:t,right:o})}s(SR,"_intersection");function TR(e,t,o,n){let r=o instanceof Z,i=r?n:o,a=r?o:null;return new e({type:"tuple",items:t,rest:a,...$(i)})}s(TR,"_tuple");function ER(e,t,o,n){return new e({type:"record",keyType:t,valueType:o,...$(n)})}s(ER,"_record");function IR(e,t,o,n){return new e({type:"map",keyType:t,valueType:o,...$(n)})}s(IR,"_map");function AR(e,t,o){return new e({type:"set",valueType:t,...$(o)})}s(AR,"_set");function kR(e,t,o){let n=Array.isArray(t)?Object.fromEntries(t.map(r=>[r,r])):t;return new e({type:"enum",entries:n,...$(o)})}s(kR,"_enum");function wR(e,t,o){return new e({type:"enum",entries:t,...$(o)})}s(wR,"_nativeEnum");function OR(e,t,o){return new e({type:"literal",values:Array.isArray(t)?t:[t],...$(o)})}s(OR,"_literal");function xc(e,t){return new e({type:"file",...$(t)})}s(xc,"_file");function RR(e,t){return new e({type:"transform",transform:t})}s(RR,"_transform");function CR(e,t){return new e({type:"optional",innerType:t})}s(CR,"_optional");function $R(e,t){return new e({type:"nullable",innerType:t})}s($R,"_nullable");function NR(e,t,o){return new e({type:"default",innerType:t,get defaultValue(){return typeof o=="function"?o():ja(o)}})}s(NR,"_default");function DR(e,t,o){return new e({type:"nonoptional",innerType:t,...$(o)})}s(DR,"_nonoptional");function zR(e,t){return new e({type:"success",innerType:t})}s(zR,"_success");function MR(e,t,o){return new e({type:"catch",innerType:t,catchValue:typeof o=="function"?o:()=>o})}s(MR,"_catch");function LR(e,t,o){return new e({type:"pipe",in:t,out:o})}s(LR,"_pipe");function UR(e,t){return new e({type:"readonly",innerType:t})}s(UR,"_readonly");function qR(e,t,o){return new e({type:"template_literal",parts:t,...$(o)})}s(qR,"_templateLiteral");function jR(e,t){return new e({type:"lazy",getter:t})}s(jR,"_lazy");function FR(e,t){return new e({type:"promise",innerType:t})}s(FR,"_promise");function Ei(e,t,o){let n=$(o);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}s(Ei,"_custom");function Sc(e,t,o){return new e({type:"custom",check:"custom",fn:t,...$(o)})}s(Sc,"_refine");function Tc(e){let t=kg(o=>(o.addIssue=n=>{if(typeof n=="string")o.issues.push(Kr(n,o.value,t._zod.def));else{let r=n;r.fatal&&(r.continue=!1),r.code??(r.code="custom"),r.input??(r.input=o.value),r.inst??(r.inst=t),r.continue??(r.continue=!t._zod.def.abort),o.issues.push(Kr(r))}},e(o.value,o)));return t}s(Tc,"_superRefine");function kg(e,t){let o=new ae({check:"custom",...$(t)});return o._zod.check=e,o}s(kg,"_check");function Ec(e){let t=new ae({check:"describe"});return t._zod.onattach=[o=>{let n=Re.get(o)??{};Re.add(o,{...n,description:e})}],t._zod.check=()=>{},t}s(Ec,"describe");function Ic(e){let t=new ae({check:"meta"});return t._zod.onattach=[o=>{let n=Re.get(o)??{};Re.add(o,{...n,...e})}],t._zod.check=()=>{},t}s(Ic,"meta");function Ac(e,t){let o=$(t),n=o.truthy??["true","1","yes","on","y","enabled"],r=o.falsy??["false","0","no","off","n","disabled"];o.case!=="sensitive"&&(n=n.map(f=>typeof f=="string"?f.toLowerCase():f),r=r.map(f=>typeof f=="string"?f.toLowerCase():f));let i=new Set(n),a=new Set(r),c=e.Codec??co,p=e.Boolean??br,m=e.String??wt,l=new m({type:"string",error:o.error}),g=new p({type:"boolean",error:o.error}),h=new c({type:"pipe",in:l,out:g,transform:s(((f,v)=>{let I=f;return o.case!=="sensitive"&&(I=I.toLowerCase()),i.has(I)?!0:a.has(I)?!1:(v.issues.push({code:"invalid_value",expected:"stringbool",values:[...i,...a],input:v.value,inst:h,continue:!1}),{})}),"transform"),reverseTransform:s(((f,v)=>f===!0?n[0]||"true":r[0]||"false"),"reverseTransform"),error:o.error});return h}s(Ac,"_stringbool");function $r(e,t,o,n={}){let r=$(n),i={...$(n),check:"string_format",type:"string",format:t,fn:typeof o=="function"?o:c=>o.test(c),...r};return o instanceof RegExp&&(i.pattern=o),new e(i)}s($r,"_stringFormat");function Ht(e){let t=e?.target??"draft-2020-12";return t==="draft-4"&&(t="draft-04"),t==="draft-7"&&(t="draft-07"),{processors:e.processors??{},metadataRegistry:e?.metadata??Re,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}}s(Ht,"initializeContext");function ie(e,t,o={path:[],schemaPath:[]}){var n;let r=e._zod.def,i=t.seen.get(e);if(i)return i.count++,o.schemaPath.includes(e)&&(i.cycle=o.path),i.schema;let a={schema:{},count:1,cycle:void 0,path:o.path};t.seen.set(e,a);let c=e._zod.toJSONSchema?.();if(c)a.schema=c;else{let l={...o,schemaPath:[...o.schemaPath,e],path:o.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,a.schema,l);else{let h=a.schema,f=t.processors[r.type];if(!f)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${r.type}`);f(e,t,h,l)}let g=e._zod.parent;g&&(a.ref||(a.ref=g),ie(g,t,l),t.seen.get(g).isParent=!0)}let p=t.metadataRegistry.get(e);return p&&Object.assign(a.schema,p),t.io==="input"&&Fe(e)&&(delete a.schema.examples,delete a.schema.default),t.io==="input"&&a.schema._prefault&&((n=a.schema).default??(n.default=a.schema._prefault)),delete a.schema._prefault,t.seen.get(e).schema}s(ie,"process");function Wt(e,t){let o=e.seen.get(t);if(!o)throw new Error("Unprocessed schema. This is a bug in Zod.");let n=new Map;for(let a of e.seen.entries()){let c=e.metadataRegistry.get(a[0])?.id;if(c){let p=n.get(c);if(p&&p!==a[0])throw new Error(`Duplicate schema id "${c}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);n.set(c,a[0])}}let r=s(a=>{let c=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){let g=e.external.registry.get(a[0])?.id,h=e.external.uri??(v=>v);if(g)return{ref:h(g)};let f=a[1].defId??a[1].schema.id??`schema${e.counter++}`;return a[1].defId=f,{defId:f,ref:`${h("__shared")}#/${c}/${f}`}}if(a[1]===o)return{ref:"#"};let m=`#/${c}/`,l=a[1].schema.id??`__schema${e.counter++}`;return{defId:l,ref:m+l}},"makeURI"),i=s(a=>{if(a[1].schema.$ref)return;let c=a[1],{ref:p,defId:m}=r(a);c.def={...c.schema},m&&(c.defId=m);let l=c.schema;for(let g in l)delete l[g];l.$ref=p},"extractToDef");if(e.cycles==="throw")for(let a of e.seen.entries()){let c=a[1];if(c.cycle)throw new Error(`Cycle detected: #/${c.cycle?.join("/")}/<root>
|
|
8
43
|
|
|
9
|
-
Note: The provided signing secret contains whitespace. This often indicates an extra newline or space is in the value`:"";if(!A)throw I?new Fe(P,m,{message:`Webhook payload must be provided as a string or a Buffer (https://nodejs.org/api/buffer.html) instance representing the _raw_ request body.Payload was provided as a parsed JavaScript object instead.
|
|
44
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let a of e.seen.entries()){let c=a[1];if(t===a[0]){i(a);continue}if(e.external){let m=e.external.registry.get(a[0])?.id;if(t!==a[0]&&m){i(a);continue}}if(e.metadataRegistry.get(a[0])?.id){i(a);continue}if(c.cycle){i(a);continue}if(c.count>1&&e.reused==="ref"){i(a);continue}}}s(Wt,"extractDefs");function Kt(e,t){let o=e.seen.get(t);if(!o)throw new Error("Unprocessed schema. This is a bug in Zod.");let n=s(a=>{let c=e.seen.get(a);if(c.ref===null)return;let p=c.def??c.schema,m={...p},l=c.ref;if(c.ref=null,l){n(l);let h=e.seen.get(l),f=h.schema;if(f.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(p.allOf=p.allOf??[],p.allOf.push(f)):Object.assign(p,f),Object.assign(p,m),a._zod.parent===l)for(let I in p)I==="$ref"||I==="allOf"||I in m||delete p[I];if(f.$ref&&h.def)for(let I in p)I==="$ref"||I==="allOf"||I in h.def&&JSON.stringify(p[I])===JSON.stringify(h.def[I])&&delete p[I]}let g=a._zod.parent;if(g&&g!==l){n(g);let h=e.seen.get(g);if(h?.schema.$ref&&(p.$ref=h.schema.$ref,h.def))for(let f in p)f==="$ref"||f==="allOf"||f in h.def&&JSON.stringify(p[f])===JSON.stringify(h.def[f])&&delete p[f]}e.override({zodSchema:a,jsonSchema:p,path:c.path??[]})},"flattenRef");for(let a of[...e.seen.entries()].reverse())n(a[0]);let r={};if(e.target==="draft-2020-12"?r.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?r.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?r.$schema="http://json-schema.org/draft-04/schema#":e.target,e.external?.uri){let a=e.external.registry.get(t)?.id;if(!a)throw new Error("Schema is missing an `id` property");r.$id=e.external.uri(a)}Object.assign(r,o.def??o.schema);let i=e.external?.defs??{};for(let a of e.seen.entries()){let c=a[1];c.def&&c.defId&&(i[c.defId]=c.def)}e.external||Object.keys(i).length>0&&(e.target==="draft-2020-12"?r.$defs=i:r.definitions=i);try{let a=JSON.parse(JSON.stringify(r));return Object.defineProperty(a,"~standard",{value:{...t["~standard"],jsonSchema:{input:fo(t,"input",e.processors),output:fo(t,"output",e.processors)}},enumerable:!1,writable:!1}),a}catch{throw new Error("Error converting schema to JSON.")}}s(Kt,"finalize");function Fe(e,t){let o=t??{seen:new Set};if(o.seen.has(e))return!1;o.seen.add(e);let n=e._zod.def;if(n.type==="transform")return!0;if(n.type==="array")return Fe(n.element,o);if(n.type==="set")return Fe(n.valueType,o);if(n.type==="lazy")return Fe(n.getter(),o);if(n.type==="promise"||n.type==="optional"||n.type==="nonoptional"||n.type==="nullable"||n.type==="readonly"||n.type==="default"||n.type==="prefault")return Fe(n.innerType,o);if(n.type==="intersection")return Fe(n.left,o)||Fe(n.right,o);if(n.type==="record"||n.type==="map")return Fe(n.keyType,o)||Fe(n.valueType,o);if(n.type==="pipe")return Fe(n.in,o)||Fe(n.out,o);if(n.type==="object"){for(let r in n.shape)if(Fe(n.shape[r],o))return!0;return!1}if(n.type==="union"){for(let r of n.options)if(Fe(r,o))return!0;return!1}if(n.type==="tuple"){for(let r of n.items)if(Fe(r,o))return!0;return!!(n.rest&&Fe(n.rest,o))}return!1}s(Fe,"isTransforming");var Ud=s((e,t={})=>o=>{let n=Ht({...o,processors:t});return ie(e,n),Wt(n,e),Kt(n,e)},"createToJSONSchemaMethod"),fo=s((e,t,o={})=>n=>{let{libraryOptions:r,target:i}=n??{},a=Ht({...r??{},target:i,io:t,processors:o});return ie(e,a),Wt(a,e),Kt(a,e)},"createStandardJSONSchemaMethod");var BR={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},qd=s((e,t,o,n)=>{let r=o;r.type="string";let{minimum:i,maximum:a,format:c,patterns:p,contentEncoding:m}=e._zod.bag;if(typeof i=="number"&&(r.minLength=i),typeof a=="number"&&(r.maxLength=a),c&&(r.format=BR[c]??c,r.format===""&&delete r.format,c==="time"&&delete r.format),m&&(r.contentEncoding=m),p&&p.size>0){let l=[...p];l.length===1?r.pattern=l[0].source:l.length>1&&(r.allOf=[...l.map(g=>({...t.target==="draft-07"||t.target==="draft-04"||t.target==="openapi-3.0"?{type:"string"}:{},pattern:g.source}))])}},"stringProcessor"),jd=s((e,t,o,n)=>{let r=o,{minimum:i,maximum:a,format:c,multipleOf:p,exclusiveMaximum:m,exclusiveMinimum:l}=e._zod.bag;typeof c=="string"&&c.includes("int")?r.type="integer":r.type="number",typeof l=="number"&&(t.target==="draft-04"||t.target==="openapi-3.0"?(r.minimum=l,r.exclusiveMinimum=!0):r.exclusiveMinimum=l),typeof i=="number"&&(r.minimum=i,typeof l=="number"&&t.target!=="draft-04"&&(l>=i?delete r.minimum:delete r.exclusiveMinimum)),typeof m=="number"&&(t.target==="draft-04"||t.target==="openapi-3.0"?(r.maximum=m,r.exclusiveMaximum=!0):r.exclusiveMaximum=m),typeof a=="number"&&(r.maximum=a,typeof m=="number"&&t.target!=="draft-04"&&(m<=a?delete r.maximum:delete r.exclusiveMaximum)),typeof p=="number"&&(r.multipleOf=p)},"numberProcessor"),Fd=s((e,t,o,n)=>{o.type="boolean"},"booleanProcessor"),Bd=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("BigInt cannot be represented in JSON Schema")},"bigintProcessor"),Zd=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Symbols cannot be represented in JSON Schema")},"symbolProcessor"),Vd=s((e,t,o,n)=>{t.target==="openapi-3.0"?(o.type="string",o.nullable=!0,o.enum=[null]):o.type="null"},"nullProcessor"),Gd=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Undefined cannot be represented in JSON Schema")},"undefinedProcessor"),Hd=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Void cannot be represented in JSON Schema")},"voidProcessor"),Wd=s((e,t,o,n)=>{o.not={}},"neverProcessor"),Kd=s((e,t,o,n)=>{},"anyProcessor"),Jd=s((e,t,o,n)=>{},"unknownProcessor"),Xd=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Date cannot be represented in JSON Schema")},"dateProcessor"),Yd=s((e,t,o,n)=>{let r=e._zod.def,i=dn(r.entries);i.every(a=>typeof a=="number")&&(o.type="number"),i.every(a=>typeof a=="string")&&(o.type="string"),o.enum=i},"enumProcessor"),Qd=s((e,t,o,n)=>{let r=e._zod.def,i=[];for(let a of r.values)if(a===void 0){if(t.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof a=="bigint"){if(t.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");i.push(Number(a))}else i.push(a);if(i.length!==0)if(i.length===1){let a=i[0];o.type=a===null?"null":typeof a,t.target==="draft-04"||t.target==="openapi-3.0"?o.enum=[a]:o.const=a}else i.every(a=>typeof a=="number")&&(o.type="number"),i.every(a=>typeof a=="string")&&(o.type="string"),i.every(a=>typeof a=="boolean")&&(o.type="boolean"),i.every(a=>a===null)&&(o.type="null"),o.enum=i},"literalProcessor"),em=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("NaN cannot be represented in JSON Schema")},"nanProcessor"),tm=s((e,t,o,n)=>{let r=o,i=e._zod.pattern;if(!i)throw new Error("Pattern not found in template literal");r.type="string",r.pattern=i.source},"templateLiteralProcessor"),rm=s((e,t,o,n)=>{let r=o,i={type:"string",format:"binary",contentEncoding:"binary"},{minimum:a,maximum:c,mime:p}=e._zod.bag;a!==void 0&&(i.minLength=a),c!==void 0&&(i.maxLength=c),p?p.length===1?(i.contentMediaType=p[0],Object.assign(r,i)):(Object.assign(r,i),r.anyOf=p.map(m=>({contentMediaType:m}))):Object.assign(r,i)},"fileProcessor"),om=s((e,t,o,n)=>{o.type="boolean"},"successProcessor"),nm=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema")},"customProcessor"),im=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Function types cannot be represented in JSON Schema")},"functionProcessor"),am=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema")},"transformProcessor"),sm=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Map cannot be represented in JSON Schema")},"mapProcessor"),cm=s((e,t,o,n)=>{if(t.unrepresentable==="throw")throw new Error("Set cannot be represented in JSON Schema")},"setProcessor"),um=s((e,t,o,n)=>{let r=o,i=e._zod.def,{minimum:a,maximum:c}=e._zod.bag;typeof a=="number"&&(r.minItems=a),typeof c=="number"&&(r.maxItems=c),r.type="array",r.items=ie(i.element,t,{...n,path:[...n.path,"items"]})},"arrayProcessor"),pm=s((e,t,o,n)=>{let r=o,i=e._zod.def;r.type="object",r.properties={};let a=i.shape;for(let m in a)r.properties[m]=ie(a[m],t,{...n,path:[...n.path,"properties",m]});let c=new Set(Object.keys(a)),p=new Set([...c].filter(m=>{let l=i.shape[m]._zod;return t.io==="input"?l.optin===void 0:l.optout===void 0}));p.size>0&&(r.required=Array.from(p)),i.catchall?._zod.def.type==="never"?r.additionalProperties=!1:i.catchall?i.catchall&&(r.additionalProperties=ie(i.catchall,t,{...n,path:[...n.path,"additionalProperties"]})):t.io==="output"&&(r.additionalProperties=!1)},"objectProcessor"),wc=s((e,t,o,n)=>{let r=e._zod.def,i=r.inclusive===!1,a=r.options.map((c,p)=>ie(c,t,{...n,path:[...n.path,i?"oneOf":"anyOf",p]}));i?o.oneOf=a:o.anyOf=a},"unionProcessor"),lm=s((e,t,o,n)=>{let r=e._zod.def,i=ie(r.left,t,{...n,path:[...n.path,"allOf",0]}),a=ie(r.right,t,{...n,path:[...n.path,"allOf",1]}),c=s(m=>"allOf"in m&&Object.keys(m).length===1,"isSimpleIntersection"),p=[...c(i)?i.allOf:[i],...c(a)?a.allOf:[a]];o.allOf=p},"intersectionProcessor"),dm=s((e,t,o,n)=>{let r=o,i=e._zod.def;r.type="array";let a=t.target==="draft-2020-12"?"prefixItems":"items",c=t.target==="draft-2020-12"||t.target==="openapi-3.0"?"items":"additionalItems",p=i.items.map((h,f)=>ie(h,t,{...n,path:[...n.path,a,f]})),m=i.rest?ie(i.rest,t,{...n,path:[...n.path,c,...t.target==="openapi-3.0"?[i.items.length]:[]]}):null;t.target==="draft-2020-12"?(r.prefixItems=p,m&&(r.items=m)):t.target==="openapi-3.0"?(r.items={anyOf:p},m&&r.items.anyOf.push(m),r.minItems=p.length,m||(r.maxItems=p.length)):(r.items=p,m&&(r.additionalItems=m));let{minimum:l,maximum:g}=e._zod.bag;typeof l=="number"&&(r.minItems=l),typeof g=="number"&&(r.maxItems=g)},"tupleProcessor"),mm=s((e,t,o,n)=>{let r=o,i=e._zod.def;r.type="object";let a=i.keyType,p=a._zod.bag?.patterns;if(i.mode==="loose"&&p&&p.size>0){let l=ie(i.valueType,t,{...n,path:[...n.path,"patternProperties","*"]});r.patternProperties={};for(let g of p)r.patternProperties[g.source]=l}else(t.target==="draft-07"||t.target==="draft-2020-12")&&(r.propertyNames=ie(i.keyType,t,{...n,path:[...n.path,"propertyNames"]})),r.additionalProperties=ie(i.valueType,t,{...n,path:[...n.path,"additionalProperties"]});let m=a._zod.values;if(m){let l=[...m].filter(g=>typeof g=="string"||typeof g=="number");l.length>0&&(r.required=l)}},"recordProcessor"),fm=s((e,t,o,n)=>{let r=e._zod.def,i=ie(r.innerType,t,n),a=t.seen.get(e);t.target==="openapi-3.0"?(a.ref=r.innerType,o.nullable=!0):o.anyOf=[i,{type:"null"}]},"nullableProcessor"),hm=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType},"nonoptionalProcessor"),ym=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType,o.default=JSON.parse(JSON.stringify(r.defaultValue))},"defaultProcessor"),gm=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType,t.io==="input"&&(o._prefault=JSON.parse(JSON.stringify(r.defaultValue)))},"prefaultProcessor"),vm=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType;let a;try{a=r.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}o.default=a},"catchProcessor"),_m=s((e,t,o,n)=>{let r=e._zod.def,i=t.io==="input"?r.in._zod.def.type==="transform"?r.out:r.in:r.out;ie(i,t,n);let a=t.seen.get(e);a.ref=i},"pipeProcessor"),bm=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType,o.readOnly=!0},"readonlyProcessor"),Pm=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType},"promiseProcessor"),Oc=s((e,t,o,n)=>{let r=e._zod.def;ie(r.innerType,t,n);let i=t.seen.get(e);i.ref=r.innerType},"optionalProcessor"),xm=s((e,t,o,n)=>{let r=e._zod.innerType;ie(r,t,n);let i=t.seen.get(e);i.ref=r},"lazyProcessor"),kc={string:qd,number:jd,boolean:Fd,bigint:Bd,symbol:Zd,null:Vd,undefined:Gd,void:Hd,never:Wd,any:Kd,unknown:Jd,date:Xd,enum:Yd,literal:Qd,nan:em,template_literal:tm,file:rm,success:om,custom:nm,function:im,transform:am,map:sm,set:cm,array:um,object:pm,union:wc,intersection:lm,tuple:dm,record:mm,nullable:fm,nonoptional:hm,default:ym,prefault:gm,catch:vm,pipe:_m,readonly:bm,promise:Pm,optional:Oc,lazy:xm};function Ii(e,t){if("_idmap"in e){let n=e,r=Ht({...t,processors:kc}),i={};for(let p of n._idmap.entries()){let[m,l]=p;ie(l,r)}let a={},c={registry:n,uri:t?.uri,defs:i};r.external=c;for(let p of n._idmap.entries()){let[m,l]=p;Wt(r,l),a[m]=Kt(r,l)}if(Object.keys(i).length>0){let p=r.target==="draft-2020-12"?"$defs":"definitions";a.__shared={[p]:i}}return{schemas:a}}let o=Ht({...t,processors:kc});return ie(e,o),Wt(o,e),Kt(o,e)}s(Ii,"toJSONSchema");var Rc=class{static{s(this,"JSONSchemaGenerator")}get metadataRegistry(){return this.ctx.metadataRegistry}get target(){return this.ctx.target}get unrepresentable(){return this.ctx.unrepresentable}get override(){return this.ctx.override}get io(){return this.ctx.io}get counter(){return this.ctx.counter}set counter(t){this.ctx.counter=t}get seen(){return this.ctx.seen}constructor(t){let o=t?.target??"draft-2020-12";o==="draft-4"&&(o="draft-04"),o==="draft-7"&&(o="draft-07"),this.ctx=Ht({processors:kc,target:o,...t?.metadata&&{metadata:t.metadata},...t?.unrepresentable&&{unrepresentable:t.unrepresentable},...t?.override&&{override:t.override},...t?.io&&{io:t.io}})}process(t,o={path:[],schemaPath:[]}){return ie(t,this.ctx,o)}emit(t,o){o&&(o.cycles&&(this.ctx.cycles=o.cycles),o.reused&&(this.ctx.reused=o.reused),o.external&&(this.ctx.external=o.external)),Wt(this.ctx,t);let n=Kt(this.ctx,t),{"~standard":r,...i}=n;return i}};var wg={};var Te=S("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");Z.init(e,t),e.def=t,e.type=t.type,e.parse=(o,n)=>gr(e,o,n,{callee:e.parse}),e.safeParse=(o,n)=>to(e,o,n),e.parseAsync=async(o,n)=>vr(e,o,n,{callee:e.parseAsync}),e.safeParseAsync=async(o,n)=>oo(e,o,n),e.check=(...o)=>e.clone({...t,checks:[...t.checks??[],...o.map(n=>typeof n=="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]},{parent:!0}),e.with=e.check,e.clone=(o,n)=>Oe(e,o,n),e.brand=()=>e,e.register=((o,n)=>(o.add(e,n),e)),e.apply=o=>o(e)}),Cc=S("ZodMiniString",(e,t)=>{wt.init(e,t),Te.init(e,t)});function y(e){return Fn(Cc,e)}s(y,"string");var Og=S("ZodMiniStringFormat",(e,t)=>{ne.init(e,t),Cc.init(e,t)});var GR=S("ZodMiniURL",(e,t)=>{Pn.init(e,t),Og.init(e,t)});function Rg(e){return xr(GR,e)}s(Rg,"url");var $c=S("ZodMiniNumber",(e,t)=>{io.init(e,t),Te.init(e,t)});function Ce(e){return pi($c,e)}s(Ce,"number");var HR=S("ZodMiniNumberFormat",(e,t)=>{xn.init(e,t),$c.init(e,t)});function Cg(e){return di(HR,e)}s(Cg,"int");var Sm=S("ZodMiniBoolean",(e,t)=>{br.init(e,t),Te.init(e,t)});function re(e){return mi(Sm,e)}s(re,"boolean");var $g=S("ZodMiniBigInt",(e,t)=>{ao.init(e,t),Te.init(e,t)});var WR=S("ZodMiniAny",(e,t)=>{Sn.init(e,t),Te.init(e,t)});function Ai(){return yi(WR)}s(Ai,"any");var KR=S("ZodMiniUnknown",(e,t)=>{Tn.init(e,t),Te.init(e,t)});function G(){return gi(KR)}s(G,"unknown");var JR=S("ZodMiniVoid",(e,t)=>{En.init(e,t),Te.init(e,t)});function Ng(e){return vi(JR,e)}s(Ng,"_void");var Dg=S("ZodMiniDate",(e,t)=>{In.init(e,t),Te.init(e,t)});var XR=S("ZodMiniArray",(e,t)=>{An.init(e,t),Te.init(e,t)});function B(e,t){return new XR({type:"array",element:e,...$(t)})}s(B,"array");var YR=S("ZodMiniObject",(e,t)=>{zs.init(e,t),Te.init(e,t),J(e,"shape",()=>t.shape)});function A(e,t){let o={type:"object",shape:e??{},...$(t)};return new YR(o)}s(A,"object");var QR=S("ZodMiniUnion",(e,t)=>{Pr.init(e,t),Te.init(e,t)});function X(e,t){return new QR({type:"union",options:e,...$(t)})}s(X,"union");var eC=S("ZodMiniDiscriminatedUnion",(e,t)=>{kn.init(e,t),Te.init(e,t)});function Jt(e,t,o){return new eC({type:"union",options:t,discriminator:e,...$(o)})}s(Jt,"discriminatedUnion");var tC=S("ZodMiniRecord",(e,t)=>{On.init(e,t),Te.init(e,t)});function H(e,t,o){return new tC({type:"record",keyType:e,valueType:t,...$(o)})}s(H,"record");var rC=S("ZodMiniEnum",(e,t)=>{Rn.init(e,t),Te.init(e,t),e.options=Object.values(t.entries)});function F(e,t){let o=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new rC({type:"enum",entries:o,...$(t)})}s(F,"_enum");var oC=S("ZodMiniLiteral",(e,t)=>{Cn.init(e,t),Te.init(e,t)});function j(e,t){return new oC({type:"literal",values:Array.isArray(e)?e:[e],...$(t)})}s(j,"literal");var nC=S("ZodMiniTransform",(e,t)=>{$n.init(e,t),Te.init(e,t)});function Xt(e){return new nC({type:"transform",transform:e})}s(Xt,"transform");var iC=S("ZodMiniOptional",(e,t)=>{so.init(e,t),Te.init(e,t)});function O(e){return new iC({type:"optional",innerType:e})}s(O,"optional");var aC=S("ZodMiniNullable",(e,t)=>{Nn.init(e,t),Te.init(e,t)});function ki(e){return new aC({type:"nullable",innerType:e})}s(ki,"nullable");var sC=S("ZodMiniPipe",(e,t)=>{Dn.init(e,t),Te.init(e,t)});function Yt(e,t){return new sC({type:"pipe",in:e,out:t})}s(Yt,"pipe");var cC=S("ZodMiniCustom",(e,t)=>{zn.init(e,t),Te.init(e,t)});function Nc(e,t){return Ei(cC,e??(()=>!0),t)}s(Nc,"custom");var wi={};Ye(wi,{bigint:()=>mC,boolean:()=>dC,date:()=>fC,number:()=>lC,string:()=>pC});function pC(e){return Bn(Cc,e)}s(pC,"string");function lC(e){return li($c,e)}s(lC,"number");function dC(e){return fi(Sm,e)}s(dC,"boolean");function mC(e){return hi($g,e)}s(mC,"bigint");function fC(e){return _i(Dg,e)}s(fC,"date");var Em=A({retryOnFailure:A({defaultValue:O(re()),hide:O(re())}),continueOnFailure:A({defaultValue:O(re()),hide:O(re())})}),Tm=class{constructor(t,o,n,r,i,a,c,p,m,l,g,h,f){this.name=t;this.displayName=o;this.description=n;this.props=r;this.propertyGroups=i;this.run=a;this.test=c;this.requireAuth=p;this.errorHandlingOptions=m;this.outputSchema=l;this.audience=g;this.aiMetadata=h;this.classification=f}static{s(this,"IAction")}},E=s(e=>new Tm(e.name,e.displayName,e.description,e.props,e.propertyGroups,e.run,e.test??e.run,e.requireAuth??!0,e.errorHandlingOptions??{continueOnFailure:{defaultValue:!1},retryOnFailure:{defaultValue:!1}},e.outputSchema,e.audience,e.aiMetadata,e.classification),"createAction");var te=A({displayName:y(),description:O(y()),advanced:O(re()),width:O(F(["half","full"])),icon:O(y()),placeholder:O(y())}),W=s((e,t)=>A({type:j(t),required:re(),defaultValue:O(Ai())}),"TPropertyValue");var tt=A({...te.shape,...W(y(),"SHORT_TEXT").shape}),Ct=A({...te.shape,...W(y(),"LONG_TEXT").shape});var Mg=A({label:y(),value:G(),description:O(y()),icon:O(y())}),Dc=A({disabled:O(re()),placeholder:O(y()),options:B(Mg)});var yC=F(["cards"]),rt=A({...te.shape,options:Dc,display:O(yC),...W(G(),"STATIC_DROPDOWN").shape}),$t=A({...te.shape,options:Dc,...W(B(G()),"STATIC_MULTI_SELECT_DROPDOWN").shape});var Im=A({...te.shape,...W(G(),"DROPDOWN").shape,refreshers:B(y())}),Oi=A({...te.shape,...W(B(G()),"MULTI_SELECT_DROPDOWN").shape,refreshers:B(y())});var Nt=A({...te.shape,reveals:O(B(y())),...W(re(),"CHECKBOX").shape});var Dt=A({...te.shape,display:O(F(["stepper"])),min:O(Ce()),max:O(Ce()),step:O(Ce()),...W(Ce(),"NUMBER").shape});var Ri=A({...te.shape,streaming:O(re()),...W(G(),"FILE").shape});var Ci=A({...te.shape,...W(y(),"DATE_TIME").shape});var Lg=H(y(),X([tt,Ct,rt,Oi,$t,Nt,Dt,Ri,Ci])),$i=A({...te.shape,properties:Lg,...W(B(G()),"ARRAY").shape});var Ug=F(["any_time","last_24_hours","last_7_days","last_30_days","last_90_days","this_month","custom"]),qg=A({preset:O(Ug),after:O(y()),before:O(y())}),Am=A({...te.shape,display:O(F(["dropdown"])),...W(qg,"DATE_RANGE").shape});var Ni=A({...te.shape,...W(X([H(y(),G())]),"JSON").shape});var jg=X([tt,rt,Ni,$i,$t]),gC=H(y(),jg),km=A({refreshers:B(y()),...te.shape,...W(G(),"DYNAMIC").shape});var zc=A({...te.shape,...W(Ng(),"MARKDOWN").shape});var Di=(o=>(o.ARCHIVE="ARCHIVE",o.REGISTRY="REGISTRY",o))(Di||{}),ho=(o=>(o.CUSTOM="CUSTOM",o.OFFICIAL="OFFICIAL",o))(ho||{}),yo=(x=>(x.ARTIFICIAL_INTELLIGENCE="ARTIFICIAL_INTELLIGENCE",x.COMMUNICATION="COMMUNICATION",x.COMMERCE="COMMERCE",x.CORE="CORE",x.UNIVERSAL_AI="UNIVERSAL_AI",x.FLOW_CONTROL="FLOW_CONTROL",x.BUSINESS_INTELLIGENCE="BUSINESS_INTELLIGENCE",x.ACCOUNTING="ACCOUNTING",x.PRODUCTIVITY="PRODUCTIVITY",x.CONTENT_AND_FILES="CONTENT_AND_FILES",x.DEVELOPER_TOOLS="DEVELOPER_TOOLS",x.CUSTOMER_SUPPORT="CUSTOMER_SUPPORT",x.FORMS_AND_SURVEYS="FORMS_AND_SURVEYS",x.HUMAN_RESOURCES="HUMAN_RESOURCES",x.PAYMENT_PROCESSING="PAYMENT_PROCESSING",x.MARKETING="MARKETING",x.SALES_AND_CRM="SALES_AND_CRM",x))(yo||{});var zi=(o=>(o.AUTHORIZATION_CODE="authorization_code",o.CLIENT_CREDENTIALS="client_credentials",o))(zi||{}),wm="both_client_credentials_and_authorization_code";var Ee=(r=>(r.POLLING="POLLING",r.WEBHOOK="WEBHOOK",r.APP_WEBHOOK="APP_WEBHOOK",r.MANUAL="MANUAL",r))(Ee||{}),Mi=(i=>(i.NONE="NONE",i.HEADER_PRESENT="HEADER_PRESENT",i.QUERY_PRESENT="QUERY_PRESENT",i.BODY_PARAM_PRESENT="BODY_PARAM_PRESENT",i.HEAD_REQUEST="HEAD_REQUEST",i))(Mi||{}),vC=A({strategy:F(Mi),paramName:O(y())}),Li=(o=>(o.SIMULATION="SIMULATION",o.TEST_FUNCTION="TEST_FUNCTION",o))(Li||{});var Mc=(o=>(o.WEBSOCKET="WEBSOCKET",o.NONE="NONE",o))(Mc||{}),Fg=A({status:O(Ce()),body:O(G()),headers:O(H(y(),y()))}),Bg=A({type:j("DELAY"),resumeDateTime:y(),requestIdToReply:O(y()),handlerId:O(y()),streamStepProgress:O(F(Mc))}),Zg=A({type:j("WEBHOOK"),requestId:y(),requestIdToReply:O(y()),response:Fg,handlerId:O(y()),streamStepProgress:O(F(Mc))}),_C=X([Bg,Zg]);var bC=A({body:G(),rawBody:O(G()),headers:H(y(),y()),queryParams:H(y(),y())});function ot(e){return e==null}s(ot,"isNil");function K(e){return e==null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:!1}s(K,"isEmpty");function Lc(e,t){if(e==null)throw new Error(`${t} is null or undefined`)}s(Lc,"assertNotNullOrUndefined");function Om(e){try{return{data:e(),error:null}}catch(t){return{data:null,error:t}}}s(Om,"tryCatchSync");var Rm=pt(require("crypto"),1);var PC=128,Qt,go,xC=s(e=>{if(e<0)throw new RangeError("Wrong ID size");try{!Qt||Qt.length<e?(Qt=Buffer.allocUnsafe(e*PC),Rm.default.randomFillSync(Qt),go=0):go+e>Qt.length&&(Rm.default.randomFillSync(Qt),go=0)}catch(t){throw Qt=void 0,t}go+=e},"fillPool"),SC=s(e=>(xC(e|=0),Qt.subarray(go-e,go)),"random"),TC=s((e,t,o)=>{let n=(2<<31-Math.clz32(e.length-1|1))-1,r=Math.ceil(1.6*n*t/e.length);return(i=t)=>{if(i<=0)return"";let a="";for(;;){let c=o(r),p=r;for(;p--;)if(a+=e[c[p]&n]||"",a.length===i)return a}}},"customRandom"),Gg=s((e,t=21)=>TC(e,t,SC),"customAlphabet");var EC="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",Hg=21,P4=y().check(ze(new RegExp(`^[0-9a-zA-Z]{${Hg}}$`))),IC=Gg(EC,Hg);var er=Yt(Xt(e=>e instanceof Date?e.toISOString():e),y()),at={id:y(),created:er,updated:er},fe=s(e=>O(ki(e)),"Nullable");function Cm(e){return O(ki(F(e)))}s(Cm,"NullableEnum");var T4=Yt(Xt(e=>e==="true"||e===!0?!0:e==="false"||e===!1?!1:void 0),O(re())),Uc=s(e=>Yt(Xt(t=>Array.isArray(t)?t:t!==void 0?[t]:void 0),O(B(e))),"OptionalArrayFromQuery");var A4=H(y(),G());var vo=(x=>(x.OPENAI="openai",x.OPENROUTER="openrouter",x.ANTHROPIC="anthropic",x.AZURE="azure",x.GOOGLE="google",x.ACTIVEPIECES="activepieces",x.CLOUDFLARE_GATEWAY="cloudflare-gateway",x.CUSTOM="custom",x.BEDROCK="bedrock",x.VERTEX="vertex",x.MISTRAL="mistral",x.XAI="xai",x.DEEPSEEK="deepseek",x.ZAI="zai",x.QWEN="qwen",x.MINIMAX="minimax",x.MOONSHOT="moonshot",x))(vo||{});var q4=y().check(ze(/^#[0-9A-Fa-f]{6}$/));var F4=A({filename:y(),data:G(),type:j("file"),mimetype:O(y())});var AC=pt(Kg());var K4=A({...at,name:y(),permissions:B(y()),platformId:fe(y()),type:y(),userCount:O(Ce())});var bu={};Ye(bu,{$brand:()=>pn,$input:()=>rc,$output:()=>tc,NEVER:()=>La,TimePrecision:()=>nc,ZodAny:()=>rf,ZodArray:()=>sf,ZodBase64:()=>su,ZodBase64URL:()=>cu,ZodBigInt:()=>Eo,ZodBigIntFormat:()=>lu,ZodBoolean:()=>To,ZodCIDRv4:()=>iu,ZodCIDRv6:()=>au,ZodCUID:()=>Yc,ZodCUID2:()=>Qc,ZodCatch:()=>wf,ZodCodec:()=>_u,ZodCustom:()=>Ji,ZodCustomStringFormat:()=>xo,ZodDate:()=>Vi,ZodDefault:()=>Sf,ZodDiscriminatedUnion:()=>uf,ZodE164:()=>uu,ZodEmail:()=>Kc,ZodEmoji:()=>Jc,ZodEnum:()=>bo,ZodError:()=>kC,ZodExactOptional:()=>bf,ZodFile:()=>vf,ZodFirstPartyTypeKind:()=>jf,ZodFunction:()=>Lf,ZodGUID:()=>qi,ZodIPv4:()=>ou,ZodIPv6:()=>nu,ZodISODate:()=>Bc,ZodISODateTime:()=>Fc,ZodISODuration:()=>Vc,ZodISOTime:()=>Zc,ZodIntersection:()=>pf,ZodIssueCode:()=>OC,ZodJWT:()=>pu,ZodKSUID:()=>ru,ZodLazy:()=>Df,ZodLiteral:()=>gf,ZodMAC:()=>Km,ZodMap:()=>hf,ZodNaN:()=>Rf,ZodNanoID:()=>Xc,ZodNever:()=>nf,ZodNonOptional:()=>gu,ZodNull:()=>ef,ZodNullable:()=>xf,ZodNumber:()=>So,ZodNumberFormat:()=>Dr,ZodObject:()=>Hi,ZodOptional:()=>yu,ZodPipe:()=>vu,ZodPrefault:()=>Ef,ZodPromise:()=>Mf,ZodReadonly:()=>Cf,ZodRealError:()=>We,ZodRecord:()=>Ki,ZodSet:()=>yf,ZodString:()=>Po,ZodStringFormat:()=>se,ZodSuccess:()=>kf,ZodSymbol:()=>Ym,ZodTemplateLiteral:()=>Nf,ZodTransform:()=>_f,ZodTuple:()=>df,ZodType:()=>Y,ZodULID:()=>eu,ZodURL:()=>Zi,ZodUUID:()=>_t,ZodUndefined:()=>Qm,ZodUnion:()=>Wi,ZodUnknown:()=>of,ZodVoid:()=>af,ZodXID:()=>tu,ZodXor:()=>cf,_ZodString:()=>Wc,_default:()=>Tf,_function:()=>r_,any:()=>Nv,array:()=>Gi,base64:()=>gv,base64url:()=>vv,bigint:()=>wv,boolean:()=>Xm,catch:()=>Of,check:()=>o_,cidrv4:()=>hv,cidrv6:()=>yv,clone:()=>Oe,codec:()=>Qv,coerce:()=>Ff,config:()=>me,core:()=>et,cuid:()=>sv,cuid2:()=>cv,custom:()=>n_,date:()=>zv,decode:()=>Fm,decodeAsync:()=>Zm,describe:()=>i_,discriminatedUnion:()=>Fv,e164:()=>_v,email:()=>Xg,emoji:()=>iv,encode:()=>jm,encodeAsync:()=>Bm,endsWith:()=>Ar,enum:()=>fu,exactOptional:()=>Pf,file:()=>Kv,flattenError:()=>Jr,float32:()=>Ev,float64:()=>Iv,formatError:()=>Xr,fromJSONSchema:()=>d_,function:()=>r_,getErrorMap:()=>CC,globalRegistry:()=>Re,gt:()=>mt,gte:()=>Ae,guid:()=>Yg,hash:()=>Tv,hex:()=>Sv,hostname:()=>xv,httpUrl:()=>nv,includes:()=>Er,instanceof:()=>s_,int:()=>Hc,int32:()=>Av,int64:()=>Ov,intersection:()=>lf,ipv4:()=>dv,ipv6:()=>fv,iso:()=>_o,json:()=>u_,jwt:()=>bv,keyof:()=>Mv,ksuid:()=>lv,lazy:()=>zf,length:()=>Gt,literal:()=>Wv,locales:()=>po,looseObject:()=>qv,looseRecord:()=>Zv,lowercase:()=>Sr,lt:()=>dt,lte:()=>je,mac:()=>mv,map:()=>Vv,maxLength:()=>Vt,maxSize:()=>Rt,meta:()=>a_,mime:()=>kr,minLength:()=>Se,minSize:()=>ft,multipleOf:()=>Ot,nan:()=>Yv,nanoid:()=>av,nativeEnum:()=>Hv,negative:()=>Pi,never:()=>du,nonnegative:()=>Si,nonoptional:()=>Af,nonpositive:()=>xi,normalize:()=>wr,null:()=>tf,nullable:()=>Fi,nullish:()=>Jv,number:()=>Jm,object:()=>Lv,optional:()=>ji,overwrite:()=>it,parse:()=>Mm,parseAsync:()=>Lm,partialRecord:()=>Bv,pipe:()=>Bi,positive:()=>bi,prefault:()=>If,preprocess:()=>p_,prettifyError:()=>Ba,promise:()=>t_,property:()=>Ti,readonly:()=>$f,record:()=>ff,refine:()=>Uf,regex:()=>ze,regexes:()=>He,registry:()=>jn,safeDecode:()=>Gm,safeDecodeAsync:()=>Wm,safeEncode:()=>Vm,safeEncodeAsync:()=>Hm,safeParse:()=>Um,safeParseAsync:()=>qm,set:()=>Gv,setErrorMap:()=>RC,size:()=>Zt,slugify:()=>mo,startsWith:()=>Ir,strictObject:()=>Uv,string:()=>Gc,stringFormat:()=>Pv,stringbool:()=>c_,success:()=>Xv,superRefine:()=>qf,symbol:()=>Cv,templateLiteral:()=>e_,toJSONSchema:()=>Ii,toLowerCase:()=>Rr,toUpperCase:()=>Cr,transform:()=>hu,treeifyError:()=>Fa,trim:()=>Or,tuple:()=>mf,uint32:()=>kv,uint64:()=>Rv,ulid:()=>uv,undefined:()=>$v,union:()=>mu,unknown:()=>Nr,uppercase:()=>Tr,url:()=>ov,util:()=>D,uuid:()=>Qg,uuidv4:()=>ev,uuidv6:()=>tv,uuidv7:()=>rv,void:()=>Dv,xid:()=>pv,xor:()=>jv});var Ui={};Ye(Ui,{ZodAny:()=>rf,ZodArray:()=>sf,ZodBase64:()=>su,ZodBase64URL:()=>cu,ZodBigInt:()=>Eo,ZodBigIntFormat:()=>lu,ZodBoolean:()=>To,ZodCIDRv4:()=>iu,ZodCIDRv6:()=>au,ZodCUID:()=>Yc,ZodCUID2:()=>Qc,ZodCatch:()=>wf,ZodCodec:()=>_u,ZodCustom:()=>Ji,ZodCustomStringFormat:()=>xo,ZodDate:()=>Vi,ZodDefault:()=>Sf,ZodDiscriminatedUnion:()=>uf,ZodE164:()=>uu,ZodEmail:()=>Kc,ZodEmoji:()=>Jc,ZodEnum:()=>bo,ZodExactOptional:()=>bf,ZodFile:()=>vf,ZodFunction:()=>Lf,ZodGUID:()=>qi,ZodIPv4:()=>ou,ZodIPv6:()=>nu,ZodIntersection:()=>pf,ZodJWT:()=>pu,ZodKSUID:()=>ru,ZodLazy:()=>Df,ZodLiteral:()=>gf,ZodMAC:()=>Km,ZodMap:()=>hf,ZodNaN:()=>Rf,ZodNanoID:()=>Xc,ZodNever:()=>nf,ZodNonOptional:()=>gu,ZodNull:()=>ef,ZodNullable:()=>xf,ZodNumber:()=>So,ZodNumberFormat:()=>Dr,ZodObject:()=>Hi,ZodOptional:()=>yu,ZodPipe:()=>vu,ZodPrefault:()=>Ef,ZodPromise:()=>Mf,ZodReadonly:()=>Cf,ZodRecord:()=>Ki,ZodSet:()=>yf,ZodString:()=>Po,ZodStringFormat:()=>se,ZodSuccess:()=>kf,ZodSymbol:()=>Ym,ZodTemplateLiteral:()=>Nf,ZodTransform:()=>_f,ZodTuple:()=>df,ZodType:()=>Y,ZodULID:()=>eu,ZodURL:()=>Zi,ZodUUID:()=>_t,ZodUndefined:()=>Qm,ZodUnion:()=>Wi,ZodUnknown:()=>of,ZodVoid:()=>af,ZodXID:()=>tu,ZodXor:()=>cf,_ZodString:()=>Wc,_default:()=>Tf,_function:()=>r_,any:()=>Nv,array:()=>Gi,base64:()=>gv,base64url:()=>vv,bigint:()=>wv,boolean:()=>Xm,catch:()=>Of,check:()=>o_,cidrv4:()=>hv,cidrv6:()=>yv,codec:()=>Qv,cuid:()=>sv,cuid2:()=>cv,custom:()=>n_,date:()=>zv,describe:()=>i_,discriminatedUnion:()=>Fv,e164:()=>_v,email:()=>Xg,emoji:()=>iv,enum:()=>fu,exactOptional:()=>Pf,file:()=>Kv,float32:()=>Ev,float64:()=>Iv,function:()=>r_,guid:()=>Yg,hash:()=>Tv,hex:()=>Sv,hostname:()=>xv,httpUrl:()=>nv,instanceof:()=>s_,int:()=>Hc,int32:()=>Av,int64:()=>Ov,intersection:()=>lf,ipv4:()=>dv,ipv6:()=>fv,json:()=>u_,jwt:()=>bv,keyof:()=>Mv,ksuid:()=>lv,lazy:()=>zf,literal:()=>Wv,looseObject:()=>qv,looseRecord:()=>Zv,mac:()=>mv,map:()=>Vv,meta:()=>a_,nan:()=>Yv,nanoid:()=>av,nativeEnum:()=>Hv,never:()=>du,nonoptional:()=>Af,null:()=>tf,nullable:()=>Fi,nullish:()=>Jv,number:()=>Jm,object:()=>Lv,optional:()=>ji,partialRecord:()=>Bv,pipe:()=>Bi,prefault:()=>If,preprocess:()=>p_,promise:()=>t_,readonly:()=>$f,record:()=>ff,refine:()=>Uf,set:()=>Gv,strictObject:()=>Uv,string:()=>Gc,stringFormat:()=>Pv,stringbool:()=>c_,success:()=>Xv,superRefine:()=>qf,symbol:()=>Cv,templateLiteral:()=>e_,transform:()=>hu,tuple:()=>mf,uint32:()=>kv,uint64:()=>Rv,ulid:()=>uv,undefined:()=>$v,union:()=>mu,unknown:()=>Nr,url:()=>ov,uuid:()=>Qg,uuidv4:()=>ev,uuidv6:()=>tv,uuidv7:()=>rv,void:()=>Dv,xid:()=>pv,xor:()=>jv});var jc={};Ye(jc,{endsWith:()=>Ar,gt:()=>mt,gte:()=>Ae,includes:()=>Er,length:()=>Gt,lowercase:()=>Sr,lt:()=>dt,lte:()=>je,maxLength:()=>Vt,maxSize:()=>Rt,mime:()=>kr,minLength:()=>Se,minSize:()=>ft,multipleOf:()=>Ot,negative:()=>Pi,nonnegative:()=>Si,nonpositive:()=>xi,normalize:()=>wr,overwrite:()=>it,positive:()=>bi,property:()=>Ti,regex:()=>ze,size:()=>Zt,slugify:()=>mo,startsWith:()=>Ir,toLowerCase:()=>Rr,toUpperCase:()=>Cr,trim:()=>Or,uppercase:()=>Tr});var _o={};Ye(_o,{ZodISODate:()=>Bc,ZodISODateTime:()=>Fc,ZodISODuration:()=>Vc,ZodISOTime:()=>Zc,date:()=>Nm,datetime:()=>$m,duration:()=>zm,time:()=>Dm});var Fc=S("ZodISODateTime",(e,t)=>{gs.init(e,t),se.init(e,t)});function $m(e){return ic(Fc,e)}s($m,"datetime");var Bc=S("ZodISODate",(e,t)=>{vs.init(e,t),se.init(e,t)});function Nm(e){return ac(Bc,e)}s(Nm,"date");var Zc=S("ZodISOTime",(e,t)=>{_s.init(e,t),se.init(e,t)});function Dm(e){return sc(Zc,e)}s(Dm,"time");var Vc=S("ZodISODuration",(e,t)=>{bs.init(e,t),se.init(e,t)});function zm(e){return cc(Vc,e)}s(zm,"duration");var Jg=s((e,t)=>{gn.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:s(o=>Xr(e,o),"value")},flatten:{value:s(o=>Jr(e,o),"value")},addIssue:{value:s(o=>{e.issues.push(o),e.message=JSON.stringify(e.issues,Hr,2)},"value")},addIssues:{value:s(o=>{e.issues.push(...o),e.message=JSON.stringify(e.issues,Hr,2)},"value")},isEmpty:{get(){return e.issues.length===0}}})},"initializer"),kC=S("ZodError",Jg),We=S("ZodError",Jg,{Parent:Error});var Mm=Yr(We),Lm=Qr(We),Um=eo(We),qm=ro(We),jm=Za(We),Fm=Va(We),Bm=Ga(We),Zm=Ha(We),Vm=Wa(We),Gm=Ka(We),Hm=Ja(We),Wm=Xa(We);var Y=S("ZodType",(e,t)=>(Z.init(e,t),Object.assign(e["~standard"],{jsonSchema:{input:fo(e,"input"),output:fo(e,"output")}}),e.toJSONSchema=Ud(e,{}),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...o)=>e.clone(D.mergeDefs(t,{checks:[...t.checks??[],...o.map(n=>typeof n=="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]}),{parent:!0}),e.with=e.check,e.clone=(o,n)=>Oe(e,o,n),e.brand=()=>e,e.register=((o,n)=>(o.add(e,n),e)),e.parse=(o,n)=>Mm(e,o,n,{callee:e.parse}),e.safeParse=(o,n)=>Um(e,o,n),e.parseAsync=async(o,n)=>Lm(e,o,n,{callee:e.parseAsync}),e.safeParseAsync=async(o,n)=>qm(e,o,n),e.spa=e.safeParseAsync,e.encode=(o,n)=>jm(e,o,n),e.decode=(o,n)=>Fm(e,o,n),e.encodeAsync=async(o,n)=>Bm(e,o,n),e.decodeAsync=async(o,n)=>Zm(e,o,n),e.safeEncode=(o,n)=>Vm(e,o,n),e.safeDecode=(o,n)=>Gm(e,o,n),e.safeEncodeAsync=async(o,n)=>Hm(e,o,n),e.safeDecodeAsync=async(o,n)=>Wm(e,o,n),e.refine=(o,n)=>e.check(Uf(o,n)),e.superRefine=o=>e.check(qf(o)),e.overwrite=o=>e.check(it(o)),e.optional=()=>ji(e),e.exactOptional=()=>Pf(e),e.nullable=()=>Fi(e),e.nullish=()=>ji(Fi(e)),e.nonoptional=o=>Af(e,o),e.array=()=>Gi(e),e.or=o=>mu([e,o]),e.and=o=>lf(e,o),e.transform=o=>Bi(e,hu(o)),e.default=o=>Tf(e,o),e.prefault=o=>If(e,o),e.catch=o=>Of(e,o),e.pipe=o=>Bi(e,o),e.readonly=()=>$f(e),e.describe=o=>{let n=e.clone();return Re.add(n,{description:o}),n},Object.defineProperty(e,"description",{get(){return Re.get(e)?.description},configurable:!0}),e.meta=(...o)=>{if(o.length===0)return Re.get(e);let n=e.clone();return Re.add(n,o[0]),n},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e.apply=o=>o(e),e)),Wc=S("_ZodString",(e,t)=>{wt.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(n,r,i)=>qd(e,n,r,i);let o=e._zod.bag;e.format=o.format??null,e.minLength=o.minimum??null,e.maxLength=o.maximum??null,e.regex=(...n)=>e.check(ze(...n)),e.includes=(...n)=>e.check(Er(...n)),e.startsWith=(...n)=>e.check(Ir(...n)),e.endsWith=(...n)=>e.check(Ar(...n)),e.min=(...n)=>e.check(Se(...n)),e.max=(...n)=>e.check(Vt(...n)),e.length=(...n)=>e.check(Gt(...n)),e.nonempty=(...n)=>e.check(Se(1,...n)),e.lowercase=n=>e.check(Sr(n)),e.uppercase=n=>e.check(Tr(n)),e.trim=()=>e.check(Or()),e.normalize=(...n)=>e.check(wr(...n)),e.toLowerCase=()=>e.check(Rr()),e.toUpperCase=()=>e.check(Cr()),e.slugify=()=>e.check(mo())}),Po=S("ZodString",(e,t)=>{wt.init(e,t),Wc.init(e,t),e.email=o=>e.check(Zn(Kc,o)),e.url=o=>e.check(xr(Zi,o)),e.jwt=o=>e.check(ui(pu,o)),e.emoji=o=>e.check(Kn(Jc,o)),e.guid=o=>e.check(lo(qi,o)),e.uuid=o=>e.check(Vn(_t,o)),e.uuidv4=o=>e.check(Gn(_t,o)),e.uuidv6=o=>e.check(Hn(_t,o)),e.uuidv7=o=>e.check(Wn(_t,o)),e.nanoid=o=>e.check(Jn(Xc,o)),e.guid=o=>e.check(lo(qi,o)),e.cuid=o=>e.check(Xn(Yc,o)),e.cuid2=o=>e.check(Yn(Qc,o)),e.ulid=o=>e.check(Qn(eu,o)),e.base64=o=>e.check(ai(su,o)),e.base64url=o=>e.check(si(cu,o)),e.xid=o=>e.check(ei(tu,o)),e.ksuid=o=>e.check(ti(ru,o)),e.ipv4=o=>e.check(ri(ou,o)),e.ipv6=o=>e.check(oi(nu,o)),e.cidrv4=o=>e.check(ni(iu,o)),e.cidrv6=o=>e.check(ii(au,o)),e.e164=o=>e.check(ci(uu,o)),e.datetime=o=>e.check($m(o)),e.date=o=>e.check(Nm(o)),e.time=o=>e.check(Dm(o)),e.duration=o=>e.check(zm(o))});function Gc(e){return Fn(Po,e)}s(Gc,"string");var se=S("ZodStringFormat",(e,t)=>{ne.init(e,t),Wc.init(e,t)}),Kc=S("ZodEmail",(e,t)=>{us.init(e,t),se.init(e,t)});function Xg(e){return Zn(Kc,e)}s(Xg,"email");var qi=S("ZodGUID",(e,t)=>{ss.init(e,t),se.init(e,t)});function Yg(e){return lo(qi,e)}s(Yg,"guid");var _t=S("ZodUUID",(e,t)=>{cs.init(e,t),se.init(e,t)});function Qg(e){return Vn(_t,e)}s(Qg,"uuid");function ev(e){return Gn(_t,e)}s(ev,"uuidv4");function tv(e){return Hn(_t,e)}s(tv,"uuidv6");function rv(e){return Wn(_t,e)}s(rv,"uuidv7");var Zi=S("ZodURL",(e,t)=>{Pn.init(e,t),se.init(e,t)});function ov(e){return xr(Zi,e)}s(ov,"url");function nv(e){return xr(Zi,{protocol:/^https?$/,hostname:He.domain,...D.normalizeParams(e)})}s(nv,"httpUrl");var Jc=S("ZodEmoji",(e,t)=>{ps.init(e,t),se.init(e,t)});function iv(e){return Kn(Jc,e)}s(iv,"emoji");var Xc=S("ZodNanoID",(e,t)=>{ls.init(e,t),se.init(e,t)});function av(e){return Jn(Xc,e)}s(av,"nanoid");var Yc=S("ZodCUID",(e,t)=>{ds.init(e,t),se.init(e,t)});function sv(e){return Xn(Yc,e)}s(sv,"cuid");var Qc=S("ZodCUID2",(e,t)=>{ms.init(e,t),se.init(e,t)});function cv(e){return Yn(Qc,e)}s(cv,"cuid2");var eu=S("ZodULID",(e,t)=>{fs.init(e,t),se.init(e,t)});function uv(e){return Qn(eu,e)}s(uv,"ulid");var tu=S("ZodXID",(e,t)=>{hs.init(e,t),se.init(e,t)});function pv(e){return ei(tu,e)}s(pv,"xid");var ru=S("ZodKSUID",(e,t)=>{ys.init(e,t),se.init(e,t)});function lv(e){return ti(ru,e)}s(lv,"ksuid");var ou=S("ZodIPv4",(e,t)=>{Ps.init(e,t),se.init(e,t)});function dv(e){return ri(ou,e)}s(dv,"ipv4");var Km=S("ZodMAC",(e,t)=>{Ss.init(e,t),se.init(e,t)});function mv(e){return oc(Km,e)}s(mv,"mac");var nu=S("ZodIPv6",(e,t)=>{xs.init(e,t),se.init(e,t)});function fv(e){return oi(nu,e)}s(fv,"ipv6");var iu=S("ZodCIDRv4",(e,t)=>{Ts.init(e,t),se.init(e,t)});function hv(e){return ni(iu,e)}s(hv,"cidrv4");var au=S("ZodCIDRv6",(e,t)=>{Es.init(e,t),se.init(e,t)});function yv(e){return ii(au,e)}s(yv,"cidrv6");var su=S("ZodBase64",(e,t)=>{Is.init(e,t),se.init(e,t)});function gv(e){return ai(su,e)}s(gv,"base64");var cu=S("ZodBase64URL",(e,t)=>{As.init(e,t),se.init(e,t)});function vv(e){return si(cu,e)}s(vv,"base64url");var uu=S("ZodE164",(e,t)=>{ks.init(e,t),se.init(e,t)});function _v(e){return ci(uu,e)}s(_v,"e164");var pu=S("ZodJWT",(e,t)=>{ws.init(e,t),se.init(e,t)});function bv(e){return ui(pu,e)}s(bv,"jwt");var xo=S("ZodCustomStringFormat",(e,t)=>{Os.init(e,t),se.init(e,t)});function Pv(e,t,o={}){return $r(xo,e,t,o)}s(Pv,"stringFormat");function xv(e){return $r(xo,"hostname",He.hostname,e)}s(xv,"hostname");function Sv(e){return $r(xo,"hex",He.hex,e)}s(Sv,"hex");function Tv(e,t){let o=t?.enc??"hex",n=`${e}_${o}`,r=He[n];if(!r)throw new Error(`Unrecognized hash format: ${n}`);return $r(xo,n,r,t)}s(Tv,"hash");var So=S("ZodNumber",(e,t)=>{io.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(n,r,i)=>jd(e,n,r,i),e.gt=(n,r)=>e.check(mt(n,r)),e.gte=(n,r)=>e.check(Ae(n,r)),e.min=(n,r)=>e.check(Ae(n,r)),e.lt=(n,r)=>e.check(dt(n,r)),e.lte=(n,r)=>e.check(je(n,r)),e.max=(n,r)=>e.check(je(n,r)),e.int=n=>e.check(Hc(n)),e.safe=n=>e.check(Hc(n)),e.positive=n=>e.check(mt(0,n)),e.nonnegative=n=>e.check(Ae(0,n)),e.negative=n=>e.check(dt(0,n)),e.nonpositive=n=>e.check(je(0,n)),e.multipleOf=(n,r)=>e.check(Ot(n,r)),e.step=(n,r)=>e.check(Ot(n,r)),e.finite=()=>e;let o=e._zod.bag;e.minValue=Math.max(o.minimum??Number.NEGATIVE_INFINITY,o.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(o.maximum??Number.POSITIVE_INFINITY,o.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(o.format??"").includes("int")||Number.isSafeInteger(o.multipleOf??.5),e.isFinite=!0,e.format=o.format??null});function Jm(e){return pi(So,e)}s(Jm,"number");var Dr=S("ZodNumberFormat",(e,t)=>{xn.init(e,t),So.init(e,t)});function Hc(e){return di(Dr,e)}s(Hc,"int");function Ev(e){return uc(Dr,e)}s(Ev,"float32");function Iv(e){return pc(Dr,e)}s(Iv,"float64");function Av(e){return lc(Dr,e)}s(Av,"int32");function kv(e){return dc(Dr,e)}s(kv,"uint32");var To=S("ZodBoolean",(e,t)=>{br.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Fd(e,o,n,r)});function Xm(e){return mi(To,e)}s(Xm,"boolean");var Eo=S("ZodBigInt",(e,t)=>{ao.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(n,r,i)=>Bd(e,n,r,i),e.gte=(n,r)=>e.check(Ae(n,r)),e.min=(n,r)=>e.check(Ae(n,r)),e.gt=(n,r)=>e.check(mt(n,r)),e.gte=(n,r)=>e.check(Ae(n,r)),e.min=(n,r)=>e.check(Ae(n,r)),e.lt=(n,r)=>e.check(dt(n,r)),e.lte=(n,r)=>e.check(je(n,r)),e.max=(n,r)=>e.check(je(n,r)),e.positive=n=>e.check(mt(BigInt(0),n)),e.negative=n=>e.check(dt(BigInt(0),n)),e.nonpositive=n=>e.check(je(BigInt(0),n)),e.nonnegative=n=>e.check(Ae(BigInt(0),n)),e.multipleOf=(n,r)=>e.check(Ot(n,r));let o=e._zod.bag;e.minValue=o.minimum??null,e.maxValue=o.maximum??null,e.format=o.format??null});function wv(e){return mc(Eo,e)}s(wv,"bigint");var lu=S("ZodBigIntFormat",(e,t)=>{Rs.init(e,t),Eo.init(e,t)});function Ov(e){return fc(lu,e)}s(Ov,"int64");function Rv(e){return hc(lu,e)}s(Rv,"uint64");var Ym=S("ZodSymbol",(e,t)=>{Cs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Zd(e,o,n,r)});function Cv(e){return yc(Ym,e)}s(Cv,"symbol");var Qm=S("ZodUndefined",(e,t)=>{$s.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Gd(e,o,n,r)});function $v(e){return gc(Qm,e)}s($v,"_undefined");var ef=S("ZodNull",(e,t)=>{Ns.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Vd(e,o,n,r)});function tf(e){return vc(ef,e)}s(tf,"_null");var rf=S("ZodAny",(e,t)=>{Sn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Kd(e,o,n,r)});function Nv(){return yi(rf)}s(Nv,"any");var of=S("ZodUnknown",(e,t)=>{Tn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Jd(e,o,n,r)});function Nr(){return gi(of)}s(Nr,"unknown");var nf=S("ZodNever",(e,t)=>{Ds.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Wd(e,o,n,r)});function du(e){return _c(nf,e)}s(du,"never");var af=S("ZodVoid",(e,t)=>{En.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Hd(e,o,n,r)});function Dv(e){return vi(af,e)}s(Dv,"_void");var Vi=S("ZodDate",(e,t)=>{In.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(n,r,i)=>Xd(e,n,r,i),e.min=(n,r)=>e.check(Ae(n,r)),e.max=(n,r)=>e.check(je(n,r));let o=e._zod.bag;e.minDate=o.minimum?new Date(o.minimum):null,e.maxDate=o.maximum?new Date(o.maximum):null});function zv(e){return bc(Vi,e)}s(zv,"date");var sf=S("ZodArray",(e,t)=>{An.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>um(e,o,n,r),e.element=t.element,e.min=(o,n)=>e.check(Se(o,n)),e.nonempty=o=>e.check(Se(1,o)),e.max=(o,n)=>e.check(Vt(o,n)),e.length=(o,n)=>e.check(Gt(o,n)),e.unwrap=()=>e.element});function Gi(e,t){return Ld(sf,e,t)}s(Gi,"array");function Mv(e){let t=e._zod.def.shape;return fu(Object.keys(t))}s(Mv,"keyof");var Hi=S("ZodObject",(e,t)=>{Vl.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>pm(e,o,n,r),D.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>fu(Object.keys(e._zod.def.shape)),e.catchall=o=>e.clone({...e._zod.def,catchall:o}),e.passthrough=()=>e.clone({...e._zod.def,catchall:Nr()}),e.loose=()=>e.clone({...e._zod.def,catchall:Nr()}),e.strict=()=>e.clone({...e._zod.def,catchall:du()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=o=>D.extend(e,o),e.safeExtend=o=>D.safeExtend(e,o),e.merge=o=>D.merge(e,o),e.pick=o=>D.pick(e,o),e.omit=o=>D.omit(e,o),e.partial=(...o)=>D.partial(yu,e,o[0]),e.required=(...o)=>D.required(gu,e,o[0])});function Lv(e,t){let o={type:"object",shape:e??{},...D.normalizeParams(t)};return new Hi(o)}s(Lv,"object");function Uv(e,t){return new Hi({type:"object",shape:e,catchall:du(),...D.normalizeParams(t)})}s(Uv,"strictObject");function qv(e,t){return new Hi({type:"object",shape:e,catchall:Nr(),...D.normalizeParams(t)})}s(qv,"looseObject");var Wi=S("ZodUnion",(e,t)=>{Pr.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>wc(e,o,n,r),e.options=t.options});function mu(e,t){return new Wi({type:"union",options:e,...D.normalizeParams(t)})}s(mu,"union");var cf=S("ZodXor",(e,t)=>{Wi.init(e,t),Ms.init(e,t),e._zod.processJSONSchema=(o,n,r)=>wc(e,o,n,r),e.options=t.options});function jv(e,t){return new cf({type:"union",options:e,inclusive:!1,...D.normalizeParams(t)})}s(jv,"xor");var uf=S("ZodDiscriminatedUnion",(e,t)=>{Wi.init(e,t),kn.init(e,t)});function Fv(e,t,o){return new uf({type:"union",options:t,discriminator:e,...D.normalizeParams(o)})}s(Fv,"discriminatedUnion");var pf=S("ZodIntersection",(e,t)=>{Ls.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>lm(e,o,n,r)});function lf(e,t){return new pf({type:"intersection",left:e,right:t})}s(lf,"intersection");var df=S("ZodTuple",(e,t)=>{wn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>dm(e,o,n,r),e.rest=o=>e.clone({...e._zod.def,rest:o})});function mf(e,t,o){let n=t instanceof Z,r=n?o:t,i=n?t:null;return new df({type:"tuple",items:e,rest:i,...D.normalizeParams(r)})}s(mf,"tuple");var Ki=S("ZodRecord",(e,t)=>{On.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>mm(e,o,n,r),e.keyType=t.keyType,e.valueType=t.valueType});function ff(e,t,o){return new Ki({type:"record",keyType:e,valueType:t,...D.normalizeParams(o)})}s(ff,"record");function Bv(e,t,o){let n=Oe(e);return n._zod.values=void 0,new Ki({type:"record",keyType:n,valueType:t,...D.normalizeParams(o)})}s(Bv,"partialRecord");function Zv(e,t,o){return new Ki({type:"record",keyType:e,valueType:t,mode:"loose",...D.normalizeParams(o)})}s(Zv,"looseRecord");var hf=S("ZodMap",(e,t)=>{Us.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>sm(e,o,n,r),e.keyType=t.keyType,e.valueType=t.valueType,e.min=(...o)=>e.check(ft(...o)),e.nonempty=o=>e.check(ft(1,o)),e.max=(...o)=>e.check(Rt(...o)),e.size=(...o)=>e.check(Zt(...o))});function Vv(e,t,o){return new hf({type:"map",keyType:e,valueType:t,...D.normalizeParams(o)})}s(Vv,"map");var yf=S("ZodSet",(e,t)=>{qs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>cm(e,o,n,r),e.min=(...o)=>e.check(ft(...o)),e.nonempty=o=>e.check(ft(1,o)),e.max=(...o)=>e.check(Rt(...o)),e.size=(...o)=>e.check(Zt(...o))});function Gv(e,t){return new yf({type:"set",valueType:e,...D.normalizeParams(t)})}s(Gv,"set");var bo=S("ZodEnum",(e,t)=>{Rn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(n,r,i)=>Yd(e,n,r,i),e.enum=t.entries,e.options=Object.values(t.entries);let o=new Set(Object.keys(t.entries));e.extract=(n,r)=>{let i={};for(let a of n)if(o.has(a))i[a]=t.entries[a];else throw new Error(`Key ${a} not found in enum`);return new bo({...t,checks:[],...D.normalizeParams(r),entries:i})},e.exclude=(n,r)=>{let i={...t.entries};for(let a of n)if(o.has(a))delete i[a];else throw new Error(`Key ${a} not found in enum`);return new bo({...t,checks:[],...D.normalizeParams(r),entries:i})}});function fu(e,t){let o=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new bo({type:"enum",entries:o,...D.normalizeParams(t)})}s(fu,"_enum");function Hv(e,t){return new bo({type:"enum",entries:e,...D.normalizeParams(t)})}s(Hv,"nativeEnum");var gf=S("ZodLiteral",(e,t)=>{Cn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Qd(e,o,n,r),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function Wv(e,t){return new gf({type:"literal",values:Array.isArray(e)?e:[e],...D.normalizeParams(t)})}s(Wv,"literal");var vf=S("ZodFile",(e,t)=>{js.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>rm(e,o,n,r),e.min=(o,n)=>e.check(ft(o,n)),e.max=(o,n)=>e.check(Rt(o,n)),e.mime=(o,n)=>e.check(kr(Array.isArray(o)?o:[o],n))});function Kv(e){return xc(vf,e)}s(Kv,"file");var _f=S("ZodTransform",(e,t)=>{$n.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>am(e,o,n,r),e._zod.parse=(o,n)=>{if(n.direction==="backward")throw new Ut(e.constructor.name);o.addIssue=i=>{if(typeof i=="string")o.issues.push(D.issue(i,o.value,t));else{let a=i;a.fatal&&(a.continue=!1),a.code??(a.code="custom"),a.input??(a.input=o.value),a.inst??(a.inst=e),o.issues.push(D.issue(a))}};let r=t.transform(o.value,o);return r instanceof Promise?r.then(i=>(o.value=i,o)):(o.value=r,o)}});function hu(e){return new _f({type:"transform",transform:e})}s(hu,"transform");var yu=S("ZodOptional",(e,t)=>{so.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Oc(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function ji(e){return new yu({type:"optional",innerType:e})}s(ji,"optional");var bf=S("ZodExactOptional",(e,t)=>{Fs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Oc(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function Pf(e){return new bf({type:"optional",innerType:e})}s(Pf,"exactOptional");var xf=S("ZodNullable",(e,t)=>{Nn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>fm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function Fi(e){return new xf({type:"nullable",innerType:e})}s(Fi,"nullable");function Jv(e){return ji(Fi(e))}s(Jv,"nullish");var Sf=S("ZodDefault",(e,t)=>{Bs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>ym(e,o,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Tf(e,t){return new Sf({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():D.shallowClone(t)}})}s(Tf,"_default");var Ef=S("ZodPrefault",(e,t)=>{Zs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>gm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function If(e,t){return new Ef({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():D.shallowClone(t)}})}s(If,"prefault");var gu=S("ZodNonOptional",(e,t)=>{Vs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>hm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function Af(e,t){return new gu({type:"nonoptional",innerType:e,...D.normalizeParams(t)})}s(Af,"nonoptional");var kf=S("ZodSuccess",(e,t)=>{Gs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>om(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function Xv(e){return new kf({type:"success",innerType:e})}s(Xv,"success");var wf=S("ZodCatch",(e,t)=>{Hs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>vm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function Of(e,t){return new wf({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}s(Of,"_catch");var Rf=S("ZodNaN",(e,t)=>{Ws.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>em(e,o,n,r)});function Yv(e){return Pc(Rf,e)}s(Yv,"nan");var vu=S("ZodPipe",(e,t)=>{Dn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>_m(e,o,n,r),e.in=t.in,e.out=t.out});function Bi(e,t){return new vu({type:"pipe",in:e,out:t})}s(Bi,"pipe");var _u=S("ZodCodec",(e,t)=>{vu.init(e,t),co.init(e,t)});function Qv(e,t,o){return new _u({type:"pipe",in:e,out:t,transform:o.decode,reverseTransform:o.encode})}s(Qv,"codec");var Cf=S("ZodReadonly",(e,t)=>{Ks.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>bm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function $f(e){return new Cf({type:"readonly",innerType:e})}s($f,"readonly");var Nf=S("ZodTemplateLiteral",(e,t)=>{Js.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>tm(e,o,n,r)});function e_(e,t){return new Nf({type:"template_literal",parts:e,...D.normalizeParams(t)})}s(e_,"templateLiteral");var Df=S("ZodLazy",(e,t)=>{Qs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>xm(e,o,n,r),e.unwrap=()=>e._zod.def.getter()});function zf(e){return new Df({type:"lazy",getter:e})}s(zf,"lazy");var Mf=S("ZodPromise",(e,t)=>{Ys.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>Pm(e,o,n,r),e.unwrap=()=>e._zod.def.innerType});function t_(e){return new Mf({type:"promise",innerType:e})}s(t_,"promise");var Lf=S("ZodFunction",(e,t)=>{Xs.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>im(e,o,n,r)});function r_(e){return new Lf({type:"function",input:Array.isArray(e?.input)?mf(e?.input):e?.input??Gi(Nr()),output:e?.output??Nr()})}s(r_,"_function");var Ji=S("ZodCustom",(e,t)=>{zn.init(e,t),Y.init(e,t),e._zod.processJSONSchema=(o,n,r)=>nm(e,o,n,r)});function o_(e){let t=new ae({check:"custom"});return t._zod.check=e,t}s(o_,"check");function n_(e,t){return Ei(Ji,e??(()=>!0),t)}s(n_,"custom");function Uf(e,t={}){return Sc(Ji,e,t)}s(Uf,"refine");function qf(e){return Tc(e)}s(qf,"superRefine");var i_=Ec,a_=Ic;function s_(e,t={}){let o=new Ji({type:"custom",check:"custom",fn:s(n=>n instanceof e,"fn"),abort:!0,...D.normalizeParams(t)});return o._zod.bag.Class=e,o._zod.check=n=>{n.value instanceof e||n.issues.push({code:"invalid_type",expected:e.name,input:n.value,inst:o,path:[...o._zod.def.path??[]]})},o}s(s_,"_instanceof");var c_=s((...e)=>Ac({Codec:_u,Boolean:To,String:Po},...e),"stringbool");function u_(e){let t=zf(()=>mu([Gc(e),Jm(),Xm(),tf(),Gi(t),ff(Gc(),t)]));return t}s(u_,"json");function p_(e,t){return Bi(hu(e),t)}s(p_,"preprocess");var OC={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function RC(e){me({customError:e})}s(RC,"setErrorMap");function CC(){return me().customError}s(CC,"getErrorMap");var jf;jf||(jf={});var L={...Ui,...jc,iso:_o},$C=new Set(["$schema","$ref","$defs","definitions","$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor","type","enum","const","anyOf","oneOf","allOf","not","properties","required","additionalProperties","patternProperties","propertyNames","minProperties","maxProperties","items","prefixItems","additionalItems","minItems","maxItems","uniqueItems","contains","minContains","maxContains","minLength","maxLength","pattern","format","minimum","maximum","exclusiveMinimum","exclusiveMaximum","multipleOf","description","default","contentEncoding","contentMediaType","contentSchema","unevaluatedItems","unevaluatedProperties","if","then","else","dependentSchemas","dependentRequired","nullable","readOnly"]);function NC(e,t){let o=e.$schema;return o==="https://json-schema.org/draft/2020-12/schema"?"draft-2020-12":o==="http://json-schema.org/draft-07/schema#"?"draft-7":o==="http://json-schema.org/draft-04/schema#"?"draft-4":t??"draft-2020-12"}s(NC,"detectVersion");function DC(e,t){if(!e.startsWith("#"))throw new Error("External $ref is not supported, only local refs (#/...) are allowed");let o=e.slice(1).split("/").filter(Boolean);if(o.length===0)return t.rootSchema;let n=t.version==="draft-2020-12"?"$defs":"definitions";if(o[0]===n){let r=o[1];if(!r||!t.defs[r])throw new Error(`Reference not found: ${e}`);return t.defs[r]}throw new Error(`Reference not found: ${e}`)}s(DC,"resolveRef");function l_(e,t){if(e.not!==void 0){if(typeof e.not=="object"&&Object.keys(e.not).length===0)return L.never();throw new Error("not is not supported in Zod (except { not: {} } for never)")}if(e.unevaluatedItems!==void 0)throw new Error("unevaluatedItems is not supported");if(e.unevaluatedProperties!==void 0)throw new Error("unevaluatedProperties is not supported");if(e.if!==void 0||e.then!==void 0||e.else!==void 0)throw new Error("Conditional schemas (if/then/else) are not supported");if(e.dependentSchemas!==void 0||e.dependentRequired!==void 0)throw new Error("dependentSchemas and dependentRequired are not supported");if(e.$ref){let r=e.$ref;if(t.refs.has(r))return t.refs.get(r);if(t.processing.has(r))return L.lazy(()=>{if(!t.refs.has(r))throw new Error(`Circular reference not resolved: ${r}`);return t.refs.get(r)});t.processing.add(r);let i=DC(r,t),a=Ue(i,t);return t.refs.set(r,a),t.processing.delete(r),a}if(e.enum!==void 0){let r=e.enum;if(t.version==="openapi-3.0"&&e.nullable===!0&&r.length===1&&r[0]===null)return L.null();if(r.length===0)return L.never();if(r.length===1)return L.literal(r[0]);if(r.every(a=>typeof a=="string"))return L.enum(r);let i=r.map(a=>L.literal(a));return i.length<2?i[0]:L.union([i[0],i[1],...i.slice(2)])}if(e.const!==void 0)return L.literal(e.const);let o=e.type;if(Array.isArray(o)){let r=o.map(i=>{let a={...e,type:i};return l_(a,t)});return r.length===0?L.never():r.length===1?r[0]:L.union(r)}if(!o)return L.any();let n;switch(o){case"string":{let r=L.string();if(e.format){let i=e.format;i==="email"?r=r.check(L.email()):i==="uri"||i==="uri-reference"?r=r.check(L.url()):i==="uuid"||i==="guid"?r=r.check(L.uuid()):i==="date-time"?r=r.check(L.iso.datetime()):i==="date"?r=r.check(L.iso.date()):i==="time"?r=r.check(L.iso.time()):i==="duration"?r=r.check(L.iso.duration()):i==="ipv4"?r=r.check(L.ipv4()):i==="ipv6"?r=r.check(L.ipv6()):i==="mac"?r=r.check(L.mac()):i==="cidr"?r=r.check(L.cidrv4()):i==="cidr-v6"?r=r.check(L.cidrv6()):i==="base64"?r=r.check(L.base64()):i==="base64url"?r=r.check(L.base64url()):i==="e164"?r=r.check(L.e164()):i==="jwt"?r=r.check(L.jwt()):i==="emoji"?r=r.check(L.emoji()):i==="nanoid"?r=r.check(L.nanoid()):i==="cuid"?r=r.check(L.cuid()):i==="cuid2"?r=r.check(L.cuid2()):i==="ulid"?r=r.check(L.ulid()):i==="xid"?r=r.check(L.xid()):i==="ksuid"&&(r=r.check(L.ksuid()))}typeof e.minLength=="number"&&(r=r.min(e.minLength)),typeof e.maxLength=="number"&&(r=r.max(e.maxLength)),e.pattern&&(r=r.regex(new RegExp(e.pattern))),n=r;break}case"number":case"integer":{let r=o==="integer"?L.number().int():L.number();typeof e.minimum=="number"&&(r=r.min(e.minimum)),typeof e.maximum=="number"&&(r=r.max(e.maximum)),typeof e.exclusiveMinimum=="number"?r=r.gt(e.exclusiveMinimum):e.exclusiveMinimum===!0&&typeof e.minimum=="number"&&(r=r.gt(e.minimum)),typeof e.exclusiveMaximum=="number"?r=r.lt(e.exclusiveMaximum):e.exclusiveMaximum===!0&&typeof e.maximum=="number"&&(r=r.lt(e.maximum)),typeof e.multipleOf=="number"&&(r=r.multipleOf(e.multipleOf)),n=r;break}case"boolean":{n=L.boolean();break}case"null":{n=L.null();break}case"object":{let r={},i=e.properties||{},a=new Set(e.required||[]);for(let[p,m]of Object.entries(i)){let l=Ue(m,t);r[p]=a.has(p)?l:l.optional()}if(e.propertyNames){let p=Ue(e.propertyNames,t),m=e.additionalProperties&&typeof e.additionalProperties=="object"?Ue(e.additionalProperties,t):L.any();if(Object.keys(r).length===0){n=L.record(p,m);break}let l=L.object(r).passthrough(),g=L.looseRecord(p,m);n=L.intersection(l,g);break}if(e.patternProperties){let p=e.patternProperties,m=Object.keys(p),l=[];for(let h of m){let f=Ue(p[h],t),v=L.string().regex(new RegExp(h));l.push(L.looseRecord(v,f))}let g=[];if(Object.keys(r).length>0&&g.push(L.object(r).passthrough()),g.push(...l),g.length===0)n=L.object({}).passthrough();else if(g.length===1)n=g[0];else{let h=L.intersection(g[0],g[1]);for(let f=2;f<g.length;f++)h=L.intersection(h,g[f]);n=h}break}let c=L.object(r);e.additionalProperties===!1?n=c.strict():typeof e.additionalProperties=="object"?n=c.catchall(Ue(e.additionalProperties,t)):n=c.passthrough();break}case"array":{let r=e.prefixItems,i=e.items;if(r&&Array.isArray(r)){let a=r.map(p=>Ue(p,t)),c=i&&typeof i=="object"&&!Array.isArray(i)?Ue(i,t):void 0;c?n=L.tuple(a).rest(c):n=L.tuple(a),typeof e.minItems=="number"&&(n=n.check(L.minLength(e.minItems))),typeof e.maxItems=="number"&&(n=n.check(L.maxLength(e.maxItems)))}else if(Array.isArray(i)){let a=i.map(p=>Ue(p,t)),c=e.additionalItems&&typeof e.additionalItems=="object"?Ue(e.additionalItems,t):void 0;c?n=L.tuple(a).rest(c):n=L.tuple(a),typeof e.minItems=="number"&&(n=n.check(L.minLength(e.minItems))),typeof e.maxItems=="number"&&(n=n.check(L.maxLength(e.maxItems)))}else if(i!==void 0){let a=Ue(i,t),c=L.array(a);typeof e.minItems=="number"&&(c=c.min(e.minItems)),typeof e.maxItems=="number"&&(c=c.max(e.maxItems)),n=c}else n=L.array(L.any());break}default:throw new Error(`Unsupported type: ${o}`)}return e.description&&(n=n.describe(e.description)),e.default!==void 0&&(n=n.default(e.default)),n}s(l_,"convertBaseSchema");function Ue(e,t){if(typeof e=="boolean")return e?L.any():L.never();let o=l_(e,t),n=e.type||e.enum!==void 0||e.const!==void 0;if(e.anyOf&&Array.isArray(e.anyOf)){let c=e.anyOf.map(m=>Ue(m,t)),p=L.union(c);o=n?L.intersection(o,p):p}if(e.oneOf&&Array.isArray(e.oneOf)){let c=e.oneOf.map(m=>Ue(m,t)),p=L.xor(c);o=n?L.intersection(o,p):p}if(e.allOf&&Array.isArray(e.allOf))if(e.allOf.length===0)o=n?o:L.any();else{let c=n?o:Ue(e.allOf[0],t),p=n?0:1;for(let m=p;m<e.allOf.length;m++)c=L.intersection(c,Ue(e.allOf[m],t));o=c}e.nullable===!0&&t.version==="openapi-3.0"&&(o=L.nullable(o)),e.readOnly===!0&&(o=L.readonly(o));let r={},i=["$id","id","$comment","$anchor","$vocabulary","$dynamicRef","$dynamicAnchor"];for(let c of i)c in e&&(r[c]=e[c]);let a=["contentEncoding","contentMediaType","contentSchema"];for(let c of a)c in e&&(r[c]=e[c]);for(let c of Object.keys(e))$C.has(c)||(r[c]=e[c]);return Object.keys(r).length>0&&t.registry.add(o,r),o}s(Ue,"convertSchema");function d_(e,t){if(typeof e=="boolean")return e?L.any():L.never();let o=NC(e,t?.defaultTarget),n=e.$defs||e.definitions||{},r={version:o,defs:n,refs:new Map,processing:new Set,rootSchema:e,registry:t?.registry??Re};return Ue(e,r)}s(d_,"fromJSONSchema");var Ff={};Ye(Ff,{bigint:()=>UC,boolean:()=>LC,date:()=>qC,number:()=>MC,string:()=>zC});function zC(e){return Bn(Po,e)}s(zC,"string");function MC(e){return li(So,e)}s(MC,"number");function LC(e){return fi(To,e)}s(LC,"boolean");function UC(e){return hi(Eo,e)}s(UC,"bigint");function qC(e){return _i(Vi,e)}s(qC,"date");me(Mn());var DF=bu.enum(["active","out_of_credits","rejected","unreachable"]);var m_=(n=>(n.AGENT_DECIDE="agent-decide",n.CHOOSE_YOURSELF="choose-yourself",n.LEAVE_EMPTY="leave-empty",n))(m_||{}),Bf=(o=>(o.FILE="FILE",o.TABLE="TABLE",o))(Bf||{}),Zf=(n=>(n.SSE="sse",n.STREAMABLE_HTTP="streamable-http",n.SIMPLE_HTTP="http",n))(Zf||{});var Vf=(n=>(n.TEXT="text",n.NUMBER="number",n.BOOLEAN="boolean",n))(Vf||{});var Gf=(o=>(o.IN_PROGRESS="in-progress",o.COMPLETED="completed",o))(Gf||{});var jC=A({mode:F(m_),value:G()}),FC=A({auth:O(y()),fields:H(y(),jC)}),BC=A({pieceName:y(),pieceVersion:y(),actionName:y(),predefinedInput:O(FC)}),ZC=A({type:j("PIECE"),toolName:y().check(Se(1)),pieceMetadata:BC}),VC=A({type:j("none")}),GC=A({type:j("access_token"),accessToken:y()}),HC=A({type:j("api_key"),apiKey:y(),apiKeyHeader:y()}),WC=A({type:j("headers"),headers:H(y(),y())}),KC=Jt("type",[VC,GC,HC,WC]),f_=A({type:j("FLOW"),toolName:y().check(Se(1)),externalFlowId:y(),flowDisplayName:O(y())}),h_=A({type:j("MCP"),toolName:y().check(Se(1)),serverUrl:Rg(),protocol:F(Zf),auth:KC}),y_=A({type:j("KNOWLEDGE_BASE"),toolName:y().check(Se(1)),sourceType:F(Bf),sourceId:y(),sourceName:y()}),JC=Jt("type",[ZC,f_,h_,y_]),XC=A({displayName:y(),description:O(y()),type:F(Vf)}),g_=A({type:j("MARKDOWN"),markdown:y()}),Io={type:j("TOOL_CALL"),input:fe(H(y(),G())),output:O(G()),toolName:y(),status:F(Gf),toolCallId:y(),startTime:y(),endTime:O(y())},u6=A(Io),v_=Jt("toolCallType",[A({...Io,toolCallType:j("PIECE"),pieceName:y(),pieceVersion:y(),actionName:y()}),A({...Io,toolCallType:j("FLOW"),displayName:y(),externalFlowId:y()}),A({...Io,toolCallType:j("MCP"),displayName:y(),serverUrl:y()}),A({...Io,toolCallType:j("KNOWLEDGE_BASE"),displayName:y(),sourceType:y()}),A({...Io,toolCallType:j("UNKNOWN"),displayName:y()})]),YC=X([g_,v_]);var Wf=(o=>(o.IMAGE="image",o.TEXT="text",o))(Wf||{}),zt=A({apiKey:y()}),e$=zt,t$=A({apiKey:y(),apiKeyHash:y()}),r$=zt,o$=zt,n$=zt,i$=zt,a$=zt,s$=zt,c$=zt,x_=A({serviceAccountJson:y().check(Se(1))}),S_=A({accessKeyId:y().check(Se(1)),secretAccessKey:y().check(Se(1))}),u$=A({}),p$=A({}),l$=A({}),d$=A({}),m$=A({}),f$=A({}),Kf=A({modelId:y(),modelName:y(),modelType:F(Wf)}),T_=A({apiKeyHeader:y(),baseUrl:y(),models:B(Kf),defaultHeaders:O(H(y(),y())),apiStyle:O(F(["chat","responses"]))}),E_=A({accountId:y(),gatewayId:y(),models:B(Kf),vertexProject:O(y()),vertexRegion:O(y())}),I_=A({resourceName:y(),apiVersion:Yt(Xt(e=>typeof e=="string"&&e.trim().length===0?void 0:e),O(y()))}),A_=A({region:y().check(Se(1))}),k_=A({project:y().check(ze(/^[a-z0-9][a-z0-9-]{0,62}$/)),region:y().check(ze(/^[a-z0-9][a-z0-9-]{0,62}$/)),models:B(Kf)}),w_=A({}),h$=X([e$,n$,i$,a$,s$,o$,r$,t$,S_,x_,c$]),O_=X([T_,E_,I_,k_,A_,u$,l$,d$,m$,p$,f$,w_]),y$=A({id:y(),name:y(),type:F(Wf)}),g$=A({id:y(),name:y(),provider:F(vo),config:O_,enabledForChat:re()}),v$=A({provider:F(vo),name:y(),enabledForChat:re(),keys:B(A({id:y(),name:y()}))}),_$=A({provider:F(vo),configId:y(),config:O_,auth:h$,platformId:y()});var m6={openai:"openai",anthropic:"anthropic","google-ai-studio":"google","google-vertex-ai":"google"},__=["gpt-5.5","gpt-5.4-mini","gpt-5.4-nano","gpt-4.1","gpt-4.1-mini"],b$=["claude-sonnet-4-6","claude-opus-4-7","claude-haiku-4-5"],R_=["claude-sonnet-4.6","claude-opus-4.7","claude-opus-4.8","claude-haiku-4.5"],Hf=["gemini-2.5-pro","gemini-2.5-flash","gemini-3.7-flash","gemini-3.1-pro-preview","gemini-3-flash-preview"],P$=["grok-4.20"],f6=R_.map(e=>`anthropic/${e}`),x$={openai:__,anthropic:b$,google:Hf,vertex:Hf,activepieces:[...R_.map(e=>`anthropic/${e}`),...__.map(e=>`openai/${e}`),...Hf.map(e=>`google/${e}`),...P$.map(e=>`x-ai/${e}`)]};var b_=128e3,S$={openai:128e3,anthropic:2e5,google:1048576,bedrock:2e5,vertex:1048576,azure:128e3,openrouter:128e3,activepieces:2e5,mistral:128e3};function T$({provider:e}){return e?S$[e]??b_:b_}s(T$,"getMaxContextTokens");var P_={openai:"text-embedding-3-small",google:"text-embedding-004",azure:"text-embedding-3-small",activepieces:"text-embedding-3-small",openrouter:"openai/text-embedding-3-small"},E$={anthropic:"native",google:"native",openrouter:"plugin",activepieces:"plugin"},I$=new Set(["anthropic","mistral","xai","deepseek","zai","qwen","minimax","moonshot"]),A$={xai:"https://api.x.ai/v1",deepseek:"https://api.deepseek.com/v1",zai:"https://api.z.ai/api/paas/v4",qwen:"https://dashscope-intl.aliyuncs.com/compatible-mode/v1",minimax:"https://api.minimax.io/v1",moonshot:"https://api.moonshot.ai/v1"};function Me(e){return{chatModels:x$[e],maxContextTokens:T$({provider:e}),defaultEmbeddingModel:P_[e],supportsEmbedding:P_[e]!==void 0,supportsImageGeneration:!I$.has(e),webSearch:E$[e]}}s(Me,"buildProviderCapabilities");var k$={openai:Me("openai"),anthropic:Me("anthropic"),openrouter:Me("openrouter"),azure:Me("azure"),google:Me("google"),"cloudflare-gateway":Me("cloudflare-gateway"),custom:Me("custom"),bedrock:Me("bedrock"),vertex:Me("vertex"),mistral:Me("mistral"),activepieces:Me("activepieces"),xai:Me("xai"),deepseek:Me("deepseek"),zai:Me("zai"),qwen:Me("qwen"),minimax:Me("minimax"),moonshot:Me("moonshot")};var w$=A({base64Url:y(),fileName:y(),extension:O(y())}),O$=A({mimeType:y(),url:y(),fileName:O(y())}),Jf=X([w$,O$]);var R$=X([A({type:j("file"),value:Jf}),A({type:j("markdown"),value:y(),files:O(B(Jf))})]),C$=A({sessionId:y(),message:y(),files:O(B(y()))});var $_=(o=>(o.ON_NEW_RECORD="ON_NEW_RECORD",o.ON_UPDATE_RECORD="ON_UPDATE_RECORD",o))($_||{}),N_=(o=>(o.ENABLED="ENABLED",o.DISABLED="DISABLED",o))(N_||{}),Xf=(n=>(n.RECORD_CREATED="RECORD_CREATED",n.RECORD_UPDATED="RECORD_UPDATED",n.RECORD_DELETED="RECORD_DELETED",n))(Xf||{});var $$=X([A({...at,name:y(),externalId:y(),type:j("STATIC_DROPDOWN"),tableId:y(),projectId:y(),data:A({options:B(A({value:y()}))})}),A({...at,name:y(),externalId:y(),type:X([j("TEXT"),j("NUMBER"),j("DATE"),j("DATETIME")]),tableId:y(),projectId:y()})]),N$=A({...at,name:y(),folderId:fe(y()),projectId:y(),externalId:y(),status:Cm(N_),trigger:Cm($_)}),D$=A({...at,tableId:y(),projectId:y(),cells:H(y(),A({updated:y(),created:y(),value:G(),fieldName:y()}))}),z$=A({events:B(F(Xf)),webhookUrl:y(),flowId:y()}),M$=A({fields:B(A({id:y(),name:y()})),rows:B(H(y(),y())),name:y()}),L$=A({projectId:y(),limit:O(wi.number()),cursor:O(y()),name:O(y()),externalIds:Uc(y()),folderId:O(y()),folderIds:Uc(y())}),U$=A({records:B(B(A({fieldId:y(),value:z_()}))),tableId:y()}),q$=A({cells:O(B(A({fieldId:y(),value:z_()}))),tableId:y(),agentUpdate:O(re())}),D_=Jt("operator",[zr("eq"),zr("neq"),zr("gt"),zr("gte"),zr("lt"),zr("lte"),zr("co"),C_("exists"),C_("not_exists")]),j$=A({tableId:y(),limit:O(wi.number()),cursor:O(y()),filters:Uc(D_)});function z_(){return Yt(Xt(e=>e==null?e:String(e)),ki(y()))}s(z_,"coerceToString");function zr(e){return A({fieldId:y(),operator:j(e),value:y()})}s(zr,"valueFilter");function C_(e){return A({fieldId:y(),operator:j(e)})}s(C_,"existenceFilter");var F$=A({status:O(Ce()),body:O(G()),headers:O(H(y(),y()))}),B$=A({...at,deleted:fe(er),ownerId:y(),displayName:y(),platformId:y(),externalId:fe(y())});var M_=A({name:y(),description:O(y()),type:y(),required:re()}),Z$=A({pieceName:y(),triggerName:y(),input:A({toolName:y(),toolDescription:y(),inputSchema:B(M_),returnsResponse:re()})});var L_="^[0-9]+\\.[0-9]+\\.[0-9]+$",$6=new RegExp(L_),G$="^([~^])?[0-9]+\\.[0-9]+\\.[0-9]+$",N6=y().check(ze(new RegExp(L_))),D6=y().check(ze(new RegExp(G$))),H$=A({packageType:j("ARCHIVE"),pieceType:F(ho),pieceName:y(),pieceVersion:y(),archiveId:y(),platformId:y()}),U_=A({packageType:j("REGISTRY"),pieceType:j("OFFICIAL"),pieceName:y(),pieceVersion:y()}),q_=A({packageType:j("REGISTRY"),pieceType:j("CUSTOM"),pieceName:y(),pieceVersion:y(),platformId:y()}),z6=X([U_,q_]),M6=X([H$,U_,q_]);var W$=Jt("type",[A({type:j("CRON_EXPRESSION"),cronExpression:y(),timezone:y()}),A({type:j("INTERVAL"),intervalMs:Cg().check(Ae(6e4))})]),L6=A({...at,type:F(Ee),projectId:y(),flowId:y(),triggerName:y(),schedule:fe(W$),flowVersionId:y(),pieceName:y(),pieceVersion:y(),deleted:fe(y()),simulate:re()}),j_=(T=>(T.UNKNOWN="UNKNOWN",T.FLOW_RUN_LOG="FLOW_RUN_LOG",T.FLOW_RUN_LOG_SLICE="FLOW_RUN_LOG_SLICE",T.PACKAGE_ARCHIVE="PACKAGE_ARCHIVE",T.FLOW_STEP_FILE="FLOW_STEP_FILE",T.SAMPLE_DATA="SAMPLE_DATA",T.TRIGGER_PAYLOAD="TRIGGER_PAYLOAD",T.SAMPLE_DATA_INPUT="SAMPLE_DATA_INPUT",T.TRIGGER_EVENT_FILE="TRIGGER_EVENT_FILE",T.PROJECT_RELEASE="PROJECT_RELEASE",T.FLOW_VERSION_BACKUP="FLOW_VERSION_BACKUP",T.PLATFORM_ASSET="PLATFORM_ASSET",T.USER_PROFILE_PICTURE="USER_PROFILE_PICTURE",T.WEBHOOK_PAYLOAD="WEBHOOK_PAYLOAD",T.KNOWLEDGE_BASE="KNOWLEDGE_BASE",T.FLOW_BUNDLE="FLOW_BUNDLE",T))(j_||{}),F_=(o=>(o.NONE="NONE",o.ZSTD="ZSTD",o))(F_||{}),B_=(o=>(o.S3="S3",o.DB="DB",o))(B_||{}),U6=A({...at,projectId:fe(y()),platformId:fe(y()),type:F(j_),compression:F(F_),data:O(G()),location:F(B_),size:fe(Ce()),fileName:fe(y()),s3Key:fe(y()),metadata:fe(H(y(),y()))}),Z_=(n=>(n.ADMIN="ADMIN",n.MEMBER="MEMBER",n.OPERATOR="OPERATOR",n))(Z_||{}),V_=(o=>(o.ACTIVE="ACTIVE",o.INACTIVE="INACTIVE",o))(V_||{}),q6=A({id:y(),email:y(),firstName:y(),status:F(V_),externalId:fe(y()),platformId:fe(y()),platformRole:F(Z_),lastName:y(),created:er,updated:er,lastActiveDate:fe(er),imageUrl:fe(y())});var Yf=A({...te.shape,...W(H(y(),G()),"OBJECT").shape});var Qf=A({...te.shape,formatProperty:O(y()),...W(y(),"RICH_TEXT").shape});var K_=A({...te.shape,...W(y(),"COLOR").shape});var eh=X([tt,Ct,Qf,zc,Nt,rt,$t,Im,Oi,km,Dt,$i,Yf,Ni,Ci,Am,Ri,K_]),u={ShortText(e){return{...e,valueSchema:void 0,type:"SHORT_TEXT"}},Checkbox(e){return{...e,valueSchema:void 0,type:"CHECKBOX"}},LongText(e){return{...e,valueSchema:void 0,type:"LONG_TEXT"}},RichText(e){return{...e,valueSchema:void 0,type:"RICH_TEXT"}},MarkDown(e){return{displayName:"Markdown",required:!1,description:e.value,type:"MARKDOWN",valueSchema:void 0,variant:e.variant??"INFO"}},Number(e){return{...e,valueSchema:void 0,type:"NUMBER"}},Json(e){return{...e,valueSchema:void 0,type:"JSON"}},Array(e){return{...e,valueSchema:void 0,type:"ARRAY"}},Object(e){return{...e,valueSchema:void 0,type:"OBJECT"}},Dropdown(e){return{...e,valueSchema:void 0,type:"DROPDOWN"}},StaticDropdown(e){return{...e,valueSchema:void 0,type:"STATIC_DROPDOWN"}},MultiSelectDropdown(e){return{...e,valueSchema:void 0,type:"MULTI_SELECT_DROPDOWN"}},DynamicProperties(e){return{...e,valueSchema:void 0,type:"DYNAMIC"}},StaticMultiSelectDropdown(e){return{...e,valueSchema:void 0,type:"STATIC_MULTI_SELECT_DROPDOWN"}},DateTime(e){return{...e,valueSchema:void 0,type:"DATE_TIME"}},DateRange(e){return{...e,valueSchema:void 0,type:"DATE_RANGE"}},File(e){return{...e,valueSchema:void 0,type:"FILE"}},Custom(e){let t=e.code.toString();return{...e,code:t,valueSchema:void 0,type:"CUSTOM"}},Color(e){return{...e,valueSchema:void 0,type:"COLOR"}}};var bt=A({displayName:y(),description:O(y()),hasConnectionIdentifier:O(re())});var J_=A({username:y(),password:y()}),th=A({...bt.shape,username:A({displayName:y(),description:O(y())}),password:A({displayName:y(),description:O(y())}),...W(J_,"BASIC_AUTH").shape});var Y$=H(y(),X([tt,Ct,Dt,Nt,rt])),rh=A({...bt.shape,props:Y$,...W(G(),"CUSTOM_AUTH").shape});var Mr=A({...bt.shape,...W(A({auth:y()}),"SECRET_TEXT").shape});var Q$=H(y(),X([tt,Ct,Mr,Dt,Nt,rt,$t,zc])),X_=A({...bt.shape,props:Q$,...W(G(),"OIDC").shape});var oh=(o=>(o.HEADER="HEADER",o.BODY="BODY",o))(oh||{}),Y_=X([tt,Mr,rt]),Q_=H(y(),Y_),eN=A({props:O(H(y(),Y_)),authUrl:y(),tokenUrl:y(),scope:B(y()),prompt:O(X([j("none"),j("consent"),j("login"),j("omit")])),pkce:O(re()),pkceMethod:O(X([j("plain"),j("S256")])),authorizationMethod:O(F(oh)),grantType:O(X([F(zi),j(wm)])),extra:O(H(y(),y()))}),eb=A({access_token:y(),props:O(Q_),data:H(y(),Ai())}),nh=A({...bt.shape,...eN.shape,...W(eb,"OAUTH2").shape});var Ao=X([th,rh,X_,nh,Mr]),Xi="Connection",ih={SecretText(e){return{...e,valueSchema:void 0,type:"SECRET_TEXT"}},OAuth2(e){return{...e,valueSchema:void 0,type:"OAUTH2",displayName:e.displayName||Xi}},BasicAuth(e){return{...e,valueSchema:void 0,type:"BASIC_AUTH",displayName:e.displayName||Xi,required:!0}},CustomAuth(e){return{...e,valueSchema:void 0,type:"CUSTOM_AUTH",displayName:e.displayName||Xi}},OIDC(e){return{...e,valueSchema:void 0,type:"OIDC",displayName:e.displayName||Xi}},None(){}};var SZ={OAUTH2:"OAUTH2",CLOUD_OAUTH2:"OAUTH2",PLATFORM_OAUTH2:"OAUTH2",BASIC_AUTH:"BASIC_AUTH",CUSTOM_AUTH:"CUSTOM_AUTH",OIDC:"OIDC",SECRET_TEXT:"SECRET_TEXT",NO_AUTH:void 0};var tN=A({...te.shape,...W(G(),"CUSTOM").shape,code:y()});var rN=X([eh,Ao]),ah=H(y(),rN),ZZ=H(y(),eh);var tb=X([A({strategy:j("CRON"),cronExpression:y()}),A({strategy:j("NONE")})]),ko=class{constructor(t,o,n,r,i,a,c,p,m,l,g,h,f,v,I,T,x,k,R,q,Q){this.name=t;this.displayName=o;this.description=n;this.requireAuth=r;this.props=i;this.type=a;this.handshakeConfiguration=c;this.onHandshake=p;this.renewConfiguration=m;this.onRenew=l;this.onEnable=g;this.onDisable=h;this.onStart=f;this.run=v;this.test=I;this.sampleData=T;this.testStrategy=x;this.outputSchema=k;this.aiMetadata=R;this.classification=q;this.propertyGroups=Q}static{s(this,"ITrigger")}},ue=s(e=>{switch(e.type){case"WEBHOOK":return new ko(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,e.handshakeConfiguration??{strategy:"NONE"},e.onHandshake??(async()=>({status:200})),e.renewConfiguration??{strategy:"NONE"},e.onRenew??(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,e.test?"TEST_FUNCTION":"SIMULATION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"POLLING":return new ko(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"MANUAL":return new ko(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups);case"APP_WEBHOOK":return new ko(e.name,e.displayName,e.description,e.requireAuth??!0,e.props,e.type,{strategy:"NONE"},async()=>({status:200}),{strategy:"NONE"},(async()=>Promise.resolve()),e.onEnable,e.onDisable,e.onStart??(async()=>Promise.resolve()),e.run,e.test??(()=>Promise.resolve([e.sampleData])),e.sampleData,ot(e.sampleData)&&ot(e.test)?"SIMULATION":"TEST_FUNCTION",e.outputSchema,e.aiMetadata,e.classification,e.propertyGroups)}},"createTrigger");var rb="2",Pu="0.82.0";var sh=class{constructor(t,o,n,r,i,a,c,p,m=Pu,l,g="",h){this.displayName=t;this.logoUrl=o;this.authors=n;this.events=r;this.categories=c;this.auth=p;this.minimumSupportedRelease=m;this.maximumSupportedRelease=l;this.description=g;this.deprecated=h;this._actions={};this._triggers={};this.getContextInfo=s(()=>({version:rb}),"getContextInfo");(!nN(m)||iN(m,Pu))&&(this.minimumSupportedRelease=Pu),i.forEach(f=>this._actions[f.name]=f),a.forEach(f=>this._triggers[f.name]=f)}static{s(this,"Piece")}metadata(){return{displayName:this.displayName,logoUrl:this.logoUrl,actions:this._actions,triggers:this._triggers,categories:this.categories,description:this.description,authors:this.authors,auth:oN(this.auth),minimumSupportedRelease:this.minimumSupportedRelease,maximumSupportedRelease:this.maximumSupportedRelease,deprecated:this.deprecated,contextInfo:this.getContextInfo?.()}}getAction(t){return this._actions[t]}getTrigger(t){return this._triggers[t]}actions(){return this._actions}triggers(){return this._triggers}},nb=s(e=>{if(e.auth&&Array.isArray(e.auth)&&!e.auth.every((o,n,r)=>n===r.findIndex(i=>i.type===o.type)))throw new Error("Auth properties must be unique by type");return new sh(e.displayName,e.logoUrl,e.authors??[],e.events,e.actions,e.triggers,e.categories??[],e.auth,e.minimumSupportedRelease,e.maximumSupportedRelease,e.description,e.deprecated)},"createPiece");function oN(e){if(e!==void 0)return Array.isArray(e)?e.map(ob):ob(e)}s(oN,"withConnectionIdentifierFlag");function ob(e){return{...e,hasConnectionIdentifier:e.getConnectionIdentifier!==void 0}}s(ob,"flagConnectionIdentifier");function nN(e){return/^\d+\.\d+\.\d+$/.test(e)}s(nN,"isValidSimpleSemver");function iN(e,t){let[o,n,r]=e.split(".").map(Number),[i,a,c]=t.split(".").map(Number);return o!==i?o<i:n!==a?n<a:r<c}s(iN,"isSemverLessThan");var aN=O(H(y(),H(y(),y()))),ib=A({id:O(y()),name:y(),displayName:y(),logoUrl:y(),description:y(),authors:B(y()),platformId:O(y()),directoryPath:O(y()),auth:O(X([Ao,B(Ao)])),version:y(),categories:O(B(F(yo))),minimumSupportedRelease:O(y()),maximumSupportedRelease:O(y()),deprecated:O(re()),i18n:aN}),sN=F(["human","ai","both"]),ab=A({description:O(y()),idempotent:O(re())}),sb=F(["READ","SEARCH","WRITE","DESTRUCTIVE"]);var cN=F(["tabs","section","summary","builder","footer"]),cb=A({key:y(),display:cN,label:O(y()),description:O(y()),icon:O(y()),props:B(y())}),ub=A({name:y(),displayName:y(),description:y(),props:ah,propertyGroups:O(B(cb)),requireAuth:re(),errorHandlingOptions:O(Em),outputSchema:O(Nc()),audience:O(sN),aiMetadata:O(ab),classification:O(sb)}),pb=A({name:y(),displayName:y(),description:y(),props:ah,propertyGroups:O(B(cb)),errorHandlingOptions:O(Em),type:F(Ee),sampleData:G(),handshakeConfiguration:O(Nc()),renewConfiguration:O(tb),testStrategy:F(Li),outputSchema:O(Nc()),aiMetadata:O(ab),classification:O(sb)}),uN=A({...ib.shape,actions:H(y(),ub),triggers:H(y(),pb)}),pN=A({...ib.shape,actions:Ce(),triggers:Ce(),suggestedActions:O(B(ub)),suggestedTriggers:O(B(pb))}),lb=A({projectUsage:Ce(),pieceType:F(ho),packageType:F(Di),platformId:O(y()),archiveId:O(y())}),HV=A({...uN.shape,...lb.shape}),WV=A({...pN.shape,...lb.shape}),KV=A({name:y(),version:y()});var lN=pt(require("path")),dN=pt(require("fs/promises"));var wo=require("node:stream");var xu=class{constructor(t,o){this.baseUrl=t;this.authenticationConverter=o}static{s(this,"BaseHttpClient")}getUrl(t){let o=new URL(`${this.baseUrl}${t.url}`),n=`${o.origin}${o.pathname}`,r=new URLSearchParams;return o.searchParams.forEach((i,a)=>{r.append(a,i)}),{urlWithoutQueryParams:n,queryParams:r}}getHeaders(t){let o={Accept:"application/json"};return t.authentication&&this.populateAuthentication(t.authentication,o),t.body&&(t.headers?.["Content-Type"]==="text/csv"?o["Content-Type"]="text/csv":o["Content-Type"]="application/json"),t.headers&&(o={...o,...t.headers}),o}populateAuthentication(t,o){this.authenticationConverter.convert(t,o)}};var Su=class{static{s(this,"DelegatingAuthenticationConverter")}constructor(t=new ch,o=new uh){this.converters={BEARER_TOKEN:t,BASIC:o}}convert(t,o){return this.converters[t.type].convert(t,o)}},ch=class{static{s(this,"BearerTokenAuthenticationConverter")}convert(t,o){return o.Authorization=`Bearer ${t.token}`,o}},uh=class{static{s(this,"BasicTokenAuthenticationConverter")}convert(t,o){let n=`${t.username}:${t.password}`,r=Buffer.from(n).toString("base64");return o.Authorization=`Basic ${r}`,o}};var Yi=class extends Error{constructor(o,n){let r=n.status||500,i=Buffer.isBuffer(n.responseBody)?n.responseBody.toString():n.responseBody;super(JSON.stringify({response:{status:r,body:i},request:{body:o}}));this.requestBody=o;this.status=r,this.responseBody=i}static{s(this,"HttpError")}errorMessage(){return{response:{status:this.status,body:this.responseBody},request:{body:this.requestBody}}}get response(){return{status:this.status,body:this.responseBody}}get request(){return{body:this.requestBody}}};function db({error:e,requestBody:t}){return e instanceof Yi?e.errorMessage():{response:{status:0,body:e instanceof Error?e.message:String(e)},request:{body:t}}}s(db,"toFailsafeOutput");var C=(a=>(a.GET="GET",a.POST="POST",a.PATCH="PATCH",a.PUT="PUT",a.DELETE="DELETE",a.HEAD="HEAD",a))(C||{});var Tu=class extends xu{static{s(this,"FetchHttpClient")}constructor(t="",o=new Su){super(t,o)}async sendRequest(t,o){process.env.NODE_TLS_REJECT_UNAUTHORIZED="0";let{urlWithoutQueryParams:n,queryParams:r}=this.getUrl(t),i=this.getHeaders(t),a=t.queryParams??{};for(let[R,q]of Object.entries(a))r.append(R,q);let c=r.toString(),p=c?`${n}?${c}`:n,m=t.responseType??"json",l=t.followRedirects??!0,g=t.retries??0,{body:h,extraHeaders:f,isStream:v}=mN(t.method)?fN(t.body,i):{body:void 0,extraHeaders:{},isStream:!1},I=yN({...i,...f}),T=await hN(async()=>{let R=new AbortController,q=t.timeout&&t.timeout>0?setTimeout(()=>R.abort(),t.timeout):void 0;try{let Q={method:t.method.toString(),headers:I,body:h,redirect:l?"follow":"manual",signal:R.signal};return v&&(Q.duplex="half"),o?.dispatcher!==void 0&&(Q.dispatcher=o.dispatcher),await fetch(p,Q)}finally{q!==void 0&&clearTimeout(q)}},v?0:g),x=l?300:400;if(T.status<200||T.status>=x){let R=await mb(T,m==="stream"?"text":m),q=new Yi(t.body,{status:T.status,responseBody:R});throw console.error("[HttpClient#(sanitized error message)] Request failed:",q),q}let k=await mb(T,m);return{status:T.status,headers:gN(T.headers),body:k}}};function mN(e){return e!=="GET"&&e!=="HEAD"}s(mN,"acceptsRequestBody");function fN(e,t){if(hb(e))return{body:void 0,extraHeaders:{},isStream:!1};if(_N(e)){let n=vN(e);if(n!==null)return{body:n,extraHeaders:e.getHeaders(),isStream:!1};let r=new wo.PassThrough;return e.on("error",i=>r.destroy(i)),e.pipe(r),{body:r,extraHeaders:e.getHeaders(),isStream:!0}}return e instanceof wo.Readable?{body:e,extraHeaders:{},isStream:!0}:typeof e=="string"||Buffer.isBuffer(e)||e instanceof URLSearchParams||e instanceof ArrayBuffer||typeof FormData<"u"&&e instanceof FormData||typeof Blob<"u"&&e instanceof Blob?{body:e,extraHeaders:{},isStream:!1}:(t["Content-Type"]??t["content-type"]??"").includes("application/x-www-form-urlencoded")?{body:new URLSearchParams(e).toString(),extraHeaders:{},isStream:!1}:{body:JSON.stringify(e),extraHeaders:{},isStream:!1}}s(fN,"serializeBody");async function mb(e,t){switch(t){case"arraybuffer":return Buffer.from(await e.arrayBuffer());case"stream":return hb(e.body)?wo.Readable.from([]):wo.Readable.fromWeb(e.body);case"blob":return await e.blob();case"text":return await e.text();default:{let o=await e.text();if(o.length===0)return;try{return JSON.parse(o)}catch{return o}}}}s(mb,"parseResponseBody");async function hN(e,t){let o;for(let n=0;n<=t;n++)try{let r=await e();if(r.status>=500&&n<t){await fb(n);continue}return r}catch(r){if(o=r,n<t){await fb(n);continue}throw r}throw o}s(hN,"sendWithRetries");function fb(e){let t=Math.min(1e3*2**e,3e4);return new Promise(o=>setTimeout(o,t))}s(fb,"backoff");function yN(e){let t=new Map;for(let[o,n]of Object.entries(e))n!==void 0&&t.set(o.toLowerCase(),[o,Array.isArray(n)?n.join(", "):n]);return Object.fromEntries(t.values())}s(yN,"normalizeHeaders");function gN(e){let t={};return e.forEach((o,n)=>{t[n]=o}),t}s(gN,"toHttpHeaders");function vN(e){if(!e.hasKnownLength()||e.getLengthSync()>bN)return null;let{data:t}=Om(()=>e.getBuffer());return t}s(vN,"bufferFormDataIfSafe");function _N(e){return typeof e=="object"&&e!==null&&typeof e.getHeaders=="function"&&typeof e.pipe=="function"&&typeof e.on=="function"}s(_N,"isNodeFormData");function hb(e){return e==null}s(hb,"isNil");var bN=100*1024*1024;var b=new Tu;var sz=pt(require("fs")),_x=pt(vx());var cz={"application/json":"json","application/pdf":"pdf","application/xml":"xml","text/xml":"xml","application/zip":"zip","application/gzip":"gz","application/x-tar":"tar","application/octet-stream":"bin","application/msword":"doc","application/vnd.openxmlformats-officedocument.wordprocessingml.document":"docx","application/vnd.ms-excel":"xls","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":"xlsx","application/vnd.ms-powerpoint":"ppt","application/vnd.openxmlformats-officedocument.presentationml.presentation":"pptx","application/rtf":"rtf","application/javascript":"js","application/x-www-form-urlencoded":"bin","text/plain":"txt","text/html":"html","text/css":"css","text/csv":"csv","text/calendar":"ics","text/markdown":"md","image/png":"png","image/jpeg":"jpeg","image/jpg":"jpg","image/gif":"gif","image/webp":"webp","image/svg+xml":"svg","image/bmp":"bmp","image/tiff":"tiff","image/x-icon":"ico","image/vnd.microsoft.icon":"ico","image/heic":"heic","audio/mpeg":"mp3","audio/mp4":"m4a","audio/wav":"wav","audio/x-wav":"wav","audio/ogg":"ogg","audio/webm":"weba","video/mp4":"mp4","video/mpeg":"mpeg","video/webm":"webm","video/quicktime":"mov","video/x-msvideo":"avi","font/woff":"woff","font/woff2":"woff2","font/ttf":"ttf","font/otf":"otf"};function uz(e){let t=e.split(";")[0].trim().toLowerCase();return cz[t]??""}s(uz,"contentTypeToExtension");var pz=s(({baseUrl:e,relativePath:t})=>{let o=e.endsWith("/")?e:`${e}/`,n=t.startsWith("/")?t.slice(1):t;return`${o}${n}`},"joinBaseUrlWithRelativePath"),lz=s((e,t)=>{let o="https://api.example.com";try{let n=t?e(t):void 0;return(n?.endsWith("/")?n.slice(0,-1):n)??o}catch{return o}},"getBaseUrlForDescription");function bx({auth:e,baseUrl:t,authMapping:o,description:n,displayName:r,name:i,props:a,extraProps:c,authLocation:p="headers",classification:m="WRITE"}){return E({audience:"human",name:i||"custom_api_call",classification:m,displayName:r||"Custom API Call",description:n||"Make a custom API call to a specific endpoint",auth:e,requireAuth:!!e,props:{url:u.DynamicProperties({auth:e,displayName:"",required:!0,refreshers:[],props:s(async({auth:l})=>({url:u.ShortText({displayName:"URL",description:`Full URL, or a path relative to ${lz(t,l)}`,required:!0,placeholder:"/resource",defaultValue:l?t(l):"",...a?.url??{}})}),"props")}),method:u.StaticDropdown({displayName:"Method",required:!0,defaultValue:"GET",options:{options:Object.values(C).map(l=>({label:l,value:l}))},...a?.method??{}}),headers:u.Object({displayName:"Headers",description:"Authorization headers are injected automatically from your connection.",required:!1,...a?.headers??{}}),queryParams:u.Object({displayName:"Query Parameters",description:"Appended to the URL as ?key=value.",required:!1,...a?.queryParams??{}}),body_type:u.StaticDropdown({displayName:"Body Type",required:!1,defaultValue:"none",options:{disabled:!1,options:[{label:"None",value:"none"},{label:"JSON",value:"json"},{label:"Form Data",value:"form_data"},{label:"Raw",value:"raw"}]}}),body:u.DynamicProperties({auth:e,displayName:"Body",refreshers:["body_type"],required:!1,props:s(async({body_type:l})=>{if(!l)return{};let g=l,h={};switch(g){case"none":break;case"json":h.data=u.Json({displayName:"JSON Body",required:!0,...a?.body??{}});break;case"raw":h.data=u.LongText({displayName:"Raw Body",required:!0});break;case"form_data":h.data=u.Array({displayName:"Form Data",required:!0,properties:{fieldName:u.ShortText({displayName:"Field Name",required:!0}),fieldType:u.StaticDropdown({displayName:"Field Type",required:!0,options:{disabled:!1,options:[{label:"Text",value:"text"},{label:"File",value:"file"}]}}),textFieldValue:u.LongText({displayName:"Text Field Value",required:!1}),fileFieldValue:u.File({displayName:"File Field Value",required:!1})}});break}return h},"props")}),response_is_binary:u.Checkbox({displayName:"Response is Binary",description:"Enable for files like PDFs, images, etc.",required:!1,defaultValue:!1,advanced:!0,...a?.response_is_binary??{}}),failsafe:u.Checkbox({displayName:"Return Error as Output",description:"On a failed request, output the error instead of failing the step.",required:!1,advanced:!0,...a?.failsafe??{}}),timeout:u.Number({displayName:"Timeout",description:"Seconds to wait for a response. Empty: up to the flow limit (10 min).",required:!1,advanced:!0,...a?.timeout??{}}),followRedirects:u.Checkbox({displayName:"Follow redirects",description:"Follow 3xx redirects instead of returning them as the response.",required:!1,defaultValue:!1,advanced:!0,...a?.followRedirects??{}}),...c},run:s(async l=>{let{method:g,url:h,headers:f,queryParams:v,body:I,body_type:T,failsafe:x,timeout:k,response_is_binary:R,followRedirects:q}=l.propsValue;Lc(g,"Method"),Lc(h,"URL");let Q=ot(o)?{}:await o(l.auth,l.propsValue),we=h.url,Pe=we.startsWith("http://")||we.startsWith("https://")?we:pz({baseUrl:t(l.auth),relativePath:we}),he={method:g,url:Pe,headers:{...f??{},...p==="headers"||!ot(p)?Q:{}},queryParams:{...p==="queryParams"?Q:{},...v??{}},timeout:k?k*1e3:0,followRedirects:q};if(R&&(he.responseType="arraybuffer"),I)if(T&&T!=="none"){let pe=I.data;if(T==="form_data"){let xe=pe,ct=new _x.default;for(let{fieldName:At,fieldType:Ze,textFieldValue:ut,fileFieldValue:Xe}of xe)Ze==="text"&&!K(ut)?ct.append(At,ut):Ze==="file"&&!K(Xe)&&ct.append(At,Xe.data,{filename:Xe?.filename});he.body=ct,he.headers={...he.headers,...ct.getHeaders()}}else he.body=pe}else T||(he.body=I);try{let pe=await b.sendRequest(he);return await dz(l.files,pe.body,pe.status,pe.headers,R)}catch(pe){if(x)return db({error:pe,requestBody:he.body});throw pe}},"run")})}s(bx,"createCustomApiCallAction");var dz=s(async(e,t,o,n,r)=>{let i;if(r&&mz(t)){let a=Array.isArray(n?.["content-type"])?n["content-type"][0]:n?.["content-type"],c=uz(a??"")||"txt",p;t instanceof ArrayBuffer?p=Buffer.from(new Uint8Array(t)):Buffer.isBuffer(t)?p=t:p=Buffer.from(t),i=await e.write({fileName:`output.${c}`,data:p})}else i=t;return{status:o,headers:n,body:i}},"handleBinaryResponse"),mz=s(e=>e instanceof ArrayBuffer||Buffer.isBuffer(e),"isBinaryBody");function ge(e,t){return{fields:[{key:"data",label:"Data",labelKey:t,listItems:e},{key:"has_more",label:"Has More",format:"boolean"},{key:"url",label:"URL"}]}}s(ge,"listSchema");function Do(e,t){return{fields:[{key:"data",label:"Results",labelKey:t,listItems:e},{key:"has_more",label:"Has More",format:"boolean"},{key:"next_page",label:"Next Page"},{key:"url",label:"URL"}]}}s(Do,"searchSchema");var xx=[{key:"line1",label:"Line 1"},{key:"line2",label:"Line 2"},{key:"city",label:"City"},{key:"state",label:"State"},{key:"postal_code",label:"Postal Code"},{key:"country",label:"Country"}],fz=[{key:"brand",label:"Brand"},{key:"last4",label:"Last 4"},{key:"exp_month",label:"Expiry Month",format:"number"},{key:"exp_year",label:"Expiry Year",format:"number"},{key:"funding",label:"Funding"},{key:"country",label:"Country"},{key:"display_brand",label:"Display Brand"}],Sx=[{key:"name",label:"Name"},{key:"email",label:"Email",format:"email"},{key:"phone",label:"Phone"},{key:"address",label:"Address",children:xx}],Rh=[{key:"id",label:"Customer ID"},{key:"email",label:"Email",format:"email"},{key:"name",label:"Name"},{key:"description",label:"Description"},{key:"phone",label:"Phone"},{key:"address",label:"Address",children:xx},{key:"balance",label:"Balance",format:"number"},{key:"currency",label:"Currency"},{key:"delinquent",label:"Delinquent",format:"boolean"},{key:"invoice_prefix",label:"Invoice Prefix"},{key:"tax_exempt",label:"Tax Exempt"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ch=[{key:"id",label:"Product ID"},{key:"name",label:"Name"},{key:"description",label:"Description"},{key:"active",label:"Active",format:"boolean"},{key:"default_price",label:"Default Price"},{key:"images",label:"Images"},{key:"url",label:"URL",format:"url"},{key:"unit_label",label:"Unit Label"},{key:"type",label:"Type"},{key:"created",label:"Created",format:"datetime"},{key:"updated",label:"Updated",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],$u=[{key:"id",label:"Price ID"},{key:"active",label:"Active",format:"boolean"},{key:"currency",label:"Currency"},{key:"product",label:"Product"},{key:"nickname",label:"Nickname"},{key:"unit_amount",label:"Unit Amount",format:"number"},{key:"unit_amount_decimal",label:"Unit Amount Decimal"},{key:"type",label:"Type"},{key:"billing_scheme",label:"Billing Scheme"},{key:"tax_behavior",label:"Tax Behavior"},{key:"lookup_key",label:"Lookup Key"},{key:"recurring",label:"Recurring",children:[{key:"interval",label:"Interval"},{key:"interval_count",label:"Interval Count",format:"number"},{key:"trial_period_days",label:"Trial Period Days",format:"number"},{key:"usage_type",label:"Usage Type"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],$h=[{key:"id",label:"Coupon ID"},{key:"name",label:"Name"},{key:"amount_off",label:"Amount Off",format:"number"},{key:"percent_off",label:"Percent Off",format:"number"},{key:"currency",label:"Currency"},{key:"duration",label:"Duration"},{key:"duration_in_months",label:"Duration In Months",format:"number"},{key:"max_redemptions",label:"Max Redemptions",format:"number"},{key:"times_redeemed",label:"Times Redeemed",format:"number"},{key:"redeem_by",label:"Redeem By",format:"datetime"},{key:"valid",label:"Valid",format:"boolean"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Tx=[{key:"id",label:"Promotion Code ID"},{key:"code",label:"Code"},{key:"active",label:"Active",format:"boolean"},{key:"customer",label:"Customer"},{key:"coupon",label:"Coupon",children:$h},{key:"expires_at",label:"Expires At",format:"datetime"},{key:"max_redemptions",label:"Max Redemptions",format:"number"},{key:"times_redeemed",label:"Times Redeemed",format:"number"},{key:"restrictions",label:"Restrictions",children:[{key:"first_time_transaction",label:"First Time Transaction",format:"boolean"},{key:"minimum_amount",label:"Minimum Amount",format:"number"},{key:"minimum_amount_currency",label:"Minimum Amount Currency"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ex=[{key:"id",label:"Tax Rate ID"},{key:"display_name",label:"Display Name"},{key:"description",label:"Description"},{key:"active",label:"Active",format:"boolean"},{key:"percentage",label:"Percentage",format:"number"},{key:"effective_percentage",label:"Effective Percentage",format:"number"},{key:"inclusive",label:"Inclusive",format:"boolean"},{key:"country",label:"Country"},{key:"state",label:"State"},{key:"jurisdiction",label:"Jurisdiction"},{key:"tax_type",label:"Tax Type"},{key:"rate_type",label:"Rate Type"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ix=[{key:"id",label:"Payment Method ID"},{key:"type",label:"Type"},{key:"customer",label:"Customer"},{key:"billing_details",label:"Billing Details",children:Sx},{key:"card",label:"Card",children:fz},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Nh=[{key:"id",label:"Payment Intent ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_received",label:"Amount Received",format:"number"},{key:"amount_capturable",label:"Amount Capturable",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"customer",label:"Customer"},{key:"description",label:"Description"},{key:"payment_method",label:"Payment Method"},{key:"latest_charge",label:"Latest Charge"},{key:"capture_method",label:"Capture Method"},{key:"confirmation_method",label:"Confirmation Method"},{key:"client_secret",label:"Client Secret"},{key:"receipt_email",label:"Receipt Email",format:"email"},{key:"setup_future_usage",label:"Setup Future Usage"},{key:"cancellation_reason",label:"Cancellation Reason"},{key:"canceled_at",label:"Canceled At",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Dh=[{key:"id",label:"Charge ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_captured",label:"Amount Captured",format:"number"},{key:"amount_refunded",label:"Amount Refunded",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"paid",label:"Paid",format:"boolean"},{key:"captured",label:"Captured",format:"boolean"},{key:"refunded",label:"Refunded",format:"boolean"},{key:"disputed",label:"Disputed",format:"boolean"},{key:"customer",label:"Customer"},{key:"description",label:"Description"},{key:"payment_intent",label:"Payment Intent"},{key:"payment_method",label:"Payment Method"},{key:"balance_transaction",label:"Balance Transaction"},{key:"receipt_url",label:"Receipt URL",format:"url"},{key:"receipt_email",label:"Receipt Email",format:"email"},{key:"receipt_number",label:"Receipt Number"},{key:"calculated_statement_descriptor",label:"Statement Descriptor"},{key:"billing_details",label:"Billing Details",children:Sx},{key:"payment_method_details",label:"Payment Method Details",children:[{key:"type",label:"Type"},{key:"card",label:"Card",children:[{key:"brand",label:"Brand"},{key:"last4",label:"Last 4"},{key:"exp_month",label:"Expiry Month",format:"number"},{key:"exp_year",label:"Expiry Year",format:"number"},{key:"funding",label:"Funding"},{key:"country",label:"Country"},{key:"network",label:"Network"}]}]},{key:"outcome",label:"Outcome",children:[{key:"network_status",label:"Network Status"},{key:"risk_level",label:"Risk Level"},{key:"risk_score",label:"Risk Score",format:"number"},{key:"seller_message",label:"Seller Message"},{key:"type",label:"Type"}]},{key:"failure_code",label:"Failure Code"},{key:"failure_message",label:"Failure Message"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],hz=[{key:"id",label:"Balance Transaction ID"},{key:"amount",label:"Amount",format:"number"},{key:"net",label:"Net",format:"number"},{key:"fee",label:"Fee",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"description",label:"Description"},{key:"reporting_category",label:"Reporting Category"},{key:"source",label:"Source"},{key:"available_on",label:"Available On",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"fee_details",label:"Fee Details",labelKey:"description",listItems:[{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"type",label:"Type"},{key:"description",label:"Description"}]}],Ax=[{key:"id",label:"Refund ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"charge",label:"Charge"},{key:"payment_intent",label:"Payment Intent"},{key:"payment_method",label:"Payment Method"},{key:"balance_transaction",label:"Balance Transaction"},{key:"reason",label:"Reason"},{key:"receipt_number",label:"Receipt Number"},{key:"created",label:"Created",format:"datetime"},{key:"metadata",label:"Metadata",dynamicKey:!0}],yz=[{key:"id",label:"Invoice Item ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"invoice",label:"Invoice"},{key:"description",label:"Description"},{key:"quantity",label:"Quantity",format:"number"},{key:"date",label:"Date",format:"datetime"},{key:"discountable",label:"Discountable",format:"boolean"},{key:"proration",label:"Proration",format:"boolean"},{key:"period",label:"Period",children:[{key:"start",label:"Start",format:"datetime"},{key:"end",label:"End",format:"datetime"}]},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],kx=[{key:"id",label:"Credit Note ID"},{key:"number",label:"Number"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"reason",label:"Reason"},{key:"customer",label:"Customer"},{key:"invoice",label:"Invoice"},{key:"memo",label:"Memo"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"subtotal_excluding_tax",label:"Subtotal Excluding Tax",format:"number"},{key:"total",label:"Total",format:"number"},{key:"total_excluding_tax",label:"Total Excluding Tax",format:"number"},{key:"discount_amount",label:"Discount Amount",format:"number"},{key:"pre_payment_amount",label:"Pre-Payment Amount",format:"number"},{key:"post_payment_amount",label:"Post-Payment Amount",format:"number"},{key:"pdf",label:"PDF",format:"url"},{key:"created",label:"Created",format:"datetime"},{key:"effective_at",label:"Effective At",format:"datetime"},{key:"voided_at",label:"Voided At",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],wx=[{key:"id",label:"Checkout Session ID"},{key:"status",label:"Status"},{key:"payment_status",label:"Payment Status"},{key:"mode",label:"Mode"},{key:"url",label:"URL",format:"url"},{key:"success_url",label:"Success URL",format:"url"},{key:"cancel_url",label:"Cancel URL",format:"url"},{key:"amount_subtotal",label:"Amount Subtotal",format:"number"},{key:"amount_total",label:"Amount Total",format:"number"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"customer_email",label:"Customer Email",format:"email"},{key:"payment_intent",label:"Payment Intent"},{key:"subscription",label:"Subscription"},{key:"invoice",label:"Invoice"},{key:"payment_link",label:"Payment Link"},{key:"client_reference_id",label:"Client Reference ID"},{key:"total_details",label:"Total Details",children:[{key:"amount_discount",label:"Amount Discount",format:"number"},{key:"amount_shipping",label:"Amount Shipping",format:"number"},{key:"amount_tax",label:"Amount Tax",format:"number"}]},{key:"expires_at",label:"Expires At",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Ox=[{key:"id",label:"Payment Link ID"},{key:"active",label:"Active",format:"boolean"},{key:"url",label:"URL",format:"url"},{key:"currency",label:"Currency"},{key:"allow_promotion_codes",label:"Allow Promotion Codes",format:"boolean"},{key:"billing_address_collection",label:"Billing Address Collection"},{key:"customer_creation",label:"Customer Creation"},{key:"payment_method_collection",label:"Payment Method Collection"},{key:"submit_type",label:"Submit Type"},{key:"application_fee_amount",label:"Application Fee Amount",format:"number"},{key:"application_fee_percent",label:"Application Fee Percent",format:"number"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Rx=[{key:"id",label:"Dispute ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"reason",label:"Reason"},{key:"charge",label:"Charge"},{key:"payment_intent",label:"Payment Intent"},{key:"balance_transaction",label:"Balance Transaction"},{key:"is_charge_refundable",label:"Is Charge Refundable",format:"boolean"},{key:"evidence_details",label:"Evidence Details",children:[{key:"due_by",label:"Due By",format:"datetime"},{key:"has_evidence",label:"Has Evidence",format:"boolean"},{key:"past_due",label:"Past Due",format:"boolean"},{key:"submission_count",label:"Submission Count",format:"number"}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Cx=[{key:"id",label:"Payout ID"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"status",label:"Status"},{key:"type",label:"Type"},{key:"method",label:"Method"},{key:"automatic",label:"Automatic",format:"boolean"},{key:"arrival_date",label:"Arrival Date",format:"datetime"},{key:"balance_transaction",label:"Balance Transaction"},{key:"destination",label:"Destination"},{key:"description",label:"Description"},{key:"statement_descriptor",label:"Statement Descriptor"},{key:"source_type",label:"Source Type"},{key:"failure_code",label:"Failure Code"},{key:"failure_message",label:"Failure Message"},{key:"reconciliation_status",label:"Reconciliation Status"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],gz=[{key:"id",label:"Transfer ID"},{key:"amount",label:"Amount",format:"number"},{key:"amount_reversed",label:"Amount Reversed",format:"number"},{key:"currency",label:"Currency"},{key:"description",label:"Description"},{key:"destination",label:"Destination"},{key:"source_transaction",label:"Source Transaction"},{key:"transfer_group",label:"Transfer Group"},{key:"reversed",label:"Reversed",format:"boolean"},{key:"balance_transaction",label:"Balance Transaction"},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],$x=[{key:"id",label:"Event ID"},{key:"type",label:"Type"},{key:"api_version",label:"API Version"},{key:"created",label:"Created",format:"datetime"},{key:"pending_webhooks",label:"Pending Webhooks",format:"number"},{key:"request",label:"Request",children:[{key:"id",label:"Request ID"},{key:"idempotency_key",label:"Idempotency Key"}]},{key:"data",label:"Data",children:[{key:"object",label:"Object"}]},{key:"livemode",label:"Live Mode",format:"boolean"}],Nx=[{key:"id",label:"Subscription Item ID"},{key:"quantity",label:"Quantity",format:"number"},{key:"subscription",label:"Subscription"},{key:"current_period_start",label:"Current Period Start",format:"datetime"},{key:"current_period_end",label:"Current Period End",format:"datetime"},{key:"price",label:"Price",children:$u},{key:"created",label:"Created",format:"datetime"},{key:"metadata",label:"Metadata",dynamicKey:!0}],zh=[{key:"id",label:"Subscription ID"},{key:"status",label:"Status"},{key:"customer",label:"Customer"},{key:"currency",label:"Currency"},{key:"description",label:"Description"},{key:"collection_method",label:"Collection Method"},{key:"latest_invoice",label:"Latest Invoice"},{key:"default_payment_method",label:"Default Payment Method"},{key:"quantity",label:"Quantity",format:"number"},{key:"start_date",label:"Start Date",format:"datetime"},{key:"billing_cycle_anchor",label:"Billing Cycle Anchor",format:"datetime"},{key:"cancel_at",label:"Cancel At",format:"datetime"},{key:"canceled_at",label:"Canceled At",format:"datetime"},{key:"cancel_at_period_end",label:"Cancel At Period End",format:"boolean"},{key:"ended_at",label:"Ended At",format:"datetime"},{key:"trial_start",label:"Trial Start",format:"datetime"},{key:"trial_end",label:"Trial End",format:"datetime"},{key:"items",label:"Items",children:[{key:"data",label:"Data",labelKey:"id",listItems:Nx}]},{key:"created",label:"Created",format:"datetime"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Dx=[{key:"id",label:"Line ID"},{key:"description",label:"Description"},{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"},{key:"quantity",label:"Quantity",format:"number"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"invoice",label:"Invoice"},{key:"period",label:"Period",children:[{key:"start",label:"Start",format:"datetime"},{key:"end",label:"End",format:"datetime"}]},{key:"discountable",label:"Discountable",format:"boolean"},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Mh=[{key:"id",label:"Invoice ID"},{key:"number",label:"Number"},{key:"status",label:"Status"},{key:"currency",label:"Currency"},{key:"customer",label:"Customer"},{key:"customer_email",label:"Customer Email",format:"email"},{key:"customer_name",label:"Customer Name"},{key:"customer_phone",label:"Customer Phone"},{key:"description",label:"Description"},{key:"collection_method",label:"Collection Method"},{key:"billing_reason",label:"Billing Reason"},{key:"amount_due",label:"Amount Due",format:"number"},{key:"amount_paid",label:"Amount Paid",format:"number"},{key:"amount_remaining",label:"Amount Remaining",format:"number"},{key:"subtotal",label:"Subtotal",format:"number"},{key:"total",label:"Total",format:"number"},{key:"attempt_count",label:"Attempt Count",format:"number"},{key:"attempted",label:"Attempted",format:"boolean"},{key:"auto_advance",label:"Auto Advance",format:"boolean"},{key:"due_date",label:"Due Date",format:"datetime"},{key:"created",label:"Created",format:"datetime"},{key:"period_start",label:"Period Start",format:"datetime"},{key:"period_end",label:"Period End",format:"datetime"},{key:"effective_at",label:"Effective At",format:"datetime"},{key:"hosted_invoice_url",label:"Hosted Invoice URL",format:"url"},{key:"invoice_pdf",label:"Invoice PDF",format:"url"},{key:"receipt_number",label:"Receipt Number"},{key:"starting_balance",label:"Starting Balance",format:"number"},{key:"ending_balance",label:"Ending Balance",format:"number"},{key:"status_transitions",label:"Status Transitions",children:[{key:"finalized_at",label:"Finalized At",format:"datetime"},{key:"paid_at",label:"Paid At",format:"datetime"},{key:"marked_uncollectible_at",label:"Marked Uncollectible At",format:"datetime"},{key:"voided_at",label:"Voided At",format:"datetime"}]},{key:"lines",label:"Lines",children:[{key:"data",label:"Data",labelKey:"description",listItems:Dx}]},{key:"livemode",label:"Live Mode",format:"boolean"},{key:"metadata",label:"Metadata",dynamicKey:!0}],Px=[{key:"amount",label:"Amount",format:"number"},{key:"currency",label:"Currency"}],Je={fields:Rh},or={fields:Ch},nr={fields:$u},Nu={fields:$h},Du={fields:Tx},zu={fields:Ex},zo={fields:Ix},qe={fields:Nh},Mo={fields:Dh},ir={fields:Ax},zx={fields:yz},Ie={fields:Mh},Ne={fields:zh},Lo={fields:kx},st={fields:Ox},Uo={fields:wx},ar={fields:Rx},Mu={fields:Cx},Mx={fields:$x},Lx={fields:[{key:"available",label:"Available",labelKey:"currency",listItems:Px},{key:"pending",label:"Pending",labelKey:"currency",listItems:Px},{key:"livemode",label:"Live Mode",format:"boolean"}]},Ux=ge(Rh,"email"),qx=ge(Ch,"name"),jx=ge($u,"id"),Fx=ge($h,"name"),Bx=ge(Tx,"code"),Zx=ge(Ex,"display_name"),Vx=ge(Ix,"id"),Gx=ge(Nh,"id"),Hx=ge(Dh,"id"),Wx=ge(Ax,"id"),Kx=ge(Mh,"number"),Jx=ge(Dx,"description"),Xx=ge(zh,"id"),Yx=ge(Nx,"id"),Qx=ge(kx,"number"),eS=ge(Ox,"id"),tS=ge(wx,"id"),rS=ge(Rx,"id"),oS=ge(Cx,"id"),nS=ge(gz,"id"),iS=ge($x,"type"),aS=ge(hz,"id"),sS=Do(Dh,"id"),Lu=Do(Rh,"email"),cS=Do(Mh,"number"),uS=Do(Nh,"id"),pS=Do($u,"id"),lS=Do(Ch,"name"),Uu={fields:[{key:"success",label:"Success",format:"boolean"},{key:"count",label:"Count",format:"number"},{key:"total_fetched",label:"Total Fetched",format:"number"},{key:"requests_made",label:"Requests Made",format:"number"},{key:"has_more_available",label:"Has More Available",format:"boolean"},{key:"subscriptions",label:"Subscriptions",labelKey:"id",listItems:zh}]};var dS=E({name:"create_customer",classification:"WRITE",auth:_,displayName:"Create Customer",description:"Create a customer in stripe",audience:"human",aiMetadata:{description:"Creates a new customer record in Stripe from an email and name, with optional contact and address fields. Use when onboarding a new payer before charging, invoicing, or subscribing them. Not idempotent: each call creates a distinct customer even with identical input.",idempotent:!1},props:{email:u.ShortText({displayName:"Email",description:void 0,required:!0}),name:u.ShortText({displayName:"Name",required:!0}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Je,async run(e){let t={email:e.propsValue.email,name:e.propsValue.name,description:e.propsValue.description,phone:e.propsValue.phone,address:{line1:e.propsValue.line1,postal_code:e.propsValue.postal_code,city:e.propsValue.city,state:e.propsValue.state,country:e.propsValue.country}};return(await b.sendRequest({method:"POST",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:{email:t.email,name:t.name,description:t.description,phone:t.phone,address:t.address}})).body}});var mS=E({name:"create_invoice",classification:"WRITE",auth:_,displayName:"Create Invoice",description:"Create an Invoice in stripe",audience:"human",aiMetadata:{description:"Creates a draft invoice in Stripe for an existing customer in the given currency. Use to bill a customer for pending invoice items. Requires a valid Stripe customer ID; not idempotent, as each call creates a separate invoice.",idempotent:!1},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"Stripe Customer ID",required:!0}),currency:u.ShortText({displayName:"Currency",description:"Currency for the invoice (e.g., USD)",required:!0}),description:u.LongText({displayName:"Description",description:"Description for the invoice",required:!1})},outputSchema:Ie,async run(e){let t={customer:e.propsValue.customer_id,currency:e.propsValue.currency,description:e.propsValue.description};return(await b.sendRequest({method:"POST",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:{customer:t.customer,currency:t.currency,description:t.description}})).body}});var fS=E({name:"retrieve_customer",classification:"READ",auth:_,displayName:"Retrieve Customer",description:"Retrieve a customer in stripe by id",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe customer by its customer ID (e.g., cus_...). Use when you already have the exact ID and need the current record; for lookup by email use Search Customer instead. Read-only and idempotent.",idempotent:!0},props:{id:u.ShortText({displayName:"ID",description:void 0,required:!0})},outputSchema:Je,async run(e){let t={id:e.propsValue.id};return(await b.sendRequest({method:"GET",url:`https://api.stripe.com/v1/customers/${t.id}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Ko=pt(require("crypto"),1),my=require("events");var ju=pt(require("crypto"),1);var sr=class{static{s(this,"CryptoProvider")}computeHMACSignature(t,o){throw new Error("computeHMACSignature not implemented.")}computeHMACSignatureAsync(t,o){throw new Error("computeHMACSignatureAsync not implemented.")}computeSHA256Async(t){throw new Error("computeSHA256 not implemented.")}},qo=class extends Error{static{s(this,"CryptoProviderOnlySupportsAsyncError")}};var qu=class extends sr{static{s(this,"NodeCryptoProvider")}computeHMACSignature(t,o){return ju.createHmac("sha256",o).update(t,"utf8").digest("hex")}async computeHMACSignatureAsync(t,o){return await this.computeHMACSignature(t,o)}async computeSHA256Async(t){return new Uint8Array(await ju.createHash("sha256").update(t).digest())}};var Uh=pt(require("http"),1),qh=pt(require("https"),1);var Le=class e{static{s(this,"HttpClient")}getClientName(){throw new Error("getClientName not implemented.")}makeRequest(t,o,n,r,i,a,c,p){throw new Error("makeRequest not implemented.")}static makeTimeoutError(){let t=new TypeError(e.TIMEOUT_ERROR_CODE);return t.code=e.TIMEOUT_ERROR_CODE,t}};Le.CONNECTION_CLOSED_ERROR_CODES=["ECONNRESET","EPIPE"];Le.TIMEOUT_ERROR_CODE="ETIMEDOUT";var cr=class{static{s(this,"HttpClientResponse")}constructor(t,o){this._statusCode=t,this._headers=o}getStatusCode(){return this._statusCode}getHeaders(){return this._headers}getRawResponse(){throw new Error("getRawResponse not implemented.")}toStream(t){throw new Error("toStream not implemented.")}toJSON(){throw new Error("toJSON not implemented.")}};var hS=Uh.default||Uh,yS=qh.default||qh,vz=new hS.Agent({keepAlive:!0}),_z=new yS.Agent({keepAlive:!0}),oa=class extends Le{static{s(this,"NodeHttpClient")}constructor(t){super(),this._agent=t}getClientName(){return"node"}makeRequest(t,o,n,r,i,a,c,p){let m=c==="http",l=this._agent;return l||(l=m?vz:_z),new Promise((h,f)=>{let v=(m?hS:yS).request({host:t,port:o,path:n,method:r,agent:l,headers:i,ciphers:"DEFAULT:!aNULL:!eNULL:!LOW:!EXPORT:!SSLv2:!MD5"});v.setTimeout(p,()=>{v.destroy(Le.makeTimeoutError())}),v.on("response",I=>{h(new Lh(I))}),v.on("error",I=>{f(I)}),v.once("socket",I=>{I.connecting?I.once(m?"connect":"secureConnect",()=>{v.write(a),v.end()}):(v.write(a),v.end())})})}},Lh=class extends cr{static{s(this,"NodeHttpClientResponse")}constructor(t){super(t.statusCode,t.headers||{}),this._res=t}getRawResponse(){return this._res}toStream(t){return this._res.once("end",()=>t()),this._res}toJSON(){return new Promise((t,o)=>{let n="";this._res.setEncoding("utf8"),this._res.on("data",r=>{n+=r}),this._res.once("end",()=>{try{t(JSON.parse(n))}catch(r){o(r)}})})}};var cT=pt(sT(),1);var uy=["apiKey","idempotencyKey","stripeAccount","apiVersion","maxNetworkRetries","timeout","host","authenticator","stripeContext","additionalHeaders","streaming"];function uT(e){return e&&typeof e=="object"&&uy.some(t=>Object.prototype.hasOwnProperty.call(e,t))}s(uT,"isOptionsHash");function lr(e,t){return cT.stringify(e,{serializeDate:s(o=>Math.floor(o.getTime()/1e3).toString(),"serializeDate"),arrayFormat:t=="v2"?"repeat":"indices"}).replace(/%5B/g,"[").replace(/%5D/g,"]")}s(lr,"queryStringifyRequestData");var Qu=(()=>{let e={"\n":"\\n",'"':'\\"',"\u2028":"\\u2028","\u2029":"\\u2029"};return t=>{let o=t.replace(/["\n\r\u2028\u2029]/g,n=>e[n]);return n=>o.replace(/\{([\s\S]+?)\}/g,(r,i)=>{let a=n[i];return QM(a)?encodeURIComponent(a):""})}})();function QM(e){return["number","string","boolean"].includes(typeof e)}s(QM,"isValidEncodeUriComponentType");function pT(e){let t=e.match(/\{\w+\}/g);return t?t.map(o=>o.replace(/[{}]/g,"")):[]}s(pT,"extractUrlParams");function Zo(e){if(!Array.isArray(e)||!e[0]||typeof e[0]!="object")return{};if(!uT(e[0]))return e.shift();let t=Object.keys(e[0]),o=t.filter(n=>uy.includes(n));return o.length>0&&o.length!==t.length&&fa(`Options found in arguments (${o.join(", ")}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options.`),{}}s(Zo,"getDataFromArgs");function ep(e){let t={host:null,headers:{},settings:{},streaming:!1};if(e.length>0){let o=e[e.length-1];if(typeof o=="string")t.authenticator=Yu(e.pop());else if(uT(o)){let n=Object.assign({},e.pop()),r=Object.keys(n).filter(i=>!uy.includes(i));if(r.length&&fa(`Invalid options found (${r.join(", ")}); ignoring.`),n.apiKey&&(t.authenticator=Yu(n.apiKey)),n.idempotencyKey&&(t.headers["Idempotency-Key"]=n.idempotencyKey),n.stripeAccount&&(t.headers["Stripe-Account"]=n.stripeAccount),n.stripeContext){if(t.headers["Stripe-Account"])throw new Error("Can't specify both stripeAccount and stripeContext.");t.headers["Stripe-Context"]=n.stripeContext}if(n.apiVersion&&(t.headers["Stripe-Version"]=n.apiVersion),Number.isInteger(n.maxNetworkRetries)&&(t.settings.maxNetworkRetries=n.maxNetworkRetries),Number.isInteger(n.timeout)&&(t.settings.timeout=n.timeout),n.host&&(t.host=n.host),n.authenticator){if(n.apiKey)throw new Error("Can't specify both apiKey and authenticator.");if(typeof n.authenticator!="function")throw new Error("The authenticator must be a function receiving a request as the first parameter.");t.authenticator=n.authenticator}n.additionalHeaders&&(t.headers=n.additionalHeaders),n.streaming&&(t.streaming=!0)}}return t}s(ep,"getOptionsFromArgs");function lT(e){let t=this,o=Object.prototype.hasOwnProperty.call(e,"constructor")?e.constructor:function(...n){t.apply(this,n)};return Object.assign(o,t),o.prototype=Object.create(t.prototype),Object.assign(o.prototype,e),o}s(lT,"protoExtend");function tp(e){if(typeof e!="object")throw new Error("Argument must be an object");return Object.keys(e).reduce((t,o)=>(e[o]!=null&&(t[o]=e[o]),t),{})}s(tp,"removeNullish");function dT(e){return e&&typeof e=="object"?Object.keys(e).reduce((t,o)=>(t[e0(o)]=e[o],t),{}):e}s(dT,"normalizeHeaders");function e0(e){return e.split("-").map(t=>t.charAt(0).toUpperCase()+t.substr(1).toLowerCase()).join("-")}s(e0,"normalizeHeader");function ma(e,t){return t?e.then(o=>{setTimeout(()=>{t(null,o)},0)},o=>{setTimeout(()=>{t(o,null)},0)}):e}s(ma,"callbackifyPromiseWithTimeout");function mT(e){return e==="OAuth"?"oauth":e[0].toLowerCase()+e.substring(1)}s(mT,"pascalToCamelCase");function fa(e){return typeof process.emitWarning!="function"?console.warn(`Stripe: ${e}`):process.emitWarning(e,"Stripe")}s(fa,"emitWarning");function t0(e){let t=typeof e;return(t==="function"||t==="object")&&!!e}s(t0,"isObject");function fT(e){let t={},o=s((n,r)=>{Object.entries(n).forEach(([i,a])=>{let c=r?`${r}[${i}]`:i;if(t0(a)){if(!(a instanceof Uint8Array)&&!Object.prototype.hasOwnProperty.call(a,"data"))return o(a,c);t[c]=a}else t[c]=String(a)})},"step");return o(e,null),t}s(fT,"flattenAndStringify");function rp(e,t,o){if(!Number.isInteger(t)){if(o!==void 0)return o;throw new Error(`${e} must be an integer`)}return t}s(rp,"validateInteger");function hT(){return typeof process>"u"?{}:{lang_version:process.version,platform:process.platform}}s(hT,"determineProcessUserAgentProperties");function Yu(e){let t=s(o=>(o.headers.Authorization="Bearer "+e,Promise.resolve()),"authenticator");return t._apiKey=e,t}s(Yu,"createApiKeyAuthenticator");function yT(e){let t=e.reduce((r,i)=>r+i.length,0),o=new Uint8Array(t),n=0;return e.forEach(r=>{o.set(r,n),n+=r.length}),o}s(yT,"concat");function r0(e,t){return this[e]instanceof Date?Math.floor(this[e].getTime()/1e3).toString():t}s(r0,"dateTimeReplacer");function gT(e){return JSON.stringify(e,r0)}s(gT,"jsonStringifyRequestData");function Vo(e){return e&&e.startsWith("/v2")?"v2":"v1"}s(Vo,"getAPIMode");function op(e){return Array.isArray(e)?e.join(", "):String(e)}s(op,"parseHttpHeaderAsString");function vT(e){let t=Array.isArray(e)?e[0]:e;return Number(t)}s(vT,"parseHttpHeaderAsNumber");function _T(e){return Object.entries(e).map(([t,o])=>[t,op(o)])}s(_T,"parseHeadersForFetch");var np=class e extends Le{static{s(this,"FetchHttpClient")}constructor(t){if(super(),!t){if(!globalThis.fetch)throw new Error("fetch() function not provided and is not defined in the global scope. You must provide a fetch implementation.");t=globalThis.fetch}globalThis.AbortController?this._fetchFn=e.makeFetchWithAbortTimeout(t):this._fetchFn=e.makeFetchWithRaceTimeout(t)}static makeFetchWithRaceTimeout(t){return(o,n,r)=>{let i,a=new Promise((p,m)=>{i=setTimeout(()=>{i=null,m(Le.makeTimeoutError())},r)}),c=t(o,n);return Promise.race([c,a]).finally(()=>{i&&clearTimeout(i)})}}static makeFetchWithAbortTimeout(t){return async(o,n,r)=>{let i=new AbortController,a=setTimeout(()=>{a=null,i.abort(Le.makeTimeoutError())},r);try{return await t(o,Object.assign(Object.assign({},n),{signal:i.signal}))}catch(c){throw c.name==="AbortError"?Le.makeTimeoutError():c}finally{a&&clearTimeout(a)}}}getClientName(){return"fetch"}async makeRequest(t,o,n,r,i,a,c,p){let m=c==="http",l=new URL(n,`${m?"http":"https"}://${t}`);l.port=o;let g=r=="POST"||r=="PUT"||r=="PATCH",h=a||(g?"":void 0),f=await this._fetchFn(l.toString(),{method:r,headers:_T(i),body:typeof h=="object"?JSON.stringify(h):h},p);return new py(f)}},py=class e extends cr{static{s(this,"FetchHttpClientResponse")}constructor(t){super(t.status,e._transformHeadersToObject(t.headers)),this._res=t}getRawResponse(){return this._res}toStream(t){return t(),this._res.body}toJSON(){return this._res.json()}static _transformHeadersToObject(t){let o={};for(let n of t){if(!Array.isArray(n)||n.length!=2)throw new Error("Response objects produced by the fetch function given to FetchHttpClient do not have an iterable headers map. Response#headers should be an iterable object.");o[n[0]]=n[1]}return o}};var ip=class extends sr{static{s(this,"SubtleCryptoProvider")}constructor(t){super(),this.subtleCrypto=t||crypto.subtle}computeHMACSignature(t,o){throw new qo("SubtleCryptoProvider cannot be used in a synchronous context.")}async computeHMACSignatureAsync(t,o){let n=new TextEncoder,r=await this.subtleCrypto.importKey("raw",n.encode(o),{name:"HMAC",hash:{name:"SHA-256"}},!1,["sign"]),i=await this.subtleCrypto.sign("hmac",r,n.encode(t)),a=new Uint8Array(i),c=new Array(a.length);for(let p=0;p<a.length;p++)c[p]=ly[a[p]];return c.join("")}async computeSHA256Async(t){return new Uint8Array(await this.subtleCrypto.digest("SHA-256",t))}},ly=new Array(256);for(let e=0;e<ly.length;e++)ly[e]=e.toString(16).padStart(2,"0");var ap=class{static{s(this,"PlatformFunctions")}constructor(){this._fetchFn=null,this._agent=null}getUname(){throw new Error("getUname not implemented.")}uuid4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{let o=Math.random()*16|0;return(t==="x"?o:o&3|8).toString(16)})}secureCompare(t,o){if(t.length!==o.length)return!1;let n=t.length,r=0;for(let i=0;i<n;++i)r|=t.charCodeAt(i)^o.charCodeAt(i);return r===0}createEmitter(){throw new Error("createEmitter not implemented.")}tryBufferData(t){throw new Error("tryBufferData not implemented.")}createNodeHttpClient(t){throw new Error("createNodeHttpClient not implemented.")}createFetchHttpClient(t){return new np(t)}createDefaultHttpClient(){throw new Error("createDefaultHttpClient not implemented.")}createNodeCryptoProvider(){throw new Error("createNodeCryptoProvider not implemented.")}createSubtleCryptoProvider(t){return new ip(t)}createDefaultCryptoProvider(){throw new Error("createDefaultCryptoProvider not implemented.")}};var dp={};Ye(dp,{StripeAPIError:()=>Go,StripeAuthenticationError:()=>Ho,StripeCardError:()=>sp,StripeConnectionError:()=>ga,StripeError:()=>_e,StripeIdempotencyError:()=>cp,StripeInvalidGrantError:()=>up,StripeInvalidRequestError:()=>ha,StripePermissionError:()=>ya,StripeRateLimitError:()=>Wo,StripeSignatureVerificationError:()=>yt,StripeUnknownError:()=>pp,TemporarySessionExpiredError:()=>lp,generateV1Error:()=>va,generateV2Error:()=>dy});var va=s(e=>{switch(e.type){case"card_error":return new sp(e);case"invalid_request_error":return new ha(e);case"api_error":return new Go(e);case"authentication_error":return new Ho(e);case"rate_limit_error":return new Wo(e);case"idempotency_error":return new cp(e);case"invalid_grant":return new up(e);default:return new pp(e)}},"generateV1Error"),dy=s(e=>e.type==="temporary_session_expired"?new lp(e):e.code==="invalid_fields"?new ha(e):va(e),"generateV2Error"),_e=class extends Error{static{s(this,"StripeError")}constructor(t={},o=null){var n;super(t.message),this.type=o||this.constructor.name,this.raw=t,this.rawType=t.type,this.code=t.code,this.doc_url=t.doc_url,this.param=t.param,this.detail=t.detail,this.headers=t.headers,this.requestId=t.requestId,this.statusCode=t.statusCode,this.message=(n=t.message)!==null&&n!==void 0?n:"",this.userMessage=t.user_message,this.charge=t.charge,this.decline_code=t.decline_code,this.payment_intent=t.payment_intent,this.payment_method=t.payment_method,this.payment_method_type=t.payment_method_type,this.setup_intent=t.setup_intent,this.source=t.source}};_e.generate=va;var sp=class extends _e{static{s(this,"StripeCardError")}constructor(t={}){super(t,"StripeCardError")}},ha=class extends _e{static{s(this,"StripeInvalidRequestError")}constructor(t={}){super(t,"StripeInvalidRequestError")}},Go=class extends _e{static{s(this,"StripeAPIError")}constructor(t={}){super(t,"StripeAPIError")}},Ho=class extends _e{static{s(this,"StripeAuthenticationError")}constructor(t={}){super(t,"StripeAuthenticationError")}},ya=class extends _e{static{s(this,"StripePermissionError")}constructor(t={}){super(t,"StripePermissionError")}},Wo=class extends _e{static{s(this,"StripeRateLimitError")}constructor(t={}){super(t,"StripeRateLimitError")}},ga=class extends _e{static{s(this,"StripeConnectionError")}constructor(t={}){super(t,"StripeConnectionError")}},yt=class extends _e{static{s(this,"StripeSignatureVerificationError")}constructor(t,o,n={}){super(n,"StripeSignatureVerificationError"),this.header=t,this.payload=o}},cp=class extends _e{static{s(this,"StripeIdempotencyError")}constructor(t={}){super(t,"StripeIdempotencyError")}},up=class extends _e{static{s(this,"StripeInvalidGrantError")}constructor(t={}){super(t,"StripeInvalidGrantError")}},pp=class extends _e{static{s(this,"StripeUnknownError")}constructor(t={}){super(t,"StripeUnknownError")}},lp=class extends _e{static{s(this,"TemporarySessionExpiredError")}constructor(t={}){super(t,"TemporarySessionExpiredError")}};var bT=require("child_process");var fy=class extends _e{static{s(this,"StreamProcessingError")}},mp=class extends ap{static{s(this,"NodePlatformFunctions")}constructor(){super(),this._exec=bT.exec,this._UNAME_CACHE=null}uuid4(){return Ko.randomUUID?Ko.randomUUID():super.uuid4()}getUname(){return this._UNAME_CACHE||(this._UNAME_CACHE=new Promise((t,o)=>{try{this._exec("uname -a",(n,r)=>{if(n)return t(null);t(r)})}catch{t(null)}})),this._UNAME_CACHE}secureCompare(t,o){if(!t||!o)throw new Error("secureCompare must receive two arguments");if(t.length!==o.length)return!1;if(Ko.timingSafeEqual){let n=new TextEncoder,r=n.encode(t),i=n.encode(o);return Ko.timingSafeEqual(r,i)}return super.secureCompare(t,o)}createEmitter(){return new my.EventEmitter}tryBufferData(t){if(!(t.file.data instanceof my.EventEmitter))return Promise.resolve(t);let o=[];return new Promise((n,r)=>{t.file.data.on("data",i=>{o.push(i)}).once("end",()=>{let i=Object.assign({},t);i.file.data=yT(o),n(i)}).on("error",i=>{r(new fy({message:"An error occurred while attempting to process the file for upload.",detail:i}))})})}createNodeHttpClient(t){return new oa(t)}createDefaultHttpClient(){return new oa}createNodeCryptoProvider(){return new qu}createDefaultCryptoProvider(){return this.createNodeCryptoProvider()}};var o0=60,fp=class e{static{s(this,"RequestSender")}constructor(t,o){this._stripe=t,this._maxBufferedRequestMetric=o}_addHeadersDirectlyToObject(t,o){t.requestId=o["request-id"],t.stripeAccount=t.stripeAccount||o["stripe-account"],t.apiVersion=t.apiVersion||o["stripe-version"],t.idempotencyKey=t.idempotencyKey||o["idempotency-key"]}_makeResponseEvent(t,o,n){let r=Date.now(),i=r-t.request_start_time;return tp({api_version:n["stripe-version"],account:n["stripe-account"],idempotency_key:n["idempotency-key"],method:t.method,path:t.path,status:o,request_id:this._getRequestId(n),elapsed:i,request_start_time:t.request_start_time,request_end_time:r})}_getRequestId(t){return t["request-id"]}_streamingResponseHandler(t,o,n){return r=>{let i=r.getHeaders(),a=s(()=>{let p=this._makeResponseEvent(t,r.getStatusCode(),i);this._stripe._emitter.emit("response",p),this._recordRequestMetrics(this._getRequestId(i),p.elapsed,o)},"streamCompleteCallback"),c=r.toStream(a);return this._addHeadersDirectlyToObject(c,i),n(null,c)}}_jsonResponseHandler(t,o,n,r){return i=>{let a=i.getHeaders(),c=this._getRequestId(a),p=i.getStatusCode(),m=this._makeResponseEvent(t,p,a);this._stripe._emitter.emit("response",m),i.toJSON().then(l=>{if(l.error){let g;throw typeof l.error=="string"&&(l.error={type:l.error,message:l.error_description}),l.error.headers=a,l.error.statusCode=p,l.error.requestId=c,p===401?g=new Ho(l.error):p===403?g=new ya(l.error):p===429?g=new Wo(l.error):o==="v2"?g=dy(l.error):g=va(l.error),g}return l},l=>{throw new Go({message:"Invalid JSON received from the Stripe API",exception:l,requestId:a["request-id"]})}).then(l=>{this._recordRequestMetrics(c,m.elapsed,n);let g=i.getRawResponse();this._addHeadersDirectlyToObject(g,a),Object.defineProperty(l,"lastResponse",{enumerable:!1,writable:!1,value:g}),r(null,l)},l=>r(l,null))}}static _generateConnectionErrorMessage(t){return`An error occurred with our connection to Stripe.${t>0?` Request was retried ${t} times.`:""}`}static _shouldRetry(t,o,n,r){return r&&o===0&&Le.CONNECTION_CLOSED_ERROR_CODES.includes(r.code)?!0:o>=n?!1:t?t.getHeaders()["stripe-should-retry"]==="false"?!1:t.getHeaders()["stripe-should-retry"]==="true"||t.getStatusCode()===409||t.getStatusCode()>=500:!0}_getSleepTimeInMS(t,o=null){let n=this._stripe.getInitialNetworkRetryDelay(),r=this._stripe.getMaxNetworkRetryDelay(),i=Math.min(n*Math.pow(2,t-1),r);return i*=.5*(1+Math.random()),i=Math.max(n,i),Number.isInteger(o)&&o<=o0&&(i=Math.max(i,o)),i*1e3}_getMaxNetworkRetries(t={}){return t.maxNetworkRetries!==void 0&&Number.isInteger(t.maxNetworkRetries)?t.maxNetworkRetries:this._stripe.getMaxNetworkRetries()}_defaultIdempotencyKey(t,o,n){let r=this._getMaxNetworkRetries(o),i=s(()=>`stripe-node-retry-${this._stripe._platformFunctions.uuid4()}`,"genKey");if(n==="v2"){if(t==="POST"||t==="DELETE")return i()}else if(n==="v1"&&t==="POST"&&r>0)return i();return null}_makeHeaders({contentType:t,contentLength:o,apiVersion:n,clientUserAgent:r,method:i,userSuppliedHeaders:a,userSuppliedSettings:c,stripeAccount:p,stripeContext:m,apiMode:l}){let g={Accept:"application/json","Content-Type":t,"User-Agent":this._getUserAgentString(l),"X-Stripe-Client-User-Agent":r,"X-Stripe-Client-Telemetry":this._getTelemetryHeader(),"Stripe-Version":n,"Stripe-Account":p,"Stripe-Context":m,"Idempotency-Key":this._defaultIdempotencyKey(i,c,l)},h=i=="POST"||i=="PUT"||i=="PATCH";return(h||o)&&(h||fa(`${i} method had non-zero contentLength but no payload is expected for this verb`),g["Content-Length"]=o),Object.assign(tp(g),dT(a))}_getUserAgentString(t){let o=this._stripe.getConstant("PACKAGE_VERSION"),n=this._stripe._appInfo?this._stripe.getAppInfoAsString():"";return`Stripe/${t} NodeBindings/${o} ${n}`.trim()}_getTelemetryHeader(){if(this._stripe.getTelemetryEnabled()&&this._stripe._prevRequestMetrics.length>0){let t=this._stripe._prevRequestMetrics.shift();return JSON.stringify({last_request_metrics:t})}}_recordRequestMetrics(t,o,n){if(this._stripe.getTelemetryEnabled()&&t)if(this._stripe._prevRequestMetrics.length>this._maxBufferedRequestMetric)fa("Request metrics buffer is full, dropping telemetry message.");else{let r={request_id:t,request_duration_ms:o};n&&n.length>0&&(r.usage=n),this._stripe._prevRequestMetrics.push(r)}}_rawRequest(t,o,n,r){return new Promise((a,c)=>{let p;try{let f=t.toUpperCase();if(f!=="POST"&&n&&Object.keys(n).length!==0)throw new Error("rawRequest only supports params on POST requests. Please pass null and add your parameters to path.");let v=[].slice.call([n,r]),I=Zo(v),T=f==="POST"?Object.assign({},I):null,x=ep(v),k=x.headers,R=x.authenticator;p={requestMethod:f,requestPath:o,bodyData:T,queryData:{},authenticator:R,headers:k,host:x.host,streaming:!!x.streaming,settings:{},usage:["raw_request"]}}catch(f){c(f);return}function m(f,v){f?c(f):a(v)}s(m,"requestCallback");let{headers:l,settings:g}=p,h=p.authenticator;this._request(p.requestMethod,p.host,o,p.bodyData,h,{headers:l,settings:g,streaming:p.streaming},p.usage,m)})}_request(t,o,n,r,i,a,c=[],p,m=null){var l;let g;i=(l=i??this._stripe._authenticator)!==null&&l!==void 0?l:null;let h=Vo(n),f=s((T,x,k,R,q)=>setTimeout(T,this._getSleepTimeInMS(R,q),x,k,R+1),"retryRequest"),v=s((T,x,k)=>{let R=a.settings&&a.settings.timeout&&Number.isInteger(a.settings.timeout)&&a.settings.timeout>=0?a.settings.timeout:this._stripe.getApiField("timeout"),q={host:o||this._stripe.getApiField("host"),port:this._stripe.getApiField("port"),path:n,method:t,headers:Object.assign({},x),body:g,protocol:this._stripe.getApiField("protocol")};i(q).then(()=>{let Q=this._stripe.getApiField("httpClient").makeRequest(q.host,q.port,q.path,q.method,q.headers,q.body,q.protocol,R),we=Date.now(),Pe=tp({api_version:T,account:op(x["Stripe-Account"]),idempotency_key:op(x["Idempotency-Key"]),method:t,path:n,request_start_time:we}),he=k||0,pe=this._getMaxNetworkRetries(a.settings||{});this._stripe._emitter.emit("request",Pe),Q.then(xe=>e._shouldRetry(xe,he,pe)?f(v,T,x,he,vT(xe.getHeaders()["retry-after"])):a.streaming&&xe.getStatusCode()<400?this._streamingResponseHandler(Pe,c,p)(xe):this._jsonResponseHandler(Pe,h,c,p)(xe)).catch(xe=>{if(e._shouldRetry(null,he,pe,xe))return f(v,T,x,he,null);{let ct=xe.code&&xe.code===Le.TIMEOUT_ERROR_CODE;return p(new ga({message:ct?`Request aborted due to timeout being reached (${R}ms)`:e._generateConnectionErrorMessage(he),detail:xe}))}})}).catch(Q=>{throw new _e({message:"Unable to authenticate the request",exception:Q})})},"makeRequest"),I=s((T,x)=>{if(T)return p(T);g=x,this._stripe.getClientUserAgent(k=>{let R=this._stripe.getApiField("version"),q=this._makeHeaders({contentType:h=="v2"?"application/json":"application/x-www-form-urlencoded",contentLength:g.length,apiVersion:R,clientUserAgent:k,method:t,userSuppliedHeaders:a.headers,userSuppliedSettings:a.settings,stripeAccount:h=="v2"?null:this._stripe.getApiField("stripeAccount"),stripeContext:h=="v2"?this._stripe.getApiField("stripeContext"):null,apiMode:h});v(R,q,0)})},"prepareAndMakeRequest");if(m)m(t,r,a.headers,I);else{let T;h=="v2"?T=r?gT(r):"":T=lr(r||{},h),I(null,T)}}};var hp=class{static{s(this,"V1Iterator")}constructor(t,o,n,r){this.index=0,this.pagePromise=t,this.promiseCache={currentPromise:null},this.requestArgs=o,this.spec=n,this.stripeResource=r}async iterate(t){if(!(t&&t.data&&typeof t.data.length=="number"))throw Error("Unexpected: Stripe API response does not have a well-formed `data` array.");let o=xT(this.requestArgs);if(this.index<t.data.length){let n=o?t.data.length-1-this.index:this.index,r=t.data[n];return this.index+=1,{value:r,done:!1}}else if(t.has_more){this.index=0,this.pagePromise=this.getNextPage(t);let n=await this.pagePromise;return this.iterate(n)}return{done:!0,value:void 0}}getNextPage(t){throw new Error("Unimplemented")}async _next(){return this.iterate(await this.pagePromise)}next(){if(this.promiseCache.currentPromise)return this.promiseCache.currentPromise;let t=(async()=>{let o=await this._next();return this.promiseCache.currentPromise=null,o})();return this.promiseCache.currentPromise=t,t}},yy=class extends hp{static{s(this,"V1ListIterator")}getNextPage(t){let o=xT(this.requestArgs),n=s0(t,o);return this.stripeResource._makeRequest(this.requestArgs,this.spec,{[o?"ending_before":"starting_after"]:n})}},gy=class extends hp{static{s(this,"V1SearchIterator")}getNextPage(t){if(!t.next_page)throw Error("Unexpected: Stripe API response does not have a well-formed `next_page` field, but `has_more` was true.");return this.stripeResource._makeRequest(this.requestArgs,this.spec,{page:t.next_page})}},vy=class{static{s(this,"V2ListIterator")}constructor(t,o,n,r){this.currentPageIterator=(async()=>(await t).data[Symbol.iterator]())(),this.nextPageUrl=(async()=>(await t).next_page_url||null)(),this.requestArgs=o,this.spec=n,this.stripeResource=r}async turnPage(){let t=await this.nextPageUrl;if(!t)return null;this.spec.fullPath=t;let o=await this.stripeResource._makeRequest([],this.spec,{});return this.nextPageUrl=Promise.resolve(o.next_page_url),this.currentPageIterator=Promise.resolve(o.data[Symbol.iterator]()),this.currentPageIterator}async next(){{let n=(await this.currentPageIterator).next();if(!n.done)return{done:!1,value:n.value}}let t=await this.turnPage();if(!t)return{done:!0,value:void 0};let o=t.next();return o.done?{done:!0,value:void 0}:{done:!1,value:o.value}}},PT=s((e,t,o,n)=>{let r=Vo(o.fullPath||o.path);return r!=="v2"&&o.methodType==="search"?hy(new gy(n,t,o,e)):r!=="v2"&&o.methodType==="list"?hy(new yy(n,t,o,e)):r==="v2"&&o.methodType==="list"?hy(new vy(n,t,o,e)):null},"makeAutoPaginationMethods"),hy=s(e=>{let t=c0((...r)=>e.next(...r)),o=u0(t),n={autoPagingEach:t,autoPagingToArray:o,next:s(()=>e.next(),"next"),return:s(()=>({}),"return"),[n0()]:()=>n};return n},"makeAutoPaginationMethodsFromIterator");function n0(){return typeof Symbol<"u"&&Symbol.asyncIterator?Symbol.asyncIterator:"@@asyncIterator"}s(n0,"getAsyncIteratorSymbol");function i0(e){if(e.length<2)return null;let t=e[1];if(typeof t!="function")throw Error(`The second argument to autoPagingEach, if present, must be a callback function; received ${typeof t}`);return t}s(i0,"getDoneCallback");function a0(e){if(e.length===0)return;let t=e[0];if(typeof t!="function")throw Error(`The first argument to autoPagingEach, if present, must be a callback function; received ${typeof t}`);if(t.length===2)return t;if(t.length>2)throw Error(`The \`onItem\` callback function passed to autoPagingEach must accept at most two arguments; got ${t}`);return s(function(n,r){let i=t(n);r(i)},"_onItem")}s(a0,"getItemCallback");function s0(e,t){let o=t?0:e.data.length-1,n=e.data[o],r=n&&n.id;if(!r)throw Error("Unexpected: No `id` found on the last item while auto-paging a list.");return r}s(s0,"getLastId");function c0(e){return s(function(){let o=[].slice.call(arguments),n=a0(o),r=i0(o);if(o.length>2)throw Error(`autoPagingEach takes up to two arguments; received ${o}`);let i=p0(e,n);return ma(i,r)},"autoPagingEach")}s(c0,"makeAutoPagingEach");function u0(e){return s(function(o,n){let r=o&&o.limit;if(!r)throw Error("You must pass a `limit` option to autoPagingToArray, e.g., `autoPagingToArray({limit: 1000});`.");if(r>1e4)throw Error("You cannot specify a limit of more than 10,000 items to fetch in `autoPagingToArray`; use `autoPagingEach` to iterate through longer lists.");let i=new Promise((a,c)=>{let p=[];e(m=>{if(p.push(m),p.length>=r)return!1}).then(()=>{a(p)}).catch(c)});return ma(i,n)},"autoPagingToArray")}s(u0,"makeAutoPagingToArray");function p0(e,t){return new Promise((o,n)=>{function r(i){if(i.done){o();return}let a=i.value;return new Promise(c=>{t(a,c)}).then(c=>c===!1?r({done:!0,value:void 0}):e().then(r))}s(r,"handleIteration"),e().then(r).catch(n)})}s(p0,"wrapAsyncIteratorWithCallback");function xT(e){let t=[].slice.call(e);return!!Zo(t).ending_before}s(xT,"isReverseIteration");function ST(e){if(e.path!==void 0&&e.fullPath!==void 0)throw new Error(`Method spec specified both a 'path' (${e.path}) and a 'fullPath' (${e.fullPath}).`);return function(...t){let o=typeof t[t.length-1]=="function"&&t.pop();e.urlParams=pT(e.fullPath||this.createResourcePathWithSymbols(e.path||""));let n=ma(this._makeRequest(t,e,{}),o);return Object.assign(n,PT(this,t,e,n)),n}}s(ST,"stripeMethod");d.extend=lT;d.method=ST;d.MAX_BUFFERED_REQUEST_METRICS=100;function d(e,t){if(this._stripe=e,t)throw new Error("Support for curried url params was dropped in stripe-node v7.0.0. Instead, pass two ids.");this.basePath=Qu(this.basePath||e.getApiField("basePath")),this.resourcePath=this.path,this.path=Qu(this.path),this.initialize(...arguments)}s(d,"StripeResource");d.prototype={_stripe:null,path:"",resourcePath:"",basePath:null,initialize(){},requestDataProcessor:null,validateRequest:null,createFullPath(e,t){let o=[this.basePath(t),this.path(t)];if(typeof e=="function"){let n=e(t);n&&o.push(n)}else o.push(e);return this._joinUrlParts(o)},createResourcePathWithSymbols(e){return e?`/${this._joinUrlParts([this.resourcePath,e])}`:`/${this.resourcePath}`},_joinUrlParts(e){return e.join("/").replace(/\/{2,}/g,"/")},_getRequestOpts(e,t,o){var n;let r=(t.method||"GET").toUpperCase(),i=t.usage||[],a=t.urlParams||[],c=t.encode||(Pe=>Pe),p=!!t.fullPath,m=Qu(p?t.fullPath:t.path||""),l=p?t.fullPath:this.createResourcePathWithSymbols(t.path),g=[].slice.call(e),h=a.reduce((Pe,he)=>{let pe=g.shift();if(typeof pe!="string")throw new Error(`Stripe: Argument "${he}" must be a string, but got: ${pe} (on API request to \`${r} ${l}\`)`);return Pe[he]=pe,Pe},{}),f=Zo(g),v=c(Object.assign({},f,o)),I=ep(g),T=I.host||t.host,x=!!t.streaming||!!I.streaming;if(g.filter(Pe=>Pe!=null).length)throw new Error(`Stripe: Unknown arguments (${g}). Did you mean to pass an options object? See https://github.com/stripe/stripe-node/wiki/Passing-Options. (on API request to ${r} \`${l}\`)`);let k=p?m(h):this.createFullPath(m,h),R=Object.assign(I.headers,t.headers);t.validator&&t.validator(v,{headers:R});let q=t.method==="GET"||t.method==="DELETE";return{requestMethod:r,requestPath:k,bodyData:q?null:v,queryData:q?v:{},authenticator:(n=I.authenticator)!==null&&n!==void 0?n:null,headers:R,host:T??null,streaming:x,settings:I.settings,usage:i}},_makeRequest(e,t,o){return new Promise((n,r)=>{var i;let a;try{a=this._getRequestOpts(e,t,o)}catch(h){r(h);return}function c(h,f){h?r(h):n(t.transformResponseData?t.transformResponseData(f):f)}s(c,"requestCallback");let p=Object.keys(a.queryData).length===0,m=[a.requestPath,p?"":"?",lr(a.queryData,Vo(a.requestPath))].join(""),{headers:l,settings:g}=a;this._stripe._requestSender._request(a.requestMethod,a.host,m,a.bodyData,a.authenticator,{headers:l,settings:g,streaming:a.streaming},a.usage,c,(i=this.requestDataProcessor)===null||i===void 0?void 0:i.bind(this))})}};function TT(e){let t={DEFAULT_TOLERANCE:300,signature:null,constructEvent(l,g,h,f,v,I){try{if(!this.signature)throw new Error("ERR: missing signature helper, unable to verify");this.signature.verifyHeader(l,g,h,f||t.DEFAULT_TOLERANCE,v,I)}catch(x){throw x instanceof qo&&(x.message+="\nUse `await constructEventAsync(...)` instead of `constructEvent(...)`"),x}return l instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(l)):JSON.parse(l)},async constructEventAsync(l,g,h,f,v,I){if(!this.signature)throw new Error("ERR: missing signature helper, unable to verify");return await this.signature.verifyHeaderAsync(l,g,h,f||t.DEFAULT_TOLERANCE,v,I),l instanceof Uint8Array?JSON.parse(new TextDecoder("utf8").decode(l)):JSON.parse(l)},generateTestHeaderString:s(function(l){let g=m(l),h=g.signature||g.cryptoProvider.computeHMACSignature(g.payloadString,g.secret);return g.generateHeaderString(h)},"generateTestHeaderString"),generateTestHeaderStringAsync:s(async function(l){let g=m(l),h=g.signature||await g.cryptoProvider.computeHMACSignatureAsync(g.payloadString,g.secret);return g.generateHeaderString(h)},"generateTestHeaderStringAsync")},o={EXPECTED_SCHEME:"v1",verifyHeader(l,g,h,f,v,I){let{decodedHeader:T,decodedPayload:x,details:k,suspectPayloadType:R}=r(l,g,this.EXPECTED_SCHEME),q=/\s/.test(h);v=v||p();let Q=v.computeHMACSignature(n(x,k),h);return i(x,T,k,Q,f,R,q,I),!0},async verifyHeaderAsync(l,g,h,f,v,I){let{decodedHeader:T,decodedPayload:x,details:k,suspectPayloadType:R}=r(l,g,this.EXPECTED_SCHEME),q=/\s/.test(h);v=v||p();let Q=await v.computeHMACSignatureAsync(n(x,k),h);return i(x,T,k,Q,f,R,q,I)}};function n(l,g){return`${g.timestamp}.${l}`}s(n,"makeHMACContent");function r(l,g,h){if(!l)throw new yt(g,l,{message:"No webhook payload was provided."});let f=typeof l!="string"&&!(l instanceof Uint8Array),v=new TextDecoder("utf8"),I=l instanceof Uint8Array?v.decode(l):l;if(Array.isArray(g))throw new Error("Unexpected: An array was passed as a header, which should not be possible for the stripe-signature header.");if(g==null||g=="")throw new yt(g,l,{message:"No stripe-signature header value was provided."});let T=g instanceof Uint8Array?v.decode(g):g,x=a(T,h);if(!x||x.timestamp===-1)throw new yt(T,I,{message:"Unable to extract timestamp and signatures from header"});if(!x.signatures.length)throw new yt(T,I,{message:"No signatures found with expected scheme"});return{decodedPayload:I,decodedHeader:T,details:x,suspectPayloadType:f}}s(r,"parseEventDetails");function i(l,g,h,f,v,I,T,x){let k=!!h.signatures.filter(e.secureCompare.bind(e,f)).length,R=`
|
|
45
|
+
Learn more about webhook signing and explore webhook integration examples for various frameworks at https://docs.stripe.com/webhooks/signature`,q=T?`
|
|
46
|
+
|
|
47
|
+
Note: The provided signing secret contains whitespace. This often indicates an extra newline or space is in the value`:"";if(!k)throw I?new yt(g,l,{message:`Webhook payload must be provided as a string or a Buffer (https://nodejs.org/api/buffer.html) instance representing the _raw_ request body.Payload was provided as a parsed JavaScript object instead.
|
|
10
48
|
Signature verification is impossible without access to the original signed material.
|
|
11
|
-
`+
|
|
12
|
-
`+
|
|
49
|
+
`+R+`
|
|
50
|
+
`+q}):new yt(g,l,{message:`No signatures found matching the expected signature for payload. Are you passing the raw request body you received from Stripe?
|
|
13
51
|
If a webhook request is being forwarded by a third-party tool, ensure that the exact request body, including JSON formatting and new line style, is preserved.
|
|
14
|
-
`+
|
|
15
|
-
`+G});let Y=Math.floor((typeof T=="number"?T:Date.now())/1e3)-h.timestamp;if(y>0&&Y>y)throw new Fe(P,m,{message:"Timestamp outside the tolerance zone"});return!0}a(i,"validateComputedSignature");function s(m,P){return typeof m!="string"?null:m.split(",").reduce((h,d)=>{let y=d.split("=");return y[0]==="t"&&(h.timestamp=parseInt(y[1],10)),y[0]===P&&h.signatures.push(y[1]),h},{timestamp:-1,signatures:[]})}a(s,"parseHeader");let l=null;function f(){return l||(l=e.createDefaultCryptoProvider()),l}a(f,"getCryptoProvider");function b(m){if(!m)throw new pe({message:"Options are required"});let P=Math.floor(m.timestamp)||Math.floor(Date.now()/1e3),h=m.scheme||r.EXPECTED_SCHEME,d=m.cryptoProvider||f(),y=`${P}.${m.payload}`,I=a(S=>`t=${P},${h}=${S}`,"generateHeaderString");return Object.assign(Object.assign({},m),{timestamp:P,scheme:h,cryptoProvider:d,payloadString:y,generateHeaderString:I})}return a(b,"prepareOptions"),t.signature=r,t}a(Pf,"createWebhooks");var xf="2025-05-28.basil";var wr={};Mn(wr,{Account:()=>Ns,AccountLinks:()=>iy,AccountSessions:()=>ay,Accounts:()=>Ns,ApplePayDomains:()=>sy,ApplicationFees:()=>uy,Apps:()=>EI,Balance:()=>cy,BalanceTransactions:()=>py,Billing:()=>II,BillingPortal:()=>AI,Charges:()=>dy,Checkout:()=>wI,Climate:()=>kI,ConfirmationTokens:()=>my,CountrySpecs:()=>hy,Coupons:()=>yy,CreditNotes:()=>gy,CustomerSessions:()=>vy,Customers:()=>_y,Disputes:()=>by,Entitlements:()=>RI,EphemeralKeys:()=>xy,Events:()=>Ty,ExchangeRates:()=>Iy,FileLinks:()=>Ay,Files:()=>ky,FinancialConnections:()=>OI,Forwarding:()=>CI,Identity:()=>$I,InvoiceItems:()=>Ry,InvoicePayments:()=>Cy,InvoiceRenderingTemplates:()=>$y,Invoices:()=>Ny,Issuing:()=>NI,Mandates:()=>Dy,OAuth:()=>My,PaymentIntents:()=>Uy,PaymentLinks:()=>Ly,PaymentMethodConfigurations:()=>qy,PaymentMethodDomains:()=>jy,PaymentMethods:()=>Fy,Payouts:()=>By,Plans:()=>Gy,Prices:()=>Vy,Products:()=>Hy,PromotionCodes:()=>Zy,Quotes:()=>Wy,Radar:()=>DI,Refunds:()=>Ky,Reporting:()=>zI,Reviews:()=>Jy,SetupAttempts:()=>Xy,SetupIntents:()=>Yy,ShippingRates:()=>Qy,Sigma:()=>MI,Sources:()=>eg,SubscriptionItems:()=>tg,SubscriptionSchedules:()=>rg,Subscriptions:()=>ng,Tax:()=>UI,TaxCodes:()=>ig,TaxIds:()=>ag,TaxRates:()=>sg,Terminal:()=>LI,TestHelpers:()=>qI,Tokens:()=>cg,Topups:()=>lg,Transfers:()=>pg,Treasury:()=>jI,V2:()=>FI,WebhookEndpoints:()=>dg});function rI(e,t){for(let r in t){if(!Object.prototype.hasOwnProperty.call(t,r))continue;let n=r[0].toLowerCase()+r.substring(1),o=new t[r](e);this[n]=o}}a(rI,"ResourceNamespace");function oe(e,t){return function(r){return new rI(r,t)}}a(oe,"resourceNamespace");var Lt=c.method,Sf=c.extend({retrieve:Lt({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}"}),list:Lt({method:"GET",fullPath:"/v1/financial_connections/accounts",methodType:"list"}),disconnect:Lt({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/disconnect"}),listOwners:Lt({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}/owners",methodType:"list"}),refresh:Lt({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/refresh"}),subscribe:Lt({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/subscribe"}),unsubscribe:Lt({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/unsubscribe"})});var Tf=c.method,Ef=c.extend({retrieve:Tf({method:"GET",fullPath:"/v1/entitlements/active_entitlements/{id}"}),list:Tf({method:"GET",fullPath:"/v1/entitlements/active_entitlements",methodType:"list"})});var _r=c.method,If=c.extend({create:_r({method:"POST",fullPath:"/v1/billing/alerts"}),retrieve:_r({method:"GET",fullPath:"/v1/billing/alerts/{id}"}),list:_r({method:"GET",fullPath:"/v1/billing/alerts",methodType:"list"}),activate:_r({method:"POST",fullPath:"/v1/billing/alerts/{id}/activate"}),archive:_r({method:"POST",fullPath:"/v1/billing/alerts/{id}/archive"}),deactivate:_r({method:"POST",fullPath:"/v1/billing/alerts/{id}/deactivate"})});var qt=c.method,Af=c.extend({create:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations"}),capture:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/capture"}),expire:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/expire"}),finalizeAmount:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/finalize_amount"}),increment:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/increment"}),respond:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/fraud_challenges/respond"}),reverse:qt({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/reverse"})});var vn=c.method,wf=c.extend({retrieve:vn({method:"GET",fullPath:"/v1/issuing/authorizations/{authorization}"}),update:vn({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}"}),list:vn({method:"GET",fullPath:"/v1/issuing/authorizations",methodType:"list"}),approve:vn({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/approve"}),decline:vn({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/decline"})});var xs=c.method,kf=c.extend({create:xs({method:"POST",fullPath:"/v1/tax/calculations"}),retrieve:xs({method:"GET",fullPath:"/v1/tax/calculations/{calculation}"}),listLineItems:xs({method:"GET",fullPath:"/v1/tax/calculations/{calculation}/line_items",methodType:"list"})});var ti=c.method,Rf=c.extend({create:ti({method:"POST",fullPath:"/v1/issuing/cardholders"}),retrieve:ti({method:"GET",fullPath:"/v1/issuing/cardholders/{cardholder}"}),update:ti({method:"POST",fullPath:"/v1/issuing/cardholders/{cardholder}"}),list:ti({method:"GET",fullPath:"/v1/issuing/cardholders",methodType:"list"})});var _n=c.method,Of=c.extend({deliverCard:_n({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/deliver"}),failCard:_n({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/fail"}),returnCard:_n({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/return"}),shipCard:_n({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/ship"}),submitCard:_n({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/submit"})});var ri=c.method,Cf=c.extend({create:ri({method:"POST",fullPath:"/v1/issuing/cards"}),retrieve:ri({method:"GET",fullPath:"/v1/issuing/cards/{card}"}),update:ri({method:"POST",fullPath:"/v1/issuing/cards/{card}"}),list:ri({method:"GET",fullPath:"/v1/issuing/cards",methodType:"list"})});var ni=c.method,$f=c.extend({create:ni({method:"POST",fullPath:"/v1/billing_portal/configurations"}),retrieve:ni({method:"GET",fullPath:"/v1/billing_portal/configurations/{configuration}"}),update:ni({method:"POST",fullPath:"/v1/billing_portal/configurations/{configuration}"}),list:ni({method:"GET",fullPath:"/v1/billing_portal/configurations",methodType:"list"})});var bn=c.method,Nf=c.extend({create:bn({method:"POST",fullPath:"/v1/terminal/configurations"}),retrieve:bn({method:"GET",fullPath:"/v1/terminal/configurations/{configuration}"}),update:bn({method:"POST",fullPath:"/v1/terminal/configurations/{configuration}"}),list:bn({method:"GET",fullPath:"/v1/terminal/configurations",methodType:"list"}),del:bn({method:"DELETE",fullPath:"/v1/terminal/configurations/{configuration}"})});var nI=c.method,Df=c.extend({create:nI({method:"POST",fullPath:"/v1/test_helpers/confirmation_tokens"})});var oI=c.method,zf=c.extend({create:oI({method:"POST",fullPath:"/v1/terminal/connection_tokens"})});var iI=c.method,Mf=c.extend({retrieve:iI({method:"GET",fullPath:"/v1/billing/credit_balance_summary"})});var Uf=c.method,Lf=c.extend({retrieve:Uf({method:"GET",fullPath:"/v1/billing/credit_balance_transactions/{id}"}),list:Uf({method:"GET",fullPath:"/v1/billing/credit_balance_transactions",methodType:"list"})});var br=c.method,qf=c.extend({create:br({method:"POST",fullPath:"/v1/billing/credit_grants"}),retrieve:br({method:"GET",fullPath:"/v1/billing/credit_grants/{id}"}),update:br({method:"POST",fullPath:"/v1/billing/credit_grants/{id}"}),list:br({method:"GET",fullPath:"/v1/billing/credit_grants",methodType:"list"}),expire:br({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/expire"}),voidGrant:br({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/void"})});var Ss=c.method,jf=c.extend({create:Ss({method:"POST",fullPath:"/v1/treasury/credit_reversals"}),retrieve:Ss({method:"GET",fullPath:"/v1/treasury/credit_reversals/{credit_reversal}"}),list:Ss({method:"GET",fullPath:"/v1/treasury/credit_reversals",methodType:"list"})});var aI=c.method,Ff=c.extend({fundCashBalance:aI({method:"POST",fullPath:"/v1/test_helpers/customers/{customer}/fund_cash_balance"})});var Ts=c.method,Bf=c.extend({create:Ts({method:"POST",fullPath:"/v1/treasury/debit_reversals"}),retrieve:Ts({method:"GET",fullPath:"/v1/treasury/debit_reversals/{debit_reversal}"}),list:Ts({method:"GET",fullPath:"/v1/treasury/debit_reversals",methodType:"list"})});var Pn=c.method,Gf=c.extend({create:Pn({method:"POST",fullPath:"/v1/issuing/disputes"}),retrieve:Pn({method:"GET",fullPath:"/v1/issuing/disputes/{dispute}"}),update:Pn({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}"}),list:Pn({method:"GET",fullPath:"/v1/issuing/disputes",methodType:"list"}),submit:Pn({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}/submit"})});var Vf=c.method,Hf=c.extend({retrieve:Vf({method:"GET",fullPath:"/v1/radar/early_fraud_warnings/{early_fraud_warning}"}),list:Vf({method:"GET",fullPath:"/v1/radar/early_fraud_warnings",methodType:"list"})});var kt=c.method,Zf=c.extend({create:kt({method:"POST",fullPath:"/v2/core/event_destinations"}),retrieve:kt({method:"GET",fullPath:"/v2/core/event_destinations/{id}"}),update:kt({method:"POST",fullPath:"/v2/core/event_destinations/{id}"}),list:kt({method:"GET",fullPath:"/v2/core/event_destinations",methodType:"list"}),del:kt({method:"DELETE",fullPath:"/v2/core/event_destinations/{id}"}),disable:kt({method:"POST",fullPath:"/v2/core/event_destinations/{id}/disable"}),enable:kt({method:"POST",fullPath:"/v2/core/event_destinations/{id}/enable"}),ping:kt({method:"POST",fullPath:"/v2/core/event_destinations/{id}/ping"})});var Es=c.method,Wf=c.extend({retrieve(...e){return Es({method:"GET",fullPath:"/v2/core/events/{id}",transformResponseData:a(r=>this.addFetchRelatedObjectIfNeeded(r),"transformResponseData")}).apply(this,e)},list(...e){return Es({method:"GET",fullPath:"/v2/core/events",methodType:"list",transformResponseData:a(r=>Object.assign(Object.assign({},r),{data:r.data.map(this.addFetchRelatedObjectIfNeeded.bind(this))}),"transformResponseData")}).apply(this,e)},addFetchRelatedObjectIfNeeded(e){return!e.related_object||!e.related_object.url?e:Object.assign(Object.assign({},e),{fetchRelatedObject:a(()=>Es({method:"GET",fullPath:e.related_object.url}).apply(this,[{stripeAccount:e.context}]),"fetchRelatedObject")})}});var oi=c.method,Kf=c.extend({create:oi({method:"POST",fullPath:"/v1/entitlements/features"}),retrieve:oi({method:"GET",fullPath:"/v1/entitlements/features/{id}"}),update:oi({method:"POST",fullPath:"/v1/entitlements/features/{id}"}),list:oi({method:"GET",fullPath:"/v1/entitlements/features",methodType:"list"})});var jt=c.method,Jf=c.extend({create:jt({method:"POST",fullPath:"/v1/treasury/financial_accounts"}),retrieve:jt({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),update:jt({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),list:jt({method:"GET",fullPath:"/v1/treasury/financial_accounts",methodType:"list"}),close:jt({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/close"}),retrieveFeatures:jt({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"}),updateFeatures:jt({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"})});var Is=c.method,Xf=c.extend({fail:Is({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/fail"}),returnInboundTransfer:Is({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/return"}),succeed:Is({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/succeed"})});var ii=c.method,Yf=c.extend({create:ii({method:"POST",fullPath:"/v1/treasury/inbound_transfers"}),retrieve:ii({method:"GET",fullPath:"/v1/treasury/inbound_transfers/{id}"}),list:ii({method:"GET",fullPath:"/v1/treasury/inbound_transfers",methodType:"list"}),cancel:ii({method:"POST",fullPath:"/v1/treasury/inbound_transfers/{inbound_transfer}/cancel"})});var xn=c.method,Qf=c.extend({create:xn({method:"POST",fullPath:"/v1/terminal/locations"}),retrieve:xn({method:"GET",fullPath:"/v1/terminal/locations/{location}"}),update:xn({method:"POST",fullPath:"/v1/terminal/locations/{location}"}),list:xn({method:"GET",fullPath:"/v1/terminal/locations",methodType:"list"}),del:xn({method:"DELETE",fullPath:"/v1/terminal/locations/{location}"})});var sI=c.method,eh=c.extend({create:sI({method:"POST",fullPath:"/v1/billing/meter_event_adjustments"})});var uI=c.method,th=c.extend({create:uI({method:"POST",fullPath:"/v2/billing/meter_event_adjustments"})});var cI=c.method,rh=c.extend({create:cI({method:"POST",fullPath:"/v2/billing/meter_event_session"})});var lI=c.method,nh=c.extend({create:lI({method:"POST",fullPath:"/v2/billing/meter_event_stream",host:"meter-events.stripe.com"})});var pI=c.method,oh=c.extend({create:pI({method:"POST",fullPath:"/v1/billing/meter_events"})});var dI=c.method,ih=c.extend({create:dI({method:"POST",fullPath:"/v2/billing/meter_events"})});var Ft=c.method,ah=c.extend({create:Ft({method:"POST",fullPath:"/v1/billing/meters"}),retrieve:Ft({method:"GET",fullPath:"/v1/billing/meters/{id}"}),update:Ft({method:"POST",fullPath:"/v1/billing/meters/{id}"}),list:Ft({method:"GET",fullPath:"/v1/billing/meters",methodType:"list"}),deactivate:Ft({method:"POST",fullPath:"/v1/billing/meters/{id}/deactivate"}),listEventSummaries:Ft({method:"GET",fullPath:"/v1/billing/meters/{id}/event_summaries",methodType:"list"}),reactivate:Ft({method:"POST",fullPath:"/v1/billing/meters/{id}/reactivate"})});var Sn=c.method,sh=c.extend({create:Sn({method:"POST",fullPath:"/v1/climate/orders"}),retrieve:Sn({method:"GET",fullPath:"/v1/climate/orders/{order}"}),update:Sn({method:"POST",fullPath:"/v1/climate/orders/{order}"}),list:Sn({method:"GET",fullPath:"/v1/climate/orders",methodType:"list"}),cancel:Sn({method:"POST",fullPath:"/v1/climate/orders/{order}/cancel"})});var ai=c.method,uh=c.extend({update:ai({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}"}),fail:ai({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/fail"}),post:ai({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/post"}),returnOutboundPayment:ai({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/return"})});var si=c.method,ch=c.extend({create:si({method:"POST",fullPath:"/v1/treasury/outbound_payments"}),retrieve:si({method:"GET",fullPath:"/v1/treasury/outbound_payments/{id}"}),list:si({method:"GET",fullPath:"/v1/treasury/outbound_payments",methodType:"list"}),cancel:si({method:"POST",fullPath:"/v1/treasury/outbound_payments/{id}/cancel"})});var ui=c.method,lh=c.extend({update:ui({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}"}),fail:ui({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail"}),post:ui({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post"}),returnOutboundTransfer:ui({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return"})});var ci=c.method,ph=c.extend({create:ci({method:"POST",fullPath:"/v1/treasury/outbound_transfers"}),retrieve:ci({method:"GET",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}"}),list:ci({method:"GET",fullPath:"/v1/treasury/outbound_transfers",methodType:"list"}),cancel:ci({method:"POST",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}/cancel"})});var As=c.method,dh=c.extend({activate:As({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/activate"}),deactivate:As({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/deactivate"}),reject:As({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/reject"})});var li=c.method,mh=c.extend({create:li({method:"POST",fullPath:"/v1/issuing/personalization_designs"}),retrieve:li({method:"GET",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),update:li({method:"POST",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),list:li({method:"GET",fullPath:"/v1/issuing/personalization_designs",methodType:"list"})});var fh=c.method,hh=c.extend({retrieve:fh({method:"GET",fullPath:"/v1/issuing/physical_bundles/{physical_bundle}"}),list:fh({method:"GET",fullPath:"/v1/issuing/physical_bundles",methodType:"list"})});var yh=c.method,gh=c.extend({retrieve:yh({method:"GET",fullPath:"/v1/climate/products/{product}"}),list:yh({method:"GET",fullPath:"/v1/climate/products",methodType:"list"})});var ws=c.method,vh=c.extend({presentPaymentMethod:ws({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/present_payment_method"}),succeedInputCollection:ws({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/succeed_input_collection"}),timeoutInputCollection:ws({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/timeout_input_collection"})});var Be=c.method,_h=c.extend({create:Be({method:"POST",fullPath:"/v1/terminal/readers"}),retrieve:Be({method:"GET",fullPath:"/v1/terminal/readers/{reader}"}),update:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}"}),list:Be({method:"GET",fullPath:"/v1/terminal/readers",methodType:"list"}),del:Be({method:"DELETE",fullPath:"/v1/terminal/readers/{reader}"}),cancelAction:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/cancel_action"}),collectInputs:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_inputs"}),processPaymentIntent:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_payment_intent"}),processSetupIntent:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_setup_intent"}),refundPayment:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/refund_payment"}),setReaderDisplay:Be({method:"POST",fullPath:"/v1/terminal/readers/{reader}/set_reader_display"})});var mI=c.method,bh=c.extend({create:mI({method:"POST",fullPath:"/v1/test_helpers/treasury/received_credits"})});var Ph=c.method,xh=c.extend({retrieve:Ph({method:"GET",fullPath:"/v1/treasury/received_credits/{id}"}),list:Ph({method:"GET",fullPath:"/v1/treasury/received_credits",methodType:"list"})});var fI=c.method,Sh=c.extend({create:fI({method:"POST",fullPath:"/v1/test_helpers/treasury/received_debits"})});var Th=c.method,Eh=c.extend({retrieve:Th({method:"GET",fullPath:"/v1/treasury/received_debits/{id}"}),list:Th({method:"GET",fullPath:"/v1/treasury/received_debits",methodType:"list"})});var hI=c.method,Ih=c.extend({expire:hI({method:"POST",fullPath:"/v1/test_helpers/refunds/{refund}/expire"})});var pi=c.method,Ah=c.extend({create:pi({method:"POST",fullPath:"/v1/tax/registrations"}),retrieve:pi({method:"GET",fullPath:"/v1/tax/registrations/{id}"}),update:pi({method:"POST",fullPath:"/v1/tax/registrations/{id}"}),list:pi({method:"GET",fullPath:"/v1/tax/registrations",methodType:"list"})});var ks=c.method,wh=c.extend({create:ks({method:"POST",fullPath:"/v1/reporting/report_runs"}),retrieve:ks({method:"GET",fullPath:"/v1/reporting/report_runs/{report_run}"}),list:ks({method:"GET",fullPath:"/v1/reporting/report_runs",methodType:"list"})});var kh=c.method,Rh=c.extend({retrieve:kh({method:"GET",fullPath:"/v1/reporting/report_types/{report_type}"}),list:kh({method:"GET",fullPath:"/v1/reporting/report_types",methodType:"list"})});var Rs=c.method,Oh=c.extend({create:Rs({method:"POST",fullPath:"/v1/forwarding/requests"}),retrieve:Rs({method:"GET",fullPath:"/v1/forwarding/requests/{id}"}),list:Rs({method:"GET",fullPath:"/v1/forwarding/requests",methodType:"list"})});var Ch=c.method,$h=c.extend({retrieve:Ch({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs/{scheduled_query_run}"}),list:Ch({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs",methodType:"list"})});var di=c.method,Nh=c.extend({create:di({method:"POST",fullPath:"/v1/apps/secrets"}),list:di({method:"GET",fullPath:"/v1/apps/secrets",methodType:"list"}),deleteWhere:di({method:"POST",fullPath:"/v1/apps/secrets/delete"}),find:di({method:"GET",fullPath:"/v1/apps/secrets/find"})});var yI=c.method,Dh=c.extend({create:yI({method:"POST",fullPath:"/v1/billing_portal/sessions"})});var Pr=c.method,zh=c.extend({create:Pr({method:"POST",fullPath:"/v1/checkout/sessions"}),retrieve:Pr({method:"GET",fullPath:"/v1/checkout/sessions/{session}"}),update:Pr({method:"POST",fullPath:"/v1/checkout/sessions/{session}"}),list:Pr({method:"GET",fullPath:"/v1/checkout/sessions",methodType:"list"}),expire:Pr({method:"POST",fullPath:"/v1/checkout/sessions/{session}/expire"}),listLineItems:Pr({method:"GET",fullPath:"/v1/checkout/sessions/{session}/line_items",methodType:"list"})});var Mh=c.method,Uh=c.extend({create:Mh({method:"POST",fullPath:"/v1/financial_connections/sessions"}),retrieve:Mh({method:"GET",fullPath:"/v1/financial_connections/sessions/{session}"})});var Lh=c.method,qh=c.extend({retrieve:Lh({method:"GET",fullPath:"/v1/tax/settings"}),update:Lh({method:"POST",fullPath:"/v1/tax/settings"})});var jh=c.method,Fh=c.extend({retrieve:jh({method:"GET",fullPath:"/v1/climate/suppliers/{supplier}"}),list:jh({method:"GET",fullPath:"/v1/climate/suppliers",methodType:"list"})});var Tn=c.method,Bh=c.extend({create:Tn({method:"POST",fullPath:"/v1/test_helpers/test_clocks"}),retrieve:Tn({method:"GET",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),list:Tn({method:"GET",fullPath:"/v1/test_helpers/test_clocks",methodType:"list"}),del:Tn({method:"DELETE",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),advance:Tn({method:"POST",fullPath:"/v1/test_helpers/test_clocks/{test_clock}/advance"})});var Os=c.method,Gh=c.extend({retrieve:Os({method:"GET",fullPath:"/v1/issuing/tokens/{token}"}),update:Os({method:"POST",fullPath:"/v1/issuing/tokens/{token}"}),list:Os({method:"GET",fullPath:"/v1/issuing/tokens",methodType:"list"})});var Vh=c.method,Hh=c.extend({retrieve:Vh({method:"GET",fullPath:"/v1/treasury/transaction_entries/{id}"}),list:Vh({method:"GET",fullPath:"/v1/treasury/transaction_entries",methodType:"list"})});var Cs=c.method,Zh=c.extend({createForceCapture:Cs({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_force_capture"}),createUnlinkedRefund:Cs({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_unlinked_refund"}),refund:Cs({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/{transaction}/refund"})});var Wh=c.method,Kh=c.extend({retrieve:Wh({method:"GET",fullPath:"/v1/financial_connections/transactions/{transaction}"}),list:Wh({method:"GET",fullPath:"/v1/financial_connections/transactions",methodType:"list"})});var $s=c.method,Jh=c.extend({retrieve:$s({method:"GET",fullPath:"/v1/issuing/transactions/{transaction}"}),update:$s({method:"POST",fullPath:"/v1/issuing/transactions/{transaction}"}),list:$s({method:"GET",fullPath:"/v1/issuing/transactions",methodType:"list"})});var mi=c.method,Xh=c.extend({retrieve:mi({method:"GET",fullPath:"/v1/tax/transactions/{transaction}"}),createFromCalculation:mi({method:"POST",fullPath:"/v1/tax/transactions/create_from_calculation"}),createReversal:mi({method:"POST",fullPath:"/v1/tax/transactions/create_reversal"}),listLineItems:mi({method:"GET",fullPath:"/v1/tax/transactions/{transaction}/line_items",methodType:"list"})});var Yh=c.method,Qh=c.extend({retrieve:Yh({method:"GET",fullPath:"/v1/treasury/transactions/{id}"}),list:Yh({method:"GET",fullPath:"/v1/treasury/transactions",methodType:"list"})});var fi=c.method,ey=c.extend({create:fi({method:"POST",fullPath:"/v1/radar/value_list_items"}),retrieve:fi({method:"GET",fullPath:"/v1/radar/value_list_items/{item}"}),list:fi({method:"GET",fullPath:"/v1/radar/value_list_items",methodType:"list"}),del:fi({method:"DELETE",fullPath:"/v1/radar/value_list_items/{item}"})});var En=c.method,ty=c.extend({create:En({method:"POST",fullPath:"/v1/radar/value_lists"}),retrieve:En({method:"GET",fullPath:"/v1/radar/value_lists/{value_list}"}),update:En({method:"POST",fullPath:"/v1/radar/value_lists/{value_list}"}),list:En({method:"GET",fullPath:"/v1/radar/value_lists",methodType:"list"}),del:En({method:"DELETE",fullPath:"/v1/radar/value_lists/{value_list}"})});var ry=c.method,ny=c.extend({retrieve:ry({method:"GET",fullPath:"/v1/identity/verification_reports/{report}"}),list:ry({method:"GET",fullPath:"/v1/identity/verification_reports",methodType:"list"})});var xr=c.method,oy=c.extend({create:xr({method:"POST",fullPath:"/v1/identity/verification_sessions"}),retrieve:xr({method:"GET",fullPath:"/v1/identity/verification_sessions/{session}"}),update:xr({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}"}),list:xr({method:"GET",fullPath:"/v1/identity/verification_sessions",methodType:"list"}),cancel:xr({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/cancel"}),redact:xr({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/redact"})});var de=c.method,Ns=c.extend({create:de({method:"POST",fullPath:"/v1/accounts"}),retrieve(e,...t){return typeof e=="string"?de({method:"GET",fullPath:"/v1/accounts/{id}"}).apply(this,[e,...t]):(e==null&&[].shift.apply([e,...t]),de({method:"GET",fullPath:"/v1/account"}).apply(this,[e,...t]))},update:de({method:"POST",fullPath:"/v1/accounts/{account}"}),list:de({method:"GET",fullPath:"/v1/accounts",methodType:"list"}),del:de({method:"DELETE",fullPath:"/v1/accounts/{account}"}),createExternalAccount:de({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts"}),createLoginLink:de({method:"POST",fullPath:"/v1/accounts/{account}/login_links"}),createPerson:de({method:"POST",fullPath:"/v1/accounts/{account}/persons"}),deleteExternalAccount:de({method:"DELETE",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),deletePerson:de({method:"DELETE",fullPath:"/v1/accounts/{account}/persons/{person}"}),listCapabilities:de({method:"GET",fullPath:"/v1/accounts/{account}/capabilities",methodType:"list"}),listExternalAccounts:de({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts",methodType:"list"}),listPersons:de({method:"GET",fullPath:"/v1/accounts/{account}/persons",methodType:"list"}),reject:de({method:"POST",fullPath:"/v1/accounts/{account}/reject"}),retrieveCurrent:de({method:"GET",fullPath:"/v1/account"}),retrieveCapability:de({method:"GET",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),retrieveExternalAccount:de({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),retrievePerson:de({method:"GET",fullPath:"/v1/accounts/{account}/persons/{person}"}),updateCapability:de({method:"POST",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),updateExternalAccount:de({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),updatePerson:de({method:"POST",fullPath:"/v1/accounts/{account}/persons/{person}"})});var gI=c.method,iy=c.extend({create:gI({method:"POST",fullPath:"/v1/account_links"})});var vI=c.method,ay=c.extend({create:vI({method:"POST",fullPath:"/v1/account_sessions"})});var hi=c.method,sy=c.extend({create:hi({method:"POST",fullPath:"/v1/apple_pay/domains"}),retrieve:hi({method:"GET",fullPath:"/v1/apple_pay/domains/{domain}"}),list:hi({method:"GET",fullPath:"/v1/apple_pay/domains",methodType:"list"}),del:hi({method:"DELETE",fullPath:"/v1/apple_pay/domains/{domain}"})});var Sr=c.method,uy=c.extend({retrieve:Sr({method:"GET",fullPath:"/v1/application_fees/{id}"}),list:Sr({method:"GET",fullPath:"/v1/application_fees",methodType:"list"}),createRefund:Sr({method:"POST",fullPath:"/v1/application_fees/{id}/refunds"}),listRefunds:Sr({method:"GET",fullPath:"/v1/application_fees/{id}/refunds",methodType:"list"}),retrieveRefund:Sr({method:"GET",fullPath:"/v1/application_fees/{fee}/refunds/{id}"}),updateRefund:Sr({method:"POST",fullPath:"/v1/application_fees/{fee}/refunds/{id}"})});var _I=c.method,cy=c.extend({retrieve:_I({method:"GET",fullPath:"/v1/balance"})});var ly=c.method,py=c.extend({retrieve:ly({method:"GET",fullPath:"/v1/balance_transactions/{id}"}),list:ly({method:"GET",fullPath:"/v1/balance_transactions",methodType:"list"})});var Tr=c.method,dy=c.extend({create:Tr({method:"POST",fullPath:"/v1/charges"}),retrieve:Tr({method:"GET",fullPath:"/v1/charges/{charge}"}),update:Tr({method:"POST",fullPath:"/v1/charges/{charge}"}),list:Tr({method:"GET",fullPath:"/v1/charges",methodType:"list"}),capture:Tr({method:"POST",fullPath:"/v1/charges/{charge}/capture"}),search:Tr({method:"GET",fullPath:"/v1/charges/search",methodType:"search"})});var bI=c.method,my=c.extend({retrieve:bI({method:"GET",fullPath:"/v1/confirmation_tokens/{confirmation_token}"})});var fy=c.method,hy=c.extend({retrieve:fy({method:"GET",fullPath:"/v1/country_specs/{country}"}),list:fy({method:"GET",fullPath:"/v1/country_specs",methodType:"list"})});var In=c.method,yy=c.extend({create:In({method:"POST",fullPath:"/v1/coupons"}),retrieve:In({method:"GET",fullPath:"/v1/coupons/{coupon}"}),update:In({method:"POST",fullPath:"/v1/coupons/{coupon}"}),list:In({method:"GET",fullPath:"/v1/coupons",methodType:"list"}),del:In({method:"DELETE",fullPath:"/v1/coupons/{coupon}"})});var Rt=c.method,gy=c.extend({create:Rt({method:"POST",fullPath:"/v1/credit_notes"}),retrieve:Rt({method:"GET",fullPath:"/v1/credit_notes/{id}"}),update:Rt({method:"POST",fullPath:"/v1/credit_notes/{id}"}),list:Rt({method:"GET",fullPath:"/v1/credit_notes",methodType:"list"}),listLineItems:Rt({method:"GET",fullPath:"/v1/credit_notes/{credit_note}/lines",methodType:"list"}),listPreviewLineItems:Rt({method:"GET",fullPath:"/v1/credit_notes/preview/lines",methodType:"list"}),preview:Rt({method:"GET",fullPath:"/v1/credit_notes/preview"}),voidCreditNote:Rt({method:"POST",fullPath:"/v1/credit_notes/{id}/void"})});var PI=c.method,vy=c.extend({create:PI({method:"POST",fullPath:"/v1/customer_sessions"})});var Q=c.method,_y=c.extend({create:Q({method:"POST",fullPath:"/v1/customers"}),retrieve:Q({method:"GET",fullPath:"/v1/customers/{customer}"}),update:Q({method:"POST",fullPath:"/v1/customers/{customer}"}),list:Q({method:"GET",fullPath:"/v1/customers",methodType:"list"}),del:Q({method:"DELETE",fullPath:"/v1/customers/{customer}"}),createBalanceTransaction:Q({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions"}),createFundingInstructions:Q({method:"POST",fullPath:"/v1/customers/{customer}/funding_instructions"}),createSource:Q({method:"POST",fullPath:"/v1/customers/{customer}/sources"}),createTaxId:Q({method:"POST",fullPath:"/v1/customers/{customer}/tax_ids"}),deleteDiscount:Q({method:"DELETE",fullPath:"/v1/customers/{customer}/discount"}),deleteSource:Q({method:"DELETE",fullPath:"/v1/customers/{customer}/sources/{id}"}),deleteTaxId:Q({method:"DELETE",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),listBalanceTransactions:Q({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions",methodType:"list"}),listCashBalanceTransactions:Q({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions",methodType:"list"}),listPaymentMethods:Q({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods",methodType:"list"}),listSources:Q({method:"GET",fullPath:"/v1/customers/{customer}/sources",methodType:"list"}),listTaxIds:Q({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids",methodType:"list"}),retrieveBalanceTransaction:Q({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),retrieveCashBalance:Q({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance"}),retrieveCashBalanceTransaction:Q({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions/{transaction}"}),retrievePaymentMethod:Q({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods/{payment_method}"}),retrieveSource:Q({method:"GET",fullPath:"/v1/customers/{customer}/sources/{id}"}),retrieveTaxId:Q({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),search:Q({method:"GET",fullPath:"/v1/customers/search",methodType:"search"}),updateBalanceTransaction:Q({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),updateCashBalance:Q({method:"POST",fullPath:"/v1/customers/{customer}/cash_balance"}),updateSource:Q({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}"}),verifySource:Q({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}/verify"})});var yi=c.method,by=c.extend({retrieve:yi({method:"GET",fullPath:"/v1/disputes/{dispute}"}),update:yi({method:"POST",fullPath:"/v1/disputes/{dispute}"}),list:yi({method:"GET",fullPath:"/v1/disputes",methodType:"list"}),close:yi({method:"POST",fullPath:"/v1/disputes/{dispute}/close"})});var Py=c.method,xy=c.extend({create:Py({method:"POST",fullPath:"/v1/ephemeral_keys",validator:a((e,t)=>{if(!t.headers||!t.headers["Stripe-Version"])throw new Error("Passing apiVersion in a separate options hash is required to create an ephemeral key. See https://stripe.com/docs/api/versioning?lang=node")},"validator")}),del:Py({method:"DELETE",fullPath:"/v1/ephemeral_keys/{key}"})});var Sy=c.method,Ty=c.extend({retrieve:Sy({method:"GET",fullPath:"/v1/events/{id}"}),list:Sy({method:"GET",fullPath:"/v1/events",methodType:"list"})});var Ey=c.method,Iy=c.extend({retrieve:Ey({method:"GET",fullPath:"/v1/exchange_rates/{rate_id}"}),list:Ey({method:"GET",fullPath:"/v1/exchange_rates",methodType:"list"})});var gi=c.method,Ay=c.extend({create:gi({method:"POST",fullPath:"/v1/file_links"}),retrieve:gi({method:"GET",fullPath:"/v1/file_links/{link}"}),update:gi({method:"POST",fullPath:"/v1/file_links/{link}"}),list:gi({method:"GET",fullPath:"/v1/file_links",methodType:"list"})});var xI=a((e,t,r)=>{let n=(Math.round(Math.random()*1e16)+Math.round(Math.random()*1e16)).toString();r["Content-Type"]=`multipart/form-data; boundary=${n}`;let o=new TextEncoder,i=new Uint8Array(0),s=o.encode(`\r
|
|
16
|
-
`);function l(m){let P=i,h=m instanceof Uint8Array?m:new Uint8Array(o.encode(m));i=new Uint8Array(P.length+h.length+2),i.set(P),i.set(h,P.length),i.set(s,i.length-2)}a(l,"push");function f(m){return`"${m.replace(/"|"/g,"%22").replace(/\r\n|\r|\n/g," ")}"`}a(f,"q");let b=pf(t);for(let m in b){if(!Object.prototype.hasOwnProperty.call(b,m))continue;let P=b[m];if(l(`--${n}`),Object.prototype.hasOwnProperty.call(P,"data")){let h=P;l(`Content-Disposition: form-data; name=${f(m)}; filename=${f(h.name||"blob")}`),l(`Content-Type: ${h.type||"application/octet-stream"}`),l(""),l(h.data)}else l(`Content-Disposition: form-data; name=${f(m)}`),l(""),l(P)}return l(`--${n}--`),i},"multipartDataGenerator");function wy(e,t,r,n){if(t=t||{},e!=="POST")return n(null,wt(t));this._stripe._platformFunctions.tryBufferData(t).then(o=>{let i=xI(e,o,r);return n(null,i)}).catch(o=>n(o,null))}a(wy,"multipartRequestDataProcessor");var Ds=c.method,ky=c.extend({create:Ds({method:"POST",fullPath:"/v1/files",headers:{"Content-Type":"multipart/form-data"},host:"files.stripe.com"}),retrieve:Ds({method:"GET",fullPath:"/v1/files/{file}"}),list:Ds({method:"GET",fullPath:"/v1/files",methodType:"list"}),requestDataProcessor:wy});var An=c.method,Ry=c.extend({create:An({method:"POST",fullPath:"/v1/invoiceitems"}),retrieve:An({method:"GET",fullPath:"/v1/invoiceitems/{invoiceitem}"}),update:An({method:"POST",fullPath:"/v1/invoiceitems/{invoiceitem}"}),list:An({method:"GET",fullPath:"/v1/invoiceitems",methodType:"list"}),del:An({method:"DELETE",fullPath:"/v1/invoiceitems/{invoiceitem}"})});var Oy=c.method,Cy=c.extend({retrieve:Oy({method:"GET",fullPath:"/v1/invoice_payments/{invoice_payment}"}),list:Oy({method:"GET",fullPath:"/v1/invoice_payments",methodType:"list"})});var vi=c.method,$y=c.extend({retrieve:vi({method:"GET",fullPath:"/v1/invoice_rendering_templates/{template}"}),list:vi({method:"GET",fullPath:"/v1/invoice_rendering_templates",methodType:"list"}),archive:vi({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/archive"}),unarchive:vi({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/unarchive"})});var Se=c.method,Ny=c.extend({create:Se({method:"POST",fullPath:"/v1/invoices"}),retrieve:Se({method:"GET",fullPath:"/v1/invoices/{invoice}"}),update:Se({method:"POST",fullPath:"/v1/invoices/{invoice}"}),list:Se({method:"GET",fullPath:"/v1/invoices",methodType:"list"}),del:Se({method:"DELETE",fullPath:"/v1/invoices/{invoice}"}),addLines:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/add_lines"}),attachPayment:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/attach_payment"}),createPreview:Se({method:"POST",fullPath:"/v1/invoices/create_preview"}),finalizeInvoice:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/finalize"}),listLineItems:Se({method:"GET",fullPath:"/v1/invoices/{invoice}/lines",methodType:"list"}),markUncollectible:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/mark_uncollectible"}),pay:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/pay"}),removeLines:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/remove_lines"}),search:Se({method:"GET",fullPath:"/v1/invoices/search",methodType:"search"}),sendInvoice:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/send"}),updateLines:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/update_lines"}),updateLineItem:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/lines/{line_item_id}"}),voidInvoice:Se({method:"POST",fullPath:"/v1/invoices/{invoice}/void"})});var SI=c.method,Dy=c.extend({retrieve:SI({method:"GET",fullPath:"/v1/mandates/{mandate}"})});var zy=c.method,zs="connect.stripe.com",My=c.extend({basePath:"/",authorizeUrl(e,t){e=e||{},t=t||{};let r="oauth/authorize";return t.express&&(r=`express/${r}`),e.response_type||(e.response_type="code"),e.client_id||(e.client_id=this._stripe.getClientId()),e.scope||(e.scope="read_write"),`https://${zs}/${r}?${wt(e)}`},token:zy({method:"POST",path:"oauth/token",host:zs}),deauthorize(e,...t){return e.client_id||(e.client_id=this._stripe.getClientId()),zy({method:"POST",path:"oauth/deauthorize",host:zs}).apply(this,[e,...t])}});var Ge=c.method,Uy=c.extend({create:Ge({method:"POST",fullPath:"/v1/payment_intents"}),retrieve:Ge({method:"GET",fullPath:"/v1/payment_intents/{intent}"}),update:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}"}),list:Ge({method:"GET",fullPath:"/v1/payment_intents",methodType:"list"}),applyCustomerBalance:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/apply_customer_balance"}),cancel:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/cancel"}),capture:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/capture"}),confirm:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/confirm"}),incrementAuthorization:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/increment_authorization"}),search:Ge({method:"GET",fullPath:"/v1/payment_intents/search",methodType:"search"}),verifyMicrodeposits:Ge({method:"POST",fullPath:"/v1/payment_intents/{intent}/verify_microdeposits"})});var wn=c.method,Ly=c.extend({create:wn({method:"POST",fullPath:"/v1/payment_links"}),retrieve:wn({method:"GET",fullPath:"/v1/payment_links/{payment_link}"}),update:wn({method:"POST",fullPath:"/v1/payment_links/{payment_link}"}),list:wn({method:"GET",fullPath:"/v1/payment_links",methodType:"list"}),listLineItems:wn({method:"GET",fullPath:"/v1/payment_links/{payment_link}/line_items",methodType:"list"})});var _i=c.method,qy=c.extend({create:_i({method:"POST",fullPath:"/v1/payment_method_configurations"}),retrieve:_i({method:"GET",fullPath:"/v1/payment_method_configurations/{configuration}"}),update:_i({method:"POST",fullPath:"/v1/payment_method_configurations/{configuration}"}),list:_i({method:"GET",fullPath:"/v1/payment_method_configurations",methodType:"list"})});var kn=c.method,jy=c.extend({create:kn({method:"POST",fullPath:"/v1/payment_method_domains"}),retrieve:kn({method:"GET",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),update:kn({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),list:kn({method:"GET",fullPath:"/v1/payment_method_domains",methodType:"list"}),validate:kn({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}/validate"})});var Er=c.method,Fy=c.extend({create:Er({method:"POST",fullPath:"/v1/payment_methods"}),retrieve:Er({method:"GET",fullPath:"/v1/payment_methods/{payment_method}"}),update:Er({method:"POST",fullPath:"/v1/payment_methods/{payment_method}"}),list:Er({method:"GET",fullPath:"/v1/payment_methods",methodType:"list"}),attach:Er({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/attach"}),detach:Er({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/detach"})});var Ir=c.method,By=c.extend({create:Ir({method:"POST",fullPath:"/v1/payouts"}),retrieve:Ir({method:"GET",fullPath:"/v1/payouts/{payout}"}),update:Ir({method:"POST",fullPath:"/v1/payouts/{payout}"}),list:Ir({method:"GET",fullPath:"/v1/payouts",methodType:"list"}),cancel:Ir({method:"POST",fullPath:"/v1/payouts/{payout}/cancel"}),reverse:Ir({method:"POST",fullPath:"/v1/payouts/{payout}/reverse"})});var Rn=c.method,Gy=c.extend({create:Rn({method:"POST",fullPath:"/v1/plans"}),retrieve:Rn({method:"GET",fullPath:"/v1/plans/{plan}"}),update:Rn({method:"POST",fullPath:"/v1/plans/{plan}"}),list:Rn({method:"GET",fullPath:"/v1/plans",methodType:"list"}),del:Rn({method:"DELETE",fullPath:"/v1/plans/{plan}"})});var On=c.method,Vy=c.extend({create:On({method:"POST",fullPath:"/v1/prices"}),retrieve:On({method:"GET",fullPath:"/v1/prices/{price}"}),update:On({method:"POST",fullPath:"/v1/prices/{price}"}),list:On({method:"GET",fullPath:"/v1/prices",methodType:"list"}),search:On({method:"GET",fullPath:"/v1/prices/search",methodType:"search"})});var Ye=c.method,Hy=c.extend({create:Ye({method:"POST",fullPath:"/v1/products"}),retrieve:Ye({method:"GET",fullPath:"/v1/products/{id}"}),update:Ye({method:"POST",fullPath:"/v1/products/{id}"}),list:Ye({method:"GET",fullPath:"/v1/products",methodType:"list"}),del:Ye({method:"DELETE",fullPath:"/v1/products/{id}"}),createFeature:Ye({method:"POST",fullPath:"/v1/products/{product}/features"}),deleteFeature:Ye({method:"DELETE",fullPath:"/v1/products/{product}/features/{id}"}),listFeatures:Ye({method:"GET",fullPath:"/v1/products/{product}/features",methodType:"list"}),retrieveFeature:Ye({method:"GET",fullPath:"/v1/products/{product}/features/{id}"}),search:Ye({method:"GET",fullPath:"/v1/products/search",methodType:"search"})});var bi=c.method,Zy=c.extend({create:bi({method:"POST",fullPath:"/v1/promotion_codes"}),retrieve:bi({method:"GET",fullPath:"/v1/promotion_codes/{promotion_code}"}),update:bi({method:"POST",fullPath:"/v1/promotion_codes/{promotion_code}"}),list:bi({method:"GET",fullPath:"/v1/promotion_codes",methodType:"list"})});var Qe=c.method,Wy=c.extend({create:Qe({method:"POST",fullPath:"/v1/quotes"}),retrieve:Qe({method:"GET",fullPath:"/v1/quotes/{quote}"}),update:Qe({method:"POST",fullPath:"/v1/quotes/{quote}"}),list:Qe({method:"GET",fullPath:"/v1/quotes",methodType:"list"}),accept:Qe({method:"POST",fullPath:"/v1/quotes/{quote}/accept"}),cancel:Qe({method:"POST",fullPath:"/v1/quotes/{quote}/cancel"}),finalizeQuote:Qe({method:"POST",fullPath:"/v1/quotes/{quote}/finalize"}),listComputedUpfrontLineItems:Qe({method:"GET",fullPath:"/v1/quotes/{quote}/computed_upfront_line_items",methodType:"list"}),listLineItems:Qe({method:"GET",fullPath:"/v1/quotes/{quote}/line_items",methodType:"list"}),pdf:Qe({method:"GET",fullPath:"/v1/quotes/{quote}/pdf",host:"files.stripe.com",streaming:!0})});var Cn=c.method,Ky=c.extend({create:Cn({method:"POST",fullPath:"/v1/refunds"}),retrieve:Cn({method:"GET",fullPath:"/v1/refunds/{refund}"}),update:Cn({method:"POST",fullPath:"/v1/refunds/{refund}"}),list:Cn({method:"GET",fullPath:"/v1/refunds",methodType:"list"}),cancel:Cn({method:"POST",fullPath:"/v1/refunds/{refund}/cancel"})});var Ms=c.method,Jy=c.extend({retrieve:Ms({method:"GET",fullPath:"/v1/reviews/{review}"}),list:Ms({method:"GET",fullPath:"/v1/reviews",methodType:"list"}),approve:Ms({method:"POST",fullPath:"/v1/reviews/{review}/approve"})});var TI=c.method,Xy=c.extend({list:TI({method:"GET",fullPath:"/v1/setup_attempts",methodType:"list"})});var Bt=c.method,Yy=c.extend({create:Bt({method:"POST",fullPath:"/v1/setup_intents"}),retrieve:Bt({method:"GET",fullPath:"/v1/setup_intents/{intent}"}),update:Bt({method:"POST",fullPath:"/v1/setup_intents/{intent}"}),list:Bt({method:"GET",fullPath:"/v1/setup_intents",methodType:"list"}),cancel:Bt({method:"POST",fullPath:"/v1/setup_intents/{intent}/cancel"}),confirm:Bt({method:"POST",fullPath:"/v1/setup_intents/{intent}/confirm"}),verifyMicrodeposits:Bt({method:"POST",fullPath:"/v1/setup_intents/{intent}/verify_microdeposits"})});var Pi=c.method,Qy=c.extend({create:Pi({method:"POST",fullPath:"/v1/shipping_rates"}),retrieve:Pi({method:"GET",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),update:Pi({method:"POST",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),list:Pi({method:"GET",fullPath:"/v1/shipping_rates",methodType:"list"})});var $n=c.method,eg=c.extend({create:$n({method:"POST",fullPath:"/v1/sources"}),retrieve:$n({method:"GET",fullPath:"/v1/sources/{source}"}),update:$n({method:"POST",fullPath:"/v1/sources/{source}"}),listSourceTransactions:$n({method:"GET",fullPath:"/v1/sources/{source}/source_transactions",methodType:"list"}),verify:$n({method:"POST",fullPath:"/v1/sources/{source}/verify"})});var Nn=c.method,tg=c.extend({create:Nn({method:"POST",fullPath:"/v1/subscription_items"}),retrieve:Nn({method:"GET",fullPath:"/v1/subscription_items/{item}"}),update:Nn({method:"POST",fullPath:"/v1/subscription_items/{item}"}),list:Nn({method:"GET",fullPath:"/v1/subscription_items",methodType:"list"}),del:Nn({method:"DELETE",fullPath:"/v1/subscription_items/{item}"})});var Ar=c.method,rg=c.extend({create:Ar({method:"POST",fullPath:"/v1/subscription_schedules"}),retrieve:Ar({method:"GET",fullPath:"/v1/subscription_schedules/{schedule}"}),update:Ar({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}"}),list:Ar({method:"GET",fullPath:"/v1/subscription_schedules",methodType:"list"}),cancel:Ar({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/cancel"}),release:Ar({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/release"})});var Ot=c.method,ng=c.extend({create:Ot({method:"POST",fullPath:"/v1/subscriptions"}),retrieve:Ot({method:"GET",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),update:Ot({method:"POST",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),list:Ot({method:"GET",fullPath:"/v1/subscriptions",methodType:"list"}),cancel:Ot({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),deleteDiscount:Ot({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}/discount"}),resume:Ot({method:"POST",fullPath:"/v1/subscriptions/{subscription}/resume"}),search:Ot({method:"GET",fullPath:"/v1/subscriptions/search",methodType:"search"})});var og=c.method,ig=c.extend({retrieve:og({method:"GET",fullPath:"/v1/tax_codes/{id}"}),list:og({method:"GET",fullPath:"/v1/tax_codes",methodType:"list"})});var xi=c.method,ag=c.extend({create:xi({method:"POST",fullPath:"/v1/tax_ids"}),retrieve:xi({method:"GET",fullPath:"/v1/tax_ids/{id}"}),list:xi({method:"GET",fullPath:"/v1/tax_ids",methodType:"list"}),del:xi({method:"DELETE",fullPath:"/v1/tax_ids/{id}"})});var Si=c.method,sg=c.extend({create:Si({method:"POST",fullPath:"/v1/tax_rates"}),retrieve:Si({method:"GET",fullPath:"/v1/tax_rates/{tax_rate}"}),update:Si({method:"POST",fullPath:"/v1/tax_rates/{tax_rate}"}),list:Si({method:"GET",fullPath:"/v1/tax_rates",methodType:"list"})});var ug=c.method,cg=c.extend({create:ug({method:"POST",fullPath:"/v1/tokens"}),retrieve:ug({method:"GET",fullPath:"/v1/tokens/{token}"})});var Dn=c.method,lg=c.extend({create:Dn({method:"POST",fullPath:"/v1/topups"}),retrieve:Dn({method:"GET",fullPath:"/v1/topups/{topup}"}),update:Dn({method:"POST",fullPath:"/v1/topups/{topup}"}),list:Dn({method:"GET",fullPath:"/v1/topups",methodType:"list"}),cancel:Dn({method:"POST",fullPath:"/v1/topups/{topup}/cancel"})});var Ct=c.method,pg=c.extend({create:Ct({method:"POST",fullPath:"/v1/transfers"}),retrieve:Ct({method:"GET",fullPath:"/v1/transfers/{transfer}"}),update:Ct({method:"POST",fullPath:"/v1/transfers/{transfer}"}),list:Ct({method:"GET",fullPath:"/v1/transfers",methodType:"list"}),createReversal:Ct({method:"POST",fullPath:"/v1/transfers/{id}/reversals"}),listReversals:Ct({method:"GET",fullPath:"/v1/transfers/{id}/reversals",methodType:"list"}),retrieveReversal:Ct({method:"GET",fullPath:"/v1/transfers/{transfer}/reversals/{id}"}),updateReversal:Ct({method:"POST",fullPath:"/v1/transfers/{transfer}/reversals/{id}"})});var zn=c.method,dg=c.extend({create:zn({method:"POST",fullPath:"/v1/webhook_endpoints"}),retrieve:zn({method:"GET",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),update:zn({method:"POST",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),list:zn({method:"GET",fullPath:"/v1/webhook_endpoints",methodType:"list"}),del:zn({method:"DELETE",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"})});var EI=oe("apps",{Secrets:Nh}),II=oe("billing",{Alerts:If,CreditBalanceSummary:Mf,CreditBalanceTransactions:Lf,CreditGrants:qf,MeterEventAdjustments:eh,MeterEvents:oh,Meters:ah}),AI=oe("billingPortal",{Configurations:$f,Sessions:Dh}),wI=oe("checkout",{Sessions:zh}),kI=oe("climate",{Orders:sh,Products:gh,Suppliers:Fh}),RI=oe("entitlements",{ActiveEntitlements:Ef,Features:Kf}),OI=oe("financialConnections",{Accounts:Sf,Sessions:Uh,Transactions:Kh}),CI=oe("forwarding",{Requests:Oh}),$I=oe("identity",{VerificationReports:ny,VerificationSessions:oy}),NI=oe("issuing",{Authorizations:wf,Cardholders:Rf,Cards:Cf,Disputes:Gf,PersonalizationDesigns:mh,PhysicalBundles:hh,Tokens:Gh,Transactions:Jh}),DI=oe("radar",{EarlyFraudWarnings:Hf,ValueListItems:ey,ValueLists:ty}),zI=oe("reporting",{ReportRuns:wh,ReportTypes:Rh}),MI=oe("sigma",{ScheduledQueryRuns:$h}),UI=oe("tax",{Calculations:kf,Registrations:Ah,Settings:qh,Transactions:Xh}),LI=oe("terminal",{Configurations:Nf,ConnectionTokens:zf,Locations:Qf,Readers:_h}),qI=oe("testHelpers",{ConfirmationTokens:Df,Customers:Ff,Refunds:Ih,TestClocks:Bh,Issuing:oe("issuing",{Authorizations:Af,Cards:Of,PersonalizationDesigns:dh,Transactions:Zh}),Terminal:oe("terminal",{Readers:vh}),Treasury:oe("treasury",{InboundTransfers:Xf,OutboundPayments:uh,OutboundTransfers:lh,ReceivedCredits:bh,ReceivedDebits:Sh})}),jI=oe("treasury",{CreditReversals:jf,DebitReversals:Bf,FinancialAccounts:Jf,InboundTransfers:Yf,OutboundPayments:ch,OutboundTransfers:ph,ReceivedCredits:xh,ReceivedDebits:Eh,TransactionEntries:Hh,Transactions:Qh}),FI=oe("v2",{Billing:oe("billing",{MeterEventAdjustments:th,MeterEventSession:rh,MeterEventStream:nh,MeterEvents:ih}),Core:oe("core",{EventDestinations:Zf,Events:Wf})});var mg="api.stripe.com",fg="443",hg="/v1/",yg=xf,gg=8e4,vg=5,_g=.5,BI=["name","version","url","partner_id"],bg=["authenticator","apiVersion","typescript","maxNetworkRetries","httpAgent","httpClient","timeout","host","port","protocol","telemetry","appInfo","stripeAccount","stripeContext"],GI=a(e=>new Qo(e,c.MAX_BUFFERED_REQUEST_METRICS),"defaultRequestSenderFactory");function Pg(e,t=GI){r.PACKAGE_VERSION="18.2.1",r.USER_AGENT=Object.assign({bindings_version:r.PACKAGE_VERSION,lang:"node",publisher:"stripe",uname:null,typescript:!1},df()),r.StripeResource=c,r.resources=wr,r.HttpClient=Ee,r.HttpClientResponse=Et,r.CryptoProvider=Tt,r.webhooks=Pf(e);function r(n,o={}){if(!(this instanceof r))return new r(n,o);let i=this._getPropsFromConfig(o);this._platformFunctions=e,Object.defineProperty(this,"_emitter",{value:this._platformFunctions.createEmitter(),enumerable:!1,configurable:!1,writable:!1}),this.VERSION=r.PACKAGE_VERSION,this.on=this._emitter.on.bind(this._emitter),this.once=this._emitter.once.bind(this._emitter),this.off=this._emitter.removeListener.bind(this._emitter);let s=i.httpAgent||null;this._api={host:i.host||mg,port:i.port||fg,protocol:i.protocol||"https",basePath:hg,version:i.apiVersion||yg,timeout:jo("timeout",i.timeout,gg),maxNetworkRetries:jo("maxNetworkRetries",i.maxNetworkRetries,2),agent:s,httpClient:i.httpClient||(s?this._platformFunctions.createNodeHttpClient(s):this._platformFunctions.createDefaultHttpClient()),dev:!1,stripeAccount:i.stripeAccount||null,stripeContext:i.stripeContext||null};let l=i.typescript||!1;l!==r.USER_AGENT.typescript&&(r.USER_AGENT.typescript=l),i.appInfo&&this._setAppInfo(i.appInfo),this._prepResources(),this._setAuthenticator(n,i.authenticator),this.errors=Xo,this.webhooks=r.webhooks,this._prevRequestMetrics=[],this._enableTelemetry=i.telemetry!==!1,this._requestSender=t(this),this.StripeResource=r.StripeResource}return a(r,"Stripe"),r.errors=Xo,r.createNodeHttpClient=e.createNodeHttpClient,r.createFetchHttpClient=e.createFetchHttpClient,r.createNodeCryptoProvider=e.createNodeCryptoProvider,r.createSubtleCryptoProvider=e.createSubtleCryptoProvider,r.prototype={_appInfo:void 0,on:null,off:null,once:null,VERSION:null,StripeResource:null,webhooks:null,errors:null,_api:null,_prevRequestMetrics:null,_emitter:null,_enableTelemetry:null,_requestSender:null,_platformFunctions:null,rawRequest(n,o,i,s){return this._requestSender._rawRequest(n,o,i,s)},_setAuthenticator(n,o){if(n&&o)throw new Error("Can't specify both apiKey and authenticator");if(!n&&!o)throw new Error("Neither apiKey nor config.authenticator provided");this._authenticator=n?Mo(n):o},_setAppInfo(n){if(n&&typeof n!="object")throw new Error("AppInfo must be an object.");if(n&&!n.name)throw new Error("AppInfo.name is required");n=n||{},this._appInfo=BI.reduce((o,i)=>(typeof n[i]=="string"&&(o=o||{},o[i]=n[i]),o),{})},_setApiField(n,o){this._api[n]=o},getApiField(n){return this._api[n]},setClientId(n){this._clientId=n},getClientId(){return this._clientId},getConstant:a(n=>{switch(n){case"DEFAULT_HOST":return mg;case"DEFAULT_PORT":return fg;case"DEFAULT_BASE_PATH":return hg;case"DEFAULT_API_VERSION":return yg;case"DEFAULT_TIMEOUT":return gg;case"MAX_NETWORK_RETRY_DELAY_SEC":return vg;case"INITIAL_NETWORK_RETRY_DELAY_SEC":return _g}return r[n]},"getConstant"),getMaxNetworkRetries(){return this.getApiField("maxNetworkRetries")},_setApiNumberField(n,o,i){let s=jo(n,o,i);this._setApiField(n,s)},getMaxNetworkRetryDelay(){return vg},getInitialNetworkRetryDelay(){return _g},getClientUserAgent(n){return this.getClientUserAgentSeeded(r.USER_AGENT,n)},getClientUserAgentSeeded(n,o){this._platformFunctions.getUname().then(i=>{var s;let l={};for(let b in n)Object.prototype.hasOwnProperty.call(n,b)&&(l[b]=encodeURIComponent((s=n[b])!==null&&s!==void 0?s:"null"));l.uname=encodeURIComponent(i||"UNKNOWN");let f=this.getApiField("httpClient");f&&(l.httplib=encodeURIComponent(f.getClientName())),this._appInfo&&(l.application=this._appInfo),o(JSON.stringify(l))})},getAppInfoAsString(){if(!this._appInfo)return"";let n=this._appInfo.name;return this._appInfo.version&&(n+=`/${this._appInfo.version}`),this._appInfo.url&&(n+=` (${this._appInfo.url})`),n},getTelemetryEnabled(){return this._enableTelemetry},_prepResources(){for(let n in wr)Object.prototype.hasOwnProperty.call(wr,n)&&(this[lf(n)]=new wr[n](this))},_getPropsFromConfig(n){if(!n)return{};let o=typeof n=="string";if(!(n===Object(n)&&!Array.isArray(n))&&!o)throw new Error("Config must either be an object or a string");if(o)return{apiVersion:n};if(Object.keys(n).filter(l=>!bg.includes(l)).length>0)throw new Error(`Config object may only contain the following: ${bg.join(", ")}`);return n},parseThinEvent(n,o,i,s,l,f){return this.webhooks.constructEvent(n,o,i,s,l,f)}},r}a(Pg,"createStripe");var xg=Pg(new Yo);var ut="https://api.stripe.com/v1",Ae=a(e=>new xg(e,{apiVersion:"2025-05-28.basil"}),"getClient"),_={baseUrl:ut,subscribeWebhook:a(async(e,t,r)=>{let n={method:"POST",url:`${ut}/webhook_endpoints`,headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{enabled_events:[e],url:t},authentication:{type:"BEARER_TOKEN",token:r},queryParams:{}},{body:o}=await v.sendRequest(n);return o},"subscribeWebhook"),unsubscribeWebhook:a(async(e,t)=>{let r={method:"DELETE",url:`${ut}/webhook_endpoints/${e}`,authentication:{type:"BEARER_TOKEN",token:t}};return await v.sendRequest(r)},"unsubscribeWebhook"),invoice:u.Dropdown({auth:g,displayName:"Invoice",required:!0,refreshers:[],options:a(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your Stripe account first"};try{return{disabled:!1,options:(await Ae(e.secret_text).invoices.list({limit:100,expand:["data.customer"]})).data.map(n=>{let o=n.customer,i=o?.name||o?.email||"Unknown Customer",s=(n.total/100).toFixed(2),l=`Invoice #${n.number||n.id} for ${i} (${s} ${n.currency.toUpperCase()})`;return{value:n.id,label:l}}).filter(n=>n.value!==void 0&&n.value!==null)}}catch(t){return console.error("Failed to load Stripe invoices:",t),{disabled:!0,options:[],placeholder:"Error loading invoices. Check connection."}}},"options")}),customer:u.Dropdown({auth:g,displayName:"Customer",required:!0,refreshers:[],options:a(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let r={method:"GET",authentication:{type:"BEARER_TOKEN",token:e.secret_text},url:t?`${ut}/customers/search`:`${ut}/customers`,queryParams:t?{query:`name~"${t}" OR email~"${t}"`}:{limit:"100"}},n=await v.sendRequest(r);return n.status===200?{disabled:!1,options:n.body.data.map(o=>({value:o.id,label:`${o.name||o.id} (${o.email||"No Email"})`}))}:{disabled:!0,options:[],placeholder:"Couldn't load customers"}},"options")}),product:u.Dropdown({auth:g,displayName:"Product",required:!0,refreshers:[],options:a(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let r="active:'true'";t&&(r+=` AND name~"${t}"`);let n=await v.sendRequest({method:"GET",url:`${ut}/products/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:r}});return n.status===200?{disabled:!1,options:n.body.data.map(o=>({value:o.id,label:o.name}))}:{disabled:!0,options:[],placeholder:"Couldn't load products"}},"options")}),price:u.Dropdown({auth:g,displayName:"Price",required:!0,refreshers:[],options:a(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let r=await v.sendRequest({method:"GET",url:`${ut}/prices/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:`active:'true' AND type:'recurring' AND (product.name~"${t||""}" OR nickname~"${t||""}")`,expand:"data.product"}});return r.status===200?{disabled:!1,options:r.body.data.map(n=>{let o=n.nickname?`${n.nickname} (${n.product.name})`:n.product.name;return{value:n.id,label:o}})}:{disabled:!0,options:[],placeholder:"Couldn't load prices"}},"options")}),subscription:u.Dropdown({auth:g,displayName:"Subscription",required:!0,refreshers:[],options:a(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account first"};try{return{disabled:!1,options:(await Ae(e.secret_text).subscriptions.list({limit:100,status:"active",expand:["data.customer"]})).data.map(n=>{let o=n.customer,s=`Subscription for ${o?.name||o?.email||"Unknown Customer"} (${n.id})`;return{value:n.id,label:s}})}}catch(t){return console.error("Failed to load Stripe subscriptions:",t),{disabled:!0,options:[],placeholder:"Couldn't load subscriptions. See console."}}},"options")}),payout:u.Dropdown({auth:g,displayName:"Payout",required:!0,refreshers:[],options:a(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let t=await v.sendRequest({method:"GET",url:`${ut}/payouts`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{limit:"100"}});return t.status===200?{disabled:!1,options:t.body.data.map(r=>{let n=new Date(r.arrival_date*1e3).toLocaleDateString(),o=(r.amount/100).toFixed(2),i=`Payout on ${n} - ${o} ${r.currency.toUpperCase()} (${r.status})`;return{value:r.id,label:i}})}:{disabled:!0,options:[],placeholder:"Couldn't load payouts"}},"options")}),paymentIntent:u.Dropdown({auth:g,displayName:"Payment Intent",required:!0,refreshers:[],options:a(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let r="status:'succeeded'";t&&(r+=` AND customer.email~"${t}"`);let n=await v.sendRequest({method:"GET",url:`${ut}/payment_intents/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:r,"expand[]":"data.customer"}});return n.status===200?{disabled:!1,options:n.body.data.map(o=>{let i=o.customer?.name||o.customer?.email||"Unknown Customer",s=(o.amount/100).toFixed(2),l=`Payment from ${i} - ${s} ${o.currency.toUpperCase()}`;return{value:o.id,label:l}})}:{disabled:!0,options:[],placeholder:"Couldn't load payment intents"}},"options")}),paymentLink:u.Dropdown({auth:g,displayName:"Payment Link",required:!0,refreshers:[],options:a(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};try{return{disabled:!1,options:(await Ae(e.secret_text).paymentLinks.list({active:!0,limit:100})).data.map(n=>({value:n.id,label:n.url}))}}catch{return{disabled:!0,options:[],placeholder:"Couldn't load payment links"}}},"options")})};var Sg=x({name:"search_customer",classification:"SEARCH",auth:g,displayName:"Search Customer",description:"Search for a customer in stripe by email",audience:"human",aiMetadata:{description:"Looks up Stripe customers matching a given email address. Use to find an existing customer record before creating, updating, or charging one, to avoid duplicates. Read-only and idempotent; matches on the exact email.",idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:void 0,required:!0})},outputSchema:So,async run(e){let t={email:e.propsValue.email};return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers/search`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},body:{query:`email:'${t.email}'`}})).body}});var Tg=ee({auth:g,name:"new_customer",classification:"READ",displayName:"New Customer",description:"Triggers when a new customer is created",aiMetadata:{description:"Fires when a new customer is created in Stripe (the customer.created event), emitting the new customer record. Use to react to customer onboarding, such as syncing them to a CRM or sending a welcome flow."},props:{},outputSchema:Re,sampleData:{id:"cus_NGtyEf4hNGTj3p",object:"customer",address:null,balance:0,created:1675180509,currency:null,default_currency:null,default_source:null,delinquent:!1,description:null,discount:null,email:"jane@example.com",invoice_prefix:"B7162248",invoice_settings:{custom_fields:null,default_payment_method:null,footer:null,rendering_options:null},livemode:!1,metadata:{},name:"John Doe",next_invoice_sequence:1,phone:null,preferred_locales:[],shipping:null,tax_exempt:"none",test_clock:null},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("customer.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_customer_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_customer_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var Eg=ee({auth:g,name:"new_payment",classification:"READ",displayName:"New Payment",description:"Triggers when a new payment is made",aiMetadata:{description:"Fires when a payment succeeds in Stripe (the payment_intent.succeeded event), emitting the completed payment. Use to react to a successful payment, such as fulfilling an order or recording revenue."},props:{},type:"WEBHOOK",outputSchema:Ie,sampleData:{id:"pi_3MWM7aKZ0dZRqLEK1soCKVrq",object:"payment_intent",amount:1e4,amount_capturable:0,amount_received:1e4,capture_method:"automatic_async",confirmation_method:"automatic",created:1675180355,currency:"usd",customer:"cus_NGtvUQ18FJXcGI",description:"Subscription creation",latest_charge:"ch_3MWM7aKZ0dZRqLEK1soCKVrq",livemode:!1,metadata:{},payment_method:"pm_1MWM8MKZ0dZRqLEKnIH41f76",receipt_email:null,setup_future_usage:null,status:"succeeded"},async onEnable(e){let t=await _.subscribeWebhook("payment_intent.succeeded",e.webhookUrl,e.auth.secret_text);await e.store?.put("_new_payment_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_payment_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/payment_intents/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"succeeded"',limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var Ig=ee({auth:g,name:"new_subscription",classification:"READ",displayName:"New Subscription",description:"Triggers when a new subscription is made",aiMetadata:{description:"Fires when a new subscription is created in Stripe (the customer.subscription.created event), emitting the new subscription. Use to react to a customer starting recurring billing, such as provisioning access or sending an onboarding flow."},props:{},type:"WEBHOOK",outputSchema:xe,sampleData:{id:"sub_1MWMJXKZ0dZRqLEKJX80JXfv",object:"subscription",application:null,application_fee_percent:null,automatic_tax:{enabled:!0},billing_cycle_anchor:1675181047,billing_thresholds:null,cancel_at:null,cancel_at_period_end:!1,canceled_at:null,collection_method:"charge_automatically",created:1675181047,currency:"usd",current_period_end:1677600247,current_period_start:1675181047,customer:"cus_NGtvUQ18FJXcGI",days_until_due:null,default_payment_method:"pm_1MWM8MKZ0dZRqLEKnIH41f76",default_source:null,default_tax_rates:[],description:null,discount:null,ended_at:null,items:{object:"list",data:[{id:"si_NGu7pb7hS3Rps3",object:"subscription_item",billing_thresholds:null,created:1675181048,metadata:{},plan:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"plan",active:!0,aggregate_usage:null,amount:1e4,amount_decimal:"10000",billing_scheme:"per_unit",created:1675179777,currency:"usd",interval:"month",interval_count:1,livemode:!1,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",tiers_mode:null,transform_usage:null,trial_period_days:null,usage_type:"licensed"},price:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"price",active:!0,billing_scheme:"per_unit",created:1675179777,currency:"usd",custom_unit_amount:null,livemode:!1,lookup_key:null,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",recurring:{aggregate_usage:null,interval:"month",interval_count:1,trial_period_days:null,usage_type:"licensed"},tax_behavior:"exclusive",tiers_mode:null,transform_quantity:null,type:"recurring",unit_amount:1e4,unit_amount_decimal:"10000"},quantity:1,subscription:"sub_1MWMJXKZ0dZRqLEKJX80JXfv",tax_rates:[]}],has_more:!1,total_count:1,url:"/v1/subscription_items?subscription=sub_1MWMJXKZ0dZRqLEKJX80JXfv"},latest_invoice:"in_1MWMJXKZ0dZRqLEKIu4a51u7",livemode:!1,metadata:{},next_pending_invoice_item_invoice:null,on_behalf_of:null,pause_collection:null,payment_settings:{payment_method_options:null,payment_method_types:null,save_default_payment_method:"off"},pending_invoice_item_interval:null,pending_setup_intent:null,pending_update:null,plan:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"plan",active:!0,aggregate_usage:null,amount:1e4,amount_decimal:"10000",billing_scheme:"per_unit",created:1675179777,currency:"usd",interval:"month",interval_count:1,livemode:!1,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",tiers_mode:null,transform_usage:null,trial_period_days:null,usage_type:"licensed"},quantity:1,schedule:null,start_date:1675181047,status:"active",test_clock:null,transfer_data:null,trial_end:null,trial_start:null},async onEnable(e){let t=await _.subscribeWebhook("customer.subscription.created",e.webhookUrl,e.auth.secret_text);await e.store?.put("_new_customer_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_customer_subscription_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var Ag=ee({auth:g,name:"payment_failed",classification:"READ",displayName:"Payment Failed",description:"Triggers when a payment fails",aiMetadata:{description:"Fires when a charge fails in Stripe (the charge.failed event), emitting the failed charge including its failure code and message. Use to react to declined payments, such as alerting the customer or triggering a retry/dunning flow."},props:{},outputSchema:ar,sampleData:{id:"ch_3MWMPQKZ0dZRqLEK063rxD7q",object:"charge",amount:1e5,amount_captured:0,amount_refunded:0,application:null,application_fee:null,application_fee_amount:null,balance_transaction:null,billing_details:{address:{city:null,country:null,line1:null,line2:null,postal_code:"12321",state:null},email:null,name:null,phone:null},calculated_statement_descriptor:"WWW.ACTIVEPIECES.COM",captured:!1,created:1675181413,currency:"usd",customer:"cus_NGtvUQ18FJXcGI",description:"Failed Payment",destination:null,dispute:null,disputed:!1,failure_balance_transaction:null,failure_code:"card_declined",failure_message:"Your card was declined.",fraud_details:{},invoice:null,livemode:!1,metadata:{},on_behalf_of:null,order:null,outcome:{network_status:"declined_by_network",reason:"generic_decline",risk_level:"normal",risk_score:60,seller_message:"The bank did not return any further details with this decline.",type:"issuer_declined"},paid:!1,payment_intent:"pi_3MWMPQKZ0dZRqLEK0Nsc6WhL",payment_method:"src_1MWMPQKZ0dZRqLEKuQ83wmZI",payment_method_details:{card:{brand:"visa",checks:{address_line1_check:null,address_postal_code_check:"pass",cvc_check:"pass"},country:"US",exp_month:12,exp_year:2031,fingerprint:"mtYxM2Q4edpEt8Pw",funding:"credit",installments:null,last4:"0341",mandate:null,network:"visa",three_d_secure:null,wallet:null},type:"card"},receipt_email:null,receipt_number:null,receipt_url:null,refunded:!1,refunds:{object:"list",data:[],has_more:!1,total_count:0,url:"/v1/charges/ch_3MWMPQKZ0dZRqLEK063rxD7q/refunds"},review:null,shipping:null,source:{id:"src_1MWMPQKZ0dZRqLEKuQ83wmZI",object:"source",amount:null,card:{exp_month:12,exp_year:2031,last4:"0341",country:"US",brand:"Visa",address_zip_check:"pass",cvc_check:"pass",funding:"credit",fingerprint:"mtYxM2Q4edpEt8Pw",three_d_secure:"optional",name:null,address_line1_check:null,tokenization_method:null,dynamic_last4:null},client_secret:"src_client_secret_TlLkl6IvhCvmbx8Cz12YNDVb",created:1675181413,currency:null,flow:"none",livemode:!1,metadata:{},owner:{address:{city:null,country:null,line1:null,line2:null,postal_code:"12321",state:null},email:null,name:null,phone:null,verified_address:null,verified_email:null,verified_name:null,verified_phone:null},statement_descriptor:null,status:"chargeable",type:"card",usage:"reusable"},source_transfer:null,statement_descriptor:"www.activepieces.com",statement_descriptor_suffix:null,status:"failed",transfer_data:null,transfer_group:null},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("charge.failed",e.webhookUrl,e.auth.secret_text);await e.store?.put("_payment_failed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_payment_failed_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/charges/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"failed"',limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var VI=[{label:"All Statuses",value:""},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}],wg=x({name:"search_subscriptions",classification:"SEARCH",auth:g,displayName:"Search Subscriptions",description:"Search for subscriptions by price ID, status, customer ID and other filters, including customer details",audience:"human",aiMetadata:{description:"Lists and filters Stripe subscriptions by price ID, status, customer ID, and creation date range, optionally expanding full customer details for each. Use to find subscriptions matching criteria or to audit a customer's subscriptions; supports paging through all results. Read-only and idempotent.",idempotent:!0},props:{price_ids:u.LongText({displayName:"Price IDs",description:"Comma-separated list of price IDs to filter by (e.g., price_1ABC123, price_2DEF456)",required:!1}),status:u.StaticDropdown({displayName:"Subscription Status",description:"Filter by subscription status",required:!1,options:{options:VI}}),customer_id:u.ShortText({displayName:"Customer ID",description:"Filter by specific customer ID (optional)",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Filter subscriptions created after this date (YYYY-MM-DD format)",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Filter subscriptions created before this date (YYYY-MM-DD format)",required:!1}),limit:u.Number({displayName:"Limit",description:"Maximum number of subscriptions to return (default: 100, set to 0 for all)",required:!1,defaultValue:100}),fetch_all:u.Checkbox({displayName:"Fetch All Results",description:"Fetch all matching subscriptions (ignores limit, may take longer for large datasets)",required:!1,defaultValue:!1}),include_customer_details:u.Checkbox({displayName:"Include Customer Details",description:"Fetch detailed customer information for each subscription",required:!1,defaultValue:!0})},outputSchema:To,async run(e){let{price_ids:t,status:r,customer_id:n,created_after:o,created_before:i,limit:s=100,fetch_all:l=!1,include_customer_details:f=!0}=e.propsValue,b=a(T=>{let A=new URLSearchParams;if(A.append("limit","100"),A.append("expand[]","data.items.data.price"),f&&A.append("expand[]","data.customer"),r&&A.append("status",r),n&&A.append("customer",n),o){let k=Math.floor(new Date(o).getTime()/1e3);A.append("created[gte]",k.toString())}if(i){let k=Math.floor(new Date(i).getTime()/1e3);A.append("created[lte]",k.toString())}return T&&A.append("starting_after",T),A},"buildQueryParams"),m=[],P=!0,h,d=0,y=l?50:Math.ceil(s/100);for(;P&&d<y;){let T=b(h),A=await v.sendRequest({method:"GET",url:`${_.baseUrl}/subscriptions?${T.toString()}`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"}});if(!A.body)throw new Error("Failed to fetch subscriptions from Stripe");let k=A.body.data;if(m=m.concat(k),P=A.body.has_more,d++,P&&k.length>0&&(h=k[k.length-1].id),!l&&m.length>=s){m=m.slice(0,s);break}}let I=m;if(t&&t.trim()){let T=t.split(",").map(A=>A.trim()).filter(A=>A.length>0);T.length>0&&(I=I.filter(A=>A.items.data.some(k=>k.price&&typeof k.price=="object"&&T.includes(k.price.id))))}let S=await Promise.all(I.map(async T=>{let A={...T};if(f){if(typeof T.customer=="object"&&T.customer!==null&&!("deleted"in T.customer&&T.customer.deleted))A.customer=T.customer;else if(typeof T.customer=="string")try{let k=await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers/${T.customer}`,headers:{Authorization:"Bearer "+e.auth.secret_text}});A.customer=k.body}catch(k){console.warn(`Failed to fetch customer details for ${T.customer}:`,k)}}return A}));return{success:!0,count:S.length,total_fetched:m.length,requests_made:d,has_more_available:P&&!l,pagination_info:{limit_requested:l?"All":s,fetch_all_enabled:l,max_requests_limit:y},subscriptions:S,filters_applied:{price_ids:t?t.split(",").map(T=>T.trim()).filter(T=>T.length>0):null,status:r||null,customer_id:n||null,created_after:o||null,created_before:i||null,limit:s,fetch_all:l,include_customer_details:f}}}});var kg=ee({auth:g,name:"new_charge",classification:"READ",displayName:"New Charge",description:"Fires when a charge is successfully completed.",aiMetadata:{description:"Fires when a charge is successfully completed in Stripe (the charge.succeeded event), emitting the charge record. Use to react to a successful card charge; note this is the charge-level event, distinct from the New Payment trigger which fires on a succeeded payment intent."},props:{},outputSchema:ar,sampleData:{id:"ch_3MmlLrLkdIwHu7ix0snN0B15",object:"charge",amount:1099,amount_captured:1099,amount_refunded:0,application:null,application_fee:null,application_fee_amount:null,balance_transaction:"txn_3MmlLrLkdIwHu7ix0uke3Ezy",billing_details:{address:{city:null,country:null,line1:null,line2:null,postal_code:null,state:null},email:"customer@example.com",name:"John Doe",phone:null},captured:!0,created:1679090539,currency:"usd",customer:"cus_ABC123",description:"My First Test Charge",disputed:!1,paid:!0,payment_intent:"pi_123",payment_method:"pm_123",receipt_url:"https://pay.stripe.com/receipts/...",refunded:!1,status:"succeeded"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("charge.succeeded",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_charge_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_charge_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/charges/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"succeeded"',limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var Rg=ee({auth:g,name:"new_invoice",classification:"READ",displayName:"New Invoice",description:"Fires when an invoice is created. Supports filters like status, customer, subscription.",aiMetadata:{description:"Fires when an invoice is created in Stripe (the invoice.created event), emitting the new invoice. Optional filters narrow firing to a specific status, customer ID, or subscription ID. Use to react to newly issued invoices, for example to record or forward them."},props:{status:u.StaticDropdown({displayName:"Status",description:"Only trigger for invoices with this status.",required:!1,options:{options:[{label:"Draft",value:"draft"},{label:"Open",value:"open"},{label:"Paid",value:"paid"},{label:"Uncollectible",value:"uncollectible"},{label:"Void",value:"void"}]}}),customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for invoices belonging to this customer ID (e.g., `cus_...`).",required:!1}),subscription:u.ShortText({displayName:"Subscription ID",description:"Only trigger for invoices belonging to this subscription ID (e.g., `sub_...`).",required:!1})},outputSchema:ge,sampleData:{id:"in_1MtHbELkdIwHu7ixl4OzzPMv",object:"invoice",customer:"cus_NeZwdNtLEOXuvB",subscription:"sub_12345ABC",status:"paid",amount_due:999,amount_paid:999,amount_remaining:0,billing_reason:"subscription_cycle",collection_method:"charge_automatically",created:1680644467,currency:"usd",customer_email:"jennyrosen@example.com",customer_name:"Jenny Rosen",hosted_invoice_url:"https://invoice.stripe.com/i/acct_...",invoice_pdf:"https://pay.stripe.com/invoice/acct_.../pdf",livemode:!1,number:"ABC-123-456"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("invoice.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_invoice_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_invoice_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{status:n,customer:o,subscription:i}=e.propsValue;return n&&r.status!==n?[]:o&&r.customer!==o?[]:i&&r.subscription!==i?[]:[r]}});var Og=ee({auth:g,name:"invoice_payment_failed",classification:"READ",displayName:"Invoice Payment Failed",description:"Fires when a payment against an invoice fails.",aiMetadata:{description:"Fires when a payment against an invoice fails in Stripe (the invoice.payment_failed event), emitting the affected invoice including the finalization error. An optional customer ID filter narrows firing to one customer. Use to react to failed invoice payments, such as starting a dunning or retry flow."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for invoices belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:ge,sampleData:{id:"in_1MtHbELkdIwHu7ixl4OzzPMv",object:"invoice",customer:"cus_NeZwdNtLEOXuvB",status:"open",amount_due:1500,amount_paid:0,amount_remaining:1500,attempt_count:1,attempted:!0,billing_reason:"subscription_cycle",collection_method:"charge_automatically",created:1680644467,currency:"usd",customer_email:"jennyrosen@example.com",customer_name:"Jenny Rosen",hosted_invoice_url:"https://invoice.stripe.com/i/acct_...",last_finalization_error:{code:"card_declined",doc_url:"https://stripe.com/docs/error-codes/card-declined",message:"Your card was declined.",param:"",payment_intent:{id:"pi_123",object:"payment_intent"},type:"card_error"},livemode:!1,next_payment_attempt:1681251667},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("invoice.payment_failed",e.webhookUrl,e.auth.secret_text);await e.store.put("_invoice_payment_failed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_invoice_payment_failed_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"open",limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&r.customer!==n?[]:[r]}});var Cg=ee({auth:g,name:"canceled_subscription",classification:"READ",displayName:"Canceled Subscription",description:"Fires when a subscription is canceled.",aiMetadata:{description:"Fires when a subscription is canceled in Stripe (the customer.subscription.deleted event), emitting the canceled subscription including any cancellation details. An optional customer ID filter narrows firing to one customer. Use to react to churn, such as revoking access or sending a win-back flow."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for subscriptions belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:xe,sampleData:{id:"sub_1MlPf9LkdIwHu7ixB6VIYRyX",object:"subscription",application:null,application_fee_percent:null,billing_cycle_anchor:1678768838,cancel_at_period_end:!1,canceled_at:1678768842,cancellation_details:{comment:"User requested cancellation via support.",feedback:"missing_features",reason:"cancellation_requested"},collection_method:"charge_automatically",created:1678768838,currency:"usd",customer:"cus_NWSaVkvdacCUi4",ended_at:1678768842,items:{object:"list",data:[{id:"si_NWSaWTp80M123q",object:"subscription_item",price:{id:"price_1MlPf7LkdIwHu7ixgcbP7cwE",object:"price",active:!0,currency:"usd",product:"prod_NWSaMgipulx8IQ",type:"recurring",unit_amount:1099},quantity:1}]},latest_invoice:"in_1MlPf9LkdIwHu7ixEo6hdgCw",livemode:!1,metadata:{},start_date:1678768838,status:"canceled"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("customer.subscription.deleted",e.webhookUrl,e.auth.secret_text);await e.store.put("_canceled_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_canceled_subscription_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"canceled",limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&r.customer!==n?[]:[r]}});var $g=ee({auth:g,name:"new_refund",classification:"READ",displayName:"New Refund",description:"Fires when a charge is refunded (full or partial).",aiMetadata:{description:"Fires when a refund is created in Stripe (the refund.created event), for a full or partial refund, emitting the refund record. Optional filters narrow firing to a specific charge ID or payment intent ID. Use to react to money returned to a customer, such as updating accounting or notifying them."},props:{charge:u.ShortText({displayName:"Charge ID",description:"Only trigger for refunds related to this Charge ID (e.g., `ch_...`).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Only trigger for refunds related to this Payment Intent ID (e.g., `pi_...`).",required:!1})},outputSchema:xt,sampleData:{id:"re_1Nispe2eZvKYlo2Cd31jOCgZ",object:"refund",amount:1e3,balance_transaction:"txn_1Nispe2eZvKYlo2CYezqFhEx",charge:"ch_1NirD82eZvKYlo2CIvbtLWuY",created:1692942318,currency:"usd",metadata:{},payment_intent:"pi_1GszsK2eZvKYlo2CfhZyoZLp",reason:"requested_by_customer",receipt_number:null,status:"succeeded"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("refund.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_refund_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_refund_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/refunds",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{charge:n,payment_intent:o}=e.propsValue;return n&&r.charge!==n?[]:o&&r.payment_intent!==o?[]:[r]}});var Ng=ee({auth:g,name:"new_dispute",classification:"READ",displayName:"New Dispute",description:"Fires when a customer disputes a charge.",aiMetadata:{description:"Fires when a customer disputes a charge in Stripe (the charge.dispute.created event), emitting the dispute including its reason and evidence due date. Optional filters narrow firing to a specific charge ID or payment intent ID. Use to react to chargebacks, such as alerting a team or gathering evidence."},props:{charge:u.ShortText({displayName:"Charge ID",description:"Only trigger for disputes related to this Charge ID (e.g., `ch_...`).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Only trigger for disputes related to this Payment Intent ID (e.g., `pi_...`).",required:!1})},outputSchema:St,sampleData:{id:"du_1MtJUT2eZvKYlo2CNaw2HvEv",object:"dispute",amount:1e3,balance_transactions:[],charge:"ch_1AZtxr2eZvKYlo2CJDX8whov",created:1680651737,currency:"usd",evidence_details:{due_by:1682294399,has_evidence:!1,past_due:!1,submission_count:0},is_charge_refundable:!0,livemode:!1,metadata:{},payment_intent:"pi_1AZtxr2eZvKYlo2CJDX8whov",reason:"general",status:"needs_response"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("charge.dispute.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_dispute_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_dispute_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/issuing/disputes",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"submitted",limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{charge:n,payment_intent:o}=e.propsValue;return n&&r.charge!==n?[]:o&&r.payment_intent!==o?[]:[r]}});var Dg=ee({auth:g,name:"new_payment_link",classification:"READ",displayName:"New Payment Link",description:"Fires when a new Payment Link is created.",aiMetadata:{description:"Fires when a new payment link is created in Stripe (the payment_link.created event), emitting the new payment link including its shareable URL. Use to react to payment-link creation, such as distributing the URL or logging it."},props:{},outputSchema:ze,sampleData:{id:"plink_1MoC3ULkdIwHu7ixZjtGpVl2",object:"payment_link",active:!0,after_completion:{hosted_confirmation:{custom_message:null},type:"hosted_confirmation"},allow_promotion_codes:!1,currency:"usd",customer_creation:"if_required",livemode:!1,metadata:{},payment_method_collection:"always",url:"https://buy.stripe.com/test_cN25nr0iZ7bUa7meUY"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("payment_link.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_payment_link_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_payment_link_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/payment_links",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var zg=ee({auth:g,name:"updated_subscription",classification:"READ",displayName:"Updated Subscription",description:"Fires when an existing subscription is changed.",aiMetadata:{description:"Fires when an existing subscription is updated in Stripe (the customer.subscription.updated event), emitting the changed subscription. Optional filters narrow firing to a target new status or a specific customer ID. Use to react to plan changes, status transitions, or quantity updates."},props:{status:u.StaticDropdown({displayName:"New Status",description:"Only trigger when the subscription is updated to this status.",required:!1,options:{options:[{label:"Incomplete",value:"incomplete"},{label:"Incomplete - Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Canceled",value:"canceled"},{label:"Unpaid",value:"unpaid"},{label:"Paused",value:"paused"}]}}),customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for subscriptions belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:xe,sampleData:{id:"sub_1MowQVLkdIwHu7ixeRlqHVzs",object:"subscription",application:null,application_fee_percent:null,automatic_tax:{enabled:!1},billing_cycle_anchor:1679609767,cancel_at_period_end:!1,canceled_at:null,collection_method:"charge_automatically",created:1679609767,currency:"usd",customer:"cus_Na6dX7aXxi11N4",items:{object:"list",data:[{id:"si_Na6dzxczY5fwHx",object:"subscription_item",price:{id:"price_1MowQULkdIwHu7ixraBm864M",object:"price",product:"prod_Na6dGcTsmU0I4R",unit_amount:2e3},quantity:1}]},latest_invoice:"in_1MowQWLkdIwHu7ixuzkSPfKd",livemode:!1,metadata:{plan:"premium"},start_date:1679609767,status:"active"},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("customer.subscription.updated",e.webhookUrl,e.auth.secret_text);await e.store.put("_updated_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_updated_subscription_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"incomplete",limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{status:n,customer:o}=e.propsValue;return n&&r.status!==n?[]:o&&r.customer!==o?[]:[r]}});var Mg=ee({auth:g,name:"checkout_session_completed",classification:"READ",displayName:"Checkout Session Completed",description:"Fires when a Stripe Checkout Session is successfully completed.",aiMetadata:{description:"Fires when a Stripe Checkout Session is successfully completed (the checkout.session.completed event), emitting the completed session including customer and payment details. An optional customer ID filter narrows firing to one customer. Use to react to a completed hosted checkout, such as fulfilling an order or granting access."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for checkout sessions created by this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:ur,sampleData:{id:"cs_test_a11YYufWQzNY63zpQ6QSNRQhkUpVph4WRmzW0zWJO2znZKdVujZ0N0S22u",object:"checkout.session",amount_subtotal:2198,amount_total:2198,created:1679600215,currency:"usd",customer:"cus_NWSaVkvdacCUi4",customer_details:{email:"jenny.rosen@example.com",name:"Jenny Rosen",phone:null},livemode:!1,mode:"payment",payment_intent:"pi_12345ABC",payment_status:"paid",status:"complete",success_url:"https://example.com/success",url:null},type:"WEBHOOK",async onEnable(e){let t=await _.subscribeWebhook("checkout.session.completed",e.webhookUrl,e.auth.secret_text);await e.store.put("_checkout_session_completed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_checkout_session_completed_trigger");t!=null&&await _.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/checkout/sessions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"complete",limit:"5"}});return H(t.body)||H(t.body.data)?[]:t.body.data},async run(e){let r=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&r.customer!==n?[]:[r]}});var Ug=x({name:"update_customer",classification:"WRITE",auth:g,displayName:"Update Customer",description:"Modify an existing customer\u2019s details.",audience:"human",aiMetadata:{description:"Updates fields on an existing Stripe customer (email, name, description, phone, address); only the fields you provide are changed. Use to correct or enrich a customer record identified by its customer ID. Idempotent in effect: repeating the same update yields the same final state.",idempotent:!0},props:{customer:_.customer,email:u.ShortText({displayName:"Email",required:!1}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Re,async run(e){let{customer:t,...r}=e.propsValue,n={};r.name&&(n.name=r.name),r.email&&(n.email=r.email),r.description&&(n.description=r.description),r.phone&&(n.phone=r.phone);let o={};return r.line1&&(o.line1=r.line1),r.city&&(o.city=r.city),r.state&&(o.state=r.state),r.postal_code&&(o.postal_code=r.postal_code),r.country&&(o.country=r.country),Object.keys(o).length>0&&(n.address=o),(await v.sendRequest({method:"POST",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var Lg=x({name:"create_payment_intent",classification:"WRITE",auth:g,displayName:"Create Payment (Payment Intent)",description:"Creates a new payment intent to start a payment flow.",audience:"human",aiMetadata:{description:"Creates a Stripe PaymentIntent for a given amount and currency to begin collecting a payment, optionally tied to a customer. Can run in two modes: leave it unconfirmed to obtain a client secret for client-side completion, or set confirm to immediately charge a supplied payment method (which then also requires a return URL). Not idempotent: each call starts a separate payment.",idempotent:!1},props:{amount:u.Number({displayName:"Amount",description:"The amount to charge, in a decimal format (e.g., 10.50 for $10.50).",required:!0}),currency:u.StaticDropdown({displayName:"Currency",description:"The three-letter ISO code for the currency.",required:!0,options:{options:[{label:"US Dollar",value:"usd"},{label:"Euro",value:"eur"},{label:"Pound Sterling",value:"gbp"},{label:"Australian Dollar",value:"aud"},{label:"Canadian Dollar",value:"cad"},{label:"Swiss Franc",value:"chf"},{label:"Chinese Yuan",value:"cny"},{label:"Japanese Yen",value:"jpy"},{label:"Indian Rupee",value:"inr"},{label:"Singapore Dollar",value:"sgd"}]}}),customer:_.customer,payment_method:u.ShortText({displayName:"Payment Method ID",description:"The ID of the Payment Method to attach (e.g., `pm_...`). Required if you want to confirm the payment immediately.",required:!1}),confirm:u.Checkbox({displayName:"Confirm Payment Immediately",description:"If true, Stripe will attempt to charge the provided payment method. A `Payment Method ID` is required.",required:!1,defaultValue:!1}),return_url:u.ShortText({displayName:"Return URL",description:"The URL to redirect your customer back to after they authenticate their payment. Required when confirming the payment.",required:!1}),description:u.LongText({displayName:"Description",required:!1}),receipt_email:u.ShortText({displayName:"Receipt Email",description:"The email address to send a receipt to. This will override the customer's email address.",required:!1})},outputSchema:Ie,async run(e){let{amount:t,currency:r,customer:n,payment_method:o,confirm:i,return_url:s,description:l,receipt_email:f}=e.propsValue;if(i&&!o)throw new Error("A Payment Method ID is required when 'Confirm Payment' is set to true.");if(i&&!s)throw new Error("A Return URL is required when 'Confirm Payment' is set to true.");let m={amount:Math.round(t*100),currency:r};return n&&(m.customer=n),o&&(m.payment_method=o),i&&(m.confirm=i),s&&(m.return_url=s),l&&(m.description=l),f&&(m.receipt_email=f),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:m})).body}});var qg=x({name:"create_product",classification:"WRITE",auth:g,displayName:"Create Product",description:"Create a new product object in Stripe.",audience:"human",aiMetadata:{description:"Creates a new product object in Stripe (the catalog item that prices attach to), with optional description, images, URL, and metadata. Use before creating a price or when adding a sellable item. Not idempotent: each call creates a distinct product.",idempotent:!1},props:{name:u.ShortText({displayName:"Product Name",description:"The product\u2019s name, meant to be displayable to the customer.",required:!0}),description:u.LongText({displayName:"Description",description:"The product\u2019s description, meant to be displayable to the customer.",required:!1}),active:u.Checkbox({displayName:"Active",description:"Whether the product is currently available for purchase. Defaults to true.",required:!1}),images:u.Array({displayName:"Image URLs",description:"A list of up to 8 URLs of images for this product.",required:!1}),url:u.ShortText({displayName:"Product URL",description:"A publicly-accessible online page for this product.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the product.",required:!1})},outputSchema:bt,async run(e){let{name:t,description:r,active:n,images:o,url:i,metadata:s}=e.propsValue,l={name:t};return r&&(l.description=r),n!==void 0&&(l.active=n),i&&(l.url=i),o&&Array.isArray(o)&&o.forEach((b,m)=>{l[`images[${m}]`]=b}),s&&typeof s=="object"&&Object.keys(s).forEach(b=>{l[`metadata[${b}]`]=s[b]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var jg=x({name:"create_price",classification:"WRITE",auth:g,displayName:"Create Price",description:"Create a price (one-time or recurring), associated with a product.",audience:"human",aiMetadata:{description:"Creates a price for an existing Stripe product, in either one-time or recurring mode depending on the selected billing interval. Use after creating a product to define what to charge before building a subscription or payment link. Requires the product ID; not idempotent, as each call creates a new price.",idempotent:!1},props:{product:_.product,unit_amount:u.Number({displayName:"Unit Amount",description:"The price amount as a decimal, for example, 25.50 for $25.50.",required:!0}),currency:u.StaticDropdown({displayName:"Currency",description:"The three-letter ISO code for the currency.",required:!0,options:{options:[{label:"US Dollar",value:"usd"},{label:"Euro",value:"eur"},{label:"Pound Sterling",value:"gbp"},{label:"Indian Rupee",value:"inr"},{label:"Australian Dollar",value:"aud"},{label:"Canadian Dollar",value:"cad"},{label:"Swiss Franc",value:"chf"},{label:"Chinese Yuan",value:"cny"},{label:"Japanese Yen",value:"jpy"},{label:"Singapore Dollar",value:"sgd"}]}}),recurring_interval:u.StaticDropdown({displayName:"Billing Interval",description:"Specify the billing frequency. Select 'One-Time' for a single, non-recurring payment.",required:!0,defaultValue:"one_time",options:{options:[{label:"One-Time",value:"one_time"},{label:"Daily",value:"day"},{label:"Weekly",value:"week"},{label:"Monthly",value:"month"},{label:"Yearly",value:"year"}]}}),recurring_interval_count:u.Number({displayName:"Interval Count",description:"The number of intervals between subscription billings (e.g., for billing every 3 months, set Interval to Monthly and Interval Count to 3). Only used for recurring prices.",required:!1})},outputSchema:Pt,async run(e){let{product:t,unit_amount:r,currency:n,recurring_interval:o,recurring_interval_count:i}=e.propsValue,s=Math.round(r*100),l={product:t,unit_amount:s,currency:n};return o!=="one_time"&&(l["recurring[interval]"]=o,i&&(l["recurring[interval_count]"]=i)),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var Fg=x({name:"create_subscription",classification:"WRITE",auth:g,displayName:"Create Subscription",description:"Start a subscription for a customer with specified items/prices.",audience:"human",aiMetadata:{description:"Starts a recurring subscription for an existing customer against one or more price IDs, with optional collection method, trial period, and default payment method. Use to enroll a customer in recurring billing. Requires a customer ID and at least one price; not idempotent, as each call creates a separate subscription.",idempotent:!1},props:{customer:_.customer,items:u.Array({displayName:"Subscription Items",description:"A list of prices to subscribe the customer to.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The ID of the price object (e.g., price_...). You can find this in your Stripe Dashboard under Products.",required:!0}),quantity:u.Number({displayName:"Quantity",description:"The number of units of this price to subscribe to. Defaults to 1.",required:!1})}}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"How to collect payment. 'charge_automatically' will try to bill the default payment method. 'send_invoice' will email an invoice.",required:!1,options:{options:[{label:"Charge Automatically",value:"charge_automatically"},{label:"Send Invoice",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Number of days before an invoice is due. Required if Collection Method is 'Send Invoice'.",required:!1}),trial_period_days:u.Number({displayName:"Trial Period (Days)",description:"Integer representing the number of trial days the customer receives before the subscription bills for the first time.",required:!1}),default_payment_method:u.ShortText({displayName:"Default Payment Method ID",description:"ID of the default payment method for the subscription (e.g., `pm_...`).",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:xe,async run(e){let{customer:t,items:r,collection_method:n,days_until_due:o,trial_period_days:i,default_payment_method:s,metadata:l}=e.propsValue,f={customer:t,collection_method:n,days_until_due:o,trial_period_days:i,default_payment_method:s,metadata:l};return Object.keys(f).forEach(m=>{(f[m]===void 0||f[m]===null)&&delete f[m]}),r&&Array.isArray(r)&&r.forEach((m,P)=>{let h=m;f[`items[${P}][price]`]=h.price,h.quantity&&(f[`items[${P}][quantity]`]=h.quantity)}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:f})).body}});var Bg=x({name:"cancel_subscription",classification:"DESTRUCTIVE",auth:g,displayName:"Cancel Subscription",description:"Cancel an existing subscription, either immediately or at the end of the current billing period.",audience:"human",aiMetadata:{description:"Cancels an existing Stripe subscription by its ID, in one of two modes: immediately, or scheduled to end at the close of the current billing period. Use to stop recurring billing for a customer. Effectively idempotent: re-running on an already-canceled subscription leaves it canceled.",idempotent:!0},props:{subscription:_.subscription,cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",description:"If true, the subscription remains active until the end of the current billing period. If false, it cancels immediately.",required:!1,defaultValue:!1})},outputSchema:xe,async run(e){let{subscription:t,cancel_at_period_end:r}=e.propsValue,n=Ae(e.auth.secret_text);return r?await n.subscriptions.update(t,{cancel_at_period_end:!0}):await n.subscriptions.cancel(t)}});var Gg=x({name:"retrieve_invoice",classification:"READ",auth:g,displayName:"Retrieve an Invoice",description:"Retrieves the details of an existing invoice by its ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe invoice by its invoice ID (e.g., in_...). Use when you have the exact invoice ID and need its current status, amounts, or hosted/PDF links. Read-only and idempotent.",idempotent:!0},props:{invoice_id:_.invoice},outputSchema:ge,async run(e){let{invoice_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Vg=x({name:"retrieve_payout",classification:"READ",auth:g,displayName:"Retrieve a Payout",description:"Retrieves the details of an existing payout by its ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe payout (funds sent to your bank account) by its payout ID (e.g., po_...). Use to check a payout's status, amount, or arrival date. Read-only and idempotent.",idempotent:!0},props:{payout_id:_.payout},outputSchema:xo,async run(e){let{payout_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payouts/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Hg=x({name:"create_refund",classification:"WRITE",auth:g,displayName:"Create a Refund",description:"Create a full or partial refund for a payment.",audience:"human",aiMetadata:{description:"Issues a refund against a payment identified by its PaymentIntent ID; refunds the full amount by default, or a partial amount if one is given, with an optional reason. Use to return funds to a customer for a captured payment. Not idempotent: each call creates a new refund and moves money again.",idempotent:!1},props:{payment_intent:_.paymentIntent,amount:u.Number({displayName:"Amount",description:"The amount to refund (e.g., 12.99). If left blank, a full refund will be issued.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",description:"An optional reason for the refund.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"}]}}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the refund.",required:!1})},outputSchema:xt,async run(e){let{payment_intent:t,amount:r,reason:n,metadata:o}=e.propsValue,i={payment_intent:t};return r!=null&&(i.amount=Math.round(r*100)),n&&(i.reason=n),o&&typeof o=="object"&&Object.keys(o).forEach(l=>{i[`metadata[${l}]`]=o[l]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Zg=x({name:"create_payment_link",classification:"WRITE",auth:g,displayName:"Create Payment Link",description:"Creates a shareable, Stripe-hosted payment link for one-time purchases or subscriptions.",audience:"human",aiMetadata:{description:"Creates a reusable, Stripe-hosted payment link for the given line items (price IDs and quantities), with optional after-completion redirect, promotion codes, and billing-address collection. Use to generate a shareable checkout URL without building a custom flow. Not idempotent: each call creates a new payment link.",idempotent:!1},props:{line_items:u.Array({displayName:"Line Items",description:"The products and quantities to include in the payment link.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The ID of the price object (e.g., price_1J2X3Y4Z...). Find this in your Stripe Dashboard under Products.",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),after_completion_type:u.StaticDropdown({displayName:"After Completion Behavior",description:"Controls the behavior after the purchase is complete. Defaults to showing Stripe's hosted confirmation page.",required:!1,options:{options:[{label:"Show Confirmation Page",value:"hosted_confirmation"},{label:"Redirect to URL",value:"redirect"}]}}),after_completion_redirect_url:u.ShortText({displayName:"Redirect URL",description:'The URL to redirect the customer to after a successful purchase. Only used if the behavior is set to "Redirect to URL".',required:!1}),allow_promotion_codes:u.Checkbox({displayName:"Allow Promotion Codes",description:"Enables the user to enter a promotion code on the Payment Link page.",required:!1}),billing_address_collection:u.StaticDropdown({displayName:"Billing Address Collection",description:"Describes whether Checkout should collect the customer\u2019s billing address.",required:!1,options:{options:[{label:"Auto",value:"auto"},{label:"Required",value:"required"}]}}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:ze,async run(e){let t=Ae(e.auth.secret_text),r=e.propsValue,n={line_items:r.line_items,allow_promotion_codes:r.allow_promotion_codes,billing_address_collection:r.billing_address_collection,metadata:r.metadata};return r.after_completion_type&&(n.after_completion={type:r.after_completion_type},r.after_completion_type==="redirect"&&r.after_completion_redirect_url&&(n.after_completion.redirect={url:r.after_completion_redirect_url})),await t.paymentLinks.create(n)}});var Wg=x({name:"deactivate_payment_link",classification:"DESTRUCTIVE",auth:g,displayName:"Deactivate Payment Link",description:"Disable or deactivate a Payment Link so it can no longer be used.",audience:"human",aiMetadata:{description:"Deactivates an existing Stripe payment link by its ID so it can no longer accept payments. Use to retire a shared checkout URL. Idempotent in effect: re-running on an already-inactive link leaves it inactive.",idempotent:!0},props:{payment_link_id:_.paymentLink},outputSchema:ze,async run(e){let{payment_link_id:t}=e.propsValue;return await Ae(e.auth.secret_text).paymentLinks.update(t,{active:!1})}});var Kg=x({name:"retrieve_payment_intent",classification:"READ",auth:g,displayName:"Find Payment (by Payment Intent ID)",description:"Retrieves the details of a payment by its unique Payment Intent ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single payment by its PaymentIntent ID (e.g., pi_...). Use when you have the exact ID and need the payment's current status, amount, or associated charge. Read-only and idempotent.",idempotent:!0},props:{payment_intent_id:_.paymentIntent},outputSchema:Ie,async run(e){let{payment_intent_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_intents/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Jg=x({name:"find_invoice",classification:"READ",auth:g,displayName:"Find Invoice",description:"Finds an invoice by its unique ID.",audience:"human",aiMetadata:{description:"Fetches a single Stripe invoice by its unique invoice ID (e.g., in_...). Use when you already have the exact invoice ID and need its current details. Read-only and idempotent.",idempotent:!0},props:{invoice_id:_.invoice},outputSchema:ge,async run(e){let{invoice_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Xg=x({name:"create_customer_ai",classification:"WRITE",auth:g,displayName:"Create Customer (Agent)",description:"Create a customer in Stripe.",audience:"ai",aiMetadata:{description:"Creates a new Stripe customer from an email and name, with optional phone and address. Use when onboarding a new payer before charging, invoicing, or subscribing them; to avoid duplicates, look the customer up first with Search Customers. Not idempotent: each call creates a distinct customer even with identical input.",idempotent:!1},props:{email:u.ShortText({displayName:"Email",required:!0}),name:u.ShortText({displayName:"Name",required:!0}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Re,async run(e){let{email:t,name:r,description:n,phone:o,line1:i,postal_code:s,city:l,state:f,country:b}=e.propsValue,m={email:t,name:r};n&&(m.description=n),o&&(m.phone=o);let P={};return i&&(P.line1=i),s&&(P.postal_code=s),l&&(P.city=l),f&&(P.state=f),b&&(P.country=b),Object.keys(P).forEach(d=>{m[`address[${d}]`]=P[d]}),(await v.sendRequest({method:"POST",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:m})).body}});var Yg=x({name:"get_customer",classification:"READ",auth:g,displayName:"Get Customer (Agent)",description:"Retrieve a Stripe customer by its ID.",audience:"ai",aiMetadata:{description:"Fetches the full details of a single Stripe customer by its customer ID (e.g., cus_...). Use when you already have the exact ID; to look a customer up by email use Search Customers, or List Customers to page through them. Read-only and idempotent.",idempotent:!0},props:{id:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0})},outputSchema:Re,async run(e){let t=e.propsValue.id;return(await v.sendRequest({method:"GET",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Qg=x({name:"update_customer_ai",classification:"WRITE",auth:g,displayName:"Update Customer (Agent)",description:"Modify an existing Stripe customer.",audience:"ai",aiMetadata:{description:"Updates fields on an existing Stripe customer (email, name, description, phone, address); only the fields you supply change. Use to correct or enrich a customer record identified by its customer ID. Idempotent: repeating the same update yields the same final state.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...) to update. Obtain it from Search Customers or List Customers.",required:!0}),email:u.ShortText({displayName:"Email",required:!1}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Re,async run(e){let{customer:t,...r}=e.propsValue,n={};r.name&&(n.name=r.name),r.email&&(n.email=r.email),r.description&&(n.description=r.description),r.phone&&(n.phone=r.phone);let o={};return r.line1&&(o.line1=r.line1),r.city&&(o.city=r.city),r.state&&(o.state=r.state),r.postal_code&&(o.postal_code=r.postal_code),r.country&&(o.country=r.country),Object.keys(o).forEach(s=>{n[`address[${s}]`]=o[s]}),(await v.sendRequest({method:"POST",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var ev=x({name:"search_customers",classification:"SEARCH",auth:g,displayName:"Search Customers (Agent)",description:"Search for Stripe customers by email or a raw search query.",audience:"ai",aiMetadata:{description:`Searches Stripe customers using the Stripe Search Query Language. Pass an email to match customers with that exact email, or supply a raw query for richer filters (e.g. "name:'Jane' OR metadata['plan']:'gold'"). Use to find an existing customer before creating/charging one; use Get Customer when you already have the cus_ ID. Read-only and idempotent.`,idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:"Match customers with this exact email. Ignored if a raw Query is provided.",required:!1}),query:u.ShortText({displayName:"Query",description:"A raw Stripe search query (e.g. email:'a@b.com', name:'Jane'). Overrides the Email field when set.",required:!1})},outputSchema:So,async run(e){let{email:t,query:r}=e.propsValue,n=r||(t?`email:'${t}'`:void 0);if(!n)throw new Error("Provide either an Email or a raw Query to search.");let o={query:n};return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var tv=x({name:"create_payment_intent_ai",classification:"WRITE",auth:g,displayName:"Create Payment Intent (Agent)",description:"Create a Stripe PaymentIntent to start a payment flow.",audience:"ai",aiMetadata:{description:"Creates a Stripe PaymentIntent for an amount and currency, optionally tied to a customer. Leave it unconfirmed to get a client secret for client-side completion, or set confirm with a payment method ID (and return URL) to charge immediately. Amount is a decimal in the major currency unit (e.g. 10.50 for $10.50). Not idempotent: each call starts a separate payment.",idempotent:!1},props:{amount:u.Number({displayName:"Amount",description:"The amount to charge, as a decimal in the major currency unit (e.g., 10.50 for $10.50).",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd, eur, gbp).",required:!0}),customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...) to associate. Obtain it from Search Customers or List Customers.",required:!1}),payment_method:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID to attach (e.g., pm_...). Required to confirm the payment immediately.",required:!1}),confirm:u.Checkbox({displayName:"Confirm Payment Immediately",description:"If true, Stripe attempts to charge the provided payment method. Requires a Payment Method ID and a Return URL.",required:!1,defaultValue:!1}),capture_method:u.StaticDropdown({displayName:"Capture Method",description:"When to capture funds. 'automatic' (default) captures immediately on confirmation; 'manual' authorizes only \u2014 funds are held and you capture later with Capture Payment Intent (auth-and-capture).",required:!1,options:{options:[{label:"Automatic",value:"automatic"},{label:"Manual (authorize only)",value:"manual"}]}}),return_url:u.ShortText({displayName:"Return URL",description:"URL to redirect the customer back to after authenticating the payment. Required when confirming.",required:!1}),description:u.LongText({displayName:"Description",required:!1}),receipt_email:u.ShortText({displayName:"Receipt Email",description:"Email to send a receipt to. Overrides the customer's email.",required:!1})},outputSchema:Ie,async run(e){let{amount:t,currency:r,customer:n,payment_method:o,confirm:i,return_url:s,description:l,receipt_email:f,capture_method:b}=e.propsValue;if(i&&!o)throw new Error("A Payment Method ID is required when 'Confirm Payment' is set to true.");if(i&&!s)throw new Error("A Return URL is required when 'Confirm Payment' is set to true.");let P={amount:Math.round(t*100),currency:r};return n&&(P.customer=n),o&&(P.payment_method=o),b&&(P.capture_method=b),i&&(P.confirm=i),s&&(P.return_url=s),l&&(P.description=l),f&&(P.receipt_email=f),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:P})).body}});var rv=x({name:"get_payment_intent",classification:"READ",auth:g,displayName:"Get Payment Intent (Agent)",description:"Retrieve a payment by its PaymentIntent ID.",audience:"ai",aiMetadata:{description:"Fetches a single payment by its PaymentIntent ID (e.g., pi_...). Use when you have the exact ID and need the current status, amount, or associated charge; use List/Search Payment Intents to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...). Obtain it from List Payment Intents or Search Payment Intents.",required:!0})},outputSchema:Ie,async run(e){let{payment_intent_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_intents/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var nv=x({name:"create_refund_ai",classification:"WRITE",auth:g,displayName:"Create Refund (Agent)",description:"Create a full or partial refund for a payment.",audience:"ai",aiMetadata:{description:"Issues a refund against a payment identified by its PaymentIntent ID; refunds the full amount by default, or a partial amount if given, with an optional reason. Amount is in the major currency unit as a decimal. Use to return funds for a captured payment. Not idempotent: each call creates a new refund and moves money again.",idempotent:!1},props:{payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to refund. Obtain it from List/Search Payment Intents.",required:!0}),amount:u.Number({displayName:"Amount",description:"The amount to refund as a decimal (e.g., 12.99). If left blank, a full refund is issued.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",description:"An optional reason for the refund.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"}]}}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the refund.",required:!1})},outputSchema:xt,async run(e){let{payment_intent:t,amount:r,reason:n,metadata:o}=e.propsValue,i={payment_intent:t};return r!=null&&(i.amount=Math.round(r*100)),n&&(i.reason=n),o&&typeof o=="object"&&Object.keys(o).forEach(l=>{i[`metadata[${l}]`]=o[l]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var ov=x({name:"create_invoice_ai",classification:"WRITE",auth:g,displayName:"Create Invoice (Agent)",description:"Create a draft invoice in Stripe.",audience:"ai",aiMetadata:{description:"Creates a draft invoice for an existing customer in the given currency. Use to bill a customer for pending invoice items; add lines with Create Invoice Item / Add Invoice Lines, then Finalize Invoice and Send Invoice. Requires a valid customer ID. Not idempotent: each call creates a separate invoice.",idempotent:!1},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),description:u.LongText({displayName:"Description",description:"Description for the invoice.",required:!1}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"How to collect payment. 'charge_automatically' (default) charges the customer's default payment method when finalized; 'send_invoice' emails the customer a payable invoice (requires Days Until Due) and is the only method that lets you later call Send Invoice.",required:!1,options:{options:[{label:"Charge automatically",value:"charge_automatically"},{label:"Send invoice (email)",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Number of days until the invoice is due. Required when Collection Method is 'send_invoice'.",required:!1})},outputSchema:ge,async run(e){let{customer_id:t,currency:r,description:n,collection_method:o,days_until_due:i}=e.propsValue;if(o==="send_invoice"&&i==null)throw new Error("days_until_due is required when collection_method is 'send_invoice'.");let s={customer:t,currency:r};return n&&(s.description=n),o&&(s.collection_method=o),o==="send_invoice"&&i!==void 0&&i!==null&&(s.days_until_due=i),(await v.sendRequest({method:"POST",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:s})).body}});var iv=x({name:"get_invoice",classification:"READ",auth:g,displayName:"Get Invoice (Agent)",description:"Retrieve a Stripe invoice by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe invoice by its invoice ID (e.g., in_...). Use when you have the exact ID and need its current status, amounts, lines, or hosted/PDF links; use List/Search Invoices to discover IDs. Read-only and idempotent.",idempotent:!0},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The Stripe invoice ID (e.g., in_...). Obtain it from List Invoices or Search Invoices.",required:!0})},outputSchema:ge,async run(e){let{invoice_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var av=x({name:"create_product_ai",classification:"WRITE",auth:g,displayName:"Create Product (Agent)",description:"Create a new product object in Stripe.",audience:"ai",aiMetadata:{description:"Creates a new Stripe product (the catalog item that prices attach to), with optional description, images, URL, and metadata. Use before creating a price or when adding a sellable item; to archive a product use Update Product with active=false. Not idempotent: each call creates a distinct product.",idempotent:!1},props:{name:u.ShortText({displayName:"Product Name",description:"The product name, displayable to the customer.",required:!0}),description:u.LongText({displayName:"Description",description:"The product description, displayable to the customer.",required:!1}),active:u.Checkbox({displayName:"Active",description:"Whether the product is currently available for purchase. Defaults to true.",required:!1}),images:u.Array({displayName:"Image URLs",description:"A list of up to 8 URLs of images for this product.",required:!1}),url:u.ShortText({displayName:"Product URL",description:"A publicly-accessible online page for this product.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the product.",required:!1})},outputSchema:bt,async run(e){let{name:t,description:r,active:n,images:o,url:i,metadata:s}=e.propsValue,l={name:t};return r&&(l.description=r),n!==void 0&&(l.active=n),i&&(l.url=i),o&&Array.isArray(o)&&o.forEach((b,m)=>{l[`images[${m}]`]=b}),s&&typeof s=="object"&&Object.keys(s).forEach(b=>{l[`metadata[${b}]`]=s[b]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var sv=x({name:"create_price_ai",classification:"WRITE",auth:g,displayName:"Create Price (Agent)",description:"Create a one-time or recurring price for a product.",audience:"ai",aiMetadata:{description:"Creates a price for an existing Stripe product, one-time or recurring depending on the chosen billing interval. Amount is a decimal in the major currency unit. Use after Create Product to define what to charge before building a subscription or payment link. Requires the product ID. Not idempotent: each call creates a new price.",idempotent:!1},props:{product:u.ShortText({displayName:"Product ID",description:"The Stripe product ID (e.g., prod_...) this price attaches to. Obtain it from List/Search Products or Create Product.",required:!0}),unit_amount:u.Number({displayName:"Unit Amount",description:"The price amount as a decimal (e.g., 25.50 for $25.50).",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),recurring_interval:u.StaticDropdown({displayName:"Billing Interval",description:"Billing frequency. Select 'One-Time' for a single, non-recurring payment.",required:!0,defaultValue:"one_time",options:{options:[{label:"One-Time",value:"one_time"},{label:"Daily",value:"day"},{label:"Weekly",value:"week"},{label:"Monthly",value:"month"},{label:"Yearly",value:"year"}]}}),recurring_interval_count:u.Number({displayName:"Interval Count",description:"Number of intervals between billings (e.g., Monthly + count 3 = every 3 months). Only used for recurring prices.",required:!1})},outputSchema:Pt,async run(e){let{product:t,unit_amount:r,currency:n,recurring_interval:o,recurring_interval_count:i}=e.propsValue,s=Math.round(r*100),l={product:t,unit_amount:s,currency:n};return o!=="one_time"&&(l["recurring[interval]"]=o,i&&(l["recurring[interval_count]"]=i)),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var uv=x({name:"create_subscription_ai",classification:"WRITE",auth:g,displayName:"Create Subscription (Agent)",description:"Start a subscription for a customer with specified prices.",audience:"ai",aiMetadata:{description:"Starts a recurring subscription for an existing customer against one or more price IDs, with optional collection method, trial period, and default payment method. Use to enroll a customer in recurring billing. Requires a customer ID and at least one price. Not idempotent: each call creates a separate subscription.",idempotent:!1},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0}),items:u.Array({displayName:"Subscription Items",description:"A list of prices to subscribe the customer to.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),quantity:u.Number({displayName:"Quantity",description:"Number of units of this price. Defaults to 1.",required:!1})}}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"'charge_automatically' bills the default payment method; 'send_invoice' emails an invoice.",required:!1,options:{options:[{label:"Charge Automatically",value:"charge_automatically"},{label:"Send Invoice",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Days before an invoice is due. Required if Collection Method is 'Send Invoice'.",required:!1}),trial_period_days:u.Number({displayName:"Trial Period (Days)",description:"Number of trial days before the subscription bills for the first time.",required:!1}),default_payment_method:u.ShortText({displayName:"Default Payment Method ID",description:"ID of the default payment method (e.g., pm_...).",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:xe,async run(e){let{customer:t,items:r,collection_method:n,days_until_due:o,trial_period_days:i,default_payment_method:s,metadata:l}=e.propsValue;if(n==="send_invoice"&&o==null)throw new Error("days_until_due is required when collection_method is 'send_invoice'.");let f={customer:t,collection_method:n,days_until_due:o,trial_period_days:i,default_payment_method:s};return Object.keys(f).forEach(m=>{(f[m]===void 0||f[m]===null)&&delete f[m]}),n!=="send_invoice"&&delete f.days_until_due,r&&Array.isArray(r)&&r.forEach((m,P)=>{let h=m;f[`items[${P}][price]`]=h.price,h.quantity&&(f[`items[${P}][quantity]`]=h.quantity)}),l&&typeof l=="object"&&Object.keys(l).forEach(m=>{f[`metadata[${m}]`]=l[m]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:f})).body}});var cv=x({name:"cancel_subscription_ai",classification:"DESTRUCTIVE",auth:g,displayName:"Cancel Subscription (Agent)",description:"Cancel a subscription immediately or at the end of the billing period.",audience:"ai",aiMetadata:{description:"Cancels an existing Stripe subscription by its ID, either immediately or scheduled to end at the close of the current billing period (via Cancel at Period End). Use to stop recurring billing. Idempotent: re-running on an already-canceled subscription leaves it canceled.",idempotent:!0},props:{subscription:u.ShortText({displayName:"Subscription ID",description:"The Stripe subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",description:"If true, the subscription stays active until the end of the current billing period. If false, it cancels immediately.",required:!1,defaultValue:!1})},outputSchema:xe,async run(e){let{subscription:t,cancel_at_period_end:r}=e.propsValue,n=Ae(e.auth.secret_text);return r?await n.subscriptions.update(t,{cancel_at_period_end:!0}):await n.subscriptions.cancel(t)}});var HI=[{label:"All Statuses",value:""},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}],lv=x({name:"search_subscriptions_ai",classification:"SEARCH",auth:g,displayName:"Search Subscriptions (Agent)",description:"Search subscriptions by price ID, status, customer ID and other filters.",audience:"ai",aiMetadata:{description:"Lists and filters Stripe subscriptions by price ID, status, customer ID, and creation date range, optionally expanding full customer details. Use to find subscriptions matching criteria or audit a customer's subscriptions; use Get Subscription when you already have the sub_ ID. Read-only and idempotent.",idempotent:!0},props:{price_ids:u.LongText({displayName:"Price IDs",description:"Comma-separated list of price IDs to filter by (e.g., price_1ABC123, price_2DEF456)",required:!1}),status:u.StaticDropdown({displayName:"Subscription Status",description:"Filter by subscription status",required:!1,options:{options:HI}}),customer_id:u.ShortText({displayName:"Customer ID",description:"Filter by specific customer ID (optional)",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Filter subscriptions created after this date (YYYY-MM-DD format)",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Filter subscriptions created before this date (YYYY-MM-DD format)",required:!1}),limit:u.Number({displayName:"Limit",description:"Maximum number of subscriptions to return (default: 100, set to 0 for all)",required:!1,defaultValue:100}),fetch_all:u.Checkbox({displayName:"Fetch All Results",description:"Fetch all matching subscriptions (ignores limit, may take longer for large datasets)",required:!1,defaultValue:!1}),include_customer_details:u.Checkbox({displayName:"Include Customer Details",description:"Fetch detailed customer information for each subscription",required:!1,defaultValue:!0})},outputSchema:To,async run(e){let{price_ids:t,status:r,customer_id:n,created_after:o,created_before:i,limit:s=100,fetch_all:l=!1,include_customer_details:f=!0}=e.propsValue,b=a(T=>{let A=new URLSearchParams;if(A.append("limit","100"),A.append("expand[]","data.items.data.price"),f&&A.append("expand[]","data.customer"),r&&A.append("status",r),n&&A.append("customer",n),o){let k=Math.floor(new Date(o).getTime()/1e3);A.append("created[gte]",k.toString())}if(i){let k=Math.floor(new Date(i).getTime()/1e3);A.append("created[lte]",k.toString())}return T&&A.append("starting_after",T),A},"buildQueryParams"),m=[],P=!0,h,d=0,y=l?50:Math.ceil(s/100);for(;P&&d<y;){let T=b(h),A=await v.sendRequest({method:"GET",url:`${_.baseUrl}/subscriptions?${T.toString()}`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"}});if(!A.body)throw new Error("Failed to fetch subscriptions from Stripe");let k=A.body.data;if(m=m.concat(k),P=A.body.has_more,d++,P&&k.length>0&&(h=k[k.length-1].id),!l&&m.length>=s){m=m.slice(0,s);break}}let I=m;if(t&&t.trim()){let T=t.split(",").map(A=>A.trim()).filter(A=>A.length>0);T.length>0&&(I=I.filter(A=>A.items.data.some(k=>k.price&&typeof k.price=="object"&&T.includes(k.price.id))))}let S=await Promise.all(I.map(async T=>{let A={...T};if(f){if(typeof T.customer=="object"&&T.customer!==null&&!("deleted"in T.customer&&T.customer.deleted))A.customer=T.customer;else if(typeof T.customer=="string")try{let k=await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers/${T.customer}`,headers:{Authorization:"Bearer "+e.auth.secret_text}});A.customer=k.body}catch(k){console.warn(`Failed to fetch customer details for ${T.customer}:`,k)}}return A}));return{success:!0,count:S.length,total_fetched:m.length,requests_made:d,has_more_available:P&&!l,pagination_info:{limit_requested:l?"All":s,fetch_all_enabled:l,max_requests_limit:y},subscriptions:S,filters_applied:{price_ids:t?t.split(",").map(T=>T.trim()).filter(T=>T.length>0):null,status:r||null,customer_id:n||null,created_after:o||null,created_before:i||null,limit:s,fetch_all:l,include_customer_details:f}}}});var pv=x({name:"create_payment_link_ai",classification:"WRITE",auth:g,displayName:"Create Payment Link (Agent)",description:"Create a shareable, Stripe-hosted payment link.",audience:"ai",aiMetadata:{description:"Creates a reusable, Stripe-hosted payment link for the given line items (price IDs and quantities), with optional after-completion redirect, promotion codes, and billing-address collection. Use to generate a shareable checkout URL without building a custom flow; for a richer one-off hosted page use Create Checkout Session. Not idempotent: each call creates a new payment link.",idempotent:!1},props:{line_items:u.Array({displayName:"Line Items",description:"The products and quantities to include in the payment link.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),after_completion_type:u.StaticDropdown({displayName:"After Completion Behavior",description:"Behavior after purchase completes. Defaults to Stripe's hosted confirmation page.",required:!1,options:{options:[{label:"Show Confirmation Page",value:"hosted_confirmation"},{label:"Redirect to URL",value:"redirect"}]}}),after_completion_redirect_url:u.ShortText({displayName:"Redirect URL",description:'URL to redirect to after a successful purchase. Only used when behavior is "Redirect to URL".',required:!1}),allow_promotion_codes:u.Checkbox({displayName:"Allow Promotion Codes",description:"Allow the customer to enter a promotion code.",required:!1}),billing_address_collection:u.StaticDropdown({displayName:"Billing Address Collection",description:"Whether Checkout collects the customer's billing address.",required:!1,options:{options:[{label:"Auto",value:"auto"},{label:"Required",value:"required"}]}}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:ze,async run(e){let t=Ae(e.auth.secret_text),r=e.propsValue,n={line_items:r.line_items,allow_promotion_codes:r.allow_promotion_codes,billing_address_collection:r.billing_address_collection,metadata:r.metadata};return r.after_completion_type&&(n.after_completion={type:r.after_completion_type},r.after_completion_type==="redirect"&&r.after_completion_redirect_url&&(n.after_completion.redirect={url:r.after_completion_redirect_url})),await t.paymentLinks.create(n)}});var dv=x({name:"deactivate_payment_link_ai",classification:"DESTRUCTIVE",auth:g,displayName:"Deactivate Payment Link (Agent)",description:"Deactivate a payment link so it can no longer be used.",audience:"ai",aiMetadata:{description:"Deactivates an existing Stripe payment link by its ID so it can no longer accept payments (sets active=false). Use to retire a shared checkout URL; use Get/List Payment Links to find the ID. Idempotent: re-running on an already-inactive link leaves it inactive.",idempotent:!0},props:{payment_link_id:u.ShortText({displayName:"Payment Link ID",description:"The payment link ID (e.g., plink_...). Obtain it from List Payment Links.",required:!0})},outputSchema:ze,async run(e){let{payment_link_id:t}=e.propsValue;return await Ae(e.auth.secret_text).paymentLinks.update(t,{active:!1})}});var mv=x({name:"get_payout",classification:"READ",auth:g,displayName:"Get Payout (Agent)",description:"Retrieve a Stripe payout by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe payout (funds sent to your bank account) by its payout ID (e.g., po_...). Use to check a payout's status, amount, or arrival date; use List Payouts to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payout_id:u.ShortText({displayName:"Payout ID",description:"The Stripe payout ID (e.g., po_...). Obtain it from List Payouts.",required:!0})},outputSchema:xo,async run(e){let{payout_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payouts/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var fv=x({name:"list_customers",classification:"SEARCH",auth:g,displayName:"List Customers (Agent)",description:"List Stripe customers, optionally filtered by email.",audience:"ai",aiMetadata:{description:"Pages through Stripe customers, newest first, optionally filtered by an exact email. Use to enumerate customers or resolve a customer ID; for query-language matching use Search Customers, or Get Customer when you have the cus_ ID. Read-only and idempotent.",idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:"Filter to customers with this exact email.",required:!1}),limit:u.Number({displayName:"Limit",description:"Number of customers to return (1-100, default 10).",required:!1}),starting_after:u.ShortText({displayName:"Starting After",description:"A customer ID; returns the page of results after this cursor for pagination.",required:!1})},outputSchema:Dd,async run(e){let{email:t,limit:r,starting_after:n}=e.propsValue,o={};return t&&(o.email=t),r&&(o.limit=r.toString()),n&&(o.starting_after=n),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var hv=x({name:"confirm_payment_intent",classification:"WRITE",auth:g,displayName:"Confirm Payment Intent (Agent)",description:"Confirm a PaymentIntent to attempt the charge.",audience:"ai",aiMetadata:{description:"Confirms a previously-created PaymentIntent to attempt collecting the payment, optionally supplying a payment method and return URL. Use when a PaymentIntent was created unconfirmed and you now want to charge it; Create Payment Intent can also confirm inline. Money-moving and not idempotent.",idempotent:!1},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to confirm. Obtain it from List/Search Payment Intents.",required:!0}),payment_method:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID to use (e.g., pm_...).",required:!1}),return_url:u.ShortText({displayName:"Return URL",description:"URL to redirect to after authentication. Required for redirect-based payment methods.",required:!1})},outputSchema:Ie,async run(e){let{payment_intent_id:t,payment_method:r,return_url:n}=e.propsValue,o={};return r&&(o.payment_method=r),n&&(o.return_url=n),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_intents/${t}/confirm`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:o})).body}});var yv=x({name:"cancel_payment_intent",classification:"DESTRUCTIVE",auth:g,displayName:"Cancel Payment Intent (Agent)",description:"Cancel a PaymentIntent that has not been captured.",audience:"ai",aiMetadata:{description:"Cancels a PaymentIntent that has not yet been captured (e.g., a manual-capture authorization or an abandoned payment), with an optional cancellation reason. Use to release an authorization or abandon a payment. Idempotent: re-running on an already-canceled PaymentIntent leaves it canceled.",idempotent:!0},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to cancel. Obtain it from List/Search Payment Intents.",required:!0}),cancellation_reason:u.StaticDropdown({displayName:"Cancellation Reason",description:"An optional reason for the cancellation.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"},{label:"Abandoned",value:"abandoned"}]}})},outputSchema:Ie,async run(e){let{payment_intent_id:t,cancellation_reason:r}=e.propsValue,n={};return r&&(n.cancellation_reason=r),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_intents/${t}/cancel`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var gv=x({name:"capture_payment_intent",classification:"WRITE",auth:g,displayName:"Capture Payment Intent (Agent)",description:"Capture funds from an authorized PaymentIntent.",audience:"ai",aiMetadata:{description:"Captures the funds of a PaymentIntent that was authorized with manual capture (status requires_capture). Optionally capture a partial amount (in the smallest currency unit, e.g. cents) and mark it as the final capture. Use to settle a held authorization. Money-moving and not idempotent.",idempotent:!1},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to capture. Obtain it from List/Search Payment Intents.",required:!0}),amount_to_capture:u.Number({displayName:"Amount to Capture",description:"The amount to capture in the smallest currency unit (e.g., 1050 for $10.50). Defaults to the full authorized amount.",required:!1}),final_capture:u.Checkbox({displayName:"Final Capture",description:"If true, the remaining uncaptured amount is released back to the customer.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to attach.",required:!1})},outputSchema:Ie,async run(e){let{payment_intent_id:t,amount_to_capture:r,final_capture:n,metadata:o}=e.propsValue,i={};return r!=null&&(i.amount_to_capture=r),n!==void 0&&(i.final_capture=n),o&&typeof o=="object"&&Object.keys(o).forEach(l=>{i[`metadata[${l}]`]=o[l]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_intents/${t}/capture`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var vv=x({name:"list_payment_intents",classification:"SEARCH",auth:g,displayName:"List Payment Intents (Agent)",description:"List Stripe PaymentIntents.",audience:"ai",aiMetadata:{description:"Pages through PaymentIntents, newest first, optionally filtered by customer or a created timestamp range. Use to enumerate payments or resolve a PaymentIntent ID; for query-language matching use Search Payment Intents, or Get Payment Intent when you have the pi_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to PaymentIntents for this customer (cus_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Only return PaymentIntents created at or after this time.",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Only return PaymentIntents created at or before this time.",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1}),starting_after:u.ShortText({displayName:"Starting After",description:"A PaymentIntent ID cursor for pagination.",required:!1})},outputSchema:Fd,async run(e){let{customer:t,created_after:r,created_before:n,limit:o,starting_after:i}=e.propsValue,s={};return t&&(s.customer=t),o&&(s.limit=o.toString()),i&&(s.starting_after=i),r&&(s["created[gte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),n&&(s["created[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:s})).body}});var _v=x({name:"search_payment_intents",classification:"SEARCH",auth:g,displayName:"Search Payment Intents (Agent)",description:"Search PaymentIntents with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches PaymentIntents using the Stripe Search Query Language (e.g. "status:'succeeded' AND customer:'cus_...'"). Use for ad-hoc filtered lookups; use List Payment Intents for simple paging or Get Payment Intent when you have the pi_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. status:'succeeded' AND amount>1000).",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:im,async run(e){let{query:t,limit:r}=e.propsValue,n={query:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_intents/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var bv=x({name:"retrieve_charge",classification:"READ",auth:g,displayName:"Retrieve Charge (Agent)",description:"Retrieve a Stripe charge by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe charge by its charge ID (e.g., ch_...). Charges are the legacy, read-mostly view of a payment; for the modern object use Get Payment Intent. Use List/Search Charges to discover IDs. Read-only and idempotent.",idempotent:!0},props:{charge_id:u.ShortText({displayName:"Charge ID",description:"The Stripe charge ID (e.g., ch_...). Obtain it from List Charges or Search Charges.",required:!0})},outputSchema:ar,async run(e){let{charge_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/charges/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Pv=x({name:"list_charges",classification:"SEARCH",auth:g,displayName:"List Charges (Agent)",description:"List Stripe charges.",audience:"ai",aiMetadata:{description:"Pages through charges, newest first, optionally filtered by customer, PaymentIntent, or a created timestamp range. Use to enumerate charges or resolve a charge ID; for query-language matching use Search Charges. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to charges for this customer (cus_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to charges for this PaymentIntent (pi_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Bd,async run(e){let{customer:t,payment_intent:r,created_after:n,created_before:o,limit:i}=e.propsValue,s={};return t&&(s.customer=t),r&&(s.payment_intent=r),i&&(s.limit=i.toString()),n&&(s["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),o&&(s["created[lte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/charges`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:s})).body}});var xv=x({name:"search_charges",classification:"SEARCH",auth:g,displayName:"Search Charges (Agent)",description:"Search charges with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches charges using the Stripe Search Query Language (e.g. "status:'succeeded' AND amount>1000"). Use for ad-hoc filtered lookups; use List Charges for simple paging or Retrieve Charge when you have the ch_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. metadata['order_id']:'6735').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:nm,async run(e){let{query:t,limit:r}=e.propsValue,n={query:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/charges/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Sv=x({name:"get_refund",classification:"READ",auth:g,displayName:"Get Refund (Agent)",description:"Retrieve a Stripe refund by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe refund by its refund ID (e.g., re_...) to check its status and amount. Use List Refunds to discover IDs. Read-only and idempotent.",idempotent:!0},props:{refund_id:u.ShortText({displayName:"Refund ID",description:"The Stripe refund ID (e.g., re_...). Obtain it from List Refunds.",required:!0})},outputSchema:xt,async run(e){let{refund_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/refunds/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Tv=x({name:"list_refunds",classification:"SEARCH",auth:g,displayName:"List Refunds (Agent)",description:"List Stripe refunds.",audience:"ai",aiMetadata:{description:"Pages through refunds, newest first, optionally filtered by PaymentIntent or charge. Use to enumerate refunds for a payment or resolve a refund ID; use Get Refund when you have the re_ ID. Read-only and idempotent.",idempotent:!0},props:{payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to refunds for this PaymentIntent (pi_...).",required:!1}),charge:u.ShortText({displayName:"Charge ID",description:"Filter to refunds for this charge (ch_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Gd,async run(e){let{payment_intent:t,charge:r,limit:n}=e.propsValue,o={};return t&&(o.payment_intent=t),r&&(o.charge=r),n&&(o.limit=n.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var Ev=x({name:"list_invoices",classification:"SEARCH",auth:g,displayName:"List Invoices (Agent)",description:"List Stripe invoices.",audience:"ai",aiMetadata:{description:"Pages through invoices, newest first, optionally filtered by customer, status, or subscription. Use to enumerate invoices or resolve an invoice ID; for query-language matching use Search Invoices, or Get Invoice when you have the in_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to invoices for this customer (cus_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",description:"Filter by invoice status.",required:!1,options:{options:[{label:"Draft",value:"draft"},{label:"Open",value:"open"},{label:"Paid",value:"paid"},{label:"Uncollectible",value:"uncollectible"},{label:"Void",value:"void"}]}}),subscription:u.ShortText({displayName:"Subscription ID",description:"Filter to invoices for this subscription (sub_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Vd,async run(e){let{customer:t,status:r,subscription:n,limit:o}=e.propsValue,i={};return t&&(i.customer=t),r&&(i.status=r),n&&(i.subscription=n),o&&(i.limit=o.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var Iv=x({name:"search_invoices",classification:"SEARCH",auth:g,displayName:"Search Invoices (Agent)",description:"Search invoices with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches invoices using the Stripe Search Query Language (e.g. "status:'open' AND customer:'cus_...'"). Use for ad-hoc filtered lookups; use List Invoices for simple paging or Get Invoice when you have the in_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. total>1000 AND status:'paid').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:om,async run(e){let{query:t,limit:r}=e.propsValue,n={query:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Av=x({name:"finalize_invoice",classification:"WRITE",auth:g,displayName:"Finalize Invoice (Agent)",description:"Finalize a draft invoice so it becomes payable.",audience:"ai",aiMetadata:{description:"Finalizes a draft Stripe invoice, locking its line items and making it payable. Use after adding all line items and before Send Invoice. Not idempotent: it errors if the invoice is already finalized.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The draft invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),auto_advance:u.Checkbox({displayName:"Auto Advance",description:"If true, Stripe automatically collects the invoice (sends/charges per its settings) after finalizing.",required:!1})},outputSchema:ge,async run(e){let{invoice_id:t,auto_advance:r}=e.propsValue,n={};return r!==void 0&&(n.auto_advance=r),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/invoices/${t}/finalize`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var wv=x({name:"send_invoice",classification:"WRITE",auth:g,displayName:"Send Invoice (Agent)",description:"Email a finalized invoice to the customer.",audience:"ai",aiMetadata:{description:"Emails a finalized Stripe invoice to the customer. The invoice must already be finalized (use Finalize Invoice first). Not idempotent: each call sends the invoice email again.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The finalized invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0})},outputSchema:ge,async run(e){let{invoice_id:t}=e.propsValue;return(await v.sendRequest({method:"POST",url:`${_.baseUrl}/invoices/${t}/send`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var kv=x({name:"add_invoice_lines",classification:"WRITE",auth:g,displayName:"Add Invoice Lines (Agent)",description:"Bulk-add line items to a draft invoice.",audience:"ai",aiMetadata:{description:"Adds one or more line items to a draft Stripe invoice in a single call. Each line supplies either a price ID or an ad-hoc amount (smallest currency unit) plus currency, with an optional description and quantity. Use to populate a draft before Finalize Invoice. Not idempotent: each call appends new lines.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The draft invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),lines:u.Array({displayName:"Lines",description:"The line items to add to the invoice.",required:!0,properties:{description:u.ShortText({displayName:"Description",required:!1}),amount:u.Number({displayName:"Amount",description:"Ad-hoc amount in the smallest currency unit (e.g., 1050 for $10.50), in the invoice's currency. Provide either an Amount or a Price ID (not both).",required:!1}),price:u.ShortText({displayName:"Price ID",description:"A price ID (e.g., price_...) instead of an ad-hoc amount.",required:!1}),quantity:u.Number({displayName:"Quantity",required:!1})}})},outputSchema:ge,async run(e){let{invoice_id:t,lines:r}=e.propsValue;if(!r||!Array.isArray(r)||r.length===0)throw new Error("Provide at least one line item to add.");let n={};return r.forEach((i,s)=>{i.description!==void 0&&i.description!==null&&i.description!==""&&(n[`lines[${s}][description]`]=i.description),i.price?(n[`lines[${s}][pricing][price]`]=i.price,i.quantity!==void 0&&i.quantity!==null&&(n[`lines[${s}][quantity]`]=i.quantity)):i.amount!==void 0&&i.amount!==null&&(n[`lines[${s}][amount]`]=i.amount)}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/invoices/${t}/add_lines`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var Rv=x({name:"list_invoice_lines",classification:"SEARCH",auth:g,displayName:"List Invoice Lines (Agent)",description:"List the line items on an invoice.",audience:"ai",aiMetadata:{description:"Pages through the line items of a single Stripe invoice. Use when you need only the lines; the lines are also returned inline by Get Invoice. Read-only and idempotent.",idempotent:!0},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Hd,async run(e){let{invoice_id:t,limit:r}=e.propsValue,n={};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/invoices/${t}/lines`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Ov=x({name:"create_invoice_item",classification:"WRITE",auth:g,displayName:"Create Invoice Item (Agent)",description:"Add a one-off pending line item to a customer.",audience:"ai",aiMetadata:{description:"Creates a pending invoice item for a customer that attaches to their next invoice, or to a specific invoice if one is given. Amount is in the smallest currency unit (e.g. cents) \u2014 pass a raw integer, not a decimal. Use to add ad-hoc charges before invoicing. Not idempotent: each call creates a new item.",idempotent:!1},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search/List Customers.",required:!0}),amount:u.Number({displayName:"Amount",description:"The amount in the smallest currency unit (e.g., 1050 for $10.50). Raw integer, not a decimal.",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),description:u.LongText({displayName:"Description",required:!1}),invoice:u.ShortText({displayName:"Invoice ID",description:"Attach to this specific draft invoice (in_...) instead of the next upcoming one.",required:!1}),price:u.ShortText({displayName:"Price ID",description:"Use a price ID (price_...) instead of an ad-hoc amount. If set, leave Amount/Currency blank.",required:!1})},outputSchema:Cd,async run(e){let{customer:t,amount:r,currency:n,description:o,invoice:i,price:s}=e.propsValue,l={customer:t};return s?l.price=s:(l.amount=r,l.currency=n),o&&(l.description=o),i&&(l.invoice=i),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/invoiceitems`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var Cv=x({name:"update_product",classification:"WRITE",auth:g,displayName:"Update Product (Agent)",description:"Update or archive a Stripe product.",audience:"ai",aiMetadata:{description:'Updates a Stripe product (rename, change description/metadata, or set active=false to archive it). Archiving is the agent path to "delete" a product, since products with prices cannot be hard-deleted. Only the fields you supply change. Idempotent: re-applying the same update converges.',idempotent:!0},props:{product_id:u.ShortText({displayName:"Product ID",description:"The product ID (e.g., prod_...). Obtain it from List/Search Products.",required:!0}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),active:u.Checkbox({displayName:"Active",description:"Set to false to archive the product.",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:bt,async run(e){let{product_id:t,name:r,description:n,active:o,metadata:i}=e.propsValue,s={};return r&&(s.name=r),n&&(s.description=n),o!==void 0&&(s.active=o),i&&typeof i=="object"&&Object.keys(i).forEach(f=>{s[`metadata[${f}]`]=i[f]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/products/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:s})).body}});var $v=x({name:"get_product",classification:"READ",auth:g,displayName:"Get Product (Agent)",description:"Retrieve a Stripe product by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe product by its product ID (e.g., prod_...). Use List/Search Products to discover IDs. Read-only and idempotent.",idempotent:!0},props:{product_id:u.ShortText({displayName:"Product ID",description:"The product ID (e.g., prod_...). Obtain it from List/Search Products.",required:!0})},outputSchema:bt,async run(e){let{product_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/products/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Nv=x({name:"list_products",classification:"SEARCH",auth:g,displayName:"List Products (Agent)",description:"List Stripe products.",audience:"ai",aiMetadata:{description:"Pages through products, newest first, optionally filtered by active status. Use to enumerate the catalog or resolve a product ID; for name matching use Search Products, or Get Product when you have the prod_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",description:"Filter by active state.",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:zd,async run(e){let{active:t,limit:r}=e.propsValue,n={};return t&&(n.active=t),r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Dv=x({name:"search_products",classification:"SEARCH",auth:g,displayName:"Search Products (Agent)",description:"Search products with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches products using the Stripe Search Query Language (e.g. "active:'true' AND name~'shirt'"). Use for name/metadata matching; use List Products for simple paging or Get Product when you have the prod_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. name~'shirt').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:sm,async run(e){let{query:t,limit:r}=e.propsValue,n={query:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/products/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var zv=x({name:"update_price",classification:"WRITE",auth:g,displayName:"Update Price (Agent)",description:"Update or archive a Stripe price.",audience:"ai",aiMetadata:{description:"Updates a Stripe price (set active=false to archive it, or edit its nickname/metadata). The unit amount is immutable \u2014 create a new price to change it. Only the fields you supply change. Idempotent: re-applying the same update converges.",idempotent:!0},props:{price_id:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),active:u.Checkbox({displayName:"Active",description:"Set to false to archive the price.",required:!1}),nickname:u.ShortText({displayName:"Nickname",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:Pt,async run(e){let{price_id:t,active:r,nickname:n,metadata:o}=e.propsValue,i={};return r!==void 0&&(i.active=r),n&&(i.nickname=n),o&&typeof o=="object"&&Object.keys(o).forEach(l=>{i[`metadata[${l}]`]=o[l]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/prices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Mv=x({name:"get_price",classification:"READ",auth:g,displayName:"Get Price (Agent)",description:"Retrieve a Stripe price by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe price by its price ID (e.g., price_...). Use List/Search Prices to discover IDs. Read-only and idempotent.",idempotent:!0},props:{price_id:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0})},outputSchema:Pt,async run(e){let{price_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/prices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Uv=x({name:"list_prices",classification:"SEARCH",auth:g,displayName:"List Prices (Agent)",description:"List Stripe prices.",audience:"ai",aiMetadata:{description:"Pages through prices, newest first, optionally filtered by product, active state, type (one_time/recurring), or currency. Use to enumerate prices or resolve a price ID; for query matching use Search Prices, or Get Price when you have the price_ ID. Read-only and idempotent.",idempotent:!0},props:{product:u.ShortText({displayName:"Product ID",description:"Filter to prices for this product (prod_...).",required:!1}),active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),type:u.StaticDropdown({displayName:"Type",required:!1,options:{options:[{label:"One-time",value:"one_time"},{label:"Recurring",value:"recurring"}]}}),currency:u.ShortText({displayName:"Currency",description:"Three-letter ISO currency code (e.g., usd).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Md,async run(e){let{product:t,active:r,type:n,currency:o,limit:i}=e.propsValue,s={};return t&&(s.product=t),r&&(s.active=r),n&&(s.type=n),o&&(s.currency=o),i&&(s.limit=i.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:s})).body}});var Lv=x({name:"search_prices",classification:"SEARCH",auth:g,displayName:"Search Prices (Agent)",description:"Search prices with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches prices using the Stripe Search Query Language (e.g. "active:'true' AND currency:'usd'"). Use for metadata/attribute matching; use List Prices for simple paging or Get Price when you have the price_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. lookup_key:'standard_monthly').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:am,async run(e){let{query:t,limit:r}=e.propsValue,n={query:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/prices/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var qv=x({name:"update_subscription",classification:"WRITE",auth:g,displayName:"Update Subscription (Agent)",description:"Update an existing Stripe subscription.",audience:"ai",aiMetadata:{description:"Updates an existing subscription: change its items (price + quantity), proration behavior, metadata, or schedule cancellation at period end. To cancel outright use Cancel Subscription. Only the fields you supply change. Idempotent: re-applying the same update converges.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),items:u.Array({displayName:"Items",description:"New/updated items. To modify an existing item include its subscription-item id; to add one supply a price.",required:!1,properties:{id:u.ShortText({displayName:"Subscription Item ID",description:"Existing item id (si_...) to update. Obtain it from List Subscription Items.",required:!1}),price:u.ShortText({displayName:"Price ID",required:!1}),quantity:u.Number({displayName:"Quantity",required:!1})}}),proration_behavior:u.StaticDropdown({displayName:"Proration Behavior",required:!1,options:{options:[{label:"Create Prorations",value:"create_prorations"},{label:"None",value:"none"},{label:"Always Invoice",value:"always_invoice"}]}}),cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:xe,async run(e){let{subscription_id:t,items:r,proration_behavior:n,cancel_at_period_end:o,metadata:i}=e.propsValue,s={};return n&&(s.proration_behavior=n),o!==void 0&&(s.cancel_at_period_end=o),i&&typeof i=="object"&&Object.keys(i).forEach(f=>{s[`metadata[${f}]`]=i[f]}),r&&Array.isArray(r)&&r.forEach((f,b)=>{let m=f;m.id&&(s[`items[${b}][id]`]=m.id),m.price&&(s[`items[${b}][price]`]=m.price),m.quantity!==void 0&&m.quantity!==null&&(s[`items[${b}][quantity]`]=m.quantity)}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/subscriptions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:s})).body}});var jv=x({name:"get_subscription",classification:"READ",auth:g,displayName:"Get Subscription (Agent)",description:"Retrieve a Stripe subscription by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe subscription by its subscription ID (e.g., sub_...). Use List/Search Subscriptions to discover IDs. Read-only and idempotent.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0})},outputSchema:xe,async run(e){let{subscription_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/subscriptions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Fv=x({name:"list_subscriptions",classification:"SEARCH",auth:g,displayName:"List Subscriptions (Agent)",description:"List Stripe subscriptions.",audience:"ai",aiMetadata:{description:"Pages through subscriptions, newest first, optionally filtered by customer, status, or price. Use to enumerate or audit a customer's subscriptions; for rich filters/customer-hydration use Search Subscriptions, or Get Subscription when you have the sub_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to subscriptions for this customer (cus_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"All",value:"all"},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}]}}),price:u.ShortText({displayName:"Price ID",description:"Filter to subscriptions containing this price (price_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Zd,async run(e){let{customer:t,status:r,price:n,limit:o}=e.propsValue,i={};return t&&(i.customer=t),r&&(i.status=r),n&&(i.price=n),o&&(i.limit=o.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var Bv=x({name:"list_subscription_items",classification:"SEARCH",auth:g,displayName:"List Subscription Items (Agent)",description:"List the line items of a subscription.",audience:"ai",aiMetadata:{description:"Pages through the items of a single subscription, returning the subscription-item IDs (si_...) needed to update quantity or report usage. Use before Update Subscription when modifying a specific item. Read-only and idempotent.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Wd,async run(e){let{subscription_id:t,limit:r}=e.propsValue,n={subscription:t};return r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/subscription_items`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Gv=x({name:"get_payment_link",classification:"READ",auth:g,displayName:"Get Payment Link (Agent)",description:"Retrieve a Stripe payment link by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe payment link by its ID (e.g., plink_...), including its URL, active state, and line items. Use List Payment Links to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payment_link_id:u.ShortText({displayName:"Payment Link ID",description:"The payment link ID (e.g., plink_...). Obtain it from List Payment Links.",required:!0})},outputSchema:ze,async run(e){let{payment_link_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_links/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Vv=x({name:"list_payment_links",classification:"SEARCH",auth:g,displayName:"List Payment Links (Agent)",description:"List Stripe payment links.",audience:"ai",aiMetadata:{description:"Pages through payment links, optionally filtered by active state. Use to enumerate links or resolve a payment link ID; use Get Payment Link when you have the plink_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Jd,async run(e){let{active:t,limit:r}=e.propsValue,n={};return t&&(n.active=t),r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_links`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Hv=x({name:"create_checkout_session",classification:"WRITE",auth:g,displayName:"Create Checkout Session (Agent)",description:"Create a Stripe-hosted Checkout Session.",audience:"ai",aiMetadata:{description:"Creates a Stripe-hosted Checkout Session for one-time payment, subscription, or setup mode, with line items (price IDs + quantities) and success/cancel URLs. Richer than a payment link for one-off flows; for a reusable shareable URL use Create Payment Link. Not idempotent: each call creates a new session.",idempotent:!1},props:{mode:u.StaticDropdown({displayName:"Mode",description:"The Checkout mode.",required:!0,options:{options:[{label:"Payment (one-time)",value:"payment"},{label:"Subscription",value:"subscription"},{label:"Setup (save payment method)",value:"setup"}]}}),line_items:u.Array({displayName:"Line Items",description:"The prices and quantities. Required for payment and subscription modes.",required:!1,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...).",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),success_url:u.ShortText({displayName:"Success URL",description:"URL to redirect to after successful payment.",required:!1}),cancel_url:u.ShortText({displayName:"Cancel URL",description:"URL to redirect to if the customer cancels.",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"An existing customer (cus_...) to associate with the session.",required:!1})},outputSchema:ur,async run(e){let{mode:t,line_items:r,success_url:n,cancel_url:o,customer:i}=e.propsValue,s={mode:t};return n&&(s.success_url=n),o&&(s.cancel_url=o),i&&(s.customer=i),r&&Array.isArray(r)&&r.forEach((f,b)=>{let m=f;s[`line_items[${b}][price]`]=m.price,s[`line_items[${b}][quantity]`]=m.quantity}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/checkout/sessions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:s})).body}});var Zv=x({name:"get_checkout_session",classification:"READ",auth:g,displayName:"Get Checkout Session (Agent)",description:"Retrieve a Stripe Checkout Session by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Checkout Session by its ID (e.g., cs_...), including payment status, customer, and amounts. Use List Checkout Sessions to discover IDs. Read-only and idempotent.",idempotent:!0},props:{session_id:u.ShortText({displayName:"Session ID",description:"The Checkout Session ID (e.g., cs_...). Obtain it from List Checkout Sessions.",required:!0})},outputSchema:ur,async run(e){let{session_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/checkout/sessions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Wv=x({name:"list_checkout_sessions",classification:"SEARCH",auth:g,displayName:"List Checkout Sessions (Agent)",description:"List Stripe Checkout Sessions.",audience:"ai",aiMetadata:{description:"Pages through Checkout Sessions, newest first, optionally filtered by customer, PaymentIntent, or status. Use to enumerate sessions or resolve a session ID; use Get Checkout Session when you have the cs_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to sessions for this customer (cus_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to the session for this PaymentIntent (pi_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"Open",value:"open"},{label:"Complete",value:"complete"},{label:"Expired",value:"expired"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Xd,async run(e){let{customer:t,payment_intent:r,status:n,limit:o}=e.propsValue,i={};return t&&(i.customer=t),r&&(i.payment_intent=r),n&&(i.status=n),o&&(i.limit=o.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/checkout/sessions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var Kv=x({name:"create_payment_method",classification:"WRITE",auth:g,displayName:"Create Payment Method (Agent)",description:"Create a PaymentMethod from a token.",audience:"ai",aiMetadata:{description:"Creates a Stripe PaymentMethod of the given type from a single-use token (e.g. tok_visa, or a token produced by Stripe.js), with optional billing details. NEVER pass raw card numbers \u2014 raw PAN entry is restricted to PCI-compliant integrations; supply a token instead. Use before Attach Payment Method. Not idempotent: each call creates a new PaymentMethod.",idempotent:!1},props:{type:u.ShortText({displayName:"Type",description:"The PaymentMethod type (e.g., card).",required:!0}),token:u.ShortText({displayName:"Card Token",description:"A single-use card token (e.g., tok_visa or a Stripe.js token). Required for card type. Do NOT pass a raw card number.",required:!1}),billing_name:u.ShortText({displayName:"Billing Name",required:!1}),billing_email:u.ShortText({displayName:"Billing Email",required:!1})},outputSchema:ir,async run(e){let{type:t,token:r,billing_name:n,billing_email:o}=e.propsValue,i={type:t};return r&&(i["card[token]"]=r),n&&(i["billing_details[name]"]=n),o&&(i["billing_details[email]"]=o),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_methods`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Jv=x({name:"attach_payment_method",classification:"WRITE",auth:g,displayName:"Attach Payment Method (Agent)",description:"Attach a PaymentMethod to a customer.",audience:"ai",aiMetadata:{description:"Attaches a PaymentMethod to a customer so it can be charged off-session (e.g. for subscriptions or saved cards). Use after Create Payment Method. Idempotent: re-attaching the same PaymentMethod to the same customer is a no-op.",idempotent:!0},props:{payment_method_id:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID (e.g., pm_...) to attach. Obtain it from Create Payment Method or List Customer Payment Methods.",required:!0}),customer:u.ShortText({displayName:"Customer ID",description:"The customer ID (e.g., cus_...) to attach the PaymentMethod to.",required:!0})},outputSchema:ir,async run(e){let{payment_method_id:t,customer:r}=e.propsValue;return(await v.sendRequest({method:"POST",url:`${_.baseUrl}/payment_methods/${t}/attach`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{customer:r}})).body}});var Xv=x({name:"get_payment_method",classification:"READ",auth:g,displayName:"Get Payment Method (Agent)",description:"Retrieve a PaymentMethod by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single PaymentMethod by its ID (e.g., pm_...), including type and (masked) card details. Use List Customer Payment Methods to discover a customer's PaymentMethod IDs. Read-only and idempotent.",idempotent:!0},props:{payment_method_id:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID (e.g., pm_...). Obtain it from List Customer Payment Methods.",required:!0})},outputSchema:ir,async run(e){let{payment_method_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payment_methods/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Yv=x({name:"list_customer_payment_methods",classification:"SEARCH",auth:g,displayName:"List Customer Payment Methods (Agent)",description:"List a customer's attached payment methods.",audience:"ai",aiMetadata:{description:"Pages through the PaymentMethods attached to a customer, returning the pm_ IDs you can charge off-session. Use to find a customer's saved card before creating a payment. Read-only and idempotent.",idempotent:!0},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"The customer ID (e.g., cus_...). Obtain it from Search/List Customers.",required:!0}),type:u.ShortText({displayName:"Type",description:"Filter by PaymentMethod type (e.g., card).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:jd,async run(e){let{customer_id:t,type:r,limit:n}=e.propsValue,o={};return r&&(o.type=r),n&&(o.limit=n.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/customers/${t}/payment_methods`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var Qv=x({name:"create_coupon",classification:"WRITE",auth:g,displayName:"Create Coupon (Agent)",description:"Create a discount coupon.",audience:"ai",aiMetadata:{description:"Creates a discount coupon \u2014 either percent_off or amount_off (the latter requires a currency), with a duration of once, repeating (with duration_in_months), or forever. To expose it to customers wrap it in a Promotion Code. Not idempotent: each call creates a new coupon, and supplying a duplicate stable id returns a 409.",idempotent:!1},props:{percent_off:u.Number({displayName:"Percent Off",description:"Percentage discount (e.g., 25 for 25%). Use this OR Amount Off.",required:!1}),amount_off:u.Number({displayName:"Amount Off",description:"Flat discount in the smallest currency unit (e.g., 500 for $5.00). Requires Currency.",required:!1}),currency:u.ShortText({displayName:"Currency",description:"Three-letter ISO currency code. Required with Amount Off.",required:!1}),duration:u.StaticDropdown({displayName:"Duration",description:"How long the discount applies.",required:!0,options:{options:[{label:"Once",value:"once"},{label:"Repeating",value:"repeating"},{label:"Forever",value:"forever"}]}}),duration_in_months:u.Number({displayName:"Duration in Months",description:"Number of months the discount lasts. Required if duration is repeating.",required:!1}),name:u.ShortText({displayName:"Name",description:"Name shown to customers on invoices/receipts.",required:!1}),id:u.ShortText({displayName:"ID",description:"A custom unique coupon ID. If omitted, Stripe generates one. Reusing an existing id returns an error.",required:!1})},outputSchema:_o,async run(e){let{percent_off:t,amount_off:r,currency:n,duration:o,duration_in_months:i,name:s,id:l}=e.propsValue,f={duration:o};return t!=null&&(f.percent_off=t),r!=null&&(f.amount_off=r),n&&(f.currency=n),i!=null&&(f.duration_in_months=i),s&&(f.name=s),l&&(f.id=l),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/coupons`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:f})).body}});var e_=x({name:"get_coupon",classification:"READ",auth:g,displayName:"Get Coupon (Agent)",description:"Retrieve a coupon by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single coupon by its ID. Use List Coupons to discover IDs. Read-only and idempotent.",idempotent:!0},props:{coupon_id:u.ShortText({displayName:"Coupon ID",description:"The coupon ID. Obtain it from List Coupons.",required:!0})},outputSchema:_o,async run(e){let{coupon_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/coupons/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var t_=x({name:"list_coupons",classification:"SEARCH",auth:g,displayName:"List Coupons (Agent)",description:"List Stripe coupons.",audience:"ai",aiMetadata:{description:"Pages through coupons, newest first. Use to enumerate coupons or resolve a coupon ID; use Get Coupon when you have the ID. Read-only and idempotent.",idempotent:!0},props:{limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Ud,async run(e){let{limit:t}=e.propsValue,r={};return t&&(r.limit=t.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/coupons`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var r_=x({name:"create_promotion_code",classification:"WRITE",auth:g,displayName:"Create Promotion Code (Agent)",description:"Create a customer-facing promotion code for a coupon.",audience:"ai",aiMetadata:{description:"Creates a customer-facing promotion code that maps to an existing coupon, with optional custom code string, customer restriction, max redemptions, and expiry. Create the coupon first with Create Coupon. Not idempotent: each call creates a new promotion code.",idempotent:!1},props:{coupon:u.ShortText({displayName:"Coupon ID",description:"The coupon ID this promotion code applies. Obtain it from List Coupons or Create Coupon.",required:!0}),code:u.ShortText({displayName:"Code",description:"The customer-facing code (e.g., SUMMER25). If omitted, Stripe generates one.",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"Restrict the code to this customer (cus_...).",required:!1}),max_redemptions:u.Number({displayName:"Max Redemptions",description:"Maximum number of times the code can be redeemed.",required:!1}),expires_at:u.DateTime({displayName:"Expires At",description:"When the promotion code expires.",required:!1}),active:u.Checkbox({displayName:"Active",required:!1})},outputSchema:bo,async run(e){let{coupon:t,code:r,customer:n,max_redemptions:o,expires_at:i,active:s}=e.propsValue,l={coupon:t};return r&&(l.code=r),n&&(l.customer=n),o!=null&&(l.max_redemptions=o),i&&(l.expires_at=Math.floor(new Date(i).getTime()/1e3)),s!==void 0&&(l.active=s),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/promotion_codes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2025-05-28.basil"},body:l})).body}});var n_=x({name:"get_promotion_code",classification:"READ",auth:g,displayName:"Get Promotion Code (Agent)",description:"Retrieve a promotion code by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single promotion code by its ID (e.g., promo_...). Use List Promotion Codes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{promotion_code_id:u.ShortText({displayName:"Promotion Code ID",description:"The promotion code ID (e.g., promo_...). Obtain it from List Promotion Codes.",required:!0})},outputSchema:bo,async run(e){let{promotion_code_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/promotion_codes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var o_=x({name:"list_promotion_codes",classification:"SEARCH",auth:g,displayName:"List Promotion Codes (Agent)",description:"List Stripe promotion codes.",audience:"ai",aiMetadata:{description:"Pages through promotion codes, optionally filtered by coupon, active state, or the literal code string. Use to enumerate codes or resolve an ID; use Get Promotion Code when you have the promo_ ID. Read-only and idempotent.",idempotent:!0},props:{coupon:u.ShortText({displayName:"Coupon ID",description:"Filter to codes for this coupon.",required:!1}),active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),code:u.ShortText({displayName:"Code",description:"Filter to the literal code string (e.g., SUMMER25).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Ld,async run(e){let{coupon:t,active:r,code:n,limit:o}=e.propsValue,i={};return t&&(i.coupon=t),r&&(i.active=r),n&&(i.code=n),o&&(i.limit=o.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/promotion_codes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var i_=x({name:"retrieve_balance",classification:"READ",auth:g,displayName:"Retrieve Balance (Agent)",description:"Get the current Stripe account balance.",audience:"ai",aiMetadata:{description:"Fetches the current Stripe account balance, broken down into available and pending funds by currency. Use to check how much can be paid out. Read-only and idempotent; takes no parameters.",idempotent:!0},props:{},outputSchema:Nd,async run(e){return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/balance`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var a_=x({name:"list_balance_transactions",classification:"SEARCH",auth:g,displayName:"List Balance Transactions (Agent)",description:"List balance transactions (the reconciliation ledger).",audience:"ai",aiMetadata:{description:"Pages through the balance-transaction ledger \u2014 every item that affected the account balance (charges, refunds, fees, payouts), newest first. Optionally filter by type, payout, or created range. Use to reconcile activity to a payout. Read-only and idempotent.",idempotent:!0},props:{type:u.ShortText({displayName:"Type",description:"Filter by transaction type (e.g., charge, refund, payout).",required:!1}),payout:u.ShortText({displayName:"Payout ID",description:"Filter to transactions paid out in this payout (po_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:rm,async run(e){let{type:t,payout:r,created_after:n,created_before:o,limit:i}=e.propsValue,s={};return t&&(s.type=t),r&&(s.payout=r),i&&(s.limit=i.toString()),n&&(s["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),o&&(s["created[lte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/balance_transactions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:s})).body}});var s_=x({name:"list_payouts",classification:"SEARCH",auth:g,displayName:"List Payouts (Agent)",description:"List payouts to the bank account.",audience:"ai",aiMetadata:{description:"Pages through payouts (funds sent to your bank account), newest first, optionally filtered by status or arrival date. Use to enumerate payouts or resolve a payout ID; use Get Payout when you have the po_ ID. Read-only and idempotent.",idempotent:!0},props:{status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"Pending",value:"pending"},{label:"In Transit",value:"in_transit"},{label:"Paid",value:"paid"},{label:"Failed",value:"failed"},{label:"Canceled",value:"canceled"}]}}),arrival_date_after:u.DateTime({displayName:"Arrival Date After",required:!1}),arrival_date_before:u.DateTime({displayName:"Arrival Date Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Qd,async run(e){let{status:t,arrival_date_after:r,arrival_date_before:n,limit:o}=e.propsValue,i={};return t&&(i.status=t),o&&(i.limit=o.toString()),r&&(i["arrival_date[gte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),n&&(i["arrival_date[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/payouts`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var u_=x({name:"create_tax_rate",classification:"WRITE",auth:g,displayName:"Create Tax Rate (Agent)",description:"Create a manual tax rate.",audience:"ai",aiMetadata:{description:"Creates a manual Stripe tax rate (a fixed percentage with a display name and inclusive/exclusive flag), for applying to invoices or subscriptions. This is the manual tax-rate object, not Stripe Tax automation. Not idempotent: each call creates a new tax rate.",idempotent:!1},props:{display_name:u.ShortText({displayName:"Display Name",description:"Name shown to customers (e.g., VAT).",required:!0}),percentage:u.Number({displayName:"Percentage",description:"The tax rate percentage (e.g., 20 for 20%).",required:!0}),inclusive:u.Checkbox({displayName:"Inclusive",description:"Whether the tax is included in the price.",required:!0}),jurisdiction:u.ShortText({displayName:"Jurisdiction",description:"Optional jurisdiction text (e.g., UK).",required:!1}),country:u.ShortText({displayName:"Country",description:"Two-letter ISO country code.",required:!1})},outputSchema:Po,async run(e){let{display_name:t,percentage:r,inclusive:n,jurisdiction:o,country:i}=e.propsValue,s={display_name:t,percentage:r,inclusive:n};return o&&(s.jurisdiction=o),i&&(s.country=i),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/tax_rates`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:s})).body}});var c_=x({name:"get_tax_rate",classification:"READ",auth:g,displayName:"Get Tax Rate (Agent)",description:"Retrieve a tax rate by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single tax rate by its ID (e.g., txr_...). Use List Tax Rates to discover IDs. Read-only and idempotent.",idempotent:!0},props:{tax_rate_id:u.ShortText({displayName:"Tax Rate ID",description:"The tax rate ID (e.g., txr_...). Obtain it from List Tax Rates.",required:!0})},outputSchema:Po,async run(e){let{tax_rate_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/tax_rates/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var l_=x({name:"list_tax_rates",classification:"SEARCH",auth:g,displayName:"List Tax Rates (Agent)",description:"List Stripe tax rates.",audience:"ai",aiMetadata:{description:"Pages through tax rates, optionally filtered by active or inclusive flags. Use to enumerate tax rates or resolve a tax rate ID; use Get Tax Rate when you have the txr_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),inclusive:u.StaticDropdown({displayName:"Inclusive",required:!1,options:{options:[{label:"Inclusive only",value:"true"},{label:"Exclusive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:qd,async run(e){let{active:t,inclusive:r,limit:n}=e.propsValue,o={};return t&&(o.active=t),r&&(o.inclusive=r),n&&(o.limit=n.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/tax_rates`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var p_=x({name:"create_credit_note",classification:"WRITE",auth:g,displayName:"Create Credit Note (Agent)",description:"Issue a credit note against a finalized invoice.",audience:"ai",aiMetadata:{description:"Issues a credit note against a finalized invoice \u2014 a post-payment adjustment (credit, refund, or out-of-band amount). Supply either a total credit_amount or itemized lines (in the smallest currency unit). The invoice must already be finalized. Not idempotent: each call creates a new credit note.",idempotent:!1},props:{invoice:u.ShortText({displayName:"Invoice ID",description:"The finalized invoice ID (e.g., in_...) to credit. Obtain it from List/Search Invoices.",required:!0}),amount:u.Number({displayName:"Amount",description:"Total amount of the credit note, in the smallest currency unit (e.g., 500 for $5.00). Stripe requires this (or itemized lines); it must not exceed the invoice total. By default the full amount credits the customer balance unless you also set Credit Amount / Refund Amount to split it.",required:!0}),credit_amount:u.Number({displayName:"Credit Amount",description:"The amount to credit to the customer balance, in the smallest currency unit (e.g., 500 for $5.00).",required:!1}),refund_amount:u.Number({displayName:"Refund Amount",description:"The amount to refund, in the smallest currency unit. Refunds against the original payment.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Order Change",value:"order_change"},{label:"Product Unsatisfactory",value:"product_unsatisfactory"}]}}),memo:u.LongText({displayName:"Memo",required:!1})},outputSchema:sr,async run(e){let{invoice:t,amount:r,credit_amount:n,refund_amount:o,reason:i,memo:s}=e.propsValue,l={invoice:t};return r!=null&&(l.amount=r),n!=null&&(l.credit_amount=n),o!=null&&(l.refund_amount=o),i&&(l.reason=i),s&&(l.memo=s),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/credit_notes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var d_=x({name:"void_credit_note",classification:"DESTRUCTIVE",auth:g,displayName:"Void Credit Note (Agent)",description:"Void a credit note.",audience:"ai",aiMetadata:{description:"Voids a Stripe credit note, reversing the credit/refund it represented. Not idempotent: it errors if the credit note is already void.",idempotent:!1},props:{credit_note_id:u.ShortText({displayName:"Credit Note ID",description:"The credit note ID (e.g., cn_...). Obtain it from List Credit Notes.",required:!0})},outputSchema:sr,async run(e){let{credit_note_id:t}=e.propsValue;return(await v.sendRequest({method:"POST",url:`${_.baseUrl}/credit_notes/${t}/void`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var m_=x({name:"get_credit_note",classification:"READ",auth:g,displayName:"Get Credit Note (Agent)",description:"Retrieve a credit note by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single credit note by its ID (e.g., cn_...), including its line items. Use List Credit Notes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{credit_note_id:u.ShortText({displayName:"Credit Note ID",description:"The credit note ID (e.g., cn_...). Obtain it from List Credit Notes.",required:!0})},outputSchema:sr,async run(e){let{credit_note_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/credit_notes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var f_=x({name:"list_credit_notes",classification:"SEARCH",auth:g,displayName:"List Credit Notes (Agent)",description:"List Stripe credit notes.",audience:"ai",aiMetadata:{description:"Pages through credit notes, newest first, optionally filtered by invoice or customer. Use to enumerate credit notes or resolve a credit note ID; use Get Credit Note when you have the cn_ ID. Read-only and idempotent.",idempotent:!0},props:{invoice:u.ShortText({displayName:"Invoice ID",description:"Filter to credit notes for this invoice (in_...).",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"Filter to credit notes for this customer (cus_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Kd,async run(e){let{invoice:t,customer:r,limit:n}=e.propsValue,o={};return t&&(o.invoice=t),r&&(o.customer=r),n&&(o.limit=n.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/credit_notes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var h_=x({name:"list_events",classification:"SEARCH",auth:g,displayName:"List Events (Agent)",description:"List Stripe account events.",audience:"ai",aiMetadata:{description:"Pages through the account event log (the audit feed of everything that happened), newest first, optionally filtered by event type (e.g. invoice.paid) or created range. Use to investigate what happened to a resource. Read-only and idempotent.",idempotent:!0},props:{type:u.ShortText({displayName:"Type",description:"Filter by event type (e.g., invoice.paid, charge.refunded).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:tm,async run(e){let{type:t,created_after:r,created_before:n,limit:o}=e.propsValue,i={};return t&&(i.type=t),o&&(i.limit=o.toString()),r&&(i["created[gte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),n&&(i["created[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/events`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var y_=x({name:"get_event",classification:"READ",auth:g,displayName:"Get Event (Agent)",description:"Retrieve a single Stripe event by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe event by its ID (e.g., evt_...), including the object snapshot it carried. Use List Events or a webhook payload to obtain the ID. Read-only and idempotent.",idempotent:!0},props:{event_id:u.ShortText({displayName:"Event ID",description:"The event ID (e.g., evt_...). Obtain it from List Events or a webhook payload.",required:!0})},outputSchema:$d,async run(e){let{event_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/events/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var g_=x({name:"get_dispute",classification:"READ",auth:g,displayName:"Get Dispute (Agent)",description:"Retrieve a dispute by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe dispute (chargeback) by its ID (e.g., dp_...), including its status, reason, and evidence due date. Use List Disputes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...). Obtain it from List Disputes.",required:!0})},outputSchema:St,async run(e){let{dispute_id:t}=e.propsValue;return(await v.sendRequest({method:"GET",url:`${_.baseUrl}/disputes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var v_=x({name:"list_disputes",classification:"SEARCH",auth:g,displayName:"List Disputes (Agent)",description:"List Stripe disputes (chargebacks).",audience:"ai",aiMetadata:{description:"Pages through disputes (chargebacks), newest first, optionally filtered by charge, PaymentIntent, or created range. Use to enumerate disputes or resolve a dispute ID; use Get Dispute when you have the dp_ ID. Read-only and idempotent.",idempotent:!0},props:{charge:u.ShortText({displayName:"Charge ID",description:"Filter to disputes for this charge (ch_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to disputes for this PaymentIntent (pi_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Yd,async run(e){let{charge:t,payment_intent:r,created_after:n,created_before:o,limit:i}=e.propsValue,s={};return t&&(s.charge=t),r&&(s.payment_intent=r),i&&(s.limit=i.toString()),n&&(s["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),o&&(s["created[lte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/disputes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:s})).body}});var __=x({name:"list_transfers",classification:"SEARCH",auth:g,displayName:"List Transfers (Agent)",description:"List transfers to connected accounts (Stripe Connect).",audience:"ai",aiMetadata:{description:"Pages through transfers to connected accounts, newest first, optionally filtered by destination. Stripe Connect platforms only \u2014 on a standard (non-Connect) account this returns an empty list, which is expected, not an error. Read-only and idempotent.",idempotent:!0},props:{destination:u.ShortText({displayName:"Destination Account ID",description:"Filter to transfers to this connected account (acct_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:em,async run(e){let{destination:t,limit:r}=e.propsValue,n={};return t&&(n.destination=t),r&&(n.limit=r.toString()),(await v.sendRequest({method:"GET",url:`${_.baseUrl}/transfers`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var b_=x({name:"update_dispute",classification:"WRITE",auth:g,displayName:"Update Dispute (Agent)",description:"Submit or update evidence on a dispute.",audience:"ai",aiMetadata:{description:"Submits or updates evidence and metadata on a Stripe dispute (chargeback) to contest it. Set submit=true to finalize and submit the evidence to the bank \u2014 once submitted, evidence can no longer be changed. Prefer this (contest with evidence) over Close Dispute (which concedes). Idempotent for metadata/evidence edits; submitting is a one-way action.",idempotent:!0},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...). Obtain it from List Disputes.",required:!0}),evidence:u.Json({displayName:"Evidence",description:'A Stripe dispute evidence object (e.g., {"product_description":"...","customer_name":"..."}).',required:!1}),submit:u.Checkbox({displayName:"Submit",description:"If true, finalizes and submits the evidence to the bank. This cannot be undone.",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:St,async run(e){let{dispute_id:t,evidence:r,submit:n,metadata:o}=e.propsValue,i={};return n!==void 0&&(i.submit=n),r&&typeof r=="object"&&Object.keys(r).forEach(l=>{i[`evidence[${l}]`]=r[l]}),o&&typeof o=="object"&&Object.keys(o).forEach(l=>{i[`metadata[${l}]`]=o[l]}),(await v.sendRequest({method:"POST",url:`${_.baseUrl}/disputes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var P_=x({name:"close_dispute",classification:"DESTRUCTIVE",auth:g,displayName:"Close Dispute (Agent)",description:"Concede a dispute (DESTRUCTIVE \u2014 forfeits the funds).",audience:"ai",aiMetadata:{description:"DESTRUCTIVE AND IRREVERSIBLE: closing a dispute concedes the chargeback and permanently forfeits the disputed funds \u2014 the money is lost and cannot be recovered. Almost always prefer Update Dispute (submit evidence to contest) instead. Only use when you explicitly intend to give up the dispute. Not idempotent.",idempotent:!1},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...) to concede. Obtain it from List Disputes.",required:!0})},outputSchema:St,async run(e){let{dispute_id:t}=e.propsValue;return(await v.sendRequest({method:"POST",url:`${_.baseUrl}/disputes/${t}/close`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var g=ua.SecretText({displayName:"Secret API Key",required:!0,description:"Secret key acquired from your Stripe dashboard",validate:a(async({auth:e})=>{try{return await v.sendRequest({method:"GET",url:"https://api.stripe.com/v1/customers",headers:{Authorization:`Bearer ${e}`}}),{valid:!0}}catch{return{valid:!1,error:"Invalid API Key. Please check the key and try again."}}},"validate")}),ZI=el({displayName:"Stripe",description:"Online payment processing for internet businesses",minimumSupportedRelease:"0.86.4",logoUrl:"https://cdn.activepieces.com/pieces/stripe.png",authors:["lldiegon","doskyft","kishanprmr","MoShizzle","AbdulTheActivePiecer","khaledmashaly","abuaboud","Prabhukiran161","sanket-a11y"],categories:["COMMERCE","PAYMENT_PROCESSING"],auth:g,actions:[um,cm,Sg,wg,lm,Ug,Lg,qg,jg,Fg,Bg,Gg,Vg,Hg,Zg,Wg,Kg,Jg,Xg,Yg,Qg,ev,tv,rv,nv,ov,iv,av,sv,uv,cv,lv,pv,dv,mv,fv,hv,yv,gv,vv,_v,bv,Pv,xv,Sv,Tv,Ev,Iv,Av,wv,kv,Rv,Ov,Cv,$v,Nv,Dv,zv,Mv,Uv,Lv,qv,jv,Fv,Bv,Gv,Vv,Hv,Zv,Wv,Kv,Jv,Xv,Yv,Qv,e_,t_,r_,n_,o_,i_,a_,s_,u_,c_,l_,p_,d_,m_,f_,h_,y_,g_,v_,__,b_,P_,yd({baseUrl:a(()=>"https://api.stripe.com/v1","baseUrl"),auth:g,authMapping:a(async e=>({Authorization:`Bearer ${e.secret_text}`}),"authMapping")})],triggers:[Eg,Tg,Ag,Ig,kg,Rg,Og,Cg,$g,Ng,Dg,zg,Mg]});0&&(module.exports={stripe,stripeAuth});
|
|
52
|
+
`+R+`
|
|
53
|
+
`+q});let Q=Math.floor((typeof x=="number"?x:Date.now())/1e3)-h.timestamp;if(v>0&&Q>v)throw new yt(g,l,{message:"Timestamp outside the tolerance zone"});return!0}s(i,"validateComputedSignature");function a(l,g){return typeof l!="string"?null:l.split(",").reduce((h,f)=>{let v=f.split("=");return v[0]==="t"&&(h.timestamp=parseInt(v[1],10)),v[0]===g&&h.signatures.push(v[1]),h},{timestamp:-1,signatures:[]})}s(a,"parseHeader");let c=null;function p(){return c||(c=e.createDefaultCryptoProvider()),c}s(p,"getCryptoProvider");function m(l){if(!l)throw new _e({message:"Options are required"});let g=Math.floor(l.timestamp)||Math.floor(Date.now()/1e3),h=l.scheme||o.EXPECTED_SCHEME,f=l.cryptoProvider||p(),v=`${g}.${l.payload}`,I=s(T=>`t=${g},${h}=${T}`,"generateHeaderString");return Object.assign(Object.assign({},l),{timestamp:g,scheme:h,cryptoProvider:f,payloadString:v,generateHeaderString:I})}return s(m,"prepareOptions"),t.signature=o,t}s(TT,"createWebhooks");var ET="2025-05-28.basil";var an={};Ye(an,{Account:()=>Ry,AccountLinks:()=>cI,AccountSessions:()=>uI,Accounts:()=>Ry,ApplePayDomains:()=>pI,ApplicationFees:()=>lI,Apps:()=>N0,Balance:()=>dI,BalanceTransactions:()=>fI,Billing:()=>D0,BillingPortal:()=>z0,Charges:()=>hI,Checkout:()=>M0,Climate:()=>L0,ConfirmationTokens:()=>yI,CountrySpecs:()=>vI,Coupons:()=>_I,CreditNotes:()=>bI,CustomerSessions:()=>PI,Customers:()=>xI,Disputes:()=>SI,Entitlements:()=>U0,EphemeralKeys:()=>EI,Events:()=>AI,ExchangeRates:()=>wI,FileLinks:()=>OI,Files:()=>CI,FinancialConnections:()=>q0,Forwarding:()=>j0,Identity:()=>F0,InvoiceItems:()=>$I,InvoicePayments:()=>DI,InvoiceRenderingTemplates:()=>zI,Invoices:()=>MI,Issuing:()=>B0,Mandates:()=>LI,OAuth:()=>qI,PaymentIntents:()=>jI,PaymentLinks:()=>FI,PaymentMethodConfigurations:()=>BI,PaymentMethodDomains:()=>ZI,PaymentMethods:()=>VI,Payouts:()=>GI,Plans:()=>HI,Prices:()=>WI,Products:()=>KI,PromotionCodes:()=>JI,Quotes:()=>XI,Radar:()=>Z0,Refunds:()=>YI,Reporting:()=>V0,Reviews:()=>QI,SetupAttempts:()=>eA,SetupIntents:()=>tA,ShippingRates:()=>rA,Sigma:()=>G0,Sources:()=>oA,SubscriptionItems:()=>nA,SubscriptionSchedules:()=>iA,Subscriptions:()=>aA,Tax:()=>H0,TaxCodes:()=>cA,TaxIds:()=>uA,TaxRates:()=>pA,Terminal:()=>W0,TestHelpers:()=>K0,Tokens:()=>dA,Topups:()=>mA,Transfers:()=>fA,Treasury:()=>J0,V2:()=>X0,WebhookEndpoints:()=>hA});function l0(e,t){for(let o in t){if(!Object.prototype.hasOwnProperty.call(t,o))continue;let n=o[0].toLowerCase()+o.substring(1),r=new t[o](e);this[n]=r}}s(l0,"ResourceNamespace");function de(e,t){return function(o){return new l0(o,t)}}s(de,"resourceNamespace");var Fr=d.method,IT=d.extend({retrieve:Fr({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}"}),list:Fr({method:"GET",fullPath:"/v1/financial_connections/accounts",methodType:"list"}),disconnect:Fr({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/disconnect"}),listOwners:Fr({method:"GET",fullPath:"/v1/financial_connections/accounts/{account}/owners",methodType:"list"}),refresh:Fr({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/refresh"}),subscribe:Fr({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/subscribe"}),unsubscribe:Fr({method:"POST",fullPath:"/v1/financial_connections/accounts/{account}/unsubscribe"})});var AT=d.method,kT=d.extend({retrieve:AT({method:"GET",fullPath:"/v1/entitlements/active_entitlements/{id}"}),list:AT({method:"GET",fullPath:"/v1/entitlements/active_entitlements",methodType:"list"})});var Jo=d.method,wT=d.extend({create:Jo({method:"POST",fullPath:"/v1/billing/alerts"}),retrieve:Jo({method:"GET",fullPath:"/v1/billing/alerts/{id}"}),list:Jo({method:"GET",fullPath:"/v1/billing/alerts",methodType:"list"}),activate:Jo({method:"POST",fullPath:"/v1/billing/alerts/{id}/activate"}),archive:Jo({method:"POST",fullPath:"/v1/billing/alerts/{id}/archive"}),deactivate:Jo({method:"POST",fullPath:"/v1/billing/alerts/{id}/deactivate"})});var Br=d.method,OT=d.extend({create:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations"}),capture:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/capture"}),expire:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/expire"}),finalizeAmount:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/finalize_amount"}),increment:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/increment"}),respond:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/fraud_challenges/respond"}),reverse:Br({method:"POST",fullPath:"/v1/test_helpers/issuing/authorizations/{authorization}/reverse"})});var _a=d.method,RT=d.extend({retrieve:_a({method:"GET",fullPath:"/v1/issuing/authorizations/{authorization}"}),update:_a({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}"}),list:_a({method:"GET",fullPath:"/v1/issuing/authorizations",methodType:"list"}),approve:_a({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/approve"}),decline:_a({method:"POST",fullPath:"/v1/issuing/authorizations/{authorization}/decline"})});var _y=d.method,CT=d.extend({create:_y({method:"POST",fullPath:"/v1/tax/calculations"}),retrieve:_y({method:"GET",fullPath:"/v1/tax/calculations/{calculation}"}),listLineItems:_y({method:"GET",fullPath:"/v1/tax/calculations/{calculation}/line_items",methodType:"list"})});var yp=d.method,$T=d.extend({create:yp({method:"POST",fullPath:"/v1/issuing/cardholders"}),retrieve:yp({method:"GET",fullPath:"/v1/issuing/cardholders/{cardholder}"}),update:yp({method:"POST",fullPath:"/v1/issuing/cardholders/{cardholder}"}),list:yp({method:"GET",fullPath:"/v1/issuing/cardholders",methodType:"list"})});var ba=d.method,NT=d.extend({deliverCard:ba({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/deliver"}),failCard:ba({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/fail"}),returnCard:ba({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/return"}),shipCard:ba({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/ship"}),submitCard:ba({method:"POST",fullPath:"/v1/test_helpers/issuing/cards/{card}/shipping/submit"})});var gp=d.method,DT=d.extend({create:gp({method:"POST",fullPath:"/v1/issuing/cards"}),retrieve:gp({method:"GET",fullPath:"/v1/issuing/cards/{card}"}),update:gp({method:"POST",fullPath:"/v1/issuing/cards/{card}"}),list:gp({method:"GET",fullPath:"/v1/issuing/cards",methodType:"list"})});var vp=d.method,zT=d.extend({create:vp({method:"POST",fullPath:"/v1/billing_portal/configurations"}),retrieve:vp({method:"GET",fullPath:"/v1/billing_portal/configurations/{configuration}"}),update:vp({method:"POST",fullPath:"/v1/billing_portal/configurations/{configuration}"}),list:vp({method:"GET",fullPath:"/v1/billing_portal/configurations",methodType:"list"})});var Pa=d.method,MT=d.extend({create:Pa({method:"POST",fullPath:"/v1/terminal/configurations"}),retrieve:Pa({method:"GET",fullPath:"/v1/terminal/configurations/{configuration}"}),update:Pa({method:"POST",fullPath:"/v1/terminal/configurations/{configuration}"}),list:Pa({method:"GET",fullPath:"/v1/terminal/configurations",methodType:"list"}),del:Pa({method:"DELETE",fullPath:"/v1/terminal/configurations/{configuration}"})});var d0=d.method,LT=d.extend({create:d0({method:"POST",fullPath:"/v1/test_helpers/confirmation_tokens"})});var m0=d.method,UT=d.extend({create:m0({method:"POST",fullPath:"/v1/terminal/connection_tokens"})});var f0=d.method,qT=d.extend({retrieve:f0({method:"GET",fullPath:"/v1/billing/credit_balance_summary"})});var jT=d.method,FT=d.extend({retrieve:jT({method:"GET",fullPath:"/v1/billing/credit_balance_transactions/{id}"}),list:jT({method:"GET",fullPath:"/v1/billing/credit_balance_transactions",methodType:"list"})});var Xo=d.method,BT=d.extend({create:Xo({method:"POST",fullPath:"/v1/billing/credit_grants"}),retrieve:Xo({method:"GET",fullPath:"/v1/billing/credit_grants/{id}"}),update:Xo({method:"POST",fullPath:"/v1/billing/credit_grants/{id}"}),list:Xo({method:"GET",fullPath:"/v1/billing/credit_grants",methodType:"list"}),expire:Xo({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/expire"}),voidGrant:Xo({method:"POST",fullPath:"/v1/billing/credit_grants/{id}/void"})});var by=d.method,ZT=d.extend({create:by({method:"POST",fullPath:"/v1/treasury/credit_reversals"}),retrieve:by({method:"GET",fullPath:"/v1/treasury/credit_reversals/{credit_reversal}"}),list:by({method:"GET",fullPath:"/v1/treasury/credit_reversals",methodType:"list"})});var h0=d.method,VT=d.extend({fundCashBalance:h0({method:"POST",fullPath:"/v1/test_helpers/customers/{customer}/fund_cash_balance"})});var Py=d.method,GT=d.extend({create:Py({method:"POST",fullPath:"/v1/treasury/debit_reversals"}),retrieve:Py({method:"GET",fullPath:"/v1/treasury/debit_reversals/{debit_reversal}"}),list:Py({method:"GET",fullPath:"/v1/treasury/debit_reversals",methodType:"list"})});var xa=d.method,HT=d.extend({create:xa({method:"POST",fullPath:"/v1/issuing/disputes"}),retrieve:xa({method:"GET",fullPath:"/v1/issuing/disputes/{dispute}"}),update:xa({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}"}),list:xa({method:"GET",fullPath:"/v1/issuing/disputes",methodType:"list"}),submit:xa({method:"POST",fullPath:"/v1/issuing/disputes/{dispute}/submit"})});var WT=d.method,KT=d.extend({retrieve:WT({method:"GET",fullPath:"/v1/radar/early_fraud_warnings/{early_fraud_warning}"}),list:WT({method:"GET",fullPath:"/v1/radar/early_fraud_warnings",methodType:"list"})});var dr=d.method,JT=d.extend({create:dr({method:"POST",fullPath:"/v2/core/event_destinations"}),retrieve:dr({method:"GET",fullPath:"/v2/core/event_destinations/{id}"}),update:dr({method:"POST",fullPath:"/v2/core/event_destinations/{id}"}),list:dr({method:"GET",fullPath:"/v2/core/event_destinations",methodType:"list"}),del:dr({method:"DELETE",fullPath:"/v2/core/event_destinations/{id}"}),disable:dr({method:"POST",fullPath:"/v2/core/event_destinations/{id}/disable"}),enable:dr({method:"POST",fullPath:"/v2/core/event_destinations/{id}/enable"}),ping:dr({method:"POST",fullPath:"/v2/core/event_destinations/{id}/ping"})});var xy=d.method,XT=d.extend({retrieve(...e){return xy({method:"GET",fullPath:"/v2/core/events/{id}",transformResponseData:s(o=>this.addFetchRelatedObjectIfNeeded(o),"transformResponseData")}).apply(this,e)},list(...e){return xy({method:"GET",fullPath:"/v2/core/events",methodType:"list",transformResponseData:s(o=>Object.assign(Object.assign({},o),{data:o.data.map(this.addFetchRelatedObjectIfNeeded.bind(this))}),"transformResponseData")}).apply(this,e)},addFetchRelatedObjectIfNeeded(e){return!e.related_object||!e.related_object.url?e:Object.assign(Object.assign({},e),{fetchRelatedObject:s(()=>xy({method:"GET",fullPath:e.related_object.url}).apply(this,[{stripeAccount:e.context}]),"fetchRelatedObject")})}});var _p=d.method,YT=d.extend({create:_p({method:"POST",fullPath:"/v1/entitlements/features"}),retrieve:_p({method:"GET",fullPath:"/v1/entitlements/features/{id}"}),update:_p({method:"POST",fullPath:"/v1/entitlements/features/{id}"}),list:_p({method:"GET",fullPath:"/v1/entitlements/features",methodType:"list"})});var Zr=d.method,QT=d.extend({create:Zr({method:"POST",fullPath:"/v1/treasury/financial_accounts"}),retrieve:Zr({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),update:Zr({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}"}),list:Zr({method:"GET",fullPath:"/v1/treasury/financial_accounts",methodType:"list"}),close:Zr({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/close"}),retrieveFeatures:Zr({method:"GET",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"}),updateFeatures:Zr({method:"POST",fullPath:"/v1/treasury/financial_accounts/{financial_account}/features"})});var Sy=d.method,eE=d.extend({fail:Sy({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/fail"}),returnInboundTransfer:Sy({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/return"}),succeed:Sy({method:"POST",fullPath:"/v1/test_helpers/treasury/inbound_transfers/{id}/succeed"})});var bp=d.method,tE=d.extend({create:bp({method:"POST",fullPath:"/v1/treasury/inbound_transfers"}),retrieve:bp({method:"GET",fullPath:"/v1/treasury/inbound_transfers/{id}"}),list:bp({method:"GET",fullPath:"/v1/treasury/inbound_transfers",methodType:"list"}),cancel:bp({method:"POST",fullPath:"/v1/treasury/inbound_transfers/{inbound_transfer}/cancel"})});var Sa=d.method,rE=d.extend({create:Sa({method:"POST",fullPath:"/v1/terminal/locations"}),retrieve:Sa({method:"GET",fullPath:"/v1/terminal/locations/{location}"}),update:Sa({method:"POST",fullPath:"/v1/terminal/locations/{location}"}),list:Sa({method:"GET",fullPath:"/v1/terminal/locations",methodType:"list"}),del:Sa({method:"DELETE",fullPath:"/v1/terminal/locations/{location}"})});var y0=d.method,oE=d.extend({create:y0({method:"POST",fullPath:"/v1/billing/meter_event_adjustments"})});var g0=d.method,nE=d.extend({create:g0({method:"POST",fullPath:"/v2/billing/meter_event_adjustments"})});var v0=d.method,iE=d.extend({create:v0({method:"POST",fullPath:"/v2/billing/meter_event_session"})});var _0=d.method,aE=d.extend({create:_0({method:"POST",fullPath:"/v2/billing/meter_event_stream",host:"meter-events.stripe.com"})});var b0=d.method,sE=d.extend({create:b0({method:"POST",fullPath:"/v1/billing/meter_events"})});var P0=d.method,cE=d.extend({create:P0({method:"POST",fullPath:"/v2/billing/meter_events"})});var Vr=d.method,uE=d.extend({create:Vr({method:"POST",fullPath:"/v1/billing/meters"}),retrieve:Vr({method:"GET",fullPath:"/v1/billing/meters/{id}"}),update:Vr({method:"POST",fullPath:"/v1/billing/meters/{id}"}),list:Vr({method:"GET",fullPath:"/v1/billing/meters",methodType:"list"}),deactivate:Vr({method:"POST",fullPath:"/v1/billing/meters/{id}/deactivate"}),listEventSummaries:Vr({method:"GET",fullPath:"/v1/billing/meters/{id}/event_summaries",methodType:"list"}),reactivate:Vr({method:"POST",fullPath:"/v1/billing/meters/{id}/reactivate"})});var Ta=d.method,pE=d.extend({create:Ta({method:"POST",fullPath:"/v1/climate/orders"}),retrieve:Ta({method:"GET",fullPath:"/v1/climate/orders/{order}"}),update:Ta({method:"POST",fullPath:"/v1/climate/orders/{order}"}),list:Ta({method:"GET",fullPath:"/v1/climate/orders",methodType:"list"}),cancel:Ta({method:"POST",fullPath:"/v1/climate/orders/{order}/cancel"})});var Pp=d.method,lE=d.extend({update:Pp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}"}),fail:Pp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/fail"}),post:Pp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/post"}),returnOutboundPayment:Pp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_payments/{id}/return"})});var xp=d.method,dE=d.extend({create:xp({method:"POST",fullPath:"/v1/treasury/outbound_payments"}),retrieve:xp({method:"GET",fullPath:"/v1/treasury/outbound_payments/{id}"}),list:xp({method:"GET",fullPath:"/v1/treasury/outbound_payments",methodType:"list"}),cancel:xp({method:"POST",fullPath:"/v1/treasury/outbound_payments/{id}/cancel"})});var Sp=d.method,mE=d.extend({update:Sp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}"}),fail:Sp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/fail"}),post:Sp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/post"}),returnOutboundTransfer:Sp({method:"POST",fullPath:"/v1/test_helpers/treasury/outbound_transfers/{outbound_transfer}/return"})});var Tp=d.method,fE=d.extend({create:Tp({method:"POST",fullPath:"/v1/treasury/outbound_transfers"}),retrieve:Tp({method:"GET",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}"}),list:Tp({method:"GET",fullPath:"/v1/treasury/outbound_transfers",methodType:"list"}),cancel:Tp({method:"POST",fullPath:"/v1/treasury/outbound_transfers/{outbound_transfer}/cancel"})});var Ty=d.method,hE=d.extend({activate:Ty({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/activate"}),deactivate:Ty({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/deactivate"}),reject:Ty({method:"POST",fullPath:"/v1/test_helpers/issuing/personalization_designs/{personalization_design}/reject"})});var Ep=d.method,yE=d.extend({create:Ep({method:"POST",fullPath:"/v1/issuing/personalization_designs"}),retrieve:Ep({method:"GET",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),update:Ep({method:"POST",fullPath:"/v1/issuing/personalization_designs/{personalization_design}"}),list:Ep({method:"GET",fullPath:"/v1/issuing/personalization_designs",methodType:"list"})});var gE=d.method,vE=d.extend({retrieve:gE({method:"GET",fullPath:"/v1/issuing/physical_bundles/{physical_bundle}"}),list:gE({method:"GET",fullPath:"/v1/issuing/physical_bundles",methodType:"list"})});var _E=d.method,bE=d.extend({retrieve:_E({method:"GET",fullPath:"/v1/climate/products/{product}"}),list:_E({method:"GET",fullPath:"/v1/climate/products",methodType:"list"})});var Ey=d.method,PE=d.extend({presentPaymentMethod:Ey({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/present_payment_method"}),succeedInputCollection:Ey({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/succeed_input_collection"}),timeoutInputCollection:Ey({method:"POST",fullPath:"/v1/test_helpers/terminal/readers/{reader}/timeout_input_collection"})});var gt=d.method,xE=d.extend({create:gt({method:"POST",fullPath:"/v1/terminal/readers"}),retrieve:gt({method:"GET",fullPath:"/v1/terminal/readers/{reader}"}),update:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}"}),list:gt({method:"GET",fullPath:"/v1/terminal/readers",methodType:"list"}),del:gt({method:"DELETE",fullPath:"/v1/terminal/readers/{reader}"}),cancelAction:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/cancel_action"}),collectInputs:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/collect_inputs"}),processPaymentIntent:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_payment_intent"}),processSetupIntent:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/process_setup_intent"}),refundPayment:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/refund_payment"}),setReaderDisplay:gt({method:"POST",fullPath:"/v1/terminal/readers/{reader}/set_reader_display"})});var x0=d.method,SE=d.extend({create:x0({method:"POST",fullPath:"/v1/test_helpers/treasury/received_credits"})});var TE=d.method,EE=d.extend({retrieve:TE({method:"GET",fullPath:"/v1/treasury/received_credits/{id}"}),list:TE({method:"GET",fullPath:"/v1/treasury/received_credits",methodType:"list"})});var S0=d.method,IE=d.extend({create:S0({method:"POST",fullPath:"/v1/test_helpers/treasury/received_debits"})});var AE=d.method,kE=d.extend({retrieve:AE({method:"GET",fullPath:"/v1/treasury/received_debits/{id}"}),list:AE({method:"GET",fullPath:"/v1/treasury/received_debits",methodType:"list"})});var T0=d.method,wE=d.extend({expire:T0({method:"POST",fullPath:"/v1/test_helpers/refunds/{refund}/expire"})});var Ip=d.method,OE=d.extend({create:Ip({method:"POST",fullPath:"/v1/tax/registrations"}),retrieve:Ip({method:"GET",fullPath:"/v1/tax/registrations/{id}"}),update:Ip({method:"POST",fullPath:"/v1/tax/registrations/{id}"}),list:Ip({method:"GET",fullPath:"/v1/tax/registrations",methodType:"list"})});var Iy=d.method,RE=d.extend({create:Iy({method:"POST",fullPath:"/v1/reporting/report_runs"}),retrieve:Iy({method:"GET",fullPath:"/v1/reporting/report_runs/{report_run}"}),list:Iy({method:"GET",fullPath:"/v1/reporting/report_runs",methodType:"list"})});var CE=d.method,$E=d.extend({retrieve:CE({method:"GET",fullPath:"/v1/reporting/report_types/{report_type}"}),list:CE({method:"GET",fullPath:"/v1/reporting/report_types",methodType:"list"})});var Ay=d.method,NE=d.extend({create:Ay({method:"POST",fullPath:"/v1/forwarding/requests"}),retrieve:Ay({method:"GET",fullPath:"/v1/forwarding/requests/{id}"}),list:Ay({method:"GET",fullPath:"/v1/forwarding/requests",methodType:"list"})});var DE=d.method,zE=d.extend({retrieve:DE({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs/{scheduled_query_run}"}),list:DE({method:"GET",fullPath:"/v1/sigma/scheduled_query_runs",methodType:"list"})});var Ap=d.method,ME=d.extend({create:Ap({method:"POST",fullPath:"/v1/apps/secrets"}),list:Ap({method:"GET",fullPath:"/v1/apps/secrets",methodType:"list"}),deleteWhere:Ap({method:"POST",fullPath:"/v1/apps/secrets/delete"}),find:Ap({method:"GET",fullPath:"/v1/apps/secrets/find"})});var E0=d.method,LE=d.extend({create:E0({method:"POST",fullPath:"/v1/billing_portal/sessions"})});var Yo=d.method,UE=d.extend({create:Yo({method:"POST",fullPath:"/v1/checkout/sessions"}),retrieve:Yo({method:"GET",fullPath:"/v1/checkout/sessions/{session}"}),update:Yo({method:"POST",fullPath:"/v1/checkout/sessions/{session}"}),list:Yo({method:"GET",fullPath:"/v1/checkout/sessions",methodType:"list"}),expire:Yo({method:"POST",fullPath:"/v1/checkout/sessions/{session}/expire"}),listLineItems:Yo({method:"GET",fullPath:"/v1/checkout/sessions/{session}/line_items",methodType:"list"})});var qE=d.method,jE=d.extend({create:qE({method:"POST",fullPath:"/v1/financial_connections/sessions"}),retrieve:qE({method:"GET",fullPath:"/v1/financial_connections/sessions/{session}"})});var FE=d.method,BE=d.extend({retrieve:FE({method:"GET",fullPath:"/v1/tax/settings"}),update:FE({method:"POST",fullPath:"/v1/tax/settings"})});var ZE=d.method,VE=d.extend({retrieve:ZE({method:"GET",fullPath:"/v1/climate/suppliers/{supplier}"}),list:ZE({method:"GET",fullPath:"/v1/climate/suppliers",methodType:"list"})});var Ea=d.method,GE=d.extend({create:Ea({method:"POST",fullPath:"/v1/test_helpers/test_clocks"}),retrieve:Ea({method:"GET",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),list:Ea({method:"GET",fullPath:"/v1/test_helpers/test_clocks",methodType:"list"}),del:Ea({method:"DELETE",fullPath:"/v1/test_helpers/test_clocks/{test_clock}"}),advance:Ea({method:"POST",fullPath:"/v1/test_helpers/test_clocks/{test_clock}/advance"})});var ky=d.method,HE=d.extend({retrieve:ky({method:"GET",fullPath:"/v1/issuing/tokens/{token}"}),update:ky({method:"POST",fullPath:"/v1/issuing/tokens/{token}"}),list:ky({method:"GET",fullPath:"/v1/issuing/tokens",methodType:"list"})});var WE=d.method,KE=d.extend({retrieve:WE({method:"GET",fullPath:"/v1/treasury/transaction_entries/{id}"}),list:WE({method:"GET",fullPath:"/v1/treasury/transaction_entries",methodType:"list"})});var wy=d.method,JE=d.extend({createForceCapture:wy({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_force_capture"}),createUnlinkedRefund:wy({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/create_unlinked_refund"}),refund:wy({method:"POST",fullPath:"/v1/test_helpers/issuing/transactions/{transaction}/refund"})});var XE=d.method,YE=d.extend({retrieve:XE({method:"GET",fullPath:"/v1/financial_connections/transactions/{transaction}"}),list:XE({method:"GET",fullPath:"/v1/financial_connections/transactions",methodType:"list"})});var Oy=d.method,QE=d.extend({retrieve:Oy({method:"GET",fullPath:"/v1/issuing/transactions/{transaction}"}),update:Oy({method:"POST",fullPath:"/v1/issuing/transactions/{transaction}"}),list:Oy({method:"GET",fullPath:"/v1/issuing/transactions",methodType:"list"})});var kp=d.method,eI=d.extend({retrieve:kp({method:"GET",fullPath:"/v1/tax/transactions/{transaction}"}),createFromCalculation:kp({method:"POST",fullPath:"/v1/tax/transactions/create_from_calculation"}),createReversal:kp({method:"POST",fullPath:"/v1/tax/transactions/create_reversal"}),listLineItems:kp({method:"GET",fullPath:"/v1/tax/transactions/{transaction}/line_items",methodType:"list"})});var tI=d.method,rI=d.extend({retrieve:tI({method:"GET",fullPath:"/v1/treasury/transactions/{id}"}),list:tI({method:"GET",fullPath:"/v1/treasury/transactions",methodType:"list"})});var wp=d.method,oI=d.extend({create:wp({method:"POST",fullPath:"/v1/radar/value_list_items"}),retrieve:wp({method:"GET",fullPath:"/v1/radar/value_list_items/{item}"}),list:wp({method:"GET",fullPath:"/v1/radar/value_list_items",methodType:"list"}),del:wp({method:"DELETE",fullPath:"/v1/radar/value_list_items/{item}"})});var Ia=d.method,nI=d.extend({create:Ia({method:"POST",fullPath:"/v1/radar/value_lists"}),retrieve:Ia({method:"GET",fullPath:"/v1/radar/value_lists/{value_list}"}),update:Ia({method:"POST",fullPath:"/v1/radar/value_lists/{value_list}"}),list:Ia({method:"GET",fullPath:"/v1/radar/value_lists",methodType:"list"}),del:Ia({method:"DELETE",fullPath:"/v1/radar/value_lists/{value_list}"})});var iI=d.method,aI=d.extend({retrieve:iI({method:"GET",fullPath:"/v1/identity/verification_reports/{report}"}),list:iI({method:"GET",fullPath:"/v1/identity/verification_reports",methodType:"list"})});var Qo=d.method,sI=d.extend({create:Qo({method:"POST",fullPath:"/v1/identity/verification_sessions"}),retrieve:Qo({method:"GET",fullPath:"/v1/identity/verification_sessions/{session}"}),update:Qo({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}"}),list:Qo({method:"GET",fullPath:"/v1/identity/verification_sessions",methodType:"list"}),cancel:Qo({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/cancel"}),redact:Qo({method:"POST",fullPath:"/v1/identity/verification_sessions/{session}/redact"})});var be=d.method,Ry=d.extend({create:be({method:"POST",fullPath:"/v1/accounts"}),retrieve(e,...t){return typeof e=="string"?be({method:"GET",fullPath:"/v1/accounts/{id}"}).apply(this,[e,...t]):(e==null&&[].shift.apply([e,...t]),be({method:"GET",fullPath:"/v1/account"}).apply(this,[e,...t]))},update:be({method:"POST",fullPath:"/v1/accounts/{account}"}),list:be({method:"GET",fullPath:"/v1/accounts",methodType:"list"}),del:be({method:"DELETE",fullPath:"/v1/accounts/{account}"}),createExternalAccount:be({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts"}),createLoginLink:be({method:"POST",fullPath:"/v1/accounts/{account}/login_links"}),createPerson:be({method:"POST",fullPath:"/v1/accounts/{account}/persons"}),deleteExternalAccount:be({method:"DELETE",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),deletePerson:be({method:"DELETE",fullPath:"/v1/accounts/{account}/persons/{person}"}),listCapabilities:be({method:"GET",fullPath:"/v1/accounts/{account}/capabilities",methodType:"list"}),listExternalAccounts:be({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts",methodType:"list"}),listPersons:be({method:"GET",fullPath:"/v1/accounts/{account}/persons",methodType:"list"}),reject:be({method:"POST",fullPath:"/v1/accounts/{account}/reject"}),retrieveCurrent:be({method:"GET",fullPath:"/v1/account"}),retrieveCapability:be({method:"GET",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),retrieveExternalAccount:be({method:"GET",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),retrievePerson:be({method:"GET",fullPath:"/v1/accounts/{account}/persons/{person}"}),updateCapability:be({method:"POST",fullPath:"/v1/accounts/{account}/capabilities/{capability}"}),updateExternalAccount:be({method:"POST",fullPath:"/v1/accounts/{account}/external_accounts/{id}"}),updatePerson:be({method:"POST",fullPath:"/v1/accounts/{account}/persons/{person}"})});var I0=d.method,cI=d.extend({create:I0({method:"POST",fullPath:"/v1/account_links"})});var A0=d.method,uI=d.extend({create:A0({method:"POST",fullPath:"/v1/account_sessions"})});var Op=d.method,pI=d.extend({create:Op({method:"POST",fullPath:"/v1/apple_pay/domains"}),retrieve:Op({method:"GET",fullPath:"/v1/apple_pay/domains/{domain}"}),list:Op({method:"GET",fullPath:"/v1/apple_pay/domains",methodType:"list"}),del:Op({method:"DELETE",fullPath:"/v1/apple_pay/domains/{domain}"})});var en=d.method,lI=d.extend({retrieve:en({method:"GET",fullPath:"/v1/application_fees/{id}"}),list:en({method:"GET",fullPath:"/v1/application_fees",methodType:"list"}),createRefund:en({method:"POST",fullPath:"/v1/application_fees/{id}/refunds"}),listRefunds:en({method:"GET",fullPath:"/v1/application_fees/{id}/refunds",methodType:"list"}),retrieveRefund:en({method:"GET",fullPath:"/v1/application_fees/{fee}/refunds/{id}"}),updateRefund:en({method:"POST",fullPath:"/v1/application_fees/{fee}/refunds/{id}"})});var k0=d.method,dI=d.extend({retrieve:k0({method:"GET",fullPath:"/v1/balance"})});var mI=d.method,fI=d.extend({retrieve:mI({method:"GET",fullPath:"/v1/balance_transactions/{id}"}),list:mI({method:"GET",fullPath:"/v1/balance_transactions",methodType:"list"})});var tn=d.method,hI=d.extend({create:tn({method:"POST",fullPath:"/v1/charges"}),retrieve:tn({method:"GET",fullPath:"/v1/charges/{charge}"}),update:tn({method:"POST",fullPath:"/v1/charges/{charge}"}),list:tn({method:"GET",fullPath:"/v1/charges",methodType:"list"}),capture:tn({method:"POST",fullPath:"/v1/charges/{charge}/capture"}),search:tn({method:"GET",fullPath:"/v1/charges/search",methodType:"search"})});var w0=d.method,yI=d.extend({retrieve:w0({method:"GET",fullPath:"/v1/confirmation_tokens/{confirmation_token}"})});var gI=d.method,vI=d.extend({retrieve:gI({method:"GET",fullPath:"/v1/country_specs/{country}"}),list:gI({method:"GET",fullPath:"/v1/country_specs",methodType:"list"})});var Aa=d.method,_I=d.extend({create:Aa({method:"POST",fullPath:"/v1/coupons"}),retrieve:Aa({method:"GET",fullPath:"/v1/coupons/{coupon}"}),update:Aa({method:"POST",fullPath:"/v1/coupons/{coupon}"}),list:Aa({method:"GET",fullPath:"/v1/coupons",methodType:"list"}),del:Aa({method:"DELETE",fullPath:"/v1/coupons/{coupon}"})});var mr=d.method,bI=d.extend({create:mr({method:"POST",fullPath:"/v1/credit_notes"}),retrieve:mr({method:"GET",fullPath:"/v1/credit_notes/{id}"}),update:mr({method:"POST",fullPath:"/v1/credit_notes/{id}"}),list:mr({method:"GET",fullPath:"/v1/credit_notes",methodType:"list"}),listLineItems:mr({method:"GET",fullPath:"/v1/credit_notes/{credit_note}/lines",methodType:"list"}),listPreviewLineItems:mr({method:"GET",fullPath:"/v1/credit_notes/preview/lines",methodType:"list"}),preview:mr({method:"GET",fullPath:"/v1/credit_notes/preview"}),voidCreditNote:mr({method:"POST",fullPath:"/v1/credit_notes/{id}/void"})});var O0=d.method,PI=d.extend({create:O0({method:"POST",fullPath:"/v1/customer_sessions"})});var ce=d.method,xI=d.extend({create:ce({method:"POST",fullPath:"/v1/customers"}),retrieve:ce({method:"GET",fullPath:"/v1/customers/{customer}"}),update:ce({method:"POST",fullPath:"/v1/customers/{customer}"}),list:ce({method:"GET",fullPath:"/v1/customers",methodType:"list"}),del:ce({method:"DELETE",fullPath:"/v1/customers/{customer}"}),createBalanceTransaction:ce({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions"}),createFundingInstructions:ce({method:"POST",fullPath:"/v1/customers/{customer}/funding_instructions"}),createSource:ce({method:"POST",fullPath:"/v1/customers/{customer}/sources"}),createTaxId:ce({method:"POST",fullPath:"/v1/customers/{customer}/tax_ids"}),deleteDiscount:ce({method:"DELETE",fullPath:"/v1/customers/{customer}/discount"}),deleteSource:ce({method:"DELETE",fullPath:"/v1/customers/{customer}/sources/{id}"}),deleteTaxId:ce({method:"DELETE",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),listBalanceTransactions:ce({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions",methodType:"list"}),listCashBalanceTransactions:ce({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions",methodType:"list"}),listPaymentMethods:ce({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods",methodType:"list"}),listSources:ce({method:"GET",fullPath:"/v1/customers/{customer}/sources",methodType:"list"}),listTaxIds:ce({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids",methodType:"list"}),retrieveBalanceTransaction:ce({method:"GET",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),retrieveCashBalance:ce({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance"}),retrieveCashBalanceTransaction:ce({method:"GET",fullPath:"/v1/customers/{customer}/cash_balance_transactions/{transaction}"}),retrievePaymentMethod:ce({method:"GET",fullPath:"/v1/customers/{customer}/payment_methods/{payment_method}"}),retrieveSource:ce({method:"GET",fullPath:"/v1/customers/{customer}/sources/{id}"}),retrieveTaxId:ce({method:"GET",fullPath:"/v1/customers/{customer}/tax_ids/{id}"}),search:ce({method:"GET",fullPath:"/v1/customers/search",methodType:"search"}),updateBalanceTransaction:ce({method:"POST",fullPath:"/v1/customers/{customer}/balance_transactions/{transaction}"}),updateCashBalance:ce({method:"POST",fullPath:"/v1/customers/{customer}/cash_balance"}),updateSource:ce({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}"}),verifySource:ce({method:"POST",fullPath:"/v1/customers/{customer}/sources/{id}/verify"})});var Rp=d.method,SI=d.extend({retrieve:Rp({method:"GET",fullPath:"/v1/disputes/{dispute}"}),update:Rp({method:"POST",fullPath:"/v1/disputes/{dispute}"}),list:Rp({method:"GET",fullPath:"/v1/disputes",methodType:"list"}),close:Rp({method:"POST",fullPath:"/v1/disputes/{dispute}/close"})});var TI=d.method,EI=d.extend({create:TI({method:"POST",fullPath:"/v1/ephemeral_keys",validator:s((e,t)=>{if(!t.headers||!t.headers["Stripe-Version"])throw new Error("Passing apiVersion in a separate options hash is required to create an ephemeral key. See https://stripe.com/docs/api/versioning?lang=node")},"validator")}),del:TI({method:"DELETE",fullPath:"/v1/ephemeral_keys/{key}"})});var II=d.method,AI=d.extend({retrieve:II({method:"GET",fullPath:"/v1/events/{id}"}),list:II({method:"GET",fullPath:"/v1/events",methodType:"list"})});var kI=d.method,wI=d.extend({retrieve:kI({method:"GET",fullPath:"/v1/exchange_rates/{rate_id}"}),list:kI({method:"GET",fullPath:"/v1/exchange_rates",methodType:"list"})});var Cp=d.method,OI=d.extend({create:Cp({method:"POST",fullPath:"/v1/file_links"}),retrieve:Cp({method:"GET",fullPath:"/v1/file_links/{link}"}),update:Cp({method:"POST",fullPath:"/v1/file_links/{link}"}),list:Cp({method:"GET",fullPath:"/v1/file_links",methodType:"list"})});var R0=s((e,t,o)=>{let n=(Math.round(Math.random()*1e16)+Math.round(Math.random()*1e16)).toString();o["Content-Type"]=`multipart/form-data; boundary=${n}`;let r=new TextEncoder,i=new Uint8Array(0),a=r.encode(`\r
|
|
54
|
+
`);function c(l){let g=i,h=l instanceof Uint8Array?l:new Uint8Array(r.encode(l));i=new Uint8Array(g.length+h.length+2),i.set(g),i.set(h,g.length),i.set(a,i.length-2)}s(c,"push");function p(l){return`"${l.replace(/"|"/g,"%22").replace(/\r\n|\r|\n/g," ")}"`}s(p,"q");let m=fT(t);for(let l in m){if(!Object.prototype.hasOwnProperty.call(m,l))continue;let g=m[l];if(c(`--${n}`),Object.prototype.hasOwnProperty.call(g,"data")){let h=g;c(`Content-Disposition: form-data; name=${p(l)}; filename=${p(h.name||"blob")}`),c(`Content-Type: ${h.type||"application/octet-stream"}`),c(""),c(h.data)}else c(`Content-Disposition: form-data; name=${p(l)}`),c(""),c(g)}return c(`--${n}--`),i},"multipartDataGenerator");function RI(e,t,o,n){if(t=t||{},e!=="POST")return n(null,lr(t));this._stripe._platformFunctions.tryBufferData(t).then(r=>{let i=R0(e,r,o);return n(null,i)}).catch(r=>n(r,null))}s(RI,"multipartRequestDataProcessor");var Cy=d.method,CI=d.extend({create:Cy({method:"POST",fullPath:"/v1/files",headers:{"Content-Type":"multipart/form-data"},host:"files.stripe.com"}),retrieve:Cy({method:"GET",fullPath:"/v1/files/{file}"}),list:Cy({method:"GET",fullPath:"/v1/files",methodType:"list"}),requestDataProcessor:RI});var ka=d.method,$I=d.extend({create:ka({method:"POST",fullPath:"/v1/invoiceitems"}),retrieve:ka({method:"GET",fullPath:"/v1/invoiceitems/{invoiceitem}"}),update:ka({method:"POST",fullPath:"/v1/invoiceitems/{invoiceitem}"}),list:ka({method:"GET",fullPath:"/v1/invoiceitems",methodType:"list"}),del:ka({method:"DELETE",fullPath:"/v1/invoiceitems/{invoiceitem}"})});var NI=d.method,DI=d.extend({retrieve:NI({method:"GET",fullPath:"/v1/invoice_payments/{invoice_payment}"}),list:NI({method:"GET",fullPath:"/v1/invoice_payments",methodType:"list"})});var $p=d.method,zI=d.extend({retrieve:$p({method:"GET",fullPath:"/v1/invoice_rendering_templates/{template}"}),list:$p({method:"GET",fullPath:"/v1/invoice_rendering_templates",methodType:"list"}),archive:$p({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/archive"}),unarchive:$p({method:"POST",fullPath:"/v1/invoice_rendering_templates/{template}/unarchive"})});var De=d.method,MI=d.extend({create:De({method:"POST",fullPath:"/v1/invoices"}),retrieve:De({method:"GET",fullPath:"/v1/invoices/{invoice}"}),update:De({method:"POST",fullPath:"/v1/invoices/{invoice}"}),list:De({method:"GET",fullPath:"/v1/invoices",methodType:"list"}),del:De({method:"DELETE",fullPath:"/v1/invoices/{invoice}"}),addLines:De({method:"POST",fullPath:"/v1/invoices/{invoice}/add_lines"}),attachPayment:De({method:"POST",fullPath:"/v1/invoices/{invoice}/attach_payment"}),createPreview:De({method:"POST",fullPath:"/v1/invoices/create_preview"}),finalizeInvoice:De({method:"POST",fullPath:"/v1/invoices/{invoice}/finalize"}),listLineItems:De({method:"GET",fullPath:"/v1/invoices/{invoice}/lines",methodType:"list"}),markUncollectible:De({method:"POST",fullPath:"/v1/invoices/{invoice}/mark_uncollectible"}),pay:De({method:"POST",fullPath:"/v1/invoices/{invoice}/pay"}),removeLines:De({method:"POST",fullPath:"/v1/invoices/{invoice}/remove_lines"}),search:De({method:"GET",fullPath:"/v1/invoices/search",methodType:"search"}),sendInvoice:De({method:"POST",fullPath:"/v1/invoices/{invoice}/send"}),updateLines:De({method:"POST",fullPath:"/v1/invoices/{invoice}/update_lines"}),updateLineItem:De({method:"POST",fullPath:"/v1/invoices/{invoice}/lines/{line_item_id}"}),voidInvoice:De({method:"POST",fullPath:"/v1/invoices/{invoice}/void"})});var C0=d.method,LI=d.extend({retrieve:C0({method:"GET",fullPath:"/v1/mandates/{mandate}"})});var UI=d.method,$y="connect.stripe.com",qI=d.extend({basePath:"/",authorizeUrl(e,t){e=e||{},t=t||{};let o="oauth/authorize";return t.express&&(o=`express/${o}`),e.response_type||(e.response_type="code"),e.client_id||(e.client_id=this._stripe.getClientId()),e.scope||(e.scope="read_write"),`https://${$y}/${o}?${lr(e)}`},token:UI({method:"POST",path:"oauth/token",host:$y}),deauthorize(e,...t){return e.client_id||(e.client_id=this._stripe.getClientId()),UI({method:"POST",path:"oauth/deauthorize",host:$y}).apply(this,[e,...t])}});var vt=d.method,jI=d.extend({create:vt({method:"POST",fullPath:"/v1/payment_intents"}),retrieve:vt({method:"GET",fullPath:"/v1/payment_intents/{intent}"}),update:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}"}),list:vt({method:"GET",fullPath:"/v1/payment_intents",methodType:"list"}),applyCustomerBalance:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/apply_customer_balance"}),cancel:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/cancel"}),capture:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/capture"}),confirm:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/confirm"}),incrementAuthorization:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/increment_authorization"}),search:vt({method:"GET",fullPath:"/v1/payment_intents/search",methodType:"search"}),verifyMicrodeposits:vt({method:"POST",fullPath:"/v1/payment_intents/{intent}/verify_microdeposits"})});var wa=d.method,FI=d.extend({create:wa({method:"POST",fullPath:"/v1/payment_links"}),retrieve:wa({method:"GET",fullPath:"/v1/payment_links/{payment_link}"}),update:wa({method:"POST",fullPath:"/v1/payment_links/{payment_link}"}),list:wa({method:"GET",fullPath:"/v1/payment_links",methodType:"list"}),listLineItems:wa({method:"GET",fullPath:"/v1/payment_links/{payment_link}/line_items",methodType:"list"})});var Np=d.method,BI=d.extend({create:Np({method:"POST",fullPath:"/v1/payment_method_configurations"}),retrieve:Np({method:"GET",fullPath:"/v1/payment_method_configurations/{configuration}"}),update:Np({method:"POST",fullPath:"/v1/payment_method_configurations/{configuration}"}),list:Np({method:"GET",fullPath:"/v1/payment_method_configurations",methodType:"list"})});var Oa=d.method,ZI=d.extend({create:Oa({method:"POST",fullPath:"/v1/payment_method_domains"}),retrieve:Oa({method:"GET",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),update:Oa({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}"}),list:Oa({method:"GET",fullPath:"/v1/payment_method_domains",methodType:"list"}),validate:Oa({method:"POST",fullPath:"/v1/payment_method_domains/{payment_method_domain}/validate"})});var rn=d.method,VI=d.extend({create:rn({method:"POST",fullPath:"/v1/payment_methods"}),retrieve:rn({method:"GET",fullPath:"/v1/payment_methods/{payment_method}"}),update:rn({method:"POST",fullPath:"/v1/payment_methods/{payment_method}"}),list:rn({method:"GET",fullPath:"/v1/payment_methods",methodType:"list"}),attach:rn({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/attach"}),detach:rn({method:"POST",fullPath:"/v1/payment_methods/{payment_method}/detach"})});var on=d.method,GI=d.extend({create:on({method:"POST",fullPath:"/v1/payouts"}),retrieve:on({method:"GET",fullPath:"/v1/payouts/{payout}"}),update:on({method:"POST",fullPath:"/v1/payouts/{payout}"}),list:on({method:"GET",fullPath:"/v1/payouts",methodType:"list"}),cancel:on({method:"POST",fullPath:"/v1/payouts/{payout}/cancel"}),reverse:on({method:"POST",fullPath:"/v1/payouts/{payout}/reverse"})});var Ra=d.method,HI=d.extend({create:Ra({method:"POST",fullPath:"/v1/plans"}),retrieve:Ra({method:"GET",fullPath:"/v1/plans/{plan}"}),update:Ra({method:"POST",fullPath:"/v1/plans/{plan}"}),list:Ra({method:"GET",fullPath:"/v1/plans",methodType:"list"}),del:Ra({method:"DELETE",fullPath:"/v1/plans/{plan}"})});var Ca=d.method,WI=d.extend({create:Ca({method:"POST",fullPath:"/v1/prices"}),retrieve:Ca({method:"GET",fullPath:"/v1/prices/{price}"}),update:Ca({method:"POST",fullPath:"/v1/prices/{price}"}),list:Ca({method:"GET",fullPath:"/v1/prices",methodType:"list"}),search:Ca({method:"GET",fullPath:"/v1/prices/search",methodType:"search"})});var Et=d.method,KI=d.extend({create:Et({method:"POST",fullPath:"/v1/products"}),retrieve:Et({method:"GET",fullPath:"/v1/products/{id}"}),update:Et({method:"POST",fullPath:"/v1/products/{id}"}),list:Et({method:"GET",fullPath:"/v1/products",methodType:"list"}),del:Et({method:"DELETE",fullPath:"/v1/products/{id}"}),createFeature:Et({method:"POST",fullPath:"/v1/products/{product}/features"}),deleteFeature:Et({method:"DELETE",fullPath:"/v1/products/{product}/features/{id}"}),listFeatures:Et({method:"GET",fullPath:"/v1/products/{product}/features",methodType:"list"}),retrieveFeature:Et({method:"GET",fullPath:"/v1/products/{product}/features/{id}"}),search:Et({method:"GET",fullPath:"/v1/products/search",methodType:"search"})});var Dp=d.method,JI=d.extend({create:Dp({method:"POST",fullPath:"/v1/promotion_codes"}),retrieve:Dp({method:"GET",fullPath:"/v1/promotion_codes/{promotion_code}"}),update:Dp({method:"POST",fullPath:"/v1/promotion_codes/{promotion_code}"}),list:Dp({method:"GET",fullPath:"/v1/promotion_codes",methodType:"list"})});var It=d.method,XI=d.extend({create:It({method:"POST",fullPath:"/v1/quotes"}),retrieve:It({method:"GET",fullPath:"/v1/quotes/{quote}"}),update:It({method:"POST",fullPath:"/v1/quotes/{quote}"}),list:It({method:"GET",fullPath:"/v1/quotes",methodType:"list"}),accept:It({method:"POST",fullPath:"/v1/quotes/{quote}/accept"}),cancel:It({method:"POST",fullPath:"/v1/quotes/{quote}/cancel"}),finalizeQuote:It({method:"POST",fullPath:"/v1/quotes/{quote}/finalize"}),listComputedUpfrontLineItems:It({method:"GET",fullPath:"/v1/quotes/{quote}/computed_upfront_line_items",methodType:"list"}),listLineItems:It({method:"GET",fullPath:"/v1/quotes/{quote}/line_items",methodType:"list"}),pdf:It({method:"GET",fullPath:"/v1/quotes/{quote}/pdf",host:"files.stripe.com",streaming:!0})});var $a=d.method,YI=d.extend({create:$a({method:"POST",fullPath:"/v1/refunds"}),retrieve:$a({method:"GET",fullPath:"/v1/refunds/{refund}"}),update:$a({method:"POST",fullPath:"/v1/refunds/{refund}"}),list:$a({method:"GET",fullPath:"/v1/refunds",methodType:"list"}),cancel:$a({method:"POST",fullPath:"/v1/refunds/{refund}/cancel"})});var Ny=d.method,QI=d.extend({retrieve:Ny({method:"GET",fullPath:"/v1/reviews/{review}"}),list:Ny({method:"GET",fullPath:"/v1/reviews",methodType:"list"}),approve:Ny({method:"POST",fullPath:"/v1/reviews/{review}/approve"})});var $0=d.method,eA=d.extend({list:$0({method:"GET",fullPath:"/v1/setup_attempts",methodType:"list"})});var Gr=d.method,tA=d.extend({create:Gr({method:"POST",fullPath:"/v1/setup_intents"}),retrieve:Gr({method:"GET",fullPath:"/v1/setup_intents/{intent}"}),update:Gr({method:"POST",fullPath:"/v1/setup_intents/{intent}"}),list:Gr({method:"GET",fullPath:"/v1/setup_intents",methodType:"list"}),cancel:Gr({method:"POST",fullPath:"/v1/setup_intents/{intent}/cancel"}),confirm:Gr({method:"POST",fullPath:"/v1/setup_intents/{intent}/confirm"}),verifyMicrodeposits:Gr({method:"POST",fullPath:"/v1/setup_intents/{intent}/verify_microdeposits"})});var zp=d.method,rA=d.extend({create:zp({method:"POST",fullPath:"/v1/shipping_rates"}),retrieve:zp({method:"GET",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),update:zp({method:"POST",fullPath:"/v1/shipping_rates/{shipping_rate_token}"}),list:zp({method:"GET",fullPath:"/v1/shipping_rates",methodType:"list"})});var Na=d.method,oA=d.extend({create:Na({method:"POST",fullPath:"/v1/sources"}),retrieve:Na({method:"GET",fullPath:"/v1/sources/{source}"}),update:Na({method:"POST",fullPath:"/v1/sources/{source}"}),listSourceTransactions:Na({method:"GET",fullPath:"/v1/sources/{source}/source_transactions",methodType:"list"}),verify:Na({method:"POST",fullPath:"/v1/sources/{source}/verify"})});var Da=d.method,nA=d.extend({create:Da({method:"POST",fullPath:"/v1/subscription_items"}),retrieve:Da({method:"GET",fullPath:"/v1/subscription_items/{item}"}),update:Da({method:"POST",fullPath:"/v1/subscription_items/{item}"}),list:Da({method:"GET",fullPath:"/v1/subscription_items",methodType:"list"}),del:Da({method:"DELETE",fullPath:"/v1/subscription_items/{item}"})});var nn=d.method,iA=d.extend({create:nn({method:"POST",fullPath:"/v1/subscription_schedules"}),retrieve:nn({method:"GET",fullPath:"/v1/subscription_schedules/{schedule}"}),update:nn({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}"}),list:nn({method:"GET",fullPath:"/v1/subscription_schedules",methodType:"list"}),cancel:nn({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/cancel"}),release:nn({method:"POST",fullPath:"/v1/subscription_schedules/{schedule}/release"})});var fr=d.method,aA=d.extend({create:fr({method:"POST",fullPath:"/v1/subscriptions"}),retrieve:fr({method:"GET",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),update:fr({method:"POST",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),list:fr({method:"GET",fullPath:"/v1/subscriptions",methodType:"list"}),cancel:fr({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}"}),deleteDiscount:fr({method:"DELETE",fullPath:"/v1/subscriptions/{subscription_exposed_id}/discount"}),resume:fr({method:"POST",fullPath:"/v1/subscriptions/{subscription}/resume"}),search:fr({method:"GET",fullPath:"/v1/subscriptions/search",methodType:"search"})});var sA=d.method,cA=d.extend({retrieve:sA({method:"GET",fullPath:"/v1/tax_codes/{id}"}),list:sA({method:"GET",fullPath:"/v1/tax_codes",methodType:"list"})});var Mp=d.method,uA=d.extend({create:Mp({method:"POST",fullPath:"/v1/tax_ids"}),retrieve:Mp({method:"GET",fullPath:"/v1/tax_ids/{id}"}),list:Mp({method:"GET",fullPath:"/v1/tax_ids",methodType:"list"}),del:Mp({method:"DELETE",fullPath:"/v1/tax_ids/{id}"})});var Lp=d.method,pA=d.extend({create:Lp({method:"POST",fullPath:"/v1/tax_rates"}),retrieve:Lp({method:"GET",fullPath:"/v1/tax_rates/{tax_rate}"}),update:Lp({method:"POST",fullPath:"/v1/tax_rates/{tax_rate}"}),list:Lp({method:"GET",fullPath:"/v1/tax_rates",methodType:"list"})});var lA=d.method,dA=d.extend({create:lA({method:"POST",fullPath:"/v1/tokens"}),retrieve:lA({method:"GET",fullPath:"/v1/tokens/{token}"})});var za=d.method,mA=d.extend({create:za({method:"POST",fullPath:"/v1/topups"}),retrieve:za({method:"GET",fullPath:"/v1/topups/{topup}"}),update:za({method:"POST",fullPath:"/v1/topups/{topup}"}),list:za({method:"GET",fullPath:"/v1/topups",methodType:"list"}),cancel:za({method:"POST",fullPath:"/v1/topups/{topup}/cancel"})});var hr=d.method,fA=d.extend({create:hr({method:"POST",fullPath:"/v1/transfers"}),retrieve:hr({method:"GET",fullPath:"/v1/transfers/{transfer}"}),update:hr({method:"POST",fullPath:"/v1/transfers/{transfer}"}),list:hr({method:"GET",fullPath:"/v1/transfers",methodType:"list"}),createReversal:hr({method:"POST",fullPath:"/v1/transfers/{id}/reversals"}),listReversals:hr({method:"GET",fullPath:"/v1/transfers/{id}/reversals",methodType:"list"}),retrieveReversal:hr({method:"GET",fullPath:"/v1/transfers/{transfer}/reversals/{id}"}),updateReversal:hr({method:"POST",fullPath:"/v1/transfers/{transfer}/reversals/{id}"})});var Ma=d.method,hA=d.extend({create:Ma({method:"POST",fullPath:"/v1/webhook_endpoints"}),retrieve:Ma({method:"GET",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),update:Ma({method:"POST",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"}),list:Ma({method:"GET",fullPath:"/v1/webhook_endpoints",methodType:"list"}),del:Ma({method:"DELETE",fullPath:"/v1/webhook_endpoints/{webhook_endpoint}"})});var N0=de("apps",{Secrets:ME}),D0=de("billing",{Alerts:wT,CreditBalanceSummary:qT,CreditBalanceTransactions:FT,CreditGrants:BT,MeterEventAdjustments:oE,MeterEvents:sE,Meters:uE}),z0=de("billingPortal",{Configurations:zT,Sessions:LE}),M0=de("checkout",{Sessions:UE}),L0=de("climate",{Orders:pE,Products:bE,Suppliers:VE}),U0=de("entitlements",{ActiveEntitlements:kT,Features:YT}),q0=de("financialConnections",{Accounts:IT,Sessions:jE,Transactions:YE}),j0=de("forwarding",{Requests:NE}),F0=de("identity",{VerificationReports:aI,VerificationSessions:sI}),B0=de("issuing",{Authorizations:RT,Cardholders:$T,Cards:DT,Disputes:HT,PersonalizationDesigns:yE,PhysicalBundles:vE,Tokens:HE,Transactions:QE}),Z0=de("radar",{EarlyFraudWarnings:KT,ValueListItems:oI,ValueLists:nI}),V0=de("reporting",{ReportRuns:RE,ReportTypes:$E}),G0=de("sigma",{ScheduledQueryRuns:zE}),H0=de("tax",{Calculations:CT,Registrations:OE,Settings:BE,Transactions:eI}),W0=de("terminal",{Configurations:MT,ConnectionTokens:UT,Locations:rE,Readers:xE}),K0=de("testHelpers",{ConfirmationTokens:LT,Customers:VT,Refunds:wE,TestClocks:GE,Issuing:de("issuing",{Authorizations:OT,Cards:NT,PersonalizationDesigns:hE,Transactions:JE}),Terminal:de("terminal",{Readers:PE}),Treasury:de("treasury",{InboundTransfers:eE,OutboundPayments:lE,OutboundTransfers:mE,ReceivedCredits:SE,ReceivedDebits:IE})}),J0=de("treasury",{CreditReversals:ZT,DebitReversals:GT,FinancialAccounts:QT,InboundTransfers:tE,OutboundPayments:dE,OutboundTransfers:fE,ReceivedCredits:EE,ReceivedDebits:kE,TransactionEntries:KE,Transactions:rI}),X0=de("v2",{Billing:de("billing",{MeterEventAdjustments:nE,MeterEventSession:iE,MeterEventStream:aE,MeterEvents:cE}),Core:de("core",{EventDestinations:JT,Events:XT})});var yA="api.stripe.com",gA="443",vA="/v1/",_A=ET,bA=8e4,PA=5,xA=.5,Y0=["name","version","url","partner_id"],SA=["authenticator","apiVersion","typescript","maxNetworkRetries","httpAgent","httpClient","timeout","host","port","protocol","telemetry","appInfo","stripeAccount","stripeContext"],Q0=s(e=>new fp(e,d.MAX_BUFFERED_REQUEST_METRICS),"defaultRequestSenderFactory");function TA(e,t=Q0){o.PACKAGE_VERSION="18.2.1",o.USER_AGENT=Object.assign({bindings_version:o.PACKAGE_VERSION,lang:"node",publisher:"stripe",uname:null,typescript:!1},hT()),o.StripeResource=d,o.resources=an,o.HttpClient=Le,o.HttpClientResponse=cr,o.CryptoProvider=sr,o.webhooks=TT(e);function o(n,r={}){if(!(this instanceof o))return new o(n,r);let i=this._getPropsFromConfig(r);this._platformFunctions=e,Object.defineProperty(this,"_emitter",{value:this._platformFunctions.createEmitter(),enumerable:!1,configurable:!1,writable:!1}),this.VERSION=o.PACKAGE_VERSION,this.on=this._emitter.on.bind(this._emitter),this.once=this._emitter.once.bind(this._emitter),this.off=this._emitter.removeListener.bind(this._emitter);let a=i.httpAgent||null;this._api={host:i.host||yA,port:i.port||gA,protocol:i.protocol||"https",basePath:vA,version:i.apiVersion||_A,timeout:rp("timeout",i.timeout,bA),maxNetworkRetries:rp("maxNetworkRetries",i.maxNetworkRetries,2),agent:a,httpClient:i.httpClient||(a?this._platformFunctions.createNodeHttpClient(a):this._platformFunctions.createDefaultHttpClient()),dev:!1,stripeAccount:i.stripeAccount||null,stripeContext:i.stripeContext||null};let c=i.typescript||!1;c!==o.USER_AGENT.typescript&&(o.USER_AGENT.typescript=c),i.appInfo&&this._setAppInfo(i.appInfo),this._prepResources(),this._setAuthenticator(n,i.authenticator),this.errors=dp,this.webhooks=o.webhooks,this._prevRequestMetrics=[],this._enableTelemetry=i.telemetry!==!1,this._requestSender=t(this),this.StripeResource=o.StripeResource}return s(o,"Stripe"),o.errors=dp,o.createNodeHttpClient=e.createNodeHttpClient,o.createFetchHttpClient=e.createFetchHttpClient,o.createNodeCryptoProvider=e.createNodeCryptoProvider,o.createSubtleCryptoProvider=e.createSubtleCryptoProvider,o.prototype={_appInfo:void 0,on:null,off:null,once:null,VERSION:null,StripeResource:null,webhooks:null,errors:null,_api:null,_prevRequestMetrics:null,_emitter:null,_enableTelemetry:null,_requestSender:null,_platformFunctions:null,rawRequest(n,r,i,a){return this._requestSender._rawRequest(n,r,i,a)},_setAuthenticator(n,r){if(n&&r)throw new Error("Can't specify both apiKey and authenticator");if(!n&&!r)throw new Error("Neither apiKey nor config.authenticator provided");this._authenticator=n?Yu(n):r},_setAppInfo(n){if(n&&typeof n!="object")throw new Error("AppInfo must be an object.");if(n&&!n.name)throw new Error("AppInfo.name is required");n=n||{},this._appInfo=Y0.reduce((r,i)=>(typeof n[i]=="string"&&(r=r||{},r[i]=n[i]),r),{})},_setApiField(n,r){this._api[n]=r},getApiField(n){return this._api[n]},setClientId(n){this._clientId=n},getClientId(){return this._clientId},getConstant:s(n=>{switch(n){case"DEFAULT_HOST":return yA;case"DEFAULT_PORT":return gA;case"DEFAULT_BASE_PATH":return vA;case"DEFAULT_API_VERSION":return _A;case"DEFAULT_TIMEOUT":return bA;case"MAX_NETWORK_RETRY_DELAY_SEC":return PA;case"INITIAL_NETWORK_RETRY_DELAY_SEC":return xA}return o[n]},"getConstant"),getMaxNetworkRetries(){return this.getApiField("maxNetworkRetries")},_setApiNumberField(n,r,i){let a=rp(n,r,i);this._setApiField(n,a)},getMaxNetworkRetryDelay(){return PA},getInitialNetworkRetryDelay(){return xA},getClientUserAgent(n){return this.getClientUserAgentSeeded(o.USER_AGENT,n)},getClientUserAgentSeeded(n,r){this._platformFunctions.getUname().then(i=>{var a;let c={};for(let m in n)Object.prototype.hasOwnProperty.call(n,m)&&(c[m]=encodeURIComponent((a=n[m])!==null&&a!==void 0?a:"null"));c.uname=encodeURIComponent(i||"UNKNOWN");let p=this.getApiField("httpClient");p&&(c.httplib=encodeURIComponent(p.getClientName())),this._appInfo&&(c.application=this._appInfo),r(JSON.stringify(c))})},getAppInfoAsString(){if(!this._appInfo)return"";let n=this._appInfo.name;return this._appInfo.version&&(n+=`/${this._appInfo.version}`),this._appInfo.url&&(n+=` (${this._appInfo.url})`),n},getTelemetryEnabled(){return this._enableTelemetry},_prepResources(){for(let n in an)Object.prototype.hasOwnProperty.call(an,n)&&(this[mT(n)]=new an[n](this))},_getPropsFromConfig(n){if(!n)return{};let r=typeof n=="string";if(!(n===Object(n)&&!Array.isArray(n))&&!r)throw new Error("Config must either be an object or a string");if(r)return{apiVersion:n};if(Object.keys(n).filter(c=>!SA.includes(c)).length>0)throw new Error(`Config object may only contain the following: ${SA.join(", ")}`);return n},parseThinEvent(n,r,i,a,c,p){return this.webhooks.constructEvent(n,r,i,a,c,p)}},o}s(TA,"createStripe");var EA=TA(new mp);var Lt="https://api.stripe.com/v1",Be=s(e=>new EA(e,{apiVersion:"2025-05-28.basil"}),"getClient"),P={baseUrl:Lt,subscribeWebhook:s(async(e,t,o)=>{let n={method:"POST",url:`${Lt}/webhook_endpoints`,headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{"enabled_events[]":e,url:t},authentication:{type:"BEARER_TOKEN",token:o},queryParams:{}},{body:r}=await b.sendRequest(n);return r},"subscribeWebhook"),unsubscribeWebhook:s(async(e,t)=>{let o={method:"DELETE",url:`${Lt}/webhook_endpoints/${e}`,authentication:{type:"BEARER_TOKEN",token:t}};return await b.sendRequest(o)},"unsubscribeWebhook"),invoice:u.Dropdown({auth:_,displayName:"Invoice",required:!0,refreshers:[],options:s(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your Stripe account first"};try{return{disabled:!1,options:(await Be(e.secret_text).invoices.list({limit:100,expand:["data.customer"]})).data.map(n=>{let r=n.customer,i=r?.name||r?.email||"Unknown Customer",a=(n.total/100).toFixed(2),c=`Invoice #${n.number||n.id} for ${i} (${a} ${n.currency.toUpperCase()})`;return{value:n.id,label:c}}).filter(n=>n.value!==void 0&&n.value!==null)}}catch(t){return console.error("Failed to load Stripe invoices:",t),{disabled:!0,options:[],placeholder:"Error loading invoices. Check connection."}}},"options")}),customer:u.Dropdown({auth:_,displayName:"Customer",required:!0,refreshers:[],options:s(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let o={method:"GET",authentication:{type:"BEARER_TOKEN",token:e.secret_text},url:t?`${Lt}/customers/search`:`${Lt}/customers`,queryParams:t?{query:`name~"${t}" OR email~"${t}"`}:{limit:"100"}},n=await b.sendRequest(o);return n.status===200?{disabled:!1,options:n.body.data.map(r=>({value:r.id,label:`${r.name||r.id} (${r.email||"No Email"})`}))}:{disabled:!0,options:[],placeholder:"Couldn't load customers"}},"options")}),product:u.Dropdown({auth:_,displayName:"Product",required:!0,refreshers:[],options:s(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let o="active:'true'";t&&(o+=` AND name~"${t}"`);let n=await b.sendRequest({method:"GET",url:`${Lt}/products/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:o}});return n.status===200?{disabled:!1,options:n.body.data.map(r=>({value:r.id,label:r.name}))}:{disabled:!0,options:[],placeholder:"Couldn't load products"}},"options")}),price:u.Dropdown({auth:_,displayName:"Price",required:!0,refreshers:[],options:s(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let o=await b.sendRequest({method:"GET",url:`${Lt}/prices/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:`active:'true' AND type:'recurring' AND (product.name~"${t||""}" OR nickname~"${t||""}")`,expand:"data.product"}});return o.status===200?{disabled:!1,options:o.body.data.map(n=>{let r=n.nickname?`${n.nickname} (${n.product.name})`:n.product.name;return{value:n.id,label:r}})}:{disabled:!0,options:[],placeholder:"Couldn't load prices"}},"options")}),subscription:u.Dropdown({auth:_,displayName:"Subscription",required:!0,refreshers:[],options:s(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account first"};try{return{disabled:!1,options:(await Be(e.secret_text).subscriptions.list({limit:100,status:"active",expand:["data.customer"]})).data.map(n=>{let r=n.customer,a=`Subscription for ${r?.name||r?.email||"Unknown Customer"} (${n.id})`;return{value:n.id,label:a}})}}catch(t){return console.error("Failed to load Stripe subscriptions:",t),{disabled:!0,options:[],placeholder:"Couldn't load subscriptions. See console."}}},"options")}),payout:u.Dropdown({auth:_,displayName:"Payout",required:!0,refreshers:[],options:s(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let t=await b.sendRequest({method:"GET",url:`${Lt}/payouts`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{limit:"100"}});return t.status===200?{disabled:!1,options:t.body.data.map(o=>{let n=new Date(o.arrival_date*1e3).toLocaleDateString(),r=(o.amount/100).toFixed(2),i=`Payout on ${n} - ${r} ${o.currency.toUpperCase()} (${o.status})`;return{value:o.id,label:i}})}:{disabled:!0,options:[],placeholder:"Couldn't load payouts"}},"options")}),paymentIntent:u.Dropdown({auth:_,displayName:"Payment Intent",required:!0,refreshers:[],options:s(async({auth:e,searchValue:t})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};let o="status:'succeeded'";t&&(o+=` AND customer.email~"${t}"`);let n=await b.sendRequest({method:"GET",url:`${Lt}/payment_intents/search`,authentication:{type:"BEARER_TOKEN",token:e.secret_text},queryParams:{query:o,"expand[]":"data.customer"}});return n.status===200?{disabled:!1,options:n.body.data.map(r=>{let i=r.customer?.name||r.customer?.email||"Unknown Customer",a=(r.amount/100).toFixed(2),c=`Payment from ${i} - ${a} ${r.currency.toUpperCase()}`;return{value:r.id,label:c}})}:{disabled:!0,options:[],placeholder:"Couldn't load payment intents"}},"options")}),paymentLink:u.Dropdown({auth:_,displayName:"Payment Link",required:!0,refreshers:[],options:s(async({auth:e})=>{if(!e)return{disabled:!0,options:[],placeholder:"Please connect your account"};try{return{disabled:!1,options:(await Be(e.secret_text).paymentLinks.list({active:!0,limit:100})).data.map(n=>({value:n.id,label:n.url}))}}catch{return{disabled:!0,options:[],placeholder:"Couldn't load payment links"}}},"options")})};var IA=E({name:"search_customer",classification:"SEARCH",auth:_,displayName:"Search Customer",description:"Search for a customer in stripe by email",audience:"human",aiMetadata:{description:"Looks up Stripe customers matching a given email address. Use to find an existing customer record before creating, updating, or charging one, to avoid duplicates. Read-only and idempotent; matches on the exact email.",idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:void 0,required:!0})},outputSchema:Lu,async run(e){let t={email:e.propsValue.email};return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers/search`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Stripe-Version":"2026-02-25.clover"},queryParams:{query:`email:'${t.email}'`}})).body}});var AA=ue({auth:_,name:"new_customer",classification:"READ",displayName:"New Customer",description:"Triggers when a new customer is created",aiMetadata:{description:"Fires when a new customer is created in Stripe (the customer.created event), emitting the new customer record. Use to react to customer onboarding, such as syncing them to a CRM or sending a welcome flow."},props:{},outputSchema:Je,sampleData:{id:"cus_NGtyEf4hNGTj3p",object:"customer",address:null,balance:0,created:1675180509,currency:null,default_currency:null,default_source:null,delinquent:!1,description:null,discount:null,email:"jane@example.com",invoice_prefix:"B7162248",invoice_settings:{custom_fields:null,default_payment_method:null,footer:null,rendering_options:null},livemode:!1,metadata:{},name:"John Doe",next_invoice_sequence:1,phone:null,preferred_locales:[],shipping:null,tax_exempt:"none",test_clock:null},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("customer.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_customer_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_customer_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var kA=ue({auth:_,name:"new_payment",classification:"READ",displayName:"New Payment",description:"Triggers when a new payment is made",aiMetadata:{description:"Fires when a payment succeeds in Stripe (the payment_intent.succeeded event), emitting the completed payment. Use to react to a successful payment, such as fulfilling an order or recording revenue."},props:{},type:"WEBHOOK",outputSchema:qe,sampleData:{id:"pi_3MWM7aKZ0dZRqLEK1soCKVrq",object:"payment_intent",amount:1e4,amount_capturable:0,amount_received:1e4,capture_method:"automatic_async",confirmation_method:"automatic",created:1675180355,currency:"usd",customer:"cus_NGtvUQ18FJXcGI",description:"Subscription creation",latest_charge:"ch_3MWM7aKZ0dZRqLEK1soCKVrq",livemode:!1,metadata:{},payment_method:"pm_1MWM8MKZ0dZRqLEKnIH41f76",receipt_email:null,setup_future_usage:null,status:"succeeded"},async onEnable(e){let t=await P.subscribeWebhook("payment_intent.succeeded",e.webhookUrl,e.auth.secret_text);await e.store?.put("_new_payment_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_payment_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/payment_intents/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"succeeded"',limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var wA=ue({auth:_,name:"new_subscription",classification:"READ",displayName:"New Subscription",description:"Triggers when a new subscription is made",aiMetadata:{description:"Fires when a new subscription is created in Stripe (the customer.subscription.created event), emitting the new subscription. Use to react to a customer starting recurring billing, such as provisioning access or sending an onboarding flow."},props:{},type:"WEBHOOK",outputSchema:Ne,sampleData:{id:"sub_1MWMJXKZ0dZRqLEKJX80JXfv",object:"subscription",application:null,application_fee_percent:null,automatic_tax:{enabled:!0},billing_cycle_anchor:1675181047,billing_thresholds:null,cancel_at:null,cancel_at_period_end:!1,canceled_at:null,collection_method:"charge_automatically",created:1675181047,currency:"usd",current_period_end:1677600247,current_period_start:1675181047,customer:"cus_NGtvUQ18FJXcGI",days_until_due:null,default_payment_method:"pm_1MWM8MKZ0dZRqLEKnIH41f76",default_source:null,default_tax_rates:[],description:null,discount:null,ended_at:null,items:{object:"list",data:[{id:"si_NGu7pb7hS3Rps3",object:"subscription_item",billing_thresholds:null,created:1675181048,metadata:{},plan:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"plan",active:!0,aggregate_usage:null,amount:1e4,amount_decimal:"10000",billing_scheme:"per_unit",created:1675179777,currency:"usd",interval:"month",interval_count:1,livemode:!1,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",tiers_mode:null,transform_usage:null,trial_period_days:null,usage_type:"licensed"},price:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"price",active:!0,billing_scheme:"per_unit",created:1675179777,currency:"usd",custom_unit_amount:null,livemode:!1,lookup_key:null,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",recurring:{aggregate_usage:null,interval:"month",interval_count:1,trial_period_days:null,usage_type:"licensed"},tax_behavior:"exclusive",tiers_mode:null,transform_quantity:null,type:"recurring",unit_amount:1e4,unit_amount_decimal:"10000"},quantity:1,subscription:"sub_1MWMJXKZ0dZRqLEKJX80JXfv",tax_rates:[]}],has_more:!1,total_count:1,url:"/v1/subscription_items?subscription=sub_1MWMJXKZ0dZRqLEKJX80JXfv"},latest_invoice:"in_1MWMJXKZ0dZRqLEKIu4a51u7",livemode:!1,metadata:{},next_pending_invoice_item_invoice:null,on_behalf_of:null,pause_collection:null,payment_settings:{payment_method_options:null,payment_method_types:null,save_default_payment_method:"off"},pending_invoice_item_interval:null,pending_setup_intent:null,pending_update:null,plan:{id:"price_1MWLz3KZ0dZRqLEK06gRMHCF",object:"plan",active:!0,aggregate_usage:null,amount:1e4,amount_decimal:"10000",billing_scheme:"per_unit",created:1675179777,currency:"usd",interval:"month",interval_count:1,livemode:!1,metadata:{},nickname:null,product:"prod_NGtm3AlvaGjaLN",tiers_mode:null,transform_usage:null,trial_period_days:null,usage_type:"licensed"},quantity:1,schedule:null,start_date:1675181047,status:"active",test_clock:null,transfer_data:null,trial_end:null,trial_start:null},async onEnable(e){let t=await P.subscribeWebhook("customer.subscription.created",e.webhookUrl,e.auth.secret_text);await e.store?.put("_new_customer_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_new_customer_subscription_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var OA=ue({auth:_,name:"payment_failed",classification:"READ",displayName:"Payment Failed",description:"Triggers when a payment fails",aiMetadata:{description:"Fires when a charge fails in Stripe (the charge.failed event), emitting the failed charge including its failure code and message. Use to react to declined payments, such as alerting the customer or triggering a retry/dunning flow."},props:{},outputSchema:Mo,sampleData:{id:"ch_3MWMPQKZ0dZRqLEK063rxD7q",object:"charge",amount:1e5,amount_captured:0,amount_refunded:0,application:null,application_fee:null,application_fee_amount:null,balance_transaction:null,billing_details:{address:{city:null,country:null,line1:null,line2:null,postal_code:"12321",state:null},email:null,name:null,phone:null},calculated_statement_descriptor:"WWW.ACTIVEPIECES.COM",captured:!1,created:1675181413,currency:"usd",customer:"cus_NGtvUQ18FJXcGI",description:"Failed Payment",destination:null,dispute:null,disputed:!1,failure_balance_transaction:null,failure_code:"card_declined",failure_message:"Your card was declined.",fraud_details:{},invoice:null,livemode:!1,metadata:{},on_behalf_of:null,order:null,outcome:{network_status:"declined_by_network",reason:"generic_decline",risk_level:"normal",risk_score:60,seller_message:"The bank did not return any further details with this decline.",type:"issuer_declined"},paid:!1,payment_intent:"pi_3MWMPQKZ0dZRqLEK0Nsc6WhL",payment_method:"src_1MWMPQKZ0dZRqLEKuQ83wmZI",payment_method_details:{card:{brand:"visa",checks:{address_line1_check:null,address_postal_code_check:"pass",cvc_check:"pass"},country:"US",exp_month:12,exp_year:2031,fingerprint:"mtYxM2Q4edpEt8Pw",funding:"credit",installments:null,last4:"0341",mandate:null,network:"visa",three_d_secure:null,wallet:null},type:"card"},receipt_email:null,receipt_number:null,receipt_url:null,refunded:!1,refunds:{object:"list",data:[],has_more:!1,total_count:0,url:"/v1/charges/ch_3MWMPQKZ0dZRqLEK063rxD7q/refunds"},review:null,shipping:null,source:{id:"src_1MWMPQKZ0dZRqLEKuQ83wmZI",object:"source",amount:null,card:{exp_month:12,exp_year:2031,last4:"0341",country:"US",brand:"Visa",address_zip_check:"pass",cvc_check:"pass",funding:"credit",fingerprint:"mtYxM2Q4edpEt8Pw",three_d_secure:"optional",name:null,address_line1_check:null,tokenization_method:null,dynamic_last4:null},client_secret:"src_client_secret_TlLkl6IvhCvmbx8Cz12YNDVb",created:1675181413,currency:null,flow:"none",livemode:!1,metadata:{},owner:{address:{city:null,country:null,line1:null,line2:null,postal_code:"12321",state:null},email:null,name:null,phone:null,verified_address:null,verified_email:null,verified_name:null,verified_phone:null},statement_descriptor:null,status:"chargeable",type:"card",usage:"reusable"},source_transfer:null,statement_descriptor:"www.activepieces.com",statement_descriptor_suffix:null,status:"failed",transfer_data:null,transfer_group:null},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("charge.failed",e.webhookUrl,e.auth.secret_text);await e.store?.put("_payment_failed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store?.get("_payment_failed_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/charges/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"failed"',limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var e1=[{label:"All Statuses",value:""},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}],RA=E({name:"search_subscriptions",classification:"SEARCH",auth:_,displayName:"Search Subscriptions",description:"Search for subscriptions by price ID, status, customer ID and other filters, including customer details",audience:"human",aiMetadata:{description:"Lists and filters Stripe subscriptions by price ID, status, customer ID, and creation date range, optionally expanding full customer details for each. Use to find subscriptions matching criteria or to audit a customer's subscriptions; supports paging through all results. Read-only and idempotent.",idempotent:!0},props:{price_ids:u.LongText({displayName:"Price IDs",description:"Comma-separated list of price IDs to filter by (e.g., price_1ABC123, price_2DEF456)",required:!1}),status:u.StaticDropdown({displayName:"Subscription Status",description:"Filter by subscription status",required:!1,options:{options:e1}}),customer_id:u.ShortText({displayName:"Customer ID",description:"Filter by specific customer ID (optional)",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Filter subscriptions created after this date (YYYY-MM-DD format)",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Filter subscriptions created before this date (YYYY-MM-DD format)",required:!1}),limit:u.Number({displayName:"Limit",description:"Maximum number of subscriptions to return (default: 100, set to 0 for all)",required:!1,defaultValue:100}),fetch_all:u.Checkbox({displayName:"Fetch All Results",description:"Fetch all matching subscriptions (ignores limit, may take longer for large datasets)",required:!1,defaultValue:!1}),include_customer_details:u.Checkbox({displayName:"Include Customer Details",description:"Fetch detailed customer information for each subscription",required:!1,defaultValue:!0})},outputSchema:Uu,async run(e){let{price_ids:t,status:o,customer_id:n,created_after:r,created_before:i,limit:a=100,fetch_all:c=!1,include_customer_details:p=!0}=e.propsValue,m=s(x=>{let k=new URLSearchParams;if(k.append("limit","100"),k.append("expand[]","data.items.data.price"),p&&k.append("expand[]","data.customer"),o&&k.append("status",o),n&&k.append("customer",n),r){let R=Math.floor(new Date(r).getTime()/1e3);k.append("created[gte]",R.toString())}if(i){let R=Math.floor(new Date(i).getTime()/1e3);k.append("created[lte]",R.toString())}return x&&k.append("starting_after",x),k},"buildQueryParams"),l=[],g=!0,h,f=0,v=c?50:Math.ceil(a/100);for(;g&&f<v;){let x=m(h),k=await b.sendRequest({method:"GET",url:`${P.baseUrl}/subscriptions?${x.toString()}`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"}});if(!k.body)throw new Error("Failed to fetch subscriptions from Stripe");let R=k.body.data;if(l=l.concat(R),g=k.body.has_more,f++,g&&R.length>0&&(h=R[R.length-1].id),!c&&l.length>=a){l=l.slice(0,a);break}}let I=l;if(t&&t.trim()){let x=t.split(",").map(k=>k.trim()).filter(k=>k.length>0);x.length>0&&(I=I.filter(k=>k.items.data.some(R=>R.price&&typeof R.price=="object"&&x.includes(R.price.id))))}let T=await Promise.all(I.map(async x=>{let k={...x};if(p){if(typeof x.customer=="object"&&x.customer!==null&&!("deleted"in x.customer&&x.customer.deleted))k.customer=x.customer;else if(typeof x.customer=="string")try{let R=await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers/${x.customer}`,headers:{Authorization:"Bearer "+e.auth.secret_text}});k.customer=R.body}catch(R){console.warn(`Failed to fetch customer details for ${x.customer}:`,R)}}return k}));return{success:!0,count:T.length,total_fetched:l.length,requests_made:f,has_more_available:g&&!c,pagination_info:{limit_requested:c?"All":a,fetch_all_enabled:c,max_requests_limit:v},subscriptions:T,filters_applied:{price_ids:t?t.split(",").map(x=>x.trim()).filter(x=>x.length>0):null,status:o||null,customer_id:n||null,created_after:r||null,created_before:i||null,limit:a,fetch_all:c,include_customer_details:p}}}});var CA=ue({auth:_,name:"new_charge",classification:"READ",displayName:"New Charge",description:"Fires when a charge is successfully completed.",aiMetadata:{description:"Fires when a charge is successfully completed in Stripe (the charge.succeeded event), emitting the charge record. Use to react to a successful card charge; note this is the charge-level event, distinct from the New Payment trigger which fires on a succeeded payment intent."},props:{},outputSchema:Mo,sampleData:{id:"ch_3MmlLrLkdIwHu7ix0snN0B15",object:"charge",amount:1099,amount_captured:1099,amount_refunded:0,application:null,application_fee:null,application_fee_amount:null,balance_transaction:"txn_3MmlLrLkdIwHu7ix0uke3Ezy",billing_details:{address:{city:null,country:null,line1:null,line2:null,postal_code:null,state:null},email:"customer@example.com",name:"John Doe",phone:null},captured:!0,created:1679090539,currency:"usd",customer:"cus_ABC123",description:"My First Test Charge",disputed:!1,paid:!0,payment_intent:"pi_123",payment_method:"pm_123",receipt_url:"https://pay.stripe.com/receipts/...",refunded:!1,status:"succeeded"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("charge.succeeded",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_charge_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_charge_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/charges/search",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2026-02-25.clover"},queryParams:{query:'status:"succeeded"',limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var $A=ue({auth:_,name:"new_invoice",classification:"READ",displayName:"New Invoice",description:"Fires when an invoice is created. Supports filters like status, customer, subscription.",aiMetadata:{description:"Fires when an invoice is created in Stripe (the invoice.created event), emitting the new invoice. Optional filters narrow firing to a specific status, customer ID, or subscription ID. Use to react to newly issued invoices, for example to record or forward them."},props:{status:u.StaticDropdown({displayName:"Status",description:"Only trigger for invoices with this status.",required:!1,options:{options:[{label:"Draft",value:"draft"},{label:"Open",value:"open"},{label:"Paid",value:"paid"},{label:"Uncollectible",value:"uncollectible"},{label:"Void",value:"void"}]}}),customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for invoices belonging to this customer ID (e.g., `cus_...`).",required:!1}),subscription:u.ShortText({displayName:"Subscription ID",description:"Only trigger for invoices belonging to this subscription ID (e.g., `sub_...`).",required:!1})},outputSchema:Ie,sampleData:{id:"in_1MtHbELkdIwHu7ixl4OzzPMv",object:"invoice",customer:"cus_NeZwdNtLEOXuvB",subscription:"sub_12345ABC",status:"paid",amount_due:999,amount_paid:999,amount_remaining:0,billing_reason:"subscription_cycle",collection_method:"charge_automatically",created:1680644467,currency:"usd",customer_email:"jennyrosen@example.com",customer_name:"Jenny Rosen",hosted_invoice_url:"https://invoice.stripe.com/i/acct_...",invoice_pdf:"https://pay.stripe.com/invoice/acct_.../pdf",livemode:!1,number:"ABC-123-456"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("invoice.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_invoice_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_invoice_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{status:n,customer:r,subscription:i}=e.propsValue;return n&&o.status!==n?[]:r&&o.customer!==r?[]:i&&o.subscription!==i?[]:[o]}});var NA=ue({auth:_,name:"invoice_payment_failed",classification:"READ",displayName:"Invoice Payment Failed",description:"Fires when a payment against an invoice fails.",aiMetadata:{description:"Fires when a payment against an invoice fails in Stripe (the invoice.payment_failed event), emitting the affected invoice including the finalization error. An optional customer ID filter narrows firing to one customer. Use to react to failed invoice payments, such as starting a dunning or retry flow."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for invoices belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:Ie,sampleData:{id:"in_1MtHbELkdIwHu7ixl4OzzPMv",object:"invoice",customer:"cus_NeZwdNtLEOXuvB",status:"open",amount_due:1500,amount_paid:0,amount_remaining:1500,attempt_count:1,attempted:!0,billing_reason:"subscription_cycle",collection_method:"charge_automatically",created:1680644467,currency:"usd",customer_email:"jennyrosen@example.com",customer_name:"Jenny Rosen",hosted_invoice_url:"https://invoice.stripe.com/i/acct_...",last_finalization_error:{code:"card_declined",doc_url:"https://stripe.com/docs/error-codes/card-declined",message:"Your card was declined.",param:"",payment_intent:{id:"pi_123",object:"payment_intent"},type:"card_error"},livemode:!1,next_payment_attempt:1681251667},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("invoice.payment_failed",e.webhookUrl,e.auth.secret_text);await e.store.put("_invoice_payment_failed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_invoice_payment_failed_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"open",limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&o.customer!==n?[]:[o]}});var DA=ue({auth:_,name:"canceled_subscription",classification:"READ",displayName:"Canceled Subscription",description:"Fires when a subscription is canceled.",aiMetadata:{description:"Fires when a subscription is canceled in Stripe (the customer.subscription.deleted event), emitting the canceled subscription including any cancellation details. An optional customer ID filter narrows firing to one customer. Use to react to churn, such as revoking access or sending a win-back flow."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for subscriptions belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:Ne,sampleData:{id:"sub_1MlPf9LkdIwHu7ixB6VIYRyX",object:"subscription",application:null,application_fee_percent:null,billing_cycle_anchor:1678768838,cancel_at_period_end:!1,canceled_at:1678768842,cancellation_details:{comment:"User requested cancellation via support.",feedback:"missing_features",reason:"cancellation_requested"},collection_method:"charge_automatically",created:1678768838,currency:"usd",customer:"cus_NWSaVkvdacCUi4",ended_at:1678768842,items:{object:"list",data:[{id:"si_NWSaWTp80M123q",object:"subscription_item",price:{id:"price_1MlPf7LkdIwHu7ixgcbP7cwE",object:"price",active:!0,currency:"usd",product:"prod_NWSaMgipulx8IQ",type:"recurring",unit_amount:1099},quantity:1}]},latest_invoice:"in_1MlPf9LkdIwHu7ixEo6hdgCw",livemode:!1,metadata:{},start_date:1678768838,status:"canceled"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("customer.subscription.deleted",e.webhookUrl,e.auth.secret_text);await e.store.put("_canceled_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_canceled_subscription_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"canceled",limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&o.customer!==n?[]:[o]}});var zA=ue({auth:_,name:"new_refund",classification:"READ",displayName:"New Refund",description:"Fires when a charge is refunded (full or partial).",aiMetadata:{description:"Fires when a refund is created in Stripe (the refund.created event), for a full or partial refund, emitting the refund record. Optional filters narrow firing to a specific charge ID or payment intent ID. Use to react to money returned to a customer, such as updating accounting or notifying them."},props:{charge:u.ShortText({displayName:"Charge ID",description:"Only trigger for refunds related to this Charge ID (e.g., `ch_...`).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Only trigger for refunds related to this Payment Intent ID (e.g., `pi_...`).",required:!1})},outputSchema:ir,sampleData:{id:"re_1Nispe2eZvKYlo2Cd31jOCgZ",object:"refund",amount:1e3,balance_transaction:"txn_1Nispe2eZvKYlo2CYezqFhEx",charge:"ch_1NirD82eZvKYlo2CIvbtLWuY",created:1692942318,currency:"usd",metadata:{},payment_intent:"pi_1GszsK2eZvKYlo2CfhZyoZLp",reason:"requested_by_customer",receipt_number:null,status:"succeeded"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("refund.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_refund_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_refund_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/refunds",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{charge:n,payment_intent:r}=e.propsValue;return n&&o.charge!==n?[]:r&&o.payment_intent!==r?[]:[o]}});var MA=ue({auth:_,name:"new_dispute",classification:"READ",displayName:"New Dispute",description:"Fires when a customer disputes a charge.",aiMetadata:{description:"Fires when a customer disputes a charge in Stripe (the charge.dispute.created event), emitting the dispute including its reason and evidence due date. Optional filters narrow firing to a specific charge ID or payment intent ID. Use to react to chargebacks, such as alerting a team or gathering evidence."},props:{charge:u.ShortText({displayName:"Charge ID",description:"Only trigger for disputes related to this Charge ID (e.g., `ch_...`).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Only trigger for disputes related to this Payment Intent ID (e.g., `pi_...`).",required:!1})},outputSchema:ar,sampleData:{id:"du_1MtJUT2eZvKYlo2CNaw2HvEv",object:"dispute",amount:1e3,balance_transactions:[],charge:"ch_1AZtxr2eZvKYlo2CJDX8whov",created:1680651737,currency:"usd",evidence_details:{due_by:1682294399,has_evidence:!1,past_due:!1,submission_count:0},is_charge_refundable:!0,livemode:!1,metadata:{},payment_intent:"pi_1AZtxr2eZvKYlo2CJDX8whov",reason:"general",status:"needs_response"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("charge.dispute.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_dispute_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_dispute_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/issuing/disputes",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"submitted",limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{charge:n,payment_intent:r}=e.propsValue;return n&&o.charge!==n?[]:r&&o.payment_intent!==r?[]:[o]}});var LA=ue({auth:_,name:"new_payment_link",classification:"READ",displayName:"New Payment Link",description:"Fires when a new Payment Link is created.",aiMetadata:{description:"Fires when a new payment link is created in Stripe (the payment_link.created event), emitting the new payment link including its shareable URL. Use to react to payment-link creation, such as distributing the URL or logging it."},props:{},outputSchema:st,sampleData:{id:"plink_1MoC3ULkdIwHu7ixZjtGpVl2",object:"payment_link",active:!0,after_completion:{hosted_confirmation:{custom_message:null},type:"hosted_confirmation"},allow_promotion_codes:!1,currency:"usd",customer_creation:"if_required",livemode:!1,metadata:{},payment_method_collection:"always",url:"https://buy.stripe.com/test_cN25nr0iZ7bUa7meUY"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("payment_link.created",e.webhookUrl,e.auth.secret_text);await e.store.put("_new_payment_link_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_new_payment_link_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/payment_links",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){return[e.payload.body.data.object]}});var UA=ue({auth:_,name:"updated_subscription",classification:"READ",displayName:"Updated Subscription",description:"Fires when an existing subscription is changed.",aiMetadata:{description:"Fires when an existing subscription is updated in Stripe (the customer.subscription.updated event), emitting the changed subscription. Optional filters narrow firing to a target new status or a specific customer ID. Use to react to plan changes, status transitions, or quantity updates."},props:{status:u.StaticDropdown({displayName:"New Status",description:"Only trigger when the subscription is updated to this status.",required:!1,options:{options:[{label:"Incomplete",value:"incomplete"},{label:"Incomplete - Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Canceled",value:"canceled"},{label:"Unpaid",value:"unpaid"},{label:"Paused",value:"paused"}]}}),customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for subscriptions belonging to this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:Ne,sampleData:{id:"sub_1MowQVLkdIwHu7ixeRlqHVzs",object:"subscription",application:null,application_fee_percent:null,automatic_tax:{enabled:!1},billing_cycle_anchor:1679609767,cancel_at_period_end:!1,canceled_at:null,collection_method:"charge_automatically",created:1679609767,currency:"usd",customer:"cus_Na6dX7aXxi11N4",items:{object:"list",data:[{id:"si_Na6dzxczY5fwHx",object:"subscription_item",price:{id:"price_1MowQULkdIwHu7ixraBm864M",object:"price",product:"prod_Na6dGcTsmU0I4R",unit_amount:2e3},quantity:1}]},latest_invoice:"in_1MowQWLkdIwHu7ixuzkSPfKd",livemode:!1,metadata:{plan:"premium"},start_date:1679609767,status:"active"},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("customer.subscription.updated",e.webhookUrl,e.auth.secret_text);await e.store.put("_updated_subscription_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_updated_subscription_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/subscriptions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"incomplete",limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{status:n,customer:r}=e.propsValue;return n&&o.status!==n?[]:r&&o.customer!==r?[]:[o]}});var qA=ue({auth:_,name:"checkout_session_completed",classification:"READ",displayName:"Checkout Session Completed",description:"Fires when a Stripe Checkout Session is successfully completed.",aiMetadata:{description:"Fires when a Stripe Checkout Session is successfully completed (the checkout.session.completed event), emitting the completed session including customer and payment details. An optional customer ID filter narrows firing to one customer. Use to react to a completed hosted checkout, such as fulfilling an order or granting access."},props:{customer:u.ShortText({displayName:"Customer ID",description:"Only trigger for checkout sessions created by this customer ID (e.g., `cus_...`).",required:!1})},outputSchema:Uo,sampleData:{id:"cs_test_a11YYufWQzNY63zpQ6QSNRQhkUpVph4WRmzW0zWJO2znZKdVujZ0N0S22u",object:"checkout.session",amount_subtotal:2198,amount_total:2198,created:1679600215,currency:"usd",customer:"cus_NWSaVkvdacCUi4",customer_details:{email:"jenny.rosen@example.com",name:"Jenny Rosen",phone:null},livemode:!1,mode:"payment",payment_intent:"pi_12345ABC",payment_status:"paid",status:"complete",success_url:"https://example.com/success",url:null},type:"WEBHOOK",async onEnable(e){let t=await P.subscribeWebhook("checkout.session.completed",e.webhookUrl,e.auth.secret_text);await e.store.put("_checkout_session_completed_trigger",{webhookId:t.id})},async onDisable(e){let t=await e.store.get("_checkout_session_completed_trigger");t!=null&&await P.unsubscribeWebhook(t.webhookId,e.auth.secret_text)},async test(e){let t=await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/checkout/sessions",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},queryParams:{status:"complete",limit:"5"}});return K(t.body)||K(t.body.data)?[]:t.body.data},async run(e){let o=e.payload.body.data.object,{customer:n}=e.propsValue;return n&&o.customer!==n?[]:[o]}});var jA=E({name:"update_customer",classification:"WRITE",auth:_,displayName:"Update Customer",description:"Modify an existing customer\u2019s details.",audience:"human",aiMetadata:{description:"Updates fields on an existing Stripe customer (email, name, description, phone, address); only the fields you provide are changed. Use to correct or enrich a customer record identified by its customer ID. Idempotent in effect: repeating the same update yields the same final state.",idempotent:!0},props:{customer:P.customer,email:u.ShortText({displayName:"Email",required:!1}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Je,async run(e){let{customer:t,...o}=e.propsValue,n={};o.name&&(n.name=o.name),o.email&&(n.email=o.email),o.description&&(n.description=o.description),o.phone&&(n.phone=o.phone);let r={};return o.line1&&(r.line1=o.line1),o.city&&(r.city=o.city),o.state&&(r.state=o.state),o.postal_code&&(r.postal_code=o.postal_code),o.country&&(r.country=o.country),Object.keys(r).length>0&&(n.address=r),(await b.sendRequest({method:"POST",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var FA=E({name:"create_payment_intent",classification:"WRITE",auth:_,displayName:"Create Payment (Payment Intent)",description:"Creates a new payment intent to start a payment flow.",audience:"human",aiMetadata:{description:"Creates a Stripe PaymentIntent for a given amount and currency to begin collecting a payment, optionally tied to a customer. Can run in two modes: leave it unconfirmed to obtain a client secret for client-side completion, or set confirm to immediately charge a supplied payment method (which then also requires a return URL). Not idempotent: each call starts a separate payment.",idempotent:!1},props:{amount:u.Number({displayName:"Amount",description:"The amount to charge, in a decimal format (e.g., 10.50 for $10.50).",required:!0}),currency:u.StaticDropdown({displayName:"Currency",description:"The three-letter ISO code for the currency.",required:!0,options:{options:[{label:"US Dollar",value:"usd"},{label:"Euro",value:"eur"},{label:"Pound Sterling",value:"gbp"},{label:"Australian Dollar",value:"aud"},{label:"Canadian Dollar",value:"cad"},{label:"Swiss Franc",value:"chf"},{label:"Chinese Yuan",value:"cny"},{label:"Japanese Yen",value:"jpy"},{label:"Indian Rupee",value:"inr"},{label:"Singapore Dollar",value:"sgd"}]}}),customer:P.customer,payment_method:u.ShortText({displayName:"Payment Method ID",description:"The ID of the Payment Method to attach (e.g., `pm_...`). Required if you want to confirm the payment immediately.",required:!1}),confirm:u.Checkbox({displayName:"Confirm Payment Immediately",description:"If true, Stripe will attempt to charge the provided payment method. A `Payment Method ID` is required.",required:!1,defaultValue:!1}),return_url:u.ShortText({displayName:"Return URL",description:"The URL to redirect your customer back to after they authenticate their payment. Required when confirming the payment.",required:!1}),description:u.LongText({displayName:"Description",required:!1}),receipt_email:u.ShortText({displayName:"Receipt Email",description:"The email address to send a receipt to. This will override the customer's email address.",required:!1})},outputSchema:qe,async run(e){let{amount:t,currency:o,customer:n,payment_method:r,confirm:i,return_url:a,description:c,receipt_email:p}=e.propsValue;if(i&&!r)throw new Error("A Payment Method ID is required when 'Confirm Payment' is set to true.");if(i&&!a)throw new Error("A Return URL is required when 'Confirm Payment' is set to true.");let l={amount:Math.round(t*100),currency:o};return n&&(l.customer=n),r&&(l.payment_method=r),i&&(l.confirm=i),a&&(l.return_url=a),c&&(l.description=c),p&&(l.receipt_email=p),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var BA=E({name:"create_product",classification:"WRITE",auth:_,displayName:"Create Product",description:"Create a new product object in Stripe.",audience:"human",aiMetadata:{description:"Creates a new product object in Stripe (the catalog item that prices attach to), with optional description, images, URL, and metadata. Use before creating a price or when adding a sellable item. Not idempotent: each call creates a distinct product.",idempotent:!1},props:{name:u.ShortText({displayName:"Product Name",description:"The product\u2019s name, meant to be displayable to the customer.",required:!0}),description:u.LongText({displayName:"Description",description:"The product\u2019s description, meant to be displayable to the customer.",required:!1}),active:u.Checkbox({displayName:"Active",description:"Whether the product is currently available for purchase. Defaults to true.",required:!1}),images:u.Array({displayName:"Image URLs",description:"A list of up to 8 URLs of images for this product.",required:!1}),url:u.ShortText({displayName:"Product URL",description:"A publicly-accessible online page for this product.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the product.",required:!1})},outputSchema:or,async run(e){let{name:t,description:o,active:n,images:r,url:i,metadata:a}=e.propsValue,c={name:t};return o&&(c.description=o),n!==void 0&&(c.active=n),i&&(c.url=i),r&&Array.isArray(r)&&r.forEach((m,l)=>{c[`images[${l}]`]=m}),a&&typeof a=="object"&&Object.keys(a).forEach(m=>{c[`metadata[${m}]`]=a[m]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var ZA=E({name:"create_price",classification:"WRITE",auth:_,displayName:"Create Price",description:"Create a price (one-time or recurring), associated with a product.",audience:"human",aiMetadata:{description:"Creates a price for an existing Stripe product, in either one-time or recurring mode depending on the selected billing interval. Use after creating a product to define what to charge before building a subscription or payment link. Requires the product ID; not idempotent, as each call creates a new price.",idempotent:!1},props:{product:P.product,unit_amount:u.Number({displayName:"Unit Amount",description:"The price amount as a decimal, for example, 25.50 for $25.50.",required:!0}),currency:u.StaticDropdown({displayName:"Currency",description:"The three-letter ISO code for the currency.",required:!0,options:{options:[{label:"US Dollar",value:"usd"},{label:"Euro",value:"eur"},{label:"Pound Sterling",value:"gbp"},{label:"Indian Rupee",value:"inr"},{label:"Australian Dollar",value:"aud"},{label:"Canadian Dollar",value:"cad"},{label:"Swiss Franc",value:"chf"},{label:"Chinese Yuan",value:"cny"},{label:"Japanese Yen",value:"jpy"},{label:"Singapore Dollar",value:"sgd"}]}}),recurring_interval:u.StaticDropdown({displayName:"Billing Interval",description:"Specify the billing frequency. Select 'One-Time' for a single, non-recurring payment.",required:!0,defaultValue:"one_time",options:{options:[{label:"One-Time",value:"one_time"},{label:"Daily",value:"day"},{label:"Weekly",value:"week"},{label:"Monthly",value:"month"},{label:"Yearly",value:"year"}]}}),recurring_interval_count:u.Number({displayName:"Interval Count",description:"The number of intervals between subscription billings (e.g., for billing every 3 months, set Interval to Monthly and Interval Count to 3). Only used for recurring prices.",required:!1})},outputSchema:nr,async run(e){let{product:t,unit_amount:o,currency:n,recurring_interval:r,recurring_interval_count:i}=e.propsValue,a=Math.round(o*100),c={product:t,unit_amount:a,currency:n};return r!=="one_time"&&(c["recurring[interval]"]=r,i&&(c["recurring[interval_count]"]=i)),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var VA=E({name:"create_subscription",classification:"WRITE",auth:_,displayName:"Create Subscription",description:"Start a subscription for a customer with specified items/prices.",audience:"human",aiMetadata:{description:"Starts a recurring subscription for an existing customer against one or more price IDs, with optional collection method, trial period, and default payment method. Use to enroll a customer in recurring billing. Requires a customer ID and at least one price; not idempotent, as each call creates a separate subscription.",idempotent:!1},props:{customer:P.customer,items:u.Array({displayName:"Subscription Items",description:"A list of prices to subscribe the customer to.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The ID of the price object (e.g., price_...). You can find this in your Stripe Dashboard under Products.",required:!0}),quantity:u.Number({displayName:"Quantity",description:"The number of units of this price to subscribe to. Defaults to 1.",required:!1})}}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"How to collect payment. 'charge_automatically' will try to bill the default payment method. 'send_invoice' will email an invoice.",required:!1,options:{options:[{label:"Charge Automatically",value:"charge_automatically"},{label:"Send Invoice",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Number of days before an invoice is due. Required if Collection Method is 'Send Invoice'.",required:!1}),trial_period_days:u.Number({displayName:"Trial Period (Days)",description:"Integer representing the number of trial days the customer receives before the subscription bills for the first time.",required:!1}),default_payment_method:u.ShortText({displayName:"Default Payment Method ID",description:"ID of the default payment method for the subscription (e.g., `pm_...`).",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:Ne,async run(e){let{customer:t,items:o,collection_method:n,days_until_due:r,trial_period_days:i,default_payment_method:a,metadata:c}=e.propsValue,p={customer:t,collection_method:n,days_until_due:r,trial_period_days:i,default_payment_method:a,metadata:c};return Object.keys(p).forEach(l=>{(p[l]===void 0||p[l]===null)&&delete p[l]}),o&&Array.isArray(o)&&o.forEach((l,g)=>{let h=l;p[`items[${g}][price]`]=h.price,h.quantity&&(p[`items[${g}][quantity]`]=h.quantity)}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:p})).body}});var GA=E({name:"cancel_subscription",classification:"DESTRUCTIVE",auth:_,displayName:"Cancel Subscription",description:"Cancel an existing subscription, either immediately or at the end of the current billing period.",audience:"human",aiMetadata:{description:"Cancels an existing Stripe subscription by its ID, in one of two modes: immediately, or scheduled to end at the close of the current billing period. Use to stop recurring billing for a customer. Effectively idempotent: re-running on an already-canceled subscription leaves it canceled.",idempotent:!0},props:{subscription:P.subscription,cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",description:"If true, the subscription remains active until the end of the current billing period. If false, it cancels immediately.",required:!1,defaultValue:!1})},outputSchema:Ne,async run(e){let{subscription:t,cancel_at_period_end:o}=e.propsValue,n=Be(e.auth.secret_text);return o?await n.subscriptions.update(t,{cancel_at_period_end:!0}):await n.subscriptions.cancel(t)}});var HA=E({name:"retrieve_invoice",classification:"READ",auth:_,displayName:"Retrieve an Invoice",description:"Retrieves the details of an existing invoice by its ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe invoice by its invoice ID (e.g., in_...). Use when you have the exact invoice ID and need its current status, amounts, or hosted/PDF links. Read-only and idempotent.",idempotent:!0},props:{invoice_id:P.invoice},outputSchema:Ie,async run(e){let{invoice_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var WA=E({name:"retrieve_payout",classification:"READ",auth:_,displayName:"Retrieve a Payout",description:"Retrieves the details of an existing payout by its ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single Stripe payout (funds sent to your bank account) by its payout ID (e.g., po_...). Use to check a payout's status, amount, or arrival date. Read-only and idempotent.",idempotent:!0},props:{payout_id:P.payout},outputSchema:Mu,async run(e){let{payout_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payouts/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var KA=E({name:"create_refund",classification:"WRITE",auth:_,displayName:"Create a Refund",description:"Create a full or partial refund for a payment.",audience:"human",aiMetadata:{description:"Issues a refund against a payment identified by its PaymentIntent ID; refunds the full amount by default, or a partial amount if one is given, with an optional reason. Use to return funds to a customer for a captured payment. Not idempotent: each call creates a new refund and moves money again.",idempotent:!1},props:{payment_intent:P.paymentIntent,amount:u.Number({displayName:"Amount",description:"The amount to refund (e.g., 12.99). If left blank, a full refund will be issued.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",description:"An optional reason for the refund.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"}]}}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the refund.",required:!1})},outputSchema:ir,async run(e){let{payment_intent:t,amount:o,reason:n,metadata:r}=e.propsValue,i={payment_intent:t};return o!=null&&(i.amount=Math.round(o*100)),n&&(i.reason=n),r&&typeof r=="object"&&Object.keys(r).forEach(c=>{i[`metadata[${c}]`]=r[c]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var JA=E({name:"create_payment_link",classification:"WRITE",auth:_,displayName:"Create Payment Link",description:"Creates a shareable, Stripe-hosted payment link for one-time purchases or subscriptions.",audience:"human",aiMetadata:{description:"Creates a reusable, Stripe-hosted payment link for the given line items (price IDs and quantities), with optional after-completion redirect, promotion codes, and billing-address collection. Use to generate a shareable checkout URL without building a custom flow. Not idempotent: each call creates a new payment link.",idempotent:!1},props:{line_items:u.Array({displayName:"Line Items",description:"The products and quantities to include in the payment link.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The ID of the price object (e.g., price_1J2X3Y4Z...). Find this in your Stripe Dashboard under Products.",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),after_completion_type:u.StaticDropdown({displayName:"After Completion Behavior",description:"Controls the behavior after the purchase is complete. Defaults to showing Stripe's hosted confirmation page.",required:!1,options:{options:[{label:"Show Confirmation Page",value:"hosted_confirmation"},{label:"Redirect to URL",value:"redirect"}]}}),after_completion_redirect_url:u.ShortText({displayName:"Redirect URL",description:'The URL to redirect the customer to after a successful purchase. Only used if the behavior is set to "Redirect to URL".',required:!1}),allow_promotion_codes:u.Checkbox({displayName:"Allow Promotion Codes",description:"Enables the user to enter a promotion code on the Payment Link page.",required:!1}),billing_address_collection:u.StaticDropdown({displayName:"Billing Address Collection",description:"Describes whether Checkout should collect the customer\u2019s billing address.",required:!1,options:{options:[{label:"Auto",value:"auto"},{label:"Required",value:"required"}]}}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:st,async run(e){let t=Be(e.auth.secret_text),o=e.propsValue,n={line_items:o.line_items,allow_promotion_codes:o.allow_promotion_codes,billing_address_collection:o.billing_address_collection,metadata:o.metadata};return o.after_completion_type&&(n.after_completion={type:o.after_completion_type},o.after_completion_type==="redirect"&&o.after_completion_redirect_url&&(n.after_completion.redirect={url:o.after_completion_redirect_url})),await t.paymentLinks.create(n)}});var XA=E({name:"deactivate_payment_link",classification:"DESTRUCTIVE",auth:_,displayName:"Deactivate Payment Link",description:"Disable or deactivate a Payment Link so it can no longer be used.",audience:"human",aiMetadata:{description:"Deactivates an existing Stripe payment link by its ID so it can no longer accept payments. Use to retire a shared checkout URL. Idempotent in effect: re-running on an already-inactive link leaves it inactive.",idempotent:!0},props:{payment_link_id:P.paymentLink},outputSchema:st,async run(e){let{payment_link_id:t}=e.propsValue;return await Be(e.auth.secret_text).paymentLinks.update(t,{active:!1})}});var YA=E({name:"retrieve_payment_intent",classification:"READ",auth:_,displayName:"Find Payment (by Payment Intent ID)",description:"Retrieves the details of a payment by its unique Payment Intent ID.",audience:"human",aiMetadata:{description:"Fetches the full details of a single payment by its PaymentIntent ID (e.g., pi_...). Use when you have the exact ID and need the payment's current status, amount, or associated charge. Read-only and idempotent.",idempotent:!0},props:{payment_intent_id:P.paymentIntent},outputSchema:qe,async run(e){let{payment_intent_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_intents/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var QA=E({name:"find_invoice",classification:"READ",auth:_,displayName:"Find Invoice",description:"Finds an invoice by its unique ID.",audience:"human",aiMetadata:{description:"Fetches a single Stripe invoice by its unique invoice ID (e.g., in_...). Use when you already have the exact invoice ID and need its current details. Read-only and idempotent.",idempotent:!0},props:{invoice_id:P.invoice},outputSchema:Ie,async run(e){let{invoice_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var ek=E({name:"create_customer_ai",classification:"WRITE",auth:_,displayName:"Create Customer (Agent)",description:"Create a customer in Stripe.",audience:"ai",aiMetadata:{description:"Creates a new Stripe customer from an email and name, with optional phone and address. Use when onboarding a new payer before charging, invoicing, or subscribing them; to avoid duplicates, look the customer up first with Search Customers. Not idempotent: each call creates a distinct customer even with identical input.",idempotent:!1},props:{email:u.ShortText({displayName:"Email",required:!0}),name:u.ShortText({displayName:"Name",required:!0}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Je,async run(e){let{email:t,name:o,description:n,phone:r,line1:i,postal_code:a,city:c,state:p,country:m}=e.propsValue,l={email:t,name:o};n&&(l.description=n),r&&(l.phone=r);let g={};return i&&(g.line1=i),a&&(g.postal_code=a),c&&(g.city=c),p&&(g.state=p),m&&(g.country=m),Object.keys(g).forEach(f=>{l[`address[${f}]`]=g[f]}),(await b.sendRequest({method:"POST",url:"https://api.stripe.com/v1/customers",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:l})).body}});var tk=E({name:"get_customer",classification:"READ",auth:_,displayName:"Get Customer (Agent)",description:"Retrieve a Stripe customer by its ID.",audience:"ai",aiMetadata:{description:"Fetches the full details of a single Stripe customer by its customer ID (e.g., cus_...). Use when you already have the exact ID; to look a customer up by email use Search Customers, or List Customers to page through them. Read-only and idempotent.",idempotent:!0},props:{id:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0})},outputSchema:Je,async run(e){let t=e.propsValue.id;return(await b.sendRequest({method:"GET",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var rk=E({name:"update_customer_ai",classification:"WRITE",auth:_,displayName:"Update Customer (Agent)",description:"Modify an existing Stripe customer.",audience:"ai",aiMetadata:{description:"Updates fields on an existing Stripe customer (email, name, description, phone, address); only the fields you supply change. Use to correct or enrich a customer record identified by its customer ID. Idempotent: repeating the same update yields the same final state.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...) to update. Obtain it from Search Customers or List Customers.",required:!0}),email:u.ShortText({displayName:"Email",required:!1}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),phone:u.ShortText({displayName:"Phone",required:!1}),line1:u.ShortText({displayName:"Address Line 1",required:!1}),postal_code:u.ShortText({displayName:"Postal Code",required:!1}),city:u.ShortText({displayName:"City",required:!1}),state:u.ShortText({displayName:"State",required:!1}),country:u.ShortText({displayName:"Country",required:!1})},outputSchema:Je,async run(e){let{customer:t,...o}=e.propsValue,n={};o.name&&(n.name=o.name),o.email&&(n.email=o.email),o.description&&(n.description=o.description),o.phone&&(n.phone=o.phone);let r={};return o.line1&&(r.line1=o.line1),o.city&&(r.city=o.city),o.state&&(r.state=o.state),o.postal_code&&(r.postal_code=o.postal_code),o.country&&(r.country=o.country),Object.keys(r).forEach(a=>{n[`address[${a}]`]=r[a]}),(await b.sendRequest({method:"POST",url:`https://api.stripe.com/v1/customers/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var ok=E({name:"search_customers",classification:"SEARCH",auth:_,displayName:"Search Customers (Agent)",description:"Search for Stripe customers by email or a raw search query.",audience:"ai",aiMetadata:{description:`Searches Stripe customers using the Stripe Search Query Language. Pass an email to match customers with that exact email, or supply a raw query for richer filters (e.g. "name:'Jane' OR metadata['plan']:'gold'"). Use to find an existing customer before creating/charging one; use Get Customer when you already have the cus_ ID. Read-only and idempotent.`,idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:"Match customers with this exact email. Ignored if a raw Query is provided.",required:!1}),query:u.ShortText({displayName:"Query",description:"A raw Stripe search query (e.g. email:'a@b.com', name:'Jane'). Overrides the Email field when set.",required:!1})},outputSchema:Lu,async run(e){let{email:t,query:o}=e.propsValue,n=o||(t?`email:'${t}'`:void 0);if(!n)throw new Error("Provide either an Email or a raw Query to search.");let r={query:n};return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var nk=E({name:"create_payment_intent_ai",classification:"WRITE",auth:_,displayName:"Create Payment Intent (Agent)",description:"Create a Stripe PaymentIntent to start a payment flow.",audience:"ai",aiMetadata:{description:"Creates a Stripe PaymentIntent for an amount and currency, optionally tied to a customer. Leave it unconfirmed to get a client secret for client-side completion, or set confirm with a payment method ID (and return URL) to charge immediately. Amount is a decimal in the major currency unit (e.g. 10.50 for $10.50). Not idempotent: each call starts a separate payment.",idempotent:!1},props:{amount:u.Number({displayName:"Amount",description:"The amount to charge, as a decimal in the major currency unit (e.g., 10.50 for $10.50).",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd, eur, gbp).",required:!0}),customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...) to associate. Obtain it from Search Customers or List Customers.",required:!1}),payment_method:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID to attach (e.g., pm_...). Required to confirm the payment immediately.",required:!1}),confirm:u.Checkbox({displayName:"Confirm Payment Immediately",description:"If true, Stripe attempts to charge the provided payment method. Requires a Payment Method ID and a Return URL.",required:!1,defaultValue:!1}),capture_method:u.StaticDropdown({displayName:"Capture Method",description:"When to capture funds. 'automatic' (default) captures immediately on confirmation; 'manual' authorizes only \u2014 funds are held and you capture later with Capture Payment Intent (auth-and-capture).",required:!1,options:{options:[{label:"Automatic",value:"automatic"},{label:"Manual (authorize only)",value:"manual"}]}}),return_url:u.ShortText({displayName:"Return URL",description:"URL to redirect the customer back to after authenticating the payment. Required when confirming.",required:!1}),description:u.LongText({displayName:"Description",required:!1}),receipt_email:u.ShortText({displayName:"Receipt Email",description:"Email to send a receipt to. Overrides the customer's email.",required:!1})},outputSchema:qe,async run(e){let{amount:t,currency:o,customer:n,payment_method:r,confirm:i,return_url:a,description:c,receipt_email:p,capture_method:m}=e.propsValue;if(i&&!r)throw new Error("A Payment Method ID is required when 'Confirm Payment' is set to true.");if(i&&!a)throw new Error("A Return URL is required when 'Confirm Payment' is set to true.");let g={amount:Math.round(t*100),currency:o};return n&&(g.customer=n),r&&(g.payment_method=r),m&&(g.capture_method=m),i&&(g.confirm=i),a&&(g.return_url=a),c&&(g.description=c),p&&(g.receipt_email=p),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:g})).body}});var ik=E({name:"get_payment_intent",classification:"READ",auth:_,displayName:"Get Payment Intent (Agent)",description:"Retrieve a payment by its PaymentIntent ID.",audience:"ai",aiMetadata:{description:"Fetches a single payment by its PaymentIntent ID (e.g., pi_...). Use when you have the exact ID and need the current status, amount, or associated charge; use List/Search Payment Intents to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...). Obtain it from List Payment Intents or Search Payment Intents.",required:!0})},outputSchema:qe,async run(e){let{payment_intent_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_intents/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var ak=E({name:"create_refund_ai",classification:"WRITE",auth:_,displayName:"Create Refund (Agent)",description:"Create a full or partial refund for a payment.",audience:"ai",aiMetadata:{description:"Issues a refund against a payment identified by its PaymentIntent ID; refunds the full amount by default, or a partial amount if given, with an optional reason. Amount is in the major currency unit as a decimal. Use to return funds for a captured payment. Not idempotent: each call creates a new refund and moves money again.",idempotent:!1},props:{payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to refund. Obtain it from List/Search Payment Intents.",required:!0}),amount:u.Number({displayName:"Amount",description:"The amount to refund as a decimal (e.g., 12.99). If left blank, a full refund is issued.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",description:"An optional reason for the refund.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"}]}}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the refund.",required:!1})},outputSchema:ir,async run(e){let{payment_intent:t,amount:o,reason:n,metadata:r}=e.propsValue,i={payment_intent:t};return o!=null&&(i.amount=Math.round(o*100)),n&&(i.reason=n),r&&typeof r=="object"&&Object.keys(r).forEach(c=>{i[`metadata[${c}]`]=r[c]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var sk=E({name:"create_invoice_ai",classification:"WRITE",auth:_,displayName:"Create Invoice (Agent)",description:"Create a draft invoice in Stripe.",audience:"ai",aiMetadata:{description:"Creates a draft invoice for an existing customer in the given currency. Use to bill a customer for pending invoice items; add lines with Create Invoice Item / Add Invoice Lines, then Finalize Invoice and Send Invoice. Requires a valid customer ID. Not idempotent: each call creates a separate invoice.",idempotent:!1},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),description:u.LongText({displayName:"Description",description:"Description for the invoice.",required:!1}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"How to collect payment. 'charge_automatically' (default) charges the customer's default payment method when finalized; 'send_invoice' emails the customer a payable invoice (requires Days Until Due) and is the only method that lets you later call Send Invoice.",required:!1,options:{options:[{label:"Charge automatically",value:"charge_automatically"},{label:"Send invoice (email)",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Number of days until the invoice is due. Required when Collection Method is 'send_invoice'.",required:!1})},outputSchema:Ie,async run(e){let{customer_id:t,currency:o,description:n,collection_method:r,days_until_due:i}=e.propsValue;if(r==="send_invoice"&&i==null)throw new Error("days_until_due is required when collection_method is 'send_invoice'.");let a={customer:t,currency:o};return n&&(a.description=n),r&&(a.collection_method=r),r==="send_invoice"&&i!==void 0&&i!==null&&(a.days_until_due=i),(await b.sendRequest({method:"POST",url:"https://api.stripe.com/v1/invoices",headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"},body:a})).body}});var ck=E({name:"get_invoice",classification:"READ",auth:_,displayName:"Get Invoice (Agent)",description:"Retrieve a Stripe invoice by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe invoice by its invoice ID (e.g., in_...). Use when you have the exact ID and need its current status, amounts, lines, or hosted/PDF links; use List/Search Invoices to discover IDs. Read-only and idempotent.",idempotent:!0},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The Stripe invoice ID (e.g., in_...). Obtain it from List Invoices or Search Invoices.",required:!0})},outputSchema:Ie,async run(e){let{invoice_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var uk=E({name:"create_product_ai",classification:"WRITE",auth:_,displayName:"Create Product (Agent)",description:"Create a new product object in Stripe.",audience:"ai",aiMetadata:{description:"Creates a new Stripe product (the catalog item that prices attach to), with optional description, images, URL, and metadata. Use before creating a price or when adding a sellable item; to archive a product use Update Product with active=false. Not idempotent: each call creates a distinct product.",idempotent:!1},props:{name:u.ShortText({displayName:"Product Name",description:"The product name, displayable to the customer.",required:!0}),description:u.LongText({displayName:"Description",description:"The product description, displayable to the customer.",required:!1}),active:u.Checkbox({displayName:"Active",description:"Whether the product is currently available for purchase. Defaults to true.",required:!1}),images:u.Array({displayName:"Image URLs",description:"A list of up to 8 URLs of images for this product.",required:!1}),url:u.ShortText({displayName:"Product URL",description:"A publicly-accessible online page for this product.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to store additional information about the product.",required:!1})},outputSchema:or,async run(e){let{name:t,description:o,active:n,images:r,url:i,metadata:a}=e.propsValue,c={name:t};return o&&(c.description=o),n!==void 0&&(c.active=n),i&&(c.url=i),r&&Array.isArray(r)&&r.forEach((m,l)=>{c[`images[${l}]`]=m}),a&&typeof a=="object"&&Object.keys(a).forEach(m=>{c[`metadata[${m}]`]=a[m]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var pk=E({name:"create_price_ai",classification:"WRITE",auth:_,displayName:"Create Price (Agent)",description:"Create a one-time or recurring price for a product.",audience:"ai",aiMetadata:{description:"Creates a price for an existing Stripe product, one-time or recurring depending on the chosen billing interval. Amount is a decimal in the major currency unit. Use after Create Product to define what to charge before building a subscription or payment link. Requires the product ID. Not idempotent: each call creates a new price.",idempotent:!1},props:{product:u.ShortText({displayName:"Product ID",description:"The Stripe product ID (e.g., prod_...) this price attaches to. Obtain it from List/Search Products or Create Product.",required:!0}),unit_amount:u.Number({displayName:"Unit Amount",description:"The price amount as a decimal (e.g., 25.50 for $25.50).",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),recurring_interval:u.StaticDropdown({displayName:"Billing Interval",description:"Billing frequency. Select 'One-Time' for a single, non-recurring payment.",required:!0,defaultValue:"one_time",options:{options:[{label:"One-Time",value:"one_time"},{label:"Daily",value:"day"},{label:"Weekly",value:"week"},{label:"Monthly",value:"month"},{label:"Yearly",value:"year"}]}}),recurring_interval_count:u.Number({displayName:"Interval Count",description:"Number of intervals between billings (e.g., Monthly + count 3 = every 3 months). Only used for recurring prices.",required:!1})},outputSchema:nr,async run(e){let{product:t,unit_amount:o,currency:n,recurring_interval:r,recurring_interval_count:i}=e.propsValue,a=Math.round(o*100),c={product:t,unit_amount:a,currency:n};return r!=="one_time"&&(c["recurring[interval]"]=r,i&&(c["recurring[interval_count]"]=i)),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var lk=E({name:"create_subscription_ai",classification:"WRITE",auth:_,displayName:"Create Subscription (Agent)",description:"Start a subscription for a customer with specified prices.",audience:"ai",aiMetadata:{description:"Starts a recurring subscription for an existing customer against one or more price IDs, with optional collection method, trial period, and default payment method. Use to enroll a customer in recurring billing. Requires a customer ID and at least one price. Not idempotent: each call creates a separate subscription.",idempotent:!1},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search Customers or List Customers.",required:!0}),items:u.Array({displayName:"Subscription Items",description:"A list of prices to subscribe the customer to.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),quantity:u.Number({displayName:"Quantity",description:"Number of units of this price. Defaults to 1.",required:!1})}}),collection_method:u.StaticDropdown({displayName:"Collection Method",description:"'charge_automatically' bills the default payment method; 'send_invoice' emails an invoice.",required:!1,options:{options:[{label:"Charge Automatically",value:"charge_automatically"},{label:"Send Invoice",value:"send_invoice"}]}}),days_until_due:u.Number({displayName:"Days Until Due",description:"Days before an invoice is due. Required if Collection Method is 'Send Invoice'.",required:!1}),trial_period_days:u.Number({displayName:"Trial Period (Days)",description:"Number of trial days before the subscription bills for the first time.",required:!1}),default_payment_method:u.ShortText({displayName:"Default Payment Method ID",description:"ID of the default payment method (e.g., pm_...).",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:Ne,async run(e){let{customer:t,items:o,collection_method:n,days_until_due:r,trial_period_days:i,default_payment_method:a,metadata:c}=e.propsValue;if(n==="send_invoice"&&r==null)throw new Error("days_until_due is required when collection_method is 'send_invoice'.");let p={customer:t,collection_method:n,days_until_due:r,trial_period_days:i,default_payment_method:a};return Object.keys(p).forEach(l=>{(p[l]===void 0||p[l]===null)&&delete p[l]}),n!=="send_invoice"&&delete p.days_until_due,o&&Array.isArray(o)&&o.forEach((l,g)=>{let h=l;p[`items[${g}][price]`]=h.price,h.quantity&&(p[`items[${g}][quantity]`]=h.quantity)}),c&&typeof c=="object"&&Object.keys(c).forEach(l=>{p[`metadata[${l}]`]=c[l]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:p})).body}});var dk=E({name:"cancel_subscription_ai",classification:"DESTRUCTIVE",auth:_,displayName:"Cancel Subscription (Agent)",description:"Cancel a subscription immediately or at the end of the billing period.",audience:"ai",aiMetadata:{description:"Cancels an existing Stripe subscription by its ID, either immediately or scheduled to end at the close of the current billing period (via Cancel at Period End). Use to stop recurring billing. Idempotent: re-running on an already-canceled subscription leaves it canceled.",idempotent:!0},props:{subscription:u.ShortText({displayName:"Subscription ID",description:"The Stripe subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",description:"If true, the subscription stays active until the end of the current billing period. If false, it cancels immediately.",required:!1,defaultValue:!1})},outputSchema:Ne,async run(e){let{subscription:t,cancel_at_period_end:o}=e.propsValue,n=Be(e.auth.secret_text);return o?await n.subscriptions.update(t,{cancel_at_period_end:!0}):await n.subscriptions.cancel(t)}});var t1=[{label:"All Statuses",value:""},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}],mk=E({name:"search_subscriptions_ai",classification:"SEARCH",auth:_,displayName:"Search Subscriptions (Agent)",description:"Search subscriptions by price ID, status, customer ID and other filters.",audience:"ai",aiMetadata:{description:"Lists and filters Stripe subscriptions by price ID, status, customer ID, and creation date range, optionally expanding full customer details. Use to find subscriptions matching criteria or audit a customer's subscriptions; use Get Subscription when you already have the sub_ ID. Read-only and idempotent.",idempotent:!0},props:{price_ids:u.LongText({displayName:"Price IDs",description:"Comma-separated list of price IDs to filter by (e.g., price_1ABC123, price_2DEF456)",required:!1}),status:u.StaticDropdown({displayName:"Subscription Status",description:"Filter by subscription status",required:!1,options:{options:t1}}),customer_id:u.ShortText({displayName:"Customer ID",description:"Filter by specific customer ID (optional)",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Filter subscriptions created after this date (YYYY-MM-DD format)",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Filter subscriptions created before this date (YYYY-MM-DD format)",required:!1}),limit:u.Number({displayName:"Limit",description:"Maximum number of subscriptions to return (default: 100, set to 0 for all)",required:!1,defaultValue:100}),fetch_all:u.Checkbox({displayName:"Fetch All Results",description:"Fetch all matching subscriptions (ignores limit, may take longer for large datasets)",required:!1,defaultValue:!1}),include_customer_details:u.Checkbox({displayName:"Include Customer Details",description:"Fetch detailed customer information for each subscription",required:!1,defaultValue:!0})},outputSchema:Uu,async run(e){let{price_ids:t,status:o,customer_id:n,created_after:r,created_before:i,limit:a=100,fetch_all:c=!1,include_customer_details:p=!0}=e.propsValue,m=s(x=>{let k=new URLSearchParams;if(k.append("limit","100"),k.append("expand[]","data.items.data.price"),p&&k.append("expand[]","data.customer"),o&&k.append("status",o),n&&k.append("customer",n),r){let R=Math.floor(new Date(r).getTime()/1e3);k.append("created[gte]",R.toString())}if(i){let R=Math.floor(new Date(i).getTime()/1e3);k.append("created[lte]",R.toString())}return x&&k.append("starting_after",x),k},"buildQueryParams"),l=[],g=!0,h,f=0,v=c?50:Math.ceil(a/100);for(;g&&f<v;){let x=m(h),k=await b.sendRequest({method:"GET",url:`${P.baseUrl}/subscriptions?${x.toString()}`,headers:{Authorization:"Bearer "+e.auth.secret_text,"Content-Type":"application/x-www-form-urlencoded"}});if(!k.body)throw new Error("Failed to fetch subscriptions from Stripe");let R=k.body.data;if(l=l.concat(R),g=k.body.has_more,f++,g&&R.length>0&&(h=R[R.length-1].id),!c&&l.length>=a){l=l.slice(0,a);break}}let I=l;if(t&&t.trim()){let x=t.split(",").map(k=>k.trim()).filter(k=>k.length>0);x.length>0&&(I=I.filter(k=>k.items.data.some(R=>R.price&&typeof R.price=="object"&&x.includes(R.price.id))))}let T=await Promise.all(I.map(async x=>{let k={...x};if(p){if(typeof x.customer=="object"&&x.customer!==null&&!("deleted"in x.customer&&x.customer.deleted))k.customer=x.customer;else if(typeof x.customer=="string")try{let R=await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers/${x.customer}`,headers:{Authorization:"Bearer "+e.auth.secret_text}});k.customer=R.body}catch(R){console.warn(`Failed to fetch customer details for ${x.customer}:`,R)}}return k}));return{success:!0,count:T.length,total_fetched:l.length,requests_made:f,has_more_available:g&&!c,pagination_info:{limit_requested:c?"All":a,fetch_all_enabled:c,max_requests_limit:v},subscriptions:T,filters_applied:{price_ids:t?t.split(",").map(x=>x.trim()).filter(x=>x.length>0):null,status:o||null,customer_id:n||null,created_after:r||null,created_before:i||null,limit:a,fetch_all:c,include_customer_details:p}}}});var fk=E({name:"create_payment_link_ai",classification:"WRITE",auth:_,displayName:"Create Payment Link (Agent)",description:"Create a shareable, Stripe-hosted payment link.",audience:"ai",aiMetadata:{description:"Creates a reusable, Stripe-hosted payment link for the given line items (price IDs and quantities), with optional after-completion redirect, promotion codes, and billing-address collection. Use to generate a shareable checkout URL without building a custom flow; for a richer one-off hosted page use Create Checkout Session. Not idempotent: each call creates a new payment link.",idempotent:!1},props:{line_items:u.Array({displayName:"Line Items",description:"The products and quantities to include in the payment link.",required:!0,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),after_completion_type:u.StaticDropdown({displayName:"After Completion Behavior",description:"Behavior after purchase completes. Defaults to Stripe's hosted confirmation page.",required:!1,options:{options:[{label:"Show Confirmation Page",value:"hosted_confirmation"},{label:"Redirect to URL",value:"redirect"}]}}),after_completion_redirect_url:u.ShortText({displayName:"Redirect URL",description:'URL to redirect to after a successful purchase. Only used when behavior is "Redirect to URL".',required:!1}),allow_promotion_codes:u.Checkbox({displayName:"Allow Promotion Codes",description:"Allow the customer to enter a promotion code.",required:!1}),billing_address_collection:u.StaticDropdown({displayName:"Billing Address Collection",description:"Whether Checkout collects the customer's billing address.",required:!1,options:{options:[{label:"Auto",value:"auto"},{label:"Required",value:"required"}]}}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:st,async run(e){let t=Be(e.auth.secret_text),o=e.propsValue,n={line_items:o.line_items,allow_promotion_codes:o.allow_promotion_codes,billing_address_collection:o.billing_address_collection,metadata:o.metadata};return o.after_completion_type&&(n.after_completion={type:o.after_completion_type},o.after_completion_type==="redirect"&&o.after_completion_redirect_url&&(n.after_completion.redirect={url:o.after_completion_redirect_url})),await t.paymentLinks.create(n)}});var hk=E({name:"deactivate_payment_link_ai",classification:"DESTRUCTIVE",auth:_,displayName:"Deactivate Payment Link (Agent)",description:"Deactivate a payment link so it can no longer be used.",audience:"ai",aiMetadata:{description:"Deactivates an existing Stripe payment link by its ID so it can no longer accept payments (sets active=false). Use to retire a shared checkout URL; use Get/List Payment Links to find the ID. Idempotent: re-running on an already-inactive link leaves it inactive.",idempotent:!0},props:{payment_link_id:u.ShortText({displayName:"Payment Link ID",description:"The payment link ID (e.g., plink_...). Obtain it from List Payment Links.",required:!0})},outputSchema:st,async run(e){let{payment_link_id:t}=e.propsValue;return await Be(e.auth.secret_text).paymentLinks.update(t,{active:!1})}});var yk=E({name:"get_payout",classification:"READ",auth:_,displayName:"Get Payout (Agent)",description:"Retrieve a Stripe payout by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe payout (funds sent to your bank account) by its payout ID (e.g., po_...). Use to check a payout's status, amount, or arrival date; use List Payouts to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payout_id:u.ShortText({displayName:"Payout ID",description:"The Stripe payout ID (e.g., po_...). Obtain it from List Payouts.",required:!0})},outputSchema:Mu,async run(e){let{payout_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payouts/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var gk=E({name:"list_customers",classification:"SEARCH",auth:_,displayName:"List Customers (Agent)",description:"List Stripe customers, optionally filtered by email.",audience:"ai",aiMetadata:{description:"Pages through Stripe customers, newest first, optionally filtered by an exact email. Use to enumerate customers or resolve a customer ID; for query-language matching use Search Customers, or Get Customer when you have the cus_ ID. Read-only and idempotent.",idempotent:!0},props:{email:u.ShortText({displayName:"Email",description:"Filter to customers with this exact email.",required:!1}),limit:u.Number({displayName:"Limit",description:"Number of customers to return (1-100, default 10).",required:!1}),starting_after:u.ShortText({displayName:"Starting After",description:"A customer ID; returns the page of results after this cursor for pagination.",required:!1})},outputSchema:Ux,async run(e){let{email:t,limit:o,starting_after:n}=e.propsValue,r={};return t&&(r.email=t),o&&(r.limit=o.toString()),n&&(r.starting_after=n),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var vk=E({name:"confirm_payment_intent",classification:"WRITE",auth:_,displayName:"Confirm Payment Intent (Agent)",description:"Confirm a PaymentIntent to attempt the charge.",audience:"ai",aiMetadata:{description:"Confirms a previously-created PaymentIntent to attempt collecting the payment, optionally supplying a payment method and return URL. Use when a PaymentIntent was created unconfirmed and you now want to charge it; Create Payment Intent can also confirm inline. Money-moving and not idempotent.",idempotent:!1},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to confirm. Obtain it from List/Search Payment Intents.",required:!0}),payment_method:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID to use (e.g., pm_...).",required:!1}),return_url:u.ShortText({displayName:"Return URL",description:"URL to redirect to after authentication. Required for redirect-based payment methods.",required:!1})},outputSchema:qe,async run(e){let{payment_intent_id:t,payment_method:o,return_url:n}=e.propsValue,r={};return o&&(r.payment_method=o),n&&(r.return_url=n),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_intents/${t}/confirm`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:r})).body}});var _k=E({name:"cancel_payment_intent",classification:"DESTRUCTIVE",auth:_,displayName:"Cancel Payment Intent (Agent)",description:"Cancel a PaymentIntent that has not been captured.",audience:"ai",aiMetadata:{description:"Cancels a PaymentIntent that has not yet been captured (e.g., a manual-capture authorization or an abandoned payment), with an optional cancellation reason. Use to release an authorization or abandon a payment. Idempotent: re-running on an already-canceled PaymentIntent leaves it canceled.",idempotent:!0},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to cancel. Obtain it from List/Search Payment Intents.",required:!0}),cancellation_reason:u.StaticDropdown({displayName:"Cancellation Reason",description:"An optional reason for the cancellation.",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Requested by Customer",value:"requested_by_customer"},{label:"Abandoned",value:"abandoned"}]}})},outputSchema:qe,async run(e){let{payment_intent_id:t,cancellation_reason:o}=e.propsValue,n={};return o&&(n.cancellation_reason=o),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_intents/${t}/cancel`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var bk=E({name:"capture_payment_intent",classification:"WRITE",auth:_,displayName:"Capture Payment Intent (Agent)",description:"Capture funds from an authorized PaymentIntent.",audience:"ai",aiMetadata:{description:"Captures the funds of a PaymentIntent that was authorized with manual capture (status requires_capture). Optionally capture a partial amount (in the smallest currency unit, e.g. cents) and mark it as the final capture. Use to settle a held authorization. Money-moving and not idempotent.",idempotent:!1},props:{payment_intent_id:u.ShortText({displayName:"Payment Intent ID",description:"The PaymentIntent ID (e.g., pi_...) to capture. Obtain it from List/Search Payment Intents.",required:!0}),amount_to_capture:u.Number({displayName:"Amount to Capture",description:"The amount to capture in the smallest currency unit (e.g., 1050 for $10.50). Defaults to the full authorized amount.",required:!1}),final_capture:u.Checkbox({displayName:"Final Capture",description:"If true, the remaining uncaptured amount is released back to the customer.",required:!1}),metadata:u.Json({displayName:"Metadata",description:"A set of key-value pairs to attach.",required:!1})},outputSchema:qe,async run(e){let{payment_intent_id:t,amount_to_capture:o,final_capture:n,metadata:r}=e.propsValue,i={};return o!=null&&(i.amount_to_capture=o),n!==void 0&&(i.final_capture=n),r&&typeof r=="object"&&Object.keys(r).forEach(c=>{i[`metadata[${c}]`]=r[c]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_intents/${t}/capture`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Pk=E({name:"list_payment_intents",classification:"SEARCH",auth:_,displayName:"List Payment Intents (Agent)",description:"List Stripe PaymentIntents.",audience:"ai",aiMetadata:{description:"Pages through PaymentIntents, newest first, optionally filtered by customer or a created timestamp range. Use to enumerate payments or resolve a PaymentIntent ID; for query-language matching use Search Payment Intents, or Get Payment Intent when you have the pi_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to PaymentIntents for this customer (cus_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",description:"Only return PaymentIntents created at or after this time.",required:!1}),created_before:u.DateTime({displayName:"Created Before",description:"Only return PaymentIntents created at or before this time.",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1}),starting_after:u.ShortText({displayName:"Starting After",description:"A PaymentIntent ID cursor for pagination.",required:!1})},outputSchema:Gx,async run(e){let{customer:t,created_after:o,created_before:n,limit:r,starting_after:i}=e.propsValue,a={};return t&&(a.customer=t),r&&(a.limit=r.toString()),i&&(a.starting_after=i),o&&(a["created[gte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),n&&(a["created[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_intents`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:a})).body}});var xk=E({name:"search_payment_intents",classification:"SEARCH",auth:_,displayName:"Search Payment Intents (Agent)",description:"Search PaymentIntents with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches PaymentIntents using the Stripe Search Query Language (e.g. "status:'succeeded' AND customer:'cus_...'"). Use for ad-hoc filtered lookups; use List Payment Intents for simple paging or Get Payment Intent when you have the pi_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. status:'succeeded' AND amount>1000).",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:uS,async run(e){let{query:t,limit:o}=e.propsValue,n={query:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_intents/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Sk=E({name:"retrieve_charge",classification:"READ",auth:_,displayName:"Retrieve Charge (Agent)",description:"Retrieve a Stripe charge by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe charge by its charge ID (e.g., ch_...). Charges are the legacy, read-mostly view of a payment; for the modern object use Get Payment Intent. Use List/Search Charges to discover IDs. Read-only and idempotent.",idempotent:!0},props:{charge_id:u.ShortText({displayName:"Charge ID",description:"The Stripe charge ID (e.g., ch_...). Obtain it from List Charges or Search Charges.",required:!0})},outputSchema:Mo,async run(e){let{charge_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/charges/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Tk=E({name:"list_charges",classification:"SEARCH",auth:_,displayName:"List Charges (Agent)",description:"List Stripe charges.",audience:"ai",aiMetadata:{description:"Pages through charges, newest first, optionally filtered by customer, PaymentIntent, or a created timestamp range. Use to enumerate charges or resolve a charge ID; for query-language matching use Search Charges. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to charges for this customer (cus_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to charges for this PaymentIntent (pi_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Hx,async run(e){let{customer:t,payment_intent:o,created_after:n,created_before:r,limit:i}=e.propsValue,a={};return t&&(a.customer=t),o&&(a.payment_intent=o),i&&(a.limit=i.toString()),n&&(a["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),r&&(a["created[lte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/charges`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:a})).body}});var Ek=E({name:"search_charges",classification:"SEARCH",auth:_,displayName:"Search Charges (Agent)",description:"Search charges with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches charges using the Stripe Search Query Language (e.g. "status:'succeeded' AND amount>1000"). Use for ad-hoc filtered lookups; use List Charges for simple paging or Retrieve Charge when you have the ch_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. metadata['order_id']:'6735').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:sS,async run(e){let{query:t,limit:o}=e.propsValue,n={query:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/charges/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Ik=E({name:"get_refund",classification:"READ",auth:_,displayName:"Get Refund (Agent)",description:"Retrieve a Stripe refund by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe refund by its refund ID (e.g., re_...) to check its status and amount. Use List Refunds to discover IDs. Read-only and idempotent.",idempotent:!0},props:{refund_id:u.ShortText({displayName:"Refund ID",description:"The Stripe refund ID (e.g., re_...). Obtain it from List Refunds.",required:!0})},outputSchema:ir,async run(e){let{refund_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/refunds/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Ak=E({name:"list_refunds",classification:"SEARCH",auth:_,displayName:"List Refunds (Agent)",description:"List Stripe refunds.",audience:"ai",aiMetadata:{description:"Pages through refunds, newest first, optionally filtered by PaymentIntent or charge. Use to enumerate refunds for a payment or resolve a refund ID; use Get Refund when you have the re_ ID. Read-only and idempotent.",idempotent:!0},props:{payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to refunds for this PaymentIntent (pi_...).",required:!1}),charge:u.ShortText({displayName:"Charge ID",description:"Filter to refunds for this charge (ch_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Wx,async run(e){let{payment_intent:t,charge:o,limit:n}=e.propsValue,r={};return t&&(r.payment_intent=t),o&&(r.charge=o),n&&(r.limit=n.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/refunds`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var kk=E({name:"list_invoices",classification:"SEARCH",auth:_,displayName:"List Invoices (Agent)",description:"List Stripe invoices.",audience:"ai",aiMetadata:{description:"Pages through invoices, newest first, optionally filtered by customer, status, or subscription. Use to enumerate invoices or resolve an invoice ID; for query-language matching use Search Invoices, or Get Invoice when you have the in_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to invoices for this customer (cus_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",description:"Filter by invoice status.",required:!1,options:{options:[{label:"Draft",value:"draft"},{label:"Open",value:"open"},{label:"Paid",value:"paid"},{label:"Uncollectible",value:"uncollectible"},{label:"Void",value:"void"}]}}),subscription:u.ShortText({displayName:"Subscription ID",description:"Filter to invoices for this subscription (sub_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Kx,async run(e){let{customer:t,status:o,subscription:n,limit:r}=e.propsValue,i={};return t&&(i.customer=t),o&&(i.status=o),n&&(i.subscription=n),r&&(i.limit=r.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var wk=E({name:"search_invoices",classification:"SEARCH",auth:_,displayName:"Search Invoices (Agent)",description:"Search invoices with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches invoices using the Stripe Search Query Language (e.g. "status:'open' AND customer:'cus_...'"). Use for ad-hoc filtered lookups; use List Invoices for simple paging or Get Invoice when you have the in_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. total>1000 AND status:'paid').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:cS,async run(e){let{query:t,limit:o}=e.propsValue,n={query:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Ok=E({name:"finalize_invoice",classification:"WRITE",auth:_,displayName:"Finalize Invoice (Agent)",description:"Finalize a draft invoice so it becomes payable.",audience:"ai",aiMetadata:{description:"Finalizes a draft Stripe invoice, locking its line items and making it payable. Use after adding all line items and before Send Invoice. Not idempotent: it errors if the invoice is already finalized.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The draft invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),auto_advance:u.Checkbox({displayName:"Auto Advance",description:"If true, Stripe automatically collects the invoice (sends/charges per its settings) after finalizing.",required:!1})},outputSchema:Ie,async run(e){let{invoice_id:t,auto_advance:o}=e.propsValue,n={};return o!==void 0&&(n.auto_advance=o),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/invoices/${t}/finalize`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var Rk=E({name:"send_invoice",classification:"WRITE",auth:_,displayName:"Send Invoice (Agent)",description:"Email a finalized invoice to the customer.",audience:"ai",aiMetadata:{description:"Emails a finalized Stripe invoice to the customer. The invoice must already be finalized (use Finalize Invoice first). Not idempotent: each call sends the invoice email again.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The finalized invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0})},outputSchema:Ie,async run(e){let{invoice_id:t}=e.propsValue;return(await b.sendRequest({method:"POST",url:`${P.baseUrl}/invoices/${t}/send`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var Ck=E({name:"add_invoice_lines",classification:"WRITE",auth:_,displayName:"Add Invoice Lines (Agent)",description:"Bulk-add line items to a draft invoice.",audience:"ai",aiMetadata:{description:"Adds one or more line items to a draft Stripe invoice in a single call. Each line supplies either a price ID or an ad-hoc amount (smallest currency unit) plus currency, with an optional description and quantity. Use to populate a draft before Finalize Invoice. Not idempotent: each call appends new lines.",idempotent:!1},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The draft invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),lines:u.Array({displayName:"Lines",description:"The line items to add to the invoice.",required:!0,properties:{description:u.ShortText({displayName:"Description",required:!1}),amount:u.Number({displayName:"Amount",description:"Ad-hoc amount in the smallest currency unit (e.g., 1050 for $10.50), in the invoice's currency. Provide either an Amount or a Price ID (not both).",required:!1}),price:u.ShortText({displayName:"Price ID",description:"A price ID (e.g., price_...) instead of an ad-hoc amount.",required:!1}),quantity:u.Number({displayName:"Quantity",required:!1})}})},outputSchema:Ie,async run(e){let{invoice_id:t,lines:o}=e.propsValue;if(!o||!Array.isArray(o)||o.length===0)throw new Error("Provide at least one line item to add.");let n={};return o.forEach((i,a)=>{i.description!==void 0&&i.description!==null&&i.description!==""&&(n[`lines[${a}][description]`]=i.description),i.price?(n[`lines[${a}][pricing][price]`]=i.price,i.quantity!==void 0&&i.quantity!==null&&(n[`lines[${a}][quantity]`]=i.quantity)):i.amount!==void 0&&i.amount!==null&&(n[`lines[${a}][amount]`]=i.amount)}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/invoices/${t}/add_lines`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:n})).body}});var $k=E({name:"list_invoice_lines",classification:"SEARCH",auth:_,displayName:"List Invoice Lines (Agent)",description:"List the line items on an invoice.",audience:"ai",aiMetadata:{description:"Pages through the line items of a single Stripe invoice. Use when you need only the lines; the lines are also returned inline by Get Invoice. Read-only and idempotent.",idempotent:!0},props:{invoice_id:u.ShortText({displayName:"Invoice ID",description:"The invoice ID (e.g., in_...). Obtain it from List/Search Invoices.",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Jx,async run(e){let{invoice_id:t,limit:o}=e.propsValue,n={};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/invoices/${t}/lines`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Nk=E({name:"create_invoice_item",classification:"WRITE",auth:_,displayName:"Create Invoice Item (Agent)",description:"Add a one-off pending line item to a customer.",audience:"ai",aiMetadata:{description:"Creates a pending invoice item for a customer that attaches to their next invoice, or to a specific invoice if one is given. Amount is in the smallest currency unit (e.g. cents) \u2014 pass a raw integer, not a decimal. Use to add ad-hoc charges before invoicing. Not idempotent: each call creates a new item.",idempotent:!1},props:{customer:u.ShortText({displayName:"Customer ID",description:"The Stripe customer ID (e.g., cus_...). Obtain it from Search/List Customers.",required:!0}),amount:u.Number({displayName:"Amount",description:"The amount in the smallest currency unit (e.g., 1050 for $10.50). Raw integer, not a decimal.",required:!0}),currency:u.ShortText({displayName:"Currency",description:"The three-letter ISO currency code (e.g., usd).",required:!0}),description:u.LongText({displayName:"Description",required:!1}),invoice:u.ShortText({displayName:"Invoice ID",description:"Attach to this specific draft invoice (in_...) instead of the next upcoming one.",required:!1}),price:u.ShortText({displayName:"Price ID",description:"Use a price ID (price_...) instead of an ad-hoc amount. If set, leave Amount/Currency blank.",required:!1})},outputSchema:zx,async run(e){let{customer:t,amount:o,currency:n,description:r,invoice:i,price:a}=e.propsValue,c={customer:t};return a?c.price=a:(c.amount=o,c.currency=n),r&&(c.description=r),i&&(c.invoice=i),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/invoiceitems`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var Dk=E({name:"update_product",classification:"WRITE",auth:_,displayName:"Update Product (Agent)",description:"Update or archive a Stripe product.",audience:"ai",aiMetadata:{description:'Updates a Stripe product (rename, change description/metadata, or set active=false to archive it). Archiving is the agent path to "delete" a product, since products with prices cannot be hard-deleted. Only the fields you supply change. Idempotent: re-applying the same update converges.',idempotent:!0},props:{product_id:u.ShortText({displayName:"Product ID",description:"The product ID (e.g., prod_...). Obtain it from List/Search Products.",required:!0}),name:u.ShortText({displayName:"Name",required:!1}),description:u.LongText({displayName:"Description",required:!1}),active:u.Checkbox({displayName:"Active",description:"Set to false to archive the product.",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:or,async run(e){let{product_id:t,name:o,description:n,active:r,metadata:i}=e.propsValue,a={};return o&&(a.name=o),n&&(a.description=n),r!==void 0&&(a.active=r),i&&typeof i=="object"&&Object.keys(i).forEach(p=>{a[`metadata[${p}]`]=i[p]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/products/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:a})).body}});var zk=E({name:"get_product",classification:"READ",auth:_,displayName:"Get Product (Agent)",description:"Retrieve a Stripe product by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe product by its product ID (e.g., prod_...). Use List/Search Products to discover IDs. Read-only and idempotent.",idempotent:!0},props:{product_id:u.ShortText({displayName:"Product ID",description:"The product ID (e.g., prod_...). Obtain it from List/Search Products.",required:!0})},outputSchema:or,async run(e){let{product_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/products/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Mk=E({name:"list_products",classification:"SEARCH",auth:_,displayName:"List Products (Agent)",description:"List Stripe products.",audience:"ai",aiMetadata:{description:"Pages through products, newest first, optionally filtered by active status. Use to enumerate the catalog or resolve a product ID; for name matching use Search Products, or Get Product when you have the prod_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",description:"Filter by active state.",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:qx,async run(e){let{active:t,limit:o}=e.propsValue,n={};return t&&(n.active=t),o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/products`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Lk=E({name:"search_products",classification:"SEARCH",auth:_,displayName:"Search Products (Agent)",description:"Search products with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches products using the Stripe Search Query Language (e.g. "active:'true' AND name~'shirt'"). Use for name/metadata matching; use List Products for simple paging or Get Product when you have the prod_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. name~'shirt').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:lS,async run(e){let{query:t,limit:o}=e.propsValue,n={query:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/products/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Uk=E({name:"update_price",classification:"WRITE",auth:_,displayName:"Update Price (Agent)",description:"Update or archive a Stripe price.",audience:"ai",aiMetadata:{description:"Updates a Stripe price (set active=false to archive it, or edit its nickname/metadata). The unit amount is immutable \u2014 create a new price to change it. Only the fields you supply change. Idempotent: re-applying the same update converges.",idempotent:!0},props:{price_id:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0}),active:u.Checkbox({displayName:"Active",description:"Set to false to archive the price.",required:!1}),nickname:u.ShortText({displayName:"Nickname",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:nr,async run(e){let{price_id:t,active:o,nickname:n,metadata:r}=e.propsValue,i={};return o!==void 0&&(i.active=o),n&&(i.nickname=n),r&&typeof r=="object"&&Object.keys(r).forEach(c=>{i[`metadata[${c}]`]=r[c]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/prices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var qk=E({name:"get_price",classification:"READ",auth:_,displayName:"Get Price (Agent)",description:"Retrieve a Stripe price by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe price by its price ID (e.g., price_...). Use List/Search Prices to discover IDs. Read-only and idempotent.",idempotent:!0},props:{price_id:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...). Obtain it from List/Search Prices.",required:!0})},outputSchema:nr,async run(e){let{price_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/prices/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var jk=E({name:"list_prices",classification:"SEARCH",auth:_,displayName:"List Prices (Agent)",description:"List Stripe prices.",audience:"ai",aiMetadata:{description:"Pages through prices, newest first, optionally filtered by product, active state, type (one_time/recurring), or currency. Use to enumerate prices or resolve a price ID; for query matching use Search Prices, or Get Price when you have the price_ ID. Read-only and idempotent.",idempotent:!0},props:{product:u.ShortText({displayName:"Product ID",description:"Filter to prices for this product (prod_...).",required:!1}),active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),type:u.StaticDropdown({displayName:"Type",required:!1,options:{options:[{label:"One-time",value:"one_time"},{label:"Recurring",value:"recurring"}]}}),currency:u.ShortText({displayName:"Currency",description:"Three-letter ISO currency code (e.g., usd).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:jx,async run(e){let{product:t,active:o,type:n,currency:r,limit:i}=e.propsValue,a={};return t&&(a.product=t),o&&(a.active=o),n&&(a.type=n),r&&(a.currency=r),i&&(a.limit=i.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/prices`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:a})).body}});var Fk=E({name:"search_prices",classification:"SEARCH",auth:_,displayName:"Search Prices (Agent)",description:"Search prices with a Stripe search query.",audience:"ai",aiMetadata:{description:`Searches prices using the Stripe Search Query Language (e.g. "active:'true' AND currency:'usd'"). Use for metadata/attribute matching; use List Prices for simple paging or Get Price when you have the price_ ID. Read-only and idempotent.`,idempotent:!0},props:{query:u.ShortText({displayName:"Query",description:"A Stripe search query (e.g. lookup_key:'standard_monthly').",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:pS,async run(e){let{query:t,limit:o}=e.propsValue,n={query:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/prices/search`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Bk=E({name:"update_subscription",classification:"WRITE",auth:_,displayName:"Update Subscription (Agent)",description:"Update an existing Stripe subscription.",audience:"ai",aiMetadata:{description:"Updates an existing subscription: change its items (price + quantity), proration behavior, metadata, or schedule cancellation at period end. To cancel outright use Cancel Subscription. Only the fields you supply change. Idempotent: re-applying the same update converges.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),items:u.Array({displayName:"Items",description:"New/updated items. To modify an existing item include its subscription-item id; to add one supply a price.",required:!1,properties:{id:u.ShortText({displayName:"Subscription Item ID",description:"Existing item id (si_...) to update. Obtain it from List Subscription Items.",required:!1}),price:u.ShortText({displayName:"Price ID",required:!1}),quantity:u.Number({displayName:"Quantity",required:!1})}}),proration_behavior:u.StaticDropdown({displayName:"Proration Behavior",required:!1,options:{options:[{label:"Create Prorations",value:"create_prorations"},{label:"None",value:"none"},{label:"Always Invoice",value:"always_invoice"}]}}),cancel_at_period_end:u.Checkbox({displayName:"Cancel at Period End",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:Ne,async run(e){let{subscription_id:t,items:o,proration_behavior:n,cancel_at_period_end:r,metadata:i}=e.propsValue,a={};return n&&(a.proration_behavior=n),r!==void 0&&(a.cancel_at_period_end=r),i&&typeof i=="object"&&Object.keys(i).forEach(p=>{a[`metadata[${p}]`]=i[p]}),o&&Array.isArray(o)&&o.forEach((p,m)=>{let l=p;l.id&&(a[`items[${m}][id]`]=l.id),l.price&&(a[`items[${m}][price]`]=l.price),l.quantity!==void 0&&l.quantity!==null&&(a[`items[${m}][quantity]`]=l.quantity)}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/subscriptions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:a})).body}});var Zk=E({name:"get_subscription",classification:"READ",auth:_,displayName:"Get Subscription (Agent)",description:"Retrieve a Stripe subscription by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe subscription by its subscription ID (e.g., sub_...). Use List/Search Subscriptions to discover IDs. Read-only and idempotent.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0})},outputSchema:Ne,async run(e){let{subscription_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/subscriptions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Vk=E({name:"list_subscriptions",classification:"SEARCH",auth:_,displayName:"List Subscriptions (Agent)",description:"List Stripe subscriptions.",audience:"ai",aiMetadata:{description:"Pages through subscriptions, newest first, optionally filtered by customer, status, or price. Use to enumerate or audit a customer's subscriptions; for rich filters/customer-hydration use Search Subscriptions, or Get Subscription when you have the sub_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to subscriptions for this customer (cus_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"All",value:"all"},{label:"Active",value:"active"},{label:"Past Due",value:"past_due"},{label:"Unpaid",value:"unpaid"},{label:"Canceled",value:"canceled"},{label:"Incomplete",value:"incomplete"},{label:"Incomplete Expired",value:"incomplete_expired"},{label:"Trialing",value:"trialing"},{label:"Paused",value:"paused"}]}}),price:u.ShortText({displayName:"Price ID",description:"Filter to subscriptions containing this price (price_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Xx,async run(e){let{customer:t,status:o,price:n,limit:r}=e.propsValue,i={};return t&&(i.customer=t),o&&(i.status=o),n&&(i.price=n),r&&(i.limit=r.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/subscriptions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var Gk=E({name:"list_subscription_items",classification:"SEARCH",auth:_,displayName:"List Subscription Items (Agent)",description:"List the line items of a subscription.",audience:"ai",aiMetadata:{description:"Pages through the items of a single subscription, returning the subscription-item IDs (si_...) needed to update quantity or report usage. Use before Update Subscription when modifying a specific item. Read-only and idempotent.",idempotent:!0},props:{subscription_id:u.ShortText({displayName:"Subscription ID",description:"The subscription ID (e.g., sub_...). Obtain it from List/Search Subscriptions.",required:!0}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Yx,async run(e){let{subscription_id:t,limit:o}=e.propsValue,n={subscription:t};return o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/subscription_items`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Hk=E({name:"get_payment_link",classification:"READ",auth:_,displayName:"Get Payment Link (Agent)",description:"Retrieve a Stripe payment link by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe payment link by its ID (e.g., plink_...), including its URL, active state, and line items. Use List Payment Links to discover IDs. Read-only and idempotent.",idempotent:!0},props:{payment_link_id:u.ShortText({displayName:"Payment Link ID",description:"The payment link ID (e.g., plink_...). Obtain it from List Payment Links.",required:!0})},outputSchema:st,async run(e){let{payment_link_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_links/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Wk=E({name:"list_payment_links",classification:"SEARCH",auth:_,displayName:"List Payment Links (Agent)",description:"List Stripe payment links.",audience:"ai",aiMetadata:{description:"Pages through payment links, optionally filtered by active state. Use to enumerate links or resolve a payment link ID; use Get Payment Link when you have the plink_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:eS,async run(e){let{active:t,limit:o}=e.propsValue,n={};return t&&(n.active=t),o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_links`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Kk=E({name:"create_checkout_session",classification:"WRITE",auth:_,displayName:"Create Checkout Session (Agent)",description:"Create a Stripe-hosted Checkout Session.",audience:"ai",aiMetadata:{description:"Creates a Stripe-hosted Checkout Session for one-time payment, subscription, or setup mode, with line items (price IDs + quantities) and success/cancel URLs. Richer than a payment link for one-off flows; for a reusable shareable URL use Create Payment Link. Not idempotent: each call creates a new session.",idempotent:!1},props:{mode:u.StaticDropdown({displayName:"Mode",description:"The Checkout mode.",required:!0,options:{options:[{label:"Payment (one-time)",value:"payment"},{label:"Subscription",value:"subscription"},{label:"Setup (save payment method)",value:"setup"}]}}),line_items:u.Array({displayName:"Line Items",description:"The prices and quantities. Required for payment and subscription modes.",required:!1,properties:{price:u.ShortText({displayName:"Price ID",description:"The price ID (e.g., price_...).",required:!0}),quantity:u.Number({displayName:"Quantity",required:!0})}}),success_url:u.ShortText({displayName:"Success URL",description:"URL to redirect to after successful payment.",required:!1}),cancel_url:u.ShortText({displayName:"Cancel URL",description:"URL to redirect to if the customer cancels.",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"An existing customer (cus_...) to associate with the session.",required:!1})},outputSchema:Uo,async run(e){let{mode:t,line_items:o,success_url:n,cancel_url:r,customer:i}=e.propsValue,a={mode:t};return n&&(a.success_url=n),r&&(a.cancel_url=r),i&&(a.customer=i),o&&Array.isArray(o)&&o.forEach((p,m)=>{let l=p;a[`line_items[${m}][price]`]=l.price,a[`line_items[${m}][quantity]`]=l.quantity}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/checkout/sessions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:a})).body}});var Jk=E({name:"get_checkout_session",classification:"READ",auth:_,displayName:"Get Checkout Session (Agent)",description:"Retrieve a Stripe Checkout Session by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Checkout Session by its ID (e.g., cs_...), including payment status, customer, and amounts. Use List Checkout Sessions to discover IDs. Read-only and idempotent.",idempotent:!0},props:{session_id:u.ShortText({displayName:"Session ID",description:"The Checkout Session ID (e.g., cs_...). Obtain it from List Checkout Sessions.",required:!0})},outputSchema:Uo,async run(e){let{session_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/checkout/sessions/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Xk=E({name:"list_checkout_sessions",classification:"SEARCH",auth:_,displayName:"List Checkout Sessions (Agent)",description:"List Stripe Checkout Sessions.",audience:"ai",aiMetadata:{description:"Pages through Checkout Sessions, newest first, optionally filtered by customer, PaymentIntent, or status. Use to enumerate sessions or resolve a session ID; use Get Checkout Session when you have the cs_ ID. Read-only and idempotent.",idempotent:!0},props:{customer:u.ShortText({displayName:"Customer ID",description:"Filter to sessions for this customer (cus_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to the session for this PaymentIntent (pi_...).",required:!1}),status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"Open",value:"open"},{label:"Complete",value:"complete"},{label:"Expired",value:"expired"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:tS,async run(e){let{customer:t,payment_intent:o,status:n,limit:r}=e.propsValue,i={};return t&&(i.customer=t),o&&(i.payment_intent=o),n&&(i.status=n),r&&(i.limit=r.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/checkout/sessions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var Yk=E({name:"create_payment_method",classification:"WRITE",auth:_,displayName:"Create Payment Method (Agent)",description:"Create a PaymentMethod from a token.",audience:"ai",aiMetadata:{description:"Creates a Stripe PaymentMethod of the given type from a single-use token (e.g. tok_visa, or a token produced by Stripe.js), with optional billing details. NEVER pass raw card numbers \u2014 raw PAN entry is restricted to PCI-compliant integrations; supply a token instead. Use before Attach Payment Method. Not idempotent: each call creates a new PaymentMethod.",idempotent:!1},props:{type:u.ShortText({displayName:"Type",description:"The PaymentMethod type (e.g., card).",required:!0}),token:u.ShortText({displayName:"Card Token",description:"A single-use card token (e.g., tok_visa or a Stripe.js token). Required for card type. Do NOT pass a raw card number.",required:!1}),billing_name:u.ShortText({displayName:"Billing Name",required:!1}),billing_email:u.ShortText({displayName:"Billing Email",required:!1})},outputSchema:zo,async run(e){let{type:t,token:o,billing_name:n,billing_email:r}=e.propsValue,i={type:t};return o&&(i["card[token]"]=o),n&&(i["billing_details[name]"]=n),r&&(i["billing_details[email]"]=r),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_methods`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Qk=E({name:"attach_payment_method",classification:"WRITE",auth:_,displayName:"Attach Payment Method (Agent)",description:"Attach a PaymentMethod to a customer.",audience:"ai",aiMetadata:{description:"Attaches a PaymentMethod to a customer so it can be charged off-session (e.g. for subscriptions or saved cards). Use after Create Payment Method. Idempotent: re-attaching the same PaymentMethod to the same customer is a no-op.",idempotent:!0},props:{payment_method_id:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID (e.g., pm_...) to attach. Obtain it from Create Payment Method or List Customer Payment Methods.",required:!0}),customer:u.ShortText({displayName:"Customer ID",description:"The customer ID (e.g., cus_...) to attach the PaymentMethod to.",required:!0})},outputSchema:zo,async run(e){let{payment_method_id:t,customer:o}=e.propsValue;return(await b.sendRequest({method:"POST",url:`${P.baseUrl}/payment_methods/${t}/attach`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{customer:o}})).body}});var ew=E({name:"get_payment_method",classification:"READ",auth:_,displayName:"Get Payment Method (Agent)",description:"Retrieve a PaymentMethod by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single PaymentMethod by its ID (e.g., pm_...), including type and (masked) card details. Use List Customer Payment Methods to discover a customer's PaymentMethod IDs. Read-only and idempotent.",idempotent:!0},props:{payment_method_id:u.ShortText({displayName:"Payment Method ID",description:"The PaymentMethod ID (e.g., pm_...). Obtain it from List Customer Payment Methods.",required:!0})},outputSchema:zo,async run(e){let{payment_method_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payment_methods/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var tw=E({name:"list_customer_payment_methods",classification:"SEARCH",auth:_,displayName:"List Customer Payment Methods (Agent)",description:"List a customer's attached payment methods.",audience:"ai",aiMetadata:{description:"Pages through the PaymentMethods attached to a customer, returning the pm_ IDs you can charge off-session. Use to find a customer's saved card before creating a payment. Read-only and idempotent.",idempotent:!0},props:{customer_id:u.ShortText({displayName:"Customer ID",description:"The customer ID (e.g., cus_...). Obtain it from Search/List Customers.",required:!0}),type:u.ShortText({displayName:"Type",description:"Filter by PaymentMethod type (e.g., card).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Vx,async run(e){let{customer_id:t,type:o,limit:n}=e.propsValue,r={};return o&&(r.type=o),n&&(r.limit=n.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/customers/${t}/payment_methods`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var rw=E({name:"create_coupon",classification:"WRITE",auth:_,displayName:"Create Coupon (Agent)",description:"Create a discount coupon.",audience:"ai",aiMetadata:{description:"Creates a discount coupon \u2014 either percent_off or amount_off (the latter requires a currency), with a duration of once, repeating (with duration_in_months), or forever. To expose it to customers wrap it in a Promotion Code. Not idempotent: each call creates a new coupon, and supplying a duplicate stable id returns a 409.",idempotent:!1},props:{percent_off:u.Number({displayName:"Percent Off",description:"Percentage discount (e.g., 25 for 25%). Use this OR Amount Off.",required:!1}),amount_off:u.Number({displayName:"Amount Off",description:"Flat discount in the smallest currency unit (e.g., 500 for $5.00). Requires Currency.",required:!1}),currency:u.ShortText({displayName:"Currency",description:"Three-letter ISO currency code. Required with Amount Off.",required:!1}),duration:u.StaticDropdown({displayName:"Duration",description:"How long the discount applies.",required:!0,options:{options:[{label:"Once",value:"once"},{label:"Repeating",value:"repeating"},{label:"Forever",value:"forever"}]}}),duration_in_months:u.Number({displayName:"Duration in Months",description:"Number of months the discount lasts. Required if duration is repeating.",required:!1}),name:u.ShortText({displayName:"Name",description:"Name shown to customers on invoices/receipts.",required:!1}),id:u.ShortText({displayName:"ID",description:"A custom unique coupon ID. If omitted, Stripe generates one. Reusing an existing id returns an error.",required:!1})},outputSchema:Nu,async run(e){let{percent_off:t,amount_off:o,currency:n,duration:r,duration_in_months:i,name:a,id:c}=e.propsValue,p={duration:r};return t!=null&&(p.percent_off=t),o!=null&&(p.amount_off=o),n&&(p.currency=n),i!=null&&(p.duration_in_months=i),a&&(p.name=a),c&&(p.id=c),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/coupons`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:p})).body}});var ow=E({name:"get_coupon",classification:"READ",auth:_,displayName:"Get Coupon (Agent)",description:"Retrieve a coupon by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single coupon by its ID. Use List Coupons to discover IDs. Read-only and idempotent.",idempotent:!0},props:{coupon_id:u.ShortText({displayName:"Coupon ID",description:"The coupon ID. Obtain it from List Coupons.",required:!0})},outputSchema:Nu,async run(e){let{coupon_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/coupons/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var nw=E({name:"list_coupons",classification:"SEARCH",auth:_,displayName:"List Coupons (Agent)",description:"List Stripe coupons.",audience:"ai",aiMetadata:{description:"Pages through coupons, newest first. Use to enumerate coupons or resolve a coupon ID; use Get Coupon when you have the ID. Read-only and idempotent.",idempotent:!0},props:{limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Fx,async run(e){let{limit:t}=e.propsValue,o={};return t&&(o.limit=t.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/coupons`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:o})).body}});var iw=E({name:"create_promotion_code",classification:"WRITE",auth:_,displayName:"Create Promotion Code (Agent)",description:"Create a customer-facing promotion code for a coupon.",audience:"ai",aiMetadata:{description:"Creates a customer-facing promotion code that maps to an existing coupon, with optional custom code string, customer restriction, max redemptions, and expiry. Create the coupon first with Create Coupon. Not idempotent: each call creates a new promotion code.",idempotent:!1},props:{coupon:u.ShortText({displayName:"Coupon ID",description:"The coupon ID this promotion code applies. Obtain it from List Coupons or Create Coupon.",required:!0}),code:u.ShortText({displayName:"Code",description:"The customer-facing code (e.g., SUMMER25). If omitted, Stripe generates one.",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"Restrict the code to this customer (cus_...).",required:!1}),max_redemptions:u.Number({displayName:"Max Redemptions",description:"Maximum number of times the code can be redeemed.",required:!1}),expires_at:u.DateTime({displayName:"Expires At",description:"When the promotion code expires.",required:!1}),active:u.Checkbox({displayName:"Active",required:!1})},outputSchema:Du,async run(e){let{coupon:t,code:o,customer:n,max_redemptions:r,expires_at:i,active:a}=e.propsValue,c={coupon:t};return o&&(c.code=o),n&&(c.customer=n),r!=null&&(c.max_redemptions=r),i&&(c.expires_at=Math.floor(new Date(i).getTime()/1e3)),a!==void 0&&(c.active=a),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/promotion_codes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded","Stripe-Version":"2025-05-28.basil"},body:c})).body}});var aw=E({name:"get_promotion_code",classification:"READ",auth:_,displayName:"Get Promotion Code (Agent)",description:"Retrieve a promotion code by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single promotion code by its ID (e.g., promo_...). Use List Promotion Codes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{promotion_code_id:u.ShortText({displayName:"Promotion Code ID",description:"The promotion code ID (e.g., promo_...). Obtain it from List Promotion Codes.",required:!0})},outputSchema:Du,async run(e){let{promotion_code_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/promotion_codes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var sw=E({name:"list_promotion_codes",classification:"SEARCH",auth:_,displayName:"List Promotion Codes (Agent)",description:"List Stripe promotion codes.",audience:"ai",aiMetadata:{description:"Pages through promotion codes, optionally filtered by coupon, active state, or the literal code string. Use to enumerate codes or resolve an ID; use Get Promotion Code when you have the promo_ ID. Read-only and idempotent.",idempotent:!0},props:{coupon:u.ShortText({displayName:"Coupon ID",description:"Filter to codes for this coupon.",required:!1}),active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),code:u.ShortText({displayName:"Code",description:"Filter to the literal code string (e.g., SUMMER25).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Bx,async run(e){let{coupon:t,active:o,code:n,limit:r}=e.propsValue,i={};return t&&(i.coupon=t),o&&(i.active=o),n&&(i.code=n),r&&(i.limit=r.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/promotion_codes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var cw=E({name:"retrieve_balance",classification:"READ",auth:_,displayName:"Retrieve Balance (Agent)",description:"Get the current Stripe account balance.",audience:"ai",aiMetadata:{description:"Fetches the current Stripe account balance, broken down into available and pending funds by currency. Use to check how much can be paid out. Read-only and idempotent; takes no parameters.",idempotent:!0},props:{},outputSchema:Lx,async run(e){return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/balance`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var uw=E({name:"list_balance_transactions",classification:"SEARCH",auth:_,displayName:"List Balance Transactions (Agent)",description:"List balance transactions (the reconciliation ledger).",audience:"ai",aiMetadata:{description:"Pages through the balance-transaction ledger \u2014 every item that affected the account balance (charges, refunds, fees, payouts), newest first. Optionally filter by type, payout, or created range. Use to reconcile activity to a payout. Read-only and idempotent.",idempotent:!0},props:{type:u.ShortText({displayName:"Type",description:"Filter by transaction type (e.g., charge, refund, payout).",required:!1}),payout:u.ShortText({displayName:"Payout ID",description:"Filter to transactions paid out in this payout (po_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:aS,async run(e){let{type:t,payout:o,created_after:n,created_before:r,limit:i}=e.propsValue,a={};return t&&(a.type=t),o&&(a.payout=o),i&&(a.limit=i.toString()),n&&(a["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),r&&(a["created[lte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/balance_transactions`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:a})).body}});var pw=E({name:"list_payouts",classification:"SEARCH",auth:_,displayName:"List Payouts (Agent)",description:"List payouts to the bank account.",audience:"ai",aiMetadata:{description:"Pages through payouts (funds sent to your bank account), newest first, optionally filtered by status or arrival date. Use to enumerate payouts or resolve a payout ID; use Get Payout when you have the po_ ID. Read-only and idempotent.",idempotent:!0},props:{status:u.StaticDropdown({displayName:"Status",required:!1,options:{options:[{label:"Pending",value:"pending"},{label:"In Transit",value:"in_transit"},{label:"Paid",value:"paid"},{label:"Failed",value:"failed"},{label:"Canceled",value:"canceled"}]}}),arrival_date_after:u.DateTime({displayName:"Arrival Date After",required:!1}),arrival_date_before:u.DateTime({displayName:"Arrival Date Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:oS,async run(e){let{status:t,arrival_date_after:o,arrival_date_before:n,limit:r}=e.propsValue,i={};return t&&(i.status=t),r&&(i.limit=r.toString()),o&&(i["arrival_date[gte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),n&&(i["arrival_date[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/payouts`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var lw=E({name:"create_tax_rate",classification:"WRITE",auth:_,displayName:"Create Tax Rate (Agent)",description:"Create a manual tax rate.",audience:"ai",aiMetadata:{description:"Creates a manual Stripe tax rate (a fixed percentage with a display name and inclusive/exclusive flag), for applying to invoices or subscriptions. This is the manual tax-rate object, not Stripe Tax automation. Not idempotent: each call creates a new tax rate.",idempotent:!1},props:{display_name:u.ShortText({displayName:"Display Name",description:"Name shown to customers (e.g., VAT).",required:!0}),percentage:u.Number({displayName:"Percentage",description:"The tax rate percentage (e.g., 20 for 20%).",required:!0}),inclusive:u.Checkbox({displayName:"Inclusive",description:"Whether the tax is included in the price.",required:!0}),jurisdiction:u.ShortText({displayName:"Jurisdiction",description:"Optional jurisdiction text (e.g., UK).",required:!1}),country:u.ShortText({displayName:"Country",description:"Two-letter ISO country code.",required:!1})},outputSchema:zu,async run(e){let{display_name:t,percentage:o,inclusive:n,jurisdiction:r,country:i}=e.propsValue,a={display_name:t,percentage:o,inclusive:n};return r&&(a.jurisdiction=r),i&&(a.country=i),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/tax_rates`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:a})).body}});var dw=E({name:"get_tax_rate",classification:"READ",auth:_,displayName:"Get Tax Rate (Agent)",description:"Retrieve a tax rate by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single tax rate by its ID (e.g., txr_...). Use List Tax Rates to discover IDs. Read-only and idempotent.",idempotent:!0},props:{tax_rate_id:u.ShortText({displayName:"Tax Rate ID",description:"The tax rate ID (e.g., txr_...). Obtain it from List Tax Rates.",required:!0})},outputSchema:zu,async run(e){let{tax_rate_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/tax_rates/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var mw=E({name:"list_tax_rates",classification:"SEARCH",auth:_,displayName:"List Tax Rates (Agent)",description:"List Stripe tax rates.",audience:"ai",aiMetadata:{description:"Pages through tax rates, optionally filtered by active or inclusive flags. Use to enumerate tax rates or resolve a tax rate ID; use Get Tax Rate when you have the txr_ ID. Read-only and idempotent.",idempotent:!0},props:{active:u.StaticDropdown({displayName:"Active",required:!1,options:{options:[{label:"Active only",value:"true"},{label:"Inactive only",value:"false"}]}}),inclusive:u.StaticDropdown({displayName:"Inclusive",required:!1,options:{options:[{label:"Inclusive only",value:"true"},{label:"Exclusive only",value:"false"}]}}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Zx,async run(e){let{active:t,inclusive:o,limit:n}=e.propsValue,r={};return t&&(r.active=t),o&&(r.inclusive=o),n&&(r.limit=n.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/tax_rates`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var fw=E({name:"create_credit_note",classification:"WRITE",auth:_,displayName:"Create Credit Note (Agent)",description:"Issue a credit note against a finalized invoice.",audience:"ai",aiMetadata:{description:"Issues a credit note against a finalized invoice \u2014 a post-payment adjustment (credit, refund, or out-of-band amount). Supply either a total credit_amount or itemized lines (in the smallest currency unit). The invoice must already be finalized. Not idempotent: each call creates a new credit note.",idempotent:!1},props:{invoice:u.ShortText({displayName:"Invoice ID",description:"The finalized invoice ID (e.g., in_...) to credit. Obtain it from List/Search Invoices.",required:!0}),amount:u.Number({displayName:"Amount",description:"Total amount of the credit note, in the smallest currency unit (e.g., 500 for $5.00). Stripe requires this (or itemized lines); it must not exceed the invoice total. By default the full amount credits the customer balance unless you also set Credit Amount / Refund Amount to split it.",required:!0}),credit_amount:u.Number({displayName:"Credit Amount",description:"The amount to credit to the customer balance, in the smallest currency unit (e.g., 500 for $5.00).",required:!1}),refund_amount:u.Number({displayName:"Refund Amount",description:"The amount to refund, in the smallest currency unit. Refunds against the original payment.",required:!1}),reason:u.StaticDropdown({displayName:"Reason",required:!1,options:{options:[{label:"Duplicate",value:"duplicate"},{label:"Fraudulent",value:"fraudulent"},{label:"Order Change",value:"order_change"},{label:"Product Unsatisfactory",value:"product_unsatisfactory"}]}}),memo:u.LongText({displayName:"Memo",required:!1})},outputSchema:Lo,async run(e){let{invoice:t,amount:o,credit_amount:n,refund_amount:r,reason:i,memo:a}=e.propsValue,c={invoice:t};return o!=null&&(c.amount=o),n!=null&&(c.credit_amount=n),r!=null&&(c.refund_amount=r),i&&(c.reason=i),a&&(c.memo=a),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/credit_notes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:c})).body}});var hw=E({name:"void_credit_note",classification:"DESTRUCTIVE",auth:_,displayName:"Void Credit Note (Agent)",description:"Void a credit note.",audience:"ai",aiMetadata:{description:"Voids a Stripe credit note, reversing the credit/refund it represented. Not idempotent: it errors if the credit note is already void.",idempotent:!1},props:{credit_note_id:u.ShortText({displayName:"Credit Note ID",description:"The credit note ID (e.g., cn_...). Obtain it from List Credit Notes.",required:!0})},outputSchema:Lo,async run(e){let{credit_note_id:t}=e.propsValue;return(await b.sendRequest({method:"POST",url:`${P.baseUrl}/credit_notes/${t}/void`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var yw=E({name:"get_credit_note",classification:"READ",auth:_,displayName:"Get Credit Note (Agent)",description:"Retrieve a credit note by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single credit note by its ID (e.g., cn_...), including its line items. Use List Credit Notes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{credit_note_id:u.ShortText({displayName:"Credit Note ID",description:"The credit note ID (e.g., cn_...). Obtain it from List Credit Notes.",required:!0})},outputSchema:Lo,async run(e){let{credit_note_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/credit_notes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var gw=E({name:"list_credit_notes",classification:"SEARCH",auth:_,displayName:"List Credit Notes (Agent)",description:"List Stripe credit notes.",audience:"ai",aiMetadata:{description:"Pages through credit notes, newest first, optionally filtered by invoice or customer. Use to enumerate credit notes or resolve a credit note ID; use Get Credit Note when you have the cn_ ID. Read-only and idempotent.",idempotent:!0},props:{invoice:u.ShortText({displayName:"Invoice ID",description:"Filter to credit notes for this invoice (in_...).",required:!1}),customer:u.ShortText({displayName:"Customer ID",description:"Filter to credit notes for this customer (cus_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:Qx,async run(e){let{invoice:t,customer:o,limit:n}=e.propsValue,r={};return t&&(r.invoice=t),o&&(r.customer=o),n&&(r.limit=n.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/credit_notes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:r})).body}});var vw=E({name:"list_events",classification:"SEARCH",auth:_,displayName:"List Events (Agent)",description:"List Stripe account events.",audience:"ai",aiMetadata:{description:"Pages through the account event log (the audit feed of everything that happened), newest first, optionally filtered by event type (e.g. invoice.paid) or created range. Use to investigate what happened to a resource. Read-only and idempotent.",idempotent:!0},props:{type:u.ShortText({displayName:"Type",description:"Filter by event type (e.g., invoice.paid, charge.refunded).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:iS,async run(e){let{type:t,created_after:o,created_before:n,limit:r}=e.propsValue,i={};return t&&(i.type=t),r&&(i.limit=r.toString()),o&&(i["created[gte]"]=Math.floor(new Date(o).getTime()/1e3).toString()),n&&(i["created[lte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/events`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:i})).body}});var _w=E({name:"get_event",classification:"READ",auth:_,displayName:"Get Event (Agent)",description:"Retrieve a single Stripe event by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe event by its ID (e.g., evt_...), including the object snapshot it carried. Use List Events or a webhook payload to obtain the ID. Read-only and idempotent.",idempotent:!0},props:{event_id:u.ShortText({displayName:"Event ID",description:"The event ID (e.g., evt_...). Obtain it from List Events or a webhook payload.",required:!0})},outputSchema:Mx,async run(e){let{event_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/events/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var bw=E({name:"get_dispute",classification:"READ",auth:_,displayName:"Get Dispute (Agent)",description:"Retrieve a dispute by its ID.",audience:"ai",aiMetadata:{description:"Fetches a single Stripe dispute (chargeback) by its ID (e.g., dp_...), including its status, reason, and evidence due date. Use List Disputes to discover IDs. Read-only and idempotent.",idempotent:!0},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...). Obtain it from List Disputes.",required:!0})},outputSchema:ar,async run(e){let{dispute_id:t}=e.propsValue;return(await b.sendRequest({method:"GET",url:`${P.baseUrl}/disputes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text}})).body}});var Pw=E({name:"list_disputes",classification:"SEARCH",auth:_,displayName:"List Disputes (Agent)",description:"List Stripe disputes (chargebacks).",audience:"ai",aiMetadata:{description:"Pages through disputes (chargebacks), newest first, optionally filtered by charge, PaymentIntent, or created range. Use to enumerate disputes or resolve a dispute ID; use Get Dispute when you have the dp_ ID. Read-only and idempotent.",idempotent:!0},props:{charge:u.ShortText({displayName:"Charge ID",description:"Filter to disputes for this charge (ch_...).",required:!1}),payment_intent:u.ShortText({displayName:"Payment Intent ID",description:"Filter to disputes for this PaymentIntent (pi_...).",required:!1}),created_after:u.DateTime({displayName:"Created After",required:!1}),created_before:u.DateTime({displayName:"Created Before",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:rS,async run(e){let{charge:t,payment_intent:o,created_after:n,created_before:r,limit:i}=e.propsValue,a={};return t&&(a.charge=t),o&&(a.payment_intent=o),i&&(a.limit=i.toString()),n&&(a["created[gte]"]=Math.floor(new Date(n).getTime()/1e3).toString()),r&&(a["created[lte]"]=Math.floor(new Date(r).getTime()/1e3).toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/disputes`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:a})).body}});var xw=E({name:"list_transfers",classification:"SEARCH",auth:_,displayName:"List Transfers (Agent)",description:"List transfers to connected accounts (Stripe Connect).",audience:"ai",aiMetadata:{description:"Pages through transfers to connected accounts, newest first, optionally filtered by destination. Stripe Connect platforms only \u2014 on a standard (non-Connect) account this returns an empty list, which is expected, not an error. Read-only and idempotent.",idempotent:!0},props:{destination:u.ShortText({displayName:"Destination Account ID",description:"Filter to transfers to this connected account (acct_...).",required:!1}),limit:u.Number({displayName:"Limit",description:"Number to return (1-100, default 10).",required:!1})},outputSchema:nS,async run(e){let{destination:t,limit:o}=e.propsValue,n={};return t&&(n.destination=t),o&&(n.limit=o.toString()),(await b.sendRequest({method:"GET",url:`${P.baseUrl}/transfers`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},queryParams:n})).body}});var Sw=E({name:"update_dispute",classification:"WRITE",auth:_,displayName:"Update Dispute (Agent)",description:"Submit or update evidence on a dispute.",audience:"ai",aiMetadata:{description:"Submits or updates evidence and metadata on a Stripe dispute (chargeback) to contest it. Set submit=true to finalize and submit the evidence to the bank \u2014 once submitted, evidence can no longer be changed. Prefer this (contest with evidence) over Close Dispute (which concedes). Idempotent for metadata/evidence edits; submitting is a one-way action.",idempotent:!0},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...). Obtain it from List Disputes.",required:!0}),evidence:u.Json({displayName:"Evidence",description:'A Stripe dispute evidence object (e.g., {"product_description":"...","customer_name":"..."}).',required:!1}),submit:u.Checkbox({displayName:"Submit",description:"If true, finalizes and submits the evidence to the bank. This cannot be undone.",required:!1}),metadata:u.Json({displayName:"Metadata",required:!1})},outputSchema:ar,async run(e){let{dispute_id:t,evidence:o,submit:n,metadata:r}=e.propsValue,i={};return n!==void 0&&(i.submit=n),o&&typeof o=="object"&&Object.keys(o).forEach(c=>{i[`evidence[${c}]`]=o[c]}),r&&typeof r=="object"&&Object.keys(r).forEach(c=>{i[`metadata[${c}]`]=r[c]}),(await b.sendRequest({method:"POST",url:`${P.baseUrl}/disputes/${t}`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:i})).body}});var Tw=E({name:"close_dispute",classification:"DESTRUCTIVE",auth:_,displayName:"Close Dispute (Agent)",description:"Concede a dispute (DESTRUCTIVE \u2014 forfeits the funds).",audience:"ai",aiMetadata:{description:"DESTRUCTIVE AND IRREVERSIBLE: closing a dispute concedes the chargeback and permanently forfeits the disputed funds \u2014 the money is lost and cannot be recovered. Almost always prefer Update Dispute (submit evidence to contest) instead. Only use when you explicitly intend to give up the dispute. Not idempotent.",idempotent:!1},props:{dispute_id:u.ShortText({displayName:"Dispute ID",description:"The dispute ID (e.g., dp_...) to concede. Obtain it from List Disputes.",required:!0})},outputSchema:ar,async run(e){let{dispute_id:t}=e.propsValue;return(await b.sendRequest({method:"POST",url:`${P.baseUrl}/disputes/${t}/close`,authentication:{type:"BEARER_TOKEN",token:e.auth.secret_text},headers:{"Content-Type":"application/x-www-form-urlencoded"},body:{}})).body}});var _=ih.SecretText({displayName:"Secret API Key",required:!0,description:"Secret key acquired from your Stripe dashboard",validate:s(async({auth:e})=>{try{return await b.sendRequest({method:"GET",url:"https://api.stripe.com/v1/customers",headers:{Authorization:`Bearer ${e}`}}),{valid:!0}}catch{return{valid:!1,error:"Invalid API Key. Please check the key and try again."}}},"validate")}),r1=nb({displayName:"Stripe",description:"Online payment processing for internet businesses",minimumSupportedRelease:"0.86.4",logoUrl:"https://cdn.activepieces.com/pieces/stripe.png",authors:["lldiegon","doskyft","kishanprmr","MoShizzle","AbdulTheActivePiecer","khaledmashaly","abuaboud","Prabhukiran161","sanket-a11y"],categories:["COMMERCE","PAYMENT_PROCESSING"],auth:_,actions:[dS,mS,IA,RA,fS,jA,FA,BA,ZA,VA,GA,HA,WA,KA,JA,XA,YA,QA,ek,tk,rk,ok,nk,ik,ak,sk,ck,uk,pk,lk,dk,mk,fk,hk,yk,gk,vk,_k,bk,Pk,xk,Sk,Tk,Ek,Ik,Ak,kk,wk,Ok,Rk,Ck,$k,Nk,Dk,zk,Mk,Lk,Uk,qk,jk,Fk,Bk,Zk,Vk,Gk,Hk,Wk,Kk,Jk,Xk,Yk,Qk,ew,tw,rw,ow,nw,iw,aw,sw,cw,uw,pw,lw,dw,mw,fw,hw,yw,gw,vw,_w,bw,Pw,xw,Sw,Tw,bx({baseUrl:s(()=>"https://api.stripe.com/v1","baseUrl"),auth:_,authMapping:s(async e=>({Authorization:`Bearer ${e.secret_text}`}),"authMapping")})],triggers:[kA,AA,OA,wA,CA,$A,NA,DA,zA,MA,LA,UA,qA]});0&&(module.exports={stripe,stripeAuth});
|
|
17
55
|
/*! Bundled license information:
|
|
18
56
|
|
|
19
57
|
mime-types/index.js:
|